-
Notifications
You must be signed in to change notification settings - Fork 7.4k
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
[ESP32H2] IDF v5.1 Monitor: Input on app console causes monitor to freeze (IDFGH-10666) #11896
Comments
Duplicate report here: https://esp32.com/viewtopic.php?f=13&t=34673 |
Apologies, I made that post first but then decided I'd rather have a GH issue to track this, plus I was able to add more details here. |
Hi, are you using the native USB port of ESP32H2? Can you see the same behavior when using the UART port (if available)? Have you tried setting 'Channel for console output' to USB Serial? - You can do it with the menuconfig command under 'Component config > ESP System Settings > Channel for console output' |
Yes, this is the native USB-C port on the ESP32-H2-DevKitM-1, not the UART port. I will try connecting up the UART to see if it reacts the same. I will double check menuconfig as well, though the output looks correct. I even get the |
@heliochronix Could you please also try examples/system/console/basic with the setting mentioned by @peterdragun above (CONFIG_ESP_CONSOLE_USB_SERIAL_JTAG)? That example definitely works over USB_SERIAL_JTAG when that option is enabled. |
Sure, I just need to figure out how to disable the various wifi subsystems as this board does not have wifi, and it's preventing it from building. Edit: And apparently the sleep subsystems, as that is not yet available on the H2 |
My bad, I forgot that we haven't backported bb3f1fd to release/v5.1 yet. Please try to |
It didn't exactly apply cleanly, but I did resolve the conflict. Also there appears to be a typo in As for the results of the test, the behavior is identical. It outputs everything, but I can't type anything and CTRL-] doesn't work, along with CTRL-T and any subsequent commands except for the help text. Example output:
|
Following up on the other testing, connecting up to the UART directly seems to work. It's seemingly just USB Serial/JTAG that is causing issues on the monitor. |
In the case of examples/system/console/basic, could you please confirm that you have CONFIG_ESP_CONSOLE_USB_SERIAL_JTAG=y in the sdkconfig file? |
Setting this does result in a functional USB Serial/JTAG interface. This is good to know! When I tested this on the other app I was still having issues. Let me double check that though... |
As far as I can tell, openthread/ot_cli example, unlike system/console/basic, doesn't implement console support via USB_SERIAL_JTAG, there is only UART support. (cc @chshu) The reason why you still see output on USB_SERIAL_JTAG is that by default, CONFIG_ESP_CONSOLE_SECONDARY_USB_SERIAL_JTAG is enabled on ESP32-H2. This forwards stdout and stderr to USB_SERIAL_JTAG, in addition to UART. That secondary channel is output-only, however. |
Ah, that must be what happened... Okay thank you, this clarifies things greatly. |
@heliochronix You may follow this #11924 (comment) to enable USB port for ot_cli example. |
Answers checklist.
General issue report
I'm running an Arch system with kernel 6.4.3, and I have the latest
release/v5.1
branch pulled (as of this posting). I'm having an issue with the IDF Monitor when talking to an ESP32-H2 board running a console app.During the
get-started/hello_world
orget-started/blink
program, output from the monitor is normal, though input on the keyboard seems to cause it to hang up for a bit before it resumes outputting stuff from the target. This is apparently expected behavior for non-console apps.However, if I try to run something like
openthread/ot_cli
that has a console, it will output fine at first but any keyboard input seems to freeze things up, to the point I can't even use CTRL-] or CTRL-T CTRL-X to exit the console and I'm forced to manually kill the python process. I can still get CTRL-T CTRL-H to output help text, but resetting, quitting, and rebuilding/flashing the target all seem to do nothing, and all output from the target stops. The only way to get it back seems to be killing the monitor python process and restarting it, which causes the reset to trigger.Any help in troubleshooting this would be appreciated! I'm relatively new, so apologies if I've missed some common troubleshooting steps.
The text was updated successfully, but these errors were encountered: