2023-10-19 07:16 AM
I am using STM32F407ZET MCU and using Eclipse IDE. My PCB board is working fine, I check and verify. In my firmware I am using timer 6 as an interrupt and systick is used for freertos. But when I click on the debug option it jumps on the following function and freezes.
void __attribute__ ((section(".after_vectors")))
Default_Handler(void)
{
#if defined(DEBUG)
__DEBUG_BKPT();
#endif
while (1)
{
;
}
}
I tried with STM32CUBE IDE, it is working normal. What can be the reason?
Solved! Go to Solution.
2023-10-20 07:31 AM
Thanks for the reply:
IQRHandler(); function was missing. I add the function and now my program does not stuck.
void TIM6_DAC_IRQHandler(void)
{
/* USER CODE BEGIN TIM6_DAC_IRQn 0 */
/* USER CODE END TIM6_DAC_IRQn 0 */
HAL_TIM_IRQHandler(&htim6);
/* USER CODE BEGIN TIM6_DAC_IRQn 1 */
/* USER CODE END TIM6_DAC_IRQn 1 */
}
2023-10-19 07:43 AM
> I am using STM32F407ZET MCU and using Eclipse IDE.
> I tried with STM32CUBE IDE, it is working normal.
Wouldn't that suggest it's an IDE issue? Why not just use STM32CubeIDE, as it's Eclipse-based anyway.
But jumping to default handler suggests ResetHandler is perhaps not properly defined or put in the vector table.
2023-10-19 08:58 AM - edited 2023-10-19 08:59 AM
Hello @Abid
The issue could be related to the debugger settings or the startup file. You can check the initial SP and PC and it should point to Reset_Handler.
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2023-10-20 07:31 AM
Thanks for the reply:
IQRHandler(); function was missing. I add the function and now my program does not stuck.
void TIM6_DAC_IRQHandler(void)
{
/* USER CODE BEGIN TIM6_DAC_IRQn 0 */
/* USER CODE END TIM6_DAC_IRQn 0 */
HAL_TIM_IRQHandler(&htim6);
/* USER CODE BEGIN TIM6_DAC_IRQn 1 */
/* USER CODE END TIM6_DAC_IRQn 1 */
}