From: Martin Mares Date: Sat, 26 Jan 2013 18:00:05 +0000 (+0100) Subject: Home: Switched sensors X-Git-Tag: v1.6~9 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=ab67ccef6257c019d751b9055c30549abaa7568c;p=arexx.git Home: Switched sensors --- diff --git a/arexxd.c b/arexxd.c index a84d9ff..52cb17c 100644 --- a/arexxd.c +++ b/arexxd.c @@ -33,7 +33,7 @@ */ #define MAX_PAST_TIME 30*86400 #define MAX_FUTURE_TIME 300 -#undef IGNORE_UNKNOWN_SENSORS +#define IGNORE_UNKNOWN_SENSORS typedef unsigned char byte; static libusb_context *usb_ctxt; @@ -190,6 +190,9 @@ static double correct_point(int id, double val, const char **name) case 10707: *name = "balcony"; return val - 0.71; + case 11699: + *name = "outside"; + return val; case 19246: *name = "catarium"; return val + 0.49; @@ -197,7 +200,7 @@ static double correct_point(int id, double val, const char **name) *name = "catarium-rh"; return val; case 12133: - *name = "outside"; + *name = "aquarium"; return val + 0.44; default: #ifdef IGNORE_UNKNOWN_SENSORS diff --git a/web/temp-12h.cgi b/web/temp-12h.cgi index 3e82db6..4ea9dc2 100755 --- a/web/temp-12h.cgi +++ b/web/temp-12h.cgi @@ -16,6 +16,7 @@ exec rrdtool graph - \ DEF:u=$D/sensor-ursarium.rrd:temp:AVERAGE \ DEF:b=$D/sensor-balcony.rrd:temp:AVERAGE \ DEF:o=$D/sensor-outside.rrd:temp:AVERAGE \ + DEF:t=$D/sensor-aquarium.rrd:temp:AVERAGE \ 'AREA:c#cc7777' \ 'AREA:u#7777cc' \ 'AREA:b#cc77cc' \ @@ -23,5 +24,6 @@ exec rrdtool graph - \ 'LINE2:c#cc0000:Catarium\n' \ 'LINE2:u#0000cc:Ursarium\n' \ 'LINE2:b#cc00cc:Balcony\n' \ - 'LINE2:o#00cc00:Outside' \ + 'LINE2:o#00cc00:Outside\n' \ + 'LINE2:t#00cccc:Aquarium' \ 'HRULE:0#0000ff'