EDAboard.com | EDAboard.de | EDAboard.co.uk | WTWH Media

Bargain

Ask a question - edaboard.com

elektroda.net NewsGroups Forum Index - Electronics AUS - Bargain

keithr0
Guest

Thu Sep 05, 2019 8:45 am   



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.

Clifford Heath
Guest

Fri Sep 20, 2019 9:45 am   



On 5/9/19 5:35 pm, keithr0 wrote:
Quote:
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.


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
"https://github.com/ct-Open-Source/tuya-convert". 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 <https://github.com/xoseperez/espurna>, 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: <https://www.adafruit.com/product/4065>.

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.

keithr0
Guest

Sun Sep 22, 2019 12:45 pm   



On 9/20/2019 6:20 PM, Clifford Heath wrote:
Quote:
On 5/9/19 5:35 pm, keithr0 wrote:
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.

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
"https://github.com/ct-Open-Source/tuya-convert". 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 <https://github.com/xoseperez/espurna>, 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: <https://www.adafruit.com/product/4065>.

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.


https://fccid.io/2ANDL-TYWE2S/User-Manual/Users-Manual-3596121

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.

Quote:
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.


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

https://thehackbox.org/tasmota/release/

> Clifford Heath.

Clifford Heath
Guest

Mon Sep 23, 2019 12:45 am   



On 22/9/19 9:19 pm, keithr0 wrote:
Quote:
On 9/20/2019 6:20 PM, Clifford Heath wrote:
On 5/9/19 5:35 pm, keithr0 wrote:
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.

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
"https://github.com/ct-Open-Source/tuya-convert". 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 <https://github.com/xoseperez/espurna>, 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: <https://www.adafruit.com/product/4065>.

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.

https://fccid.io/2ANDL-TYWE2S/User-Manual/Users-Manual-3596121

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.


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.

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

https://thehackbox.org/tasmota/release/


Thanks.

Does anyone recognise this energy monitoring chip? The marking I see is
"1852AVH":
<https://www.dropbox.com/s/pzf0km6m85c0a1s/SmartPlugEnergyChip2.jpg>
<https://www.dropbox.com/s/46sl5cxqapm9v4r/SmartPlugEnergyChip3.jpg>

Clifford Heath.

keithr0
Guest

Mon Dec 30, 2019 12:08 am   



On 9/23/2019 9:25 AM, Clifford Heath wrote:
Quote:
On 22/9/19 9:19 pm, keithr0 wrote:
On 9/20/2019 6:20 PM, Clifford Heath wrote:
On 5/9/19 5:35 pm, keithr0 wrote:
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.

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
"https://github.com/ct-Open-Source/tuya-convert". 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 <https://github.com/xoseperez/espurna>, 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: <https://www.adafruit.com/product/4065>.

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.

https://fccid.io/2ANDL-TYWE2S/User-Manual/Users-Manual-3596121

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.

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 I then updated them to the latest
capacitor. It would probably suffice to add a series 2K resistor, so the
button still works but RS232 can over-ride that.

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

https://thehackbox.org/tasmota/release/

Thanks.

Does anyone recognise this energy monitoring chip? The marking I see is
"1852AVH":
https://www.dropbox.com/s/pzf0km6m85c0a1s/SmartPlugEnergyChip2.jpg
https://www.dropbox.com/s/46sl5cxqapm9v4r/SmartPlugEnergyChip3.jpg

Clifford Heath.


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.

elektroda.net NewsGroups Forum Index - Electronics AUS - Bargain

Ask a question - edaboard.com

Arabic version Bulgarian version Catalan version Czech version Danish version German version Greek version English version Spanish version Finnish version French version Hindi version Croatian version Indonesian version Italian version Hebrew version Japanese version Korean version Lithuanian version Latvian version Dutch version Norwegian version Polish version Portuguese version Romanian version Russian version Slovak version Slovenian version Serbian version Swedish version Tagalog version Ukrainian version Vietnamese version Chinese version Turkish version
EDAboard.com map