diff options
Diffstat (limited to 'firmware/export')
-rw-r--r-- | firmware/export/timer.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/firmware/export/timer.h b/firmware/export/timer.h index b12ec55881..92b26db216 100644 --- a/firmware/export/timer.h +++ b/firmware/export/timer.h | |||
@@ -30,6 +30,7 @@ | |||
30 | #define TIMER_FREQ 1000000 | 30 | #define TIMER_FREQ 1000000 |
31 | #endif | 31 | #endif |
32 | 32 | ||
33 | /* NOTE: if unreg cb is defined you are in charge of calling timer_unregister() */ | ||
33 | bool timer_register(int reg_prio, void (*unregister_callback)(void), | 34 | bool timer_register(int reg_prio, void (*unregister_callback)(void), |
34 | long cycles, void (*timer_callback)(void) | 35 | long cycles, void (*timer_callback)(void) |
35 | IF_COP(,int core)); | 36 | IF_COP(,int core)); |
@@ -37,6 +38,10 @@ bool timer_set_period(long cycles); | |||
37 | #ifdef CPU_COLDFIRE | 38 | #ifdef CPU_COLDFIRE |
38 | void timers_adjust_prescale(int multiplier, bool enable_irq); | 39 | void timers_adjust_prescale(int multiplier, bool enable_irq); |
39 | #endif | 40 | #endif |
41 | |||
42 | /* NOTE: unregister callbacks are not called by timer_unregister() | ||
43 | * the unregister_callback only gets called when your timer gets | ||
44 | * overwritten by a lower priority timer using timer_register() */ | ||
40 | void timer_unregister(void); | 45 | void timer_unregister(void); |
41 | 46 | ||
42 | /* target-specific interface */ | 47 | /* target-specific interface */ |