Sonoff Wifi 5-pin LED control
Moderators: grovkillen, Stuntteam, TD-er
Sonoff Wifi 5-pin LED control
Hi,
I've gor my Sonoff flashed (147) and under 2-way control with Domoticz and some Rules.
The relay switches, and the LED goes on and off as required.
However, the LED, even when off, switches back on whenever the Sonoff sends any data back to Domoticz, e.g. RSSI.
If the LED is already on, it blinks!
Is this something hardwired into the device?
I've gor my Sonoff flashed (147) and under 2-way control with Domoticz and some Rules.
The relay switches, and the LED goes on and off as required.
However, the LED, even when off, switches back on whenever the Sonoff sends any data back to Domoticz, e.g. RSSI.
If the LED is already on, it blinks!
Is this something hardwired into the device?
Domoticz, Sonoff, ESP32
Re: Sonoff Wifi 5-pin LED control
Post your rules!
Re: Sonoff Wifi 5-pin LED control
Rules as requested.
SW0 = Push switch GPIO-0
Relay, State = GPIO-12 and its Value
SW0 = Push switch GPIO-0
Relay, State = GPIO-12 and its Value
Code: Select all
on TurnOn do
if [Relay#State]=0
gpio,13,0
gpio,12,1
inputswitchstate 0,1
endif
endon
on TurnOff do
if [Relay#State]=1
gpio,13,1
gpio,12,0
inputswitchstate 0,0
endif
endon
on Toggle do
event,ToggleRelay
endon
on SW0#Switch=1 do
event,ToggleRelay
endon
on ToggleRelay do
if [Relay#State]=1
gpio,13,1
gpio,12,0
inputswitchstate 0,0
else
gpio,13,0
gpio,12,1
inputswitchstate 0,1
endif
endon
On System#Boot do //When the ESP boots, do
timerSet,1,10 //Set Timer 1 for the next event in 10 seconds
endon
On Rules#Timer=1 do //When Timer1 expires, do
SendToHTTP RaspberryPi,8080,/json.htm?type=command=switchlight&idx=2313&switchcmd=Off
Pulse,13,0,500
gpio,12,0
endon
Domoticz, Sonoff, ESP32
Re: Sonoff Wifi 5-pin LED control
Remove all lines with 'inputswitchstate x,y', try again and post your results please.
Re: Sonoff Wifi 5-pin LED control
Hi Data,
Thanks, but I'm sure that the LED is also controlled by the main ESP code, overriding my settings.
I have had a look in the code.
The function void statusLED(boolean traffic) in Misc.ino is called from several places.
It certainly appears to make the blink I noticed when device data is sent to Domoticz and the LED is already on.
Also, if Wifi is connected, the LED state is set LOW which I guess is ON.
Thanks, but I'm sure that the LED is also controlled by the main ESP code, overriding my settings.
I have had a look in the code.
The function void statusLED(boolean traffic) in Misc.ino is called from several places.
It certainly appears to make the blink I noticed when device data is sent to Domoticz and the LED is already on.
Also, if Wifi is connected, the LED state is set LOW which I guess is ON.
Domoticz, Sonoff, ESP32
Re: Sonoff Wifi 5-pin LED control
Have you made any changes on the GPIO page?
I have the same setup as you do but have not this issue.
I have the same setup as you do but have not this issue.
Re: Sonoff Wifi 5-pin LED control
Hi Data,
Thanks for pointing me in the right direction!
In Hardware, I had set Wifi Status Led: to 13.
Setting it blank fixes it.
Thanks for pointing me in the right direction!
In Hardware, I had set Wifi Status Led: to 13.
Setting it blank fixes it.
Domoticz, Sonoff, ESP32
Re: Sonoff Wifi 5-pin LED control
Hello i am new in sonoff esp things anf might have killed my firt one
It would de helpfull to see what you have exactly done in all menues of the espy easy pages when flashing the sonoff to R120/147
I think and hope most people will have this first
pressing the button and switching the relais with status LED
sincerly
Michael
It would de helpfull to see what you have exactly done in all menues of the espy easy pages when flashing the sonoff to R120/147
I think and hope most people will have this first
pressing the button and switching the relais with status LED
sincerly
Michael
Who is online
Users browsing this forum: No registered users and 98 guests