Help with fan rule

Hi

I have a rule which is meant to check the temperature of the bedroom every 30 minutes when the house is in either night or evening mode then turn on or off the fan depending on that. If the house is in day or away then the repeat should stop until the mode changes again.

However I have found that even during day mode my rule is repeating :frowning: What have I done wrong?

I expect this is a trigger problem. I think you should trigger your rule on mode changes and every 30 minutes instead of using repeats.

Perhaps like this:

Stole an example from one of my own rules. Adjust as @dadarkgtprince illustrates below.

S

change your trigger to a periodic schedule instead of mode changed (on the 0 and 30)

If Mode in Day,Away THEN
-If Temperature > 22 AND Override is off THEN
--On: Fan
-ELSE-IF Temp < 22 OR Override is on THEN
--Off: Fan
-END-IF
ELSE-IF Mode in Night,Evening THEN
-Off: Fan
END-IF

1 Like

Thanks both. I have updated the rules and will see how that goes :slight_smile: Much appreciated.

It looks like changing the trigger will solve most of your problems, but there appear to be some structural issues with the rule as well....

  • your last ELSE-IF in a group can usually be a simple ELSE statement. Something the rule should do if none of your IF or ELSE-IF conditions is true. It looks like you could eliminate a couple conditions by just using ELSE.
  • I can't see the problem, but your final ELSE-IF appears to be nested with your second IF statement. It shouldn't be indented like it appears to be based on my understanding of the rule. It might be due to the Repeat directly above it.
  • Repeating actions are structured similar to IF statements. The first line is a "Repeat every .... minutes" and the last line is END-REP. The repeating actions (and usually a condition to cancel them) are located between these two commands.
1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.