kopia lustrzana https://github.com/majbthrd/pico-debug
rodzic
5035fb4ec7
commit
c5cfd9b8aa
3
main.c
3
main.c
|
@ -68,7 +68,6 @@ uint16_t tud_hid_get_report_cb(uint8_t instance, uint8_t report_id, hid_report_t
|
||||||
void tud_hid_set_report_cb(uint8_t instance, uint8_t report_id, hid_report_type_t report_type, uint8_t const* RxDataBuffer, uint16_t bufsize)
|
void tud_hid_set_report_cb(uint8_t instance, uint8_t report_id, hid_report_type_t report_type, uint8_t const* RxDataBuffer, uint16_t bufsize)
|
||||||
{
|
{
|
||||||
static uint8_t TxDataBuffer[CFG_TUD_HID_EP_BUFSIZE];
|
static uint8_t TxDataBuffer[CFG_TUD_HID_EP_BUFSIZE];
|
||||||
uint32_t response_size = TU_MIN(CFG_TUD_HID_EP_BUFSIZE, bufsize);
|
|
||||||
|
|
||||||
// This doesn't use multiple report and report ID
|
// This doesn't use multiple report and report ID
|
||||||
(void) instance;
|
(void) instance;
|
||||||
|
@ -77,5 +76,5 @@ void tud_hid_set_report_cb(uint8_t instance, uint8_t report_id, hid_report_type_
|
||||||
|
|
||||||
DAP_ProcessCommand(RxDataBuffer, TxDataBuffer);
|
DAP_ProcessCommand(RxDataBuffer, TxDataBuffer);
|
||||||
|
|
||||||
tud_hid_report(0, TxDataBuffer, response_size);
|
tud_hid_report(0, TxDataBuffer, sizeof(TxDataBuffer));
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,7 +25,7 @@ tusb_desc_device_t const desc_device =
|
||||||
/* using Dapper Miser CMSIS-DAP VID:PID */
|
/* using Dapper Miser CMSIS-DAP VID:PID */
|
||||||
.idVendor = 0x1209,
|
.idVendor = 0x1209,
|
||||||
.idProduct = 0x2488,
|
.idProduct = 0x2488,
|
||||||
.bcdDevice = 0x1004,
|
.bcdDevice = 0x1005,
|
||||||
|
|
||||||
.iManufacturer = STRID_MANUFACTURER,
|
.iManufacturer = STRID_MANUFACTURER,
|
||||||
.iProduct = STRID_PRODUCT,
|
.iProduct = STRID_PRODUCT,
|
||||||
|
|
Ładowanie…
Reference in New Issue