Announcement

Collapse
No announcement yet.

HS3 Counters and Timers

Collapse
This is a sticky topic.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    HS3 Counters and Timers

    Some folks have been asking/wondering about counters and timers. Thought I'd share a little something I whipped up here at the office. Perhaps others could share too.

    How to turn a 1-button scene controller into multi-scene controller
    In this example, I created a series of events that are launched by tapping a single paddle scene controller multiple times.

    2 taps on = my office light and reception lights turn on
    2 taps off = my office light and reception lights turn off

    3 taps on = reception lights turn on
    3 taps off = reception lights turn off

    5 taps on = my office lights turn on
    5 taps off = my office lights turn off

    To accomplish this, I created a "Lighting Timer" and 2 counters, "Lighting On" and "Lighting Off". Then, I created the events below.

    In operation, tapping the paddle on the controller on or off starts the timer. Each tap on increments the "Lighting On" counter; each tap off increments the "Lighting Off" counter. Once the timer reach 2 seconds, it launches the appropriate lighting event based on the number of taps received. Each lighting event includes an action to run the Group Actions... thus stopping the timer and resetting the counters. A failsafe event is also included to reset the counters and timer after 4 seconds, if the number of taps received is anything other than 2, 3 or 5.



    So... what have you guys done with this feature? Love to hear...
    💁‍♂️ Support & Customer Service 🙋‍♂️ Sales Questions 🛒 Shop HomeSeer Products

    #2
    This is cool. My two year old is going to love this. 1 click, light on, 2 click light on for 5 minutes, 3 click, play audio bwuahahahah.
    _______________________________________________

    HS3 : HSpro (3.0.0.460) on Win2012 (vm on ESXi)
    Plugins: HSTouch, UPBSpud, Kinect, Nest, IFTTT, DirecTV, EasyTrigger, Imperihome, Zwave, RFXcom, UltraMon3, UltraWeatherBug3, UltraGCIR3, UltraLog3, UltraPioneer, PHLocation, Pushover, Pushalot, MCSSPrinklers S, JowiHue
    Jon00 Plugins: Bluetooth Proximity, Performance Monitor, DB Chart, Links

    Comment


      #3
      Re: HS3 Counters and Timers

      This will become very useful when Instant Status starts working with our multi instance multi level zwave devices over here in Euro land

      Sent from my Nexus 7 using Tapatalk 2
      Nicolai L

      Comment


        #4
        so when you say counter.. is it what i am thinking of?
        i would like to have it count how many times my ds10a is tripped (sump pump)????
        HW - i5 4570T @2.9ghz runs @11w | 8gb ram | 128gb ssd OS - Win10 x64

        HS - HS3 Pro Edition 3.0.0.435

        Plugins - BLRF 2.0.94.0 | Concord 4 3.1.13.10 | HSBuddy 3.9.605.5 | HSTouch Server 3.0.0.68 | RFXCOM 30.0.0.36 | X10 3.0.0.36 | Z-Wave 3.0.1.190

        Hardware - EdgePort/4 DB9 Serial | RFXCOM 433MHz USB Transceiver | Superbus 2000 for Concord 4 | TI103 X-10 Interface | WGL Designs W800 RF | Z-Net Z-Wave Interface

        Comment


          #5
          I was just thinking about this. I have an event that allows me to "see" slow double taps, where I just variables to trap the time between taps. The "in 2 seconds" type of action is REALLY going to simplify my scripting for 3 and 4 taps!

          I never finished implementing the 3 taps (or more) because it was getting difficult to tell the difference between 2 taps and 2 "fast" taps and 1 "slow" tap (3 taps total).

          Any word on the UPB plugin? I can't really test this out until then.

          --Dan
          Tasker, to a person who does Homeautomation...is like walking up to a Crack Treatment facility with a truck full of 3lb bags of crack. Then for each person that walks in and out smack them in the face with an open bag.

          Comment


            #6
            Has anyone found a simple way to display a counter with its value as a device on the Home page?

            I have a counter which increments by 1 (in a simple event) each time we use 1 litre of water. I should like to show the litres used, ie the counter value, in a simple way.

            or am I misusing counters? should I just set up a virtual device and increment its value?

            Comment


              #7
              any one done this yet ?
              Neil
              Newmarket Ontario

              Comment


                #8
                Re: HS3 Counters and Timers

                No.. i only have 5% of my devices in hs right now....

                Sent from my Samsung Galaxy Note 3
                HW - i5 4570T @2.9ghz runs @11w | 8gb ram | 128gb ssd OS - Win10 x64

                HS - HS3 Pro Edition 3.0.0.435

                Plugins - BLRF 2.0.94.0 | Concord 4 3.1.13.10 | HSBuddy 3.9.605.5 | HSTouch Server 3.0.0.68 | RFXCOM 30.0.0.36 | X10 3.0.0.36 | Z-Wave 3.0.1.190

                Hardware - EdgePort/4 DB9 Serial | RFXCOM 433MHz USB Transceiver | Superbus 2000 for Concord 4 | TI103 X-10 Interface | WGL Designs W800 RF | Z-Net Z-Wave Interface

                Comment


                  #9
                  There is no way that I know of to get or set counters other than through events or the counter management page. There are a couple of script functions to manipulate timers, but it is very limited. I would like to see counter and full timer support in scripts. To start and stop a timer, for example, I had to create a manual event for each action on each timer and trigger those events from a script. It works, but it is clunky.

                  Bill

                  Comment


                    #10
                    Is it me or is there a trick to adding a counter or timer. Every time I try to create one on the web tab it just sits there and does nothing. It will not create anything. All I can do is hit the big "x" on the upper right corner which cancels it out. I am running Beta .42. Any guidance would be helpful.

                    Comment


                      #11
                      Originally posted by Sean Willoughby View Post
                      Is it me or is there a trick to adding a counter or timer. Every time I try to create one on the web tab it just sits there and does nothing. It will not create anything. All I can do is hit the big "x" on the upper right corner which cancels it out. I am running Beta .42. Any guidance would be helpful.
                      I just created both here with Chrome and they work fine. Which browser are you using?
                      HS4Pro on a Raspberry Pi4
                      54 Z-Wave Nodes / 21 Zigbee Devices / 108 Events / 767 Devices
                      Plugins: Z-Wave / Zigbee Plus / EasyTrigger / AK Weather / OMNI

                      HSTouch Clients: 1 Android

                      Comment


                        #12
                        I think Rich tricked out the timer and counter calls in latest version. See the help page.
                        Originally posted by bdickhaus View Post
                        There is no way that I know of to get or set counters other than through events or the counter management page. There are a couple of script functions to manipulate timers, but it is very limited. I would like to see counter and full timer support in scripts. To start and stop a timer, for example, I had to create a manual event for each action on each timer and trigger those events from a script. It works, but it is clunky.

                        Bill
                        Don

                        Comment


                          #13
                          There are still some timer functions I would like to see that aren't there. I'm going to open a ticket for an enhancement request. I would like to be able to stop, start and set timers from a script. TimerReset sets the timer to zero, but automatically starts it, I'd like to be able to set a timer to zero, but leave it in whatever state it is in (running or stopped).

                          Bill

                          Comment


                            #14
                            It is working now. Weird thing is I had to create a timer through an event and then things started working on the Timer/Counter Page. Just needed a kick start! BTW I am using IE10.

                            Comment


                              #15
                              Cool stuff, is there anyway to display the timer and counter values in HSTouch?
                              Billy

                              Comment

                              Working...
                              X