DEV Community

Tao Liu
Tao Liu

Posted on • Edited on

1

Win10: disable devices that wake PC

Open powershell as admin

Enter command:
powercfg /devicequery wake_armed | ForEach{ powercfg /devicedisablewake $_ }

You will get back:
Invalid Parameters -- try "/?" for help

To verify, enter command:
powercfg /devicequery wake_armed

You will get back (it means all devices have been disabled):
NONE

You're all set!

Source:
https://superuser.com/questions/1320578/prevent-all-devices-from-waking-my-computer

You can disable all devices from waking your computer with powershell -Command "powercfg /devicequery wake_armed | ForEach{ powercfg /devicedisablewake $_ }".
In cmd, you can run powercfg /devicequery wake_armed to get a list of the devices that are currently allowed to wake up your computer.

Top comments (0)

Qodo Takeover

Introducing Qodo Gen 1.0: Transform Your Workflow with Agentic AI

Rather than just generating snippets, our agents understand your entire project context, can make decisions, use tools, and carry out tasks autonomously.

Read full post

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay