This ESP32-Based PCIe Card Powers on a PC Remotely
Andrea Aghemo came up with something better than Wake-on-LAN: an ESP32-based PCIe card that presses the PC’s power button on request.
You want to turn your PC on, but you’re not nearby to push the power button. What do you do? Wake-on-LAN (WoL) is the typical solution, but it requires a wired Ethernet connection and the right network card, motherboard, and BIOS. Andrea Aghemo came up with a better solution: an ESP32-based PCIe card that presses the PC’s power button on request.
A motherboard’s PCIe slots do not provide full power when the PC is off, but they do provide a little bit of auxiliary power. That auxiliary power is exactly how PCIe network cards provide WoL functionality. For this project, Aghemo took advantage of the same PCIe slots and the same auxiliary power (3.3V on pin B10), but in a way that makes more sense in many modern environments. It doesn’t require Ethernet at all and it doesn’t care if the motherboard or BIOS support WoL.
This works because Aghemo made a custom PCIe card that hosts an ESP32-H2 development board. That consumes very little power, so it can get everything it needs from that 3.3V auxiliary rail. Its firmware “listens” via Zigbee and integrates with Home Assistant. So, a simple Home Assistant command (or scheduled routine) can tell it what to do.
When it gets the command to turn on the PC, the ESP32 pulls the power switch to ground with a MOSFET, simulating a button press and causing the PC to turn on. There are passthrough headers, so the button still functions as normal, too.
As a bonus, the ESP32 can also detect if the PC is already on by simply looking to see if full power is coming in through the PCIe connection. That prevents accidentally pushing the power button when the PC is already on and it also provides a provision for checking if the PC is on, but isn’t connecting to the network for some reason (potentially useful if it isn’t networked at all).
It is an elegant solution that would be useful to many people.
Please log in or sign up to comment.