Kodi and LIRC

recluce

Member

Thanks: 9
Messages: 91

#1
I was wondering if anybody has Kodi working with an IR remote and LIRC under FreeBSD 11.0-STABLE.

It was actually quite easy to setup LIRC and the LIRC tools show that the remote is recognized and key presses are interpreted correctly on the OS side. Kodi 16.10 has been build from ports with LIRC support enabled (currently on Kodi 16.10_11). But when I start Kodi, there is no mention of LIRC in Kodi's log file and it simply does not work - with no debug or log data available from Kodi.

If anybody had success getting this to work, I would appreciate it if he or she could chime in here.
 
OP
OP
R

recluce

Member

Thanks: 9
Messages: 91

#3
Thank you for the link, but I tried that guide early on. However, I went through the steps again, just to be sure and when starting kodi with "--lircdev /dev/lirc0 --debug", I finally got something in the log file:

Code:
09:03:34 T:34845252864    INFO: LIRC Process: using: /dev/lirc0
09:03:34 T:34845252864    INFO: LIRC Connect: connect failed: Socket operation on non-socket
09:03:34 T:34845252864    INFO: CRemoteControl::Process - failed to connect to LIRC, will keep retrying every 5 seconds
A couple of seconds later, a message that it gave up on lirc:

Code:
09:03:44 T:34844270592  NOTICE: closing down remote control service
09:03:44 T:34845252864   DEBUG: Failed to connect to LIRC. Giving up.
09:03:44 T:34845252864   DEBUG: Thread RemoteControl 34845252864 terminating
09:03:44 T:34844270592    INFO: LIRC SetEnabled: disabled
 

aht0

Active Member

Thanks: 30
Messages: 103

#4
Have you tried updating ports recently? I built Kodi using ports over the last weekend and got 17.1 out of it.

Can't chime in about LIRC, I am using remote which is recognized as mouse (ums) by FreeBSD
 
OP
OP
R

recluce

Member

Thanks: 9
Messages: 91

#5
17.1 currently breaks passthrough audio for me (Kodi tells me it is enabled, but only 2.0 arrives at the amplifier), so I am staying away from it at the moment (I rolled back to 16.10_11). The issue has existed since I set up the system (originally with 16.10_7).

I checked the sockets on that machine, /var/run/lirc/lircd exists. Does the socket error indicate a bug in Kodi?
 

SirDice

Administrator
Staff member
Administrator
Moderator

Thanks: 6,429
Messages: 27,750

#6
After you've configured LIRC make sure the daemon runs before starting Kodi; service lircd start. If I recall correctly it's the daemon process that creates the device.
 

SirDice

Administrator
Staff member
Administrator
Moderator

Thanks: 6,429
Messages: 27,750

#7
I checked the sockets on that machine, /var/run/lirc/lircd exists. Does the socket error indicate a bug in Kodi?
No, it's more likely that /dev/lirc0 is not correct and you need to point it to /var/run/lirc/lircd.
 
OP
OP
R

recluce

Member

Thanks: 9
Messages: 91

#8
lircd is started on system boot and I verified it is running, creating /dev/lirc0 and /var/run/lirc/lircd

No, it's more likely that /dev/lirc0 is not correct and you need to point it to /var/run/lirc/lircd.
You may be onto something here. I tried /var/run/lirc/lircd. While it did not work, the result is different:

Code:
11:25:28 T:34845252864   DEBUG: Thread RemoteControl start, auto delete: false
11:25:28 T:34845252864    INFO: LIRC Process: using: /var/run/lirc/lircd
11:25:28 T:34845252864   DEBUG: LIRC: Failed to initialize Inotify. LIRC device will not be monitored.
11:25:28 T:34845252864    INFO: CRemoteControl::Process - failed to connect to LIRC, will keep retrying every 5 seconds
 
OP
OP
R

recluce

Member

Thanks: 9
Messages: 91

#10
I found a workaround, as Kodi simply does not seem to work with lircd under FreeBSD. I ordered a second generation FLIRC (the all metal one), a nifty little device that is a programmable infrared receiver, but emulates a regular USB keyboard towards the computer. Once programmed, no driver or software is needed. Works!
 
Top