CEC problems on rpi5 with LE nightly

  • Hi, i am running LE nightly on a fresh installed rpi5.

    All works like a charm except CEC. I had running an Odroid n2 before with coreelec and all works, so i assume the AV Receiver and the TV are configured properly. When i power off the rpi5 with the menu in LE, the TV powers off too but the AV receiver not. When i power off the TV, neither the rpi5 nor the AV receiver power off.

    Whats also a bit confusing: i have 2 CEC configuration entries like i would have 2 CEC Adapters. I configured both of them in the same way and maybe messed up a bit. Can anyone help me a bit here?

    Quote

    2024-06-07 12:58:14.428 T:1244 info <general>: Register - new cec device registered on cec->/dev/cec0: CEC Adapter (0000:0000)
    2024-06-07 12:58:14.429 T:1244 info <general>: Register - new cec device registered on cec->/dev/cec1: CEC Adapter (0000:0000)

    Whats working: i can use the remote from the TV to navigate in LE, so CEC in general works.

    Edited once, last by olze (June 7, 2024 at 12:36 PM).

  • With the nightly builds there is some progress in the CEC adapter settings. Somethere I have read, that libCEC is able to support CEC on both HDMI ports. This is the reason for /dev/cec0 and /dev/cec0. It was introduced with LE13 nightly - I don't know if planned or not. LE12 should be expose only 1 CEC adapter.

    During my tests last week with a LE13 nightly build, I had the same experience like you, that it feels not consistent. Afterwards I stumbled over the configuration file '/storage/.kodi/userdata/peripheral_data/cec_CEC_Adapter.xml'. This includes only a single set of settings. I fear it's not fully implemented yet to support splitted settings for HDMI 0 and HDMI 1. The last one wins, sometimes only after a reboot.

    EDIT: found, seems planned

    cec: Allow cec driver to handle multiple instances by popcornmix · Pull Request #8812 · LibreELEC/LibreELEC.tv
    Currently on a Pi4/5, LibreELEC is largely usable when connected to second hdmi port, except CEC doesn't work as it's hard-coded to /dev/cec0. This generates…
    github.com

    Edited 4 times, last by HarryH (June 7, 2024 at 5:13 PM).

  • Unfortunately i must use the second hdmi port. I use a micro-hdmi-to-hdmi-adapter and this would overlap the power supply if i would use the first hdmi slot.

    So its broken atm in nightly and i assume nothing i can do. Just wondering why its not default like anyone would expect, e.g. when powering off the TV, power off the rpi5 and vice versa.

  • Either you change the settings in both CEC Adapter entries sequential to identical settings. Sound weird, but should work. Or you change only in one of them and make a KODI restart afterwards.

    Only some other observations remains, which I had already made before with LE 12. Manual set of HDMI port or changing "Connected to" from TV to AVR doesn't resist and is reset after a restart. There seems some interference with a kind of HDMI hierachy auto-detection and should only be used if auto-detection fails completely. All other settings like repeat rate and so on works fine.

  • CEC on the second HDMI port isn't officially supported. Personally I like those small adapters, because I prefer standard cables. Maybe it's smart to get a new RPi case to use HDMI-0.

  • how should a RPI case change anything in my current situation? I need a new mini-hdmi adapter then. The mini-hdmi-adapter blocks the power port of the rpi5 when i use the adapter in the first hdmi slot. Or do you mean "cable" and that was a typo?

    I would love to use such an adapter but seems like its nearly impossible, they are much more expensive (in switzerland) than a cable itself... i ordered now https://www.digitec.ch/de/s1/product/…hz-mit-42870548 and hope that works.

    Edited 2 times, last by olze (June 8, 2024 at 10:53 AM).

  • No typo, I was talking about my preferences in general.

    Some RPi5 cases have internal wiring. They can adapt to full size HDMI, or increase the distance between USB-C and HDMI-0.

    However, your new cable will do the trick.

  • Oh wow, i was not aware of that. So its like a case which connects to the micro-hdmi-port and extends it to a full sized hdmi port? i have never seen something, but sounds very reasonable! thanks for that information! do you maybe have a link to such case?

  • I replaced now the adapter with the cable and used the first port, close to the power supply, but still the same behaviour.

    I am not sure if this is a nightly-problem or also in the stable. For me, unfortunately, a killer. I will see if i can get a new SD card for testing and see what happens with latest stable.

  • Click at Settings -> System -> Input -> Peripherals -> CEC Adapter to setup the AVR behavior.

    You listed that already as second posting and thats where i was from the beginning, see my initial posting.

    Unfortunately, it does not change the behaviour, as i dont know how i should configure all those settings.

    Its german, so i try to translate those entries: report kodi as primary source: checked, hdmi port number 1 and 2 (both cec adapters are configured in the same way, atm 2), wake up device when screen saver is deactivated checked, connected with hdmi-device: av-receiver, activated: checked, wake up av receiver when kodi gets activated: check, when powering off kodi report as inactive: checked, when poweroff kodi then explicit (avr + tv), on start of kodi explicit (avr+tv).

    I have the feeling this is just so hardcore broken, that it does not work at all. I thought i go to the other cec adapter settings for configuration to check if they are maybe swapped (e.g. the first cec adapter is for the second port) and noticed, they are equal in also using the hdmi port which makes the possibility to configure both useless, as its only possible to configure one hdmi port, because the other entry will have the exact same configuration (including the same hdmi port). I guess thats what HarryH meant.

    Is the first hdmi port close to the power supply HDMI port 1 or port 2?