aboutsummaryrefslogtreecommitdiff
path: root/client
diff options
context:
space:
mode:
Diffstat (limited to 'client')
-rw-r--r--client/i2c.cpp18
1 files changed, 0 insertions, 18 deletions
diff --git a/client/i2c.cpp b/client/i2c.cpp
index 2a5e67a..c8b2dc8 100644
--- a/client/i2c.cpp
+++ b/client/i2c.cpp
@@ -9,8 +9,6 @@
#include "pb.h"
#include "pb-types.h"
-// #include "pb/mod/main.h"
-
bool i2c_dump_send = true;
bool i2c_dump_recv = true;
@@ -34,8 +32,6 @@ void i2c_send(uint16_t addr, const char * data, size_t data_size) {
free(packed);
}
-static void i2c_handle_cmd_read(uint16_t, const char *, size_t);
-
void i2c_recv(const char * data, size_t data_size) {
if (i2c_dump_recv) {
_rl_printf_start();
@@ -45,17 +41,3 @@ void i2c_recv(const char * data, size_t data_size) {
}
}
-// static void i2c_handle_cmd_read(uint16_t i2c_addr, const char * buf, size_t sz) {
-// if (sz < 2) return; // require data address + 1 byte of data
-// pb_cmd_read_t * cmd = (pb_cmd_read_t *) buf;
-// sz--; // sz now represents size of cmd->data
-//
-// if (i2c_addr == BUSADDR_MAIN && cmd->address == 0x01) {
-// if (sz % 2 != 0) return; // invalid data
-// for (size_t offset = 0; offset < sz; offset += sizeof(pb_mod_main_mod_t)) {
-// pb_mod_main_mod_t * mod = (pb_mod_main_mod_t *) (cmd->data + offset);
-// printf("module at addr 0x%02x with state %d\n", mod->addr, mod->state);
-// }
-// }
-// }
-