Skip to content

[HWCDC] Missing data via USB Serial on S3 #11959

@vvb333007

Description

@vvb333007

Board

ESP32S3 Dev Module

Device Description

Generic ESP32-S3 board, Devkit clone, N16R8 variant, 2 ports: native usb and uart/usb bridge

Hardware Configuration

Powered through the usb link. Monitored via TeraTerm

Version

v3.3.2

Type

Bug

IDE Name

Arduino IDE

Operating System

Windows 10

Flash frequency

80

PSRAM enabled

yes

Upload speed

115200

Description

Time to time, when printing strings via Serial.write() (class HWCDC) some chunks of text are missing. Exactly as described in the issue #9378. Looks like somebody or something clears output buffer. As a result, instead of

"Hello World! USB console is working,
yay! Does it?"

you'll get

"Hello USB console is working,
yay! it?"

One more observation: if I use just fwrite(..., stdout) then it all works: fast and no missing text. I tried it with Arduino Cores 3.0.x and 3.3.2 - behaviour is the same.

Another example of lost text:

"% exec : Execute scripts/aliases
% : Exit"

instead of

"% exec : Execute scripts/aliases
% exit : Exit"

Sketch

Single call:
          "%             -- ESPShell Keys -- \r\n\r\n"
          "% <ENTER>         : Execute command.\r\n"
          "% <- ->           : Arrows: move cursor left or right. Up and down to scroll\r\n"
          "%                   through command history\r\n"
          "% <DEL>           : As in Notepad\r\n"
          "% <BACKSPACE>     : As in Notepad\r\n"
          "% <HOME>, <END>   : Use Ctrl+A instead of <HOME> and Ctrl+E as <END>\r\n"
          "% <TAB>           : Move cursor to the next word/argument: press <TAB> multiple\r\n"
          "%                   times to cycle through words in the line\r\n"
          "% Ctrl+R          : Command history search\r\n"
          "% Ctrl+K          : [K]ill line: clear input line from cursor to the end\r\n"
          "% Ctrl+L          : Clear screen\r\n"
          "% Ctrl+Z          : Same as entering \"exit\" command\r\n"
          "% Ctrl+C          : Suspend sketch execution\r\n"
          "% <ESC>,NUM,<ESC> : Same as entering letter with decimal ASCII code NUM\r\n%\r\n"
          "% -- Terminal compatibility workarounds (alternative key sequences) --\r\n%\r\n"
          "% Ctrl+B and Ctrl+F work as \"<-\" and \"->\" ([B]ack & [F]orward arrows)>\r\n"
          "% Ctrl+O or P   : Go through the command history: O=backward, P=forward\r\n"
          "% Ctrl+D works as <[D]elete> key\r\n"
          "% Ctrl+H works as <BACKSPACE> key\r\n");

Or multiple calls in sequence with shorter strings as well

Debug Message

No relevant debug/verbose messages

Other Steps to Reproduce

No response

I have checked existing issues, online documentation and the Troubleshooting Guide

  • I confirm I have checked existing issues, online documentation and Troubleshooting guide.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions