Jump to content

Wake On LAN?


tcster

Recommended Posts

Posted

Any thoughts on the ability to do WOL from the ISY? The ability to turn on a PC (or two) either remotely or by schedule would be pretty cool.

 

Just think..... walk in the door and turn off the "On Vacation" button.... before you can take off your shoes, the PC in the office fires up and starts playing music and is dowloading your e-mail. Ah... home automation.

Posted

tcster,

 

Very cool idea! I am not sure how we can do this without having an agent inside the computer which runs even when the computer is in sleep mode and thus wakes up the computer on ISY activity. Don't you think so?

 

With kind regards,

Michel

 

 

Any thoughts on the ability to do WOL from the ISY? The ability to turn on a PC (or two) either remotely or by schedule would be pretty cool.

 

Just think..... walk in the door and turn off the "On Vacation" button.... before you can take off your shoes, the PC in the office fires up and starts playing music and is dowloading you e-mail. Ah... home automation.

Posted

It seems conceivable to me that the ISY could be triggered by an insteon event, or a scheduled event, to send a WOL packet to a pre-specified MAC address over the ethernet port.

Posted

tcster,

 

I think that would work but we have never tested it.

What does the computer do on the receipt of WOL? Should ISY ignore?

 

With kind regards,

Michel

 

It seems conceivable to me that the ISY could be triggered by an insteon event, or a scheduled event, to send a WOL packet to a pre-specified MAC address over the ethernet port.
Posted

Hi Michel,

 

I'm not going to claim to be an expert as I have been researching the topic myself recently. Here's an article that explains some of the basics.

http://en.wikipedia.org/wiki/Wake_on_LAN

 

Basically, a device sends a "Magic Packet" to a MAC address and a PC, that is WOL capable, that is either on standy by or off, turns on.

 

I wouldn't expect the ISY to do anything with/to the PC beyond that, but that ability alone could come in pretty handy for say... having a program like Promixis operate other home automation tasks.

Posted

Hi tcster,

 

Excellent ... let us do some investigation and see what we can do with this. Thanks so very much for the feedback.

 

With kind regards,

Michel

 

Hi Michel,

 

I'm not going to claim to be an expert as I have been researching the topic myself recently. Here's an article that explains some of the basics.

http://en.wikipedia.org/wiki/Wake_on_LAN

 

Basically, a device sends a "Magic Packet" to a MAC address and a PC, that is WOL capable, that is either on standy by or off, turns on.

 

I wouldn't expect the ISY to do anything with/to the PC beyond that, but that ability alone could come in pretty handy for say... having a program like Promixis operate other home automation tasks.

  • 5 months later...
Posted

Michel,

 

This is pretty simple to do. You just need to send out a special formed packet. It should be easy for the ISY.

Posted

Hi Gary,

 

Do you have more information on this?

 

bhyland,

 

Not the next release, but if all it takes is to send out a UDP packet, then it can be done quite easily (in the programs).

 

Wïth kind regards,

Michel

Michel,

 

This is pretty simple to do. You just need to send out a special formed packet. It should be easy for the ISY.

Posted

Here is some ver simple PHP code that should help.

 

Best regards,

Gary

 

<?
# Wake on LAN - (c) HotKey@spr.at, upgraded by Murzik
# Modified by Allan Barizo http://www.hackernotcracker.com
flush();
function WakeOnLan($addr, $mac,$socket_number) {
 $addr_byte = explode(':', $mac);
 $hw_addr = '';
 for ($a=0; $a <6; $a++) $hw_addr .= chr(hexdec($addr_byte[$a]));
 $msg = chr(255).chr(255).chr(255).chr(255).chr(255).chr(255);
 for ($a = 1; $a <= 16; $a++) $msg .= $hw_addr;
 // send it to the broadcast address using UDP
 // SQL_BROADCAST option isn't help!!
 $s = socket_create(AF_INET, SOCK_DGRAM, SOL_UDP);
 if ($s == false) {
   echo "Error creating socket!\n";
   echo "Error code is '".socket_last_error($s)."' - " . socket_strerror(socket_last_error($s));
   return FALSE;
   }
 else {
   // setting a broadcast option to socket:
   $opt_ret = socket_set_option($s, 1, 6, TRUE);
   if($opt_ret <0) {
     echo "setsockopt() failed, error: " . strerror($opt_ret) . "\n";
     return FALSE;
     }
   if(socket_sendto($s, $msg, strlen($msg), 0, $addr, $socket_number)) { 
     echo "Magic Packet sent successfully!";
     socket_close($s);
     return TRUE;
     }
   else { 
     echo "Magic packet failed!";
     return FALSE;
     } 

   }
 }
