From 469a2bfbefd757c4088b71976729d3a148c495c9 Mon Sep 17 00:00:00 2001 From: alanbjohnston Date: Mon, 17 Aug 2020 20:42:33 -0400 Subject: [PATCH] cleanup after dealing with bus 11 properly and using python read --- afsk/telem.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/afsk/telem.c b/afsk/telem.c index 8e08914e..2255de10 100644 --- a/afsk/telem.c +++ b/afsk/telem.c @@ -99,13 +99,13 @@ struct SensorData read_sensor_data(struct SensorConfig sensor) { pclose(file); data.voltage = atof(cmdbuffer); - printf("voltage: %s \n", cmdbuffer); +// printf("voltage: %s \n", cmdbuffer); file = popen(sensor.commandi, "r"); fgets(cmdbuffer, 1000, file); pclose(file); - printf("current: %s \n", cmdbuffer); +// printf("current: %s \n", cmdbuffer); data.current = atof(cmdbuffer); @@ -171,7 +171,7 @@ struct SensorConfig config_sensor(char *bus, int address, int milliAmps) { char command[50] = "timeout 10 i2cdetect -y "; // strcat (command, &bus[pos]); strcat (command, buss); - printf("Command: %s \n", command); +// printf("Command: %s \n", command); FILE *i2cdetect = popen(command, "r"); while (fgets(result, 128, i2cdetect) != NULL) { @@ -200,7 +200,7 @@ struct SensorConfig config_sensor(char *bus, int address, int milliAmps) { strcat (pythonv, addr); strcpy (data.commandv, pythonv); - printf("V Command: %s \n", data.commandv); +// printf("V Command: %s \n", data.commandv); char spacei[] = " 0x"; strcat (pythoni, buss); @@ -208,7 +208,7 @@ struct SensorConfig config_sensor(char *bus, int address, int milliAmps) { strcat (pythoni, addr); strcpy (data.commandi, pythoni); - printf("V Command: %s \n", data.commandi); +// printf("V Command: %s \n", data.commandi); /* data.fd = wiringPiI2CSetupInterface(bus, address);