i am in the process of migrating webcore to sharptools. i have a rule that relies on the condition of a temperature sensor: “rises above” or “drops below”. it would be excellent if this could be implemented in sharptools are a condition/trigger.
Good idea, I’ve been pondering about making a thermostat that combines my central heating with the airconditioner. To incorporate the outside temperature, when it wouldn’t be beneficial to use the aircon anymore.
My use case is having code turn on a ceiling fan after the thermostat calls for heat and the temperature reported by a vent exceeds 80 degrees (no sense in starting the fan early if the incoming air near the ceiling isn’t warm enough yet). Hence my need for a trigger only once when the vent temperature crosses the 80 degree threshold on the way up. Josh posted some code that helps me do something similar, but pointed to this feature request to have it implemented natively, so I came over here to give this my vote.
When configuring a trigger within this beta version, you’ll notice a new option labeled ‘On Transition Only’. This nifty feature changes the operator from ‘updates and is greater than’ → ‘changes to greater than’.
This means that your rule will only be activated when the configured trigger initially transitions to true… and will only reactivate once the trigger leaves the configured state and revisits it. In other words, your rule comes into action only when the value ‘ascends above’ or ‘descends below’ your set threshold.