Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Real time embedded FreeRTOS mailing list 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT Training




Loading

highest priority task stuck in ready queue on NXP Cortex-M3

Posted by alexde on November 4, 2013

Hi,

I'm using FreeRTOS 7.3 and lwIP 1.4.1 on a NXP LPC1776 MCU.

The problem I have is that the TCP/IP task is not called any more after a few minutes. It runs into xQueueGenericReceive. Because the queue is empty but xTicksToWait is nonzero vTaskPlaceOnEventList is called. After calling portYIELDWITHINAPI the task does not start again although ethernet packets are received. The receive interrupts is still firing but the RTOS is running the IDLE and all other tasks but not the TCP/IP task.

I'm using IAR embedded workbench and the C-SPY debugger. I can see that the TCP/IP task is placed in the ready queue. This task has the highest priority in the system.

I made a similar application running on the LPC4337 Cortex-M4 core which runs without any problems.

I also verified that there is no stack overflow and the interrupt priorities are set via the CMSIS function NVIC_SetPriority.

Hopefully one of you can help.

Thank you in advance.

Best regards, Alex


highest priority task stuck in ready queue on NXP Cortex-M3

Posted by richardbarry on November 4, 2013

Are you running the latest version of FreeRTOS with configASSERT() defined? http://www.freertos.org/a00110.html#configASSERT

Does anything get posted into the queue on which the task is running? [I think it must if the task gets moved into the ready list]

Can you see the states of the tasks and the queue using the IAR FreeRTOS plug-in?

Regards.


highest priority task stuck in ready queue on NXP Cortex-M3

Posted by alexde on November 5, 2013

Hi Richard,

I'm using FreeRTOS 7.3 with configAssert defined as

define configASSERT( x ) if( ( x ) == 0 ) { taskDISABLE_INTERRUPTS(); for( ;; ); }

I attached a screenshot that shows the FreeRTOS plugin with the all the tasks and the queue status.

Regards Alex

Attachments

FreeRTOSTasks.png (16805 bytes)

highest priority task stuck in ready queue on NXP Cortex-M3

Posted by richardbarry on November 5, 2013

I'm using FreeRTOS 7.3 with configAssert defined as

Please use the latest version with configASSERT() defined - it has extra assert statements specifically to trap common configuration problems on Cortex-M devices.

Regards.


highest priority task stuck in ready queue on NXP Cortex-M3

Posted by alexde on November 5, 2013

I switched to FreeRTOS 7.5.3 but the outcome is the same. None of the configASSERTS is catching the problem.

Attached a picture of the IDE.

Regards, Alex

Attachments

FreeRTOSTasks.png (43036 bytes)

highest priority task stuck in ready queue on NXP Cortex-M3

Posted by richardbarry on November 5, 2013

Please zip up your project and send it to the "business contact" email address listed on http://www.freertos.org/contact . I will take a quick look to see if I can see anything obvious, otherwise we will have to take a deeper dive to try and debug what is happening.

Regards.


highest priority task stuck in ready queue on NXP Cortex-M3

Posted by richardbarry on November 5, 2013

Note I just edited the link in the post above so the full stop/period was not included as part of the URL.

Regards.


highest priority task stuck in ready queue on NXP Cortex-M3

Posted by alexde on November 5, 2013

Hi Richard,

I forgot to update the port files to 7.5.3.

Let me do that first and give you some feedback on how it works. If it is still not working I will upload the project.

Regards


highest priority task stuck in ready queue on NXP Cortex-M3

Posted by alexde on November 5, 2013

Hi,

after updating the port files to 7.5.3 the software seems to be working. It runs for about 15 minutes without problems until now.

Previously it crashed after 10 minutes latest. I will post here again if it cashes.

Thank you.

Regards, Alex


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




Copyright (C) 2004-2010 Richard Barry. Copyright (C) 2010-2016 Real Time Engineers Ltd.
Any and all data, files, source code, html content and documentation included in the FreeRTOSTM distribution or available on this site are the exclusive property of Real Time Engineers Ltd.. See the files license.txt (included in the distribution) and this copyright notice for more information. FreeRTOSTM and FreeRTOS.orgTM are trade marks of Real Time Engineers Ltd.

Latest News:

FreeRTOS V9.0.0 is now available for download.


Free TCP/IP and file system demos for the RTOS


Sponsored Links

⇓ Now With No Code Size Limit! ⇓
⇑ Free Download Without Registering ⇑


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Renesas Electronics Gold Alliance RTOS Partner.jpg

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Atmel RTOS partner supporting ARM Cortex-M3 and AVR32 microcontrollers

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

Xilinx Microblaze and Zynq partner

Silicon Labs low power RTOS partner

Altera RTOS partner for Nios II and Cortex-A9 SoC

Freescale Alliance RTOS Member supporting ARM and ColdFire microcontrollers

Infineon ARM Cortex-M microcontrollers

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

Cypress RTOS partner supporting ARM Cortex-M3

Fujitsu RTOS partner supporting ARM Cortex-M3 and FM3

Microsemi (previously Actel) RTOS partner supporting ARM Cortex-M3

Atollic Partner

IAR Partner

Keil ARM Partner

Embedded Artists