Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Wake On Lan Magic Packet Sender #226

Open
jmsuk opened this issue Feb 17, 2014 · 10 comments
Open

Add Wake On Lan Magic Packet Sender #226

jmsuk opened this issue Feb 17, 2014 · 10 comments

Comments

@jmsuk
Copy link

jmsuk commented Feb 17, 2014

It would be great to include the ability to configure Serenity to send a Magic Packet when it starts up. This would give users a more seamless experience when using Serenity to connect to a Plex Media Servers set up for Wake On Lan (e.g. remove the need to WoL via another app). If active, this WoL packet sender should probably attempt to deliver its payload before Serenity does any server discovery.

The configuration settings should probably include the following:
MAC Address of target
IP Address of target
Port on target
"Send as Broadcast" switch (If "on" then an additional field to set "subnet" should appear)
"Send Multiple" switch (if "on" then an additional field to set packet count should appear)
Interval (in seconds)

Hope this helps :)

@jmsuk jmsuk closed this as completed Feb 17, 2014
@jmsuk jmsuk reopened this Feb 17, 2014
@kingargyle
Copy link
Contributor

Android library that can be leveraged for this:

https://github.com/mafrosis/Wake-On-Lan

@kingargyle kingargyle added this to the 1.8.0 - milestone Jul 23, 2014
@kingargyle
Copy link
Contributor

Will try and get this in place for 1.8.0-M3, if not, then 1.8.0-M4

@kingargyle
Copy link
Contributor

Question I have on this. It appears that this needs to either send to a Mac Address or to an IP Address specifically to wake the implementation. I can grab the IP Address during the server discovery process but if the servers are already asleep, they may not be broadcasting so that Serenity can find them. How should this case be handled, or is it something that should be ignored?

The plan would be to send out the message to the particular server when Serenity is started. Not sure how long it takes for a particular server to start.

@jmsuk
Copy link
Author

jmsuk commented Jul 25, 2014

My thoughts are, if people are going to utilize your WoL feature, them going through the effort of putting in the configuration settings above, saves you some hassle in trying to do too much auto discovery. IMHO life is easier when the Plex Server is on a fixed/reserved IP anyway.. :) But.. if you do want some kind of auto discovery incase ppl still have theirs setup with dhcp, how about using the last known discovered address if none is specified in the settings page?

As for how long to wait after sending packets, that's a tricky one.. perhaps delay server connection attempt by a configurable number of seconds (if WoL enabled) and also offer a 'refresh' button or menu item like the one in the official client? (If there isn't one already?)

@kingargyle
Copy link
Contributor

Thanks, I should at least be able to get some basic support, where it just tries the preferred plex servers address when the app starts up.

@kingargyle kingargyle removed the future label Jul 25, 2014
@jmsuk
Copy link
Author

jmsuk commented Jul 25, 2014

Any support will put Serenity leagues ahead of anything else out there.. it's considered a "small" overlooked feature, but a simple trawl through the internets would reveal that integrating WoL would be a really well received feature (along with "trailer support" that's been promised in Plex for what feels like eons :) )

@kingargyle
Copy link
Contributor

Serenity already has Movie Trailer support, if you have the offical YouTube player installed on the device. I'll see if I can get WoL in this weekend.

@jmsuk
Copy link
Author

jmsuk commented Jul 25, 2014

Ahh yeah, I'd forgotten about that. I think I was thinking more about trailers held locally, that could be queued up in a batch (e.g. with little DTS/Dolby Digital idents etc.), saved as a batch and played automagically before a movie.. Plex has a queue feature but its not quite the same :)

@kingargyle
Copy link
Contributor

You could do something similar with Serenity's built in queue feature. You would need to have a library that has all the local items. Go to to the Trailers you want to play before the movie starts, add them individually to the queue. Go to the movie you want to play, add it to the Queue. Then use the side menu, to Play All from Queue. The trailers should play first, followed by the movie.

@kingargyle kingargyle modified the milestones: 1.8.0 -, 2.0.0 Aug 15, 2014
@goosar19
Copy link

goosar19 commented Sep 4, 2014

I like jmsuk's line of thinking. I have to agree with him that for anyone even half serious about setting up a reliable Plex server should have their computer set to a static IP (or a DDNS configuration in place) so using the WoL option would alleviate the need for me to keep my computer on 24/7. I will eventually be trying to move the PMS over to a NAS running nas4free that will be on 24/7, however in the meantime this is a great idea to incorporate.

@kingargyle kingargyle removed this from the 1.9.0 milestone Nov 30, 2014
@kingargyle kingargyle added this to the 2.0.0 - MediaBrowser Support milestone Mar 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants