[SOLVED] Firmware 1.7.8 build failed when flashing firmware on linux.
-
Hello,
I have an issue with building the latest firwmare 1.7.8. I follow all the instructions on the github readme and I installed this version of the toolchain: https://dl.espressif.com/dl/xtensa-esp32-elf-linux64-1.22.0-61-gab8375a-5.2.0.tar.gz
Everything runs great except the last step when running flash command
make BOARD=LOPY -j5 LORA_BAND=USE_BAND_868 flashI get permission denied which is expected because I want to access serial communication
esptool.py v2.0.1 Traceback (most recent call last): File "/home/yahia/micropython/pycom-esp-idf/components/esptool_py/esptool/esptool.py", line 2412, in <module> _main() File "/home/yahia/micropython/pycom-esp-idf/components/esptool_py/esptool/esptool.py", line 2405, in _main main() File "/home/yahia/micropython/pycom-esp-idf/components/esptool_py/esptool/esptool.py", line 2134, in main esp = chip_class(args.port, initial_baud) File "/home/yahia/micropython/pycom-esp-idf/components/esptool_py/esptool/esptool.py", line 175, in __init__ self._port = serial.serial_for_url(port) File "/home/yahia/.local/lib/python2.7/site-packages/serial/__init__.py", line 88, in serial_for_url instance.open() File "/home/yahia/.local/lib/python2.7/site-packages/serial/serialposix.py", line 268, in open raise SerialException(msg.errno, "could not open port {}: {}".format(self._port, msg)) serial.serialutil.SerialException: [Errno 13] could not open port /dev/ttyUSB0: [Errno 13] Permission denied: '/dev/tt yUSB0' application.mk:382: recipe for target 'flash' failed make: *** [flash] Error 1However when I run the same command with sudo i get this error:
python ../py/makeversionhdr.py build/LOPY_868/release/genhdr/mpversion.h make: *** No rule to make target '/components/esp32/ld/esp32.ld', needed by 'build/LOPY_868/release/esp32_out.ld'. Stop. make: *** Waiting for unfinished jobs....Does anyone know why this happens? Maybe I am missing a step.
Thank you.
Yahia
-
@yahia
I think when you sudo-ed you lost your IDF_PATH environment variable (which points to pycom-esp-idf )I'd recommend simply having permissions on your tty device to include your regular user. For example on Ubuntu this means adding yourself to group dialout:
sudo adduser $USER dialout -
@jmarcelino Works great! Thank you very much sir.
-
@yahia another option (if you have WiFi enabled) is just to copy the generated appimg.bin into /flash/sys using FTP.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login