View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 16 posts ] 
Go to page 1, 2  Next

Print view Previous topic   Next topic  
Author Message
Search for:
 Post subject: IRblaster R5B7
PostPosted: Sun Mar 19, 2006 5:45 pm 
Offline
Joined: Sun Jan 23, 2005 11:13 am
Posts: 9
Location: Mishawaka, IN
Long time listener , first time caller.
First off thanks a million to all the folks that make knoppmyth happen:!:

I have been running R5A12 since it's release a year ago and just love it. I decided to dive in and update the box to the latest and greatest R5B7. I will admit that I forgot a lot of the little tweaks and customizations that were done over time on the box. I decided to blow the box away and start from scratch for that nice clean feeling :)

I have an external DirecTV tuner that has an infrared Irblaster hooked into the com1 on the mythtv box.
When I set this up previously I used the amazing write up at http://losdos.dyndns.org:8080/public/my ... _LIRC.html to set this all up. It really took me by the hand and walked me though what I needed to do to get this up and running. 8)

I have tried to follow these steps again with setting up R5B7 but have met with a lot of failure over the last two days. I would list all the steps that I have tried to make it work from using the latest lirc to modifying the myth_ledxmit.sh script to use com1 but that is not the reason for this post exactly.

During the new install of R5B7 there is a part that inquires if you are using an irblaster! I went through the nice clean setup script and answered that I had the hauppage remote. It also asked what model and I answered with silver. It then asked what com port I was on....then answered 1.

My Hauppage remote works great for navigating around inside MythTV!

The reason for this long winded post is that I am not sure where to define what kind of Satellite tuner I am running like I did with my previous install of MythTV or the change channel script that I would need to use. I am assuming this new part of the MythTV install is geared toward these external digital devices and I think you may be able to define this all now in the same /etc/irblaster/hardware.conf file but I am afraid I am a bit at a loss.

Thank you in advance for pointing me in the right direction! :!: 8)


Top
 Profile  
 
 Post subject:
PostPosted: Sun Mar 19, 2006 6:28 pm 
Offline
Joined: Mon Mar 21, 2005 1:43 pm
Posts: 388
Location: Nanaimo BC
If you only have one pvr card the script should work great for you.

what you need to do is take the remote.conf file for your sat reciever (get from lirc.org) and rename it to irblasterd.conf; put it in /etc/irblaster.

Then you need to make a channel change script. However you did it before should work but instead of lircd1 use irblasterd.


This is mine (sorta)

#!/bin/sh
STB_NAME=DCT2000
for digit in $(echo $1 | sed -e 's/./& /g'); do
irsend --device=/dev/irblasterd SEND_ONCE $STB_NAME $digit
sleep 0.7
done
irsend --device=/dev/irblasterd SEND_ONCE $STB_NAME OK

Name it whatever you like (change_channel.sh)

I put it in /etc/irblaster. Then just reference it from the setup screens.

*NOTE I have not actually got it working yet due to having 2 pvr cards so I had to go back to the way I have done it in the past. Should this not work for you search for a post by me that describes how I have mine working.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Mar 19, 2006 6:38 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
iscraigh - Could you do the dance of IR blaster clue bestowal for wanttoknow over here? http://mysettopbox.tv/phpBB2/viewtopic.php?t=9093
Thx!


Top
 Profile  
 
 Post subject:
PostPosted: Sun Mar 19, 2006 8:47 pm 
Offline
Joined: Sun Jan 23, 2005 11:13 am
Posts: 9
Location: Mishawaka, IN
Thank you for the very prompt reply!

I went strait to work to see if I could make this happen. I am afraid I did not have a lot of success but you have me in the right direction now :)

Here are my configs from the /etc/irblaster

hardware.conf
Quote:
# /etc/irblaster/hardware.conf
#
# Author: Greg Frost
# The COM Port used by the IRBlaster. Set it to "COM1" "COM2" or "".

IRBLASTER_SERIAL_PORT="COM1"

