Win Black screen after wake-up from standby
#16
(2018-06-05, 08:15)aderlopas Wrote: Thanks, but how does the executable work? 
I run it and it does nothing.
I put it in shellConfusedtartup and does not solve the issue.
Is it a service?
Does it have to be scheduled to run?
Can you provide some more details on "RestoreWindows.exe"?

Regardless of the workarounds which are not acceptable in my case, will Kodi team get that issue fixed?
The source code is available on github. But in summary it logs the position (placement, size, z order etc) of every window every second. As soon as there's a change in display (sleep / monitor off etc) it stores those values and waits until the corresponding "wake up". At that point it restores every window to its former position and size and also wakes the screen up. It does that by programmatically pressing the windows key twice. It's not exactly elegant, but it works for me.

It isn't technically a service, no, but you need to run it at start up (or at least before you turn the monitor off). It doesn't do anything visible at all - it just runs in the background... you should see it in Task Manager. Like you, I put it in shell: startup
Reply
#17
Same problem for me, when turning my screen off & on again.
RestoreWindows.exe does help (Thanks!), but I would love to have a proper solution from the Kodi team...
Reply
#18
(2018-06-09, 11:53)shlomki Wrote: Same problem for me, when turning my screen off & on again.
RestoreWindows.exe does help (Thanks!), but I would love to have a proper solution from the Kodi team...
Yes an official fix would be great. Restorewindows does not restore audio unfortunately...so my screen is restored but no audio...
Reply
#19
It does help, however, not in combination with change refresh rate Sad
Win 8.1 64bit
NUC5i5RYK, Onkyo TX508, LG 42LM620T
Reply
#20
Is there any update on this issue?
Reply
#21
Not that I know, just several threads reporting the issue.
Reply
#22
Same issue here, thought I found out one thing: if my TV is off when I wake the HTPC, Kodi shows up normally. Tried both use full screen and full window option, same issue.

Using Windows Store version along with Windows 10 1809.
Reply
#23
The only reliable fix for me was to create a scheduled PC reboot one hour before normal viewing time and since I use sleep mode, a fairly large (sleep after 3 hours) setting. I tried just wake from sleep, but that does not refresh the screen. Since we view at a different time on the weekends, I created a second schedule for weekends (same instructions with different trigger time). This has worked flawlessly for over a year.
Reply
#24
(2018-06-05, 08:21)aderlopas Wrote: Note that my current workaround is to use Launcher4Kodi and specify:

1. Kodi to close during Suspend
2. Kodi to start when resuming from Sleep

As you understand, if I pause a movie or TV and in the meantime HTPC goes to sleep then I have lost the movie/TV episode I'm watching so not acceptable workaround.

We need a fix for that please Kodi team.

Sadly i have had the same issue. I have had it since Kodi 17. Some installs seemed to solved the problems in the past. I can't remember how or why (also because i remember fiddling a LOT to get it working well, including going into Windows test mode to change the monitor.inf file) but i was running for a year or so without issues untill the last Windows fall update.

It's sad because Kodi is awesome, but this black screen issue keeps comming back. Sad

I hope the Kodi team can make a permanent fix for this or give us an option in the settings to prevent this issue.

Win 10
Leia 18 (all, except the nightlies)
Intel graphics

Does anyone know if the Kodi team is busy looking at this issue or not? Or how to monitor the status regarding this issue? It seems to effect a lot of people.
Reply
#25
Love how some pile on Kodi when the issue might be in their own equipment. https://answers.microsoft.com/en-us/wind...h=1&page=1 A simple Google search with the term "screen stays black after waking computer from sleep mode" turns up 17 million pages. The MS forum has been locked for some time, this a known issue with windows. I suspect that various graphic engines have different addressing and might be the root of the irregular nature of the issue. If work rounds are insufficient, try some of these solutions. 

This works for some, but not all.

Solution 1 – Turn off Hibernation
Solution 2 – Power Options, “Turn on Fast Startup”  off; and restart your PC twice!
Solution 3 – Network settings, adapter settings, Internet adapter properties, Configure, Advanced, Wake on Magic Packet and Wake on Pattern Match, off
Solution 4 – Update graphics card driver
Solution 5 - Windows key + Ctrl + Shift + B. sometimes restarts the graphics driver
Solution 6 – Update BIOS
Solution 7 – Disable Sleep mode
(2019-04-17, 09:11)Lemon79 Wrote: Does anyone know if the Kodi team is busy looking at this issue or not?
MS has been apprised of the issue.
Reply
#26
(2019-04-18, 18:17)PatK Wrote: Love how some pile on Kodi when the issue might be in their own equipment. https://answers.microsoft.com/en-us/wind...h=1&page=1 A simple Google search with the term "screen stays black after waking computer from sleep mode" turns up 17 million pages. The MS forum has been locked for some time, this a known issue with windows. I suspect that various graphic engines have different addressing and might be the root of the irregular nature of the issue. If work rounds are insufficient, try some of these solutions. 

This works for some, but not all.

