Monday, May 16, 2011

Elmo is Born

There has been a great deal of work over the past week. This has mostly been concerned with the network comms side of things. Because I decided to run an XML based protocol I needed to implement some support code to drive it all. The result is rather pleasing in its functionality and simplicity.

Having got the basic comms up and running, I then wanted to be able to query the Elmo server for the available devices and commands, so a Catalogue was needed to keep track of this information and the appropriate XML formats designed.

I wrote the client in Windows (using MFC - that takes me back) and integrated my previous socket client into the new program. I then added my socket server to the server side and was able to get command catalogue information passed between the two machines. I also got a cross-compiled Windows-based test server so I could continue to develop away from home.

Come the weekend it was time to link this up to the IR side of things. That took a few hours on Saturday, so on Sunday the big moment of truth. I set all the test kit up in the lounge, ran up the client on the laptop and tried to send some commands. It didn't work.

After lots of investigation and fiddling around, everything looked correct but the signals weren't being transmitted. Eventually I realised that the new server program had the wrong version of the IR Protocol library. Correcting this brought Elmo to life - finally.

The system now accepts button presses for various remote control functions on the laptop, passes them over the wireless network to the server where they are converted to the appropriate infrared signals and transmitted from the dongle. It sounds quite simple, but represents rather a lot of work, both investigating, prototyping and developing code.

There are still some limitations to the IR codes I can learn, but I intend to push on with the development now and start work on the iOS client program that will allow control from the iPhone.

No comments:

Post a Comment