platformioでESP32にファームウェアを書き込めない
Q&A
Closed
解決したいこと
VSCode + platformioでESP32用のプロジェクトを作成しています。
ビルドは成功したのですが、ファームウェアを書き込もうと”Upload”を実施してもエラーが出てESP32に書き込みが失敗してしまいます。
ちゃんとplatformioとESP32の書き込みの通信接続ができているのかご教示の程宜しくお願い致します。
発生している問題・エラー
> Executing task: C:\Users\kmaeh\.platformio\penv\Scripts\platformio.exe run --target upload <
Processing esp32dev (platform: espressif32; board: esp32dev; framework: arduino)
--------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32dev.html
PLATFORM: Espressif 32 (2.0.0) > Espressif ESP32 Dev Module
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (minimodule) External (esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-arduinoespressif32 3.10004.200129 (1.0.4)
- tool-esptoolpy 1.20600.0 (2.6.0)
- tool-mkspiffs 2.230.0 (2.30)
- tool-openocd-esp32 1.1000.20190709 (10.0)
- toolchain-xtensa32 2.50200.80 (5.2.0)
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 41 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <TFT_eSPI> 2.3.2
| |-- <SPIFFS> 1.0
| | |-- <FS> 1.0
| |-- <FS> 1.0
| |-- <SPI> 1.0
|-- <lv_arduino> 3.0.1
|-- <ESP32 BLE Arduino> 1.0.1
Building in debug mode
Retrieving maximum program size .pio\build\esp32dev\firmware.elf
Checking size .pio\build\esp32dev\firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [ ] 4.8% (used 15820 bytes from 327680 bytes)
Flash: [== ] 21.4% (used 280403 bytes from 1310720 bytes)
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 = minimodule
Uploading .pio\build\esp32dev\firmware.bin
Open On-Chip Debugger v0.10.0-esp32-20190708 (2019-07-08-11:04)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
debug_level: 1
adapter speed: 20000 kHz
esp32 interrupt mask on
Error: no device found
Error: unable to open ftdi device with vid 0403, pid 6010, description 'FT2232H MiniModule', serial '*' at bus location '*'
** OpenOCD init failed **
shutdown command invoked
Warn : Flash driver of esp32.flash does not support free_driver_priv()
Warn : Flash driver of irom does not support free_driver_priv()
Warn : Flash driver of drom does not support free_driver_priv()
*** [upload] Error 1
============================================ [FAILED] Took 4.22 seconds ============================================
The terminal process "C:\Users\kmaeh\.platformio\penv\Scripts\platformio.exe 'run', '--target', 'upload'" terminated with exit code: 1.
Terminal will be reused by tasks, press any key to close it.
自分で試したこと
platformio.iniには、次のように設定しています。
platformio.ini
[env:esp32dev]
platform = espressif32
board = esp32dev
framework = arduino
debug_tool = minimodule
monitor_port = COM12
monitor_speed = 115200
upload_speed = 460800
upload_protocol = minimodule
build_type = debug
lib_deps = bodmer/TFT_eSPI@^2.3.2
現在PCとESP32をUSBケーブルで直接つないでいます。
その際にデバイスマネージャで確認してみるとCOM12と表示されている状態です。
0