# Set this to the lirc device that will be used by lirc_serial. In my case
# it is /dev/lirc. I have a USB remote, so my remote does not use the
# /dev/lirc device, so it is used by lirc_serial for my ir blaster. If you
# have a remote that uses /dev/lirc, the blaster may user /dev/lirc1. Not
# sure.

IRBLASTER_DEVICE="/dev/lirc1"



irblasterd.conf
Quote:
# This config file was generated by hand on Aug 19 2003
# by Bryan Jacobs <bryan_jj@hotmail.com>.
# It is based on HIRD-B2.
# brand: Hughes
# model: HIRD-B2/GAEBO DSS satellite receiver

begin remote

name HUGHES_DSS_GAEBO
bits 16
flags SPACE_ENC|CONST_LENGTH
eps 30
aeps 100

header 9200 4400
one 700 1600
zero 700 450
ptrail 700
repeat 9200 2150
pre_data_bits 16
pre_data 0x30DF
gap 108000
toggle_bit 0

begin codes

last 0x0000000000006897
guide 0x00000000000048B7
up 0x0000000000009867
down 0x00000000000008F7
left 0x00000000000028D7
right 0x000000000000E817
select 0x00000000000018E7
action 0x000000000000708F
list 0x0000000000008877
info 0x000000000000C837
back 0x000000000000F00F
power 0x000000000000A857

1 0x000000000000A05F
2 0x000000000000609F
3 0x000000000000E01F
4 0x00000000000010EF
5 0x000000000000906F
6 0x00000000000050AF
7 0x000000000000D02F
8 0x00000000000030CF
9 0x000000000000B04F
0 0x00000000000020DF
ch- 0x000000000000C03F
ch+ 0x00000000000040BF

end codes
end remote


change_chan.sh
Quote:
#!/bin/sh
REMOTE_NAME=HUGHES_DSS_GAEBO
for digit in $(echo $1 | sed -e 's/./& /g'); do
irsend --device=/dev/irblaster SEND_ONCE $REMOTE_NAME $digit
sleep 0.4 # note, you may have to tweak the interdigit delay up a bit, depending on your DISH receiver model
done


When I try and run the change_chan.sh script by hand this is what I get.
Quote:
root@mythtv:~# /etc/irblaster/change_chan.sh 123
irsend: command failed: SEND_ONCE HUGHES_DSS_GAEBO 1
irsend: hardware does not support sending
irsend: command failed: SEND_ONCE HUGHES_DSS_GAEBO 2
irsend: hardware does not support sending
irsend: command failed: SEND_ONCE HUGHES_DSS_GAEBO 3
irsend: hardware does not support sending


Also when I put those conf files in the /etc/irblaster directory my Hauppage remote stop working to navigate around the MythTV menu screens. When I pull the files out of the /etc/irblaster directory the Hauppage remote starts working again to navigate the screens.

I do see both of these processes running when they are both enabled.
3343 root 21:22 /usr/sbin/irblasterd --driver=default --device=/dev/lirc1 --pidfile=/var/run/irb ...
3503 root 21:22 /usr/sbin/lircd --driver=default –device=/dev/lirc



Thanks again for the help!


Top
 Profile  
 
 Post subject:
PostPosted: Mon Mar 20, 2006 12:05 am 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
This could be an order of startup issue. I'm not sure how lirc_serial knows to use /dev/lirc1 and lirc_gpio (or whatever else it is that handles your remote) knows to use /dev/lirc.

Perhaps someone could do some manual fiddling adding and removing the modules and running lircd/irblasterd to see if it is an order of modules loading thing.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 23, 2006 6:16 pm 
Offline
Joined: Sun Jan 23, 2005 11:13 am
Posts: 9
Location: Mishawaka, IN
I have been working on this and learning a lot (more than I ever wanted to know) about lirc.

When I do an "irblaster stop" in the /etc/init.d dir it complains that it cannot unload lirc_serial because it's in use.

