logo elektroda
logo elektroda
X
logo elektroda

[Solved] ESP32 and Aduino IDE (under Linux) - ModuleNotFoundError: No module named 'serial'.

CC_PL 654 4
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
  • #1 20510139
    CC_PL
    Level 13  
    I have an Arduino IDE under Linux (in the form of APPIMAGE - in one file) and I am using ESP32.

    In the Arduino IDE I get an error (when trying to verify the code):

    Quote:
    Traceback (most recent call last):
    File "/home/cc/.arduino15/packages/esp32/tools/esptool_py/4.5.1/esptool.py", line 31, in
    import esptool
    File "/home/cc/.arduino15/packages/esp32/tools/esptool_py/4.5.1/esptool/__init__.py", line 41, in
    from esptool.cmds import (
    File "/home/cc/.arduino15/packages/esp32/tools/esptool_py/4.5.1/esptool/cmds.py", line 14, in
    from .bin_image import ELFFile, ImageSegment, LoadFirmwareImage
    File "/home/cc/.arduino15/packages/esp32/tools/esptool_py/4.5.1/esptool/bin_image.py", line 14, in
    from .loader import ESPLoader
    File "/home/cc/.arduino15/packages/esp32/tools/esptool_py/4.5.1/esptool/loader.py", line 30, in
    import serial
    ModuleNotFoundError: No module named 'serial'

    exit status 1

    Compilation error: exit status 1


    It appears that the Arduino IDE uses a Python in which there is no pyserial, but I don't know how to check which Python the IDE uses.
    Do you have a problem with Arduino? Ask question. Visit our forum Arduino.
  • ADVERTISEMENT
  • #2 20510158
    khoam
    Level 42  
    Code: Bash
    Log in, to see the code
    .
  • ADVERTISEMENT
  • #3 20510587
    CC_PL
    Level 13  
    3.9.12 on Linux (system), but I also have Anaconda and I don't know if the Arduino IDE doesn't have its Python? I can't open the terminal from within the Arduino IDE.
  • ADVERTISEMENT
  • Helpful post
    #4 20510618
    khoam
    Level 42  
    CC_PL wrote:
    I don't know if the Arduino IDE doesn't have its own Python?
    No. It uses the system one.
  • #5 20510898
    CC_PL
    Level 13  
    OK, problem solved. You need to install the Arduino IDE from the Ubuntu Software application. The "portable" version in the form of the AppImage file doesn't quite work (even though it was downloaded from Arduino.cc).
ADVERTISEMENT