USB Common#

Common parts for both host and device USB stacks.

Modules#

USB_Setup_TypeDef

USB_DeviceDescriptor_TypeDef

USB_ConfigurationDescriptor_TypeDef

USB_InterfaceDescriptor_TypeDef

USB_EndpointDescriptor_TypeDef

USB_StringDescriptor_TypeDef

Enumerations#

enum
USB_STATUS_OK = 0
USB_STATUS_REQ_ERR = -1
USB_STATUS_EP_BUSY = -2
USB_STATUS_REQ_UNHANDLED = -3
USB_STATUS_ILLEGAL = -4
USB_STATUS_EP_STALLED = -5
USB_STATUS_EP_ABORTED = -6
USB_STATUS_EP_ERROR = -7
USB_STATUS_EP_NAK = -8
USB_STATUS_DEVICE_UNCONFIGURED = -9
USB_STATUS_DEVICE_SUSPENDED = -10
USB_STATUS_DEVICE_RESET = -11
USB_STATUS_TIMEOUT = -12
USB_STATUS_DEVICE_REMOVED = -13
USB_STATUS_HC_BUSY = -14
USB_STATUS_DEVICE_MALFUNCTION = -15
USB_STATUS_PORT_OVERCURRENT = -16
}

USB transfer status enumerator.

Typedefs#

typedef unsigned short

Data type used for UTF-16LE formatted USB string descriptors.

typedef int(*
USB_XferCompleteCb_TypeDef)(USB_Status_TypeDef status, uint32_t xferred, uint32_t remaining)

USB transfer callback function.

typedef void(*

USBTIMER callback function.

Functions#

int
USB_PUTCHAR(char c)

Transmit a single char on the debug serial port.

void
USB_PUTS(const char *p)

Transmit a zero terminated string on the debug serial port.

int
USB_PRINTF(const char *format,...)

Transmit "printf" formated data on the debug serial port.

char *

Return an error message string for a given error code.

void
USB_PrintErrorMsgString(char *pre, int error)

Format and print a text string given an error code, prepends an optional user supplied leader string.

void
USBTIMER_DelayMs(uint32_t msec)

Active wait millisecond delay function.

void
USBTIMER_DelayUs(uint32_t usec)

Active wait microsecond delay function.

void

Activate the hardware timer used to pace the 1 millisecond timer system.

void
USBTIMER_Start(uint32_t id, uint32_t timeout, USBTIMER_Callback_TypeDef callback)

Start a timer.

void
USBTIMER_Stop(uint32_t id)

Stop a timer.

Macros#

#define

Silicon Labs Vendor ID, supplied by USB-IF.

#define

Setup request data stage OUT direction value.

#define

Setup request data stage IN direction value.

#define

Setup request data stage direction mask.

#define

Setup request data stage IN direction mask.

#define

Setup request data stage OUT direction mask.

#define

Standard setup request value.

#define

Class setup request value.

#define

Vendor setup request value.

#define

Standard setup request mask.

#define

Class setup request mask.

#define

Vendor setup request mask.

#define

Setup request device recipient value.

#define

Setup request interface recipient value.

#define

Setup request endpoint recipient value.

#define

Setup request other recipient value.

#define

Standard setup request GET_STATUS.

#define

Standard setup request CLEAR_FEATURE.

#define

Standard setup request SET_FEATURE.

#define

Standard setup request SET_ADDRESS.

#define

Standard setup request GET_DESCRIPTOR.

#define

Standard setup request SET_DESCRIPTOR.

#define

Standard setup request GET_CONFIGURATION.

#define

Standard setup request SET_CONFIGURATION.

#define

Standard setup request GET_INTERFACE.

#define

Standard setup request SET_INTERFACE.

#define

Standard setup request SYNCH_FRAME.

#define

HID class setup request GET_REPORT.

#define

HID class setup request GET_IDLE.

#define

HID class setup request SET_REPORT.

#define

HID class setup request SET_IDLE.

#define

HID class setup request SET_PROTOCOL.

#define

CDC class setup request SET_LINE_CODING.

#define

CDC class setup request GET_LINE_CODING.

#define

CDC class setup request SET_CONTROL_LINE_STATE.

#define

MSD class setup request Bulk only transfer reset.

#define

MSD class setup request Get Max LUN.

#define

Audio class setup request GET_CUR.

#define

Audio class setup request GET_CUR.

#define

Audio class setup request SET_CUR.

#define

Audio class setup request SET_MIN.

#define

Audio class setup request GET_MIN.

#define

Audio class setup request SET_MAX.

#define

Audio class setup request GET_MAX.

#define

Audio class setup request SET_RES.

#define

Audio class setup request GET_RES.

#define

Audio class setup request SET_MEM.

#define

Audio class setup request GET_MEM.

#define

Audio class setup request GET_STAT.

#define

DEVICE descriptor value.

#define

CONFIGURATION descriptor value.

#define

STRING descriptor value.

#define

Maximum STRING descriptor bString length.

#define

INTERFACE descriptor value.

#define

ENDPOINT descriptor value.

#define

DEVICE_QUALIFIER descriptor value.

#define

OTHER_SPEED_CONFIGURATION descriptor value.

#define

INTERFACE_POWER descriptor value.

#define

INTERFACE_ASSOCIATION descriptor value.

#define

HID descriptor value.

#define

Smartcard usb-ccid-specific Descriptor Type.

#define

HID REPORT descriptor value.

#define

Audio Class-specific interface Descriptor Type.

#define

Audio Class-specific endpoint Descriptor Type.

#define

HUB descriptor value.

#define

Audio Class-Specific AC Interface Header descriptor.

#define

Audio Class-Specific AC Interface Input Terminal desc.

#define

Audio Class-Specific AC Interface Output Terminal desc.

#define

Audio Class-Specific AC Interface Mixer descriptor.

#define

Audio Class-Specific AC Interface Selector desc.

#define

Audio Class-Specific AC Interface Feature desc.

#define

Audio Class-Specific AC Interface Processing desc.

#define

Audio Class-Specific AC Interface Extension desc.

#define

Audio Class-Specific general descriptor subtype code.

#define

Audio Class-Specific AS Interface General descriptor.

#define

Audio Class-Specific AS Interface Format Type desc.

#define

Device descriptor size.

#define

Configuration descriptor size.

#define

Interface descriptor size.

#define

Endpoint descriptor size.

#define

Device qualifier descriptor size.

#define

Device other speed configuration descriptor size.

#define

INTERFACE_ASSOCIATION descriptor size.

#define

HID descriptor size.

#define

CCID descriptor size.

#define

CDC Header functional descriptor size.

#define

CDC Call Management functional descriptor size.

#define

CDC Abstract Control Management functional descriptor size.

#define

Audio Input Terminal descriptor size.

#define

Audio Output Terminal descriptor size.

#define

Audio Class-Specific general descriptor subtype size.

#define

Audio Class-Specific AS Interface General desc size.

#define

Audio-class standard audio stream descriptor size.

#define

The max size of low speed control endpoints.

#define

The max size of low speed interrupt endpoints.

#define

The max size of full speed control endpoints.

#define

The max size of full speed interrupt endpoints.

#define

The max size of full speed bulk endpoints.

#define

The max size of full speed isochronous endpoints.

#define

Endpoint type control.

#define

Endpoint type isochron.

#define

Endpoint type bulk.

#define

Endpoint type interrupt.

#define
USB_EPSYNC_NO (0 << 2)

Endpoint synchronization type, none.

#define

Endpoint synchronization type, asynchronous.

#define

Endpoint synchronization type, adaptive.

#define

Endpoint synchronization type, synchronous.

#define

Endpoint direction mask.

#define

Setup request packet size.

#define

Endpoint number mask.

#define

English-United States language id.

#define

Maximum allowable device address.

#define

Configuration descriptor attribute macro.

#define

Configuration descriptor attribute macro.

#define

Configuration descriptor attribute macro.

#define

Configuration descriptor transfer type bitmask.

#define

Configuration descriptor power macro.

#define

Standard request GET_STATUS bitmask.

#define

Standard request GET_STATUS bitmask.

#define

Standard request CLEAR/SET_FEATURE bitmask.

#define

Standard request CLEAR/SET_FEATURE bitmask.

#define

HUB class request CLEAR/SET_PORT_FEATURE feature selector.

#define

HUB class request CLEAR/SET_PORT_FEATURE feature selector.

#define

HUB class request CLEAR/SET_PORT_FEATURE feature selector.

#define

HUB class request CLEAR/SET_PORT_FEATURE feature selector.

#define

HUB class request CLEAR/SET_PORT_FEATURE feature selector.

#define

CDC device/interface class code.

#define

CDC Data interface class code.

#define

CDC Abstract Control Model interface subclass code.

#define

CDC class Header Functional Descriptor subtype.

#define

CDC class Call Management Functional Descriptor subtype.

#define

CDC class Abstract Control Management Functional Descriptor subtype.

#define

CDC class Union Functional Descriptor subtype.

#define

HID device/interface class code.

#define

HID keyboard interface protocol code.

#define

HID mouse interface protocol code.

#define

HUB device/interface class code.

#define

MSD device/interface class code.

#define

MSD Bulk Only Transport protocol.

#define

MSD Subclass SCSI transparent command set.

#define

MSD BOT Command status wrapper command passed code.

#define

MSD BOT Command status wrapper command failed code.

#define

MSD BOT Command status wrapper cmd phase error code.

#define

Audio interface class code.

#define

Audio subclass code for control interface.

#define

Audio subclass code for streaming interface.

#define

Audio subclass code for midi streaming interface.

#define

MISCELLANEOUS device class code.

#define

MISCELLANEOUS Common sub class code.

#define

MISCELLANEOUS Interface Association Descriptor protocol code.

#define

Full speed return value for USBH_GetPortSpeed().

#define

Low speed return value for USBH_GetPortSpeed().

#define

Use LFXO as DPLL clock source.

#define

Use HFXO as DPLL clock source.

#define

Macro for creating USB compliant UTF-16LE UNICODE string descriptors.

#define

Macro for creating USB compliant language string descriptors.

#define
UBUF (x, y)

Macro for creating WORD (4 byte) aligned uint8_t array with size which is a multiple of WORD size.

#define

Macro for creating WORD (4 byte) aligned static uint8_t arrays with size which is a multiple of WORD size.

Enumeration Documentation#

USB_Status_TypeDef#

USB_Status_TypeDef

USB transfer status enumerator.

Enumerator
USB_STATUS_OK

No errors detected.

USB_STATUS_REQ_ERR

Setup request error.

USB_STATUS_EP_BUSY

Endpoint is busy.

USB_STATUS_REQ_UNHANDLED

Setup request not handled.

USB_STATUS_ILLEGAL

Illegal operation attempted.

USB_STATUS_EP_STALLED

Endpoint is stalled.

USB_STATUS_EP_ABORTED

Endpoint transfer was aborted.

USB_STATUS_EP_ERROR

Endpoint transfer error.

USB_STATUS_EP_NAK

Endpoint NAK'ed transfer request.

USB_STATUS_DEVICE_UNCONFIGURED

Device is unconfigured.

USB_STATUS_DEVICE_SUSPENDED

Device is suspended.

USB_STATUS_DEVICE_RESET

Device is/was reset.

USB_STATUS_TIMEOUT

Transfer timeout.

USB_STATUS_DEVICE_REMOVED

Device was removed.

USB_STATUS_HC_BUSY

Host channel is busy.

USB_STATUS_DEVICE_MALFUNCTION

Malfunctioning device attached.

USB_STATUS_PORT_OVERCURRENT

VBUS shortcircuit/overcurrent failure.


Definition at line 324 of file platform/middleware/usb_gecko/inc/em_usb.h

Typedef Documentation#

char16_t#

typedef unsigned short char16_t

Data type used for UTF-16LE formatted USB string descriptors.


Definition at line 252 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_XferCompleteCb_TypeDef#

typedef int(* USB_XferCompleteCb_TypeDef) (USB_Status_TypeDef status, uint32_t xferred, uint32_t remaining) )(USB_Status_TypeDef status, uint32_t xferred, uint32_t remaining)

