I have managed to write a rule that is “timer based” turn off after 15 mins etc
I now have a requirement to “do something” if a specific temperature is reached, the problem is I dont know where to start I have managed some basics such as
Item mySwitch changed from OFF to ON
but I need some help/pointers on how to refer to temperature. such as if temp > 20 “do something”
Use a rule that triggers on the Change event of item that holds the temperature and use in the body an if statement that checks if the temperature is above the given value.
Something like:
val Number mySpecificTemperature=20
rule "Temperature Checker"
when
Item YourTempItem changed
then
if YourTempItem.state>mySpecificTemperature {
'do whatever you need to do
}
end