Issue with CEC

  • I'm testing the Matrix alpha release with a Raspberry Pi 4 Model B Rev 1.1 (nightly-02021031-73c0ce6).

    Now that HD Audio is supported, I connect the RPi4 directly to my Soundbar (SB36514-G6) which is connected to my TV (Sony X850G) via eARC.

    If I boot (or reboot) my RPi, the CEC remote works perfectly.

    If I turn the TV off, and then on again, it doesn't work anymore.

    The cec-client reports that it's "unable to open the device on port Linux" even when the remote control is able to communicate with Kodi.

  • I'm seeing the same symptoms on the latest nightlies. I've reproduced the issue on two different devices (PINE A64 and Rock64), each connected to a different TV (directly with HDMI). If the TV is on when the device is booted, the TV remote can control Kodi normally. Once the TV is turned off, or was off while Kodi started, the remote will no longer control Kodi the next time the TV is turned on.

  • AFAIK it is always important to have the HDMI device(s) active when Kodi starts otherwise several (if not all) things related to HDMI port(s) won't work. The reason is that Kodi performs an autodetect at start (only).

    In general, systemctl restart kodi should help without complete reboot.

    Edited once, last by ghtester (March 11, 2021 at 1:00 PM).

  • AFAIK it is always important to have the HDMI device(s) active when Kodi starts otherwise several (if not all) things related to HDMI port(s) won't work. The reason is that Kodi performs an autodetect at start (only).

    In general, systemctl restart kodi should help without complete reboot.

    I think that having the TV (And soundbar) both on did it. I've restarted the TV a few times, and Kodi is remote-controllable.

  • AFAIK it is always important to have the HDMI device(s) active when Kodi starts otherwise several (if not all) things related to HDMI port(s) won't work. The reason is that Kodi performs an autodetect at start (only).

    In general, systemctl restart kodi should help without complete reboot.

    That seems wrong, since the point of CEC is to be able to interact with the TV while it's off (the device can send a command to turn the TV on while starting). Besides, it doesn't explain why it behaves this way even if the TV was on at startup and then turned off. Thanks for the tip on restarting Kodi though.

    (There seems to be a separate issue where, if my TV is on and switched to my Rock64 and I start/restart the system, I won't see a picture. Switching to the input while it's booting sometimes works? Regardless, this didn't happen to the Pine A64, which exhibited the same symptoms related to CEC, so I don't think it's related.)

    ...on further testing, the above parenthetical also applies to restarting Kodi without a full reboot. However, it isn't consistent—sometimes if Kodi starts while it's not the active input, it will appear when I switch inputs, and sometimes it won't; same applies if I keep the TV on Kodi's input the whole time. Sometimes switching to the input while Kodi is starting (usually just after systemctl returns) helps. The behavior with CEC is reproducible though: if Kodi is not the active input when it's started, I can't control it with the TV remote when I switch to it/start the TV; if Kodi is the active input, remote control works but ceases to work after I switch away from its input once.

  • Well, it depends how the HDMI device (TV) exactly works, as turned off might not always mean turned off completely. Perhaps many features related to HDMI CEC should be standardized but the reality is different.

    I was testing LE with my old LG TV regarding to CEC features but I decided stop using CEC soon as it did not work 100% reliable. So from my point of view it was unusable for me. Also some basic CEC commands did not work at all (despite accepted by TV, but ignored). For instance the power off command or volume control. Currently I am using TV without CEC, just as a display with audio, turned on / off by relay from LE running on my RPi 4B. This works perfectly and I am not missing (unreliable and obscure) CEC at all.

    I understand there are use cases for CEC but as every HDMI device is quite different, it's a question, who can invest the time to make it (somehow) working.

    Another possible reason, why HDMI does not work good, could be a cheap / bad quality cabling, especially when 4K resolution is used.

  • I am having the same issue with rpi 3 and kodi 19. When I turn off the TV and come back to it the next day, I can't get kodi to wake up using any keys on any remotes. I have to turn it off and then on again.

  • I am having the same issue with rpi 3 and kodi 19. When I turn off the TV and come back to it the next day, I can't get kodi to wake up using any keys on any remotes. I have to turn it off and then on again.

    When the TV is switching off, the RPi stops A/V output by default. When switching on the TV, there must be miscommunication between your RPi and TV, so A/V will not switch on.

    Go into input device settings, and select CEC adapter. Change the CEC settings to ignore TV switch-off signal. So RPi's A/V stays active all the time, and should still run when you switch the TV on again.

  • HI all,

    Unfortunately I have the same problem on Allwinner BananaPi M2+. I check CEC settings and its set correctly ("ignore on switch off"). I try recompile image with old libCEC 4.0.5 but issue is still visible. I observe that after power on my TV, physical address on cec-ctl is set as f.f.f.f (should be 1.0.0.0). Restart kodi helps but is no good solution. On LE 9.2 CEC worked correctly.