Getting weather station data into the emoncms? Anyone got good ideas?

Hi guys!

 

I have been searching for a web based weather station that goes with the emoncms and will measure the following:

  • Windspeed
  • Temperature
  • Humidity
  • Rain
  • Pressure
  • UV index
  • Solar energy
  • Indoor temperature and humidity

I found this unit that suits the needs pretty good:

WH2600 Weatherstation

WH2600

 

 

​It is produced by this chineese company:    Fine Offset

This unit has a weatherstation, and a small unit that collects the data wirelessly and plugs into your router to upload it to the wunderground.com . From the hardware perspective this is all i need.

 

I have found some ways described with scripts, getting the data from wunderground and then posting it into the emoncms every 15 minutes. However i am not so sure this is the best way to get around to it. It sure works but it would be much better if the data posted directly to the emoncms. How can we do that?

This way the user can decide on upload frequency, and also upload the indoor temperature and humidity. (This data does not upload to the wunderground website)

I am open for all ideas about this, and i would be very happy if someone could find a nice solution.

I thought that there might be some way, which might be difficult in first approach but makes it easier later on. And this would grant the community easy access to a affordable weatherstation.

My idea was to try to hack/rewrite the software/firmware in the unit that uploads data, and just make it send the data in the correct format to emoncms. This might also be done through contact with the supplier, maybe they will be interested in allowing us to make an alternative firmware as this can produce more sales for their unit.

Does anyone have another idea? Maybe a man in the middle unit that catches wunderground data, changes the format and sends it to the emoncms? Or maybe a plugin for emoncms that will decode data in wunderground format, and a small rerouting of the wunderground domain in the WiFi router so that it points to emoncms?

This is the URL for wundergrund weather data:

API

 

What i think is needed is a plug and play solution that does not require the user to write or edit scripts, sketches, and stuff like that. Just to input the user ID info and address for the emoncms. I am open for any ideas, and i would be very happy if this was possible! As i am sure others here would love this to!

 

Best regards

//J

Robert Wall's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

I'm fairly certain that Paul Reed imports weather data, and that he's published the method he uses somewhere here (and I think he mentioned 'Wunderground'. I suggest searching here for that and/or 'weather'.

goodfidelity's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

Hello Robert!

 

Thank you kindly for your reply.

I have found and read the solution provided by Paul, but that solution is way to complicated for most users and requires programming skills and setting up your own server. This is way out of reach for most people and takes alot of time.

What i am looking for is a simple and straight forward solution, the most perfect one would be to just send data straight to emoncms like any of the emon nodes. If this would be done by a small hardware man-in-the-middle unit or by altering some small stuff in the firmware of the weather station i dont know, but i am hoping to find a solution that allows anybody to just buy the weatherstation, hook it up, put the user ID or API key and go.

Just as simple as with wonderground.

Best regards

//J

 

Paul Reed's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

I'm afraid there isn't a simple hardware 'man in the middle' hardware solution, and we've found that we need to develop software interfaces to get everything talking the same language (IoT), whether they are cloud based, or local installations.

Paul

pb66's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

Have you seen http://www.weewx.com/ ?

It is compatible with the weather station you selected (among many others) and can report to wunderground and also has emoncms listed in its wiki.

It's all open-source so even if it doesn't do exactly what you are after it can be used as a reference to design a custom interface, by that I mean a tailored universal solution as you describe rather than a per user custom script.

IMO rather than sending direct to emoncms using a standalone software, the "custom script" could be a emonhub interfacer so that it is part of an existing software and data can be posted to multiple places. I had already written a wunderground interfacer that retrieved weather data from wunderground if you have an api account, this provided a pure software "cloud based" weather solution. the recommended interval for that was 3mins due to the api constraints.

Paul

EDIT - @Paul, there should be no need for additional hardware with this station, it interconnects using 868MHz and then forwards using Ethernet, I haven't looked closely at it but I suspect weewx just intercepts, parses and forwards using http and/or rest api etc. once captured the data can be packaged in any form, even mqtt :-)

goodfidelity's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

Hi Guys!

 

Thanks for input!

To be honest i don't understand half of what is written as i don't know so much about programming, but it sounds good =)

But the product mentioned earlier in the first post is already actually all the hardware needed. It just does not speak the right language for emoncms.

The perfect thing would be a feature in the product itself that allows the user to specify any server address and define the posting method for sending the data. The product would then do everything itself, just as it does today but to emoncms AND wounderground.com website.

Since the unit already communicates with wunderground, and that is a public API. What is needed is something in between that will listen to that and just translate to the API of the emoncms and relay it.

It is very important to have all the data in one database, because from analysis point of view sometimes you would like to do calculations from energy data combined with weather data. So it is not just a matter of displaying the weather data on a webpage, but actually having the server (emoncms) making calculations based on weather data and energy data. For example E/T diagrams and such.

As i see it this solution could be a raspberry with double network ports, that just picks up the weatherstation in one end, and posts the data untouched to wunderground.com, and relays reformatted data to emoncms. Maybe its possible to add a software feature to the raspberry emon base station, and add a USB ethernet dongle? And plug the weatherstation into the raspberry instead of the router.

This would practically be a EmonWeather base emulator inside the raspberry.. Instead of a EmonV3 or EmonTH. But it takes data from the USB Ethernet instead of the RMB12 chip.

I run emoncms on the public webserver. I dont have my own server. Most people like it this way because ordinary users cant setup or maintain their own server. This also limits the options on the server side, with less options for software modifications to server software.

