Sunday: Light Cloud
Monday: Light Cloud
New - Connecting the Pi to a weather station
Following a number of requests I have created below the steps required to connect a Maplin USB Weather Station to a Raspberry Pi using the pywws python software. This latest update now uses python-usb instead of Cython making the settup easier and quicker.
What you need
- A Raspberry Pi with power supply
- Maplin USB Weather Station
- An Ethernet connection
- A wireless ethernet connection with a powered USB hub
I found that a powered hub is not required with a direct ethernet cable to your router, keeping the power usage to a minimum, but you may require one when using a wireless dongle. Plus I had some issues with the wireless connection dropping out, and so reverted back to wired.
The weather sensors communicates to the weather station using radio frequencies, then via USB to the Raspberry Pi. The Raspberry runs a python program called pywws written and maintained by Jim Easterbrook found here. The instructions below explain the changes required in order to run on the Raspberry Pi.
I have had reports that the maplin weather station ID 1941:8021 Dream Link WH1080 Weather Station requires a powered USB hub, otherwise the Raspberry Pi can overheat. This is not the case with the Maplin USB Wireless Touchscreen Weather Forecaster.
Step 1 - Initial Setup
Create an SD card (at least 4GB) with the Raspbian "wheezy" image at http://www.raspberrypi.org/downloads.
I use a Medion 8Gb Class 4 purchased from Aldi. There will be plenty of space on this for many years of data.
Boot the Raspberry Pi with the SD card User pi Password raspberry.
Resize the partition to the full capacity of the card using the raspi-config menu. If it does not start automatically or you are using ssh, type sudo raspi-config at the command prompt.
Change the password to something other than the default.
Set the time zone correctly as an incorrect time will cause problems with synchronising to the weather station later. Make sure your weather station has the correct time as well.
As we won't be using much GPU, set the memory split and change the value to 16.
I usually set ssh to enable so that I can control the Pi from another machine and therefore won't require a monitor on the Pi in future.
Finally exit the menu and update the Pi using the commands:
- sudo apt-get update
- sudo apt-get upgrade
Reboot by typing
- sudo reboot
Step 2 - Installing the software
Install pip and python-dev
- sudo apt-get install python-pip
- sudo apt-get install python-dev
- sudo apt-get install python-usb
Step 3 - Install pywws
Install the latest version of pywws http://pypi.python.org/pypi/pywws/ to the weather directory
- cd ~
- sudo pip install pywws
Step 4 - Testing
Connect the weather station to the Pi with the USB connection.
Test the weatherstation
- sudo python -m pywws.TestWeatherStation
You should see a series of Hex numbers if the connection is working.
Next - Setting up pywws