HubAction to make WOL requests

Any chance this functionality can be added. I have an ST smartApp that lets me wake my pc when I enter my office. Would love to move this over to Hubitat. What is the likelihood of this @patrick?

See ST app below as an example:

1 Like

WOL shouldn't be too tough. Haven't looked into sending a magic packet... Doesn't appear that the above app actually does this though. Maybe ST made WOL into a method?

sendHubCommand(new physicalgraph.device.HubAction (
    "wake on lan ${newMac}",

all that seems to be doing is sending the text "wake on lan {mac}" to the device. This must be getting trapped by ST to then actually create the magic packet to do WOL.

Someone could probably just do the packet forming and just send the magic packet to the MAC today inside Hubitat... Otherwise, I can add this "wake on lan {mac}" trapping in the sendHubCommand LAN portion to the feature request list.

I seem to recall another method for WOL at some point that someone came up with that did the magic packet stuff. That might be easier to port over and should just work.

I did a scan through the ST forums but only found the same solution I’m using, Core or a man in the middle solution. If you can point me to the method you mentioned that would be appreciated. Otherwise, I know it won’t be high on the priority list but adding the sendHubCommand to the feature request list would be great.

1 Like

Latest update adds Wake On Lan (WOL) functionality


All I can say is…WOW!!
Did not expect this so soon. You guys rock!!! :metal:

You just put another small shovel full of dirt on my ST hub.


How is this implemented? Do I need to load the smartthings app?

No, I posted that as an example so they could see how I implemented this in smartthings. I will post my Hubitat smartApp shortly.

  1. Create a Virtual Switch and set the auto-off to 1 sec (it essentially acts as a momentary switch).
  2. Install the app below.
  3. Select the Momentary switch you just created.
  4. Enter the Mac address (no spaces, dashes or colons) of the device you want to WOL.

Now you can add this switch to any automatons you need... eg when I open my office door, the lights come on and my pc wakes from sleep.

See link to app code below:



I loaded this up today but am unable to get it to wake my pc. I have confirmed that the pc responds to wol from webcore. Any suggestions?

If I remember correctly, the mac address needs to be letters and numbers only. Remove any ":" or "-"'.

1 Like

Thanks @stephack

Turned out to be windows settings - go figure.

The app works perfectly. Thank you..

1 Like

@stephack tank you very much for your app. I have followed all the steps but it works only for back to sleep and it doesn't work for turn on. Is there anything that I am possibly missing? I am connect only via Wi-fi, is it a problem? I am using a laptop Asus model Q536F. Thank you

You won't be able to do WOL from off when using Wi-Fi, only ethernet. It's a limitation of the WoWOL (Wake on Wireless LAN).

This blog talks about the standard and it's limitations:
Revolution Wi-Fi: Wake on Wireless LAN.


  • Standby Mode Only - Because wireless clients must remain connected to the BSS at all times, standby mode is the lowest power state supported. Hibernation or full power off states will not work because no power is provided to the wireless NIC to maintain network association.

I don't seem to be able to get [Boot Me Up Scottie] to work. I have some software(WakemeonLan) on my PC that sends a WOL packet and my server then boots up but not using this software. The HE and server are plugged into the same hub.

Any ideas?

Are you using the latest HE firmware?
Anything in your logs when you toggle the WOL switch you created?

Changed HE to DHCP and works now. (found this info on the forum)

1 Like

Worked perfectly thanks for the app. Also there's a package manager that works really well these days. Might be nice to have this app included in it.

There's a few things you'd need to setup. But I think it's pretty easy.