Will it be a difficult thing do do this in the raspberry?

Thanks for all the input, and best regards

//J

goodfidelity's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

pb66, that weewx looks very interesting!

I am pretty sure this can be something that openenergymonitor can use. They also listed a one wire weatherstation, and some other cool stuff. But still it cant be used by anyone who lacks programming skills.

I still haven fully understood the concept of weewx, but it looks alittle bit like what i think it would look like to have the weatherstation data pass trough the emonPi (raspberry) on its way out to the wunderground and emoncms. I downloaded the app for OSX but it does not have a GUI or even a executable file so it seems this is one of the solutions that require more enthusiasm then the average user has.

This is the page in the Wiki:

weewex

This solution still involves tinkering in terminal, configuration files and such. I think what is needed is a plug and play device. Just like the WH2600 or WS1400IP but that uploads directly to emoncms instead of wunderground.

In those weather stations, all you have to put is the account ID for wunderground and then you are set to go. Its really nice.

//J

 

 

 

goodfidelity's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

"I had already written a wunderground interfacer that retrieved weather data from wunderground if you have an api account, this provided a pure software "cloud based" weather solution. the recommended interval for that was 3mins due to the api constraints."

 

This sounds interesting, would that make it possible to just put the user ID for a wunderground account into emoncms and have all the weather data from that account loaded onto the emoncms?

That could be really something, or even better alternative would be a emoncms extension that allows you to put the ID of the weather station, and that it will act just like a node in the emoncms. This way people will only need to be in close proximity to some other weatherstation.

In the end, what i am talking about is the need for this to be a simple solution that only requires very simple interaction from the user. And it would be amazing if it would work directly with the weather station, even if i understand this will require more work on the software side.

 

//J

GJPickard's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

I have managed to get a Fine Offset 1080 (Maplin N96GY) weather station posting to Emoncms via a node that grabs the weather station data and then resends as a standard emoncms compatible signal

http://openenergymonitor.org/emon/node/3907

If you hunt around I suspect someone has already decoded your w/s signal using an arduino and transceiver.  Your issue will be if your w/s transmits at a different frequency to your emoncms network - you will need to try and get 2 transmitters running on the one arduino.

I gave up on using batteries for my receiver as they only lasted a month or so and now use a small 5v usb charger I had lying around

Best of luck on the project - I am no coder either so don't give up - the benefit of arduino is that it is very hard to kill so experiment away!

Gary

goodfidelity's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

This is just a small update to what happened.

 

I purchased this weather station from Conrad, WH2600

 

It was luckily so that the firmware that ships with the weather station allows for input of any server address you wish. And then your emoncms server can be used to logg weather data if it only accepts this kind of input:

http://wiki.wunderground.com/index.php/PWS_-_Upload_Protocol

So then a guy who is really good in programming made a small and simple code to put on the emoncms server that allows the server to receive the input signal from the weather station. It's not fully tested yet due to my own mistake.

By putting the API key in the USER ID field for wunderground account, and then putting the normal wunderground user data in the PASSWORD field in the setup of the weather station, it now logs to wunderground and emoncms. When we have finished testing it out ;) The emoncms server now relays all the data to wunderground so that no functionality of the weather station is lost.

When working with this i discovered that the USER ID field has not enough character space to fit the whole API key, and it seems the US upgrade for the firmware had a solution to this. However the US version was wunderground only solution, and they had removed the possibility to input any server address you like.. And now i was stuck with a firmware that does not work as intended. I have to solve this and i am now trying to make conrad send me the original firmware so that i can downgrade back to where i was.

This solution gives everything i ever wanted.

- Easy setup that anyone can understand

- Full usage of wunderground service AND emoncms logging

- A small and simple script that should be embedded into the emoncms server if they decide to add weather station support.

 

The image attached shows the setup of the weather station.

 

Peter Galbavy's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

The station itself is made by Fine Offset. They do eventually respond to e-mail enquiries; http://www.foshk.com/dv/Quality.html

I have the Maplin rebadged version of the HP1000 and I like what you are doing - so I'll try it too. Can you share more details of the proxy on the emonpi and what you are doing with the data as such?

goodfidelity's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

Hi Peter!

I tried sending them email, they answer initial email and then it is quiet. I think that they do not want people to use the station with any other service then wunderground, probably because they make money from cooperation with them.

The firmware version 1.1 is loaded on units sold by conrad. But it cant be downloaded anywhere. I am looking for a way to obtain this firmware from the unit itself. But i don't have a clue about how to do that.

Todays solution is really simple, we can just put the emoncms server address in the setup of the weather station, and the station will post straight into emoncms. (if the script is used)

Instead of wunderground ID you just put the API key and its good to go.

This feature is also multi user supportive and can be used on the server for many users.

 

I dont know how to use the script locally on the emonPi, but guess that it can be dont with static IPs and just sending the data from the WH2600 into the local emonPi IP address.

 

Anyhow, this is really cool and we need more research on this. If this can be done in a nice user friendly way it will be very nice for openenergymonitor to have its own weather station.

 

//J

goodfidelity's picture

Re: Getting weather station data into the emoncms? Anyone got good ideas?

I dont know enough about this stuff to figure this out, but seems you can get all the data from this station direct into your Pi, if you follow this URL there is some explaning.

 

http://www.wxforum.net/index.php?topic=25679.0

 

Might be something if you want to catch the data locally.

 

//J

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.