Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

Threaded View
Aldi were selling Medion Life Smart Plugs for $20. At our local shop  
they are selling them off at $10 which is a real bargain.
As they stand you have to control them with an app through a "Cloud"  
probably in china - not so good. The "Brains" of the device is a TYWE2S  
module which is based on the ESP8266 and is thus highly hackable. Some  
care needs to be taken as there is 240v floating about in there, but  
anybody competent in electronics should have no problems.

Re: Bargain
On 5/9/19 5:35 pm, keithr0 wrote:
Quoted text here. Click to load it

Thanks Keith. I bought a couple, and ground an old screwdriver to the  
required triangular point to undo the screws. The device is indeed a  
TUYA TYWE2S, which is based on the ESP8285, which is an ESP8266 with  
1MByte of flash on-chip, so it doesn't need external flash like the ESP8266.

These can be re-flashed "over the air", and until Tuya started rolling  
out a patch in Jan, you could do it yourself using  
" ". So if that patch has  
been applied by Aldi/Medion (which is unlikely but possible), or if Tuya  
has reflashed your device over the air, the only way to reprogram it is  
to reflash using an RS232 dongle.

The device is supported by the Espurna open source smart-home software  
available at < , which uses Arduino  
and PlatformIO, so even script kiddies have a chance of making it go.  
Adafruit sell modules with the same chip, so it should be well  
supported: < .

I haven't yet diagnosed which of the 9 pins are connected to what. But  
there's obviously 3v3, GND, Tx, Rx and RESET. So that leaves four  
connections, of which one goes to a momentary push-button and one must  
drive the relay, leaving two... spare? I don't know yet.

In any case, unless you want to give some unknown Chinese people access  
to your WiFi network, I'd recommend you don't buy these... unless you  
intend to reflash them with some new code.

Clifford Heath.

Re: Bargain
On 9/20/2019 6:20 PM, Clifford Heath wrote:
Quoted text here. Click to load it

I am lead to believe that the relay is on GPIO 14 although I haven't  
personally confirmed that. There is another connection to the energy  
monitoring chip, one to the push button and one to the LED.

Quoted text here. Click to load it

Word has it that flashing them with Tasmota and the Teckin module will work.

Quoted text here. Click to load it

Re: Bargain
On 22/9/19 9:19 pm, keithr0 wrote:
Quoted text here. Click to load it

Here is what I have traced out:
* IO13 goes to the LED, active low
* The switch goes to RXD0, with resistor pullup and debounce cap
* IO14 drives the relay via a transistor (which pulls low)
* IO12,IO4 and IO5 go to the energy monitoring chip
* TXD0 and TOUT are not connected

To re-program it, it would be necessary to free up Rx from the debounce  
capacitor. It would probably suffice to add a series 2K resistor, so the  
button still works but RS232 can over-ride that.

Quoted text here. Click to load it


Does anyone recognise this energy monitoring chip? The marking I see is  


Clifford Heath.

Re: Bargain
On 9/23/2019 9:25 AM, Clifford Heath wrote:
Quoted text here. Click to load it

I eventually got around to doing something with these. I flashed them  
with tuya-convert using a raspberry-pi. I then updated them to the  
latest version of Tasmota, and applied the Medion template available on  
the main Tasmota site. I still have to set up MQTT, but though the web  
interface I can control power on and off and monitor the voltage current  
and power (some calibration was needed). The power can also be toggled  
with the button on the switch itself.

Some of the steps weren't totally straight forward but the biggest  
problem was that Tasmota has a maximum WiFi password size of 31 char, I  
had an over the top Wifi password of 63 char and had to reset the  
password on the router, 3 laptops, 2 iPads, 2 phones, 3 raspberry-pis  
and 2 set top boxes.

I'm pretty happy with the result.

Site Timeline