My previous assessment of interfacing directly to the IR device was, surprisingly, confirmed this weekend.
Due to the glorious weather this weekend, I didn't have a great deal of time, but I managed to take the basic code I'd written in the week, port it onto the Linux box and successfully transmit codes to the Sky box (the digit 1). Having done that, with some more work I managed to capture IR from the remote control and confirm the numbers I was capturing matched those I'd previously sent. The trickiest part was getting all the data in the correct format since it doesn't seem to be consistent for different messages.
The upshot of all this is that Elmo can now capture IR signals from a remote control and regurgitate them to control devices (so far, only the Sky box). LIRC, the bane of my life, has been abandoned and I'm communicating directly with the IR device driver via a pipe. Initial indications are that the codes captured are very consistent.
I've taken the time to capture codes from 4 different remotes so I can work out the best way to analyse and store the codes - which is the task for this week whilst I'm away from home. If I can get a reasonable mechanism to do this then the most difficult part should be over. It's taken a very long time to get this far!
Next step: Analyse the captured remote codes and decide on the best way to record and store them. Write some code to support this, ready for porting to Linux at the weekend.
Monday, April 11, 2011
Wednesday, April 6, 2011
Signs of life
I managed to find some time on Monday to look through the IR dongle utilities code. To my surprise, using the device seems to be reasonably straightforward (a first on this project). There are a number of utility functions which can be reused to drive the basic protocol which just leaves the higher, packet, level to drive.
I was lucky enough to grab some time yesterday and quickly put together a program using the utility code to open a connection and read some data from the dongle. It worked! Knowing this, I can now work on some basic learning functionality so I can program up the remote controls I have. My plan is to keep this fairly simple for now and refine it later. The focus is to be able to issue individual commands to multiple individual devices. I already have a demonstration of the networking ability, so that can be put to one side for now.
Right now it feels like the project once again has a future, but this will be tempered by the reliability I manage to get from the learned codes. I fear there may still be a way to go yet.
I was lucky enough to grab some time yesterday and quickly put together a program using the utility code to open a connection and read some data from the dongle. It worked! Knowing this, I can now work on some basic learning functionality so I can program up the remote controls I have. My plan is to keep this fairly simple for now and refine it later. The focus is to be able to issue individual commands to multiple individual devices. I already have a demonstration of the networking ability, so that can be put to one side for now.
Right now it feels like the project once again has a future, but this will be tempered by the reliability I manage to get from the learned codes. I fear there may still be a way to go yet.
Monday, April 4, 2011
Wonders of USB
My previous idea of using third-party IR codes was all very well until I found that the majority of remote controls I have do not seem to have files available on the net. So, I'm back to having to capture my own IR.
During my usual weekend frenzy of work on the project, I discovered the problem with capturing IR was that, once again, LIRC has been using the internal IR receiver rather than the external dongle I want it to use. I finally managed to disable the internal device by blacklisting the driver but now LIRC doesn't want to work at all!
I think there is a problem within the system because both the interal and external receiver use USB, but I cannot confirm this. Anyhow, I then decided to revert to using the tools supplied by the dongle manufacturer and finally had some success! I've managed to record some IR and retransmit it, successfully controlling the satellite box!
The process is currently rather tedious and manual - requiring copying dats from one tool into another, but I've downloaded the source code and am hoping to find the interfaces I need to access the interfaces programmatically. Hopefully this will then allow me to reliably record and retransmit IR signals. I'm quite excited by the prospect but I've thought I was at this point before and it all came to naught. The good thing is that I can examine the source during the week when I'm away from home.
During my usual weekend frenzy of work on the project, I discovered the problem with capturing IR was that, once again, LIRC has been using the internal IR receiver rather than the external dongle I want it to use. I finally managed to disable the internal device by blacklisting the driver but now LIRC doesn't want to work at all!
I think there is a problem within the system because both the interal and external receiver use USB, but I cannot confirm this. Anyhow, I then decided to revert to using the tools supplied by the dongle manufacturer and finally had some success! I've managed to record some IR and retransmit it, successfully controlling the satellite box!
The process is currently rather tedious and manual - requiring copying dats from one tool into another, but I've downloaded the source code and am hoping to find the interfaces I need to access the interfaces programmatically. Hopefully this will then allow me to reliably record and retransmit IR signals. I'm quite excited by the prospect but I've thought I was at this point before and it all came to naught. The good thing is that I can examine the source during the week when I'm away from home.
Monday, March 28, 2011
Light dawns
After a slight change of tactic over the weekend, there has been some success with Elmo.
I decided to set aside the issue of decoding the infrared signals and switch to a set of IR codes produced by a third party. This led to some moderate success in controlling my satellite reciever. With a number of tweaks and tricks I was able to get moderate reliability of reception from the satellite box. I then went in search of some alternate codes and found a set which works very well with the box. The new set are actually decoded fully, rather than relying on the raw codes that the other file used - this looks like the way to go.
I then married my previous work with a socket server together with my infrared code and got to a point where I could issue commands on one machine and get the Linux box to send the appropriate IR codes. This is essential for the final solution since I don't want a display plugged into the Linux box.
I've not been able to find files for my other equipment so I'm back to trying to decode the IR signals in order to create my own config file. I'm hoping that the example file I already have will help in this process.
It's a good step forward, though, and has illustrated that the whole idea looks practical and achievable.
I decided to set aside the issue of decoding the infrared signals and switch to a set of IR codes produced by a third party. This led to some moderate success in controlling my satellite reciever. With a number of tweaks and tricks I was able to get moderate reliability of reception from the satellite box. I then went in search of some alternate codes and found a set which works very well with the box. The new set are actually decoded fully, rather than relying on the raw codes that the other file used - this looks like the way to go.
I then married my previous work with a socket server together with my infrared code and got to a point where I could issue commands on one machine and get the Linux box to send the appropriate IR codes. This is essential for the final solution since I don't want a display plugged into the Linux box.
I've not been able to find files for my other equipment so I'm back to trying to decode the IR signals in order to create my own config file. I'm hoping that the example file I already have will help in this process.
It's a good step forward, though, and has illustrated that the whole idea looks practical and achievable.
Monday, March 21, 2011
Close, but no cigar
A weekend of frenzied Elmoness has seen progress on both receiving and sending IR signals. My test programs can now do both, the only problem being that the two aren't compatible - codes recorded don't activate the equipment as expected. When I use the numbers captured by the real LIRC programs, everything is fine. Although frustrating, this means that the basic mechanisms are there, I'm just missing something on the reception side. I'm wondering about the sample frequency of the receiver (and transmitter).
My receive and record program can get consistent results and distinguish different buttons on the remote which is better than I've managed before. Transmit is cheating by using a program provided by the IR transceiver manufacturer.
If I can get the reception calibrated in line with transmission, the learning process I've come up with will work much better than the LIRC default one, which is rather long-winded. I'm hoping this doesn't prove too difficult, but only time will tell.
My receive and record program can get consistent results and distinguish different buttons on the remote which is better than I've managed before. Transmit is cheating by using a program provided by the IR transceiver manufacturer.
If I can get the reception calibrated in line with transmission, the learning process I've come up with will work much better than the LIRC default one, which is rather long-winded. I'm hoping this doesn't prove too difficult, but only time will tell.
Wednesday, March 16, 2011
Hiatus
Elmo has been in hibernation for over a year now due to other commitments and loss of momentum. However the purchase of some new equipment has prompted me to start work once again.
I've finally fathomed out my problems with IR reception (down to my own misunderstanding of the protocol) and I've managed to recover the development environment to the point of building test code again. I've also spent some time learning about iOS programming.
I suspect progress will be slow since I'm away from home alot at the moment.
Having managed to receive some meaningful data on the IR device, my next step is to write a tool that makes some sense of the data in preparation for retransmission. I intend to focus on a single IR remote control for now and get to the point of being able to send a few simple commands. This should be reasonable simple, but with IR it never seems to quite work that way.
More news, as it happens.
I've finally fathomed out my problems with IR reception (down to my own misunderstanding of the protocol) and I've managed to recover the development environment to the point of building test code again. I've also spent some time learning about iOS programming.
I suspect progress will be slow since I'm away from home alot at the moment.
Having managed to receive some meaningful data on the IR device, my next step is to write a tool that makes some sense of the data in preparation for retransmission. I intend to focus on a single IR remote control for now and get to the point of being able to send a few simple commands. This should be reasonable simple, but with IR it never seems to quite work that way.
More news, as it happens.
Tuesday, February 9, 2010
One Small Step
After some cries for help to the manufacturer, I've finally made some progress with the IR.
Reconfiguring LIRC (again) has finally let me successfully record and then retransmit IR signals to my Sky box. A small, but significant step forward.
I've discovered that recording things in raw mode seems to work OK - where the software doesn't try to work out the coding scheme being used but just regurgitates the codes as it captures them. This is a bit of a relief, as it makes the process a little simpler.
Having got LIRC working, I can now go back to my custom software and see where I can get with that. This isn't easy, but at least I'm making progress again.
Reconfiguring LIRC (again) has finally let me successfully record and then retransmit IR signals to my Sky box. A small, but significant step forward.
I've discovered that recording things in raw mode seems to work OK - where the software doesn't try to work out the coding scheme being used but just regurgitates the codes as it captures them. This is a bit of a relief, as it makes the process a little simpler.
Having got LIRC working, I can now go back to my custom software and see where I can get with that. This isn't easy, but at least I'm making progress again.
Subscribe to:
Posts (Atom)