Sonoff S20 Smart Socket - RTurala/Sonoff-Tasmota GitHub Wiki
- Itead Product Page: http://sonoff.itead.cc/en/products/residential/s20-socket
- Itead Wiki: https://www.itead.cc/wiki/S20_Smart_Socket
Please see the Hardware Preparation page for general instructions.
The picture shows how to program the S20 Smart Socket powered by the FTDI USB converter. With newer US sockets, either use a right-angle header, or remove the header after flashing. Otherwise, the pushbutton may rub against a pin and get stuck.Be sure it is NOT plugged in!
Remove the "hidden" screw.
Remove the board so you can access the GND,TXD,RXD,VCCIO better. There are 2 screws. At the Red and the Blue cable. Be careful not to damage the soldered connection!
Connect the jumper cables.
RX and TX is reversed.
From top to bottom (see image below):
- Vcc (3,3V)
- TXD
- RXD
- GND
Connected? Hold the little button pressed while connecting the USB cable to your Notebook, PC etc. after ca. 2 sec. let go of the button. It is now in flashing mode. Follow the Hardware Preparation page for general instructions.
sonoff.items:
Switch S20_1 "Coffee S20-1 Powerplug" (LR,gLight)
{ mqtt=">[broker:cmnd/sonoff-S20-1/POWER:command:*:default],
<[broker:stat/sonoff-S20-1/POWER:state:default],
<[broker:stat/sonoff-S20-1/RESULT:state:JSONPATH($.POWER)],
<[broker:tele/sonoff-S20-1/STATE:state:JSONPATH($.POWER)]
"}
Switch S20_1_Reachable "S20-1 reachable" <contact> (gReachable)
{ mqtt="<[broker:tele/sonoff-S20-1/LWT:state:MAP(reachable.map)],
<[broker:stat/sonoff-S20-1/RESULT:state:ON],
<[broker:stat/sonoff-S20-1/POWER:state:ON],
<[broker:tele/sonoff-S20-1/STATE:state:ON]
" }
default.sitemap:
Switch item=S20_1 labelcolor=[S20_1_Reachable == "ON" = "green",S20_1_Reachable == "OFF" = "red"]