-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
ESP32S3: import wifi
crashes circuitpython
#5662
Comments
Reproduced on ESP32-S3 Box as well. |
I'm seeing the same thing on an ESP32-S3-DevKitC-1: Adafruit CircuitPython 7.2.0-alpha.1-16-gf2f38c7df-dirty on 2022-01-03; ESP32-S3-DevKitC-1 with ESP32S3 Has been working fine on my ESP32-S2 feather builds. |
This clearly isn't surprising but I've traced the hang to line 98 of Radio.c in port/espressif/common-hal/wifi/.
I've built the example fast_scan from the ESP-IDE and so far have been unable to recreate the crash. |
The S3 Dev Kit I'm using has two micro USB connectors, one shows up as /dev/ttyUSB0 and the other as /dev/ttyACM0. CircuitPython grabs the ACM0 port for the REPL and the DEBUG=1 output goes to the USB0 port. After placing some mp_printf statements that go to the USB0 port and some ESP_LOGW statements that go to the ACM0 port, it looks to me like the micro controller is not hanging, it's just reseting the /dev/ttyACM0 port. The device disappears from linux but the USB0 port is still there and continues to print debug information out until it has nothing more to do. I've placed print statements to both ports before and after the esp_wifi_start statement and here are the results: /dev/ttyACM0
/dev/ttyUSB0
From the DEBUG=1 messages it looks to me like the esp_wifi_start completed and program control continued. The REPL interface was somehow reset though so the user is disconnected from the microcontroller. The 'git diff' from the build that generated the above output:
|
Just for kicks, I modified an rgbblink program so that along with blinking the neopixel it manipulated a gpio pin in a way that the DEBUG output was updated and then added an "import wifi" statement. When I imported the updated rgbblink from the REPL, the REPL froze up, but the neopixel kept blinking and the debug output continued to display updates for the GPIO pin updates. |
@hathach Sounds like this could be a USB issue. |
tinyuf2 seems to work on S3 as well on S2. Maybe there is some conflict, I will try to test this out tomorrow and see if I could spot anything. |
Please reopen this issue, as I have it on ESP32-S3 DevKitC N8R2, with CP 8.2.0. I did apply this PR #5858 on CP 8.2.x and it solved my issue!! |
CircuitPython version
Code/REPL
Behavior
On the REPL:
On the serial debug console (build with DEBUG=1):
Description
As also reported by discord user "wgp", wifi doesn't seem to work at all with the esp32-s3
Additional information
No response
The text was updated successfully, but these errors were encountered: