Moderator Control Panel ]

IR used with LIRC?

IR used with LIRC?

Postby StationG » Mon Sep 06, 2010 3:23 pm

Hi

Did anyone manage to set up the use of the infrared led with lirc?

Thanks for your feed back

Jerome
StationG
 
Posts: 16
Joined: Sat Aug 28, 2010 5:53 pm

Re: IR used with LIRC?

Postby cody » Mon Sep 06, 2010 10:52 pm

hi Jerome,

i believe you have to check this:

viewtopic.php?f=12&t=61&p=295&hilit=lirc#p295

and you can always share with us your experience with it :)
cody
 
Posts: 627
Joined: Tue Apr 13, 2010 11:20 pm

Re: IR used with LIRC?

Postby StationG » Tue Sep 07, 2010 4:31 pm

Thx for the reply Cody

To start i found lirc to be an intimidating piece of software!
I did search the forum to start and managed to get a reaction from my system with the following config:

/etc/lirc/hardware.conf
Code: Select All Code
# hardware.conf for eb1501
#
#REMOTE="Windows Media Center Transceivers/Remotes (all)"
REMOTE_MODULES="lirc_dev"
REMOTE_DRIVER="devinput"
REMOTE_DEVICE="/dev/input/irremote"
REMOTE_SOCKET=""
#REMOTE_LIRCD_CONF="devinput/lircd.conf.devinput"
REMOTE_LIRCD_ARGS=""
TRANSMITTER="None"
TRANSMITTER_MODULES=""
TRANSMITTER_DRIVER=""
TRANSMITTER_DEVICE=""
TRANSMITTER_SOCKET=""
TRANSMITTER_LIRCD_CONF=""
TRANSMITTER_LIRCD_ARGS=""
START_LIRCD="true"
LOAD_MODULES="true"
LIRCMD_CONF=""
FORCE_NONINTERACTIVE_RECONFIGURATION="false"
START_LIRCMD=""
REMOTE_MODULES=""
REMOTE_LIRCD_CONF=""



/etc/lirc/lircd.conf
Code: Select All Code
#
include "/usr/share/lirc/remotes/devinput/lircd.conf.devinput"


the command irw will then return such output as remote buttons are pressed:
Code: Select All Code
jerome@eeebox:~$ irw
0000000080010160 00 KEY_OK devinput
0000000080010193 00 KEY_CHANNELDOWN devinput

Every single buttons but the CHL+ and MODE! for some strange reason any idea on fixing this?
irrecord refuses to record those very two buttons as well!

Anyway i had no plan on using the provided remote i was dreaming on using an other remote with the TBS device receiver but i don't manged to obtain such output as below any hint on that?

Thx for your help

Jerome
StationG
 
Posts: 16
Joined: Sat Aug 28, 2010 5:53 pm

Re: IR used with LIRC?

Postby StationG » Wed Sep 08, 2010 10:56 pm

I manged to use the provided remote.
Is the IR driver stable?
Cause sometimes I "lose" the remote control and can't watch channels from TBS device either.
I have to reboot to get both back
StationG
 
Posts: 16
Joined: Sat Aug 28, 2010 5:53 pm

Re: IR used with LIRC?

Postby cody » Thu Sep 09, 2010 4:19 pm

i found small mistake in the driver that two keys have the same description:

{ 0xff86, KEY_2 },

{0xff86, KEY_CHANNELUP },

which definetly will cause problems and i will fix it in the next driver release that we will release soon, but can you give me more details about this:

StationG Wrote:Cause sometimes I "lose" the remote control and can't watch channels from TBS device either.
I have to reboot to get both back


i'm not sure that i understand well the trouble. thanks.
cody
 
Posts: 627
Joined: Tue Apr 13, 2010 11:20 pm

Re: IR used with LIRC?

Postby StationG » Thu Sep 09, 2010 8:07 pm

Cody thank you for bringing up that piece of source to me.
Reading this I feel like renamming KEY_* withing the source, the remote should be able to act as a keyboard. therefore I will have no need of using lirc. Wich will make my system simplier and I guess more reliable.
StationG
 
Posts: 16
Joined: Sat Aug 28, 2010 5:53 pm

Re: IR used with LIRC?

Postby cody » Fri Sep 10, 2010 3:36 am

StationG Wrote:Cody thank you for bringing up that piece of source to me.


you're welcome, i've just reviewed the code, because of the problem you reported. please, note that

{0xff86, KEY_CHANNELUP },

is a mistake and it should be:

{0xff96, KEY_CHANNELUP },

StationG Wrote:Reading this I feel like renamming KEY_* withing the source, the remote should be able to act as a keyboard. therefore I will have no need of using lirc. Wich will make my system simplier and I guess more reliable.


