Wakiewakie v1.29

Developed or developing a new product in PureBasic? Tell the world about it.
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Wakiewakie v1.29

Post by blueznl »

I have written a simple tool for laptops and / or HTPC clients that need to wake up a home server. Think of it as a combination of find / ipconfig / ping / send wol / ping. Just like a complicated batch file, only looking better :-)

Practical example: wife / kids use a laptop to watch a movie. When they switch on the laptop the home server will wake up. In effect it is as simple as that.

The simple process:

- check if the adapter is valid (local adapter is typically 0.0.0.0 if Wifi isn't connected yet)
- check if the router can be reached
- send out a WOL to the server
- check if the server can be reached

To simplify life, the tool also shows all possible adapter names, MAC adresses etc.

It now has reached a functional state and looks something like this:

Image

Image

Homepage: http://www.ninelizards.com/purebasic/purebasic%2029.htm#wakiewakie.

Source included.
Last edited by blueznl on Tue Jun 06, 2017 11:58 pm, edited 15 times in total.
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
Nituvious
Addict
Addict
Posts: 954
Joined: Sat Jul 11, 2009 4:57 am
Location: United States

Re: Wakiewakie - WIP

Post by Nituvious »

Pretty cool, I used an old laptop as an HTPC for quite a while because it was the only computer in the house with a S-Video out. Then I bought an HD TV for that HDMI fancy stuff. If only you had released this months ago :(

BTW, you're greying out local addresses that every PC on every local area network will usually have.
▓▓▓▓▓▒▒▒▒▒░░░░░
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie - v1.03x

Post by blueznl »

Nutivious, I was on someone else's network when I posted the previous image. I've replaced it now.

To ALL: feel free to fool around with this tool, especially if you use WOL.
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie - v1.03x

Post by blueznl »

Update v1.06x:

- some bug fixes
- I forgot to binary include the images in the final exe, fixed
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie - v1.03x

Post by blueznl »

Update v1.08x:

- more led colours
- allows skipping of unused fields
- some IP address checking
- can create upon request a desktop shortcut with all parameters set

Creating a desktop shortcut from within is something I never thought of before, but works great. (I used Rashad's code from the board.)
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie - v1.09x

Post by blueznl »

Update v1.09x:

- create / remove an autorun entry to start when logging into windows
- reads previous parameters if an autorun entry already existed

(I'm going to add that to WallX, never thought of this approach...)
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie - v1.11x

Post by blueznl »

Update v1.11x:

- added a led to indicate autorun status
- added a small button to use the server mac from a successful ping
- fixed the empty archive (oops!)
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie - v1.12x

Post by blueznl »

Update v1.18:

- speed up
- improved documentation
- better adapter detection
- 50 msec extra reply detection for slower PC's and routers
- using newer PB compiler
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
Shield
Addict
Addict
Posts: 1021
Joined: Fri Jan 21, 2011 8:25 am
Location: 'stralia!
Contact:

Re: Wakiewakie - v1.18

Post by Shield »

Unfortunately of limited use to me, but I like the simplicity and +1 for the name anyway. :mrgreen:
Image
Blog: Why Does It Suck? (http://whydoesitsuck.com/)
"You can disagree with me as much as you want, but during this talk, by definition, anybody who disagrees is stupid and ugly."
- Linus Torvalds
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie v1.18

Post by blueznl »

Update v1.27x:

- new 'history' and 'linger' options
- little faster
- some fixes

After waking up a remote machine Wakiewakie will 'linger' another 200 msec by default. This to allow the remote machine to get its other services up and running. Without the linger period setting up a VNC session or logging in from a batch file using 'net ...' might sometimes fail. 200 msec seemed to be enough for all the systems I have at home, but it's easy to increase.

The 'history' option shows a progress bar, and Wakiewakie then tries to predict how long the wakeup will take. Obviously this isn't going to be very accurate, but I've empirically tuned the algoritm in such a way most impatient kids / spouses will accept the lie Wakiewakie presents :-)

I would like some feedback on the default values for the history option and linger option. I've set the current parameters after fooling around with five different machines at home (after countless reboots) and even when Wakiewakie gets it totally wrong, it will keep re-adjusting until it gets it right.

The 'history' option creates a human readable file wakiewakie.his for those interested.
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie v1.29

Post by blueznl »

Update v1.29:

- faster
- sportier

:lol:

- little speed up (especially name resolving, though I blame Windows)
- better (?) default values for linger and retry
- set window color (ah yes, batman black, go see the Lego movie) and border size
- escape key (thanks, Danilo, yeah, I need to read better :oops: )
- easier to add / modify parameters
- smoother progress bar

(Ran into a little weird Windows and / or Fritzbox behaviour: resolving name first, immediately followed by a mac caused the Fritzbox to wait with a reply, which made Windows halt for a moment as well. Swapping the two fixed that most of the time, but not always... The wonders of programming...)

Image
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie v1.29

Post by blueznl »

Update 1.36:

- Improved name resolving
- Changed default values
- Other minor things
- Recompiled with 5.50 x86

Download:

- Changed my homepage but it's still there :-)
- http://www.ninelizards.com/purebasic/pu ... wakiewakie
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie v1.29

Post by blueznl »

Update v1.37:

- Added 'adaptive' linger mode and code
- Added linger indicator using the progress bar
- Some other less important stuff (see the source code)

Download:

- Changed my homepage but it's still there :-)
- http://www.ninelizards.com/purebasic/pu ... wakiewakie
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6086
Joined: Sat May 17, 2003 11:31 am
Contact:

Re: Wakiewakie v1.29

Post by blueznl »

Update v1.44:

- added 'all' parameter to improve WOL operation on wifi networks
- updated documentation
- tweaked 'lingering' a bit more

See included documentation. Here's an example of a command line:

wakiewakie.exe history adapter 10.172.*.* router 10.172.0.99 server 10.172.0.4 mac D5:5E:99:48:11:9F color $FFFFFF $000080 linger 1200 retry 500 all

Download:

- http://www.ninelizards.com/purebasic/wakiewakie.zip
( PB7.xx Win10 x64 Asrock AB350 Pro4 Ryzen 1600X 32GB RAM Evo 840 GTX1060 )
( The path to enlightenment and the PureBasic Survival Guide right here... )
Post Reply