Remote Control Signals 101

Ā

Ever wondered what a remote control signal actually looks like? Well, it's a beam of infrared light that flashes rapidly kinda like morse code, the actual message is carried in the way the light flashes, not the IR frequency as many might expect.

Most signals create the message by varying the amount of time the light is OFF between the flashes, although some (like Sony) vary the ON time to create the message, and a few vary both but don't worry about that now.

In a typical signal the ON time will be constant, and there will be two different OFF times, one is usually identical to the ON time and the other is longer, usually a multiple of the OFF time. This timing feature is used to create ONEs and ZEROs, which in turn are used to create a binary string.

For example, the NEC format is a 32 bit code, which means that when you decode the IR signal you should end up with a string of 32 ONEs and ZEROs. In Pronto hex the ON time for the NEC format is "15" and the OFF time can be either "15" or "3f", in decimal "15" translates to 21 and "3f" translates to 63, so you can see that "3f" is 3 times the length of "15". In the NEC format, a ONE is represented as "15 3f" and a ZERO is represented as "15 15".

Even if you got a bit lost in the details there, don't worry about it, it's enough that you know that a signal can be reduced to binary. Now let's take a look at how you can read that binary signal. Let's say you downloaded a file from the Pronto section and translated the pronto hex into binary as described above, you might end up with a string that looks something like this:

11011111 00100000 01000000 10111111

What people like myself have done already is get many samples of the code and look to see how it varies, and from this we have deduced the format. In this example, you need to read the binary from left to right (the opposite of what you might expect), this is because this protocol is what we call a "Least Significant Bit first" protocol (LSB for short), some signals are MSB (Most Significant Bit first). We have also already deduced that the first word (8 bits) is the device code, the 2nd word is the compliment of the device code (ie, reverse all the bits, 1's become 0's and vice versa). The third word is the command code and the 4th word is the command code compliment.

So, the example that I gave above is device code 251, command code 2

If you already know how to read binary, skip to the next paragraph.... Here's how I got 251 from the "11011111" string, reading from the left, here's how the bits work

1 * 1 = 1
1 * 2 = 2
0 * 4 = 0
1 * 8 = 8
1 * 16 = 16
1 * 32 = 32
1 * 64 = 64
1 * 128 = 128

1+2+0+8+16+0+64+128 = 251

Now that you know everything gets reduced to binary, it should give you an idea of how to look at the code that you might find in the memory of your 15-1994 remotes. All the information is stored in hex format, which can easily be converted to binary using the Microsoft Excel function "hex2bin". Other useful functions include hex2dec, bin2dec, bin2hex, dec2bin and dec2hex. (NOTE: to activate these functions in Excel, go to the "Tools" menu item and select "Add-ins...", then select the "Analysis Toolpak").

 Home | Forums | Manuals | Files | Infra Red | JP1 Upgrades | Setup Codes | Advanced Codes | Links    