USB transfer callback function.

Parameters
[in]status

The transfer status. See USB_Status_TypeDef.

[in]xferred

Number of bytes actually transferred.

[in]remaining

Number of bytes not transferred.

The callback function is called when a transfer has completed. An application should check the status, xferred and optionally the remaining parameters before deciding if the transfer is usable. In the case where the transfer is part of a control request data stage, the callback function should return an appropriate USB_Status_TypeDef status.

Returns


Definition at line 653 of file platform/middleware/usb_gecko/inc/em_usb.h

USBTIMER_Callback_TypeDef#

typedef void(* USBTIMER_Callback_TypeDef) (void) )(void)

USBTIMER callback function.

The callback function is called when an USBTIMER has expired. The callback is done with interrupts disabled.


Definition at line 663 of file platform/middleware/usb_gecko/inc/em_usb.h

Function Documentation#

USB_PUTCHAR#

int USB_PUTCHAR (char c)

Transmit a single char on the debug serial port.

Parameters
[in]c

Char to transmit.

Note

  • This function is enabled with #define DEBUG_USB_API when configuring the protocol stack in "usbconfig.h". This is convenient when debugging code, no need to remove use of this function when debugging has completed.

Returns

  • The char transmitted.


Definition at line 536 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_PUTS#

void USB_PUTS (const char * p)

Transmit a zero terminated string on the debug serial port.

Parameters
[in]p

Pointer to string to transmit.

Note

  • This function is enabled with #define DEBUG_USB_API when configuring the protocol stack in "usbconfig.h". This is convenient when debugging code, no need to remove use of this function when debugging has completed.


Definition at line 551 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_PRINTF#

int USB_PRINTF (const char * format, ... )

Transmit "printf" formated data on the debug serial port.

Parameters
[in]format

Format string (as in printf). No floating point format support.

N/A

Note

  • This function is enabled with #define USB_USE_PRINTF when configuring the protocol stack in "usbconfig.h". This is convenient when debugging code, no need to remove use of this function when debugging has completed.

Returns

  • Number of chars transmitted.


Definition at line 569 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_GetErrorMsgString#

char * USB_GetErrorMsgString (int error)

Return an error message string for a given error code.

Parameters
[in]error

Error code, see USB_Status_TypeDef.

Returns

  • Error message string pointer.


Definition at line 665 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_PrintErrorMsgString#

void USB_PrintErrorMsgString (char * pre, int error)

Format and print a text string given an error code, prepends an optional user supplied leader string.

Parameters
[in]pre

Optional leader string to prepend to error message string.

[in]error

Error code, see USB_Status_TypeDef.


Definition at line 668 of file platform/middleware/usb_gecko/inc/em_usb.h

USBTIMER_DelayMs#

void USBTIMER_DelayMs (uint32_t msec)

Active wait millisecond delay function.

Parameters
[in]msec

Number of milliseconds to wait.

Can also be used inside interrupt handlers.


Definition at line 170 of file platform/middleware/usb_gecko/src/em_usbtimer.c

USBTIMER_DelayUs#

void USBTIMER_DelayUs (uint32_t usec)

Active wait microsecond delay function.

Parameters
[in]usec

Number of microseconds to wait.

Can also be used inside interrupt handlers.


Definition at line 190 of file platform/middleware/usb_gecko/src/em_usbtimer.c

USBTIMER_Init#

void USBTIMER_Init (void )

Activate the hardware timer used to pace the 1 millisecond timer system.

Parameters
N/A

Call this function whenever the HFPERCLK frequency is changed. This function is initially called by HOST and DEVICE stack xxxx_Init() functions.


Definition at line 221 of file platform/middleware/usb_gecko/src/em_usbtimer.c

USBTIMER_Start#

void USBTIMER_Start (uint32_t id, uint32_t timeout, USBTIMER_Callback_TypeDef callback)

Start a timer.

Parameters
[in]id

Timer id (0..).

[in]timeout

Number of milliseconds before timer will elapse.

[in]callback

Function to be called on timer elapse, ref. USBTIMER_Callback_TypeDef.

If the timer is already running, it will be restarted with new timeout.


Definition at line 265 of file platform/middleware/usb_gecko/src/em_usbtimer.c

USBTIMER_Stop#

void USBTIMER_Stop (uint32_t id)

Stop a timer.

Parameters
[in]id

Timer id (0..).


Definition at line 327 of file platform/middleware/usb_gecko/src/em_usbtimer.c

Macro Definition Documentation#

SILABS_USB_VID#

#define SILABS_USB_VID
Value:
0x10C4

Silicon Labs Vendor ID, supplied by USB-IF.



Definition at line 66 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_DIR_OUT#

#define USB_SETUP_DIR_OUT
Value:
0

Setup request data stage OUT direction value.



Definition at line 69 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_DIR_IN#

#define USB_SETUP_DIR_IN
Value:
1

Setup request data stage IN direction value.



Definition at line 70 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_DIR_MASK#

#define USB_SETUP_DIR_MASK
Value:
0x80

Setup request data stage direction mask.



Definition at line 71 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_DIR_D2H#

#define USB_SETUP_DIR_D2H
Value:
0x80

Setup request data stage IN direction mask.



Definition at line 72 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_DIR_H2D#

#define USB_SETUP_DIR_H2D
Value:
0x00

Setup request data stage OUT direction mask.



Definition at line 73 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_TYPE_STANDARD#

#define USB_SETUP_TYPE_STANDARD
Value:
0

Standard setup request value.



Definition at line 76 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_TYPE_CLASS#

#define USB_SETUP_TYPE_CLASS
Value:
1

Class setup request value.



Definition at line 77 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_TYPE_VENDOR#

#define USB_SETUP_TYPE_VENDOR
Value:
2

