Is there an addon or a command to detect remote key for RF remote like LIRC ?

  • Hi all !

    I got a pi4 4gb with a 4tb HDD and a Gyration RF remote gyr3101eu

    I installed LibreELEC and it works like a charm (so happy) !

    I tried to use Keymap Editor add-on but all menus of this addon are very hard to understand, all menus are mixed and not really explicit.

    I would like to know if there is an add-on or a command like LIRC for IR remote but for RF remote.

    I want to know all my remote keys and make my own remote.xml

    Thanks

  • Easiest way is to enable debug logging in kodi and then watch kodi log as you press buttons. eg

    Code
    tail -f .kodi/temp/kodi.log

    You can also use evtest from the system tools addon, but you have to make sure you've stopped kodi and eventlircd as both of them might grab the input device and thus evtest doesn't report any buttons/keys (evtest will warn you about that). BTW: If eventlircd grabbed the remote input button presses will show up as LIRC events instead of keyboard/input events in kodi.

    so long,

    Hias

  • I tried it with kodi log file via ssh, I found 50% of all my remote keys but the other 50% are not working, I got the same code 0x... for all these keys and also the code is longer as normal, more than 6 numbers after 0x

    Is there a generic driver to install to have all keys working ?

  • Can you upload the kodi log where you press some of those buttons?

    My guess is the remote shows up as a keyboard in kodi and it's sending some keycodes that kodi doesn't handle - the logfile should tell us what's happening.

    so long,

    Hias

  • As suspected the remote is sending some keycodes that kodi doesn't handle.

    You can change the keycodes with a hwdb file - eg map the scancodes to some function keys like f1, f2, f3, ... Read this post for more info Ok button doesn't work on H1 remote

    Also look at the /lib/udev/hwdb.d/60-keyboard.hwdb file in LE, it contains the documentation of the hwdb file format and several entries for keyboards that you can use as a reference.

    so long,

    Hias

  • Another option would be to tell eventlircd to translate the keyboard events from your remote into lirc events - then you can use kodi's Lircmap.xml plus remote.xml (or keymap editor addon) to map the button codes.

    To do this you first need to find out the USB vendor and model/product id using "lsusb" - note the "ID" output from your RF receiver, the first 4-digit hex number (before the colon) is the vendor ID, the second 4-digit hex number (after the colon) is the model/product ID.

    Then copy LibreELEC's eventlircd udev rule to /storage/.config/udev.rules.d and edit it:

    Code
    cp /usr/lib/udev/rules.d/98-eventlircd.rules /storage/.config/udev.rules.d/
    nano /storage/.config/udev.rules.d/98-eventlircd.rules

    At the beginning of the USB section in that file (around line 90, after the 'ENV{ID_USB_INTERFACES}=="", IMPORT{builtin}="usb_id"') add a line with the following content. Substitute XXXX/ / YYYY with your vendor / model IDs from lsusb and make sure everything is on a single line:

    Code
    ENV{ID_VENDOR_ID}=="0bc7", ENV{ID_MODEL_ID}=="0006", ENV{eventlircd_enable}="true"

    After a reboot eventlircd should pick up your remote and the buttons should show up as Lirc events instead of keyboard events in kodi.log.

    so long,

    Hias

  • Ok with lirc method all buttons are working except one but the problem is I don't have anymore the mouse fonction

    I will try this weekend the method with remapping keys but I doubt.

    Thanks again