Solved Powershell Question


Catnip

Forum Nitwit
Power User
VIP
Local time
8:56 PM
Posts
838
OS
Win 11 Pro 25H2
Okay, stupid question time:

I'll preface by saying that I am not that well versed in Powershell.

I have a device, an integrated circuit, which presents itself as a HID device. It is configured to wake the computer when a button is pressed. In Windows, I have tried to set the power configurations in Device Manager, but the option to wake the computer is greyed out. Are there not power setup commands in Powershell? I have to have this thing wake the computer for the project to work. It just currently won't and there seems to be no way to set it.

I throw myself on the pile of "Gee whiz I need help."

TIA
 
Windows Build/Version
25H2 Win 11 Pro

My Computer My Computer

At a glance

Win 11 Pro 25H2Intel i7 13700KF32 GB Team Group DDR5 - 6000 CL 30ASUS TUF GAMING RTX 3070 Ti
OS
Win 11 Pro 25H2
Computer type
PC/Desktop
Manufacturer/Model
Self build
CPU
Intel i7 13700KF
Motherboard
Gigabyte Z790 UD AC
Memory
32 GB Team Group DDR5 - 6000 CL 30
Graphics Card(s)
ASUS TUF GAMING RTX 3070 Ti
Sound Card
On board Realtek
Monitor(s) Displays
ACER 34 inch
Screen Resolution
Not 4K like I thought. 35" wide though.
Hard Drives
1 TB Samsung 980 Pro Nvme, 1 TB Samsung 970 EVO Nvme, 2 x Samsung 970 2TB SSD SATA
PSU
EVGA 1000Q
Case
Rosewill something or other
Cooling
Noctua NH-D15. A whole schwak of Noctua case fans. $$$
Keyboard
Logitech G815
Mouse
Logitech G502 Hero
Internet Speed
700 up, 600 down
Browser
Firefox
Antivirus
MalwareBytes
You're looking for the MSPower_DeviceWakeEnable class in the root\WMI namespace.

This is how you would turn off waking the computer for every device, which is not what you want but an example of using the class.

Powershell:
Set-CimInstance -Query 'SELECT InstanceName FROM MSPower_DeviceWakeEnable WHERE (Enable = True)' -Namespace 'root\WMI' -Property @{Enable = $false}
 

My Computer My Computer

At a glance

Windows 11 Enterprise 25H2
OS
Windows 11 Enterprise 25H2
Just out of curiosity, how is this thing connected to the PC ? Through USB port or serial port or other ways ?
 

My Computers My Computers

  • At a glance

    Windows 11 Pro build 26200.8524Intel i7-4790Teams DDR3-1600 4x4 GBMSI Nvidia GeForce GTX 1050Ti
    OS
    Windows 11 Pro build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Built
    CPU
    Intel i7-4790
    Motherboard
    Asus H97 Pro Gamer with add-on TPM1.2 module
    Memory
    Teams DDR3-1600 4x4 GB
    Graphics Card(s)
    MSI Nvidia GeForce GTX 1050Ti
    Sound Card
    Realtek ALC1150
    Monitor(s) Displays
    Dell P2425D
    Screen Resolution
    2560 by 1440 pixels
    Hard Drives
    Corsair NVMe M.2 Core XT 1000 GB (Windows 11 v.25H2); Samsung SATA Evo 870 500 GB (Windows 11 v.25H2);
    PSU
    Corsair HX850
    Case
    Gigabyte Solo 210
    Cooling
    Zalman CNPS7X Tower
    Keyboard
    Microsoft AIO Wireless (includes touchpad)
    Mouse
    HP S1000 Plus Wireless
    Internet Speed
    500 Mb fiber optic
    Browser
    Chrome; MS Edge
    Antivirus
    Windows Defender
  • At a glance

    MacOS 12 MontereyIntel Core i58 GBIntel integrated
    Operating System
    MacOS 12 Monterey
    Computer type
    Laptop
    Manufacturer/Model
    Apple Macbook Air
    CPU
    Intel Core i5
    Memory
    8 GB
    Graphics card(s)
    Intel integrated
    Screen Resolution
    1440 by 900 pixels
    Hard Drives
    128 GB
    Keyboard
    Built-in
    Mouse
    Microsoft Wireless
    Internet Speed
    802.11 ac
    Browser
    Chrome; Safari
    Antivirus
    N/A
Just out of curiosity, how is this thing connected to the PC ? Through USB port or serial port or other ways ?
It's attached via a USB port. I am not using the serial port function on this IC. It is enumerating as a HID device.

