2023-12-01 12:06 PM
Hi Everyone, I am working with STM32L431CBT6 and STM IDE cube 1.14. I am currently facing the problem that the HAL_delay function is not working. on investigating further I found that SysTick_Handler(void) is never getting called and thus "uwTick" is never getting incremented.
I have seen that the systick is working but when ever the counter reaches zero, an interrupt is raised but soon the Stlinl-V3 debugger hangs and restarts.
But if I run the systick without raising interrupt everything works, the counter reloads and starts again.
I guess the issue is with the location of the interrupt, IRQ is going to a wrong location. I there a way that overwrite the default irq function and write my own.
Thanks for the help in advance.
Kind regards,
Dibyendu
2023-12-01 12:31 PM
The solution provided by Xme helped. But to figure this out was a few days work for me. May be a permanent solution can be found.
2023-12-01 07:00 PM
Is this a custom board?
Is BOOT0 pulled LOW ?
Is there a boot loader at 0x08000000 and an app somewhere deeper in FLASH ?
Doesn't SCB->VTOR normally get set in SystemInit() ?
2023-12-02 02:18 AM
in stm32xxxx_t.c
you should found SysTick_Handler and it maybe have no HAL_SYSTICK_IRQHandler();
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_IRQHandler();
/* USER CODE END SysTick_IRQn 1 */
}
and after this, the HAL_SYSTICK_Callback in main.c should be active
/**
* @brief SYSTICK callback
* @PAram None
* @retval None
*/
void HAL_SYSTICK_Callback(void)
2024-01-20 01:04 PM - edited 2024-01-20 01:05 PM
Hi, I am getting similar problem in below setup:
1. Device is STM32U585.
2. ST provided BL is being used in the project.
3. This Project is TFM enabled.
4. Application is using threadX in non-secure zone.
My problem seems as same as below screenshot.
I have spent enough time on this and now got completely blank. Looking out for immediate support from #ST #STM32U5 #SysTick
Any help will be much appreciated.
2024-01-20 01:14 PM
>> Looking out for immediate support..
It is the weekend
The Vector Table is defined via SCB->VTOR, this address typically needs 512-byte alignment, depending on the number of vectors.
The table could be in RAM, you could change individual vectors that way.
The main vector list will be in startup.s make sure you have the name of the functions there, and that you get linkage. Watch C++ / .CPP name mangling if using those.
Watch SystemInit() configuration of SCB->VTOR if deeped in memory. A smarter method is to use linker symbols to assign the address based on the build settings.
If _disable_irq() is used in the loader, you'll need to re-enable