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

xTaskResumeAll - Endless loop

Posted by Nobody/Anonymous on December 19, 2005
I'm using LPC2148 and freeRTOSV3.2.4.

It works fine for a whole bunch of tasks. But if I start now anothoer one I get into this while loop in xTaskResumeAll after a while:

/* If any ticks occurred while the scheduler was suspended then they should be processed now. This ensures the tick count does not slip, and that any delayed tasks are resumed at the correct time. */
if( uxMissedTicks > ( unsigned portBASE_TYPE ) 0 )
{
while( uxMissedTicks > ( unsigned portBASE_TYPE ) 0 )
{
vTaskIncrementTick();
--uxMissedTicks;
}

It doesn't return from this loop anymore, so RTOS is blocked. I'm just starting a simple task more like:

for(;;)
{
vTaskDelay(20);
}

If i don't start this task, my application works fine. I don't have an idea what I have done wrong.

Can you help me?

Thanks, Stefan

RE: xTaskResumeAll - Endless loop

Posted by Nobody/Anonymous on December 19, 2005
Most likely memory corruption. Check the stacks of your tasks have not overflowed. Also, try stepping through the creation of the offending task to check it can obtain the memory it requires.

RE: xTaskResumeAll - Endless loop

Posted by John W. on December 20, 2005
I agree.

You said you allocated a whole bunch of tasks.
Each task takes stack space - you can deplete
available memory with too many tasks.

How many tasks have you created?
What is the amount of stack space allocated for
each task?
How much memory can your application address?

These types of problems are usually simple to figure out - so that's the good news I suppose.
The bad news is that you many not be able to allocate all of the tasks you require with the memory available.

Good Luck,
John W.

RE: xTaskResumeAll - Endless loop

Posted by Nobody/Anonymous on December 20, 2005
Thanks a lot. I'll check out the memory allocation and I'm sure I'll get this thing working. Thanks for helping me, kind regards Stefan


[ 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