Digi-Key SmartFusion2 Maker Kit FreeRTOS undefined reference

Hi everybody,

Who can help me?

I bought the Digi-Key SmartFusion2 Maker Kit and I am testing the example from eewiki:


I am in the last step to build the project but I have 2 errors about the FreeRTOS 9.0 undefined reference:

undefined reference to `ulGetRunTimeCounterValue’ in tasks.c

undefined reference to `vConfigureTimerForRunTimeStats’ in tasks.c

FreeRTOS 9
SoftConsole v4.0
Libero Soc v11.8



I’m guessing your version of FreeRTOS is different than was used in the guide. There are two options:

  1. You could disable run time stats altogether if you don’t need them in FreeRTOSConfig.h. Just change the #define to:
    #define configGENERATE_RUN_TIME_STATS 0

  2. vConfigureTimerForRunTimeStats is defined in RunTimeStatsTimer.c which should be in your project. If it’s not, you can find it in the SmartFusion demo in the FreeRTOS source directory: FreeRTOSv9.0.0\FreeRTOS\Demo\CORTEX_SmartFusion2_M2S050_SoftConsole\RTOSDemo

Instructions on using this FreeRTOS feature are here: https://www.freertos.org/rtos-run-time-stats.html

Hi Taylor,

Thanks very much for your help !! You resolved the problem.

I am using the same Free RTOS v9.0.0 of the eewiki example.

The problem is about the RunTimeStats.c that you informed. When I inserted this file into the project, the error was solved.

Look in the eewiki example, there is a small problem to solve, in the item: Import Free RTOS line 4: Check the entire FreeRTOS-Source directory amd also import FreeRTOSConfig. h , it is necessary to import the RunTimeStats.c too to work. Just it !!



Hi RicahrdBarry,

Thanks for your help and attention.


Strange, I don’t recall having to import that file when I made the project which made me think it was a different FreeRTOS release. Maybe I disabled the run time stats.

Either way, thanks for pointing that out. I’ll make a note to include the file on the wiki.