[mythtv-users] DCT2000 Serial Control
Lonny Selinger
lonny at bangtherockstogether.net
Wed Jul 23 09:13:56 EDT 2003
**long post
So following the directions and suggestions for getting the serial
connection on a DCT2000 working I've managed to come to a block. I
compiled, configured, and installed lirc from CVS using the serial
option (home-brew) and grabbed Ian's scripts. So far this is what I'm
getting.
>From lircd: # modprobe lirc_serial
Jul 23 07:57:59 laptop kernel: lirc_serial: auto-detected active high
receiver
(same thing in dmesg)
in /dev/ I have: /dev/lircd= and /dev/lirc/serial
I copied the remote.py and crcgen.py to /usr/local/bin (changed
/dev/ttyS1 to /dev/ttyS0) and tried to execute the changechannel
script ... this is what I got:
# ./changechannel.sh 3
Traceback (most recent call last):
File "/usr/local/bin/remote.py", line 13, in ?
import crcgen # CRC generator - preset to generate
CCITT polynomial crc's
ImportError: No module named crcgen
I searched google for a while trying to find a crcgen module for
python and came up with nothing (not sure if they have a repository
for modules but I'm guessing they do and I just couldn't find it).
Anyway, just for the sake of debugging and to see if anything would
happen, I commented out the crcgen line and tried again:
File "/usr/local/bin/remote.py", line 111, in ?
stopbits=serial.STOPBITS_ONE, timeout=1, xonxoff=1,rtscts=0,)
File "/usr/lib/python2.2/site-packages/serial/serialposix.py", line
161, in __init__
raise serialutil.SerialException, "could not open port: %s" % msg
serial.serialutil.SerialException: could not open port: (5,
'Input/output error')
It seems like for some reason the supplied serial port isn't getting
passed to serialposix.py. Here's line 111 in remote.py:
serCon = serial.Serial('/dev/ttyS0',baudrate=9600,
bytesize=serial.EIGHTBITS, parity=serial.PARITY_NONE,
stopbits=serial.STOPBITS_ONE, timeout=1, xonxoff=1,rtscts=0,)
Does it seem like I'm at least on the right track (minus the minor
hang up)? I just dont want to spend a few days trying to debug and end
result if the thing that got me there started out wrong :) Either
way I'll keep hammering away at it ... just looking for
advice/suggestions.
Sorry for the long post,
Lonny
More information about the mythtv-users
mailing list