SubscriptionStatus that waits for state to be stable
Closed this issue · 0 comments
DominicOram commented
We have a usecase where we would like to wait on a PV being a certain state and staying at that state for a given length of time. If in that time it changes to a different state we want to restart the timer for it to be stable
.
It was suggested on slack that we could implement this with a SubscriptionStatus
like object that rather than marking itself as done when the user function is True, starts a cancelable timer to do it and if it gets a False back from the user function cancels the timer.
We would also need to make sure that we do not spawn multiple timers.