Live data from Hacker News

Reprogramming a $13 consumer wifi-enabled outlet

rluckom.github.io

1–10 of 44 posts

Re: Reprogramming a $13 consumer wifi-enabled outlet

#2
There seems to be enough room in the enclosure to solder on some pin headers to both sides of the ESP-12. That would make getting access to them a lot easier than trying to rig up a custom 3D printed pogo pin setup.

Other than that, this is exactly what I've been looking for. I have an old wireless outlet (controlled by a RF remote) that I rigged up a Raspberry Pi Zero to, but that is a lot of effort compared to soldering some headers and flashing a new firmware.

Now all we need is some good software to securely integrate this with other IoT systems.

Re: Reprogramming a $13 consumer wifi-enabled outlet

#3
The Sonoff S22 is a good candidate for reprogramming, with the bonus option that it supports external temperature+humidity sensors.

You can definitely achieve the same functionality cheaper with a ESP8266 breakout + shield, but this way you get a nice case that can just sit on a socket.

https://www.aliexpress.com/item/Sonoff-S22-Smart-Wifi-Power-...

https://github.com/arendst/Sonoff-Tasmota/issues/627

Re: Reprogramming a $13 consumer wifi-enabled outlet

#5

There seems to be enough room in the enclosure to solder on some pin headers to both sides of the ESP-12. That would make getting access to them a lot easier than trying to rig up a custom 3D printed pogo pin setup. Other than that, this is exactly what I've been looking for. I have an old wireless outlet (controlled by a RF remote) that I rigged up a Raspberry Pi Zero to, but that is a lot of effort compared to sold…

Something like Sonoff-Tasmota (and many other similar projects) provides MQTT support, which works nicely with pretty much any IoT setup.

https://github.com/arendst/Sonoff-Tasmota

Re: Reprogramming a $13 consumer wifi-enabled outlet

#6
post #4

The most popular esp8266 based relay from Sonoff is designed for friendly reprogramming - http://randomnerdtutorials.com/reprogram-sonoff-smart-switch...

Have several of these. I run an Mqtt broker, HomeAssistant and "Sonoff Tasmota" https://github.com/arendst/Sonoff-Tasmota . I believe however, this firmware will also emulate a Philips Hue Bridge or Belkin Wemo to make integration easy with Alexa and such.

Re: Reprogramming a $13 consumer wifi-enabled outlet

#7
This looks quite similar to the Sonoff S20. [1] Although they opted for the ESP module instead of designing a custom PCB around the ESP8266 chip as Sonoff does.

According to the S20 schematic, uart is routed to a header, so it should be easier to flash. [2]

The Sonoff S20 is the same price as the mentioned model, and is supported by espurna. [3] Espurna is great, it has MQTT, Domoticz, Home Assistant, an HTTP API, and Alexa integration. Espurna also supports sending data directly to InfluxDB which is very handy.

If you want to monitor power consumption as well, I can highly recommend the Sonoff POW. [4] Although to get a plug you will need to butcher an extension cable or power strip. If you only want to monitor power consumption and don't want to have the relay, it's quite easy to solder across the relay in the Sonoff POW and use it only as a power monitoring device.

Just a reminder to anyone working with these devices: never, ever connect UART while the device is plugged into AC!!

[1] https://www.itead.cc/smart-socket.html

[2] https://www.itead.cc/wiki/S20_Smart_Socket

[3] https://bitbucket.org/xoseperez/espurna/wiki/Hardware.md

[4] https://www.itead.cc/sonoff-pow.html

Re: Reprogramming a $13 consumer wifi-enabled outlet

#10
I really enjoyed reading this, but it wasn't entirely clear to me what the author planned to reprogram the unit to actually do. So from my perspective, the article ended abruptly when the author declared success even though I was looking forward to a description of the conclusion.

The story is important and often overlooked in these moments. It's what justifies spending a hundred hours and $200 to achieve something you could probably just buy for $50.

Post reply on HN