Setting stopwatches to a specified time

Fabian42

New member
The only time that stopwatches can currently be set to is 0. I would like to be able to set them to any value, it would be especially helpful if the time could be determined by an integer variable (as number of seconds).

Usecase: I have a pretty complicated set of macros that tries to determine when I'm awake or asleep and sets alarms at (hopefully) good times, depending on when I went to sleep and how long I was awake before that. Since my sleep cycles can get pretty chaotic, there are all kinds of special cases. I want a timer to track the time that I'm awake for, so I need to reset it right when I wake up. Long periods of not using my phone might be misinterpreted as sleep by my macros, so I want to be able to manually tell it that I wasn't sleeping. But if I wasn't sleeping, then the timer should go back to tracking the time since the previous detected wake up time. For that, I would have to be able to set it to that value. I also can't just restart the timer later, when the macro can be sure that I actually woke up, because then that duration would be missing from it.
So what I have to do instead is to either alternate between two timers, one for even and one for odd days, only reset one of them and fall back onto the other if necessary, then duplicate every usage of that timer, or maybe I can get it to work by determining a fixed duration after which the macros assume that it correctly recorded the wake up time, then I could subtract that duration from every usage of the timer instead. I still have to plan whether that can work for all usages of that timer of it would mess something up. Anyway, this missing feature is making my alarm macro system even more complicated, I'll probably need at least a thirteenth macro and a fourth timer just for this. :D
There might also be possible usecases that are currently completely impossible, but they might also all be solvable by introducing a new integer variable and using e.g. triggers and conditions for "stopwatch=whatever minus integer", outputting "stopwatch plus integer" to the log, etc.
 

FrameXX

Well-known member
Why no to set a boolean variable while stopwatch is running/stopped and use this variable change as a constraint?
Intelligent. That's propably what I have done. I just missed the direct option. I'll remove the suggestion.
 
Top