Undefined reference to `vApplicationIdleHook' and 'xTaskGetCurrentTaskHandle' while compiling!

ahelbadwi wrote on Wednesday, October 30, 2019:

hello everyone ,
i am a beginner in freertos and while porting the freertos files using eclipse and my target is atmega32 ,
i got these errors attached in the picture , could you support me ?

rtel wrote on Wednesday, October 30, 2019:

Anything that starts ‘Application’ is a callback function that must be
defined by the application writer if they have certain features enabled

  • in this case the feature is the idle hook function so you must either
    turn that feature off or define the hook. You can find the info in the
    book, but one of the easiest things is just to Google the undefined
    symbol to the doc pages - in this case https://www.freertos.org/a00016.html

xTaskGetCurrentTaskHandle() on the other hand starts Task so is defined
in tasks.c - here you will find the definitions required to make the
function available:
https://sourceforge.net/p/freertos/code/HEAD/tree/tags/V10.2.1/FreeRTOS/Source/tasks.c#l3904