door_nick_lookup_zmq written
[svn42.git] / sensor_graph / sensors.cgi
1 #!/usr/bin/rrdcgi
2 <HTML>
3 <HEAD><TITLE>RealRaum Sensor Data</TITLE></HEAD>
4 <BODY>
5 <H1>RealRaum Sensor Data</H1>
6 <RRD::GOODFOR 30>
7 <P>
8 <RRD::GRAPH ../light0.png
9    --imginfo '<IMG SRC="/%s" WIDTH="%lu" HEIGHT="%lu" >'
10    --color="BACK#d0d0af" --color="CANVAS#ffffff" 
11    --color="SHADEA#dfdfdf" --color="SHADEB#525252" 
12    --color="AXIS#761407" --color="FONT#272727" --color="MGRID#b65447"
13    --color="ARROW#761407" --color="GRID#d0d0af"
14    --title="Room Illumination"
15    --start=now-36h --end=now --width=490
16    --slope-mode --alt-autoscale-max
17    DEF:cel=/home/sensorlight.rrd:light:LAST VDEF:lv=cel,LAST
18    LINE2:cel#04d532:"0 complete darkness via 450 dark to 1023 quite bright," GPRINT:lv:"Current Value\: %1.0lf">
19 </P>
20 Current Light Value: <RRD::INCLUDE /home/sensorlight.txt>
21 <P>
22 <RRD::GRAPH ../temp0.png
23    --imginfo '<IMG SRC="/%s" WIDTH="%lu" HEIGHT="%lu" >'
24    --color="BACK#d0d0af" --color="CANVAS#ffffff" 
25    --color="SHADEA#dfdfdf" --color="SHADEB#525252" 
26    --color="AXIS#761407" --color="FONT#272727" --color="MGRID#b65447"
27    --color="ARROW#761407" --color="GRID#d0d0af"
28    --title="Room Temperature"
29    --start=now-36h --end=now --width=490
30    --slope-mode
31    DEF:cel=/home/sensortemp.rrd:temp:LAST 
32    CDEF:corrcel=cel,6,- VDEF:lv=corrcel,LAST
33    LINE2:corrcel#e21407:"°C (±0.5)," GPRINT:lv:"Current Temperature\: %1.2lf °C">
34 </P>
35 Current Temperature: <RRD::INCLUDE /home/sensortemp.txt> °C
36 <P>
37 <RRD::GRAPH ../movement.png
38   --imginfo '<IMG SRC="/%s" WIDTH="%lu" HEIGHT="%lu" >'
39   --color="BACK#d0d0af" --color="CANVAS#ffffff" 
40   --color="SHADEA#dfdfdf" --color="SHADEB#525252" 
41   --color="AXIS#761407" --color="FONT#272727" --color="MGRID#b65447"
42   --color="ARROW#761407" --color="GRID#d0d0af"
43   --title="Movement Sensor"
44   --start=now-36h --end=now --width=490
45   DEF:cel=/home/sensormovement.rrd:movement:LAST
46   LINE2:cel#1407e2:"Movements / Minute">
47 </P>
48 Page generated: <RRD::TIME::NOW "%Y-%m-%d %H:%M">
49 </BODY>
50 </HTML>