Announcement

Collapse
No announcement yet.

Easy Trigger plug-in - Feature Requests

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

  • Originally posted by spud View Post
    I think I could add an optional condition to all the EasyTrigger actions. This condition field would only appear if the advanced mode is activated, and would be defined using a boolean expression that can contains replacement variables (e.g. $$DVR:234: == 0)
    What do you think?
    I think that would work as along as it only affects that "action" and not all actions in an event
    Thanks,
    Frank

    Comment


    • Originally posted by jpick View Post
      Hi, I would like to be able to display on the HSTouch app the time of the next scheduled change.

      My use case: I am using the easy trigger schedule for my boiler control. "IF time enters boiler time range set boiler to on". What I would like to do at this point is put the next leaving time of the schedule on the HSTouch app. This allows a user to clearly see when the boiler will next go off (or on).

      I can see that this could be done by setting a value on a virtual device. Or updating a timer value to this specific time.

      Are there any other ways of doing this? Is is possible for EasyTrigger to set this value?

      Thanks for any thoughts.
      The plug-in has a
      Code:
      GetSchedule(string scheduleName)
      scripting function, so you could build a script to parse the schedule and find the next scheduled range.

      or to make things easier for you, I could add the following scripting functions:

      Code:
      GetScheduleNextTimeRangeStart(string scheduleName)
      GetScheduleNextTimeRangeEnd(string scheduleName)
      what do you think?

      Comment


      • Originally posted by spud View Post
        The plug-in has a
        Code:
        GetSchedule(string scheduleName)
        scripting function, so you could build a script to parse the schedule and find the next scheduled range.

        or to make things easier for you, I could add the following scripting functions:

        Code:
        GetScheduleNextTimeRangeStart(string scheduleName)
        GetScheduleNextTimeRangeEnd(string scheduleName)
        what do you think?
        That would be excellent thanks! ... I think
        Although I'm going to have to do a bit of reading on how scripts work. Something long overdue I suspect!
        Last edited by jpick; January 19th, 2017, 06:38 AM.

        Comment


        • Hi Spud,
          is there any way we can do things with CAPI status in the PI?
          I'm trying to bulletproof things for my system, and I do get the odd device where it can go into an unknown status - I'd like to be able to trigger something on that, however this isn't native within HS.
          It is exposed with CAPI however, so wondering if this could be potentially done - just to test if a device is set to Unknown, as the values are pretty much covered by the other device properties.
          Cheers

          Comment


          • Originally posted by Furious View Post
            Hi Spud,
            is there any way we can do things with CAPI status in the PI?
            I'm trying to bulletproof things for my system, and I do get the odd device where it can go into an unknown status - I'd like to be able to trigger something on that, however this isn't native within HS.
            It is exposed with CAPI however, so wondering if this could be potentially done - just to test if a device is set to Unknown, as the values are pretty much covered by the other device properties.
            Cheers
            What do you call "CAPI status" ?
            A device can have a value and a string status, both can be used with the EasyTrigger plugin
            Your Unknown status is probably associated to a value

            Comment


            • Originally posted by spud View Post
              What do you call "CAPI status" ?
              A device can have a value and a string status, both can be used with the EasyTrigger plugin
              Your Unknown status is probably associated to a value
              With zwave, if a device is polled and is offline/hung/not reachable, the gui status and the status icon go to "unknown" - the device value and the device string stay the same as they were before being marked as unknown.

              With CAPI you can query a device for this status string - I currently use a script to poll all devices and get their string and then set the actual device string to "Zwave broken" and trigger off that, just wondered if it could be something to be added as an extra trigger.

              Basically allows polling devices without having to worry about accidental powering down - too many polls of offline devices can cause zwave to hang in my experience.

              Comment


              • Originally posted by Furious View Post
                With zwave, if a device is polled and is offline/hung/not reachable, the gui status and the status icon go to "unknown" - the device value and the device string stay the same as they were before being marked as unknown.

                With CAPI you can query a device for this status string - I currently use a script to poll all devices and get their string and then set the actual device string to "Zwave broken" and trigger off that, just wondered if it could be something to be added as an extra trigger.

                Basically allows polling devices without having to worry about accidental powering down - too many polls of offline devices can cause zwave to hang in my experience.
                I've wanted to do something similar, but we should probably ask HS to expose the functionality by changing either the status to some value (-99 as one option), or actually changing the the String to "Unknown". It seems like they are bypassing their own API with the way they do it right now.

                Cheers
                Al
                HS 3.0.0.548: 1976 Devices 1156 Events
                Z-Wave 3.0.1.262: 123 Nodes on one Z-Net

                Comment


                • Originally posted by AutomatedJim View Post
                  I like the toggle feature but not being able to have it 'start over' if someone manually changes the light had me confused.

                  Can an action be added to reset the toggle to the beginning if someone manually operates the switch?

                  IE: I set up a light to start at on, then dim to 75%, 50%, 25%, off. It has toggled through to 25%, someone walks up to the switch and manually turns the light on to 100%. The reset action would start the toggle process over. Another scenario, the light has toggled down to 25%, someone raised the dim level to 80%. The toggle process doesn't reset completely, only to the next value, IE in my example 75%.

                  Thanks,

                  Jim
                  in version 3.0.0.31 available here, there is now an advanced option (you have to be in "Advanced editing mode" to see it) that solves this problem:

                  Click image for larger version

