Kodi Community Forum

Full Version: CEC not working after standby in beta 3
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I am using Kodi 17 beta3 / libreELEC 7.90.007 Alpha on a Raspberry pi 3 on a Samsung UE60J6275. The problems starting after upgdrading from Kodi beta2 / libreELEC 7.90.006.

Debug logs with CEC component: https://dflund.se/~glyph/stuff/kodi/cec%...tandby.log

The logs contain the following:

Here I turn off the TV, before that everything works fine.
Code:
16:14:02  39.222042 T:1800872864   DEBUG: CecLogMessage - TV (0): power status changed from 'on' to 'standby'

After that I start it again on
Code:
16:14:19  56.635731 T:1800872864   DEBUG: CecLogMessage - TV (0): power status changed from 'standby' to 'on'

And pressing keys on the remote no longer works, the keypresses shown are from a regular keyboard. After that I try to change back and forth between different input sources on the TV to try and restore the CEC connection, but this doesn't work.

Another instance of the problem is around

Code:
16:25:25 722.202393 T:1800872864   DEBUG: CecLogMessage - TV (0): power status changed from 'standby' to 'on'

Here I had the TV turned off for about 8 minutes so the screensaver would activate itself. You can't see it in the logs but I tried pressing keys on the TV remote after this line.

Code:
16:27:01 818.986877 T:1961512960   DEBUG: Keyboard: scancode: 0x6c, sym: 0x0112, unicode: 0x0000, modifier: 0x0
I press a key on the regular keyboard and the screensaver is turned off. After that CEC starts working again.

It appears that if I wait for the screensaver to kick in I can press a key on the keyboard and get CEC working, but this only works if the screensaver is activated.

Any ideas?
Issue still exists in beta5 / LibreElec 7.90.008. I had hoped that the new version of LibCEC would fix this...
(2016-11-01, 00:02)Glyphs Wrote: [ -> ]Issue still exists in beta5 / LibreElec 7.90.008. I had hoped that the new version of LibCEC would fix this...

I don't believe LE beta5 uses libCEC 4. You need a Milhouse nightly build for that.
(2016-11-01, 15:52)popcornmix Wrote: [ -> ]
(2016-11-01, 00:02)Glyphs Wrote: [ -> ]Issue still exists in beta5 / LibreElec 7.90.008. I had hoped that the new version of LibCEC would fix this...

I don't believe LE beta5 uses libCEC 4. You need a Milhouse nightly build for that.

I never got around to trying the nightly builds. But now I got LibreElec 7.90.009 with libCEC 4. The issue I still there.

I did find 2 interesting settings for the CEC adapter that I don't know if they have been there before or not:

1. Wake devices when deactivating screensaver
This is enabled, I suspect this is what makes it work if I have the screensaver activated and then use a regular keyboard.

2. When the TV i switched off
This was set to suspend, I tried changing it to ignore (which is the default). But I didn't notice any difference.

Any ideas? Would a new debug log be useful?
Can you grab a log with CEC enabled in component specific debug (using the libCEC 4 build).
Post an issue here for the best chance of the right guy seeing it.
I tried downgrading Kodi to beta 2 which was the one that used to work. (It had trouble finding the LibreELEC 7.90.006 file, but after quite a lot of google search I finally found one outdated mirror since it was removed from the official one)

I reset all Kodi and LibreELEC settings to default, but it still didn't work. Now I think that my TV is to blame somehow. Don't know why it stopped working right after a Kodi upgrade though.... Maybe an unfortunate timing with an auto-update of the TV-firmware. I looked into downgrading, but there isn't any official support for that.

I'm thinking about either buying a wireless keyboard to use instead of the TV remote or do some kind of hack which hijacks one of the HTTP requests the TV makes when booting and use it to toggle the CEC from Kodi.
When I searched the web for more on Samsung and CEC issues I found https://forum.samygo.tv/viewtopic.php?t=11166 and https://forum.libreelec.tv/thread-2387.html

Looks like Samsung is to blame. Sorry for wasting your time, guess my auto-update of the TV just had bad timing.

To bad I can't downgrade :-(
Interesting. Hopefully Samsung will revert the change they made, but from the thread it doesn't sound too promising.

It may still be worth creating a libcec issue with cec log. Explain this was broken following a firmware upgrade of the TV.

CEC is often poorly implemented with the manufacturers giving it a new name (e.g. anynet+) and not promising to work nicely with other CEC devices.

libcec contains a lot of "quirks" where it uses the vendor id to try to work around this.
Now it's quite likely the firmware update hasn't changed the vendor id, so it may or may not be possible to work with both the old and new firmware,
but opdenkamp at libcec may be able to work something out.
I don't have hopes of Samsung fixing anything, though one in France claims to have gotten a fixed 1478 version, so who knows...

It looks there already is an issue created on libcec https://github.com/Pulse-Eight/libcec/issues/264

Here I was thinking CEC was a good standard. I guess the community did a good work covering all its flaws from the end-user.
In case anyone is interested, the latest Milhouse build (#1218), had some differences as to how libcec was built. I tested it, but there was no effect on this issue for me.
Solved by updating my TV to firmware1480, available on Samsung's web page.
(2016-12-20, 22:50)Glyphs Wrote: [ -> ]Solved by updating my TV to firmware1480, available on Samsung's web page.

That's good to hear. Must say I'm a little surprised Samsung responded to this, but fair play to them.