Does irblaster need to use it's own version of lirc_serial or can it share the one that it is using with whatever else has it open?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 23, 2006 7:10 pm 
Offline
Joined: Sun Jan 23, 2005 11:13 am
Posts: 9
Location: Mishawaka, IN
The other thing I see is that when I get a list of open files the lircd has /dev/lirc open but irblaster does not have /dev/lirc1 open. Also it looks like irblaster is firing up first since it has a lower PID so if we have a timing issue on load order how can I get irblaster to fire up second?


Quote:
For process /usr/sbin/lircd --driver=default --device=/dev/lirc (PID 2886)

File Descriptor Type Path
Current dir Directory /
Root dir Directory /
Program code Regular file /usr/sbin/lircd
Shared library Regular file [heap] (stat: No such file or directory)
Shared library Regular file /lib/tls/libpthread-2.3.5.so
Shared library Regular file /lib/tls/libdl-2.3.5.so
Shared library Regular file /lib/tls/libm-2.3.5.so
Shared library Regular file /lib/tls/libc-2.3.5.so
Shared library Regular file /lib/libusb-0.1.so.4.4.2
Shared library Regular file /usr/lib/libasound.so.2.0.0
Shared library Regular file /lib/ld-2.3.5.so
0u Character special /dev/null
1u Character special /dev/null
2u Character special /dev/null
3u Regular file /var/run/lircd.pid
7u Character special /dev/lirc


Quote:
For process /usr/sbin/irblasterd --driver=default --device=/dev/lirc1 --pidfile=/var/run/irblasterd.pid --output=/dev/irblaster /etc/irblaster/irblasterd.conf (PID 2726)

File Descriptor Type Path
Current dir Directory /
Root dir Directory /
Program code Regular file /usr/sbin/irblasterd
Shared library Regular file [heap] (stat: No such file or directory)
Shared library Regular file /lib/tls/libpthread-2.3.5.so
Shared library Regular file /lib/tls/libdl-2.3.5.so
Shared library Regular file /lib/tls/libm-2.3.5.so
Shared library Regular file /lib/tls/libc-2.3.5.so
Shared library Regular file /lib/libusb-0.1.so.4.4.2
Shared library Regular file /usr/lib/libasound.so.2.0.0
Shared library Regular file /lib/ld-2.3.5.so
0u Character special /dev/null
1u Character special /dev/null
2u Character special /dev/null
3u Regular file /var/run/irblasterd.pid


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 23, 2006 7:48 pm 
Offline
Joined: Sun Jan 23, 2005 11:13 am
Posts: 9
Location: Mishawaka, IN
Well I found out how to change the load order.

I went into /etc/rc5.d and renamed the symbolic link s20irblaster to s40irblaster.

lircd got a pid of 2862 and irblaster got a pid of 4160.

This had no effect on things. I assume this is what was meant by timing.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 23, 2006 7:50 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
I suspect this module load order issue is what is giving isgraigh problems too. I am hopingto work through it with him this weekend. Basically, the lirc modules are loaded when /etc/init.d/lirc runs and the irblaster module (lirc_serial) is loaded when /etc/init.d/irblaster runs. Looking in /etc/rc5.d, they both have the startup number 20 which means they will just start in alphabetical order meaning that S20irblaster runs before S20lirc. To fix this you will need to do some update-rc.d commands to change the startup number for irblaster to something greater than 20. Not sure exactly what commands. check the man page.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Mar 27, 2006 4:09 am 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
We found the problem with iscraig's irblaster setup ( http://mysettopbox.tv/phpBB2/viewtopic. ... 4331#54331 ), but it seems you have already tried something similar. What is the exact symptom of your problem now?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 30, 2006 8:56 pm 
Offline
Joined: Sun Jan 23, 2005 11:13 am
Posts: 9
Location: Mishawaka, IN
Sorry it took a few days to get back to this.
I tried all the setup that you have written up in this post
http://mysettopbox.tv/phpBB2/viewtopic.php?t=9352

