How's The Weather?


One of the items on the Geek Ranch agenda is a weather station. While we don't have one yet, we have learned a bit about weather stations and Linux.

First, why don't we have one? Well, there is no electricity at the Geek Ranch site yet for starters. But, more important, there is no Internet connection. So, let's just call this research.

I started my search for weather stations a few months ago. The criteria was simple:

  • Reliable
  • Inexpensive
  • Works with Linux

The result was that I bought two different systems. The first is a La Crosse Technology, WS-2310TWC. The TWC in the model number means that it says "The Weather Channel" on it. I don't plan to use it with The Weather Channel but I paid $10 less to have that info on the box.

While it was the most inexpensive unit I found with a computer interface, I don't give it any awards for the "Works with Linux" test and, based on my experience with a different La Crosse model, I am not sure about the reliability. Talking to the La Cross tech support folks, they said there was no Linux software and they would not release the communications specifications.

A bit of searching and I found Open2300, software designed to talk to the 23xx series of weather stations. Clearly it is a bit of reverse engineering and, based on what I read, I understand why they don't want to release the specifications. The unit appears to be a 4-bit processor (can you still get those) with no API. That is, you just can read and write memory. Yuck.

The good news is that the software includes a Weather Underground interface routine. It doesn't work and I don't want to figure out why but it is there.

On the reliability issue, my previous La Crosse unit which didn't have a computer interface recently self-destructed. The wind speed and direction unit all but disintegrated after about two years in service. The good news is that the new unit has a totally different design that appears a bit sturdier.

Before I get into getting the 2300 to work, let me talk about what I really will use at the Geek Ranch. It is an Oregon Scientific WMR968. The one I have happens to be dark green and say "John Deere" on it. Much like The Weather Channel model of the other unit, I saved about $10 because of this ad. Whatever.

Both units are called wireless and communicate to the base station on 433MHz. The difference is that on the La Crosse unit wireless means that there are wires that run from the wind and rain sensors back to the outside temperature sensor which then wirelessly communicates with the base unit. With the Oregon Scientific, all the sensors, including the indoor temperature unit, are independent. All except the indoor temperature unit are solar powered.

Before you say "I need sun for the solar cells but I don't want the outside temperature sensor in the sun", don't panic. The sensors connect with cables to their own solar panel/transmitter unit. Clearly an easy to work with design. Comparing the two, I am glad I splurged for the extra money for the "real one".

