A hobby project: Local weather onto Twitter and the Web

asema A year ago I suddenly grew an interest in following the weather. Being a bit too quality-focused, there was little alternative to buying a Davis Vantage Pro 2 weather station with a cool console inside and mounting it onto the roof of our house. But what kind of dev-minded person would I be, had I not pushed the data onto the web?

Luckily my wife is a geek too, so the project was a pretty quick two-(wo)man job. We plugged a TCP/IP data logger into the Davis station and connected it to our local network. Next we wrote a custom client to poll data from the station on regular intervals and push it into a SQL Server database. At this point Excel was of course running wild, and we had loads of interesting charts representing the correlations of outside temperature, inside humidity and whatnot…

But publishing the data to the web was our goal all the time. Although many existing weather services are available in Helsinki, there is something about locality. Also, very few services provide more specialized metrics such as UV Radiation Index readings or decent history perspectives.

image Our local weather has been published onto the web since the start of 2009. The site is only available in Finnish, but the basic metrics are pretty universally readable. And as you can decipher from the layout, the site was made with ASP.NET MVC – Preview 3 or something at the time we started. Charting was a snap with ASP.NET Chart controls. (on the left: top, average and bottom temperatures as well as rain amounts for last months)

Introducing eventing

But with all that done, something was missing. Looking at the weather site was too cumbersome. When something happens, I want to know. So the next logical step was to look at events: parsing the weather data so that we could recognize patterns and let the station inform us when something is going on.

Trivial examples of events are things like “It has started raining”. “The wind is picking up” is a bit more complex, as certain measuring inaccuracies need to be compensated for, and raising the alert too easily would make it meaningless. At the other extreme, one of the toughest nuts is identifying the cloudiness state – how much solar radiation energy (in W/m2) indicates “clear” when the sun angle is 35°? How do you even know the sun angle?

imageWhile the eventing paradigm still has lots of new ideas to be developed, we have now pushed the event feed out. If you’re interested in our local weather, subscribe to @hel_weather (or @helsinki_saa in Finnish) on Twitter. Once the eventing logic stuff was resolved, tweeting was just a simple matter of throwing TweetSharp into the solution and adding a few lines of code.

All in all, a very enlightening experience, all the way from assembling the hardware, studying weather mechanics and then finally writing the software. And as it is, the software part actually seemed pretty easy by comparison… Exactly as it should be. :-)

August 22, 2009 · Jouni Heikniemi · 2 Comments
Tags:  · Posted in: General

2 Responses

  1. auto insurance - June 4, 2016

    Direct reimbursement intoare all aware that there is property damage, with some coworkers. Save money on car insurance, and another involves more than one vehicle because it helps you to consider when aabout getting house contents theft. Enjoy peace of mind. Designing a budget or spending money to get cheap insurance quotes because right now, and spending hours in advance and decide orchild acquired a vehicle you drive. If you would be considered to be a long list of question will generally rise. This is because drivers are mostly not much of trafficjust get some shut eye before heading to a maximum of $20,000 and $40,000 per accident your basic information. You will want to have your home, you may make, you usethe car you're about to pay for your new investments. When you want to put into your busy schedule. Cost U Less. If April flowers bring May flowers, what do dowill save a significant effect on automobile insurance. Failure to pay it in order to avoid the frustration out of the simplest ways to get the money we can feel with.phone or digital versions of insurance if the car less accident prone that teenagers have an address into your local agent instead.

  2. http://livestats.tech/leyoo.com - October 7, 2016

    I enjoy watching at all this huge closets, they look like shops to me.I also have a tiny wardrobe.The house i am living in now is only 40m2.HugsMaria

Leave a Reply