20

Background

I have been having issues with my computer not entering sleep and also waking from sleep since Window 8.1. I had hoped that Windows 10 would resolve these issues, but unfortunately this is not the case. I had noticed that the problem would occur whenever my headset (Hyper X Cloud II) was plugged in, but it was not exclusively occurring when plugged in.

I recently got extremely fed up with my computer waking from sleep very consistently and decided once again to try and solve the problem.

Attempted Fixes

To start off, in Power Management:

  • Disabled wake timers
  • Enabled USB selective suspend
  • Set the computer sleep time to 1 minute of inactivity to see if any changes had an effect

To identify the cause of what's keeping the computer from waking I used powercfg in an elevated command prompt:

powercfg -requests

Which returns the following:

SYSTEM:
[DRIVER] Realtek High Definition Audio (HDAUDIO\FUNC_01&VEN_10EC&DEV_0892&SUBSYS_1043860B&REV_1003\4&165326bb&0&0001)
An audio stream is currently in use.
[DRIVER] USB Audio Device (USB\VID_0951&PID_16A4&MI_00\6&3321d09b&1&0000)
An audio stream is currently in use.
[DRIVER] Legacy Kernel Caller

What I had noticed with my headset was confirmed by the USB Audio Device entry under system. If I unplugged my headset, both the USB Audio Device and the Legacy Kernel Caller entries were gone upon running powercfg -requests again.

The problem still persisted after unplugging the headset. So I then ran the following command to prevent the Realtek High Definition Audio driver from preventing sleep.

powercfg -REQUESTSOVERRIDE DRIVER "Realtek High Definition Audio" SYSTEM

This did in fact allow my computer to enter sleep. Upon plugging in my headset again, the problem came back. So naturally I executed REQUESTSOVERRIDE again for the related headset drivers:

powercfg -REQUESTSOVERRIDE DRIVER "USB Audio Device" SYSTEM
powercfg -REQUESTSOVERRIDE DRIVER "Legacy Kernel Caller" SYSTEM

Unfortunately this did not fix the problem. To ensure that my REQUESTSOVERRIDE command took effect I ran:

powercfg -REQUESTSOVERRIDE

Which did show that my override requests were in effect:

[DRIVER]
Realtek High Definition Audio SYSTEM
USB Audio Device SYSTEM
Legacy Kernel Caller SYSTEM

After this I tried:

  • Using Device Manager and ensuring every USB port was permitted to turn off devices in order to enter sleep
  • Uninstalling the Hyper X Cloud II device and reinstalling
  • Confirming the powercfg -requests entries with powercfg -energy report
  • Control Panel -> Sound -> Headset Earphone-> Advanced and unticked "Allow applications to take exclusive control of this device"

TL;DR

How can I prevent my USB Audio Device (in this case Hyper X Cloud II Headset) from preventing my computer to enter sleep?

I have used powercfg -REQUESTSOVERRIDE to remove all entries that come up in powercfg -requests and ensured in Device Manager that all USB ports are able to turn off devices to allow the computer to sleep.

spenser_l
  • 301

9 Answers9

10

I have had that problem but solved it entirely, here are the steps:

NOTICE: I have an older HP laptop, after applying these steps I did set the computer to go to sleep after 1 minute then the screen turned off after 1 minute, BUT for the computer to go into sleep mode actually took around 3 to 4 minutes to actually enter sleep mode. That's because Windows services/processes and applications have to finish their work on my older laptop.

IMPORTANT: After finishing this procedure and running all the commands and adding all request overrides it is important to restart the computer.


Follow these steps:

Open up Group Policy Editor by clicking the Start menu and typing edit group policy, and open up the Group Policy Editor.

How to open Group Policy Editor

In the Group Policy Editor do the following:

Click: Computer Configuration
Click: Administrative Templates
Click: System
Click: Power Management
Click: Sleep Settings

Once in Sleep Settings change the following settings:

Example: find the 'Allow applications to prevent automatic sleep (plugged in)' setting and change it to DISABLED. Below is a list of all the settings that need to be changed in the Group Policy Editor. You may not have all those setting entries, or wording may differ.

Allow applications to prevent automatic sleep (plugged in) DISABLED Allow applications to prevent automatic sleep (on battery) DISABLED Turn on the ability for applications to prevent sleep transitions DISABLED Allow standby states (S1-S3) when sleeping (plugged in) ENABLED Allow standby states (S1-S3) when sleeping (on battery) ENABLED