Ok, back to getting the 2310 into operation. It boils down to the following:

  1. Download the software
  2. Modify the make file. (There is no configure script but the default setup is for Linux. I didn't have to make any changes.)
  3. Do a make install.
  4. Plug the cable from the base unit into a serial port and make sure you have read/write permission on the port.
  5. Run fetch2300 and you should see the info read from the unit.

If all went well, you are now up and running. In my case, all that worked fine so I decided to put myself on the map. That is, put Estelí, Nicaragua up on Weather Underground. (Note that the page you see there combines this weather station with some "airport" information. The airport actually shares little in common with Estelí as it is over 100km away and at a much different altitude. Clicking on the historical data link gets you the real information.)

To put the data up, all I had to do was log into Weather Underground and add the details of the station. That got me the station ID which is IESTELIE2.

That station ID and my password can then be added to the open2300.conf and then running wu2300 will poll the weather station and upload the information to Weather Underground. Easy. Unfortunately, it didn't work. No complaints but WU never got the data.

The next step was to turn on debugging. Setting DEBUG to non-zero in wu2300.c causes the program to echo the http request to standard output rather than send it. It looked just fine. I pasted it into a browser and got success back plus the page got updated.

After scratching my head a bit and realizing it was 3AM, I did what any real geek would do—glued the pieces together with a shell script. Here is the "quick hack" version.

./wu2300 > $data
wget -i $data
rm $data updateweatherstation.php*

It just grabs the http request and sends it using wget. I then added a crontab entry to run the script and all is well. Ok, all works and I will clean up the mess someday. In the mean time, you can see that my weather here is better than your weather. Ok, maybe someone has better weather some of the year but I am guessing most people would prefer my weather to their weather most of the time.


Phil Hughes


Comment viewing options

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

new file engine search

Anonymous's picture

Tired of the links in favorites for downloading? Visit and find the straight link to the file required.

Weather back to normal

Phil Hughes's picture

For those who looked at the weather reports and just thought it was always too hot here, we are back to normal. We felt the same--it was too hot for over a month. But, things are looking up now. Now we just have to go up to the Geek Ranch and see if the rain damaged the not yet completed road work.

Phil Hughes

Lacrosse weather station

dfranz's picture

I have a Lacrosse 2310 weather station and have it sending data to the
Weather Underground. I got the software from the Subversion repository
to work--mostly. My problem is that after some time, varies in length, the Lacrosse
unit causes the open2300 software to report "Unable to reset". This happens
even with a query interval of about 2-4 minutes. Once that happens, the
software stops sending data to the Weather Underground:( When I have
time, I will work something out so that the software gets killed and
restarted if the "Unable to reset" message shows up.

Does that happen with your "quick and dirty" solution?

Yes the unit is rather limited in its capabilities, but then I got
mine for free, as a Christmas gift.


Not yet

Phil Hughes's picture

It has been running fine now with updates every 15 minutes. The only "problem" I have is that we are still in "April weather". April is the one month that is too hot in Estelí. And, well, it still is. I think the weather is "running about 20 days late" this year as the first 2/3 of April were relatively nice.

For anyone concerned, the Geek Ranch is at a higher altitude. Where there is still no connectivity (and I have been in the office and not there for two weeks), I am sure it is still nice weather up there.

Phil Hughes

Don't support those who refuse to publish specifications

Z1's picture

Why not buy a product that releases specifications so you can develop your own software, rather than having to resort to a reverse engineered product?

I would recommend Davis Vantage Pro. I've had mine for 4 years and it has worked flawlessly. Davis don't provide Linux software, but they do publish full specifications of the protocol and several people, including myself, have implemented Linux versions.

I would also doubt the accuracy of many of these cheaper products (toys?), which is why I could not recommended anything other than Davis Instruments for anyone wanting reliability, accuracy and good support at a very reasonable price.

+1 on Davis

Anonymous's picture

I'm also using a Davis Vantage Pro with Linux. I've written a small daemon in C that collects the data and periodically fires off secondary processing (like web page generation and Weather Underground upload).

The only thing I've had to do with my system in the 2.5 years since I installed it is replace the backup battery in the sensor package and occasionally clean the leaves out of the rain collector.

I had one small glitch with one of my consoles when I initially set them up, but when I called Davis, the phone was answered by a human who actually dealt with my problem (!).

Davis weather
My weather data

BTW, the daemon is written so that it's relatively easy to add support for other weather stations (I did just that for the weather sensors at work). If anyone is interested in the code, contact me via the Weather Underground.


Jeff Shantz's picture

The link to Lacrosse Technology is misspelled. It should be

Correct url

the1_ts's picture

Hey, great article I've been looking at doing this for a while. Can you correct the url for Lacrosse Technology



Andrew's picture

I've had an Oregon WMR-968 for some time now, and connected it to a small (8Mb RAM, 32Mb Flash disk) Linux embedded box using the WX200d software which has worked well for me. However my little Linux system is way too small to run the (python?) scripts that the wx200d software provides to upload data to Weather Underground, although the wx200d daemon that actually connects to the serial port is written in C and is small and extremely reliable.

I wrote my own data uploader that queries the wx200d daemon every 30 seconds and spawns a wget-clone program to upload the data. Note that the wget process can freeze if your network connection goes down, so the parent also needs to time out and kill the wget process if it takes too long to run. Initially this was coded as a couple of shell scripts, but more recently I converted it all to C which has been more reliable.

One other feature I included in the uploader was to calculate the actual dewpoint temperature myself from the %RH and the air temperature — if the dewpoint goes below freezing, the WMR-968 returns an error value. My uploaded data is found here.