It does, but not for starting the countdown unfortunately. I'll add a function to start the timer when I get a chance The program is designed to be ran in the background really - clicking the icon and then clicking "Countdown Timer" restarts the last countdown duration. Would the command line function need to work even if Sleep# was already running?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I've made a basic implementation which responds to the -countdown command line parameter. It simply sets the countdown to its last set value (like clicking the "Countdown Timer" menu item) and starts the timer. Is this suitable?
You can also communicate with Sleep# using the custom Unified Remote interface (https://www.unifiedremote.com/) - this sends messages to the hwnd which Sleep# stores in %temp%\sshw upon startup. See the win.send commands in C:\ProgramData\Unified Remote\Remotes\Custom\Sleep#\remote.lua.
Let me know if this is ok or if you have any problems. I haven't properly tested it but I tried to make as few changes as possible. An updated version to fix the fader issue with some Windows 10 Apps will include this change.
I apologize for the delay of response (for some reason I did not get the alert). Yes I can now run through a cmd shortcut which is awesome.
ps: I just noticed it's not open source (I thought sourceforge was only about open source), so I can't install it on my main computer. You should maybe consider providing the source, your app would be much more popular if it was on github. Anyway, thanks a lot!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
If so, how would you launch it automatically with a count down timer of 1h?
Thanks!
It does, but not for starting the countdown unfortunately. I'll add a function to start the timer when I get a chance The program is designed to be ran in the background really - clicking the icon and then clicking "Countdown Timer" restarts the last countdown duration. Would the command line function need to work even if Sleep# was already running?
Thanks for your reply Chris,
I don't know, I only need to run a script that will launch a sound (whitenoise) and then Sleep# with the arguments "sleep in 1h" + "5mn fade".
I guess the easiest for you will be the best (I can kill Sleep# before, or launching it before running the commande line parameters).
Last edit: Lidit 2017-10-20
Hi Lidit,
I've made a basic implementation which responds to the -countdown command line parameter. It simply sets the countdown to its last set value (like clicking the "Countdown Timer" menu item) and starts the timer. Is this suitable?
You can also communicate with Sleep# using the custom Unified Remote interface (https://www.unifiedremote.com/) - this sends messages to the hwnd which Sleep# stores in %temp%\sshw upon startup. See the win.send commands in C:\ProgramData\Unified Remote\Remotes\Custom\Sleep#\remote.lua.
Let me know if this is ok or if you have any problems. I haven't properly tested it but I tried to make as few changes as possible. An updated version to fix the fader issue with some Windows 10 Apps will include this change.
Thanks for using Sleep#!
Chris
v3.21.1 Sent the command line option -countdown to the previous instance if Sleep# is already running.
I apologize for the delay of response (for some reason I did not get the alert). Yes I can now run through a cmd shortcut which is awesome.
ps: I just noticed it's not open source (I thought sourceforge was only about open source), so I can't install it on my main computer. You should maybe consider providing the source, your app would be much more popular if it was on github. Anyway, thanks a lot!
Hi Lidit,
I've just released v3.22 which has a major overhall of the log window. Bug fixes and your changes are now included.
I'll work towards commenting the code and making it open source - out of interest, why can't you install closed source software on your main computer?
Thanks for your help and recommendations.
CHris