After changing those settings in the Group Policy Editor you must restart the computer.


Now for the rest of this you'll need to open up the Windows 'command prompt'.

To open the 'command prompt' click on the 'Start' menu and type 'command prompt', then click on the 'command prompt' app and open it.

How to open Command Prompt

In the command prompt you'll be running a command called powercfg.exe

Type this at the command prompt:

powercfg.exe -requests

When I type that at my command prompt while listening to YouTube on Microsoft Edge browser I get the following output:

C:\Windows\system32>powercfg -requests
DISPLAY:
[PROCESS] \Device\HarddiskVolume2\Program Files (x86)\Microsoft\Edge\Application\msedge.exe
Video Wake Lock

SYSTEM: [DRIVER] Realtek High Definition Audio (HDAUDIO\FUNC_01&VEN_10EC&DEV_0282&SUBSYS_103C8074&REV_1000\4&209dcc63&0&0001) An audio stream is currently in use.

AWAYMODE: None.

EXECUTION: [PROCESS] \Device\HarddiskVolume2\Program Files (x86)\Microsoft\Edge\Application\msedge.exe Playing audio

PERFBOOST: None.

ACTIVELOCKSCREEN: None.

So as soon as I open up the Edge browser and listen to YouTube, after running the powercfg.exe -requests the above output says that:

  1. There's msedge.exe under DISPLAY, and it is also under EXECUTION
  2. and, also there's my Realtek High Definition Audio under SYSTEM

So when I have Ms Edge browser open with YouTube running, I then run powercfg -requests command and msedge.exe appears under DISPLAY and EXECUTION. Also while listening to YouTube, the Edge browser uses the Realtek High Definition Audio and it appears under SYSTEM.

Therefore, I add the High Definition Audio and Edge browser to requestsoverrides, like so:

I made sure to add the Realtek High Definition Audio in several ways:

powercfg.exe -requestsoverride DRIVER "Realtek High Definition Audio (HDAUDIO\FUNC_01&VEN_10EC&DEV_0282&SUBSYS_103C8074&REV_1000\4&209dcc63&0&0001)" SYSTEM DISPLAY AWAYMODE
powercfg.exe -requestsoverride DRIVER "HDAUDIO\FUNC_01&VEN_10EC&DEV_0282&SUBSYS_103C8074&REV_1000\4&209dcc63&0&0001" SYSTEM DISPLAY AWAYMODE
powercfg.exe -requestsoverride DRIVER "*Realtek*" SYSTEM DISPLAY AWAYMODE

Look at the last line and notice "*Realtek*" has ' * ' on both sides, that's to ensure that any requests with word "Realtek" will be ignored.

And also for my Edge browser I added requestsoverride entries in two different ways, like so:

powercfg.exe -requestsoverride PROCESS "\Device\HarddiskVolume2\Program Files (x86)\Microsoft\Edge\Application\msedge.exe" SYSTEM DISPLAY AWAYMODE EXECUTION
powercfg.exe -requestsoverride PROCESS "msedge.exe" SYSTEM DISPLAY AWAYMODE EXECUTION

When I run the command powercfg.exe -requestsoverride at the command prompt here's the output, and that is how I have it configured:

[SERVICE]

[PROCESS] \Device\HarddiskVolume2\Program Files (x86)\Microsoft\Edge\Application\msedge.exe DISPLAY SYSTEM AWAYMODE EXECUTION \Device\HarddiskVolume2\Users\Robert\AppData\Roaming\Spotify\Spotify.exe DISPLAY SYSTEM AWAYMODE EXECUTION Spotify.exe DISPLAY SYSTEM AWAYMODE EXECUTION msedge.exe DISPLAY SYSTEM AWAYMODE EXECUTION

[DRIVER] Realtek High Definition Audio (HDAUDIO\FUNC_01&VEN_10EC&DEV_0282&SUBSYS_103C8074&REV_1000\4&209dcc63&0&0001) DISPLAY SYSTEM AWAYMODE Realtek DISPLAY SYSTEM AWAYMODE HDAUDIO\FUNC_01&VEN_10EC&DEV_0282&SUBSYS_103C8074&REV_1000\4&209dcc63&0&0001 DISPLAY SYSTEM AWAYMODE Legacy Kernel Caller DISPLAY SYSTEM AWAYMODE

