aboutsummaryrefslogtreecommitdiff
path: root/include/ubox_timer.h
blob: 3a723ccd7141e22cdb161ef193a3b76be2005708 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#pragma once

/* updates 18.2 times per second */
extern volatile uint32_t ubox_ticks;

void ubox_timer_init();
void ubox_timer_free();

/* to be called 18.2 times per second */
void ubox_timer_user_fn(void (*fn)(void));

/* countdown clock updating by seconds */
void ubox_timer_start(uint8_t secs, volatile uint8_t *updated);
uint8_t ubox_timer_value();
void ubox_timer_stop();
void ubox_timer_resume();