Why is this rule not working?

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
Thersellse
New user
Posts: 2
Joined: 12 Jan 2018, 20:32

Why is this rule not working?

#1 Post by Thersellse » 12 Jan 2018, 20:41

Hi,

sorry, I'm new ot ESP Easy ... using 120 on an sonoff S20.
I tried to use the following rules:

Code: Select all

on switchon do
  gpio 12,1
  gpio 13,1
endon

on switchoff do
  gpio 12,0
  gpio 13,0
endon

on Clock#Time=All,20:30 do
    event switchon
    timerSet,1,10
endon

on Rules#Timer=1
     event switchoff
endon

on System#Boot
   gpio 13,0
endon
According to the debug log "System#Boot" is triggered - but the gpio command is not executed. Also the Clock#Timer is triggered (+ ACT: timerSet,1,10) - but the event "switchoff" is not triggered - although the event "Rules#Timer=1" fired.

Code: Select all

EVENT: Clock#Time=Fri,20:40
ACT  : event switchon
EVENT: switchon
ACT  : gpio 12,1
SW   : GPIO 12 Set to 1
ACT  : gpio 13,1
SW   : GPIO 13 Set to 1
ACT  : timerSet,1,10
EVENT: Rules#Timer=1
WD   : Uptime 12 ConnectFailures 0 FreeMem 27776
WD   : Uptime 13 ConnectFailures 0 FreeMem 27776
EVENT: Clock#Time=Fri,20:41
What am i doing wrong?

Thanks!

User avatar
vader
Normal user
Posts: 241
Joined: 21 Mar 2017, 17:35

Re: Why is this rule not working?

#2 Post by vader » 12 Jan 2018, 22:03

It must be..

on System#Boot do

on Rules#Timer=1 do

Thersellse
New user
Posts: 2
Joined: 12 Jan 2018, 20:32

Re: Why is this rule not working?

#3 Post by Thersellse » 13 Jan 2018, 12:52

many thanks you made my day!

Post Reply

Who is online

Users browsing this forum: No registered users and 45 guests