@pseymour I will give that a try and report back.
 

My Computer My Computer

At a glance

Win 11 Pro 25H2Intel i7 13700KF32 GB Team Group DDR5 - 6000 CL 30ASUS TUF GAMING RTX 3070 Ti
OS
Win 11 Pro 25H2
Computer type
PC/Desktop
Manufacturer/Model
Self build
CPU
Intel i7 13700KF
Motherboard
Gigabyte Z790 UD AC
Memory
32 GB Team Group DDR5 - 6000 CL 30
Graphics Card(s)
ASUS TUF GAMING RTX 3070 Ti
Sound Card
On board Realtek
Monitor(s) Displays
ACER 34 inch
Screen Resolution
Not 4K like I thought. 35" wide though.
Hard Drives
1 TB Samsung 980 Pro Nvme, 1 TB Samsung 970 EVO Nvme, 2 x Samsung 970 2TB SSD SATA
PSU
EVGA 1000Q
Case
Rosewill something or other
Cooling
Noctua NH-D15. A whole schwak of Noctua case fans. $$$
Keyboard
Logitech G815
Mouse
Logitech G502 Hero
Internet Speed
700 up, 600 down
Browser
Firefox
Antivirus
MalwareBytes
Please also check Advanced Power Options to see if you can enable a setting there to help you wake your PC
 

My Computers My Computers

  • At a glance

    Windows 11 Pro build 26200.8524Intel i7-4790Teams DDR3-1600 4x4 GBMSI Nvidia GeForce GTX 1050Ti
    OS
    Windows 11 Pro build 26200.8524
    Computer type
    PC/Desktop
    Manufacturer/Model
    Home Built
    CPU
    Intel i7-4790
    Motherboard
    Asus H97 Pro Gamer with add-on TPM1.2 module
    Memory
    Teams DDR3-1600 4x4 GB
    Graphics Card(s)
    MSI Nvidia GeForce GTX 1050Ti
    Sound Card
    Realtek ALC1150
    Monitor(s) Displays
    Dell P2425D
    Screen Resolution
    2560 by 1440 pixels
    Hard Drives
    Corsair NVMe M.2 Core XT 1000 GB (Windows 11 v.25H2); Samsung SATA Evo 870 500 GB (Windows 11 v.25H2);
    PSU
    Corsair HX850
    Case
    Gigabyte Solo 210
    Cooling
    Zalman CNPS7X Tower
    Keyboard
    Microsoft AIO Wireless (includes touchpad)
    Mouse
    HP S1000 Plus Wireless
    Internet Speed
    500 Mb fiber optic
    Browser
    Chrome; MS Edge
    Antivirus
    Windows Defender
  • At a glance

    MacOS 12 MontereyIntel Core i58 GBIntel integrated
    Operating System
    MacOS 12 Monterey
    Computer type
    Laptop
    Manufacturer/Model
    Apple Macbook Air
    CPU
    Intel Core i5
    Memory
    8 GB
    Graphics card(s)
    Intel integrated
    Screen Resolution
    1440 by 900 pixels
    Hard Drives
    128 GB
    Keyboard
    Built-in
    Mouse
    Microsoft Wireless
    Internet Speed
    802.11 ac
    Browser
    Chrome; Safari
    Antivirus
    N/A

My Computer My Computer

At a glance

Win 11 Pro 25H2Intel i7 13700KF32 GB Team Group DDR5 - 6000 CL 30ASUS TUF GAMING RTX 3070 Ti
OS
Win 11 Pro 25H2
Computer type
PC/Desktop
Manufacturer/Model
Self build
CPU
Intel i7 13700KF
Motherboard
Gigabyte Z790 UD AC
Memory
32 GB Team Group DDR5 - 6000 CL 30
Graphics Card(s)
ASUS TUF GAMING RTX 3070 Ti
Sound Card
On board Realtek
Monitor(s) Displays
ACER 34 inch
Screen Resolution
Not 4K like I thought. 35" wide though.
Hard Drives
1 TB Samsung 980 Pro Nvme, 1 TB Samsung 970 EVO Nvme, 2 x Samsung 970 2TB SSD SATA
PSU
EVGA 1000Q
Case
Rosewill something or other
Cooling
Noctua NH-D15. A whole schwak of Noctua case fans. $$$
Keyboard
Logitech G815
Mouse
Logitech G502 Hero
Internet Speed
700 up, 600 down
Browser
Firefox
Antivirus
MalwareBytes

Latest Support Threads

Back
Top Bottom