Name:	toggleadvancedoption.png
Views:	1
Size:	14.4 KB
ID:	1188631

                  Comment


                  • Originally posted by spud View Post
                    The plug-in has a
                    Code:
                    GetSchedule(string scheduleName)
                    scripting function, so you could build a script to parse the schedule and find the next scheduled range.

                    or to make things easier for you, I could add the following scripting functions:

                    Code:
                    GetScheduleNextTimeRangeStart(string scheduleName)
                    GetScheduleNextTimeRangeEnd(string scheduleName)
                    what do you think?
                    these functions have been added in version 3.0.0.31

                    here is a C# example script, in this example the schedule name is "Test"

                    Code:
                    public object Main(object[] Parms)
                    {
                    	string nextStart = (string) hs.PluginFunction("EasyTrigger", "", "GetScheduleNextTimeRangeStart", new object[] { "Test" });
                    	string nextEnd = (string) hs.PluginFunction("EasyTrigger", "", "GetScheduleNextTimeRangeEnd", new object[] { "Test" });
                    	
                    	
                    	hs.WriteLog("EasyTrigger Script", "Next Start = " + nextStart);
                    	hs.WriteLog("EasyTrigger Script", "Next End = " + nextEnd);
                    	return 0;
                    }

                    Comment


                    • Originally posted by spud View Post
                      in version 3.0.0.31 available here, there is now an advanced option (you have to be in "Advanced editing mode" to see it) that solves this problem:

                      [ATTACH]59008[/ATTACH]
                      This really helps, as does the event filtering on devices used in Easy Trigger.


                      Thank you.
                      Randy Prade
                      Aurora, CO
                      Prades.net

                      PHLocation - Pushover - EasyTrigger - UltraECM3 - Ultra1Wire3 - Arduino

                      Comment


                      • Originally posted by spud View Post
                        these functions have been added in version 3.0.0.31

                        here is a C# example script, in this example the schedule name is "Test"

                        Code:
                        public object Main(object[] Parms)
                        {
                        	string nextStart = (string) hs.PluginFunction("EasyTrigger", "", "GetScheduleNextTimeRangeStart", new object[] { "Test" });
                        	string nextEnd = (string) hs.PluginFunction("EasyTrigger", "", "GetScheduleNextTimeRangeEnd", new object[] { "Test" });
                        	
                        	
                        	hs.WriteLog("EasyTrigger Script", "Next Start = " + nextStart);
                        	hs.WriteLog("EasyTrigger Script", "Next End = " + nextEnd);
                        	return 0;
                        }

                        Spud many thanks for these 2 functions. They are fantastic. Also thanks for the sample script which was enormously helpful. I made a slight change to update the string of a virtual device and from there I displayed it onto the HSTouch screen. Exactly what I was wanting to achieve.

                        Comment


                        • Device in z state for x minutes/hours in the past y minutes/hours/days

                          Hi Spud,
                          I purchased EasyTrigger and Ecobee (thanks for fixing the fan mode setting a temp hold) and wondering if there was a way to set a condition similar to the title explains? I could have a trigger be a door sensor or light switch and then have an event perform an action if the room was occupied for a certain length of time.

                          This would be especially handy for motion and door sensors. Especially with motion sensors that turn off if the person is still. I am having an issue where a person goes into a room, sits down, then leaves but the motion sensor is seeing it as two different events.

                          Comment


                          • Originally posted by mwolter View Post
                            Hi Spud,
                            I purchased EasyTrigger and Ecobee (thanks for fixing the fan mode setting a temp hold) and wondering if there was a way to set a condition similar to the title explains? I could have a trigger be a door sensor or light switch and then have an event perform an action if the room was occupied for a certain length of time.

                            This would be especially handy for motion and door sensors. Especially with motion sensors that turn off if the person is still. I am having an issue where a person goes into a room, sits down, then leaves but the motion sensor is seeing it as two different events.
                            I'm not sure to understand the condition and how you would use it?

                            Let's say for example a device is On for 5 minutes then is Off for 2 minutes (and still currently Off)
                            Then the condition "Device in On state for 5 minutes in the past 10 minutes" would return true?
                            Please give some example of how you would use that.

                            Comment


                            • Yes, that is the general idea of how it would work. If the device is in the specified state for the minimum time within a period then the condition would return true.

                              My particular use case would be to use this function to monitor a motion sensor and turn on a virtual device. So basically the virtual device would turn on to indicate the room is occupied, then off when no motion is sensed for a minimum time in a period. In effect making an 'occupancy sensor' if you will. Not sure if I'm explaining this properly, let me know if you need more info.

                              This could be added to the trigger 'This device's value has been in the range [X,Y] for exactly...' or to the condition 'This device has been/for at least...' by adding 'in the past' and a time selection function.

                              See below for an example of how I would use this:

                              IF: Motion sensor in the garage changes and becomes 'Motion'

                              OR IF: The event will automatically trigger every... five minutes
                              AND IF: Motion has been detected in the garage for five minutes in the past 20 minutes

                              THEN: Cancel a Delayed Device action for the 'Garage Occupancy Virtual Device'
                              THEN: Turn on 'Garage Occupancy Virtual Device'
                              THEN: Turn off 'Garage Occupancy Virtual Device' After Waiting: 30 minutes

                              I can also see many other instances where this function could be useful. For example, this could be used with a temp, humidity, luminescence, wind or other sensors where the value fluctuates and you don't need it triggering immediately but want reliable value.

                              Comment


                              • Parsing a string

                                Here is what I'm trying to do.

                                Example String:
                                mqtt device string looks like this {"progress": 93, "location": "local", "path": "MM_Leg_Stand_PETG.gcode"}

                                Desired Feature:
                                1) Monitor device string, and if device string changes and contains "progress":
                                2) Take the "93" from with-in the device string and append another devices string value with it.

                                Completed Example:
                                2nd Device Original String Value: Printing PETG : 11:53 AM
                                2nd Device Appended String Value: Printing PETG : 11:53 AM 93%
                                Last edited by ServiceXp; March 18th, 2017, 04:44 PM.
                                RJ_Make On YouTube

                                Comment

                                Working...
                                X