raspberry pi: can't get lirc working

Ask questions about Arch Linux ARM. Please search before making a new topic.

raspberry pi: can't get lirc working

Postby bouh » Sat Oct 01, 2016 7:59 pm

Hi,

On raspberry pi 2, I've installed lirc and lirc-utils package, and updated. I'm using this versions :
$this->bbcode_second_pass_code('', '
$ uname -a
Linux <host> 4.4.23-1-ARCH #1 SMP Fri Sep 30 19:06:51 MDT 2016 armv7l GNU/Linux
$ mode2 --version
mode2 0.9.4b
')

I added dtoverlay=lirc-rpi in /boot/config.txt

I stopped lircd :
$this->bbcode_second_pass_code('', '
$ systemctl stop lircd
')

I can see lirc_rpi, lirc_dev in the lsmod output.

I can also see:
$this->bbcode_second_pass_code('', '
$ dmesg | grep lirc
[ 7.198975] lirc_dev: IR Remote Control driver registered, major 244
[ 7.224093] lirc_rpi: module is from the staging directory, the quality is unknown, you have been warned.
[ 8.191682] lirc_rpi: auto-detected active high receiver on GPIO pin 18
[ 8.192009] lirc_rpi lirc_rpi: lirc_dev: driver lirc_rpi registered at minor = 0
')

Then I try to read raw input using mode2:
$this->bbcode_second_pass_code('', '
$mode2 -d /dev/lirc0
Using driver devinput on device /dev/lirc0
Trying device: /dev/lirc0
Using device: /dev/lirc0
Warning: Running as root.
Partial read 8 bytes on /dev/lirc0
$
')

It returns directly back to prompt after the "partial read" log.

I was expecting to get a proper result from mode2.

Then I can not get lircd working properly :

$this->bbcode_second_pass_code('', '
$ systemctl start lircd
$ irw
^C
$ systemctl status lircd
* lircd.service - Flexible IR remote input/output application support
Loaded: loaded (/usr/lib/systemd/system/lircd.service; enabled; vendor preset: disabled)
Active: active (running) since Sat 2016-10-01 19:48:59 UTC; 8min ago
Docs: man:lircd(8)
http://lirc.org/html/configure.html
Main PID: 522 (lircd)
Tasks: 1 (limit: 4915)
CGroup: /system.slice/lircd.service
`-522 /usr/sbin/lircd --nodaemon

Oct 01 19:49:09 <host> lircd[522]: lircd-0.9.4b[522]: Error: Cannot glob /sys/class/rc/rc0/input[0-9]*/event[0-9]*
Oct 01 19:49:09 <host> lircd-0.9.4b[522]: Error: Cannot glob /sys/class/rc/rc0/input[0-9]*/event[0-9]*
Oct 01 19:49:10 <host> lircd[522]: lircd-0.9.4b[522]: Error: Cannot glob /sys/class/rc/rc0/input[0-9]*/event[0-9]*
Oct 01 19:49:10 <host> lircd-0.9.4b[522]: Error: Cannot glob /sys/class/rc/rc0/input[0-9]*/event[0-9]*
Oct 01 19:49:10 <host> lircd[522]: lircd-0.9.4b[522]: Error: Cannot glob /sys/class/rc/rc0/input[0-9]*/event[0-9]*
Oct 01 19:49:10 <host> lircd[522]: lircd-0.9.4b[522]: Info: removed client
Oct 01 19:49:10 <host> lircd[522]: lircd-0.9.4b[522]: Info: closing 'auto'
Oct 01 19:49:10 <host> lircd-0.9.4b[522]: Error: Cannot glob /sys/class/rc/rc0/input[0-9]*/event[0-9]*
Oct 01 19:49:10 <host> lircd-0.9.4b[522]: Info: removed client
Oct 01 19:49:10 <host> lircd-0.9.4b[522]: Info: closing 'auto'
')

Did I miss something ?

Thanks for your advices

Bouh.
bouh
 
Posts: 3
Joined: Sat Oct 01, 2016 7:32 pm

Re: raspberry pi: can't get lirc working

Postby graysky » Sat Oct 01, 2016 8:10 pm

Consult the Arch wiki lirc page for some troubleshooting tips. I have the same versions on the same hardware albeit with another remote that works as expected.

EDIT: also see my github/streamzap for some tips with that remote that might be applicable to your hardware (ie default mode and the status of the kernel driver).
graysky
Developer
 
Posts: 1728
Joined: Sun Jun 26, 2011 6:56 am
Location: /run/user/1000

Re: raspberry pi: can't get lirc working

Postby moonman » Sat Oct 01, 2016 11:42 pm

Don't know if the bug is still there as I don't have IR remote in my setup anyore, but last time I tried it the latest lirc did not work. Try a version or 2 older package.
EDIT: this is the version that works:
$this->bbcode_second_pass_code('', 'Last login: Mon Sep 19 16:43:21 2016 from 192.168.43.140
[root@alarmpi ~]# pacman -Qs lirc
local/lirc 1:0.9.3.a-2
Linux Infrared Remote Control utils')

Maybe it is just a configuration problem but I did not bother to dig deeper
Pogoplug V4 | GoFlex Home | Raspberry Pi 4 4GB | CuBox-i4 Pro | ClearFog | BeagleBone Black | Odroid U2 | Odroid C1 | Odroid XU4
-----------------------------------------------------------------------------------------------------------------------
[armv5] Updated U-Boot | [armv5] NAND Rescue System
moonman
Developer
 
Posts: 3387
Joined: Sat Jan 15, 2011 3:36 am

Re: raspberry pi: can't get lirc working

Postby bouh » Sun Oct 02, 2016 7:05 am

Hi,

Thanks for your replies.

Thanks to a tip I found on github/streamzap, I could get it working with this configuration in /etc/lirc/lirc_options.conf :
$this->bbcode_second_pass_code('', '
driver = default
device = /dev/lirc0
')

Bouh
bouh
 
Posts: 3
Joined: Sat Oct 01, 2016 7:32 pm

Re: raspberry pi: can't get lirc working

Postby graysky » Wed Nov 02, 2016 9:31 pm

$this->bbcode_second_pass_quote('bouh', 'T')hanks to a tip I found on github/streamzap,


Yeah, that me :) You don't need that entry in your boot.ini by the way.
graysky
Developer
 
Posts: 1728
Joined: Sun Jun 26, 2011 6:56 am
Location: /run/user/1000


Return to User Questions

Who is online

Users browsing this forum: No registered users and 9 guests