Press power button on PC

Hi. I want a way to turn my PC on and off.
WOL does not have the features I want.
I want my computer to be in a full shutdown, and be able to trigger something in HA, then have either the physical button be pressed to turn on my PC, or have a relay bypass the button, and press the button for me.

What is the best way to do this?
I use Zigbee already, so Aqara’s Relay seems like it would work. What about those “button pusher” things. I can’t find any for Zigbee however.

The Aqara relay would be fine for this.

Note you should script turning the relay on for a brief period for start up / shutdown. Holding the relay on for more than 10 seconds will cause a hardware shutdown. You should not regularly turn off your PC like that.

1 Like

I’m curious about the button requirement. WOL is designed to power on a powered off computer, is it not?

Yeah me too.

Sweet! Ah good to note. I’ll keep that in mind.

Can WOL also power off or put to sleep a computer? I’m running linux, so I can just ssh in to sleep or shutdown.
One thing with WOL, does it work while outside the network, but while vpn’d? I have a wireguard vpn running locally on a server. So I can access my 192 ip locally or remotely.
Also, any good guides for config on linux? I haven’t been able to get WOL working.

It can wake. You can supply an action to turn off (wake or sleep shell command).

Yes. The HA server is sending the commands and that is on your local network.

1 Like

Mmm… Actually, not typically. WOL sends a local broadcast on you LAN only. That packet is not routed, so does not work through a VPN / VLAN / …
There are surely ways to overcome that limitation, but not by default.

But that is not how its working here, he is sending the command to HA via VPN. HA then sends out the packet on the local network.

I have one of these working fine with Z2M

https://www.aliexpress.com/item/1005005957946547.html?spm=a2g0o.order_list.order_list_main.34.76cb1802ID0ajF

It is sent from home assistant which is on the local network. They could connect via telepathy to fire the WoL action for all the HA server cares.

Ah, if that is meant, indeed.
But not if the computer to be awaken is on the other side of the vpn…

If you are still looking for something what about this one:
aliexpress.com/item/1005006090821609.html?

I cannot guarantee it working with Zigbee2Mqtt or ZHA
for the price its roughly 20-25 euro normally, I have seen it in the “Bundle-deals” though at the times I spotted it it was sold out, so keep your eye out for it.

some versions are in the “Discount finder” in the coins section, so when there is a sale discounts can get as high as 20%

I might get one myself later, when I can get it trough the bundle-deals.

or these:

Flashable with Tasmota or ESPHome