-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
USB Console stops logging when primary console (IDFGH-6454) #8113
Comments
Hi, @mdelete, |
But that's the thing: In my setup ESP_LOGx doesn't log on USB Serial even if I set it to be the primary output. I'll re-test on my side to be sure... |
@mdelete, Can you confirm that the USB Serial you monitored is the port of ESP32C3 built-in USB (USB-Serial-JTAG) instead of the port of UART-USB conversion chip? |
I retested it several times and the result is as originally reported: If I enable USB-Serial/JTAG as primary console (which sets secondary console to none) the last line both serial ports (USB-Serial as well as UART with USB-Serial conversion chip) log is: |
Did you connect the hardware according to this documention? USB-Serial conversion chip and built-in USB will be shown as different ports on your PC. Like in Ubuntu, the USB-Serial conversion chip shows the port /dev/ttyUSBx and the built-in USB shows the port /dev/ttyACMx, and you should specify the corresponding port to get print |
Could you please have a try with the config option CONFIG_USB_SERIAL_JTAG_CONSOLE is on? |
@mdelete There are two versions of ESP32-C3-DevKit-M-1, one is that the Micro-USB port on the board is connected to the built-in USB, the other is connected to the USB-Serial conversion chip, the Micro-USB in the picture below is connected to the USB-Serial conversion chip This is the print I got on the build-in USB port and USB-Serial port respectively on ESP32-C3-DevKit-M-1 v1.0: |
@esp-wzh My devkit is jumpered as seen in your first picture, I will change that to your suggested setup and retry. |
@mdelete How did you connect to get the port |
I think you're right, I think it is a macOS issue where different drivers claim the same device so this is the silabs chip, but twice. However, if I switch the resistors like you suggested, I also see a serial device, but I can only flash the device, there is no console at all, regardless which setting I chose in menconfig:
|
Ha, scratch that. Now it works! Thanks @esp-wzh for you support! I'll test around some more and then eventually close the ticket. |
Environment
Problem Description
If you set
Component config > ESP System Settings > Channel for console output
to USB Serial / JTAG Controller (in which case Channel for console secondary output is forced to no secondary console) then no ESP_LOG output from an app will be printed on the USB console. An app is running fine, though.In fact the last log output line seen on the USB console will be:
I (376) heap_init: At 50000010 len 00001FF0 (7 KiB): RTCRAM
If you set Channel for console output to Default: UART0 and secondary console to USB_SERIAL_JTAG_CONTROLLER then ESP_LOG output of an app will be visible on both consoles and the system log will not stop early:
Expected Behavior
The JTAG/serial console logs.
Actual Behavior
The JTAG/serial console stops logging early in the startup.
Steps to reproduce
idf.py menuconfig
and set (primary) console output to USB Serial / JTAG Controller.Code to reproduce this issue
[N/A]
Debug Logs
[N/A]
The text was updated successfully, but these errors were encountered: