2014-07-09 10:33 PM
I'm using STM32Cube_FW_F4_V1.1.0 libraries for STM32F4. I found uint32_t HAL_GetTick(void) will provide tics in milliseconds.
I have found the following in a FreeRTOS based code .timeNowMs
=
xTaskGetTickCount
()
*
portTICK_RATE_MS
;
This problem is described athttp://forums.openpilot.org/topic/44037-gps-nmea-ubx-code-adaptaion-data-tests/?p=353138
( sorry for redirecting you). can I use it like timeNowMs = HAL_GetTick();Would this result in same functionality ? #freertos #milliseconds
2014-10-09 03:39 AM
Hi,
The HAL_GetTick() API is used to:There is a new API,HAL_InitTick() (not available in F4x STM32Cube V1.1.0), which is a weak function that configures the source of the time base, by default it is systick but can be redefined by user.
To conlcude, in your use case, you can use:timeNowMs = HAL_GetTick();
since the the tick count is incremented on each tick interrupt. xTaskGetTickCount() does nothing more than return the current tick count.
Regards,
Heisenberg.