-->
Page 1 of 1

Unable to boot Wemos D1 after flashing (csum err)

PostPosted: Wed Jan 24, 2018 6:13 am
by ratfink
I have been working with a NodeMCU 12E module using a custom firmware from the NodeMCU builder site and as I am on windows using the NodeMCU flasher GUI without problems. I want to port my project to the Wemos D1 module for some of the units I will be building and cannot get any firmware to properly boot after flashing. I have read up on the module and seen about having to add the bootloader to the first part of memory and whilst in theory the GUI flasher should work it doesn't so I have been trying the esptool.py for the job. In all cases the flash completes but the system will not boot, simply spewing the csum error at 74880 baud on the console.
For example:
Code: Select allpython esptool.py -p com33 erase_flash
python esptool.py -p com33 flash_id
python esptool.py -p com33 -b 115200 write_flash -ff 80m -fm dio -fs 1MB 0x0 boot_v1.7.bin 0x01000 firmware.bin

Yeilds:
Image
at the command prompt and
Code: Select allPORT OPEN 74880

Communication with MCU..Got answer! Communication with MCU established.
AutoDetect firmware...

Can't autodetect firmware, because proper answer not received (may be unknown firmware).
Please, reset module or continue.
boot mode:(3,6)

load 0x40100000, len 2592, room 16
tail 0
chksum 0xef
load 0x00000000, len 0, room 8
tail 0
chksum 0xef
load 0x00000000, len 0, room 0
tail 0
chksum 0xef
csum 0xef
csum err
ets_main.c

at the ESPlorer.

I have tried various combinations of baud rate, write speed, dio / qio and flash sizes and all give the same result. In the case above the firmware.bin is my custom firmware which works on the esp8266 but I have also tried various demo firmwares from around the web.

Finally, if I try and run the esptool.py against one of my working NodeMCU units it times out with a no packet header error.

Can anyone point me in the correct direction here?

Re: Unable to boot Wemos D1 after flashing (csum err)

PostPosted: Fri Jan 26, 2018 10:57 am
by lpares12
I had the same problem with an ESP-01. Trying to do it with dout instead of dio or qio solved it.

My current parameters are: -fm dout -ff 40m -fs 1MB. When flashing try always to specify everything according to your device to avoid getting default parameters from esptool.

Hope this solves your problem! I did the same as you, tried all combinations with qio/dio but never used dout until I saw that it's the default for some boards.

Re: Unable to boot Wemos D1 after flashing (csum err)

PostPosted: Sun Jan 28, 2018 5:27 am
by ratfink
WOW! thank you!
I thought I had tried all the options for DOUT etc. but that seems to have fixed it. Had actually given up thinking I had a dodgy clone device and have ordered a few different ones on Ebay.