Vendor setup request value.



Definition at line 78 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_TYPE_STANDARD_MASK#

#define USB_SETUP_TYPE_STANDARD_MASK
Value:
0x00

Standard setup request mask.



Definition at line 79 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_TYPE_CLASS_MASK#

#define USB_SETUP_TYPE_CLASS_MASK
Value:
0x20

Class setup request mask.



Definition at line 80 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_TYPE_VENDOR_MASK#

#define USB_SETUP_TYPE_VENDOR_MASK
Value:
0x40

Vendor setup request mask.



Definition at line 81 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_RECIPIENT_DEVICE#

#define USB_SETUP_RECIPIENT_DEVICE
Value:
0

Setup request device recipient value.



Definition at line 84 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_RECIPIENT_INTERFACE#

#define USB_SETUP_RECIPIENT_INTERFACE
Value:
1

Setup request interface recipient value.



Definition at line 85 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_RECIPIENT_ENDPOINT#

#define USB_SETUP_RECIPIENT_ENDPOINT
Value:
2

Setup request endpoint recipient value.



Definition at line 86 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_RECIPIENT_OTHER#

#define USB_SETUP_RECIPIENT_OTHER
Value:
3

Setup request other recipient value.



Definition at line 87 of file platform/middleware/usb_gecko/inc/em_usb.h

GET_STATUS#

#define GET_STATUS
Value:
0

Standard setup request GET_STATUS.



Definition at line 90 of file platform/middleware/usb_gecko/inc/em_usb.h

CLEAR_FEATURE#

#define CLEAR_FEATURE
Value:
1

Standard setup request CLEAR_FEATURE.



Definition at line 91 of file platform/middleware/usb_gecko/inc/em_usb.h

SET_FEATURE#

#define SET_FEATURE
Value:
3

Standard setup request SET_FEATURE.



Definition at line 92 of file platform/middleware/usb_gecko/inc/em_usb.h

SET_ADDRESS#

#define SET_ADDRESS
Value:
5

Standard setup request SET_ADDRESS.



Definition at line 93 of file platform/middleware/usb_gecko/inc/em_usb.h

GET_DESCRIPTOR#

#define GET_DESCRIPTOR
Value:
6

Standard setup request GET_DESCRIPTOR.



Definition at line 94 of file platform/middleware/usb_gecko/inc/em_usb.h

SET_DESCRIPTOR#

#define SET_DESCRIPTOR
Value:
7

Standard setup request SET_DESCRIPTOR.



Definition at line 95 of file platform/middleware/usb_gecko/inc/em_usb.h

GET_CONFIGURATION#

#define GET_CONFIGURATION
Value:
8

Standard setup request GET_CONFIGURATION.



Definition at line 96 of file platform/middleware/usb_gecko/inc/em_usb.h

SET_CONFIGURATION#

#define SET_CONFIGURATION
Value:
9

Standard setup request SET_CONFIGURATION.



Definition at line 97 of file platform/middleware/usb_gecko/inc/em_usb.h

GET_INTERFACE#

#define GET_INTERFACE
Value:
10

Standard setup request GET_INTERFACE.



Definition at line 98 of file platform/middleware/usb_gecko/inc/em_usb.h

SET_INTERFACE#

#define SET_INTERFACE
Value:
11

Standard setup request SET_INTERFACE.



Definition at line 99 of file platform/middleware/usb_gecko/inc/em_usb.h

SYNCH_FRAME#

#define SYNCH_FRAME
Value:
12

Standard setup request SYNCH_FRAME.



Definition at line 100 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HID_GET_REPORT#

#define USB_HID_GET_REPORT
Value:
0x01

HID class setup request GET_REPORT.



Definition at line 103 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HID_GET_IDLE#

#define USB_HID_GET_IDLE
Value:
0x02

HID class setup request GET_IDLE.



Definition at line 104 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HID_SET_REPORT#

#define USB_HID_SET_REPORT
Value:
0x09

HID class setup request SET_REPORT.



Definition at line 105 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HID_SET_IDLE#

#define USB_HID_SET_IDLE
Value:
0x0A

HID class setup request SET_IDLE.



Definition at line 106 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HID_SET_PROTOCOL#

#define USB_HID_SET_PROTOCOL
Value:
0x0B

HID class setup request SET_PROTOCOL.



Definition at line 107 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CDC_SETLINECODING#

#define USB_CDC_SETLINECODING
Value:
0x20

CDC class setup request SET_LINE_CODING.



Definition at line 108 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CDC_GETLINECODING#

#define USB_CDC_GETLINECODING
Value:
0x21

CDC class setup request GET_LINE_CODING.



Definition at line 109 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CDC_SETCTRLLINESTATE#

#define USB_CDC_SETCTRLLINESTATE
Value:
0x22

CDC class setup request SET_CONTROL_LINE_STATE.



Definition at line 110 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_MSD_BOTRESET#

#define USB_MSD_BOTRESET
Value:
0xFF

MSD class setup request Bulk only transfer reset.


Definition at line 111 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_MSD_GETMAXLUN#

#define USB_MSD_GETMAXLUN
Value:
0xFE

MSD class setup request Get Max LUN.



Definition at line 112 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_GET_CUR#

#define USB_AUDIO_GET_CUR
Value:
0x81

Audio class setup request GET_CUR.



Definition at line 113 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_GET_CUR#

#define USB_AUDIO_GET_CUR
Value:
0x81

Audio class setup request GET_CUR.



Definition at line 115 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_SET_CUR#

#define USB_AUDIO_SET_CUR
Value:
0x01

Audio class setup request SET_CUR.



Definition at line 114 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_SET_MIN#

#define USB_AUDIO_SET_MIN
Value:
0x02

Audio class setup request SET_MIN.



Definition at line 116 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_GET_MIN#

#define USB_AUDIO_GET_MIN
Value:
0x82

Audio class setup request GET_MIN.



Definition at line 117 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_SET_MAX#

#define USB_AUDIO_SET_MAX
Value:
0x03

Audio class setup request SET_MAX.



