22 April, 2014

Turris - OpenWRT and thermometers


I would like to put here some notes about the thermometers in OpenWrt and Turris.

Turris internal thermometers

Turris has it's own thermometers which are monitoring the temperature of CPU and board. The how-to expects the previous lighttpd configuration described in my previous post. Here is the way how you can create graps wrom the data using RRDtool.




You should be able to see the generated graphs in http://192.168.1.1/myadmin/temperature_sensors in few next days.

Here is the example:


External thermometers

I'm using two external thermometers to monitor temperature around router + in the room. These were build according the following descriptions:
http://www.linuxfocus.org/English/November2003/article315.shtml
http://martybugs.net/electronics/tempsensor/hardware.cgi

I used the serial to usb converter and it's working nicely with Digitemp:
gate / # digitemp_DS9097 -c/etc/digitemp.conf -t0 -q -s/dev/ttyUSB0 -o"%.2C"
28.00
gate / # digitemp_DS9097 -c/etc/digitemp.conf -t1 -q -s/dev/ttyUSB0 -o"%.2C"
20.63

The scripts are very similar to previous solution, except getting the data from thermometers. It's happened form time to time, that digitemp returns bad values, so you need to read them few few times.


Graph example:


(you can see the temperature was higher when I turned the PC near the wifi router 16:00 and 00:00)

The scripts created by the steps above can be found in GitHub.

Enjoy...

1 comment:

  1. This comment has been removed by the author.

    ReplyDelete

Note: only a member of this blog may post a comment.