void SysTick_Handler(void) { timerCounter++; // these variables are all declared globally in main.cpp timer_10ms_tick = true; if ((timerCounter % 10) == 0) //every 100ms { timer_100ms_tick = true; } if ((timerCounter % 100) == 0) //every 1000ms { timer_1000ms_tick = true; } } |
SysTick_Config(12000000/100); |
#ifdef __cplusplus [color=#f00]extern "C" {[/color] #endif //SysTick void SysTick_Handler(void) //SysTick handler { ...blablabla... }//end SysTick handler #ifdef __cplusplus [color=#f00]}[/color] #endif |