USB-MSC : Device reset after multiple times mount on ESP32S2-MINI1 (ESP32S2-SF4)

Lalith1011
Posts: 6
Joined: Fri May 13, 2022 9:23 am

USB-MSC : Device reset after multiple times mount on ESP32S2-MINI1 (ESP32S2-SF4)

Postby Lalith1011 » Fri Oct 21, 2022 3:45 am

Iam using ESP32S2-MINI1 for USB-MISC (CDC + MSC) functionality. When I connect my device to a PC via USB, rarely ( once in 3 or 4 times) device is getting reset. I checked the logs and found out that the device was getting mounted twice (tud_mount_cb() function called twice) when the issue was occuring. Below are the logs that present a detailed info about the error. Can anyone please help as soon as possible? We are experiencing a serious delay in our product release.
Thanks.

Note: We checked with multiple devices and on multiple PCs and found the same issue. We ran the "cdc_msc_freertos" example code alone and "never" experienced this issue after testing the device for nearly 20 times straight.

LOGS:

I (1085) USB: USB CONNECTED //Log being printed from tud_mount_cb function.
I (1445) USB: USB CONNECTED
Guru Meditation Error: Core 0 panic'ed (LoadProhibited). Exception was unhandled.

Core 0 register dump:
PC : 0x40088388 PS : 0x00060031 A0 : 0x80088868 A1 : 0x3ffbdbf0
0x40088388: write_fifo_packet at dcd_dwc2.c:?

A2 : 0x00000000 A3 : 0x0000000f A4 : 0x00000000 A5 : 0x00000040
A6 : 0x00000000 A7 : 0x3ffbdbf0 A8 : 0x800886b0 A9 : 0x3ffbdbf0
A10 : 0x00000001 A11 : 0x00000000 A12 : 0x00000003 A13 : 0x00000000
A14 : 0x00000001 A15 : 0x3ffbdbf0 SAR : 0x0000001d EXCCAUSE: 0x0000001c
EXCVADDR: 0x00000000 LBEG : 0x00000003 LEND : 0x00000000 LCOUNT : 0x400243d9
0x400243d9: _xt_user_exc at C:/Users/Praveen/esp/esp-idf/components/freertos/port/xtensa/xtensa_vectors.S:633

Core 0 was running in ISR context:
EPC1 : 0x4002a7df EPC2 : 0x00000000 EPC3 : 0x00000000 EPC4 : 0x00000000
0x4002a7df: uart_hal_write_txfifo at C:/Users/Praveen/esp/esp-idf/components/hal/uart_hal_iram.c:35



Backtrace:0x40088385:0x3ffbdbf00x40088865:0x3ffbdc40 0x40088a9b:0x3ffbdc90 0x400870c1:0x3ffbdcd0 0x400244fa:0x3ffbdd00 0x400833a8:0x3ffc5410 0x40083853:0x3ffc5440 0x4009030e:0x3ffc5480 0x40027be1:0x3ffc54a0
0x40088385: write_fifo_packet at dcd_dwc2.c:?

0x40088865: handle_epin_irq at dcd_dwc2.c:?

0x40088a9b: dcd_int_handler at ??:?

0x400870c1: dcd_int_handler_wrap at dcd_dwc2.c:?

0x400244fa: _xt_lowint1 at C:/Users/Praveen/esp/esp-idf/components/freertos/port/xtensa/xtensa_vectors.S:1111

0x400833a8: get_driver at usbd.c:?

0x40083853: tud_task at ??:?

0x4009030e: usb_device_task at C:\Users\Praveen\esp\esp-idf\Workspace_Proton\proton-esp32s2\build/../components/USB_MSC_CDC/USB_main.c:212 (discriminator 1)

0x40027be1: vPortTaskWrapper at C:/Users/Praveen/esp/esp-idf/components/freertos/port/xtensa/port.c:131





ELF file SHA256: a6424d70874738c2

Rebooting...

Who is online

Users browsing this forum: No registered users and 162 guests