Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem


Loading

Cant receive from the queue

Posted by Thomas Johansen on January 17, 2012
Hi

I have a strange problem. I have created an queue.

I post on the queue every 1 sec with task 1 using:
xQueueSend(g_xRXEvent, (void*)&nAll, ( portTickType ) 10);
The function do succeed every time.

In task 2 I try to receive the queue message using the xQueueReceive
while(TRUE)
{
if(pdTRUE == xQueueReceive (g_xRXEvent, &nRXBufferIndex, portMAX_DELAY))
{
.... Do stuff

The xQueueReceive never returns?
When the scheduler is started, the xQueueReceive do return in task 2 the first time, but that is before anything is send to the queue by task 1.?

The two task have the same priority
I'm running 7.1.0 on a LPC2478

Thomas

RE: Cant receive from the queue

Posted by Thomas Johansen on January 17, 2012
I may add, that other queue seems to work. I have a UART isr using xQueueSendFromISR that is working.

Thomas


[ Back to the top ]    [ About FreeRTOS ]    [ Privacy ]    [ Sitemap ]    [ ]


Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.

Latest News

Version 10.1.0 of the FreeRTOS kernel is available for immediate download. MIT licensed.

View a recording of the "OTA Update Security and Reliability" webinar, presented by TI and AWS.


Careers

FreeRTOS and other embedded software careers at AWS.



FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Espressif ESP32

IAR Partner

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Renesas

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

OpenRTOS and SafeRTOS

Xilinx Microblaze and Zynq partner