Definition at line 118 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_GET_MAX#

#define USB_AUDIO_GET_MAX
Value:
0x83

Audio class setup request GET_MAX.



Definition at line 119 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_SET_RES#

#define USB_AUDIO_SET_RES
Value:
0x04

Audio class setup request SET_RES.



Definition at line 120 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_GET_RES#

#define USB_AUDIO_GET_RES
Value:
0x84

Audio class setup request GET_RES.



Definition at line 121 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_SET_MEM#

#define USB_AUDIO_SET_MEM
Value:
0x05

Audio class setup request SET_MEM.



Definition at line 122 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_GET_MEM#

#define USB_AUDIO_GET_MEM
Value:
0x85

Audio class setup request GET_MEM.



Definition at line 123 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_AUDIO_GET_STAT#

#define USB_AUDIO_GET_STAT
Value:
0xFF

Audio class setup request GET_STAT.



Definition at line 124 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_DEVICE_DESCRIPTOR#

#define USB_DEVICE_DESCRIPTOR
Value:
1

DEVICE descriptor value.



Definition at line 127 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CONFIG_DESCRIPTOR#

#define USB_CONFIG_DESCRIPTOR
Value:
2

CONFIGURATION descriptor value.



Definition at line 128 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_STRING_DESCRIPTOR#

#define USB_STRING_DESCRIPTOR
Value:
3

STRING descriptor value.



Definition at line 129 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_MAX_STRING_DESCRIPTOR_CHARS#

#define USB_MAX_STRING_DESCRIPTOR_CHARS
Value:
126

Maximum STRING descriptor bString length.



Definition at line 130 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_INTERFACE_DESCRIPTOR#

#define USB_INTERFACE_DESCRIPTOR
Value:
4

INTERFACE descriptor value.



Definition at line 131 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_ENDPOINT_DESCRIPTOR#

#define USB_ENDPOINT_DESCRIPTOR
Value:
5

ENDPOINT descriptor value.



Definition at line 132 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_DEVICE_QUALIFIER_DESCRIPTOR#

#define USB_DEVICE_QUALIFIER_DESCRIPTOR
Value:
6

DEVICE_QUALIFIER descriptor value.



Definition at line 133 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_OTHER_SPEED_CONFIG_DESCRIPTOR#

#define USB_OTHER_SPEED_CONFIG_DESCRIPTOR
Value:
7

OTHER_SPEED_CONFIGURATION descriptor value.



Definition at line 134 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_INTERFACE_POWER_DESCRIPTOR#

#define USB_INTERFACE_POWER_DESCRIPTOR
Value:
8

INTERFACE_POWER descriptor value.



Definition at line 135 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_INTERFACE_ASSOCIATION_DESCRIPTOR#

#define USB_INTERFACE_ASSOCIATION_DESCRIPTOR
Value:
11

INTERFACE_ASSOCIATION descriptor value.



Definition at line 136 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HID_DESCRIPTOR#

#define USB_HID_DESCRIPTOR
Value:
0x21

HID descriptor value.



Definition at line 137 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SMARTCARD_DESCRIPTOR#

#define USB_SMARTCARD_DESCRIPTOR
Value:
0x21

Smartcard usb-ccid-specific Descriptor Type.



Definition at line 138 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HID_REPORT_DESCRIPTOR#

#define USB_HID_REPORT_DESCRIPTOR
Value:
0x22

HID REPORT descriptor value.



Definition at line 139 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CS_INTERFACE_DESCRIPTOR#

#define USB_CS_INTERFACE_DESCRIPTOR
Value:
0x24

Audio Class-specific interface Descriptor Type.



Definition at line 140 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CS_ENDPOINT_DESCRIPTOR#

#define USB_CS_ENDPOINT_DESCRIPTOR
Value:
0x25

Audio Class-specific endpoint Descriptor Type.



Definition at line 141 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HUB_DESCRIPTOR#

#define USB_HUB_DESCRIPTOR
Value:
0x29

HUB descriptor value.



Definition at line 142 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_HEADER_DESCRIPTOR#

#define USB_CA_HEADER_DESCRIPTOR
Value:
1

Audio Class-Specific AC Interface Header descriptor.


Definition at line 143 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_INPUT_TERMINAL_DESCRIPTOR#

#define USB_CA_INPUT_TERMINAL_DESCRIPTOR
Value:
2

Audio Class-Specific AC Interface Input Terminal desc.


Definition at line 144 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_OUTPUT_TERMINAL_DESCRIPTOR#

#define USB_CA_OUTPUT_TERMINAL_DESCRIPTOR
Value:
3

Audio Class-Specific AC Interface Output Terminal desc.


Definition at line 145 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_MIXER_UNIT_DESCRIPTOR#

#define USB_CA_MIXER_UNIT_DESCRIPTOR
Value:
4

Audio Class-Specific AC Interface Mixer descriptor.


Definition at line 146 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_SELECTOR_UNIT_DESCRIPTOR#

#define USB_CA_SELECTOR_UNIT_DESCRIPTOR
Value:
5

Audio Class-Specific AC Interface Selector desc.



Definition at line 147 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_FEATURE_UNIT_DESCRIPTOR#

#define USB_CA_FEATURE_UNIT_DESCRIPTOR
Value:
6

Audio Class-Specific AC Interface Feature desc.



Definition at line 148 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_PROCESSING_UNIT_DESCRIPTOR#

#define USB_CA_PROCESSING_UNIT_DESCRIPTOR
Value:
7

Audio Class-Specific AC Interface Processing desc.


Definition at line 149 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_EXTENSION_UNIT_DESCRIPTOR#

#define USB_CA_EXTENSION_UNIT_DESCRIPTOR
Value:
8

Audio Class-Specific AC Interface Extension desc.


Definition at line 150 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_EP_GENERAL_DESCRIPTOR#

#define USB_CA_EP_GENERAL_DESCRIPTOR
Value:
1

Audio Class-Specific general descriptor subtype code.


Definition at line 151 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_AS_GENERAL_DESCRIPTOR#

