Kodi Stops when I turn my TV off/on
#1
This has been driving me nuts.  I'm running Oreo on a Shield TV.  I have a thread with 50+ posts on the Shield forum but still no resolution.  
Depending on the circumstances Kodi stops when I turn my TV off or on.  It will also stop when my TV goes to sleep and then wakes.  
This occurs whether or not the Shield goes to sleep.  
I have all of the CEC settings on the receiver (Onkyo TX-NR646), TV (Samsung JS8500), and Shield turned off.  
I have tried Kodi 17.6 from the Play Store, SPMC from the Play Store, and several versions of Leia.  The same thing happens with them all on the Shield.  
If I bypass my receiver and connect the Shield directly to the TV then Kodi doesn't stop when I turn my TV off and on.  
If I connect my W95 streaming box dual booting into LibreELEC and Android 7.1 the same way the Shield is connected the problem doesn't occur.  I can turn the TV off and on and LibreELEC (Kodi) doesn't stop nor do the Android versions of Kodi, SMPC, and MrMC Lite.  So the problem is isolated to the Shield/Kodi combination.  
If I force the TV and receiver to stay awake Kodi doesn't stop.  
If I put the Shield to sleep before I turn off the TV and then wake the Shield before I turn the TV back on then Kodi doesn't stop.  However, Kodi will freeze when Cron jobs try to run while the TV is off.  

Some more gory details.  All items below done in the sequence stated. Shield never went to sleep. 

Receiver passthrough disabled:
TV off then on - Kodi stops when TV is turned on.
Receiver off then on - Kodi doesn't stop.
Switch receiver to different input and then back to Shield - Kodi doesn't stop.
Receiver off, TV off, TV on, Receiver on - Kodi doesn't stop.
Switch receiver to different input, receiver off, TV off, TV on, receiver on, switch receiver input back to Shield - Kodi doesn't stop. 
Switch receiver to different input, TV off, receiver off, receiver on, TV on - Kodi stops when TV turned back on.

Receiver passthrough enabled:
TV off then on - Kodi stops when TV is turned on.
Receiver off then on - Kodi doesn't stop.
Switch receiver to different input and then back to Shield - Kodi doesn't stop.
Receiver off, TV off - Kodi stops. 
Switch receiver to different input, receiver off, TV off - Kodi stops.
Switch receiver to different input, TV off - Kodi stops.

Shield connected directly to the TV bypassing the receiver:
TV off then on - Kodi doesn't stop. 

Playing music in the background doessn't seem to change the results. 

Below is a link to a Kodi log file.  I turned the TV off at about the 12:48 mark where there is the warning about not being able to find the input device.  I turned the TV back on about the 12:49 mark where all the quitting/stopping messages start.  This is on a fresh install of Kodi 17.6 with no add-ons installed.  
https://paste.ubuntu.com/p/Y9G7qwJdgJ/

Any help would be greatly appreciated.
Reply
#2
Giving this a bump and adding some more information.  This is possibly HDCP related.  I moved my Shield HDMI cable from a HDCP 2.2 port on the receiver to a HDCP 1.4 port and Kodi (and SPMC) no longer stops when I turn off my TV.  
I had to reduce the Shield resolution to 1080p because Kodi (Leia alpha 3) was doing some strange things at the 4k settings on this port.  
But I still have some issues in Kodi. 
Kodi shows errors in the log when the Shield screensaver turns on.  
Kodi will freeze if zap2epg is executing when the Shield screensaver turns on. 
If the Shield screensaver is on, Cron will execute but Kodi will freeze when it attempts to run zap2epg.  
Zap2epg runs fine if it completes before the Shield screensaver turns on.  
SPMC doesn't have these problems.
Reply
#3
My Panasonic tv has an option to just turn the display off; might be worth checking your tv settings for this workaround.
Reply
#4
CEC should have been one of those technologies where TV and/or AVR manufacturers couldn't mess up, but they still did IMO. Every involved TV maker has its own implementation of and vision on CEC, and each even gave it its own name... And some of them seem to follow the rules of CEC better than others.

I have an older LG TV, which reacts differently on some power on/power off situations from when I use my Nvidia Shield TV. The same applies when I use a PC machine with a USB-CEC adapter. Why they things differently, I don't know. I'm not a CEC developer/guru myself. I'd have to say the Nvidia Shield TV does CEC support best, but it's not flawless. I still have to turn on my TV first and then the Shield TV, otherwise the Shield gets powered down again once the TV is up...
Reply
#5
The Shield forum informed me on how to turn off the Shield screensaver (its in developer options).  This workaround allows zap2epg run.  
Is this a Shield problem or a Kodi problem?
Reply
#6
My Samsung TV will always switch my receiver input to TV with CEC enabled on the Onkyo receiver.  And it will switch the receiver back to TV if I switch the receiver to a different input.  
Here is my understanding of the HDMI CEC specification (and it probably isn't 100% correct).  The spec is very loose.  It controls how CEC commands are sent and interpreted.  It does not control when and which commands are to be sent.  So when I call Onkyo tech support about the problem they tell me they are complying with the spec by switching the input when the command is sent.  When I call Samsung they tell me that I need to have all Samsung hardware for 100% compatibility.  I know some receiver manufacturers have got around this by having an option in the settings to ignore the switch to TV input command.  I suggested this to Onkyo but it fell on deaf ears.
Reply

Logout Mark Read Team Forum Stats Members Help
Kodi Stops when I turn my TV off/on0