at24cm0x 1.0
at24cm0x driver library
Loading...
Searching...
No Matches
systick.h
Go to the documentation of this file.
1
19
20#ifndef SYSTICK_H_
21#define SYSTICK_H_
22
23 #include <util/atomic.h>
24
37
43
52 {
53 unsigned int expire;
55 };
56
62
63 void systick_init(void);
64 void systick_reset(void);
65 void systick_tick(void);
66 unsigned int systick_current(void);
67
68 void systick_timer_set(SYSTICK_Timer *timer, unsigned int delay_ticks);
70 unsigned int systick_timer_remaining(SYSTICK_Timer *timer);
71 void systick_timer_wait(unsigned int ticks);
72 void systick_timer_wait_ms(unsigned int ms);
73 void systick_timer_wait_us(unsigned int us);
75
76#endif /* SYSTICK_H_ */
Represents a SysTick software timer instance.
Definition systick.h:52
SYSTICK_Timer_Status status
Definition systick.h:54
unsigned int expire
Definition systick.h:53
SYSTICK_Timer_Status systick_timer_elapsed(SYSTICK_Timer *timer)
Checks whether a SysTick software timer has expired.
Definition systick.c:118
void systick_reset(void)
Resets the SysTick timer value.
Definition systick.c:48
unsigned int systick_timer_remaining(SYSTICK_Timer *timer)
Returns the remaining time before a SysTick timer expires.
Definition systick.c:142
struct SYSTICK_Timer_t SYSTICK_Timer
Alias for struct SYSTICK_Timer_t representing a SysTick software timer.
Definition systick.h:61
enum SYSTICK_Timer_Status_t SYSTICK_Timer_Status
Alias for enum SYSTICK_Timer_Status_t representing SysTick timer states.
Definition systick.h:42
void systick_timer_cancel(SYSTICK_Timer *timer)
Cancels a running SysTick software timer.
Definition systick.c:189
unsigned int systick_current(void)
Returns the current SysTick tick counter value.
Definition systick.c:76
void systick_timer_set(SYSTICK_Timer *timer, unsigned int delay_ticks)
Sets and starts a SysTick software timer.
Definition systick.c:97
void systick_init(void)
Initializes the SysTick timer module.
Definition systick.c:35
void systick_tick(void)
Increments the SysTick timer tick counter.
Definition systick.c:61
void systick_timer_wait_ms(unsigned int ms)
SYSTICK_Timer_Status_t
Represents the current status of the SysTick timer.
Definition systick.h:33
@ SYSTICK_Timer_Running
Definition systick.h:34
@ SYSTICK_Timer_Expired
Definition systick.h:35
void systick_timer_wait_us(unsigned int us)
void systick_timer_wait(unsigned int ticks)
Blocks execution for a specified number of SysTick ticks.
Definition systick.c:168