Page 2 of 2

Re: unable to get REPL prompt

Posted: Tue Aug 01, 2017 10:20 am
by torwag
Hi, I can just say that I flashed multiple D1 mini boards with daily git builds and face no problem.
Maybe you could set the UART speed to 74880bps and see what the "garbage" is telling you.
Other then this it could be simply a faulty device, or as Peter suggested a fraud device. There are images on the web which show the slight differences between original and fraud D1 mini boards.
That it runs with older firmware or arduino could be just luck, if a particular unit of memory is broken.

Taken the price of the D1 mini, I would get a second device, possibly from another source, and give it a go. If the problem is not reproducible with the new device, I would simply blame the first D1 mini "dead-on-arrival" and go on. Maybe the seller will send you a new one.

Re: unable to get REPL prompt

Posted: Tue Aug 01, 2017 12:09 pm
by rpi_nerd
I tried setting the UART speed to 74880 (and several over baud rates) to see if what I was getting at reset was actually something else other than garbage, but so far have had no luck. Balu, what firmware version worked for you?

Re: unable to get REPL prompt

Posted: Thu Aug 10, 2017 9:07 am
by richarddavison
Did you manage to solve it?

I have the same problem ☹️

Re: unable to get REPL prompt

Posted: Thu Aug 10, 2017 10:20 pm
by rpi_nerd
Nope, never found a solution. I did get a refund and ordered a replacement. Will see if that one will work.

Re: unable to get REPL prompt

Posted: Fri Aug 11, 2017 5:41 pm
by rpi_nerd
SUCCESS! After reading the reply on richarddavison's thread (viewtopic.php?f=16&t=3665) , suggesting that the one that I have may have an ESP8285 chip. I tried the instructions provided in the linked thread(adding --flash_mode=dout) and success, I now get the REPL prompt!

EDIT: I've looked up the ESP8285 and it says it has 1MB of flash, yet all of the tools that I've used detected 4MB of flash on my board. On the ESP module itself, it says ESP8266 on the RF shield.

Re: [SOLVED] unable to get REPL prompt

Posted: Tue Dec 05, 2017 8:35 pm
by bogd
THANK YOU, rpi_nerd!! I came to this forum after an entire day of trying (unsuccessfully!) to get two Wemos D1 Mini boards to work with MicroPython.

I tried all the tutorials I could find, but I was getting the exact same result - nothing on the serial connection, and garbage when resetting the board (garbage at 115200, and different garbage at 74880 :) ).

After flashing the boards with --flash_mode=dout, I finally managed to get a REPL prompt on one of them! (I left the other one at work, so I cannot test it right now :( )

I have to admit I did find the ESP8285 reference earlier, but I was firmly convinced that my boards were ESP8266. Because:
1) they both have "D1 mini" printed on them (even though one has the Wemos logo on it, the other does not)
2) the metal shield on the (now working) board says "ESP-12N" (which as I understand is ESP8266-based)
3) the esptool.py detects them as ESP8266 with 4MB of flash:

esptool.py v2.2
Connecting....
Detecting chip type... ESP8266
Chip is ESP8266EX
Uploading stub...

Now I'm beginning to wonder if I can trust what the esptool is telling me. Is there a reliable way to determine the chip type and flash size on my boards? (is it really 4MB, or could it be 1MB?)

Once again, a big THANK YOU to rpi_nerd for coming back here and posting his solution!!

Re: [SOLVED] unable to get REPL prompt

Posted: Thu Dec 07, 2017 9:40 pm
by rpi_nerd
Glad that my thread was able to help you bogd :)

Re: [SOLVED] unable to get REPL prompt

Posted: Sat Nov 10, 2018 9:03 pm
by JohnLittle
Sorry to be resurrecting yet another old thread!

I bought a few "CH340G NodeMcu Wireless WIFI Module Connector Board Replace ESP-12E ESP8266 UK" off ebay and was not able to flash them without adding --flash_mode=dout

The board is labelled "HW-628 V1.1" and comes with a 4MB flash memory chip.

My esptool command is:

esptool.py --port /dev/ttyUSB0 --baud 460800 write_flash --flash_size=detect 0 esp8266-20180511-v1.9.4.bin --flash_mode=dout

And the output:

esptool.py v2.5.1
Serial port /dev/ttyUSB0
Connecting....
Detecting chip type... ESP8266
Chip is ESP8266EX
Features: WiFi
MAC: **redacted**
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 460800
Changed.
Configuring flash size...
Auto-detected Flash size: 4MB
Flash params set to 0x0340
Compressed 604872 bytes to 394893...
Wrote 604872 bytes (394893 compressed) at 0x00000000 in 9.4 seconds (effective 516.2 kbit/s)...
Hash of data verified.

I then get a prompt with picocom using

picocom -b115200 /dev/ttyUSB0