VTaskDelay Frozen

Hi   I´m using FreeRtos 5.0.0 and I have two tasks in a MSP430 with IAR. One blocked for ever because it temporaly empty and in another if I try the following   const portTickType xDelay = 5;     for (;;)     {       LedToggle();       vTaskDelay( xDelay );     } The led only Blink if I use #define configUSE_PREEMPTION 0, if it is set it doesn´t work. If I use VTaskDelayUntil it doesn´t work with both configurations. The microcontroller is working perfectly because I´m sending and receiving data through a radio using interrupts. What I could be doing wrong? The full configuration is this one. #define configUSE_PREEMPTION              0 #define configUSE_IDLE_HOOK              0 #define configUSE_TICK_HOOK                  0 #define configCPU_CLOCK_HZ           ( ( unsigned portLONG ) 7372800 ) /* Clock setup from main.c in the demo application. */ #define configTICK_RATE_HZ           ( ( portTickType ) 256 ) #define configMAX_PRIORITIES           ( ( unsigned portBASE_TYPE ) 5 ) #define configMINIMAL_STACK_SIZE       ( ( unsigned portSHORT ) 100 ) #define configTOTAL_HEAP_SIZE           ( ( size_t ) ( 4000 ) ) #define configMAX_TASK_NAME_LEN          ( 8 ) #define configUSE_TRACE_FACILITY        0 #define configUSE_16_BIT_TICKS            1 #define configIDLE_SHOULD_YIELD            1 #define configUSE_MUTEXES                   1

VTaskDelay Frozen

Can you check that the tick interrupt is working, if you put a break point in the tick interrupt does it get hit repeatedly and does it increase uxTickCount? Also a delay of 5 is very low, could it be that the LED it toggling too quickly to see? Are any other tasks or interrupts accessing the same port that the LED is connected to? Regards.

VTaskDelay Frozen

Thanks Richard for your support. The problem was in the the tick interrupt, the FreeRTOSConfig.h was not properly included so the call to    #vTaskSwitchContext was never executed.          Regards.