Announcement

Collapse
No announcement yet.

How to use timers

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How to use timers

    Hello, I want to use use timers to turn off lights, but can't understand the dynamics on using them in the event, can someone help me understand the concept please..
    Hector
    ____________________________________
    Win.2003 OS, HS3
    BLDSC,BLstat,BLRadar,BLRamdom,BLOccupied
    BLups,BLrain8,HSTouch,Ultrajones Weatherbug,
    MyTrigger,ACRF2,W800,Zwave
    AP800,Honeywell Stat

    #2
    1) Create a Timer under Tools, Timers/Counters
    2, a) use events to start (resets timer to zero), stop, resume or set to time.
    2, b) remember to stop a timer when not in use, it will count down indefinitely
    3) use event triggers to trigger on the appropriate Timer value

    so, as an example, you create a Timer "Hall Light Timer"
    you then create an event that triggers when your Hall Light changes and becomes on. The action of the event starts your Hall Light Timer
    a 2nd event then triggers when the Hall Light Timer becomes 5min (or alternatively is more than 5 min); the action then turns the Hall Light off and stops the Hall Light Timer.

    With that said, there is always more than one way to skin a cat, here are 3 other options

    1) I use the EasyTrigger plugin for the lights I want to turn off after x time. The reason I use it is that my hall light is a dimmer, so it's not just on/off.
    Click image for larger version

Name:	Screenshot 2023-04-25 220345.png
Views:	328
Size:	36.1 KB
ID:	1611737


    2) Here is my old event where I used a delayed action to turn the light off. if your light is a dimmer, you'd need two triggers 1. device just changed or set, 2. And is not off. I'm a big fan of delayed actions. remember you can delete a delayed action with another event if another event triggers.

    Click image for larger version

Name:	Screenshot 2023-04-25 220735.png
Views:	249
Size:	28.7 KB
ID:	1611738


    3) You could also have a recurring event trigger ​that repeats every 5 seconds
    Then you use conditional actions for each of the lights you want to turn off on a timer. The one nice thing is you can set up one event with all your timed light control. Having all your timed light controls in one event could also be a negative if you, like me, disable events to override the automated timer. You may note this version only works for on/off devices. for a dimmer your first conditional argument would be 'Has been: Any Value'. you'd then add in a 2nd conditional trigger 'And Device has a value that is not Off'

    Click image for larger version

