Forum: ARM programming with GCC/GNU tools LPC1768 + FreeRTOS not working

Author: nissan (Guest)
Posted on:
Attached files:

Rate this post
0 useful
not useful

since weeks I am trying to get freeRTOS to work on a NXP LPC1768 Cortex 
M3 with CodeSourcery G++ Lite Compiler (using Eclipse IDE).

I have tried an altered CMSIS startupfile (with interrupt vector table 
adapted to freeRTOS handlers) and the included startup-file of the 
codeRed demo-project. Neither of them is working.
The university I am attending gave me the evaluation board where the 
cortex m3 is placed onto, so it is not a commercial version. However 
nobody at university can tell me what the problem is, or why it is not 

Within the main() function I just create one simple Task which is 
supposed to toggle a LED, but already the creation of the task fails and 
the programm does not even come to start the scheduler.

I have added the eclipse project in the hope that somebody can help me.
Maybe somebody has a working hardware of the lpc1768 and can test the 
project, or somebody can tell me just by looking at the code where the 
problem is.
Would really appreciate any kind of help.

Best regards,

Author: Gerd Bauer (Guest)
Posted on:

Rate this post
0 useful
not useful
Try instead of
xTaskCreate(vTask1,  (const signed char * const)("Task 1"),configMINIMAL_STACK_SIZE,NULL,tskIDLE_PRIORITY,NULL );
  int main( void )
  /* Create one task. */
  xTaskCreate(vTask1,  "Task1",configMINIMAL_STACK_SIZE*10,NULL,tskIDLE_PRIORITY+1,NULL );
  GPIO_SetValue(1, 0x02);    /* Turn on P1.1 */
  /* Start the scheduler so our tasks start executing. */
  /* If all is well we will never reach here as the scheduler will now be
  running.  If we do reach here then it is likely that there was insufficient
  heap available for the idle task to be created. */
  for( ;; );
  return 0;

void vTask1( void *pvParameters )
  //for( ;; )
    GPIO_SetValue(1, 0x02);    /* Turn on P1.1 */
    vTaskDelay(2000/portTICK_RATE_MS);    /* Insert delay */
    GPIO_ClearValue(1, 0x03);    /* Turn off P1.1 */
    vTaskDelay(2000/portTICK_RATE_MS);     /*Insert delay */
    GPIO_SetValue(1, 0x02);    /* Turn on P1.1 */
    vTaskDelay(2000/portTICK_RATE_MS);    /* Insert delay */    

Does it turn on? -> Init OK Port OK

Does it turn on, off, on, off -> Task has been executed


Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]

Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.