andysworkshop / stm32plus

The C++ library for the STM32 F0, F100, F103, F107 and F4 microcontrollers
http://www.andybrown.me.uk
Other
745 stars 224 forks source link

SysTick_Handler #184

Open fiedlfa opened 8 years ago

fiedlfa commented 8 years ago

Hi,

i think you should really not disable the SysTick_Handler by comment it out in the Start-Assembler Code.

/*

I don't know to which other frameworks you refer but if someone (like me) looks in the original Assembler Code from STM one can miss that you comment it out. If you flash code with the SysTick_Handler to your Stm32 he wants to jump into the SysTick_Handler and doesn't find it and therefor jumps in the WWDG_IRQHandler (either because its the next Handler or its somehow the default one). To find this bug is very tedious.

STM uses in the _it.c (e.g. stm32f10x_it.c) just a empty method as the SysTick_Handler.

I would suggest to do a similar thing. I don't know what's your favorite Version so i didn't file a pull request, but i would probably make a file: config/SysTick_Handler.h which has just the Method: void SysTick_Handler(void) { }

I think this will increase the usability, because also the other way round if i would use a different framework it would be quite difficult to realize the SysTick_Handler is not called because of the Assembler.