New To The Forum? Click Here To Read The How To Guide. -- Developers Click Here.

Rift preventing Computer from going to sleep

NibreNibre Posts: 51 Poster of the Week
I was trying to setup 'Put the computer to sleep' in my Power Options, but noticed that something is preventing it from actually kicking in. 

By running powercfg -requests in Powershell, I get this;
DISPLAY:
None.

SYSTEM:
[DRIVER] Realtek High Definition Audio (HDAUDIO\FUNC_01&VEN_10EC&DEV_1220&SUBSYS_10438735&REV_1000\5&1e493937&0&0001)
An audio stream is currently in use.
[DRIVER] Oculus VR Headset (USB\VID_2833&PID_0330&MI_00\9&3a680418&2&0000)
An audio stream is currently in use.

AWAYMODE:
None.

EXECUTION:
None.

PERFBOOST:
None.

ACTIVELOCKSCREEN:
None.
So it looks like it may be the Rift keeping it awake. If I manually put the Computer to sleep, it works fine (other than the Headset alert), but timed sleep just refuses to kick in on its own. I don't have any games running or anything, and the headset is put away (still plugged in, but asleep with the Amber light). For reference, I am on Windows 10 1607, and Oculus 1.12.0.347531.

Testing;
If go into Devices->Rift, and change my Audio Output to Rift only (instead of Mirroring), the Realtek entry disappears from powercfg -requests. So that is definitely causing that one. Then, if I close the Oculus app, the Oculus entry disapears too. Timed sleep then starts to work correctly, until the App is opened again.

If I instead leave Audio Mirroring enabled, neither of the entries disappear when I close the Oculus App. In fact, the only thing that seems removes them at that point is manually Stopping the OVRService, or just turning off Audio Mirroring and closing the Oculus App.

Conclusion;
So it appears that there are 2 issues here, due to Audio Streams.
  • Issue 1 - Having the Oculus App running, while the Headset is dormant and no VR is active, prevents timed sleep until the App is closed. (This may be intentional, but can be pretty annoying. It should let it sleep if nothing's currently happening, and prevent it when it needs to)
  • Issue 2 - Having Audio Mirroring enabled prevents timed sleep from happening whatsoever, until the OVRService is Stopped or Mirroring is disabled. (Seems to be because Mirroring continues to work after the App is closed. It'd be nice if it still allowed sleep to work somehow. Maybe add an option to only Mirror if VR things are happening, instead of 24/7?)
Partial Fix;
I've had mixed luck getting powercfg -requestsoverride to make it ignore the Audio Streams.
By using this, it will sometimes work after a Reboot, but doesn't seem to consistently work after that. Very hit and miss for me.
powercfg -requestsoverride DRIVER "Realtek High Definition Audio" SYSTEM
powercfg -requestsoverride DRIVER "Oculus VR Headset" SYSTEM


Figured I'd post this here to give you guys a heads up, or see if I'm missing something. Thanks!

Comments

  • TwoHedWlfTwoHedWlf Posts: 1,844 Poster of the Week
    Make sure you close Oculus Home.  I find if it's on it won't let my PC sleep(Or keeps waking it up after a while, hours even.  How?  I don't know)  But if it's closed before putting it to sleep, it's fine.
  • cyberealitycybereality Posts: 23,033 Oculus Staff
    My computer won't stay asleep for more than an hour or two. I'm sure I've disabled everything that I could find. I wonder if this issue you mention is the reason.
    AMD Ryzen 7 1800X | MSI X370 Titanium | G.Skill 16GB DDR4 3200 | EVGA SuperNOVA 1000 | Corsair Hydro H110i
    Gigabyte RX Vega 64 x2 | Samsung 960 Evo M.2 500GB | Seagate FireCuda SSHD 2TB | Phanteks ENTHOO EVOLV
  • TwoHedWlfTwoHedWlf Posts: 1,844 Poster of the Week
    edited March 23
    My computer won't stay asleep for more than an hour or two. I'm sure I've disabled everything that I could find. I wonder if this issue you mention is the reason.
    Have you tried end tasking all the oculus tasks before putting it to sleep?  I seriously don't see how a running application could cause it to wake up after it's been asleep a while but that does seem to be the case.  Maybe sleeping computers dream and Oculus Home gives them nightmares?
  • weasel47weasel47 Posts: 299
    Nexus 6
    My computer also wakes up after being asleep for a little while.  I usually shut it down instead of putting it to sleep.  Even crazier, sometimes it even turns itself back on immediately after I tell it to shut down!  Could it have something to do with HDMI or USB?  I know a sleeping computer can be woken up with a mouse wiggle or keystroke, so maybe a USB or HDMI disconnect / reconnect is occurring and triggering the same thing.
  • danybonindanybonin Posts: 30
    Brain Burst
    If the computer wakes up, its because he have sleeped enought. Don't try to force him to sleep if he is not tired...
  • DimebonixDimebonix Posts: 1
    NerveGear
    edited September 13
    weasel47 said:
    My computer also wakes up after being asleep for a little while.  I usually shut it down instead of putting it to sleep.  Even crazier, sometimes it even turns itself back on immediately after I tell it to shut down!  Could it have something to do with HDMI or USB?  I know a sleeping computer can be woken up with a mouse wiggle or keystroke, so maybe a USB or HDMI disconnect / reconnect is occurring and triggering the same thing.
    Sounds like some poltergeist shit to me.

    In all seriousness, I happened upon this page for the exact same reason. So what are we concluding is the most reasonable fix at this time? Just ending the OVRservice process in the task manager? That could be a pain in the butt having to do that every time.
Sign In or Register to comment.