From: Martin Mares Date: Mon, 27 Jul 2020 10:32:36 +0000 (+0200) Subject: BSB: Errors logged in decimal (for Grafana's sake) X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=0cc857a4e3c5992908895678cb5031192962a343;p=home-hw.git BSB: Errors logged in decimal (for Grafana's sake) --- diff --git a/MQTT b/MQTT index d6ef72b..a3b0a03 100644 --- a/MQTT +++ b/MQTT @@ -48,7 +48,7 @@ burrow/heating/circuit1/active 0/1 burrow/heating/circuit2/room-temp burrow/heating/circuit2/active 0/1 burrow/heating/water/active 0/1 -burrow/heating/error %04x [error code from message 0500:006b] +burrow/heating/error [error code from message 0500:006b in decimal] burrow/heating/clock yyyy-mm-ddThh:mm bsb/stats/* diff --git a/bsb/daemon/burrow-bsbd.c b/bsb/daemon/burrow-bsbd.c index 2ffb94f..d855b47 100644 --- a/bsb/daemon/burrow-bsbd.c +++ b/bsb/daemon/burrow-bsbd.c @@ -205,7 +205,7 @@ static void process_info(time_t t, byte *p, uint len) case 0x0500006b: if (len >= 2) { int err = get_u16_be(p); - mqtt_publish("burrow/heating/error", "%04x %lld", err, (long long) t); + mqtt_publish("burrow/heating/error", "%d %lld", err, (long long) t); } break; case 0x0500006c: