Live Wind Data Serial to IP

I took the live wind data feed down for a few days while I reconfigured my network and added a serial to IP converter to the system.

I wanted to alleviate having to tie the OSCirrus device to a specific machine and make its data available on the network directly instead of through a serial port. So, I built a serial to ethernet converter that looks like this:

Pasted Graphic 1

It uses a LANtronix XPort Direct which is the lower black and white module with the RJ45 jack into it. This module is sweet because it encapsulates a full TCP/IP stack and has serial pins you can use to feed data into and out of it with a microcontroller.

Once it's on the network, you can connect to the device through a socket, 10001, and start receiving what's coming into it on the serial port. Here's what the configuration looks like in my wiring closet where I keep the OSCirrus device (and all my networking gear.)

Pasted Graphic

The top plexiglass base and yellow CAT5 cable is the wind sensor data lines coming into the cable breakout board and OSCirrus device. The bottom plexiglass base holds the serial to TCP/IP converter and you can see a homebrewed serial cable running between the OSCirrus output and the serial to IP converter board. The bottom yellow CAT5 cable is an ethernet connection to my Netgear switch and the rest of my network.

I then wrote some Ruby code that takes the place of the Groovy code I wrote to read the serial port directly and translate it to an XML data feed. The Ruby code is a socket client that connects to the XPort socket and sucks the OScirrus data and translates it to the same feed format that the Groovy code did. It drops the XML file in the same location so the Live weather flash client is none the wiser.

I'll post the Ruby code to the downloads section of the site shortly (after I test it out for a little bit.)