Solution 1 – Turn off Hibernation
Solution 2 – Power Options, “Turn on Fast Startup”  off; and restart your PC twice!
Solution 3 – Network settings, adapter settings, Internet adapter properties, Configure, Advanced, Wake on Magic Packet and Wake on Pattern Match, off
Solution 4 – Update graphics card driver
Solution 5 - Windows key + Ctrl + Shift + B. sometimes restarts the graphics driver
Solution 6 – Update BIOS
Solution 7 – Disable Sleep mode
(2019-04-17, 09:11)Lemon79 Wrote: Does anyone know if the Kodi team is busy looking at this issue or not?
MS has been apprised of the issue. 
Hi PatK,

Thx for the update!

I'm not here to pile on Kodi since it's a great project. What i think is the reason for people targetting Kodi instead of MS/Windows that (at least in my case) the HDMI-handshaking/Black-screen issue only happens in Kodi after HDMI source switching. The black screen issue does NOT happen in windows or any other windows application.

I've tried all your mentioned 7 options and would like to add a few that didn't work for me:
- Turning off hardware acceleration in Kodi.
- Fideling with screensaver in Kodi.
- Switching to windowed mode (which solves the problem completely but i DONT want to watch in windowed mode).
- Updating to Kodi 18.2 and a clean new install to Kodi 18.2 (still black screen, like all other versions since Kodi 17, 32-or 64 bit).
- Cleaning Kodi cache, removing all addons en trying a non-default skin.
- Cleaning Windows cache.

It's very nice to hear some feedback about communication with MS. I understand that the problem may be caused by the Windows Fall Creators Update, but it would be nice to get some updates/status info regarding this topic in relation to MS.
Reply
#27
(2019-04-30, 14:17)Lemon79 Wrote: The black screen issue does NOT happen in windows or any other windows application.
And windowed mode works fine... then hitting the \ to go full screen is the issue and your screen goes black? Which would mean if you have desktop on the TV with HDMI, then the issue is NOT HDMI source switching. But full screen vs windowed mode and that might be more telling with a proper debug log posted to a public pastebin and that URL linked back to this thread.
Reply
#28
I've been battling this problem for a decade. The problem is a loss of HDMI EDID info when the connected TV turns off. If you remote into your PC via VNC you will see that the TV disappears from the device list when it is turned off and Win 10 will then render to a dummy monitor instead. I have managed to fix this in the past using a Dr HDMI device to store the TV's EDID info by sitting between my PC and my TV. Unfortunately I haven't been able to get this to work permanently on my new PC which is using an AMD APU while prior it was an Nvidia PCIe Card.

Kodi doesn't handle this dummy monitor very well if it is rendering in full screen at the time and will often result in a weird looking compressed or stretched out display because the dummy monitor doesn't match the TV's resolution. If Kodi loads with the TV off it will then distort when the TV turns on. This can be fixed by toggling full screen by pressing the \ key twice or closing and the reopening Kodi.

Via VNC you can change the virtual display's resolution but for some reason it maxs out at something like 1680x1050. There are some registry hacks posted online to enable higher resolutions but I couldn't get them to work. What did work was fooling the PC into thinking there was a monitor connected to the VGA port by adding resistors as per this link https://www.geeks3d.com/20091230/vga-hac...ummy-plug/

You can then force this fake display to render at higher resolutions to match your TV. Interestingly, even after removing the dummy plug, you can then choose the same resolution on Win 10s original display. Now that both your TV's and dummy monitor's resolutions match you won't get that weird full screen distortion any more.

The final fix is to use Eventghost to toggle full screen automatically everytime it detected your TV turning off and on. This is what my set-up looks like and it works perfectly! This works better than Launcher4Kodi closing and reopening Kodi on sleep / wake as this display changing can occur at other times too.

https://imgur.com/a/TBPgf9w

The first convoluted step to match the resolutions is probably not necessary but it is nice to have the resolution never change.

Hope this helps someone from pulling their hair out in future! It would be great if Kodi could be programmed to sort this out itself as it detects the display is changing according to the logs.
Reply
#29
Log doesn't seem useful.  This is a fresh Kodi install on my laptop, used portable data folder so as to not mess with my normal kodi installation, and so you don't have plugin spam.

https://paste.kodi.tv/foyuxayefe.kodi

I started Kodi, waited for initialization tasks to complete, then pressed the "HandleKey: right (0xf083)" when I started testing sleep.
Sleep behaved correctly one or two times. After successful wake from sleep, I pressed the "HandleKey: up (0xf080)" one or more times,
and then after it was black screen instead, I pressed "HandleKey: down (0xf081)" several times to ensure it registered in the log and was easy to find.

Thing is, looking at it, and this is debug mode with window and video components set to debug too... What can I do to get a more detailed log?  From what I see, normal sleep / wake and the broken sleep / wake looked the same, log-wise.  Am I missing something?
Reply
#30
@Leafchip 

follow along with this thread https://forum.kodi.tv/showthread.php?tid=138652 perhaps an explanation and solve is buried within.
Reply

Logout Mark Read Team Forum Stats Members Help
Black screen after wake-up from standby1