10enum class RequestDirection : uint8_t
20enum class RequestType : uint8_t
32enum class Recipient : uint8_t
44constexpr uint8_t REQ_DIRECTION_MASK = 0x80;
45constexpr uint8_t REQ_TYPE_MASK = 0x60;
46constexpr uint8_t REQ_RECIPIENT_MASK = 0x1F;
69enum class StandardRequest : uint8_t
77 GET_CONFIGURATION = 8,
78 SET_CONFIGURATION = 9,
88enum class Speed : uint8_t
97enum class USBSpec : uint16_t
106 USB_3_1_SUPER_SPEED_PLUS = 0x0321
USB 标准请求 SETUP 包(固定8字节) Standard USB setup packet (8 bytes)
uint16_t wIndex
对象索引,如接口号或端点号 / Index (e.g., interface or endpoint)
uint16_t wLength
数据阶段长度 / Number of bytes in data stage
uint16_t wValue
参数字段,含请求相关值 / Value field (e.g., descriptor type/index)
uint8_t bRequest
请求码 / Request code (e.g., GET_DESCRIPTOR)