Help With Broadcaster

Questions and comments specific to a particular plugin should go here.
enobhsiw
Posts: 29
Joined: Mon Sep 11, 2017 7:51 pm

Re: Help With Broadcaster

Post by enobhsiw » Sun Oct 01, 2017 4:44 pm

So what was it?? :P

User avatar
kgschlosser
Site Admin
Posts: 3693
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Help With Broadcaster

Post by kgschlosser » Sun Oct 01, 2017 6:37 pm

It was the way I was obtaining the mac address. you can't ping yourself and then lookup the mac of the computer in the arp tables. So i opted to grab it from ipconfig instead


here is the version that fixes the traceback.
Attachments
WOL.egplugin
(3.05 KiB) Downloaded 25 times
If you like the work I have been doing then feel free to Image

enobhsiw
Posts: 29
Joined: Mon Sep 11, 2017 7:51 pm

Re: Help With Broadcaster

Post by enobhsiw » Sun Oct 01, 2017 11:36 pm

Ok I ran the plugin and got these results:

Image

The iOS Remotes ran fine with no errors.

The Android remotes however had an issue.
Yatze remote, gave some error/data.
Kore remote gave an instant double WoL
'
Here's the data from Yatze.

Code: Select all

data: [89, 97, 116, 115, 101, 83, 116, 97, 114, 116, 45, 88, 98, 109, 99]

Code: Select all

wol_packet: [255, 255, 255, 255, 255, 255, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19, 52, 230, 173, 14, 67, 19]
However, in all instances, they have a proper WoL signal

User avatar
kgschlosser
Site Admin
Posts: 3693
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Help With Broadcaster

Post by kgschlosser » Mon Oct 02, 2017 1:47 am

do me a favor. turn on your log time stamping and then send the WOL packets. I probably just have to tweak the timing. Or put in place a thread lock (the latter probably being the case) the thread lock will not allow another thread to process the same code simultaneously. thus allowing the first one that is running to set up the timer and the flag to not process the second before it actually does. but if the 2 are running almost at the exact same time then the second packet is making it past the flag before the first even sets it.. That is why the log times will help me out. it will let me know how close they come in to one another.
If you like the work I have been doing then feel free to Image

User avatar
kgschlosser
Site Admin
Posts: 3693
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Help With Broadcaster

Post by kgschlosser » Mon Oct 02, 2017 1:50 am

as far as the "error data" this is not of concern. i am going to be removing that error printout when this is buttoned up.
If you like the work I have been doing then feel free to Image

enobhsiw
Posts: 29
Joined: Mon Sep 11, 2017 7:51 pm

Re: Help With Broadcaster

Post by enobhsiw » Mon Oct 02, 2017 9:18 am

Well, both the signals are almost instantaneous, just a few milliseconds apart I would say.
Your idea would be nice as it would stop WoL spam on network, or atleast prevent 2 remotes sending a signal simultaneously.

Image

User avatar
kgschlosser
Site Admin
Posts: 3693
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Help With Broadcaster

Post by kgschlosser » Mon Oct 02, 2017 1:20 pm

yeah it is as i thought. let me institute the threading lock and go from there. that will take care of the problem. tho i may use threading events as the flag this will allow me to bump out the second one since they are back to back like they are.
If you like the work I have been doing then feel free to Image

User avatar
kgschlosser
Site Admin
Posts: 3693
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Help With Broadcaster

Post by kgschlosser » Mon Oct 02, 2017 2:04 pm

ok i think i got this right. it's early I haven't fully woken up. what i did is this. I am thinking that the double events might be coming from the fact that the plugin is listening on 3 different ports. so I added the port the WOL comes in on to the even. but I also made the lock and the timer for the double WOL packet span all 3 instances of the socket. so if a packet comes in on port 0 as an example and another comes in on port 9 because whatever program it is that is sending the WOL packet might send it to 0 and 9 automatically to try and cover it's bases we don't want to get the double event. I am going to refine this a bit to do actual IP checking so it will only stop them from being a double if it is the same IP but lets make sure this works first.
Attachments
WOL.egplugin
(3.12 KiB) Downloaded 26 times
If you like the work I have been doing then feel free to Image

enobhsiw
Posts: 29
Joined: Mon Sep 11, 2017 7:51 pm

Re: Help With Broadcaster

Post by enobhsiw » Mon Oct 02, 2017 2:53 pm

Sorry I was unable to post any results.
I installed the plugin, but when I tried to 'Add' the plugin, EG hanged.

User avatar
kgschlosser
Site Admin
Posts: 3693
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Help With Broadcaster

Post by kgschlosser » Mon Oct 02, 2017 4:09 pm

I thought that might happen. so give this a try I remove the use of wx to handle the timer bits. I created my own thread for it and i also instituted the ip address checking. so if you have a WOL come in from different IP addresses it will not block them. it will only block them if the WOL comes in from the same IP address more then one time per second.
Attachments
WOL.egplugin
(3.2 KiB) Downloaded 23 times
If you like the work I have been doing then feel free to Image

enobhsiw
Posts: 29
Joined: Mon Sep 11, 2017 7:51 pm

Re: Help With Broadcaster

Post by enobhsiw » Mon Oct 02, 2017 7:18 pm

Same thing again. EG hanged :(

User avatar
kgschlosser
Site Admin
Posts: 3693
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Help With Broadcaster

Post by kgschlosser » Tue Oct 03, 2017 9:23 am

ok last time.

LOL
Attachments
WOL.egplugin
(3.22 KiB) Downloaded 33 times
If you like the work I have been doing then feel free to Image

enobhsiw
Posts: 29
Joined: Mon Sep 11, 2017 7:51 pm

Re: Help With Broadcaster

Post by enobhsiw » Tue Oct 03, 2017 10:16 pm

Ok I ran the plugin successfully.
As you can see from the picture below, there were no errors, or data popups from both iOS (1,2) and Android (3,4).
I will test it a bit more, and if I run into anything, I will let you know.

Image

But so far it seems to be very successful.

enobhsiw
Posts: 29
Joined: Mon Sep 11, 2017 7:51 pm

Re: Help With Broadcaster

Post by enobhsiw » Thu Oct 05, 2017 9:45 am

Ok,
I have ran the plugin multiple times and have no problems so far.

Thank you so much kgschlosser for the time and effort you put into this.

Now to see what possibilities this plugin opens up :)

User avatar
kgschlosser
Site Admin
Posts: 3693
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Help With Broadcaster

Post by kgschlosser » Thu Oct 05, 2017 2:46 pm

no worries m8. thats why i am here

:D
If you like the work I have been doing then feel free to Image

Post Reply