From 7893fa123087328d5721fa27e9ee45130ba5da96 Mon Sep 17 00:00:00 2001 From: Gergő J. Miklós Date: Sun, 12 May 2019 12:37:47 +0200 Subject: hmc5883 added + some refactoring --- src/hmc5883.c | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 src/hmc5883.c (limited to 'src/hmc5883.c') diff --git a/src/hmc5883.c b/src/hmc5883.c new file mode 100644 index 0000000..6167f73 --- /dev/null +++ b/src/hmc5883.c @@ -0,0 +1,29 @@ + +#include +#include +#include +#include +#include + + +#include "hmc5883.h" + +extern int file; +extern void bus_err(int ern); +extern void print_help(void); +unsigned char buf[5]; + + +void hmc5883_print_all(void) +{ + printf( + "00: Temperature data [°C] (reg: 0x00)\n" + "01: Configuration [hex] (reg: 0x01)\n" + "02: Tos (Overtemp) [°C] (reg: 0x03)\n" + "03: Thys (Hysteresis) [°C] (reg: 0x04)\n" + "\n"); +} + +void hmc5883_read_all(const char *opts) {} +void hmc5883_read_one(const char *opts) {} +void hmc5883_conf_set(const char *opts){} \ No newline at end of file -- cgit v1.2.3