Countdown timer w/ Display?

General HouseBot discussion. Any issues that don't fit into any of the other topics belong here.
Post Reply
loo_hoo_ser
Member
Posts: 83
Joined: Sat Oct 30, 2004 4:16 pm

Countdown timer w/ Display?

Post by loo_hoo_ser »

Hi y'all -

I searched the forums for an answer to this and I did turn up an old post from 2004 - but alas, no solution.

What I have is a timer that counts down to turn off the lights, but I'd also like to display the time remaining before the lights turn off (timer expires).

For example, when I start it, it starts at 5 minutes, then it would display 4 minutes, 3 minutes and so on. I thought about doing two timers. One timer to count out the entire 5 minutes and a second timer to count out each minute to decrement a display value. But I thought this was cumbersome and was wondering if there was another way to do this?

Ideally, it'd be nice to have the timer device make visible the time remaining and that would be that! But I don't think this made it as a feature, even in HB 3.0.
ScottBot
Site Admin
Posts: 2790
Joined: Thu Feb 13, 2003 6:46 pm
Location: Georgia (USA)
Contact:

Re: Countdown timer w/ Display?

Post by ScottBot »

loo_hoo_ser wrote:Ideally, it'd be nice to have the timer device make visible the time remaining and that would be that! But I don't think this made it as a feature, even in HB 3.0.
It was on the V3 list, but I never implemented this. The only other way would be to do it with a script and a 1 sec repeating timer, but that's a lot of trouble.
Scott
roussell
Advanced Member
Posts: 268
Joined: Wed Dec 15, 2004 9:07 am
Location: Pelham, AL

Post by roussell »

FWIW, I too would love this functionality. My wife controls the sprinklers in her flower bed with a SWremote on her phone and she has asked for a display to show how many minutes are left on the watering schedule.

(Sorry - thread hijack coming, I'll move to a different thread if it's a problem)

While we're on the subject of timers, it would be great to break out the sleep time property out into separate days/hour/minute/second/mili properties. That would make it a lot easier to tie a slider or similar control to a time. The wife wants this so she can simply adjust a slider to change the water schedule. If there is already a way to do this, please clue me in. I've been trying to implement it with a script but it's cumbersome at best.

Thanks,
Terry
Richard Naninck
HouseBot Guru Extraordinaire
Posts: 1121
Joined: Tue Sep 28, 2004 7:49 am
Location: The Netherlands

Post by Richard Naninck »

roussell wrote:If there is already a way to do this, please clue me in. I've been trying to implement it with a script but it's cumbersome at best.
SetPropertyValue "Any Timer.Sleep Time", "Seconds=" & GetPropertyValue("NULL Device.Seconds")

In short; create a property and call it.... Seconds (is apropriate) and bind it to any device (NULL Device in my case). Then bind a theme slider to this seconds property. Create a tasks that looks for changes on the Seconds property. If it changes, fire the script line as above.
If Seconds is set to 100, actually 1 minute and 40 seconds will be enterend into the device. Obviously this can also be done with Minutes, Hours etc.

Hope this is what you are looking for.
roussell
Advanced Member
Posts: 268
Joined: Wed Dec 15, 2004 9:07 am
Location: Pelham, AL

Post by roussell »

Thanks Richard, that's pretty much what I'm doing which works - I just hate having all those scripts and tasks for such a simple need.

I've submitted a feature request for both the "Remaining Time" and separated "sleep time" properties.

Terry
Richard Naninck
HouseBot Guru Extraordinaire
Posts: 1121
Joined: Tue Sep 28, 2004 7:49 am
Location: The Netherlands

Post by Richard Naninck »

These are both nice feature requests as long as the current functionality remains working.

Lets say the sleep timer is broken into hours, minutes, seconds etc and I want to set one and a half minute I would have to set two sliders. The minute slider set to one and the seconds slider set to 30 whereas now the seconds can be set to 90 and it takes 1.5 minutes. But looking at the time property which is broken into pieces I think this won't be a problem.
Post Reply