Name:	image.png
Views:	255
Size:	50.6 KB
ID:	1611739
    HS4 Pro on Shuttle NC10U, Win10; Z-NET
    Number of Devices: 1005
    Number of Events: 293

    Plug-Ins: BLLock, DirecTv, EasyTrigger, Honeywell WiFi Thermostat, Marquis monoprice Amp, MeiHarmonyHub, PHLocation2, Pushover 3P, UltraM1G3, rnbWeather, Worx Landroid, Z-Wave

    External applications: Homebridge-homeseer, Geofency, EgiGeoZone.

    Comment


      #3
      You might find something in this thread. I put my 2 cents in in post Non-HomeSeer Related How do you setup your motion enabled lighting events - HomeSeer Message Board

      Comment


        #4
        For the basic using a timer scenario:

        - create a timer with a suitable name
        - create your start event which does something (or triggers off something) and then uses the action "Start Timer"
        - create your end event which triggers on "A timer's value becomes..." the time you want
        - in the end event stop the timer (for neatness, it doesn't actually matter), and do what you need

        The names of the timer actions aren't necessarily clear - they're actually:

        Start = Start from zero (including setting it running)
        Stop = Pause running
        Resume = Resume running
        Set to time = Set to time but do not change the running / paused state

        Unfortunately they can't count down - for display purposes that would be nicer in many cases :-(

        Comment


          #5
          I made the timer, and in a event The trigger was the motion sensor. Then in the action I turned the light on and started the timer. That worked.
          I then made a event stating " when timer is over" X time turn off light, stop timer, but don't have the option to reset.. I know I'm doing something wrong
          Hector
          ____________________________________
          Win.2003 OS, HS3
          BLDSC,BLstat,BLRadar,BLRamdom,BLOccupied
          BLups,BLrain8,HSTouch,Ultrajones Weatherbug,
          MyTrigger,ACRF2,W800,Zwave
          AP800,Honeywell Stat

          Comment


            #6
            The timer is reset when you "start" it.

            Comment


              #7
              You can also stop the timer then set the timer to 0. When I’m looking at a timer I want it to be stopped and at 0 when not being used.

              Click image for larger version

Name:	image.png
Views:	234
Size:	38.1 KB
ID:	1611823
              HS4 Pro, 4.2.19.0 Windows 10 pro, Supermicro LP Xeon

              Comment


                #8
                Is there any way to get higher resolution than one second?

                Comment


                  #9
                  Originally posted by Younglake View Post
                  Is there any way to get higher resolution than one second?
                  No, there isn't.

                  HS4 Pro, 4.2.19.0 Windows 10 pro, Supermicro LP Xeon

                  Comment


                    #10
                    Originally posted by randy View Post
                    No, there isn't.
                    Thank you Randy.

                    Comment


                      #11
                      Thank you guys, I got it working... thank you all.
                      Hector
                      ____________________________________
                      Win.2003 OS, HS3
                      BLDSC,BLstat,BLRadar,BLRamdom,BLOccupied
                      BLups,BLrain8,HSTouch,Ultrajones Weatherbug,
                      MyTrigger,ACRF2,W800,Zwave
                      AP800,Honeywell Stat

                      Comment


                        #12
                        Is there a difference when turning off switches that are dimmer VS on/off switch? I am seeing that when a dimmer switch is about to turn off and it's gets a signal to turn on it flickers and continues to turn off.
                        Hector
                        ____________________________________
                        Win.2003 OS, HS3
                        BLDSC,BLstat,BLRadar,BLRamdom,BLOccupied
                        BLups,BLrain8,HSTouch,Ultrajones Weatherbug,
                        MyTrigger,ACRF2,W800,Zwave
                        AP800,Honeywell Stat

                        Comment


                          #13
                          That would be affected by the ramp rate setting. Switches are instant but a dimmer can be set such that it takes seconds to complete a turn off or setting to an on level. If it is a slow ramp, a dimmer could take seconds to fully turn off before it can accept a new command.
                          HS4 Pro, 4.2.19.0 Windows 10 pro, Supermicro LP Xeon

                          Comment


                            #14
                            Originally posted by Younglake View Post
                            Is there any way to get higher resolution than one second?
                            I believe you can, if you want to learn scripting...
                            HomeSeer Version: HS4 Pro Edition 4.2.19.0 (Windows - Running as a Service)
                            Home Assistant 2024.3
                            Operating System: Microsoft Windows 11 Pro - Desktop
                            Z-Wave Devices via two Z-Net G3s
                            Zigbee Devices via RaspBee on RPi 3b+
                            WiFi Devices via Internal Router.

                            Enabled Plug-Ins
                            AK GoogleCalendar 4.0.4.16,AK HomeAssistant 4.0.1.23,AK SmartDevice 4.0.5.1,AK Weather 4.0.5.181,AmbientWeather 3.0.1.9,Big6 3.44.0.0,BLBackup 2.0.64.0,BLGData 3.0.55.0,BLLock 3.0.39.0,BLUPS 2.0.26.0,Device History 4.5.1.1,EasyTrigger 3.0.0.76,Harmony Hub 4.0.14.0,HSBuddy 4.51.303.0,JowiHue 4.1.4.0,LG ThinQ 4.0.26.0,ONVIF Events 1.0.0.5,SDJ-Health 3.1.1.9,TPLinkSmartHome4 2022.12.30.0,UltraCID3 3.0.6681.34300,Z-Wave 4.1.3.0

                            Comment


                              #15
                              It is possible. When I write a timer value to the log I get 7 decimal points of precision. If you use Events it is only resolved to seconds. Here I stop a timer and write its value to the log.

                              From my log:
                              Circulator ON Normal Cycle - 01:01:21.1034686

                              There are only two scripting calls for timers 1) reset hs.TimerReset("my timer") and 2) read value hs.TimerValue("mytimer")
                              HS4 Pro, 4.2.19.0 Windows 10 pro, Supermicro LP Xeon

                              Comment

                              Working...
                              X