Arduino IDE v1.8.9, esp32 v1.0.2 and ulptool v2.3.0

Are you messing with ultra low power esp32 code and have tried to setup the ulptool example from duff2013s GitHub in Arduino IDE v1.8.9 with Espressif Systems esp32 v1.0.2?

Maybe you got a lot of strange compile errors like these?

Traceback (most recent call last):
 File "C:\Users\<your user name>\AppData\Local\Arduino15\packages\esp32\tools\ulptool\src/esp32ulp_build_recipe.py", line 506, in 
 main(sys.argv[1:])
 File "C:\Users\
<your user name>\AppData\Local\Arduino15\packages\esp32\tools\ulptool\src/esp32ulp_build_recipe.py", line 106, in main
 build_ulp(PATHS, ulp_files, board_options, True)
 File "C:\Users\
<your user name>\AppData\Local\Arduino15\packages\esp32\tools\ulptool\src/esp32ulp_build_recipe.py", line 136, in build_ulp
 proc = subprocess.Popen(cmd[1],stdout=subprocess.PIPE,stderr=subprocess.PIPE,shell=False)
 File "C:\Python27\lib\subprocess.py", line 394, in init
 errread, errwrite)
 File "C:\Python27\lib\subprocess.py", line 644, in _execute_child
 startupinfo)
 WindowsError: [Error 2] The system cannot find the file specified
 exit status 1
 Error compiling for board ESP32 Dev Module.

Note: This error is also reported here: https://github.com/duff2013/ulptool/issues/35

It is quite a simple fix: The error is probably caused by Espressif Systems moving around some files in esp32 v.1.0.2 – or actually renaming a catalog.

You just need to edit a single file in ulptool v2.3.0. Simply open your platform.local.txt file and change the line:

compiler.ulp.path={runtime.tools.ulptool.path}/esp32ulp-elf-binutils/bin/

…to…

compiler.ulp.path={runtime.tools.ulptool.path}/bin/

…and you are “back in business” :-).

Leave a Reply

Your email address will not be published. Required fields are marked *