enum influxcmdtype { I_READ, I_WRITE, I_PING }; void colprintf( char *prefix, const char *col, char* format, va_list *args ); void info( char* format, ... ); void err( char* format, ... ); void warn( char* format, ... ); int hextoint(char *hex); int readresult(hid_device *dev, uint8_t *retbuf); void showlevel(uint8_t *buf); int tcpconnect(char *hname, int port); int dohttp(char *hname, int port, char *header, char *body, char *retbuf); struct hostent *resolve(char *hname); int influx_init(char *hname, char *db, char *user, char *pass); int influx_cmd(enum influxcmdtype cmdtype, char *cmd, char *retbuf); int influx_insert(char *cmd, char *retbuf); int influx_query(char *cmd, char *retbuf); int influx_ping(char *retbuf); int influx_write_decibels(double decibels);