From e0eeeb389302c3050310ac8e618119384ce0fef8 Mon Sep 17 00:00:00 2001 From: Gergő J. Miklós Date: Mon, 13 May 2019 00:49:29 +0200 Subject: LM75 refactored --- src/main.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/main.c') diff --git a/src/main.c b/src/main.c index 18f762a..7afe9c0 100644 --- a/src/main.c +++ b/src/main.c @@ -31,9 +31,9 @@ uint16 devicef; //# Bus-Device file uchar temp[256]; void (*print_all)(void) = NULL; -void (*read_all)(const char *opts) = NULL; -void (*read_one)(const char *opts) = NULL; -void (*conf_set)(const char *opts) = NULL; +void (*read_all)(const uchar *opts) = NULL; +void (*read_one)(const uchar *opts) = NULL; +void (*conf_set)(const uchar *opts) = NULL; void print_help(void) { @@ -79,12 +79,12 @@ void preinit(const char *dev_type){ conf_set = hih61xx_conf_set; } - else if(!strcmp("hmc5883", dev_type)) { - print_all = hmc5883_print_all; - read_all = hmc5883_read_all; - read_one = hmc5883_read_one; - conf_set = hmc5883_conf_set; - } + // else if(!strcmp("hmc5883", dev_type)) { + // print_all = hmc5883_print_all; + // read_all = hmc5883_read_all; + // read_one = hmc5883_read_one; + // conf_set = hmc5883_conf_set; + // } } @@ -153,7 +153,7 @@ int main(int argc, char *argv[]) } else if(!strcmp("read_one",argv[1]) && read_one != NULL && argc > 5) //# Prints out the selected register { - read_one(argv[5]); + read_one((uchar*)argv[5]); } else //# No other option { -- cgit v1.2.3