#define USB_CA_AS_GENERAL_DESCRIPTOR
Value:
1

Audio Class-Specific AS Interface General descriptor.


Definition at line 152 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_FORMAT_TYPE_DESCRIPTOR#

#define USB_CA_FORMAT_TYPE_DESCRIPTOR
Value:
2

Audio Class-Specific AS Interface Format Type desc.


Definition at line 153 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_DEVICE_DESCSIZE#

#define USB_DEVICE_DESCSIZE
Value:
18

Device descriptor size.



Definition at line 155 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CONFIG_DESCSIZE#

#define USB_CONFIG_DESCSIZE
Value:
9

Configuration descriptor size.



Definition at line 156 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_INTERFACE_DESCSIZE#

#define USB_INTERFACE_DESCSIZE
Value:
9

Interface descriptor size.



Definition at line 157 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_ENDPOINT_DESCSIZE#

#define USB_ENDPOINT_DESCSIZE
Value:
7

Endpoint descriptor size.



Definition at line 158 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_DEVICE_QUALIFIER_DESCSIZE#

#define USB_DEVICE_QUALIFIER_DESCSIZE
Value:
10

Device qualifier descriptor size.



Definition at line 159 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_OTHER_SPEED_CONFIG_DESCSIZE#

#define USB_OTHER_SPEED_CONFIG_DESCSIZE
Value:
9

Device other speed configuration descriptor size.


Definition at line 160 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_INTERFACE_ASSOCIATION_DESCSIZE#

#define USB_INTERFACE_ASSOCIATION_DESCSIZE
Value:
8

INTERFACE_ASSOCIATION descriptor size.



Definition at line 161 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_HID_DESCSIZE#

#define USB_HID_DESCSIZE
Value:
9

HID descriptor size.



Definition at line 162 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SMARTCARD_DESCSIZE#

#define USB_SMARTCARD_DESCSIZE
Value:
54

CCID descriptor size.



Definition at line 163 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CDC_HEADER_FND_DESCSIZE#

#define USB_CDC_HEADER_FND_DESCSIZE
Value:
5

CDC Header functional descriptor size.



Definition at line 164 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CDC_CALLMNG_FND_DESCSIZE#

#define USB_CDC_CALLMNG_FND_DESCSIZE
Value:
5

CDC Call Management functional descriptor size.



Definition at line 165 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CDC_ACM_FND_DESCSIZE#

#define USB_CDC_ACM_FND_DESCSIZE
Value:
4

CDC Abstract Control Management functional descriptor size.


Definition at line 166 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_INPUT_TERMINAL_DESCSIZE#

#define USB_CA_INPUT_TERMINAL_DESCSIZE
Value:
12

Audio Input Terminal descriptor size.



Definition at line 167 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_OUTPUT_TERMINAL_DESCSIZE#

#define USB_CA_OUTPUT_TERMINAL_DESCSIZE
Value:
9

Audio Output Terminal descriptor size.



Definition at line 168 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_EP_GENERAL_DESCSIZE#

#define USB_CA_EP_GENERAL_DESCSIZE
Value:
7

Audio Class-Specific general descriptor subtype size.


Definition at line 169 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_AS_GENERAL_DESCSIZE#

#define USB_CA_AS_GENERAL_DESCSIZE
Value:
7

Audio Class-Specific AS Interface General desc size.


Definition at line 170 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CA_STD_AS_ENDPOINT_DESCSZIE#

#define USB_CA_STD_AS_ENDPOINT_DESCSZIE
Value:
9

Audio-class standard audio stream descriptor size.


Definition at line 171 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_LS_CTRL_EP_MAXSIZE#

#define USB_LS_CTRL_EP_MAXSIZE
Value:
8

The max size of low speed control endpoints.



Definition at line 174 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_LS_INTR_EP_MAXSIZE#

#define USB_LS_INTR_EP_MAXSIZE
Value:
8

The max size of low speed interrupt endpoints.



Definition at line 175 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_FS_CTRL_EP_MAXSIZE#

#define USB_FS_CTRL_EP_MAXSIZE
Value:
64

The max size of full speed control endpoints.



Definition at line 176 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_FS_INTR_EP_MAXSIZE#

#define USB_FS_INTR_EP_MAXSIZE
Value:
64

The max size of full speed interrupt endpoints.



Definition at line 177 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_FS_BULK_EP_MAXSIZE#

#define USB_FS_BULK_EP_MAXSIZE
Value:
64

The max size of full speed bulk endpoints.



Definition at line 178 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_FS_ISOC_EP_MAXSIZE#

#define USB_FS_ISOC_EP_MAXSIZE
Value:
1023

The max size of full speed isochronous endpoints.


Definition at line 179 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPTYPE_CTRL#

#define USB_EPTYPE_CTRL
Value:
0

Endpoint type control.



Definition at line 180 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPTYPE_ISOC#

#define USB_EPTYPE_ISOC
Value:
1

Endpoint type isochron.



Definition at line 181 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPTYPE_BULK#

#define USB_EPTYPE_BULK
Value:
2

Endpoint type bulk.



Definition at line 182 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPTYPE_INTR#

#define USB_EPTYPE_INTR
Value:
3

Endpoint type interrupt.



Definition at line 183 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPSYNC_NO#

#define USB_EPSYNC_NO
Value:
(0 << 2)

Endpoint synchronization type, none.



Definition at line 184 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPSYNC_ASYNC#

#define USB_EPSYNC_ASYNC
Value:
(1 << 2)

Endpoint synchronization type, asynchronous.



Definition at line 185 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPSYNC_ADAPTIVE#

#define USB_EPSYNC_ADAPTIVE
Value:
(2 << 2)

Endpoint synchronization type, adaptive.



Definition at line 186 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPSYNC_SYNC#

#define USB_EPSYNC_SYNC
Value:
(3 << 2)

Endpoint synchronization type, synchronous.



Definition at line 187 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EP_DIR_IN#

#define USB_EP_DIR_IN
Value:
0x80

