PlatformIO Community

No such file or directory: /Users/mac/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/bin/bootloader__40m.bin'

When I try to Upload using Platformio in VS Code on MacOS Big Sur I’m getting the following error:

esptool write_flash: error: argument <address> <filename>: [Errno 2] No such file or directory: '/Users/mac/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/bin/bootloader__40m.bin'
*** [upload] Error 2

The project works on Windows 11. Platformi INI parameters:

platform =
framework = arduino

This branch is outdated beyond belief, please don’t use it. The latest regular release (5.1.0) (Releases · platformio/platform-espressif32 · GitHub) has support for the latest released Arduino-ESP32 v2.0.4, so if you want to use that, jsut set platform = espressif32.

@maxgerhardt After I changed it it worked fine.

platform =
platform_packages =

Now I have the following problem with uploading. Please take a look log below:

Configuring upload protocol...
AVAILABLE: esp-prog, espota, esptool, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa
CURRENT: upload_protocol = esptool
Looking for upload port...
Auto-detected: /dev/cu.usbserial-1120
Uploading .pio/build/HUBER_M1_L1/firmware.bin v3.1
Serial port /dev/cu.usbserial-1120
Chip is ESP32-D0WD-V3 (revision 3)
Features: WiFi, BT, Dual Core, 240MHz, VRef calibration in efuse, Coding Scheme None
WARNING: Detected crystal freq 41.24MHz is quite different to normalized freq 40MHz. Unsupported crystal in use?
Crystal is 40MHz
MAC: 34:94:54:bb:2b:50
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 921600
Configuring flash size...

A fatal error occurred: Timed out waiting for packet header
*** [upload] Error 2
============= [FAILED] Took 15.32 seconds =============

Again, I absolutely cannot recommend doing that, this branch is a whopping 112 commits behind master (Branches · platformio/platform-espressif32 · GitHub) and may use others lots of outdated version, like, causing the error you have now.

@maxgerhardt Tested also with

platform = espressif32
platform_packages =

Same error as above in a process of flashing.

Try setting upload_speed = 115200 in the platformio.ini.

With 115200 it works. Thank you.