// Port number where the computer is listening. Usually, any number between 1-50000 will do. Normally people choose 7 or 9.
$socket_number = "7";
// MAC Address of the listening computer's network device
$mac_addy = "00:12:4G:SF:12:13";
// IP address of the listening computer. Input the domain name if you are using a hostname (like when under Dynamic DNS/IP)
$ip_addy = gethostbyname("myhomeserver.dynamicdns.org");

WakeOnLan($ip_addy, $mac_addy,$socket_number)
?>

Posted

Gary,

 

This is excellent. Thanks so very much. And, what happens if the computer gets a new IP address?

 

With kind regards,

Michel

 

Here is some ver simple PHP code that should help.

 

Best regards,

Gary

 

# Wake on LAN - (c) HotKey@spr.at, upgraded by Murzik
# Modified by Allan Barizo http://www.hackernotcracker.com
flush();
function WakeOnLan($addr, $mac,$socket_number) {
 $addr_byte = explode(':', $mac);
 $hw_addr = '';
 for ($a=0; $a   $msg = chr(255).chr(255).chr(255).chr(255).chr(255).chr(255);
 for ($a = 1; $a 

Posted
Gary,

 

This is excellent. Thanks so very much. And, what happens if the computer gets a new IP address?

 

With kind regards,

Michel

We don't really care about the computers IP address. The reason we would want the IP addess is so we will know the broadcast address. We send the packt to the broadcast address, and the packet contains the MAC address of the computer.

Posted

This would be great, thanks for the consideration! I would love to be able to trigger this as eother a scheduled event or in response to a button etc. I want to use this to manage my media server as I currently send the server to either S3 or S5 at the end of the day and want to wake it on our return home maybe from the welcome home keypad button :) I understand it won;t make intot he next release but I'll keep my fingers crossed we'll see this soon.

 

Thanks again

Posted

Thank you all!

 

This is rather simple to implement. Consider it done.

 

With kind regards,

Michel

 

This would be great, thanks for the consideration! I would love to be able to trigger this as eother a scheduled event or in response to a button etc. I want to use this to manage my media server as I currently send the server to either S3 or S5 at the end of the day and want to wake it on our return home maybe from the welcome home keypad button :) I understand it won;t make intot he next release but I'll keep my fingers crossed we'll see this soon.

 

Thanks again

  • 1 month later...
Posted

Hi Michael,

 

Hopefully I won't appear pushy but any rough estimate when / if you might be able to implement this feature?

 

Thanks

 

Brian

Posted

Hi Brian,

 

No guarantees, but we are trying to make it in our 2.7 release (the next official release). So, within the next few weeks.

 

With kind regards,

Michel

 

Hi Michael,

 

Hopefully I won't appear pushy but any rough estimate when / if you might be able to implement this feature?

 

Thanks

 

Brian

  • 1 month later...
Posted

huddadudda,

 

Boy we are in synch today! Today I also started investigating the Magic Packet for Wake On Lan to ascertain the level of difficulty. Not difficult at all but it touches all major components:

1. GUI - Configuration tab to enter the list of computers with their names and MAC addresses

2. Programs - to have the list of names present in the Action

3. Services - to store and retrieve computer information

4. Firmware - to make a magic packet out of parsed computer information

 

Again, quite trivial since we have all the framework. But, as I mentioned before, we cannot afford delaying the official release. Again, rest assured that it has high priority and shall be done as soon as we release the official version.

 

With kind regards,

Michel

 

 

I also would love to see this as a awesome feature to have. Please let us know when its done. Wish it was in the recent 2.6.14 beta release. Maybe .15? ;)
  • 1 month later...
