Page 1 of 1

Re: Weather Pi

Posted: Tue May 08, 2012 8:01 pm
by spennig
I'm delighted to announce that my 1 wire weather station http://www.daria.co.uk/wx/ is currently running on a Raspberry Pi. Or, at least the data acquisition side of it is … the storage database (mongodb) and web generation remains handled by a mini-itx box.

The 1-wire data network uses a USB interface, which the Pi handles just fine.



The blue blob to the left is the DS9490R USB 1-wire adapter. I appreciate this is cheating and no where near as cool as hacking the GPIO.

Re: Weather Pi

Posted: Wed May 09, 2012 9:24 pm
by morphy_richards
George James Symons would be proud! I"d love to see a picture of your actual weather measuring equipment too... And that little blue 1 wire thing , I"ve never come across such a thing. What is it?

Re: Weather Pi

Posted: Thu May 10, 2012 1:09 am
by error404
Nice work! I like your web frontend, what are you using for generating the charts?

Re: Weather Pi

Posted: Sun May 13, 2012 6:00 am
by Cool.Majkl
That's awesome man ! Would you make some tutorial ? Do you think, that it would be possible to connect those sensors wirelessly ?

Re: Weather Pi

Posted: Sun May 13, 2012 6:57 am
by spennig
To answer the questions:

The blue blob is the USB to 1-wire adapter. It converts the Dallas-Maxim 1 wire protocol that the weather sensors use into a USB interface. There are some (old) images of the actual weather measuring equipment at http://www.daria.co.uk/wx/tech.html.

The charts are generated by ploticus http://ploticus.sourceforge.net/doc/welcome.html. This takes place on the Mini-ITX box.

It is not possible to connect the weather sensors I use wirelessly (the connection technology is '1-wire'; the wire part is not optional). There's more info at http://www.daria.co.uk/wx/tech.html, and I will do a tutorial some time, specifically addressing the RPi part.

Re: Weather Pi

Posted: Sun May 13, 2012 7:28 am
by Jancis
could graph generation be done by raspi too? i have nginx running for serving static content on mine and it performs VERY well.

Re: Weather Pi

Posted: Sun May 13, 2012 7:58 am
by jamesh
I imagine you could easily use GNUPLOT to generate graphs on the Pi and serve them over a web interface.

Re: Weather Pi

Posted: Sun May 13, 2012 5:41 pm
by Fede
great project! I'll wait the Tutorial!
I'm curious, can I extend the lenght of the wire until 60 meters?
Thanks in advance,
Fede

Re: Weather Pi

Posted: Sun May 13, 2012 7:08 pm
by error404
Ploticus looks pretty nice. Thanks. Should run on the Pi too if you wanted to.

With some effort you could go wireless by adding a serial->1wire bridge like the DS2480 and a pair of those cheap 433MHz wireless UART modules.

Re: Weather Pi

Posted: Sun May 13, 2012 7:42 pm
by spennig
Yes, you probably could <http://www.maxim-ic.com/app-notes/index.mvp/id/148>.

And on the subject of generating the graphs / pages on the RPi, the dependencies for my setup (ruby, gems, ploticus etc) are available in the Arch AUR (and for Debian). Generating my particular web pages is quite CPU intensive (it pulls down and processes 1 days worth of 10 sensors, each read every 2 minutes, so c. 7200 records, some of which then need maths to derive the 'user' value), however, the RPi generates the page and graphs (using ploticus) just fine, in about 25s (compared to 2.5s on the mini-itx box it normally runs on) -- a good performance considering the CPU and I/O disparity. lighttpd or nginx would then serve it just fine.

Re: Weather Pi

Posted: Mon May 14, 2012 2:27 am
by peterwit
could you talk more about how you're talking to the 1-wire interface?
I'm looking into using 1-wire with an RPi for my EE senior project and don't really know where to start with it.

Re: Weather Pi

Posted: Mon May 14, 2012 5:42 pm
by spennig
There are a number of options, based on existing Linux software, inter alia:
There are others, but these are (imho), the most useful. Both of these use USB or serial interfaces to the one wire network; bit banging the GPIO would be significantly more difficult, but somewhat more impressive. USB and serial adaptors are available from a number of vendors, such as HobbyBoards http://www.hobby-boards.com/ or HomeChip http://www.homechip.com.

Re: Weather Pi

Posted: Mon May 14, 2012 7:29 pm
by peterwit
thanks for the info. Does your package have the ability to write to devices?
In particular i'm looking at the DS2408 to control a set of relays.
Alternatively do you have any experience with OWFS?
http://owfs.org/index.php?page=owfs

Re: Weather Pi

Posted: Tue May 15, 2012 1:31 pm
by Fede
Hi,
the hobby-boards anemometer uses an anemometer board with this features:
- DS2423 counter for wind speed or general counting purposes.
- DS2438 A/D for wind direction or general A/D purposes.
I saw that the first one w1retap can support it, but no info regarding the second one?
It's still supported or not?
Thanks for the replies..

Re: Weather Pi

Posted: Tue May 15, 2012 4:56 pm
by spennig
peterwit wrote:thanks for the info. Does your package have the ability to write to devices?
In particular i'm looking at the DS2408 to control a set of relays.
Alternatively do you have any experience with OWFS?
http://owfs.org/index.php?page=owfs
I have used OWFS, at the time it didn't have all the features I needed, so I wrote w1retap. For many project it's good solution, particularly if you're writing to devices, rather than just logging.

Re: Weather Pi

Posted: Tue May 15, 2012 4:59 pm
by spennig
Fede wrote:Hi,
the hobby-boards anemometer uses an anemometer board with this features:
- DS2423 counter for wind speed or general counting purposes.
- DS2438 A/D for wind direction or general A/D purposes.
I saw that the first one w1retap can support it, but no info regarding the second one?
It's still supported or not?
Thanks for the replies..
Currently, w1retap only supports the old wind sensor, not the new hobby boards device (oww supports both). If an owner of the HB wind indicator would like it supported (and is prepared to support remote debugging), then I'll add it. That's how many of the sensors get added, I don't own all of them.

Re: Weather Pi

Posted: Fri May 18, 2012 9:08 am
by Fede
Thank's for the reply.
What about this: viewtopic.php?f=9&t=2812? :?:
What is the minimum interval that can i set with oww/owfs? For example, can i set 1 second interval for the anemometer and 30 sec for the rest of the sensors?

Re: Weather Pi

Posted: Tue May 22, 2012 11:01 am
by nr
I have something very similar - a couple of DS18B20 sensors, and a DS2490 1-wire to USB bridge. The output is run through GD with a bit of perl to produce a graph of the temperature inside, and outside my shed:

http://www.ronketti.org.uk/temp.html

I'm also using net::twitter::lite to generate a tweet whenever I have a cup of tea. There's no good reason at all for this. Which is quite probably why I did it.

Re: Weather Pi

Posted: Tue May 22, 2012 10:43 pm
Weather stuff is fun! I spent the weekend building a weather station - on an arduino, so not that relevant here, however it will be talking to a Pi to upload the data to a remote database in the fullness of time - however I did have a play with the SHT15 temperature sensor directly connected to my Pi:

Image

The LEDs are showing the temperature in binary...

The program is written in BASIC using my wirinngPi library and bit-bangs the data to & from the sensor (it's not quite I2C compatable)

http://unicorn.drogon.net/rtb/sht15.rtb

Gordon

Re: Weather Pi

Posted: Wed May 23, 2012 4:48 pm
by _John
Hi,
as a complete NEWB to this area but as a thing I wanted to try and use the Pi for I would be really greatful if you guys could give me some general pointers where to read on things like this.

(warning the following is probably still in dreamland for me)
but in the longer run it would be great being able to run a Pi off a Solar charger and wirelessly transmitted and served up.

Admittedly that is in the very very long run, it would be great to get started with this kind of thing :D