andysworkshop / stm32plus

The C++ library for the STM32 F0, F100, F103, F107 and F4 microcontrollers

Home Page:http://www.andybrown.me.uk

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SysTick_Handler

fiedlfa opened this issue · comments

Hi,

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

/*

  • SysTick_Handler in stm32plus is now marked 'weak' so that compatibility with other

  • frameworks is made possible.

    .weak SysTick_Handler
    .thumb_set SysTick_Handler,Default_Handler
    */

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.