timer store into dummy device timer state timerstop
Moderators: grovkillen, Stuntteam, TD-er
timer store into dummy device timer state timerstop
Hi
you can I store the timer state - seconds -
into a dummy variable?
Is timer state available somewhere?
Dummy is having 4 values now?
Will that work:
TaskValueSet 10,2,[timer1]
PS timerstop. did not find any reference in WIKI?
How is timerstop referenced to a timer having more than 1.
Thanks T
you can I store the timer state - seconds -
into a dummy variable?
Is timer state available somewhere?
Dummy is having 4 values now?
Will that work:
TaskValueSet 10,2,[timer1]
PS timerstop. did not find any reference in WIKI?
How is timerstop referenced to a timer having more than 1.
Thanks T
-
- Normal user
- Posts: 307
- Joined: 06 Nov 2016, 13:45
Re: timer store into dummy device timer state timerstop
Seen here: viewtopic.php?f=6&t=5841&p=31646&hilit= ... ble#p31646PS timerstop. did not find any reference in WIKI?
Code: Select all
Timer,1,0 //disable the timer
30+ ESP units for production and test. Ranging from control of heating equipment, flow sensing, floor temp sensing, energy calculation, floor thermostat, water usage, to an interactive "fun box" for my grandson. Mainly Wemos D1.
Re: timer store into dummy device timer state timerstop
Sorry do not undertand your hint.Domosapiens wrote: ↑05 Jan 2019, 12:02Seen here: viewtopic.php?f=6&t=5841&p=31646&hilit= ... ble#p31646PS timerstop. did not find any reference in WIKI???Code: Select all
Timer,1,0 //disable the timer
question: timerstop and timerstart is this an event?
- refering to which timer? having more than one timers running?
how to publish use timer elapsed time in mqtt or in dummy device.
I understand your hint to pass a value from dummy as timer time. but I need other way around
Thanks Thomas
- grovkillen
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
- Contact:
Re: timer store into dummy device timer state timerstop
You would need to use two timers, one that is pushing the seconds passed to a dummy. But if you can explain the need for a system variable then we might implement it.
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
Re: timer store into dummy device timer state timerstop
Hi ok, thanks.grovkillen wrote: ↑05 Jan 2019, 13:55 You would need to use two timers, one that is pushing the seconds passed to a dummy. But if you can explain the need for a system variable then we might implement it.
but how do I push the seconds passed to the dummy? Would this work already?
or publish the seconds passed?
Thanks
- grovkillen
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
- Contact:
Re: timer store into dummy device timer state timerstop
Code: Select all
On StartTimer Do
TaskValueSet,12,1,%eventvalue%
TimerSet,1,%eventvalue%
TimerSet,8,1
EndOn
On Rules#Timer=1 Do
TimerSet,8,0
TaskValueSet,12,1,0
//Whatever
EndOn
On Rules#Timer=8 Do
TaskValueSet,12,1,[dummy#timeleft]-1
TimerSet,8,1
EndOn
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
Re: timer store into dummy device timer state timerstop
hi, ok thanks, will check
Re: timer store into dummy device timer state timerstop
But is it possible to reference the time of a specifiy timer?grovkillen wrote: ↑05 Jan 2019, 16:40If you have your dummy on task number 12. Named dummy#timeleft. Start timer by using the event command, Event,StartTimer=123. Use whatever integer as the countdown.Code: Select all
On StartTimer Do TaskValueSet,12,1,%eventvalue% TimerSet,1,%eventvalue% TimerSet,8,1 EndOn On Rules#Timer=1 Do TimerSet,8,0 TaskValueSet,12,1,0 //Whatever EndOn On Rules#Timer=8 Do TaskValueSet,12,1,[dummy#timeleft]-1 TimerSet,8,1 EndOn
Code: Select all
On Rules#Timer=8 Do
TaskValueSet,12,1,[dummy#timeleft]-1
TimerSet,8,1
EndOn
Probably I am incorrect how to number the different timer.
Timer 1: timerSet,1,13600
Timer 2: timerSet,2,10
etc.
or is this not correct?
Rule#Timer=2: Evento for finished timer 2?
Thanks T
Last edited by riker1 on 05 Jan 2019, 23:41, edited 1 time in total.
- grovkillen
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
- Contact:
Re: timer store into dummy device timer state timerstop
Yes the timer 1 event makes sure that it'll stay zero once the timer 1 is up. Thus these lines:
You can then always use the [dummy#timeleft] to use it elsewhere.
Code: Select all
TimerSet,8,0
TaskValueSet,12,1,0
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
Re: timer store into dummy device timer state timerstop
ok thanks understood.
Nice aproach.
maybe a systemvariable for timers would be easier instead of duplicating it via dummy device.
another related questions. :is it possible to set the variable via mqtt?
Thanks Thomas
Nice aproach.
maybe a systemvariable for timers would be easier instead of duplicating it via dummy device.
another related questions. :is it possible to set the variable via mqtt?
Thanks Thomas
- grovkillen
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
- Contact:
Re: timer store into dummy device timer state timerstop
Which variable? The timer? If so, just use the command event,StartTimer=123 and change 123 to whatever number you want.
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
Re: timer store into dummy device timer state timerstop
ok perfect, easier than I thoughtgrovkillen wrote: ↑06 Jan 2019, 11:23 Which variable? The timer? If so, just use the command event,StartTimer=123 and change 123 to whatever number you want.
Who is online
Users browsing this forum: No registered users and 145 guests