You may wish to modify the delay and elapse check times, but try the following logic:
Result:
Trigger check is a pure function, by the way.