It gets me a bit further along. Now when the irblaster.conf is populated my Hauppage remote still works unlike before but I still can't get it to change channels on my sattelite dish.
I deleted the old /dev/irblaster and /etc/mythtv/modules/lirc_serial. It re-created those and the /dev/irblasterd.
I modified my change_chan.sh to this.
Quote:
#!/bin/sh
REMOTE_NAME=HUGHES_DSS_GAEBO
for digit in $(echo $1 | sed -e 's/./& /g'); do
/usr/local/bin/irsend -d /dev/irblasterd SEND_ONCE HUGHES_DSS_GAEBO $digit
sleep 0.4 # note, you may have to tweak the interdigit delay up a bit, depending on your DISH receiver model
done


When I run that I get no errors like before but at the same time nothing happens either.

I do see this in the /var/log/syslog though and am not sure if this is the problem or just cosmetic.
Quote:
Mar 30 21:24:29 mythtv lircd-0.8.0pre4-pvr150[3548]: accepted new client on /dev/irblasterd
Mar 30 21:24:29 mythtv kernel: BUG: using smp_processor_id() in preemptible [00000001] code: irblasterd/3548
Mar 30 21:24:29 mythtv kernel: caller is lirc_ioctl+0x8e/0x340 [lirc_serial]
Mar 30 21:24:29 mythtv kernel: [debug_smp_processor_id+140/160] debug_smp_processor_id+0x8c/0xa0
Mar 30 21:24:29 mythtv kernel: [pg0+546050222/1067881472] lirc_ioctl+0x8e/0x340 [lirc_serial]
Mar 30 21:24:29 mythtv kernel: [pg0+545931102/1067881472] irctl_ioctl+0x14e/0x190 [lirc_dev]
Mar 30 21:24:29 mythtv kernel: [do_ioctl+70/112] do_ioctl+0x46/0x70
Mar 30 21:24:29 mythtv kernel: [vfs_ioctl+83/448] vfs_ioctl+0x53/0x1c0
Mar 30 21:24:29 mythtv kernel: [sys_ioctl+71/112] sys_ioctl+0x47/0x70
Mar 30 21:24:29 mythtv kernel: [syscall_call+7/11] syscall_call+0x7/0xb


Thanks for all of your hard work on the irblaster stuff Greg Frost!


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 30, 2006 9:10 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
hmmm. That smp bug log message occurs for me too (at startup and on each irsend), but my blaster works so I havent worried about it. I have heard that others have recompiled the kernel without SMP support to get rid of it.
Please post the result of
Code:
ls -la /dev/lirc* /dev/irblaster*
While you are at it,
Code:
ls -laR /sys/class/lirc
cat /sys/class/lirc/lirc*/dev
ps ax | grep ir
What happens when you run at the command line:
Code:
irsend -d /dev/irblasterd SEND_ONCE HUGHES_DSS_GAEBO 1


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 31, 2006 6:15 am 
Offline
Joined: Sun Jan 23, 2005 11:13 am
Posts: 9
Location: Mishawaka, IN
ls -la /dev/lirc* /dev/irblaster*

Quote:
root@mythtv:~# ls -la /dev/lirc* /dev/irblaster*
crw-r--r-- 1 root root 61, 1 Mar 31 04:07 /dev/irblaster
srw-rw-rw- 1 root root 0 Mar 31 04:07 /dev/irblasterd
crw-r--r-- 1 root root 61, 0 Jan 23 22:41 /dev/lirc
crw-rw-rw- 1 root root 61, 1 Oct 1 03:02 /dev/lirc1
srw-rw-rw- 1 root root 0 Mar 30 21:21 /dev/lircd
prw-r--r-- 1 root root 0 Jul 30 2004 /dev/lircm


