diff options
Diffstat (limited to 'libyhy.c')
-rw-r--r-- | libyhy.c | 13 |
1 files changed, 6 insertions, 7 deletions
@@ -9,6 +9,12 @@ #ifdef DEBUG #include <stdio.h> #define DBG(x) (x) + static void xxd(uint8_t* buf, size_t len){ + size_t n; + for(n = 0; n < len; n++){ + printf("%02X ", buf[n]); + } + } #else #define DBG(x) #endif @@ -97,13 +103,6 @@ enum /*_yhy_command*/ { * uint8_t[4] data */ }; -static void xxd(uint8_t* buf, size_t len){ - size_t n; - for(n = 0; n < len; n++){ - DBG(printf("%02X ", buf[n])); - } -} - static ssize_t yhy_send_command(int fd, uint16_t node, uint16_t cmd, uint8_t* payload, size_t len){ size_t n; uint8_t checksum = 0x00; |