While building my Smart Home system I figured I might as well attach my Diskstation DS212 to the controls so I can turn it on and off at will. To make this work, I used the exec binding, the network health binding and the WOL binding combined into one neat little Switch:

Switch DS212 "DiskStation DS212" (Network) {
 nh="192.168.0.19", 
 exec="OFF:plink root@192.168.0.19 -pw password poweroff", 
 wol="192.168.0.255#00:11:32:0F:7F:2C" }

The corresponding sitemap entry look like this then:

Frame label="Network" {
 Switch item=DS212
}

Leave a comment