Endpoint direction mask.



Definition at line 188 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_SETUP_PKT_SIZE#

#define USB_SETUP_PKT_SIZE
Value:
8

Setup request packet size.



Definition at line 189 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_EPNUM_MASK#

#define USB_EPNUM_MASK
Value:
0x0F

Endpoint number mask.



Definition at line 190 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_LANGID_ENUS#

#define USB_LANGID_ENUS
Value:
0x0409

English-United States language id.



Definition at line 191 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_MAX_DEVICE_ADDRESS#

#define USB_MAX_DEVICE_ADDRESS
Value:
127

Maximum allowable device address.



Definition at line 192 of file platform/middleware/usb_gecko/inc/em_usb.h

CONFIG_DESC_BM_REMOTEWAKEUP#

#define CONFIG_DESC_BM_REMOTEWAKEUP
Value:
0x20

Configuration descriptor attribute macro.



Definition at line 194 of file platform/middleware/usb_gecko/inc/em_usb.h

CONFIG_DESC_BM_SELFPOWERED#

#define CONFIG_DESC_BM_SELFPOWERED
Value:
0x40

Configuration descriptor attribute macro.



Definition at line 195 of file platform/middleware/usb_gecko/inc/em_usb.h

CONFIG_DESC_BM_RESERVED_D7#

#define CONFIG_DESC_BM_RESERVED_D7
Value:
0x80

Configuration descriptor attribute macro.



Definition at line 196 of file platform/middleware/usb_gecko/inc/em_usb.h

CONFIG_DESC_BM_TRANSFERTYPE#

#define CONFIG_DESC_BM_TRANSFERTYPE
Value:
0x03

Configuration descriptor transfer type bitmask.



Definition at line 197 of file platform/middleware/usb_gecko/inc/em_usb.h

CONFIG_DESC_MAXPOWER_mA#

#define CONFIG_DESC_MAXPOWER_mA
Value:
(x)

Configuration descriptor power macro.



Definition at line 198 of file platform/middleware/usb_gecko/inc/em_usb.h

DEVICE_IS_SELFPOWERED#

#define DEVICE_IS_SELFPOWERED
Value:
0x0001

Standard request GET_STATUS bitmask.



Definition at line 200 of file platform/middleware/usb_gecko/inc/em_usb.h

REMOTE_WAKEUP_ENABLED#

#define REMOTE_WAKEUP_ENABLED
Value:
0x0002

Standard request GET_STATUS bitmask.



Definition at line 201 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_FEATURE_ENDPOINT_HALT#

#define USB_FEATURE_ENDPOINT_HALT
Value:
0

Standard request CLEAR/SET_FEATURE bitmask.



Definition at line 202 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_FEATURE_DEVICE_REMOTE_WAKEUP#

#define USB_FEATURE_DEVICE_REMOTE_WAKEUP
Value:
1

Standard request CLEAR/SET_FEATURE bitmask.



Definition at line 203 of file platform/middleware/usb_gecko/inc/em_usb.h

HUB_FEATURE_PORT_RESET#

#define HUB_FEATURE_PORT_RESET
Value:
4

HUB class request CLEAR/SET_PORT_FEATURE feature selector.


Definition at line 205 of file platform/middleware/usb_gecko/inc/em_usb.h

HUB_FEATURE_PORT_POWER#

#define HUB_FEATURE_PORT_POWER
Value:
8

HUB class request CLEAR/SET_PORT_FEATURE feature selector.


Definition at line 206 of file platform/middleware/usb_gecko/inc/em_usb.h

HUB_FEATURE_C_PORT_CONNECTION#

#define HUB_FEATURE_C_PORT_CONNECTION
Value:
16

HUB class request CLEAR/SET_PORT_FEATURE feature selector.


Definition at line 207 of file platform/middleware/usb_gecko/inc/em_usb.h

HUB_FEATURE_C_PORT_RESET#

#define HUB_FEATURE_C_PORT_RESET
Value:
20

HUB class request CLEAR/SET_PORT_FEATURE feature selector.


Definition at line 208 of file platform/middleware/usb_gecko/inc/em_usb.h

HUB_FEATURE_PORT_INDICATOR#

#define HUB_FEATURE_PORT_INDICATOR
Value:
22

HUB class request CLEAR/SET_PORT_FEATURE feature selector.


Definition at line 209 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_CDC#

#define USB_CLASS_CDC
Value:
2

CDC device/interface class code.



Definition at line 211 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_CDC_DATA#

#define USB_CLASS_CDC_DATA
Value:
0x0A

CDC Data interface class code.



Definition at line 212 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_CDC_ACM#

#define USB_CLASS_CDC_ACM
Value:
2

CDC Abstract Control Model interface subclass code.


Definition at line 213 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_CDC_HFN#

#define USB_CLASS_CDC_HFN
Value:
0

CDC class Header Functional Descriptor subtype.



Definition at line 214 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_CDC_CMNGFN#

#define USB_CLASS_CDC_CMNGFN
Value:
1

CDC class Call Management Functional Descriptor subtype.


Definition at line 215 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_CDC_ACMFN#

#define USB_CLASS_CDC_ACMFN
Value:
2

CDC class Abstract Control Management Functional Descriptor subtype.


Definition at line 216 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_CDC_UNIONFN#

#define USB_CLASS_CDC_UNIONFN
Value:
6

CDC class Union Functional Descriptor subtype.



Definition at line 217 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_HID#

#define USB_CLASS_HID
Value:
3

HID device/interface class code.



Definition at line 219 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_HID_KEYBOARD#

#define USB_CLASS_HID_KEYBOARD
Value:
1

HID keyboard interface protocol code.



Definition at line 220 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_HID_MOUSE#

#define USB_CLASS_HID_MOUSE
Value:
2

HID mouse interface protocol code.



Definition at line 221 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_HUB#

#define USB_CLASS_HUB
Value:
9

HUB device/interface class code.



Definition at line 223 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MSD#

#define USB_CLASS_MSD
Value:
8

MSD device/interface class code.



