Sonoff s20 dead after flashing custom firmware


(Ravi Shankar) #1

I flashed this firmware on to my new S20 by following the method shown here. Flash was successful but when I connected the S20 to the power socket, it does not turn on. No led blinking, its as if its dead. I tried to flash again, but now my system dose not even detect the device and it does not go into flash mode.

Below is my flash output -

C:\Users\ravi_\Desktop\Smartthings\ESPEasy_R120>esptool.exe -vv -cd nodemcu -cd 115200 -cp COM8 -ca 0x00000 -cf SonoffS20.ino.generic.bin
esptool v0.4.6 - © 2014 Ch. Klippel ck@atelier-klippel.de
setting board to nodemcu
setting board to 115200
error: unknown board: 115200
known boards are: none ck wifio nodemcu
setting port from COM1 to COM8
setting address from 0x00000000 to 0x00000000
espcomm_upload_file
stat SonoffS20.ino.generic.bin success
setting serial port timeouts to 1000 ms
opening bootloader
resetting board
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
resetting board
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
resetting board
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
warning: espcomm_sync failed
error: espcomm_open failed

C:\Users\ravi_\Desktop\Smartthings\ESPEasy_R120>esptool.exe -vv -cd nodemcu -cd 115200 -cp COM8 -ca 0x00000 -cf SonoffS20.ino.generic.bin
esptool v0.4.6 - © 2014 Ch. Klippel ck@atelier-klippel.de
setting board to nodemcu
setting board to 115200
error: unknown board: 115200
known boards are: none ck wifio nodemcu
setting port from COM1 to COM8
setting address from 0x00000000 to 0x00000000
espcomm_upload_file
stat SonoffS20.ino.generic.bin success
setting serial port timeouts to 1000 ms
opening bootloader
resetting board
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
read 0, requested 1
trying to connect
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
espcomm_send_command: receiving 2 bytes of data
espcomm_send_command: receiving 2 bytes of data
espcomm_send_command: receiving 2 bytes of data
espcomm_send_command: receiving 2 bytes of data
espcomm_send_command: receiving 2 bytes of data
espcomm_send_command: receiving 2 bytes of data
espcomm_send_command: receiving 2 bytes of data
espcomm_send_command: receiving 2 bytes of data
espcomm_open
Uploading 345760 bytes from SonoffS20.ino.generic.bin to flash at 0x00000000
erasing flash
size: 0546a0 address: 000000
first_sector_index: 0
total_sector_count: 85
head_sector_count: 16
adjusted_sector_count: 69
adjusted_size: 045000
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
setting serial port timeouts to 10000 ms
setting serial port timeouts to 1000 ms
espcomm_send_command: receiving 2 bytes of data
writing flash

starting app without reboot
espcomm_send_command: sending command header
espcomm_send_command: sending command payload
espcomm_send_command: receiving 2 bytes of data
closing bootloader
flush start
setting serial port timeouts to 1 ms
setting serial port timeouts to 1000 ms
flush complete


(Eric) #2

maybe you burned out the USB port itself. They don’t seem very robust. You may not have abused it but it can still fail. Static is everywhere anyway.

The Sonoff’s are incredibly cheap. I would not expect them to be durable either. Buy two.


(Ravi Shankar) #3

After some looking around, I saw a post and followed that method and flashed again and it worked.

I got it working. I don’t know exactly why or how, but I read through a lot of the ESPEasy forums and pieced together information. Flash it using NodeMCU flasher here: https://github.com/nodemcu/nodemcu-flasher In Config set the first box to the path of the sonoff firmware: [image] Then under advanced set Baudrate to 115200, Flash Size to 1MByte, Flash speed to 40MHZ and SPI Mode to DOUT. Then press flash under operation. Wait until its complete. Then disconnect the programmer, disconnect TX/RX, plug the programmer back in with only VCC and Ground, wait for it to boot, reset the wifi by holding the button for 10+ seconds, then connect to the wifi and configure it as usual.


(Lee Berry) #4

had the same problem. followed the above … and it worked …
the main thing i had not done before was removing the TX/RX while testing …