'''2006-02-06''' [SRIV] I've always wondered how to utilize the Wake On Lan feature of modern computers, especially since last night when I had to halt a machine 200 miles away and I had noone there to power it back up. After you enable WOL in you motherboards BIOS, boot into your OS. I typically use Linux. In order for the halt command to power down the computer you must have the apm module loaded first. Now, issue the halt command, and the computer should turn off, but, the LAN jack indicator LEDs should still be lit. Run this script, passing the IP Address and MAC address of the computers NIC on the command line: wakeonlan.tcl 192.168.0.55 00:40:63:D5:2A:B9 and you will note that the computer will power on. You'll need to obtain the tcludp extension as well. # wakeonlan.tcl - Steve Redler IV # # Create and send the magic packet needed to wake a halted # computer over the internet via broadcast UDP socket. # package require udp 1.0.8 # Select the ipaddress and the port number. set ipaddress [lindex $argv 0] set port 32767 # Create a listening socket and configure for sending too. set s [udp_open $port] fconfigure $s -buffering none -blocking 0 fconfigure $s -broadcast 1 -remote [list $ipaddress $port] # Announce our presence and run set hw_addr [binary format H* [string map {: ""} [lindex $argv 1]]] set msg "\xff\xff\xff\xff\xff\xff[string repeat $hw_addr 16]" # Lets send it 4 times to be safe for {set a 0} {$a < 4} {incr a} { puts -nonewline $s $msg after 100 } exit