newbie and Rules

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
leafy
New user
Posts: 3
Joined: 18 Jun 2017, 01:43

newbie and Rules

#1 Post by leafy » 22 Jun 2017, 19:38

Hi,I am trying to switch a relay on controller 1( gpio 12) by using a rule on controller 2.
Need assistance to troubleshoot were i am going wrong.
the rule on controller 1 is :-
On PIR#Switch=1 do
if [LDR#Light]<300
sendTo 2,event,lighton
endon
the Html command
http://192.168.1.11/control?cmd=event,lighton
works..
rule for lighton is :-
On lighton do
gpio ,12,1
endon

Cheers

User avatar
grovkillen
Core team member
Posts: 3621
Joined: 19 Jan 2017, 12:56
Location: Hudiksvall, Sweden
Contact:

Re: newbie and Rules

#2 Post by grovkillen » 22 Jun 2017, 20:03

When you say "controller" 1 and 2 do you mean ESP Easy units?
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you :idea: :idea: :idea:

leafy
New user
Posts: 3
Joined: 18 Jun 2017, 01:43

Re: newbie and Rules

#3 Post by leafy » 22 Jun 2017, 21:43

yeah .. I have sorted it thanks to this post https://www.letscontrolit.com/forum/vie ... f=6&t=2992
I did not realize that PIR was the name parameter ....
As i was using mqtt i thought it would be easier to have all my names set to the room location (livingroom).
Have amended setup now and it is working .
my new rule is :-
On PIR#Switch=1 do
if [LDR#Light]<150
sendTo 2,event,lighton
timerSet,1,10
endon
On Rules#Timer=1 do
sendTo 2,event,lightoff
endon

thank you for reply

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot] and 43 guests