FIGURE 4. The logic output of a "1" from the Comcast remote.
FIGURE 5. The first group of the six sets of lines visible in Figure 4.
if I could just decode what the
cable remote (Figure 3) was
sending and program it into
the Arduino on my own, just
using the most basic
“digital Write” HIGH and LOW
commands. For this, I decided
to use a new toy. The Saleae
Logic logic analyzer ($150)
was more than enough to
meet my needs for this project.
Figure 4 shows the logic
analyzer output of what
happens when a “one” is
pressed on the remote; at this
level of zoom, there are three
subgroups of lines visible, each
divided into two smaller
Zooming in on the first
half of the first subgroup of
lines, we get Figure 5.
We need to go in even
closer. Again, zooming in on
the first of these nine pulses,
we get the picture in Figure 6.
Finally, we can see what is
happening. Close inspection of
the whole sequence of data
sent by pushing a “1” shows
that this pattern above is the
fundamental word that the IR
control understands; delay
times between these words
provide all of the information
the control needs.
When we look at this, we
find that the pulse is high for
about 8 µs and then off for
about 18 µs. I say “about”
because the Saleae device can
easily show that these pulses
have some significant variation.
With just the group of eight
pulses shown, we have on times from 7. 67 µs to 8. 29
µs, and off times from 17. 79 µs to 18. 46 µs. In other
words, this is not a case where nanosecond timing is
crucial. Note that the on time plus the off time give a
period of 26 µs, or a frequency of about 38 kHz —
somewhat standard for IR remotes.
After confirming all pulses were really just these
eight on/off transitions separated by some time (making
this job far easier), it became clear that the useful data
was encoded in the delay between pulses. I just had to
FIGURE 6. Close-up of the first of the nine pulses shown in Figure 5. This is the fundamental
pulse sent by the remote every time. Each "fat" line in Figure 5 looks just like this when we examine
somewhat sensitive to the exact placement of the
alligator clip leads) from the picture and just use the
Arduino itself as a smart remote control. A quick
Google search reveals that there are many websites out
there with information about IR remote control
protocols and libraries to help program the Arduino to
use them. There are even sites that will show you how
to use an IR receiver to detect the code with the
Arduino, instead of the method described here.
I wanted to do this a different way; I wanted to see