Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MicroPython crashes when accessed using mpremote #74

Open
andypiper opened this issue Jun 4, 2022 · 2 comments
Open

MicroPython crashes when accessed using mpremote #74

andypiper opened this issue Jun 4, 2022 · 2 comments

Comments

@andypiper
Copy link

MicroPython identifies itself as MicroPython afceb56-dirty on 2022-06-04; TiDAL with ESP32S3 when connected to in the REPL.

I can run mpremote devs to successfully list the attached device, and I can use mpremote connect mpremote connect /dev/cu.usbmodem1234561 (macOS) to connect to the REPL if no other apps (Thonny or Chrome WebSerial) are attached, but trying to run mpremote commands e.g. mpremote connect /dev/cu.usbmodem1234561 ls fails with the following trace (the board reboots to the EMF logo and locks up at this point)

$ mpremote connect /dev/cu.usbmodem1234561 ls                                 git:(master|)
Traceback (most recent call last):
  File "/opt/homebrew/lib/python3.9/site-packages/serial/serialposix.py", line 575, in read
    buf = os.read(self.fd, size - len(read))
OSError: [Errno 6] Device not configured

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/opt/homebrew/bin/mpremote", line 8, in <module>
    sys.exit(main())
  File "/opt/homebrew/lib/python3.9/site-packages/mpremote/main.py", line 478, in main
    pyb.enter_raw_repl(soft_reset=auto_soft_reset)
  File "/opt/homebrew/lib/python3.9/site-packages/mpremote/pyboard.py", line 352, in enter_raw_repl
    data = self.read_until(1, b"raw REPL; CTRL-B to exit\r\n")
  File "/opt/homebrew/lib/python3.9/site-packages/mpremote/pyboard.py", line 303, in read_until
    data = self.serial.read(min_num_bytes)
  File "/opt/homebrew/lib/python3.9/site-packages/serial/serialposix.py", line 581, in read
    raise SerialException('read failed: {}'.format(e))
serial.serialutil.SerialException: read failed: [Errno 6] Device not configured

I'm relatively certain this is not supposed to happen (I do Mpy development with other ESP32 boards, using MicroPython v1.18+ from GitHub nightlies).

Is there a board definition file / config I can use to build the firmware in the current MicroPython source tree?

@tomsci
Copy link
Contributor

tomsci commented Jun 4, 2022

mpremote is untested. If it has an option to disable soft reboot, try that.

Is there a board definition file / config I can use to build the firmware in the current MicroPython source tree?

No, sorry. You need to build using this repo.

@ithinuel
Copy link

ithinuel commented Jun 4, 2022

Have been trying to use the docker images but seems like we'll be hitting docker/for-mac#900.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants