why is --flash_mode dio required for my build but not the release?

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
lfast
Posts: 8
Joined: Mon Jul 09, 2018 6:57 pm

why is --flash_mode dio required for my build but not the release?

Post by lfast » Thu Sep 06, 2018 10:19 pm

I finally got my own build of micropython running on the Huzzah esp32. Yay! The final issues was dio/qio. Note to other Huzzah esp32 users: You need manually rerun the deploy command with --flash_mode dio

Q: Why doesn't the release build require --flash_mode dio? This was a point of confusion for me as I expected the release deploy command should work with my own build.

NOTE: setting FLASH_MODE = dio in my makefile did not change the flash command. I had to manually rerun the esptool deploy command.

User avatar
Roberthh
Posts: 3667
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: why is --flash_mode dio required for my build but not the release?

Post by Roberthh » Fri Sep 07, 2018 4:29 pm

Sorry. If I look into the ESP32 Makefile, the flash mode is set to dio.

Code: Select all

FLASH_MODE ?= dio

lfast
Posts: 8
Joined: Mon Jul 09, 2018 6:57 pm

Re: why is --flash_mode dio required for my build but not the release?

Post by lfast » Fri Sep 07, 2018 5:10 pm

Thanks for looking into it. I'm just going by my experience - which could easily be some kind of misconfiguration on my part.
Here's the output showing make deploy trying to use qio

.../ports/esp32> make deploy V=1
python ../../py/makeversionhdr.py build/genhdr/mpversion.h
Writing build/firmware.bin to the board
/home/lfast/Documents/IoT/micropython/esp-idf/components/esptool_py/esptool/esptool.py --chip esp32 --port /dev/ttyUSB0 --baud 460800 write_flash -z --flash_mode qio --flash_freq 40m 0x1000 build/firmware.bin
esptool.py v2.5.0

Now that I have something running I'm getting ready to purge my whole build environment and start again clean. I'll call back when I have a result from that.

lfast
Posts: 8
Joined: Mon Jul 09, 2018 6:57 pm

Re: why is --flash_mode dio required for my build but not the release?

Post by lfast » Sat Sep 08, 2018 12:30 am

Not unexpectedly, after doing a clean rebuilding my dev environment, all problems went away. Thanks for all your help along the way and the well documented setup process.

I'm still curious about the difference between the basic esp32 build environment that I just built and how the 'release' binary gets built. The release binary does not require --flash_mode qio/dio. Just curious.

Post Reply