MCPcopy Create free account
hub / github.com/ARMmbed/DAPLink / DAP_queue_get_send_buf

Function DAP_queue_get_send_buf

source/daplink/cmsis-dap/DAP_queue.c:41–52  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

39 */
40
41BOOL DAP_queue_get_send_buf(DAP_queue * queue, uint8_t ** buf, int * len)
42{
43 if (queue->send_count) {
44 queue->send_count--;
45 *buf = queue->USB_Request[queue->send_idx];
46 *len = queue->resp_size[queue->send_idx];
47 queue->send_idx = (queue->send_idx + 1) % DAP_PACKET_COUNT;
48 queue->free_count++;
49 return (__TRUE);
50 }
51 return (__FALSE);
52}
53
54/*
55 * Overridable function to determine if the DAP activity should trigger or

Callers 3

hid_send_packetFunction · 0.85
usbd_hid_get_reportFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected