MSC: Tinyusb with SD card as MSC device will lose in PC [UEFI:Built-in EFI Shell] .error #1396
PhoenixLauCN
started this conversation in
General
Replies: 1 comment 1 reply
-
|
move to discussion since this is more likely your firmware issue than the stack. Feel free to provide minimal firmware (best with slightly modified stock example) to prove if it is the stack issue. Also please attach your debug log as txt for readability. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Operating System
Others
Board
EPS32-S2 ro S3
Firmware
Tinyusb with SD card as MSC device
What happened ?
1.Function:Mass Storage Class (MSC) .
2.EPS32-S2 ro S3 with SD card whole as MSC device.
3.Error1:on PC(personal computer) internal efi shell environment,Pull and insert Tinyusb's usb device(base on EPS32-S2 ro S3 with SD card),will lose Tinyusb's usb MSC device.
3.1:you can reboot your PC and press keyboard [F12],you can see boot device:[UEFI:Built-in EFI Shell],press keyboard [Enter] to enter internal efi shell environment.
3.2:enter internal efi shell environment.you can see [EFI Shell version 2.x () current running mode 1.1.2 map:...]
4.Error2:insert usb MSC device in your PC,on PC(personal computer) internal efi shell environment,press keyboard input [reset] to reboot PC,Enter again internal efi shell environment,will lose Tinyusb's usb MSC device.
5.Key information
USBD Xfer Complete on EP 00 with 0 bytes
USBD Xfer Complete on EP 01 with 31 bytes
How to reproduce ?
4.Error2:insert usb MSC device in your PC,on PC(personal computer) internal efi shell environment,press keyboard input [reset] to reboot PC,Enter again internal efi shell environment,will lose Tinyusb's usb MSC device.
Debug Log
6.Debug code
【Pass】
`USBD Bus Reset
USBD Setup Received 80 06 00 01 00 00 08 00
Get Descriptor Device
Queue EP 80 with 8 bytes ... OK
USBD Xfer Complete on EP 80 with 8 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 00 05 01 00 00 00 00 00
Set Address
USBD Xfer Complete on EP 80 with 0 bytes
USBD Setup Received 80 06 00 01 00 00 12 00
Get Descriptor Device
Queue EP 80 with 18 bytes ... OK
USBD Xfer Complete on EP 80 with 18 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 00 02 00 00 FF 00
Get Descriptor Configuration[0]
Queue EP 80 with 32 bytes ... OK
USBD Xfer Complete on EP 80 with 32 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 00 09 01 00 00 00 00 00
Set Configuration
Open EP 01 with Size = 64
Open EP 81 with Size = 64
Queue EP 01 with 31 bytes ... OK
MSC opened
I (422070) tud_mount_cb: /tinyusb/additions/src/tusb_msc.c
Queue EP 80 with 0 bytes ... OK
USBD Xfer Complete on EP 80 with 0 bytes
USBD Setup Received 80 06 00 02 00 00 09 00
Get Descriptor Configuration[0]
Queue EP 80 with 9 bytes ... OK
USBD Xfer Complete on EP 80 with 9 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 00 02 00 00 20 00
Get Descriptor Configuration[0]
Queue EP 80 with 32 bytes ... OK
USBD Xfer Complete on EP 80 with 32 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 00 03 00 00 FF 00
Get Descriptor String[0]
Queue EP 80 with 4 bytes ... OK
USBD Xfer Complete on EP 80 with 4 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 01 03 09 04 FF 00
Get Descriptor String[1]
Queue EP 80 with 36 bytes ... OK
USBD Xfer Complete on EP 80 with 36 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 02 03 09 04 FF 00
Get Descriptor String[2]
Queue EP 80 with 34 bytes ... OK
USBD Xfer Complete on EP 80 with 34 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 03 03 09 04 FF 00
Get Descriptor String[3]
Queue EP 80 with 14 bytes ... OK
USBD Xfer Complete on EP 80 with 14 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 00 02 00 00 FF 00
Get Descriptor Configuration[0]
Queue EP 80 with 32 bytes ... OK
USBD Xfer Complete on EP 80 with 32 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received A1 FE 00 00 00 00 01 00
MSC control request
Queue EP 80 with 1 bytes ... OK
USBD Xfer Complete on EP 80 with 1 bytes
MSC control complete
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Inquiry
Queue EP 81 with 36 bytes ... OK
USBD Xfer Complete on EP 81 with 36 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read Capacity10
Queue EP 81 with 8 bytes ... OK
USBD Xfer Complete on EP 81 with 8 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Test Unit Ready
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read Capacity10
Queue EP 81 with 8 bytes ... OK
USBD Xfer Complete on EP 81 with 8 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read10
Queue EP 81 with 512 bytes ... OK
USBD Xfer Complete on EP 81 with 512 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read10
Queue EP 81 with 512 bytes ... OK
USBD Xfer Complete on EP 81 with 512 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Test Unit Ready
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Test Unit Ready
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read10
Queue EP 81 with 512 bytes ... OK
USBD Xfer Complete on EP 81 with 512 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Test Unit Ready
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read10
Queue EP 81 with 2048 bytes ... OK
USBD Xfer Complete on EP 81 with 2048 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Test Unit Ready
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read10
Queue EP 81 with 512 bytes ... OK
USBD Xfer Complete on EP 81 with 512 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Test Unit Ready
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read10
Queue EP 81 with 512 bytes ... OK
USBD Xfer Complete on EP 81 with 512 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Test Unit Ready
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
USBD Xfer Complete on EP 01 with 31 bytes
MSC xfer callback
SCSI Command: Read10
Queue EP 81 with 2048 bytes ... OK
USBD Xfer Complete on EP 81 with 2048 bytes
MSC xfer callback
SCSI Data
Queue EP 81 with 13 bytes ... OK
USBD Xfer Complete on EP 81 with 13 bytes
MSC xfer callback
SCSI Status: 0
Queue EP 01 with 31 bytes ... OK
/*******************************************************************************
【Fail】(lose Tinyusb's usb MSC device)
*******************************************************************************/
USBD Bus Reset
USBD Setup Received 80 06 00 01 00 00 08 00
Get Descriptor Device
Queue EP 80 with 8 bytes ... OK
USBD Xfer Complete on EP 80 with 8 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 00 05 01 00 00 00 00 00
Set Address
USBD Xfer Complete on EP 80 with 0 bytes
USBD Setup Received 80 06 00 01 00 00 12 00
Get Descriptor Device
Queue EP 80 with 18 bytes ... OK
USBD Xfer Complete on EP 80 with 18 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 00 02 00 00 FF 00
Get Descriptor Configuration[0]
Queue EP 80 with 32 bytes ... OK
USBD Xfer Complete on EP 80 with 32 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 00 09 01 00 00 00 00 00
Set Configuration
Open EP 01 with Size = 64
Open EP 81 with Size = 64
Queue EP 01 with 31 bytes ... OK
MSC opened
I (22130) tud_mount_cb: /tinyusb/additions/src/tusb_msc.c
Queue EP 80 with 0 bytes ... OK
USBD Xfer Complete on EP 80 with 0 bytes
USBD Setup Received 80 06 00 02 00 00 09 00
Get Descriptor Configuration[0]
Queue EP 80 with 9 bytes ... OK
USBD Xfer Complete on EP 80 with 9 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 00 02 00 00 20 00
Get Descriptor Configuration[0]
Queue EP 80 with 32 bytes ... OK
USBD Xfer Complete on EP 80 with 32 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 00 03 00 00 FF 00
Get Descriptor String[0]
Queue EP 80 with 4 bytes ... OK
USBD Xfer Complete on EP 80 with 4 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 01 03 09 04 FF 00
Get Descriptor String[1]
Queue EP 80 with 36 bytes ... OK
USBD Xfer Complete on EP 80 with 36 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 02 03 09 04 FF 00
Get Descriptor String[2]
Queue EP 80 with 34 bytes ... OK
USBD Xfer Complete on EP 80 with 34 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 03 03 09 04 FF 00
Get Descriptor String[3]
Queue EP 80 with 14 bytes ... OK
USBD Xfer Complete on EP 80 with 14 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 80 06 00 02 00 00 FF 00
Get Descriptor Configuration[0]
Queue EP 80 with 32 bytes ... OK
USBD Xfer Complete on EP 80 with 32 bytes
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received A1 FE 00 00 00 00 01 00
MSC control request
Queue EP 80 with 1 bytes ... OK
USBD Xfer Complete on EP 80 with 1 bytes
MSC control complete
Queue EP 00 with 0 bytes ... OK
USBD Xfer Complete on EP 00 with 0 bytes
USBD Setup Received 21 FF 00 00 00 00 00 00
MSC control request
Queue EP 80 with 0 bytes ... OK
USBD Xfer Complete on EP 80 with 0 bytes
USBD Setup Received 02 01 00 00 81 00 00 00
Clear Feature
MSC control request
Queue EP 80 with 0 bytes ... OK
USBD Xfer Complete on EP 80 with 0 bytes
USBD Setup Received 02 01 00 00 01 00 00 00
Clear Feature
MSC control request
Queue EP 80 with 0 bytes ... OK
USBD Xfer Complete on EP 80 with 0 bytes
`
Screenshots
No response
Beta Was this translation helpful? Give feedback.
All reactions