Is this the right way to flash?

All ESP8266 boards running MicroPython.
Official boards are the Adafruit Huzzah and Feather boards.
Target audience: MicroPython users with an ESP8266 board.
Post Reply
dhust
Posts: 40
Joined: Sun Jul 11, 2021 10:59 pm

Is this the right way to flash?

Post by dhust » Sun Jul 25, 2021 11:54 pm

I bought this Izokee development board and these Teyleten Robot boards.

I've been flashing them with these arguments. Just want to make sure I'm not messing up from the get go or if doing it wrong will give me issues down the road.

Code: Select all

esptool.py --port COM3 write_flash --flash_size=4MB -fm dio 0 C:\Users\Main\Downloads\firmware-esp8266-GENERIC.bin
I've seen some people use

Code: Select all

-fm dout
I've tried to figure out what that means but couldn't find it. And also not sure what the 0 means after dio.

The Teyleten flash_id shows this:

Code: Select all

esptool.py v3.0
Serial port COM3
Connecting....
Detecting chip type... ESP8266
Chip is ESP8266EX
Features: WiFi
Crystal is 26MHz
MAC: 98:cd:ac:25:bd:a9
Uploading stub...
Running stub...
Stub running...
Manufacturer: d8
Device: 4016
Detected flash size: 4MB
Hard resetting via RTS pin...

davef
Posts: 811
Joined: Thu Apr 30, 2020 1:03 am
Location: Christchurch, NZ

Re: Is this the right way to flash?

Post by davef » Mon Jul 26, 2021 12:18 am

As an example:
NodeMcu v3 board, default dio some boards need dout
Something to do with how the flash is used or what type of flash there is on-board. Still looking in my notes.

davef
Posts: 811
Joined: Thu Apr 30, 2020 1:03 am
Location: Christchurch, NZ

Re: Is this the right way to flash?

Post by davef » Mon Jul 26, 2021 12:44 am

For ESP-NOW and a ESP-01S board:

1) hold GPIO0 low
2) plug in USB
3) sudo esptool.py --chip esp8266 --port /dev/ttyUSB0 erase_flash
4) hold GPIO0 low
5) plug in USB
6) sudo esptool.py --port /dev/ttyUSB0 --baud 460800 write_flash --flash_size=1MB -fm dout 0x0 esp8266-1m-20200902-v1.13.bin
try --baud 115200 if 460800 doesn't work
-fm dout mode instead of the default qio mode (default dio?)
-fm dout means flash mode is Dual Output

Option Mode Name Pins Used Speed (ESP8266 & ESP32)
qio Quad I/O 4 pins used for address & data Fastest.
qout Quad Output 4 pins used for data. Approx 15% slower than qio.
dio Dual I/O 2 pins used for address & data Approx 45% slower than qio.
dout Dual Output 2 pins used for data. Approx 50% slower than qio.

Post Reply