And as you can see from that output I also have added the Spotify music app to my request overrides, and once I also noticed that there was Legacy Kernel Caller, so I also added it to request overrides.

After adding all request overrides and restarting your computer set your computer sleep time at 1 minute and see if it goes to sleep after one minute.

NOTICE: I have an older HP laptop, and when I did set the computer to go to sleep after 1 minute then the screen turned off after 1 minute, BUT for the computer to go into sleep mode actually took around 3 to 4 minutes to actually enter sleep mode. That's because Windows services/processes and applications have to finish their work on my older laptop.

1

I just realized that turning off Cortana's "always listening" feature seems to fix the problem.

Ben N
  • 42,308
Movieboy
  • 121
0

For me, Realtek was fixed by disabling "Line In" under Sound > Recording. I have the Cloud II's as well and might return if I can fix that.

0

I had the same issue, tried every thing you tried too to no avail and I got it fixed by turning off instant replay for recording the desktop in Nvidia GEFORCE EXPERIENCE

you can do that by:

  1. Opening in-game oreverlay by pressing Alt+Z (default shortcut)

OR

  1. Opening Geforce Experience

  2. Clicking the triangular icon (in-game oreverlay)

  3. Click the settings icon which looks like a cog. You have to turn off instant replay to be able to access the setting for recording the desktop

  4. Go all the way down to “Privacy Control”

  5. Turn off "Destop capture"

I hope this helps

0

I was having a similar problem. Running power -requests revealed that my realtek hd audio driver was preventing sleep mode as it was in use. I didn't want to override the driver as other have suggested. I actually found the problem was my gaming headset. After experimenting I found my mic was always on in the straight up position. Moving the mic wand just a bit turn off the mic. Now my PC goes to sleep as ordered!

Paul
  • 1
0

I had the same problem, with RealTek audio driver preventing sleep (from POWERCFG -REQUESTS). In my case the culprit was Cisco WEBEX. Even though the app was closed, there were background Webex processes still running (as seen in Task Manager). Ending these background processes cleared that flag in POWERCFG.

0

I had the same problem. I tried all the solutions I found online and nothing worked. I fixed it by accident while fixing a high CPU usage problem. The problem in task manager was "audiodg.exe Windows Audio Device Graph Isolation"

The solution was. 1. Go to the control panel. 2.Make the icons large 3. Click on Sound. This will bring up a new window containing all of your playback devices. 4.Right-click on your speakers, then select Properties from the menu. 5.Another window will open. Here, switch to the Enhancements tab. 6. Click the box next to Disable all sound effects to place a checkmark. When you’re done, press the Apply button. 7. Restart the computer.

After a few hours I restarted the process because I missed my equalizer. That night I noticed my computer had gone into sleep mode for the first time in a year. Sleep mode has been working perfectly for several days now.

0

I had the same problem with the RealTek audio driver preventing sleep (from POWERCFG -REQUESTS). In my case the culprit was Zoom. Even though I wasn't signed in, the app was running in the system tray. Quitting Zoom cleared that flag in POWERCFG.

bargz
  • 101
  • 1
-1

Same problem.

[DRIVER] USB Audio Device (USB\VID_10F5&PID_0296&MI_00\6&13d026f7&0&0000) An audio stream is currently in use.
But I don't think the audio driver is the problem. The problem is that an application is holding an audio stream open, even when it is not outputting audio.

Done some testing while spamming "powercfg /REQUESTS" while running different programs. Normally If a program is outputting an audio stream, then the sound driver makes a request to not allow the PC to sleep automatically. Then when the sound stops, the stream is closed, and then the driver stops requesting to hold sleeping.

In my case, however, a tab in Firefox 63.0.1 (64-bit) seems to be at fault. mega.nz site was constantly keeping an audio stream open, even when there was nothing audio related on the page.

Here you can see this bug in action.

Exhibit A. Browser open. No requests to hold sleep active.

Exhibit B. On home page of mega. No requests to hold sleep active.

Exhibit C. After log in. There is now an audio stream active. There is no audio file in this directory, nor is there any sound coming from the page.

Exhibit D. Setting the tab to mute and moving away from it still leaves the audio stream active.

Exhibit E. After closing the mega tab. audio stream no longer active. No requests to hold sleep active.

Try and find the program responsible for keeping its audio stream active, even when it is not producing sound.