2020-06-30 11:30 AM
I have designed a custom board for my simple timer interrupt based application for STM32F446re it is run properly in debug mode but not working in normal run, firstly i thought may be some issue with board but if i run the code with normal delay then it work fine in normal mode. dont know how to solve the issue. keed help:sad_but_relieved_face:
2020-06-30 11:38 AM
What is the difference between "debug mode" and "normal run"? Optimization level when compiling? Then you most probably didn't use properly the volatile qualifier for variables shared between main and interrupt.
JW
2020-06-30 12:41 PM
You can also run the code, then attach a debugger to it without resetting. Could be stuck in a hardfault handler.
Typically when this happens, it's due to a bug in your code.
2020-06-30 08:59 PM
Previously i was using 84MZ APB1 bus now i have compiled the project with 16MHZ and now my code work properly.
2020-06-30 10:08 PM
@NPhal.1 it could be linked with hardware design. Did you follow HW getting started application note? Please check here: https://www.st.com/resource/en/application_note/dm00115714-getting-started-with-stm32f4xxxx-mcu-hardware-development-stmicroelectronics.pdf
2020-06-30 11:51 PM
> i was using 84MZ APB1 bus
That's more than is the allowed maximum frequency for APB1, see datasheet.
JW