|
Post by papa on Apr 21, 2019 14:27:23 GMT
Program Itead Sonoff S26 ECOPlug (ESP8266) Introduction If you don't have an S 26 ECOPlug & S 20 ECOPlugs are still available, I recommend you buy & reprogram an S20 which is easier (See this thread). However, if you have or get an S26 ECOPlug, the I believe the following might make it fairly easy to re-program an S26 even with NO soldering.The S26 ECOplug I received differs in construction from my S20s. The S26 mostly functions like an S20, except for one important difference (see next post). S26's Similarities to the S20:
The S26 LEDs function similarly & the GPIO pins are the same. My S26 has a green LED that blinks while connecting to WiFi & then is solid when connected. An orange LED lights when the relay is tripped (via push button, via openHAB) to deliver AC power through the female mains socket. The green LED does not blink when the S26 is in flashing mode. Opening the S26 case is similar to the S20. Remove 3 screws instead of one. Again separate the case halves by using a fingernail or flat screwdriver head in the case seam that runs around the middle of the case sides.
One can flash S26s with new programming in much the same way as an S20 ( again, see this thread): To enter the S26's re-programming mode (as with the S20) press the push button & hold it while plugging the FTDI device into USB. Then we can release the push button & proceed with uploading programming with the Arduino IDE. However, the S26's programming/toggling push button is more awkward to reach. I used a pencil stub which is skinnier than my finger.
Note: This thread lacks some key details about programming an ESP82xx device. Please read ALL of this thread to gain missing details. Next, Introduction Continues (Including an Important Difference)
|
|
|
Post by papa on Apr 22, 2019 13:47:17 GMT
Program Itead Sonoff S26 ECOPlug (ESP8266) Introduction ContinuesThe biggest difference & disappointment: the S26 no longer has the S20's convenient row of programming header holes (3.3v, Gnd, Tx, & Rx). Those connections are still available, but less convenient to use. Fortunately, once this forum's programming is on the S26, (as with the S20) one can re-program the S26 over WiFi. As shown in the pics below, the re-programming locations (3.3v, gnd, Tx, Rx) are present, but not as easy to connect: Forum members (free registration), click on pics for larger view.
daughter board pads main board jumpers & pins
Next, Connect the S26 for Re-Programming
|
|
|
Post by papa on Apr 23, 2019 17:35:44 GMT
Connect the S26 for Re-ProgrammingAgain to upload new programming opened in Arduino IDE, we need to connect four S26 signal locations (illustrated in last post & listed below) to four locations on the FTDI programming device that is connected via USB to the Arduino IDE hosted computer: S26 signal locations to be connected to an FTDI USB programming device VCC 3V3 Rx Tx ETX (Tx) Rx GND GND To make these connections on the Sonoff S26, some people have soldered wires to the S26's J1, J2, & maybe J10 & held dupont male pins to ETX & maybe ERX. Here is a 3-D printed pogo pin adapter to re-program an S26. I don't have a 3-D printer & I wanted to avoid soldering. Next, Electrically Connect the S26 without Solder
|
|
|
Post by papa on Apr 24, 2019 14:14:35 GMT
Without Solder, Electrically Connect the S26 for Re-programmingAgain, I don't have a 3-D printer & I wanted to avoid soldering. This thread shows devices I have used to make electrical connections without solder. As shown in these pictures, I used grabber test clips to connect to the 3.3 volts & gnd pins of the AMS1117 regulator (U2) on the main board. I used an alligator clip to connect to J10 on the main board which has the Rx signal. Put tape over the jumper pad next to J10 to prevent it from being connected. I had a male to male dupont cable connected to FTDI's Rx pin & ready to touch to the S26's ETX pad.
main board connections daughter board connections
Next, Complete the S26's Re-programming
|
|
|
Post by papa on Apr 24, 2019 14:31:07 GMT
Complete the S26's Re-programmingHave the new S26 programming open in the Arduino IDE. After all connections except ETX have been made (as in the last post above) & FTDI is NOT connected to USB, press & hold the S26 push button (with a pencil stub?) & then plug the FTDI into the Arduino IDE computer. You can then release the push button. To indicate it is in programming mode (not seeking WiFi), the S26 LED should NOT blink.
Click the Arduino IDE upload button & be ready for the following: While the programming is compiling & BEFORE the actual upload starts, press & hold the loose male dupont pin (from FTDI Rx) to the S26's ETX pad. Keep the pin there until the Arduino IDE completes the upload. Repeat this paragraph until successful. (If not successful, recheck your connections to match the last post.) Once successful, you can reassemble the S26 in its case. You can do any future re-programming via WiFi. See the thread about programming the Sonoff S20. FTDI programming & WiFi programming of the S26 is the same as for the S20, except for how one physically connects to the S26 for the FTDI programming. Reassembling the case is harder than opening it. Hint: Start with the male mains prongs pointing down through the bottom case hole & those prongs' plastic disc sung in its case hole. Fit the circuit board mounting holes over the screw holes in the case's bottom. Then fit the top case over the female mains sockets & snap together the case parts. If successful, re-install the 3 screws.
|
|
|
Post by jimkernsjr on May 18, 2019 4:12:22 GMT
Most of this is pointless anymore. See here for a modern way to do it: www.youtube.com/watch?v=O5GYh470m5kNo need to even open the cases. Especially useful when you cannot open the case.
Works with Ecoplugs, anything that uses Smartlife, or TUYA cloud. Here is a supported device list:
Happy flashing!
P.S. Many of these devices being re-flashed have energy monitoring. Switch to the Tasmota firmware and it supports it natively. You just need to tell it the chip and monitoring pin number.
|
|