
Here are my experiences with a Sonoff S60TPG iPlug UK smart plug, along with teardown, flashing information and OpenESP32 experiments (OBK port).






The plug was bought from Ali Express
https://nl.aliexpress.com/item/1005006764953793.html
Glue seemed to be too strong and I didn't have the right width tools to contort it in a vice to crack it open. I resorted to drilling a hole at the chassis join from which it could be pried apart. Main PCB removed from power pins and then module de-soldered.

















A module I've not seen before. A Coolkit SM-049 V1.3 - an ESP32-C3 with 4mb flash integrated. On the reverse of the module is a Chipsea Technologies CSE7759B energy metering chip. Module takes 5V from main PCB but then 3.3v supplied to ESP32 thanks to a MicrOne (Nanjing Micro One Elec) ME6211A33PG-N 6211A 2438/33 LDO.

from IO21/TX at 115200 baud, factory boot log
Code: Text
eWeLink app experience. fw ver 1.1.1 with update to 1.2.0 offered






IO9/Key grounded gets ESP into download mode
Code: Text
info gathering with esptool
esptool.exe --port com73 get_security_info
Code: Text
good, no secure boot or flash encryption.
espefuse.exe --chip esp32c3 --port COM73 summary
Code: Text
dump to file
esptool.exe --chip esp32c3 --port COM73 --baud 921600 read_flash 0x000000 0x400000 flash_dump.bin
Flashed OpenESP32C3 factory image with esp-flasher.exe from https://github.com/Jason2866/ESP_Flasher/releases
Module contact tracing and labels



Meaning the assignments are
Code: JSON
The blue wifi LED is controllable but the second red LED is linked to the relay. On=relay closed, Off=relay open.
ESP builds are missing the CSE7766 driver (compatible with CSE7759B), so I enabled it with this PR https://github.com/openshwprojects/OpenBK7231T_App/pull/1642 but @insmod warned me in the comments that it may not work. This is my first CSE7759B - from what I've seen in other posts it seems only the driver needs starting and perhaps flag 26 ([UART] Use alternate UART for BL0942, CSE, TuyaMCU, etc) needs enabling in some situations. Unfortunately no readings on ESP32 with or without flag. IO7 is connected to TX on the CSE7759B.


and that's the current state of play.
Cool? Ranking DIY