ls -laR /sys/class/lirc
Quote:
root@mythtv:~# ls -laR /sys/class/lirc
/sys/class/lirc:
total 0
drwxr-xr-x 4 root root 0 Mar 31 04:07 .
drwxr-xr-x 27 root root 0 Mar 30 21:21 ..
drwxr-xr-x 2 root root 0 Mar 31 07:06 lirc0
drwxr-xr-x 2 root root 0 Mar 31 07:06 lirc1

/sys/class/lirc/lirc0:
total 0
drwxr-xr-x 2 root root 0 Mar 31 07:06 .
drwxr-xr-x 4 root root 0 Mar 31 04:07 ..
-r--r--r-- 1 root root 4096 Mar 31 07:06 dev
--w------- 1 root root 4096 Mar 31 07:06 uevent

/sys/class/lirc/lirc1:
total 0
drwxr-xr-x 2 root root 0 Mar 31 07:06 .
drwxr-xr-x 4 root root 0 Mar 31 04:07 ..
-r--r--r-- 1 root root 4096 Mar 31 07:06 dev
--w------- 1 root root 4096 Mar 31 07:06 uevent


root@mythtv:~# cat /sys/class/lirc/lirc*/dev
Quote:
61:0
61:1


ps ax | grep ir

Quote:
root@mythtv:~# ps ax | grep ir
3 ? SN 0:00 [ksoftirqd/0]
808 ? S< 0:00 [kmirrord]
2860 ? S 0:00 [lirc_dev]
2863 ? Ss 0:00 /usr/sbin/lircd --driver=default --device=/dev/lirc
3442 ? S<l 0:26 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --skip-locking --port=3306 --socket=/var/run/mysqld/mysqld.sock
4616 ? S 0:00 irexec
5649 ? Ss 0:00 /usr/sbin/irblasterd --driver=default --device=/dev/irblaster --pidfile=/var/run/irblasterd.pid --output=/dev/irblasterd /etc/irblaster/irblasterd.conf


Quote:
root@mythtv:~# irsend -d /dev/irblasterd SEND_ONCE HUGHES_DSS_GAEBO 1

I am afraid nothing happens at all but at least it does not throw an error :)


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 31, 2006 4:55 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
That all looks to be configured the way it should be.

Do you have a com2 port? Might be worth trying it.

To discount the possibility that the lirc_serial module settings are not working, look at
/sys/module/lirc_serial/parameters/io (should be 1016 which is 0x3f8) and /sys/module/lirc_serial/parameters/irq (should be 4).

Perhaps check in your bios to check if there is something strange (ports disabled, irq or io ports that do not use the traditional irq4 io3f8 for com1 and irq3 io2f8 for com2).

For checking hardware, check to see if the blaster is lighting up using a digital camera (they can detect infra red), perhaps your config file is not correct.

Could your IR led have blown? Did you make the blaster yourself?

One of the things I did to check that the serial port was working correctly when I first set my blaster up was to use a multimeter to measure the voltage on the pin that controls the blaster (I think it was pin 4, but you could check the blaster documentation). Then I did an irsend with SEND_START (or something like that, again check the man page) instead of SEND_ONCE and I saw the voltage the multimeter was registering changed. This made me confident that I had the right COM port and the software was controlling it.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Apr 28, 2006 5:03 pm 
Offline
Joined: Tue Dec 13, 2005 3:13 pm
Posts: 43
Location: Leicestershire, UK
[quote="Greg Frost"]hmmm. That smp bug log message occurs for me too (at startup and on each irsend), but my blaster works so I havent worried about it. I have heard that others have recompiled the kernel without SMP support to get rid of it.]

This has troubled me for some time. I have gone through the pain of recompiling the kernel with SMP disabled using my previous hardware (EPIA M12000) and sure enough, that gets rid of this bug. Now I am using the Dragon hardware (with an AMD64) I wonder if disabling the SMP support will have a detremental effect on performance?

Algenon.

_________________
Dragon without HDTV card, PVR350, PAL-UK


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 16 posts ] 
Go to page 1, 2  Next



All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 11 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu