LinHES Forums http://forum.linhes.org/ |
|
=fixed=7.4 and ir blaster http://forum.linhes.org/viewtopic.php?f=22&t=23669 |
Page 1 of 2 |
Author: | ssbn [ Wed Jan 02, 2013 8:14 pm ] |
Post subject: | =fixed=7.4 and ir blaster |
It has been a long time from the last time I redid my mythtv. I was running 6.1 and no problems at all. But I decided it was time to upgrade my hardware and software. So I did a fresh install of 7.4 and have just about everything working. I have satellite tv so had to use an ir blaster to change the channels. I have a serial ir blaster. I was able to set it up by the gui. But I can't recall how to set up the Chang Chanel script. I have my old one but a lot has changed. Can anyone point me to how to setup the new script. Thanks for the help |
Author: | goofee [ Thu Jan 03, 2013 11:24 am ] |
Post subject: | Re: 7.4 and ir blaster |
In mythtv-setup -> #5 input connections, enter the path to your script in the "external channel change command" box. Enter the proper channel on the "preset tuner channel" box if using a tuner input. There is a sample change script at /usr/MythVantage/templates/change_chan.sh, just change the remote name to match the remote name in your lircd.conf. I put mine in the mythtv home dir so it always gets backed up and restored on upgrade. |
Author: | ssbn [ Thu Jan 03, 2013 9:58 pm ] |
Post subject: | Re: 7.4 and ir blaster |
goofee wrote: In mythtv-setup -> #5 input connections, enter the path to your script in the "external channel change command" box. Enter the proper channel on the "preset tuner channel" box if using a tuner input. There is a sample change script at /usr/MythVantage/templates/change_chan.sh, just change the remote name to match the remote name in your lircd.conf. I put mine in the mythtv home dir so it always gets backed up and restored on upgrade. Thanks for the help that has me well on my way. But I have run into another problem. I set my mceusb remot to use a serial irblaster at TTYs0 as per this command. dmesg | grep tty [ 0.000000] Kernel command line: root=/dev/disk/by-uuid/46ee9211-d04f-4517-b549-d6eaaf183ae7 ro init=/sbin/runit vmalloc=192M quiet vga=0x314 splash=silent,theme:linhes console=tty1 [ 0.000000] console [tty1] enabled [ 0.484861] serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A [ 0.568822] 00:0c: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A [root@mythtv-server templates]# Broadcast message from root@mythtv-server (Thu Jan 3 23:45:22 2013): I also picked my set top box brand that was an exact match. I modified my change_chan.sh as follows. #!/bin/sh REMOTE_NAME=mceusbcmd="$1" case $cmd in [0-9]*) for digit in $(echo $1 | sed -e 's/./& /g'); do irsend SEND_ONCE $REMOTE_NAME $digit sleep 0.5 # If things work OK with sleep 1, try this for faster channel changes: # sleep 0.3 done ;; *) irsend SEND_ONCE $REMOTE_NAME $cmd ;; esac # /usr/bin/fix_audio.sh & I then add the location of the script in input connections. But when I change the channel nothing happens. When I run the following command I get this error. [root@mythtv-server ~]# /usr/MythVantage/templates/change_chan.sh 123 irsend: command failed: SEND_ONCE mceusb 1 irsend: unknown command: "1" irsend: command failed: SEND_ONCE mceusb 2 irsend: unknown command: "2" irsend: command failed: SEND_ONCE mceusb 3 irsend: unknown command: "3" But it will run this command without error but wont turn off the box. /usr/MythVantage/templates/change_chan.sh power [root@mythtv-server ~]# It looks to me like the signal is not getting to the com port. |
Author: | ssbn [ Fri Jan 04, 2013 9:36 am ] |
Post subject: | Re: 7.4 and ir blaster |
Can anyone tell me how to send a repeating command to the serial port so I can check it with a digital camera for a signal? |
Author: | goofee [ Fri Jan 04, 2013 10:22 am ] |
Post subject: | Re: 7.4 and ir blaster |
I suspect mceusb is the remote your using to control mythtv. You'll want to put the remote name that is used to control your satbox into that script. Looking at the error it gave and comparing to /usr/MythVantage/templates/remotes/mceusb/lircd.conf.mceusb the config file has "one" instead of "1". What kind of satbox are you looking to control? What does /etc/lircd.conf have in it? I suspect it should have 2 lines, one for mceusb and one for satbox. |
Author: | ssbn [ Fri Jan 04, 2013 5:31 pm ] |
Post subject: | Re: 7.4 and ir blaster |
goofee wrote: I suspect mceusb is the remote your using to control mythtv. You'll want to put the remote name that is used to control your satbox into that script. Looking at the error it gave and comparing to /usr/MythVantage/templates/remotes/mceusb/lircd.conf.mceusb the config file has "one" instead of "1". What kind of satbox are you looking to control? What does /etc/lircd.conf have in it? I suspect it should have 2 lines, one for mceusb and one for satbox. Here is lircd.conf include "/usr/MythVantage/templates/remotes/mceusb/lircd.conf.mceusb" include "/usr/MythVantage/templates/transmit/motorola_dsr315/lircd.conf" You are correct I have mceusb and Motorola_dsr315 I did put the remote name in the channel change script. Do you know of hand the script the gives the irblaster settings? Could my problem be there. |
Author: | ssbn [ Fri Jan 04, 2013 9:32 pm ] |
Post subject: | Re: 7.4 and ir blaster |
ok let me se if I can give you the whole picture now that I know where most thinks are. Step one In mythtv go to remote settings pick mcusb remote then for ir blaster pick ttys0 and for sat box pick motorola_dsr315 Step Two edit /usr/MythVantage/templates/change_chan.sh and add mceusb as follows in bold. Then add the location of the shange channel script in mythtv-settings. #!/bin/sh REMOTE_NAME=mceusb cmd="$1" case $cmd in [0-9]*) for digit in $(echo $1 | sed -e 's/./& /g'); do irsend SEND_ONCE $REMOTE_NAME $digit sleep 0.5 # If things work OK with sleep 1, try this for faster channel changes: # sleep 0.3 done ;; *) irsend SEND_ONCE $REMOTE_NAME $cmd ;; esac # /usr/bin/fix_audio.sh & Step three verify what /etc/lircd.conf include "/usr/MythVantage/templates/remotes/mceusb/lircd.conf.mceusb" include "/usr/MythVantage/templates/transmit/motorola_dsr315/lircd.conf" the contents of borth are as follows # # RC-6 config file # # source: http://home.hccnet.nl/m.majoor/projects ... ontrol.htm # http://home.hccnet.nl/m.majoor/pronto.pdf # # used by: Philips # ######### # # Philips Media Center Edition remote control # For use with the USB MCE ir receiver # # Dan Conti dconti|acm.wwu.edu # # Updated with codes for MCE 2005 Remote additional buttons # *, #, Teletext, Red, Green, Yellow & Blue Buttons # Note: TV power button transmits no code until programmed. # Updated 12th September 2005 # Graham Auld - mce|graham.auld.me.uk # # Radio, Print, RecTV are only available on the HP Media Center remote control # begin remote name mceusb bits 16 flags RC6|CONST_LENGTH eps 30 aeps 100 header 2667 889 one 444 444 zero 444 444 pre_data_bits 21 pre_data 0x37FF0 gap 105000 toggle_bit 22 rc6_mask 0x100000000 begin codes #-------------------------------------------------------------b9 Testb90 0x00007b90 Testb91 0x00007b91 Testb92 0x00007b92 Testb93 0x00007b93 Testb94 0x00007b94 Testb95 0x00007b95 Testb96 0x00007b96 Testb97 0x00007b97 Testb98 0x00007b98 Testb99 0x00007b99 TV????? 0x00007b9a Messenger 0x00007b9b Testb9c 0x00007b9c Testb9d 0x00007b9d Testb9e 0x00007b9e Testb9f 0x00007b9f #-------------------------------------------------------------ba Testba0 0x00007ba0 Blue 0x00007ba1 Yellow 0x00007ba2 Green 0x00007ba3 Red 0x00007ba4 Teletext 0x00007ba5 Testba6 0x00007ba6 Testba7 0x00007ba7 Testba8 0x00007ba8 Testba9 0x00007ba9 Testbaa 0x00007baa Testbab 0x00007bab Testbac 0x00007bac Testbad 0x00007bad Testbae 0x00007bae Radio 0x00007baf #-------------------------------------------------------------bb Testbb0 0x00007bb0 Print 0x00007bb1 Testbb2 0x00007bb2 Testbb3 0x00007bb3 Testbb4 0x00007bb4 Videos 0x00007bb5 Pictures 0x00007bb6 RecordedTV 0x00007bb7 Music 0x00007bb8 TV 0x00007bb9 Testbba 0x00007bba Testbbb 0x00007bbb Testbbc 0x00007bbc Testbbd 0x00007bbd Testbbe 0x00007bbe Testbbf 0x00007bbf #-------------------------------------------------------------- bc Testbc0 0x00007bc0 Testbc1 0x00007bc1 Testbc2 0x00007bc2 Testbc3 0x00007bc3 Testbc4 0x00007bc4 Testbc5 0x00007bc5 Testbc6 0x00007bc6 Testbc7 0x00007bc7 Testbc8 0x00007bc8 Testbc9 0x00007bc9 Testbca 0x00007bca Testbcb 0x00007bcb Testbcc 0x00007bcc Testbcd 0x00007bcd Testbce 0x00007bce Testbcf 0x00007bcf #---------------------------------------------------------------bd Testbd0 0x00007bd0 Testbd1 0x00007bd1 Testbd2 0x00007bd2 Testbd3 0x00007bd3 Testbd4 0x00007bd4 Testbd5 0x00007bd5 Testbd6 0x00007bd6 Testbd7 0x00007bd7 Testbd8 0x00007bd8 Guide 0x00007bd9 LiveTV 0x00007bda DVDMenu 0x00007bdb Back 0x00007bdc OK 0x00007bdd Right 0x00007bde Left 0x00007bdf #--------------------------------------------------------------be Down 0x00007be0 Up 0x00007be1 Star 0x00007be2 Hash 0x00007be3 Replay 0x00007be4 Skip 0x00007be5 Stop 0x00007be6 Pause 0x00007be7 Record 0x00007be8 Play 0x00007be9 Rewind 0x00007bea Forward 0x00007beb ChannelDown 0x00007bec ChannelUp 0x00007bed VolumeDown 0x00007bee VolumeUp 0x00007bef #---------------------------------------------------------------bf More 0x00007bf0 Mute 0x00007bf1 Start 0x00007bf2 Power 0x00007bf3 Enter 0x00007bf4 Clear 0x00007bf5 Nine 0x00007bf6 Eight 0x00007bf7 Seven 0x00007bf8 Six 0x00007bf9 Five 0x00007bfa Four 0x00007bfb Three 0x00007bfc Two 0x00007bfd One 0x00007bfe Zero 0x00007bff end codes end remote And the sat box # # this config file was automatically generated # using lirc-0.8.0(serial) on Wed Apr 12 13:07:22 2006 # # contributed by # # brand: Motorola # model no. of remote control: IRC451 (PN:515301-002) Modes 0000,0001,0002,0003 # devices being controlled by this remote: Motorola (DSR205 & DSR315) StarChoice receiver # begin remote name Motorola_dsr_series bits 12 flags SPACE_ENC|CONST_LENGTH eps 30 aeps 100 header 5082 1878 one 1102 2874 zero 1102 884 ptrail 1107 gap 99386 min_repeat 1 toggle_bit 0 begin codes POWER 0x605 UP 0xC4F DOWN 0x045 LEFT 0xB88 RIGHT 0x80C ENTER 0x384 GOBACK 0x68F EXIT 0xA0F INFO 0xE4C GUIDE 0x782 REWIND 0x944 PLAY 0x74D FORWARD 0x148 RECORD 0x54E PAUSE 0x34B STOP 0xB47 CH_UP 0xD07 CH_DOWN 0x08A LAST 0x187 INTERESTS 0x581 BROWSE 0x849 PPV 0xB02 FUTURE 0x443 OPTIONS 0x289 1 0xF04 2 0x886 3 0x48C 4 0xE83 5 0x98B 6 0xD8D 7 0x50B 8 0x901 9 0x708 0 0x246 HELP 0xF8E end codes end remote begin remote name Motorola_IRC451_0001 bits 12 flags SPACE_ENC|CONST_LENGTH eps 30 aeps 100 header 5074 1909 one 1086 2902 zero 1086 906 ptrail 1090 gap 99708 min_repeat 1 toggle_bit 0 begin codes POWER_1 0x62B UP_1 0xC61 DOWN_1 0x06B LEFT_1 0xBA6 RIGHT_1 0x822 ENTER_1 0x3AA GOBACK_1 0x6A1 EXIT_1 0xA21 INFO_1 0xE62 GUIDE_1 0x7AC REWIND_1 0x96A PLAY_1 0x763 FORWARD_1 0x166 RECORD_1 0x560 PAUSE_1 0x365 STOP_1 0xB69 CH_UP_1 0xD29 CH_DOWN_1 0x0A4 LAST_1 0x1A9 INTERESTS_1 0x5AF BROWSE_1 0x867 PPV_1 0xB2C FUTURE_1 0x46D OPTIONS_1 0x2A7 1_1 0xF2A 2_1 0x8A8 3_1 0x4A2 4_1 0xEAD 5_1 0x9A5 6_1 0xDA3 7_1 0x525 8_1 0x92F 9_1 0x726 0_1 0x268 HELP_1 0xFA0 end codes end remote begin remote name Motorola_IRC451_0002 bits 12 flags SPACE_ENC|CONST_LENGTH eps 30 aeps 100 header 5048 1936 one 1055 2934 zero 1055 941 ptrail 1054 gap 99772 toggle_bit 0 begin codes POWER_2 0x612 UP_2 0xC58 DOWN_2 0x052 LEFT_2 0xB9F RIGHT_2 0x81B ENTER_2 0x393 GOBACK_2 0x698 EXIT_2 0xA18 INFO_2 0xE5B GUIDE_2 0x795 REWIND_2 0x953 PLAY_2 0x75A FORWARD_2 0x15F RECORD_2 0x559 PAUSE_2 0x35C STOP_2 0xB50 CH_UP_2 0xD10 CH_DOWN_2 0x09D LAST_2 0x190 INTERESTS_2 0x596 BROWSE_2 0x85E PPV_2 0xB15 FUTURE_2 0x454 OPTIONS_2 0x29E 1_2 0xF13 2_2 0x891 3_2 0x49B 3_2 0x49B 4_2 0xE94 5_2 0x99C 6_2 0xD9A 7_2 0x51C 8_2 0x916 9_2 0x71F 0_2 0x251 HELP_2 0xF99 end codes end remote begin remote name Motorola_IRC451_0003 bits 12 flags SPACE_ENC|CONST_LENGTH eps 30 aeps 100 header 5052 1934 one 1047 2943 zero 1047 949 ptrail 1041 gap 99759 toggle_bit 0 begin codes POWER_3 0x63C UP_3 0xC76 DOWN_3 0x07C LEFT_3 0xBB1 RIGHT_3 0x835 ENTER_3 0x3BD GOBACK_3 0x6B6 EXIT_3 0xA36 INFO_3 0xE75 GUIDE_3 0x7BB REWIND_3 0x97D PLAY_3 0x774 FORWARD_3 0x171 RECORD_3 0x577 PAUSE_3 0x372 STOP_3 0xB7E CH_UP_3 0xD3E CH_DOWN_3 0x0B3 LAST_3 0x1BE INTERESTS_3 0x5B8 BROWSE_3 0x870 PPV_3 0xB3B FUTURE_3 0x47A OPTIONS_3 0x2B0 1_3 0xF3D 2_3 0x8BF 3_3 0x4B5 4_3 0xEBA 5_3 0x9B2 6_3 0xDB4 7_3 0x532 8_3 0x938 9_3 0x731 0_3 0x27F HELP_3 0xFB7 end codes end remote One thing I notice is in the Motorola_dsr315 there are a few name fields with duplicate settings. I wonder if I have to pick what one to use. I alos don't know where the file is that has my serial settings I set from the gui. Lets hope someone can spot my mistake. |
Author: | jams [ Fri Jan 04, 2013 10:10 pm ] |
Post subject: | Re: 7.4 and ir blaster |
For the remote name in blasting you want to use the name of the remote that your cablebox will understand. So in this case instead of using mceusb as the remote name in the change channel script use one of the names for the Motorola box like Motorola_dsr_series. To test that it's really blasting use this command: irsend SEND_ONCE Motorola_dsr_series 1 That will tell the blaster to send the Motorola 1 key code. For reference the settings from the GUI are stored in /etc/systemconfig and referenced by the remotes startup script. |
Author: | ssbn [ Sat Jan 05, 2013 11:06 am ] |
Post subject: | Re: 7.4 and ir blaster |
jams wrote: For the remote name in blasting you want to use the name of the remote that your cablebox will understand. So in this case instead of using mceusb as the remote name in the change channel script use one of the names for the Motorola box like Motorola_dsr_series. To test that it's really blasting use this command: irsend SEND_ONCE Motorola_dsr_series 1 That will tell the blaster to send the Motorola 1 key code. For reference the settings from the GUI are stored in /etc/systemconfig and referenced by the remotes startup script. Here is my ir info from the systemconfig. #IR settings Remotetype="mceusb" ReceiverType="Default" HDHRlirc_device="No devices found" HostLircWait="" ReceiverSerialport="ttyS0" HostTransmitproto_1="motorola_dsr315" HostTransmitproto_2="dish_dvr625" HostTransmitproto_3="none" HostTransmitproto_4="none" HostBlasterType="Serial" HostSerialPort_blasterlirc="ttyS0" Hostnumblaster="1" rootSSH="1" I did this command that should send a signal every second to my ir blaster. I then looked at it with an iphone camera and did not se any blink. while [ 1 ]; do irsend SEND_ONCE Motorola_dsr_series 2; sleep 1; Even if I had the wrong codes I should have seen something I assume. It is now looking like I am not transmitting to the serial port or at least the wrong one? Do you have any tips on how to verify this? |
Author: | jams [ Sat Jan 05, 2013 11:53 am ] |
Post subject: | Re: 7.4 and ir blaster |
Well i think you did verify that it's not transmitting with your camera. It might be the wrong serial port defined or a couple of other things. Unfortunately with transmitting and different lirc devices there is no great way to debug, or define a setup. |
Author: | jams [ Sat Jan 05, 2013 1:16 pm ] |
Post subject: | Re: 7.4 and ir blaster |
So do you have both a mce receiver and a serial transmitter? |
Author: | ssbn [ Sat Jan 05, 2013 2:45 pm ] |
Post subject: | Re: 7.4 and ir blaster |
jams wrote: So do you have both a mce receiver and a serial transmitter? This is what I have. http://www.irblaster.info/ir_blaster.jpg I seem to remember last time I redid the mythtv I had a similar problem. I cant recall if I could se it with my iphone when it was working or if it was to dim. |
Author: | ssbn [ Sat Jan 05, 2013 3:29 pm ] |
Post subject: | Re: 7.4 and ir blaster |
I know I am spinning in one spot a bit more info. Quote: [root@mythtv-server ~]# dmesg | grep tty [ 0.000000] Kernel command line: root=/dev/disk/by-uuid/46ee9211-d04f-4517-b549-d6eaaf183ae7 ro init=/sbin/runit vmalloc=192M quiet vga=0x314 splash=silent,theme:linhes console=tty1 [ 0.000000] console [tty1] enabled [ 0.484823] serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A [ 0.568826] 00:0c: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A My Systemconfig has Quote: #IR settings Remotetype="mceusb" ReceiverType="Default" HDHRlirc_device="No devices found" HostLircWait="" ReceiverSerialport="ttyS0" HostTransmitproto_1="motorola_dsr315" HostTransmitproto_2="dish_dvr625" HostTransmitproto_3="none" HostTransmitproto_4="none" HostBlasterType="Serial" HostSerialPort_blasterlirc="ttyS0"Hostnumblaster="1" rootSSH="1" Could ReceiverSerialport and HostSerialPort_blasterlirc being the same be the problem? |
Author: | goofee [ Sat Jan 05, 2013 9:08 pm ] |
Post subject: | Re: 7.4 and ir blaster |
I've never mixed receiver/transmitter types so not sure if that would cause a problem. Could try setting up one first then the other to see if they conflict. I suspect that mceusb being a usb device should not tie up the serial port. Just flipping through the GUI, I see that you can select mseusb for the remote and for the receiver type. Not sure if that makes a difference. That is the same blaster I'm using and it does NOT show up when checking with iphone 4S camera. It does show up with my kodak digital camera and my panasonic video camera. I'm using a motorola dsr315 as well (I think that looks like the file I submitted years ago) so that combination can definitely work. Best of luck. |
Author: | ssbn [ Sun Jan 06, 2013 8:18 am ] |
Post subject: | Re: 7.4 and ir blaster |
goofee wrote: I've never mixed receiver/transmitter types so not sure if that would cause a problem. Could try setting up one first then the other to see if they conflict. I suspect that mceusb being a usb device should not tie up the serial port. Just flipping through the GUI, I see that you can select mseusb for the remote and for the receiver type. Not sure if that makes a difference. That is the same blaster I'm using and it does NOT show up when checking with iphone 4S camera. It does show up with my kodak digital camera and my panasonic video camera. I'm using a motorola dsr315 as well (I think that looks like the file I submitted years ago) so that combination can definitely work. Best of luck. Thanks for the help. I found an old digital camera and still can se it. I think I will go back to my old hardware or se if there is a new hauppauge card out there with a blaster that is not serial that is supported. |
Page 1 of 2 | All times are UTC - 6 hours |
Powered by phpBB® Forum Software © phpBB Group http://www.phpbb.com/ |