[mythtv-users] Need Help: HD-PVR IR Blaster [SOLVED....SORT OF]
martin.lynch.toronto at gmail.com
Wed Jan 5 03:53:06 UTC 2011
>>> > However if I replace:
>>> > name 0_26_KEY_0
>>> > 1703936
>>> > with
>>> > name 0_26_KEY_0
>>> > 2149187584
>>> > it fails ("2149187584" is the code corresponding to "name
>> Perhaps it is worth noting that 2149187584 is 0x801A0000 in hex, which
>> if stored as a signed number is -1703936 or so. Perhaps something in
>> the code doesn't like negative numbers.
> Well, that's fascinating! If that's the case, would it have different
> implications on a 64 bit machine vs a 32 bit (ie is the decision made
> in the programming to make it either a 32 bit signed integer or a 64
> bit signed integer? Or is that automatically accounted for?)?
> Jarod: can you possibly shed some light on this? ie what happens to
> these numbers/are they converted/etc?
In case anyone is following this thread (and so it ends up on the
record), here's how this played out:
Try as I might, I was unable to get the HD-PVR's IR Blaster to work.
Michael Lynch very kindly sent me all his configuration files which were
known to work, however upon inserting Michael's lircd.conf file to
/etc/lirc, once again my system refused to recognize any lircd.conf
which contained blaster codes with 10 digits - as soon as a single 10
digit code was included anywhere, $irsend LIST "" "" would report nothing.
I began to suspect it was either a kernel issue or a 64 bit vs 32 bit
issue, so I tested both: I went through the compile/copy files/etc
procedure on 2.6.31-11-rt and also 2.6.32-27-generic; neither worked
once the 10 digit codes were introduced. I also went through the
procedure on a 32 bit laptop: likewise everything went swimmingly until
a 10 digit code was introduced, then nothing.
I sent a private email to Jarod and posted my question above and signed
up to the LIRC mailing list, none of which elicited any response, so
having wasted a good 3 weeks on this, I gave up.
I instead bought a USB-UIRT IR receiver/blaster. The unit was around $60
with tax. After perhaps another 8 hours of monkeying around with that,
and attempting various lircd.conf and hardware.conf modifications, I
finally got it working. I also reworked the channel changing script
originally created by Daniel Kristjansson such that it will work for a
Bell 9241 STB (which is identical to a Dish Network VIP612, both of
which are made by Echostar). Lastly, I played around for quite some time
to figure out the proper codes for this remote/STB via trial and error -
I literally tried every code in steps of 100 and documented what the
different frequencies do (if anything) in case anyone else needs this
(because the remote that comes with this box uses IR for everything
_except_ the STB, which uses RF, therefore I couldn't simply capture the
codes via irw or irrecord. Luckily the box will accept an IR signal. Had
it not, I think it may well have found itself hurtling down 32 stories
in free fall...). You can find the codes in my lircd.conf file below -
lots of them are pretty useless in a MythTV setup, but there they are
So, for all who may follow, here's my lircd.conf, my hardware.conf and
my modified channel changing script (I've left some of the original
stuff in the script and simply commented it out, in case it turns out
useful to someone). Note that it is still sub-optimal, because one of
the LIRC instances is running conflicting instructions on which device
to use (it simultaneously reports "--device=/dev/lircd1" and "-d
/dev/ttyUSB0") but I'm so utterly fed up spending my time on LIRC and
ruing the day my firewire box left me that, since this works perfectly
for me, I have zero intention of further monkeying with it. When I see
the letters L-I-R-C these days my blood begins to boil and I have a
distinctly better understanding of the mechanics involved when people
lose it and go on homicidal rampages...LIRC is a ridiculous bunch of
smoke and mirrors and voodoo and incantations, none of which, it seems,
is documented in detail or firmly understood by _anyone_ (or certainly
not by anyone willing to share the magic spells).
Please note too that, under the subject line, "HD-PVR Priming Script" I
posted another (unresolved) question about unfreezing my constantly
freezing HD-PVR. Well, as it turns out, since abandoning LIRC
(grrrrr...) for the USB-UIRT, the HD-PVR has worked flawlessly - I've
been recording virtually all day every day and the HD-PVR has captured
every show. The channel changes via the USB-UIRT have worked flawlessly
with my amended channel change script and the box has yet to freeze.
That's great, because I was about to modify a power bar to allow control
of it via a USB cable such that I could interrupt the power and thereby
reset the HD-PVR. Now I can go back to enjoying, rather than struggling
Thanks, sincerely, to Michael and Mark for their kind efforts to help me
out - very much appreciated!
header 400 6100
one 400 1700
zero 400 2800
#Chosen IR Transmitter
TRANSMITTER="USB-UIRT2 : Dish Receiver"
#Chosen Remote Control
#Don't start lircmd even if there seems to be a good config file
#Try to load appropriate kernel modules
# Default configuration files for your hardware if any
#Forcing noninteractive reconfiguration
#If lirc is to be reconfigured by an external application
#that doesn't have a debconf frontend available, the noninteractive
#frontend can be invoked and set to parse REMOTE and TRANSMITTER
#It will then populate all other variables without any user input
#If you would like to configure lirc via standard methods, be sure
#to leave this set to "false"
channel change script for Bell 9241/Dish Net VIP612 - make sure you make
the file executable; place in /usr/local/bin, then point to it in the
mythtv-setup screen (I think it's under 4. Inputs? My backend is very
busy now so cannot check):
# This script is provided without any warranty of fitness to whoever
# wishes to use it. It has been used by me for many months with the
# VIP211 receivers. -- Daniel Kristjansson (March 20th, 2008)
# Additional modifications by Martin Lynch to enable use with
# Bell 9241 and Dish Network VIP612. It will likely work with
# other VIP STBs too (Jan 2, 2011).
# If you have a separate IR reciever you will want to give it "/dev/lircd"
# and use something like "/dev/lircd1" for the transmitter.
# If the tranmitter is on a remote LIRC server, use the ip/hostname:port
# with -a to address it.
# Use dish1, dish2 .. dish16 depending on which id you are using
# Every dish receiver can be assigned a different remote code, so
# that you can have multiple receivers in one room, and controlled
# by the same LIRC transmitter.
# This is the command passed in from MythTV.
# First, leave sleep mode..
# Note: I have commented this out as it did not function correctly and
# appears unnecessary - ML
#irsend $DEVICE SEND_ONCE $REMOTE_NAME select
case $cmd in
# make sure we leave any encrypted channel..
# Note: this IR send slows down MythTV LiveTV, if you want faster
# channel changing in LiveTV remove it. However if someone ever
# changes to a channel you don't get, either with this script or
# manually, you need this "up" to leave that channel.
# I likewise commented this out - encrypted channels do not pose a
# problem for a component connection (they certainly do for firewire!) ML
# irsend $DEVICE SEND_ONCE $REMOTE_NAME up
# sleep 0.3
for digit in $(echo $1 | sed -e 's/./& /g'); do
irsend $DEVICE SEND_ONCE $REMOTE_NAME $digit
# If things work OK with sleep 1, try this for faster channel
# I commented out the sleep 0.15 as channel changes did not work
# only the first digit made it through. Increased to 1 second. ML
# Send a select so that this channel change takes immediately.
irsend $DEVICE SEND_ONCE $REMOTE_NAME SELECT
irsend $DEVICE SEND_ONCE $REMOTE_NAME $cmd
More information about the mythtv-users