Definition at line 225 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MSD_BOT_TRANSPORT#

#define USB_CLASS_MSD_BOT_TRANSPORT
Value:
0x50

MSD Bulk Only Transport protocol.



Definition at line 226 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MSD_SCSI_CMDSET#

#define USB_CLASS_MSD_SCSI_CMDSET
Value:
6

MSD Subclass SCSI transparent command set.



Definition at line 227 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MSD_CSW_CMDPASSED#

#define USB_CLASS_MSD_CSW_CMDPASSED
Value:
0

MSD BOT Command status wrapper command passed code.


Definition at line 228 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MSD_CSW_CMDFAILED#

#define USB_CLASS_MSD_CSW_CMDFAILED
Value:
1

MSD BOT Command status wrapper command failed code.


Definition at line 229 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MSD_CSW_PHASEERROR#

#define USB_CLASS_MSD_CSW_PHASEERROR
Value:
2

MSD BOT Command status wrapper cmd phase error code.


Definition at line 230 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_AUDIO#

#define USB_CLASS_AUDIO
Value:
1

Audio interface class code.



Definition at line 232 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_AUDIO_CONTROL#

#define USB_CLASS_AUDIO_CONTROL
Value:
1

Audio subclass code for control interface.



Definition at line 233 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_AUDIO_STREAMING#

#define USB_CLASS_AUDIO_STREAMING
Value:
2

Audio subclass code for streaming interface.



Definition at line 234 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_AUDIO_MIDISTREAMING#

#define USB_CLASS_AUDIO_MIDISTREAMING
Value:
3

Audio subclass code for midi streaming interface.



Definition at line 235 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MISCELLANEOUS#

#define USB_CLASS_MISCELLANEOUS
Value:
0xEF

MISCELLANEOUS device class code.



Definition at line 238 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MISC_COMMON_SUBCLASS#

#define USB_CLASS_MISC_COMMON_SUBCLASS
Value:
2

MISCELLANEOUS Common sub class code.



Definition at line 239 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_CLASS_MISC_IAD_PROTOCOL#

#define USB_CLASS_MISC_IAD_PROTOCOL
Value:
1

MISCELLANEOUS Interface Association Descriptor protocol code.


Definition at line 240 of file platform/middleware/usb_gecko/inc/em_usb.h

PORT_FULL_SPEED#

#define PORT_FULL_SPEED
Value:
1

Full speed return value for USBH_GetPortSpeed().


Definition at line 242 of file platform/middleware/usb_gecko/inc/em_usb.h

PORT_LOW_SPEED#

#define PORT_LOW_SPEED
Value:
2

Low speed return value for USBH_GetPortSpeed().



Definition at line 243 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_DPLL_SRC_LFXO#

#define USB_DPLL_SRC_LFXO
Value:
1

Use LFXO as DPLL clock source.



Definition at line 245 of file platform/middleware/usb_gecko/inc/em_usb.h

USB_DPLL_SRC_HFXO#

#define USB_DPLL_SRC_HFXO
Value:
2

Use HFXO as DPLL clock source.



Definition at line 246 of file platform/middleware/usb_gecko/inc/em_usb.h

STATIC_CONST_STRING_DESC#

#define STATIC_CONST_STRING_DESC
Value:
SL_PACK_START(1) \
typedef struct \
{ \
uint8_t len; \
uint8_t type; \
char16_t name[1 + sizeof((char16_t[]){ __VA_ARGS__ }) / 2]; \
} SL_ATTRIBUTE_PACKED _##_name; \
SL_PACK_END() \
SL_ALIGN(4) \
SL_PACK_START(1) \
static const _##_name _name SL_ATTRIBUTE_ALIGN(4) = \
{ \
.len = sizeof(_##_name) - 2, \
.type = USB_STRING_DESCRIPTOR, \
.name = { __VA_ARGS__ }, \
.name[((sizeof(_##_name) - 2) / 2) - 1] = '\0' \
} \
SL_PACK_END()

Macro for creating USB compliant UTF-16LE UNICODE string descriptors.


Example: STATIC_CONST_STRING_DESC(iManufacturer, 'E','n','e','r','g','y',' ','M','i','c','r','o',' ','A','S'); Note

  • The size of the resulting struct will be two byte larger than a USB string descriptor. This is to accommodate a terminating null char for the string. The value assigned to the 'len' member does not take this into account and is therefore correct usb wise.


Definition at line 269 of file platform/middleware/usb_gecko/inc/em_usb.h

STATIC_CONST_STRING_DESC_LANGID#

#define STATIC_CONST_STRING_DESC_LANGID
Value:
SL_PACK_START(1) \
typedef struct \
{ \
uint8_t len; \
uint8_t type; \
uint8_t name[2]; \
} SL_ATTRIBUTE_PACKED _##_name; \
SL_PACK_END() \
SL_ALIGN(4) \
SL_PACK_START(1) \
static const _##_name _name SL_ATTRIBUTE_ALIGN(4) = \
{ \
.len = 4, \
.type = USB_STRING_DESCRIPTOR, \
.name = { y, x } \
} \
SL_PACK_END()

Macro for creating USB compliant language string descriptors.


Example: STATIC_CONST_STRING_DESC_LANGID(langID, 0x04, 0x09);


Definition at line 292 of file platform/middleware/usb_gecko/inc/em_usb.h

UBUF#

#define UBUF
Value:
(x, y)

Macro for creating WORD (4 byte) aligned uint8_t array with size which is a multiple of WORD size.


Example:
UBUF(rxBuffer, 37); => uint8_t rxBuffer[40];


Definition at line 315 of file platform/middleware/usb_gecko/inc/em_usb.h

STATIC_UBUF#

#define STATIC_UBUF
Value:
(x, y)

Macro for creating WORD (4 byte) aligned static uint8_t arrays with size which is a multiple of WORD size.


Example:
STATIC_UBUF(rxBuffer, 37); => static uint8_t rxBuffer[40];


Definition at line 321 of file platform/middleware/usb_gecko/inc/em_usb.h