Hi all,
I’m following these instructions to use the latest 3.0.1 release of the ESP32 arduino framwork for PlatformIO, but this crashes upon install. The same happens if I specify in my platformio.ini file to use version 3.0.1 of arduino-esp32.
To reproduce, just use this config in platformio.ini:
; PlatformIO Project Configuration File
;
; Build options: build flags, source filter
; Upload options: custom upload port, speed and extra flags
; Library options: dependencies, extra library storages
; Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; Redirecting...
[env:adafruit_feather_esp32s3_nopsram]
platform = espressif32
board = adafruit_feather_esp32s3_nopsram
framework = arduino
monitor_speed = 115200
build_flags = -DARDUINO_USB_MODE=1
platform_packages =
platformio/framework-arduinoespressif32 @ https://github.com/espressif/arduino-esp32.git
Upon installing, the installer/build script will crash with the following Python error:
Resolving adafruit_feather_esp32s3_nopsram dependencies...
Already up-to-date.
Updating metadata for the vscode IDE...
UserSideException: Processing adafruit_feather_esp32s3_nopsram (platform: espressif32; board: adafruit_feather_esp32s3_nopsram; framework: arduino)
--------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/adafruit_feather_esp32s3_nopsram.html
PLATFORM: Espressif 32 (6.7.0) > Adafruit Feather ESP32-S3 No PSRAM
HARDWARE: ESP32S3 240MHz, 320KB RAM, 8MB Flash
DEBUG: Current (cmsis-dap) External (cmsis-dap, esp-bridge, esp-builtin, 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.0.1+sha.6b22339
- tool-esptoolpy @ 1.40501.0 (4.5.1)
- toolchain-riscv32-esp @ 12.2.0+20230208
- toolchain-xtensa-esp32s3 @ 12.2.0+20230208
KeyError: 'framework-arduinoespressif32-libs':
File "/Users/jensa/.platformio/penv/lib/python3.11/site-packages/platformio/builder/main.py", line 173:
env.SConscript("$BUILD_SCRIPT")
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Script/SConscript.py", line 612:
return _SConscript(self.fs, *files, **subst_kw)
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Script/SConscript.py", line 279:
exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
File "/Users/jensa/.platformio/platforms/espressif32/builder/main.py", line 368:
target_elf = env.BuildProgram()
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Util/envs.py", line 251:
return self.method(*nargs, **kwargs)
File "/Users/jensa/.platformio/penv/lib/python3.11/site-packages/platformio/builder/tools/piobuild.py", line 61:
env.ProcessProgramDeps()
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Util/envs.py", line 251:
return self.method(*nargs, **kwargs)
File "/Users/jensa/.platformio/penv/lib/python3.11/site-packages/platformio/builder/tools/piobuild.py", line 121:
env.BuildFrameworks(env.get("PIOFRAMEWORK"))
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Util/envs.py", line 251:
return self.method(*nargs, **kwargs)
File "/Users/jensa/.platformio/penv/lib/python3.11/site-packages/platformio/builder/tools/piobuild.py", line 347:
SConscript(env.GetFrameworkScript(name), exports="env")
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Script/SConscript.py", line 676:
return method(*args, **kw)
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Script/SConscript.py", line 612:
return _SConscript(self.fs, *files, **subst_kw)
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Script/SConscript.py", line 279:
exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
File "/Users/jensa/.platformio/platforms/espressif32/builder/frameworks/arduino.py", line 36:
SConscript(
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Script/SConscript.py", line 676:
return method(*args, **kw)
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Script/SConscript.py", line 612:
return _SConscript(self.fs, *files, **subst_kw)
File "/Users/jensa/.platformio/packages/tool-scons/scons-local-4.7.0/SCons/Script/SConscript.py", line 279:
exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
File "/Users/jensa/.platformio/packages/framework-arduinoespressif32@src-537c58760dafe7fcc8a1d9bbcf00b6f6/tools/platformio-build.py", line 38:
FRAMEWORK_LIBS_DIR = platform.get_package_dir("framework-arduinoespressif32-libs")
File "/Users/jensa/.platformio/penv/lib/python3.11/site-packages/platformio/platform/_packages.py", line 32:
pkg = self.get_package(name)
File "/Users/jensa/.platformio/penv/lib/python3.11/site-packages/platformio/platform/_packages.py", line 29:
return self.pm.get_package(spec or self.get_package_spec(name))
File "/Users/jensa/.platformio/penv/lib/python3.11/site-packages/platformio/platform/_packages.py", line 21:
owner=self.packages[name].get("owner"),
========================== [FAILED] Took 0.61 seconds ==========================
I have tried to manually deleted all folders with the name “framework-arduinoespressif32” from my /Users/name/.platformio/packages This obviously makes the install take longer, but it still will exit with the same errors. I’m on macOS 13.1, with all updates applied in PlatformIO ( Core 6.1.15, Home 3.4.4, EspressIF 6.7.0).
It looks like it’s just a variable that is incorrectly defined for the library path, but Python really isn’t my strong side… Any advice appreciated!