Skip to content

ESP32-S2 USB-ACM target device [NOT UART]: hang on receive #8779

@hpax

Description

@hpax

Board

ESP32-S2-WROVER-I

Device Description

WROVER module on custom board (see below).

Hardware Configuration

Serial port (UART 0):
GPIO 0 - DTR
GPIO 43, 44 - RX/TX

LEDs:
GPIO 2, 3, 4

USB-C power control FETs: (configured as power sink)
#define PIN_USB_PWR_EN 7
#define PIN_USB_PWR_SINK 8

SPI link to FPGA: (using SPI2)
#define PIN_FPGA_CS2 1 /* Unused */
#define PIN_FPGA_INT 9
#define PIN_FPGA_CS 10
#define PIN_FPGA_IO0 11
#define PIN_FPGA_CLK 12
#define PIN_FPGA_IO1 13

JTAG link to FPGA:
#define PIN_FPGA_TDI 16
#define PIN_FPGA_TDO 17
#define PIN_FPGA_TMS 14
#define PIN_FPGA_TCK 18

I2C device (RTC); shared with FPGA (not never used by ESP32-S2):
#define PIN_I2C_SDA 5
#define PIN_I2C_SCL 6
#define PIN_RTC_32KHZ 15

External header:
GPIO 0, 21, 33-39 (includes ESP32-S2 JTAG and UART)

Schematic:
https://max80.abc80.org/docs/max80v2.sch.pdf

Version

v2.0.14

IDE Name

arduino-cli

Operating System

Linux

Flash frequency

Default (80 MHz I believe?)

PSRAM enabled

yes

Upload speed

921600

Description

Note: Serial = USB-ACM; Serial1 = UART

The ESP32-S2 ACM port using Serial.read() for reviewing data hangs fairly randomly; sometimes it is possible to download over a megabyte, but more frequently it hangs after about 400K, at least in my application.

Once it is hung, it can neither transmit nor receive.

This happened before ACM was broken in 2.0.10 (or thereabouts) and is happening again with 2.0.14.

Sketch

See https://git.zytor.com/abc80/max80/fw.git/tree/esp32/max80/tty.cpp

Debug Message

None

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

Labels

Peripheral: UARTRelated to the UART peripheral or its functionality.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions