I used to have my WS2300 located right next to a small, dedicated server running Windows XP. Connecting the weather station to the server, and the server to my home network, was easy because the boxes were all very close to one another. Using Open2300 to update my Weather Underground account was easy! Then I moved. In my new house, the WS2300 console is in the bedroom and the Internet connection is 50 feet away in the study. Running a long cable was not an option. Further complicating matters, my Windows server had a small fan in it and I didn't want to listen to the whir of the fan while trying to fall asleep every night. Thus, I set about looking for another solution. I bought a
Kurobox, but it also had a small fan, plus I couldn't get my USB-to-serial converter to work with it. But reading the Kurobox forums led me to the
Linksys NSLU2. The NSLU2 is designed to allow you to connect USB disk drives to a network, giving you a simple and cheap NAS (network attached storage) solution. The NSLU2 runs Linux and an extensive user community supports upgrading the NSLU2 to run a wide variety of Linux-based software. And it is silent (no fan)!
I am not the first person to run Open2300 on an NSLU2 - just Google "open2300 nslu2" and you will see a couple of examples. However, I've been so pleased with the result that I thought the process of configuring the NSLU2 to run Open2300 should be documented.
The NSLU2 comes with an ethernet port and 2 USB ports. Once you've purchased an NSLU2 (I got mine on eBay), you'll need to make two important decisions:
- How will you connect the NSLU2 to the Internet? I used a wireless bridge, but there are many options here -- direct ethernet cable (if you have an ethernet port nearby), ethernet over AC, etc.
- How will you connect the NSLU2 to your WS2300? If you are experienced with a soldering iron, there is an internal serial port you can hook into. Otherwise I would recommend a USB to serial converter. With a converter, you need to make sure you pick one that is supported by the Linux version on the NSLU2. Read the details here.
Here is the configuration I ended up using:
+--------+ +---------+ +---------+ +---------+ +----------+ | | | IOGear | | Linksys | | Linksys | | Wireless | | WS2300 | -> | GUC232A | -> | NSLU2 | -> | WET11 | ~~~~ | Router | -> Internet | | | USB-Ser | | | | Bridge | WiFi | | +--------+ +---------+ +---------+ +---------+ +----------+
The WS2300, USB-to-serial converter, NSLU2, and WET11 are all placed near my nightstand, with the NSLU2 able to connect wirelessly to the Internet. In order to extend the software on the NSLU2, you will also need to attach either a USB disk drive or a USB flash drive. I used a 512MB USB flash drive (I would not recommend using anything smaller than this).
The NSLU2 Linux community is located at
www.nslu2-linux.org. Getting the NSLU2 configured correctly is not simple -- it took me just over a day of off and on fiddling (I have extensive experience configuring Windows, but limited experience with Linux). Hopefully, with these instructions, it will go a little faster for you.
Configuration Steps
- Follow the instructions for installing the latest "Unslung" Linux version onto the NSLU2. I used the latest version of Unslung, which at the time was 6.8. Note that the first steps involve configuring the NSLU2 using the Linksys utility that came with the unit -- you don't reflash the NSLU2 until after the IP address, gateway address, and DNS address have been set. I had some problems trying to use a dynamic IP address, so I ended up sticking with a static IP. The last steps involved "unslinging" Linux onto the external flash (or hard disk) drive. I used a 512MB flash drive on port 2.
- If you can telnet into the NSLU2, you are at least half-way there! I thought I might need a 3rd party telnet package, but in the end, the one built into Windows XP worked just fine (just type "telnet" followed by the ip address at the command prompt).
- Install some packages (after you have run "ipkg update". I installed:
- coreutils
- make
- crosstool-native (the gnu c++ compiler)
- nano (a text editor)
- If you are using a USB-to-serial converter, this is a good time to check it out. Follow the instructions here. For my GUC232A, I had to follow the additional "Special Note about the kernel-module-pl2303" instructions too.
- I created "/etc/profile" with the following content. This step does two important things: it adds /opt/bin to the path (this is where the package executables get installed), and it sets TERM which allows nano to run.
export PATH=/opt/local/bin:/opt/bin:/sbin:/bin:/usr/sbin:/usr/bin:/opt/sbin:/opt/usr/bin:/opt/usr/sbin export LD_LIBRARY_PATH=/opt/lib export TERMINFO=/opt/share/terminfo alias ls='ls -F' export TERM=vt100
- Now to get Open2300!
cd / wget http://prdownloads.sourceforge.net/open2300/open2300-1.10.tar.gz gunzip open2300-1.10.tar.gz tar -x -f open2300-1.10.tar cd open2300-1.10 make cp *2300 /opt/bin cp open2300-dist.conf /etc/open2300.conf
- Edit open2300.conf. If you are using a USB-to-serial converter, then SERIAL_DEVICE should be set to "/dev/ttyUSB0" (you can verify this using the dmesg command).
cd /etc nano open2300.conf
- With all of the cables connected, you should now be able to run "fetch2300", or most of the other open2300 utilities (with the exception of mysql2300).
-- Matt Brown, 14 Jul 2007
* Excellent writeup. there is a small thing that needs to be changed in step 6. Just AFTER make, one should edit the Makefile and change line 15 to prefix = /opt . Then type make install. the cp *2300 /opt/bin command is not needed. (it copies not only the binaries but a lot of other unwanted stuff).
Also one can easily add a mysql database to the NSLU with ipkg mysql. see
http://www.nslu2-linux.org/wiki/Optware/MySQL.
Iraklis M.
For loading your weather data to Weather Underground:
1. There is a bug in wu2300 version 1.10 that will keep your data from successfully loading to weather underground. You can either use version 1.11, or patch 1.10 as shown on
this page. Just change the sources and start again from step 6 from the line where it says "make".
2. wu2300 is the program that loads your weather data to Weather Underground. It only loads your current data and closes. In order to update your data every x minutes to Weather Underground, edit /etc/crontab. At the end of crontab, add
*/5 * * * * root /opt/bin/wu2300
This will run wu2300 every 5 minutes.
Erik B.