mnayef95
(Mohammad Hamdan)
November 3, 2020, 11:19pm
1
I have flashed Magic home v1.1 ZJ-WFMN-A
before, Now I bought another led controller from Magic home but they updated it.
I tried to flash it the same way as an old one but it’s didn’t work.
This is the V1.1
I have flashed it like this:
TXD --> RXD
RXD --> TXD
GND --> GND
IO0 --> GND
And it’s worked with Esphome.
But the new version of the magic home which is this:
Is not working in the same way, I tried different ways with a different one:
Way 1
TXD --> RXD
RXD --> TXD
GND --> GND
BOOT --> GND
Way 2
TXD --> TXD
RXD --> RXD
GND --> GND
BOOT --> GND
But still didn’t work, Do you have any suggestion to get it to work?
DrJeff
(DrJeff)
November 4, 2020, 12:58am
3
not if he’s powering via 12V on the Magic Home then only ground!
DrJeff
(DrJeff)
November 4, 2020, 1:01am
4
@mnayef95 Did you try pulling down boot only @boot then flash?
nickrout
(Nick Rout)
November 4, 2020, 1:03am
5
He doesn’t say that, but he might be. In that case, is it the same GND for the power supply and the FTDI?
mnayef95
(Mohammad Hamdan)
November 4, 2020, 9:56am
6
@DrJeff @nickrout I have tried to connect the boot to the same GND for the power supply and the FTDI and tried to separate them and still same issue, Tried to connect the boot pin to GND for 5 seconds then disconnect it and flash, but didn’t worked
apmillen
(Andy)
November 4, 2020, 9:59am
7
What are you using to flash? ESPHomeFlasher? Something else?
Are there any errors?
mnayef95
(Mohammad Hamdan)
November 4, 2020, 10:08am
8
@apmillen I’m using home assistant Esphome add-on installed on raspberry pi 4 model b, I got only one error which is timeout.
mnayef95
(Mohammad Hamdan)
November 5, 2020, 7:50pm
10
@nickrout
Serial port /dev/ttyUSB0
Connecting........_____....._____....._____....._____....._____....._____....._____
A fatal error occurred: Failed to connect to ESP8266: Invalid head of packet (0x46)
INFO Upload with baud rate 460800 failed. Trying again with baud rate 115200.
INFO Running: esptool.py --before default_reset --after hard_reset --baud 115200 --chip esp8266 --port /dev/ttyUSB0 write_flash 0x0 /data/light_11/.pioenvs/light_11/firmware.bin
esptool.py v2.8
Serial port /dev/ttyUSB0
Connecting........_____....._____....._____....._____....._____....._____....._____
A fatal error occurred: Failed to connect to ESP8266: Invalid head of packet (0x46)
mnayef95
(Mohammad Hamdan)
November 5, 2020, 9:33pm
12
@nickrout
INFO Reading configuration /config/esphome/light_11.yaml...
INFO Generating C++ source...
INFO Compiling app...
INFO Running: platformio run -d /config/esphome/light_11
Processing light_11 (board: esp01_1m; framework: arduino; platform: [email protected] )
--------------------------------------------------------------------------------
HARDWARE: ESP8266 80MHz, 80KB RAM, 1MB Flash
PACKAGES:
- framework-arduinoespressif8266 3.20704.0 (2.7.4)
- tool-esptool 1.413.0 (4.13)
- tool-esptoolpy 1.20800.0 (2.8.0)
- toolchain-xtensa 2.40802.200502 (4.8.2)
Dependency Graph
|-- <ESPAsyncTCP-esphome> 1.2.3
| |-- <ESP8266WiFi> 1.0
|-- <ESP8266WiFi> 1.0
|-- <ESP8266mDNS> 1.2
| |-- <ESP8266WiFi> 1.0
|-- <ESPAsyncWebServer-esphome> 1.2.7
| |-- <ESPAsyncTCP-esphome> 1.2.3
| | |-- <ESP8266WiFi> 1.0
| |-- <Hash> 1.0
| |-- <ESP8266WiFi> 1.0
|-- <DNSServer> 1.1.1
| |-- <ESP8266WiFi> 1.0
Retrieving maximum program size /data/light_11/.pioenvs/light_11/firmware.elf
Checking size /data/light_11/.pioenvs/light_11/firmware.elf
RAM: [===== ] 45.4% (used 37156 bytes from 81920 bytes)
Flash: [==== ] 40.3% (used 413152 bytes from 1023984 bytes)
========================= [SUCCESS] Took 17.40 seconds =========================
INFO Successfully compiled program.
INFO Running: esptool.py --before default_reset --after hard_reset --baud 460800 --chip esp8266 --port /dev/ttyUSB0 write_flash 0x0 /data/light_11/.pioenvs/light_11/firmware.bin
esptool.py v2.8
Serial port /dev/ttyUSB0
Connecting........_____....._____....._____....._____....._____....._____....._____
A fatal error occurred: Failed to connect to ESP8266: Timed out waiting for packet header
INFO Upload with baud rate 460800 failed. Trying again with baud rate 115200.
INFO Running: esptool.py --before default_reset --after hard_reset --baud 115200 --chip esp8266 --port /dev/ttyUSB0 write_flash 0x0 /data/light_11/.pioenvs/light_11/firmware.bin
esptool.py v2.8
Serial port /dev/ttyUSB0
Connecting........_____....._____....._____....._____....._____....._____....._____
A fatal error occurred: Failed to connect to ESP8266: Timed out waiting for packet header
nickrout
(Nick Rout)
November 5, 2020, 10:30pm
13
Thanks.
Are you 100% sure that:
all wires are connected
rx<–>tx and tx<–>rx
gpio0 is at ground
if there is a reset or program switch on the PCB you have pressed it
Also what ftdi do you have. I found the ones based on the cp2102 to be the best.
mnayef95
(Mohammad Hamdan)
November 6, 2020, 3:43pm
14
@nickrout Yes I’m sure, I did it more than 10 times with the 4 different controllers, I have tried two different ftdis but I don’t know the model or make.
What do you mean by this?
if there is a reset or program switch on the PCB you have pressed it
nickrout
(Nick Rout)
November 6, 2020, 9:00pm
15
I just had a closer look at your pics, there don’t seem to be any pushbuttons.
You say this is a new version magic home. Are you sure it is a esp8366 chip?
Tediore
November 6, 2020, 9:09pm
16
Yeah, it could be one of these…
opened 01:59PM - 04 May 20 UTC
closed 08:06PM - 27 Jul 20 UTC
The chip inside the new LED controllers from Magic Home is changed from ESP to probably Suzhou SmartChip Semiconductor Co., LTD....
mnayef95
(Mohammad Hamdan)
November 6, 2020, 9:16pm
17
Actually, I don’t know, I can’t find the esp label on it, not the same as the old one.
You can check @Tediore reply it’s the same device.
nickrout
(Nick Rout)
November 6, 2020, 9:23pm
18
Bummer. Becoming a major problem, new closed chips locking us into proprietary solutions.
Tediore
November 6, 2020, 9:28pm
19
Was just about to say that. Shame to see so many things move away from ESPs.
mnayef95
(Mohammad Hamdan)
November 6, 2020, 9:53pm
20
@nickrout @Tediore I think I can’t flash it , so I should throw them away and get the old version?
Now I want to flash them because the magic home and home assistant is not synced correctly, for example:
If I turn off the light from the magic home app it takes much time to reflect the home assistant and vice versa, and most of the time the home assistant is not working when turning the light off or on.
Is there a way to solve these issues without reflashing it or buying the old version?