Missing /dev/lirc0

Moderators: odroid, mdrjr

Missing /dev/lirc0

Unread postby berndbausch » Sun Feb 04, 2018 10:58 am

Odroid C1+ running the latest Ubuntu 16.04. 3.5 inch LCD shield. I did the following tests with and without shield; no difference.

I thought I'd give the built-in infrared receiver a try, but already this step doesn't work:
Code: Select all
irrecord --device /dev/lirc0 myfile

because there is no /dev/lirc0. Actually, no /dev/lirc*.

Software is installed:
Code: Select all
bbausch@odroid:~$ dpkg -l | grep -i lirc
ii  liblircclient0:armhf   0.9.0-0ubuntu6   armhf   infra-red remote control support - client library
ii  lirc                          0.9.0-0ubuntu6   armhf   infra-red remote control support

Drivers correctly configured (or perhaps not?) in the kernel:
Code: Select all
bbausch@odroid:/boot$ uname -r
3.10.107-191
bbausch@odroid:/boot$ grep LIRC config-3.10.107-191
CONFIG_LIRC=m
CONFIG_IR_LIRC_CODEC=m
CONFIG_LIRC_STAGING=y
# CONFIG_LIRC_IGORPLUGUSB is not set
# CONFIG_LIRC_IMON is not set
# CONFIG_LIRC_PARALLEL is not set
CONFIG_LIRC_ODROID=m
# CONFIG_LIRC_SASEM is not set
# CONFIG_LIRC_SERIAL is not set
# CONFIG_LIRC_SIR is not set
# CONFIG_LIRC_ZILOG is not set

Kernel modules seem to exist:
Code: Select all
bbausch@odroid:/boot$ find /lib/modules/3.10.107-191 -iname '*lirc*'
/lib/modules/3.10.107-191/kernel/drivers/media/rc/lirc_dev.ko
/lib/modules/3.10.107-191/kernel/drivers/media/rc/ir-lirc-codec.ko
/lib/modules/3.10.107-191/kernel/drivers/staging/media/lirc
/lib/modules/3.10.107-191/kernel/drivers/staging/media/lirc/lirc_odroid.ko

But nothing in the message buffer:
Code: Select all
bbausch@odroid:/boot$ dmesg |grep -i lirc
bbausch@odroid:/boot$

I can modprobe lirc_dev, but the device file is still missing. Not sure what lirc_odroid is for:
Code: Select all
bbausch@odroid:/boot$ sudo modprobe lirc_odroid
modprobe: ERROR: could not insert 'lirc_odroid': No such device
bbausch@odroid:/boot$ dmesg | tail
...
[ 2423.791071] lirc_odroid: module is from the staging directory, the quality is unknown, you have been warned.
[ 2423.791796] uart_ao is using the pin GPIOAO_0 as pinmux
[ 2423.791812] pinmux-m8b pinmux: request() failed for pin 0
[ 2423.793564] pinmux-m8b pinmux: pin-0 (amlogic:gpio:0) status -22
[ 2423.799143] lirc_odroid: cant claim gpio pin 0
[ 2423.799155] lirc_odroid: init port fail!
[ 2423.799161] lirc_odroid[lirc_odroid_exit]


So, in short, what am I missing?
berndbausch
 
Posts: 9
Joined: Mon Mar 20, 2017 11:57 am
languages_spoken: english german french japanese
ODROIDs: C1+ running Ubuntu

Re: Missing /dev/lirc0

Unread postby odroid » Sun Feb 04, 2018 11:07 am

https://wiki.odroid.com/odroid-c1/application_note/lirc
Can you find "meson_ir" and "lirc_dev" in lsmod output?
User avatar
odroid
Site Admin
 
Posts: 29121
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: Missing /dev/lirc0

Unread postby berndbausch » Sun Feb 04, 2018 9:15 pm

Yes, but only after modprobing them manually. And now I have a /dev/lirc0! It looks like meson_ir did the trick.
The irrecord command reacts when I push buttons on the remote control I had lying around. I am in business. Thanks!

The kernel config seems to indicate that the modules should be loaded automatically, is that correct? In this case something is wrong, but I do have a very good workaround.
berndbausch
 
Posts: 9
Joined: Mon Mar 20, 2017 11:57 am
languages_spoken: english german french japanese
ODROIDs: C1+ running Ubuntu

Re: Missing /dev/lirc0

Unread postby mad_ady » Mon Feb 05, 2018 3:46 am

You will need to add the modules you want loaded at boot to /etc/modules.
User avatar
mad_ady
 
Posts: 4939
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1


Return to Hardware and peripherals

Who is online

Users browsing this forum: Google [Bot] and 2 guests