From ff32f694fb2a0e2087b82e7903752a615d81ec44 Mon Sep 17 00:00:00 2001 From: "(no author)" <(no author)@6dc7ffe9-61d6-0310-9af1-9938baff3ed1> Date: Sat, 9 Sep 2006 10:45:06 +0000 Subject: TC_CDIV (carrier divisor) is part of both PICC and PCD, move it to 'os' git-svn-id: https://svn.openpcd.org:2342/trunk@150 6dc7ffe9-61d6-0310-9af1-9938baff3ed1 --- openpcd/firmware/src/os/tc_cdiv.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 openpcd/firmware/src/os/tc_cdiv.h (limited to 'openpcd/firmware/src/os/tc_cdiv.h') diff --git a/openpcd/firmware/src/os/tc_cdiv.h b/openpcd/firmware/src/os/tc_cdiv.h new file mode 100644 index 0000000..8b4031d --- /dev/null +++ b/openpcd/firmware/src/os/tc_cdiv.h @@ -0,0 +1,23 @@ +#ifndef _TC_CDIV_H +#define _TC_CDIV_H + +#include + +extern void tc_cdiv_phase_add(int16_t inc); +extern void tc_cdiv_set_divider(u_int16_t div); + +static inline void tc_cdiv_phase_inc(void) +{ + tc_cdiv_phase_add(1); +} + +static inline void tc_cdiv_phase_dec(void) +{ + tc_cdiv_phase_add(-1); +} + +extern void tc_cdiv_print(void); +extern void tc_cdiv_init(void); +extern void tc_cdiv_fini(void); + +#endif -- cgit v1.2.3