First of all, I wanted to say that I am new in "smart-house" family... I am doing this to learn new things and they are awweesssommee
I managed to make a hardware lamp. It's an esp8266 esp 12 that controls a light. with ESP Easy 120.
I have some problems here.
I managed to make the configurations for the relay. On GPIO4 (lightSwitch) I have the Switch for the lamp and GPIO5(lightState) is the relay, settings are from this video: https://youtu.be/Kp4KJVbOWd0.
The Rule is this one:
Code: Select all
on lightSwitch#Switch do
if[lightState#Switch]=1
gpio,5,0
else
gpio,5,1
endif
endon
If I push the button the light goes off, if I push the button again...it doesn't come back.. I don't know what to do in this case.
The second thing, how can I add a digital button to my openhab sitemap?
I google it both things but I don't know how to really search for them...
Thank you
P.S. the relay it's like the one on the picture attached