Open chyparo opened 2 years ago
Same
The toolchain was renamed, it for an ESP32 (not S2, C2 or C3 etc.) the line
should be
toolchain_xtensa_dir = platform.get_package_dir("toolchain-xtensa32-esp32")
instead
A safe alternative is setting platform = espressif32@3.5.0
in the platformio.ini
of the project to revert back to the known working platform with the previously named toolchain.
seems to pass error .. but new one now:
problably need to change PATH to reduce char
The command line is too long.
Using
A safe alternative is setting
platform = espressif32@3.5.0
in theplatformio.ini
of the project to revert back to the known working platform with the previously named toolchain.
Then replacing all the _error_string = cmd[0] + '\r' + err errorstring = cmd[0] + '\r' + err.decode('utf-8')
using, for "The command line is too long" error
[platformio]
packages_dir = C:\\pio
i have new problem.. it may be python vers. related .. but unable to fix it
Processing esp32dev (platform: espressif32@3.5.0; 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 (3.5.0) > Espressif ESP32 Dev Module
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-prog) 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.10006.210326 (1.0.6)
- tool-esptoolpy @ 1.30100.210531 (3.1.0)
- toolchain-esp32ulp @ 1.22851.191205 (2.28.51)
- toolchain-xtensa32 @ 2.50200.97 (5.2.0)
LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 45 compatible libraries
Scanning dependencies...
Dependency Graph
|-- ulptool-pio @ 0.1.0+sha.6d4c5c5
Building in release mode
cb([".pio\build\esp32dev\firmware.elf"], [".pio\build\esp32dev\src\ulp_counter.cpp.o"])
Running ulptool
C:\Users\administrator\.platformio\penv\Scripts\python.exe C:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio/src/esp32ulp_build_recipe.py -IC:\ULP_pulse\ulp -IC:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio\src\include\ulptool -IC:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio\src\ulpcc\include -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\config -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\app_trace -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\app_update -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\asio -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\bootloader_support -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\bt -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\coap -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\console -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\driver -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\efuse -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp-tls -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp32 -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_adc_cal -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_event -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_http_client -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_http_server -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_https_ota -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_https_server -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_ringbuf -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_websocket_client -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\espcoredump -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\ethernet -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\expat -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\fatfs -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\freemodbus -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\freertos -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\heap -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\idf_test -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\jsmn -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\json -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\libsodium -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\log -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\lwip -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\mbedtls -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\mdns -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\micro-ecc -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\mqtt -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\newlib -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\nghttp -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\nvs_flash -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\openssl -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\protobuf-c -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\protocomm -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\pthread -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\sdmmc -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\smartconfig_ack -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\soc -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\spi_flash -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\spiffs -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\tcp_transport -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\tcpip_adapter -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\ulp -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\unity -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\vfs -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\wear_levelling -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\wifi_provisioning -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\wpa_supplicant -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\xtensa-debug-module -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp-face -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp32-camera -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp-face -IC:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\fb_gfx -IC:\pio\framework-arduinoespressif32@3.10006.210326\cores\esp32 -IC:\pio\framework-arduinoespressif32@3.10006.210326\variants\esp32 -b C:\ULP_pulse -p C:\pio\framework-arduinoespressif32@3.10006.210326 -u C:\pio\toolchain-esp32ulp/bin -x
C:\pio\toolchain-xtensa32/bin -t C:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio/src/ --DARDUINO_ESP32_DEV --DARDUINO=10805 --DARDUINO_ARCH_ESP32 --DARDUINO_VARIANT=\"esp32\" --DARDUINO_BOARD=\"Espressif\ ESP32\ Dev\ Module\"
C:\pio\toolchain-xtensa32/bin\xtensa-esp32-elf-gcc -DESP_PLATFORM -MMD -MP -DWITH_POSIX -DMBEDTLS_CONFIG_FILE=mbedtls\esp_config.h -DHAVE_CONFIG_H -MT ulp_main.common.ld -E -P -xc -o ulp_main.common.ld -I C:\ULP_pulse\ulp -I C:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio\src\include\ulptool -I C:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio\src\ulpcc\include -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\config -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\app_trace -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\app_update -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\asio -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\bootloader_support -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\bt -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\coap -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\console -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\driver -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\efuse -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp-tls -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp32 -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_adc_cal -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_event -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_http_client -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_http_server -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_https_ota -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_https_server -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_ringbuf -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp_websocket_client -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\espcoredump -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\ethernet -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\expat -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\fatfs -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\freemodbus -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\freertos -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\heap -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\idf_test -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\jsmn -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\json -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\libsodium -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\log -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\lwip -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\mbedtls -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\mdns -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\micro-ecc -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\mqtt -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\newlib -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\nghttp -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\nvs_flash -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\openssl -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\protobuf-c -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\protocomm -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\pthread -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\sdmmc -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\smartconfig_ack -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\soc -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\spi_flash -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\spiffs -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\tcp_transport -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\tcpip_adapter -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\ulp -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\unity -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\vfs -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\wear_levelling -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\wifi_provisioning -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\wpa_supplicant -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\xtensa-debug-module -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp-face -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp32-camera -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\esp-face -I C:\pio\framework-arduinoespressif32@3.10006.210326\tools\sdk\include\fb_gfx -I C:\pio\framework-arduinoespressif32@3.10006.210326\cores\esp32 -I C:\pio\framework-arduinoespressif32@3.10006.210326\variants\esp32 -DARDUINO_ESP32_DEV -DARDUINO=10805 -DARDUINO_ARCH_ESP32 -DARDUINO_VARIANT="esp32" -DARDUINO_BOARD="Espressif\ -I C:\ULP_pulse\ulp -D__ASSEMBLER__ C:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio/src/ld\esp32.ulp.ld
<command-line>:0:15: warning: missing terminating " character
*** Error 1
*** [.pio\build\esp32dev\firmware.elf] Exception : An error returned by ulptool.
Traceback (most recent call last):
File "C:\pio\tool-scons\scons-local-4.3.0\SCons\Action.py", line 1279, in execute
result = self.execfunction(target=target, source=rsources, env=env)
File "C:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio\post_extra_script_ulptool.py", line 59, in cb
run_ulptool()
File "C:\ULP_pulse\.pio\libdeps\esp32dev\ulptool-pio\post_extra_script_ulptool.py", line 54, in run_ulptool
raise Exception("An error returned by ulptool.")
Exception: An error returned by ulptool.
=========================================== [FAILED] Took 3.84 seconds ===========================================
The terminal process "C:\Users\administrator\.platformio\penv\Scripts\platformio.exe 'run'" terminated with exit code: 1.
Terminal will be reused by tasks, press any key to close it.`
where did you modify the Python script? I didn't find a place that contains the line of code error_string = cmd[0] + '\r' + err error_string = cmd[0] + '\r' + err.decode('utf-8')
shown above. For the rest i'm motivated to work on an updated version.
where did you modify the Python script? I didn't find a place that contains the line of code
error_string = cmd[0] + '\r' + err error_string = cmd[0] + '\r' + err.decode('utf-8')
shown above. For the rest i'm motivated to work on an updated version.
https://github.com/likeablob/ulptool-pio/blob/feat-pio-integration/src/esp32ulp_build_recipe.py
I tried to fix most of the issues on Windows, you can find the fork here: https://github.com/powelllens/ulptool-pio
Unfortunately i was unable to get the ulp_Readme running.
Seems to be one of the most common issues: undefined reference to 'ulp_count'
I noticed many broken links and references: https://github.com/powelllens/ulptool-pio/blob/e6f504824dc01488ab3f960b2c379e425f62783b/src/esp32ulp_build_recipe.py#L340 https://github.com/powelllens/ulptool-pio/blob/e6f504824dc01488ab3f960b2c379e425f62783b/src/esp32ulp_build_recipe.py#L373
These links to files and locations have been changed since the last running version. Currently I'm not sure if all links are correctly redirected 'tools', 'sdk', 'esp32', 'include', 'soc', 'esp32', 'include', 'soc') old-> #\tools\sdk\include\soc 'tools', 'sdk', 'esp32', 'include', 'soc', 'include', 'soc') old -> #\tools\sdk\include\soc\soc
While comparing the @3.5.0 and newest version i noticed many more files missing and bad links which might end up in the broken build. The ASM Build process seems to run fine, but the rest (linking to the project) is broken and I do not see any change to correct this by myself. I would need detailed information about the purpose of the files and the new position.
As an example: since v2.0.0 the files esp32.ld and esp32_out.ld are gone but still linked in the Recipe Build.
finally! .. thanks @powelllens
reinstall all, in new machine.. windows, Vscode platformio.. all then compilation show me SUCCESS
Hello, examples passed well when switch to platform = espressif32@3.5.0
My setup is Linux
But I need current platform = espressif32 version, and faces this issue:
FileNotFoundError: [Errno 2] No such file or directory: '~/.platformio/packages/framework-arduinoespressif32/tools/sdk/include/config/sdkconfig.h'
Looking at script
.pio/libdeps/esp32dev/ulptool-pio/src/esp32ulp_build_recipe.py
and can not understand, it's passed sdkconfig.h file open at line #175 and failed at the very similar line #269
I am grateful in advance for any help
UPDATE:
Dirty Hack:
create folder ~/.platformio/packages/framework-arduinoespressif32/tools/sdk/include/config
and copy sdkconfig.h
file from ~/.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/qio_qspi/include
@ssriblo It builds with
platform = espressif32@~5.2.0
wihout the dirty hack if you put
sdk_hash = md5(os.path.join(PATHS['core'] , 'tools', 'sdk', 'esp32', 'dio_qspi', 'include', 'sdkconfig.h'))
into https://github.com/likeablob/ulptool-pio/blob/6d4c5c51c13ca5a371edf96cfaf1fa2f2194ba88/src/esp32ulp_build_recipe.py#L269 and https://github.com/likeablob/ulptool-pio/blob/6d4c5c51c13ca5a371edf96cfaf1fa2f2194ba88/src/esp32ulp_build_recipe.py#L175
and ofcourse
toolchain_xtensa_dir = platform.get_package_dir("toolchain-xtensa-esp32")
into https://github.com/likeablob/ulptool-pio/blob/6d4c5c51c13ca5a371edf96cfaf1fa2f2194ba88/post_extra_script_ulptool.py#L24
Okay so I created a PR with the changes I needed to make to make it compile: https://github.com/likeablob/ulptool-pio/pull/3
Hi guys, sry for the late reply. I'm gonna merge PR #3 from @xtrinch .
For the sdkconfig.h
related issue, I guess the framework generates separate .h
s depending on board_build.flash_mode = qio | qout | dio | dout
(doc).
$ find ~/.platformio/packages/framework-arduinoespressif32@3.20004.0/tools/sdk/esp32/ -iname sdkconfig.h
~/.platformio/packages/framework-arduinoespressif32@3.20004.0/tools/sdk/esp32/qio_qspi/include/sdkconfig.h
~/.platformio/packages/framework-arduinoespressif32@3.20004.0/tools/sdk/esp32/dio_qspi/include/sdkconfig.h
~/.platformio/packages/framework-arduinoespressif32@3.20004.0/tools/sdk/esp32/dout_qspi/include/sdkconfig.h
~/.platformio/packages/framework-arduinoespressif32@3.20004.0/tools/sdk/esp32/qout_qspi/include/sdkconfig.h
If so, passing the flash_mode
value to esp32ulp_build_recipe.py
or just calculating and concatenating all the file hashes would be preferable.
toolchain_xtensa_dir = platform.get_package_dir("toolchain-xtensa-esp32")
i get "the command line is too long" when using your workaround
Try with example from #4.
Try with example from #4.
Thanks.
ok, so i have mix problem now. It seems that the compilation are OK now.
[env]
platform = espressif32@5.3.0
and
lib_deps =
https://github.com/maxgerhardt/ulptool-pio.git
i didnt see the python script execution in terminal? is this normal?
EDIT: its working!! just need to adapt my code from 3.5 to the 5.3
I have problem to compile any working code from the past and even an example. The compiler terminates with this error:
================================ [FAILED] Took 3.63 seconds ================================ Proces terminálu platformio 'run', '--target', 'upload' byl ukončen s ukončovacím kódem: 1.