QUOTE(clofland @ Feb 19 2010, 04:00 PM)
Anyone know how to send a WOL Magic Packet from a Zaurus?
To answer my own question (because I hate it when I find questions with no answers).
(And a copy in case the above URL dies before this forum does)
# Copyright © 2002 by Micro Systems Marc Balmer
# Written by Marc Balmer, firstname.lastname@example.org, http://www.msys.ch/
# This code is free software under the GPL
import struct, socket
# Construct a six-byte hardware address
addr_byte = ethernet_address.split(':')
hw_addr = struct.pack('BBBBBB', int(addr_byte, 16),
# Build the Wake-On-LAN "Magic Packet"...
msg = '\xff' * 6 + hw_addr * 16
# ...and send it to the broadcast address using UDP
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
s.setsockopt(socket.SOL_SOCKET, socket.SO_BROADCAST, 1)
s.sendto(msg, ('<broadcast>', 9))
# Example use
As long as you have python installed, this works great. Just replace the MAC after the last line with the one you want to wake up.
Very nice. Now I can shut all of the computers in my house off (or put them to sleep) and use my Z to turn them on when I need to access them.