Return type of GetRunTimeCounterValue() generated for FreeRTOS Run Time Stats does not match configRUN_TIME_COUNTER_TYPE
This is a bug with the code generation with STM32CubeMX2.
In STM32CubeMX2, enable the middleware FreeRTOS, and in its settings Core → Main features → Advanced parameters selector → Task statistics and run-time, enable “Generate run time stats”.
This generate a function in mx_freertos_app.c:
/**
* @brief Function to get the current value of the run-time timer counter.
* @param None
* @retval uint64_t The current counter value.
*/
uint64_t GetRunTimeCounterValue (void)
{
return 0;
}The return type is uint64_t, but it does not match the following type from FreeRTOSConfig.h (which cannot be changed in STM32CubeMX2):
#define configRUN_TIME_COUNTER_TYPE uint32_t