yes, you can change the mapping between the key code for example 0xff96 and what you want to do (KEY_*) directly in the source code and then rebuild the driver. please, share with us your experience with that approach.
cody
 
Posts: 627
Joined: Tue Apr 13, 2010 11:20 pm

Re: IR used with LIRC?

Postby StationG » Fri Sep 10, 2010 3:11 pm

I Changed KEY_OK to KEY_RETURN in:

Code: Select All Code
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/Documentation/DocBook/v4l/remote_controllers.xml
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-pctv-sedna.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-manli.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-tevii-nec.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-fusionhdtv-mce.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-tt-1500.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-dntv-live-dvbt-pro.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-nec-terratec-cinergy-xs.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-pv951.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-behold.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-tbs-nec.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-cinergy-1400.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-imon-mce.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-budget-ci-old.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-genius-tvgo-a11mce.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-terratec-cinergy-xs.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-avermedia-m135a.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-avermedia-cardbus.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-videomate-tv-pvr.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-avermedia-m733a-rm-k6.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/af9015.h
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/dibusb-common.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/dw2102.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/dib0700_devices.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/anysee.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/nova-t-usb2.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/tbs-qbox2.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/cxusb.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/tbs-qboxs2.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/m920x.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/tbs-qbox.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/cinergyT2-core.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/ttusb-dec/ttusb_dec.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/ttpci/av7110_ir.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/firewire/firedtv-rc.c


during make I bang into error:

Code: Select All Code
[...]
 CC [M]  /home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110_hw.o
  CC [M]  /home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110_v4l.o
  CC [M]  /home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110_av.o
  CC [M]  /home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110_ca.o
  CC [M]  /home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110.o
  CC [M]  /home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110_ipack.o
  CC [M]  /home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110_ir.o
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110_ir.c:74: error: 'KEY_RETURN' undeclared here (not in a function)
make[3]: *** [/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l/av7110_ir.o] Error 1
make[2]: *** [_module_/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l] Error 2
make[2]: Leaving directory `/usr/src/linux-headers-2.6.32-24-generic'
make[1]: *** [default] Erreur 2
make[1]: quittant le répertoire « /home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/v4l »
make: *** [all] Erreur 2



I guess I missed something any hint?

thx

Jérôme
StationG
 
Posts: 16
Joined: Sat Aug 28, 2010 5:53 pm

Re: IR used with LIRC?

Postby StationG » Sun Sep 12, 2010 3:01 pm

I did manage to customise KEY_* mapping and get rid of lirc (woohooo!)
KEY_RETURN was a silly test example as KEY_ENTER was the proper way to declare it.
As I understand you can rename KEY_* into anything listed in that file:
http://lirc.sourceforge.net/remotes/dev ... f.devinput

I finally only customised those file :
Code: Select All Code
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/tbs-qbox.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/tbs-qboxs2.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/dvb/dvb-usb/tbs-qbox2.c
/home/jerome/Sources/custom/linux-tbs-all_20100903/linux-tbs-all/linux/drivers/media/IR/keymaps/rc-tbs-nec.c


NOTE: My system was set up with an AZERTY keyboard which returns me strange output with the remote. Setting the system keyboard to QWERTY fixed it.

Now i have issue with the remote reliability. Sometimes the remote stop responding (but i'm still able to use the keyboard) it happened with lirc and now without so I'm kind of blaming TBS IR driver or device.
What could be done to solved this issue (apart from rebooting ;) )

thx
Jerome
StationG
 
Posts: 16
Joined: Sat Aug 28, 2010 5:53 pm

Re: IR used with LIRC?

Postby feadog » Tue Sep 14, 2010 4:11 am

#Now i have issue with the remote reliability. Sometimes the remote stop responding (but i'm still #able to use the keyboard) it happened with lirc and now without so I'm kind of blaming TBS IR #driver or device.

Identical problem here with my qboxs2. The only way I have found to restore the remote is to reload the driver ' rmmod dvb_usb_tbsqboxs2' and then modprobe dvb_usb_tbsqboxs2. Unfortunately that means having to restart mythtv-backend. Also sometimes the box hangs up completely following a remote key event, the computer stalls to a snails pace and I have to unplug the usb lead and power down the qbox to restore the system.

I have observed that the problem key event does not need to switch the tuner channel, just to move the cursor up or down is enough to trigger the problem.

In all cases my wireless keyboard (usb dongle)is not effected.
Thanks,
Noel
feadog
 
Posts: 4
Joined: Tue Sep 14, 2010 3:44 am

Next

Return to Linux

Who is online

Users browsing this forum: No registered users and 0 guests