
Today’s home weather stations are cheaper, more powerful, and do more than ever. In my neck of the woods, the weather has certainly evolved over that time frame-“fire season” is now a dreaded annual thing here in California-and one would hope that home weather gadgetry would have evolved in that time span too. Regex "outTemp.*value=\"(-++\.I first ventured into the world of DIY weather forecasting five years ago when I reviewed four home weather stations that let you play armchair meteorologist, teasing out every last detail of your local climate. Using the example above as a template, I started off with a simple config (added to the block above) to grab the indoor and outdoor temperatures: Well, no reason aside from not being familiar with the cURL plugin - yet. The WS-1400-IP weather station has a base unit which makes the live weather data available on a web page, station IP}/livedata.htm - why couldn't I just use the cURL plugin and hit that page? Then I realize - this is the cURL plugin. All calculated live on the Graphite server. That's 9/5, divided by 1000, and offset by 32 degrees. If you're curious, the Graphite target for this conversion from millidegrees C to degrees F would be: It doesn't matter how I log it, just that I do.
Easy weather software for ambient weather ws 1400 ip how to#
At some point I'll discover how to change the data before it gets logged, but if I'm accessing this data in Graphite, I'll be able to use the wonderful Graphite functions (specifically, offset and scale) to convert it into whatever I want. Okay, granted - the 1-wire temperature is being written in millidegrees C, so 23 degrees C logs as "23000". A couple small adjustments, and blammo, I'm logging CPU temperature and room temperature from the 1-wire sensor. I adjusted the file path to the 1Wire sensor, as the writer mentions " 1wire-filesystem", which I don't use, so I just used the normal path to the 1-wire sensor. URL "file:///sys/class/thermal/thermal_zone0/temp" I thought that was just cooler than the Poconos in the middle of February, so I had to go ahead and add the following config: Then I remembered coming across this awesome post a while back where the writer uses the collectd cURL plugin to read both CPU temps and connected 1-Wire sensors. I then used the collectd APCUPSD plugin to grab metrics from the UPS that's connected to the system. Got it up and running, looked good, started logging to the CSV files in my home directory. I started out with just some basic metrics, cpu, df, disk, load, memory, ntpd, ping, and swap. Since I don't have a Graphite server there, I decided I'd just write the metrics to CSV files, so I'd have them, and if I needed, I could import those into my home Graphite server. Well, I took another look at the Raspberry Pi that I have in this remote location, and decided that I wanted to set up a simple collectd to start logging some of the metrics on this system. I've even got a Graphite server running at home with Collectd running on all my systems (except laptops, at the moment) just because it's cool and I'm a metrics nerd. While Graphite is really, really awesome (I have several blog posts I want to do on it) I've been more and more impressed with the flexibility of Collectd. (inside temperature too cold, risk of pipes freezing, etc) This works, and works well, but recently I've been doing a bunch of work with Graphite and Collectd as part of a monitoring system at work. Initially, I was using curl with some bash tomfoolery to get the values, and alert if necessary. I have a DS18B20 1-wire temperature sensor sticking out of the case of the Pi, but I also have it connecting to an Ambient Weather WS-1400-IP weather station, tracking the inside and outside temperatures. I have a Raspberry Pi that I'm using to track temperature inside a house that isn't occupied year-round.
