2019-01-21 09:56 AM
In stm32f3xx_hal_cortex.c defined systick interrupt:
void HAL_SYSTICK_IRQHandler(void)
{
HAL_SYSTICK_Callback();
}
but in stm32f3xx_it.c the systick interrupt defined too:
void SysTick_Handler(void)
{
/* USER CODE BEGIN SysTick_IRQn 0 */
/* USER CODE END SysTick_IRQn 0 */
HAL_IncTick();
/* USER CODE BEGIN SysTick_IRQn 1 */
/* USER CODE END SysTick_IRQn 1 */
}
Of course in interrupt table (startup_stm32f373xc.s) can be used only one :)
g_pfnVectors:
.word _estack
.word Reset_Handler
...
.word SysTick_Handler
And HAL_SYSTICK_IRQHandler is never called. And with it is not called user defined HAL_SYSTICK_Callback :(
2019-01-21 10:45 AM
This was already discussed , IIRC.
HAL_SYSTICK_Callback has been deprecated. 90% of users do not need it.
If you want to be called every systick interrupt, you can add the code directly in the SysTick_Handler.
--pa
2019-01-21 12:35 PM
Thank you.
Yes, i need callback to every systick interrupt. And now I simple add HAL_SYSTICK_Callback to SysTick_Handler:
void SysTick_Handler(void)
{
/* USER CODE BEGIN SysTick_IRQn 0 */
/* USER CODE END SysTick_IRQn 0 */
HAL_IncTick();
/* USER CODE BEGIN SysTick_IRQn 1 */
HAL_SYSTICK_Callback();
/* USER CODE END SysTick_IRQn 1 */
}
But it's something strange :)