19 static uint32_t * _timerNow = _timers[0];
20 static uint32_t * _timerLast = _timers[1];
22 static uint32_t _tTot;
23 static uint32_t _tNow;
33 static uint32_t elapsed()
36 uint32_t e = c - _tNow;
41 static inline void newRound()
45 uint32_t * t = _timerNow;
46 _timerNow = _timerLast;
59 if (_tTot >= TIMER_MAX_COUNT)
61 _tTot -= TIMER_MAX_COUNT;
62 if (_sect >= 0) _timerNow[_sect] += e - _tTot;
66 _timerNow[_sect] += e;
#define TIMER_SECT_COUNT
No of timers to add.
int timerMark(int section)
Starts the timing of a new section, the previous section is returned, or -1 if it is the first...
White Rabbit simple timer 'Ticks' driver.
#define TIMER_SECT_IDLE
time spend being idle
static uint32_t ticks()
Nr of ticks since device start up.
uint32_t * timerValues()
Returns.
void timerInit()
Initializes the timer.