Posted

Hi, I am new to isy and insteon, so forget me if I this is totally off. But i am excited about the possibilities of ISY combined with Insteon and the computer. Technically, I am not a programmer, but I conceptually, I can't avoid to think if you can send a WOL to a PC. Then basically, theorectically, you can control the PC or home media server if it has an app to listen to these signals from ISY.

 

I am thinking if you can get the PC to receive a WOL from the ISY, why not

 

Have ISY control wimamp or itunes (understanding that the winamp or itunes would have need a plugin, which I believe there are many out there already). So you can use the insteon controllers to have music stream off and on, volume up and down, next song etc.

 

What about two way command. Would it not be possible to have a little app on the PC that listens to see if a new email arrived? If so, it sends a singal to the ISY or PLM that is programed through ISY to flash a light. Similarly, can a little PC app be used to receive RSS and parse the data, if certain data is True then send a signal to ISY.

 

I am thinking conceptually, I know this would take a lot of things to come together, ISY and PC apps or plugins on both sides. But wondering if this is at least possible so that I can see what holds for the future of ISY? If this is possible, that would be very exciting.

 

Comments?

Posted

Hi Joefly -

 

The ISY has a Java SDK and Web Services SDK available, so I don't see why anything you've mentioned wouldn't be possible - it's simply a matter of someone writing the necessary applications.

Posted
Hi, I am new to isy and insteon, so forget me if I this is totally off. But i am excited about the possibilities of ISY combined with Insteon and the computer. Technically, I am not a programmer, but I conceptually, I can't avoid to think if you can send a WOL to a PC. Then basically, theorectically, you can control the PC or home media server if it has an app to listen to these signals from ISY.

 

I am thinking if you can get the PC to receive a WOL from the ISY, why not

 

Have ISY control wimamp or itunes (understanding that the winamp or itunes would have need a plugin, which I believe there are many out there already). So you can use the insteon controllers to have music stream off and on, volume up and down, next song etc.

 

What about two way command. Would it not be possible to have a little app on the PC that listens to see if a new email arrived? If so, it sends a singal to the ISY or PLM that is programed through ISY to flash a light. Similarly, can a little PC app be used to receive RSS and parse the data, if certain data is True then send a signal to ISY.

 

I am thinking conceptually, I know this would take a lot of things to come together, ISY and PC apps or plugins on both sides. But wondering if this is at least possible so that I can see what holds for the future of ISY? If this is possible, that would be very exciting.

 

Comments?

 

My 2 cents - I do not see any reason for the ISY development to move further in the PC direction other than this feature. Why would anyone need to control iTunes through the ISY or anything else for that matter? The Wake on Lan function is good for specific users whom are running media centers with other servers like myself so when we pickup our Pronto or universal remote to control our PC to turn it on it can also send a wake up command to the server from the ISY. The PC should be the front end and there are already a ton of utilities already developed and mature. Universal Devices should not try and redevelop the wheel and spend valuable time down the PC path unless a majority of members see benefits. I would rather a stable product for the Insteon side than a feature rich product - which is a fine line.

Posted

 

Comments?

 

My 2 cents - I do not see any reason for the ISY development to move further in the PC direction other than this feature. Why would anyone need to control iTunes through the ISY or anything else for that matter? The Wake on Lan function is good for specific users whom are running media centers with other servers like myself so when we pickup our Pronto or universal remote to control our PC to turn it on it can also send a wake up command to the server from the ISY. The PC should be the front end and there are already a ton of utilities already developed and mature. Universal Devices should not try and redevelop the wheel and spend valuable time down the PC path unless a majority of members see benefits. I would rather a stable product for the Insteon side than a feature rich product - which is a fine line.

 

I agree. There are many computer programs available that perform these functions. If they wish to integrate with Insteon, and hopefully the ISY, all they need to do is create a plug-in. The tools for the ISY are here, as MikeB mentions. And they are not platform dependent.

 

The #1 job for the ISY is, and should remain, easy management and interaction with home automation devices. The developers have already displayed the ability to interact with the internet and networked devices via Climate module, ELK integration, etc.

 

IMHO,

Rand

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...