Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Thread

FreeRTOS queues and ISRs

FreeRTOS queues and ISRs

2006-01-23 by Guillermo Prandi

Hi. Perhaps this is not the right place to post this, so sorry if it 
is not.

I am implementing FreeRTOS in my LPC2138 board. I am using the queue 
mechanism to serve the serial ports (this include an SPI port). In 
the ISRs I am using the xQueueSendFromISR() and xQueueReceiveFromISR
() functions, to whom I pass the xTaskPreviouslyWoken parameter with 
a pdFALSE the first time and, if the same ISR calls another QUEUE 
function, the xTaskPreviouslyWoken parameter gets the return value 
from a previous call. This seems pretty straightforward, but then I 
realized that I might be wrong. These are the questions that come to 
my mind:

- If xQueueSendFromISR() returns pdTRUE, should a further call to 
xQueueSendFromISR() but to a different queue get xTaskPreviouslyWoken 
= pdTRUE?

- If xQueueSendFromISR() returns pdTRUE, should a further call to 
xQueueReceiveFromISR() get xTaskPreviouslyWoken = pdTRUE? Or vice-
versa.

- What happens if two consecutive interrupts are served, the first 
interrupt gets a pdTRUE from -let's say- xQueueSendFromISR() and the 
second interrupt occurs before the woken task had had any scheduled 
time. Could a call to xQueueSendFromISR() with xTaskPreviouslyWoken = 
pdFALSE be harmful? i.e., the second interrupt knows nothing about 
the pdTRUE got from the first interrupt call.

Thanks in advance.

Guille

RE: [lpc2000] FreeRTOS queues and ISRs

2006-01-23 by Paul Curtis

Hi, 

> Hi. Perhaps this is not the right place to post this, so sorry if it 
> is not.

It's not.  Try the FreeRTOS forums:
http://sourceforge.net/forum/forum.php?forum_id=382005.

Rgds,

--
Paul Curtis, Rowley Associates Ltd  http://www.rowley.co.uk
CrossWorks for MSP430, ARM, AVR and now MAXQ processors

Re: FreeRTOS queues and ISRs

2006-01-23 by Guillermo Prandi

OK. Sorry. Thanks for the link.

Guille

--- In lpc2000@yahoogroups.com, "Paul Curtis" <plc@r...> wrote:
>
> Hi, 
> 
> > Hi. Perhaps this is not the right place to post this, so sorry if 
it 
Show quoted textHide quoted text
> > is not.
> 
> It's not.  Try the FreeRTOS forums:
> http://sourceforge.net/forum/forum.php?forum_id=382005.
> 
> Rgds,
> 
> --
> Paul Curtis, Rowley Associates Ltd  http://www.rowley.co.uk
> CrossWorks for MSP430, ARM, AVR and now MAXQ processors
>

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.