這個(gè)是HID類(lèi)協(xié)議。你可以看下HID類(lèi)協(xié)議。
把你配置描述符的值和SET-REPORT發(fā)的數(shù)組SetupSetReport里的值全部發(fā)上來(lái)看看
unsigned char SetupSetReport[]={0x21,0x09,0x00,0x02,0x00,0x00,0x01,0x00};
配置描述符的值呢?
const UINT8C SetupGetDevDescr[] = { 0x80, 0x06, 0x00, 0x01, 0x00, 0x00, 0x12, 0x00 }; /* 獲取配置描述符 */ const UINT8C SetupGetCfgDescr[] = { 0x80, 0x06, 0x00, 0x02, 0x00, 0x00, 0x04, 0x00 }; /* 設(shè)置USB地址 */ const UINT8C SetupSetUsbAddr[] = { 0x00, 0x05, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00 }; /* 設(shè)置USB配置 */ const UINT8C SetupSetUsbConfig[] = { 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; /* SET IDLE */ unsigned char SetupSetidle[]={0x21,0x0a,0x00,0x00,0x00,0x00,0x00,0x00}; /* 獲取HID 報(bào)告描述符 */ unsigned char SetupGetHidDes[]={0x81,0x06,0x00,0x22,0x00,0x00,0x81,0x00}; /* SET REPORT */ unsigned char SetupSetReport[]={0x21,0x09,0x00,0x02,0x00,0x00,0x01,0x00};
獲取的配置描述符的值呢