OpenOCD
cmsis_dap_usb_bulk.c File Reference
Include dependency graph for cmsis_dap_usb_bulk.c:

Go to the source code of this file.

Data Structures

struct  cmsis_dap_backend_data
 

Functions

static int cmsis_dap_usb_alloc (struct cmsis_dap *dap, unsigned int pkt_sz)
 
static void cmsis_dap_usb_close (struct cmsis_dap *dap)
 
static int cmsis_dap_usb_open (struct cmsis_dap *dap, uint16_t vids[], uint16_t pids[], const char *serial)
 
static int cmsis_dap_usb_read (struct cmsis_dap *dap, int timeout_ms)
 
static int cmsis_dap_usb_write (struct cmsis_dap *dap, int txlen, int timeout_ms)
 
 COMMAND_HANDLER (cmsis_dap_handle_usb_interface_command)
 

Variables

const struct cmsis_dap_backend cmsis_dap_usb_backend
 
static int cmsis_dap_usb_interface = -1
 
const struct command_registration cmsis_dap_usb_subcommand_handlers []
 

Function Documentation

◆ cmsis_dap_usb_alloc()

static int cmsis_dap_usb_alloc ( struct cmsis_dap dap,
unsigned int  pkt_sz 
)
static

◆ cmsis_dap_usb_close()

static void cmsis_dap_usb_close ( struct cmsis_dap dap)
static

◆ cmsis_dap_usb_open()

◆ cmsis_dap_usb_read()

◆ cmsis_dap_usb_write()

static int cmsis_dap_usb_write ( struct cmsis_dap dap,
int  txlen,
int  timeout_ms 
)
static

◆ COMMAND_HANDLER()

COMMAND_HANDLER ( cmsis_dap_handle_usb_interface_command  )

Definition at line 455 of file cmsis_dap_usb_bulk.c.

Variable Documentation

◆ cmsis_dap_usb_backend

const struct cmsis_dap_backend cmsis_dap_usb_backend
Initial value:
= {
.name = "usb_bulk",
.packet_buffer_alloc = cmsis_dap_usb_alloc,
}
static int cmsis_dap_usb_write(struct cmsis_dap *dap, int txlen, int timeout_ms)
static int cmsis_dap_usb_alloc(struct cmsis_dap *dap, unsigned int pkt_sz)
static int cmsis_dap_usb_open(struct cmsis_dap *dap, uint16_t vids[], uint16_t pids[], const char *serial)
static int cmsis_dap_usb_read(struct cmsis_dap *dap, int timeout_ms)
static void cmsis_dap_usb_close(struct cmsis_dap *dap)

Definition at line 455 of file cmsis_dap_usb_bulk.c.

◆ cmsis_dap_usb_interface

int cmsis_dap_usb_interface = -1
static

Definition at line 42 of file cmsis_dap_usb_bulk.c.

Referenced by cmsis_dap_usb_open().

◆ cmsis_dap_usb_subcommand_handlers

const struct command_registration cmsis_dap_usb_subcommand_handlers[]
Initial value:
= {
{
.name = "interface",
.handler = &cmsis_dap_handle_usb_interface_command,
.mode = COMMAND_CONFIG,
.help = "set the USB interface number to use (for USB bulk backend only)",
.usage = "<interface_number>",
},
}
#define COMMAND_REGISTRATION_DONE
Use this as the last entry in an array of command_registration records.
Definition: command.h:247
@ COMMAND_CONFIG
Definition: command.h:41

Definition at line 455 of file cmsis_dap_usb_bulk.c.