Loading...
Searching...
No Matches
USB peripheral compile time configurations

Detailed Description

Modules

 USBUS CDC ACM compile time configurations
 
 USBUS compile time configurations
 

Macros

#define INTERNAL_PERIPHERAL_VID   (0x1209)
 Reserved for RIOT standard peripherals as per http://pid.codes/1209/7D00/.
 
#define INTERNAL_PERIPHERAL_PID   (0x7D00)
 Reserved for RIOT standard peripherals as per http://pid.codes/1209/7D00/.
 
#define CONFIG_USB_VID
 USB peripheral device vendor ID.
 
#define CONFIG_USB_PID
 USB peripheral device product ID.
 
#define CONFIG_USB_MANUF_STR   "RIOT-os.org"
 USB peripheral manufacturer string.
 
#define CONFIG_USB_PRODUCT_STR   RIOT_BOARD
 USB peripheral product string.
 
#define CONFIG_USB_CONFIGURATION_STR   "USB config"
 USB peripheral configuration string.
 
#define CONFIG_USB_SERIAL_STR   "RIOT-12345"
 USB peripheral serial string.
 
#define CONFIG_USB_PRODUCT_BCDVERSION   0x0100
 USB peripheral serial string length.
 
#define CONFIG_USB_SPEC_BCDVERSION   0x0200
 USB specification version.
 
#define CONFIG_USB_SELF_POWERED   (0)
 USB peripheral setting to indicate self powered devices.
 
#define CONFIG_USB_REM_WAKEUP   (0)
 USB peripheral setting to indicate remote wakeup capability.
 
#define CONFIG_USB_MAX_POWER   (100)
 USB device max power draw in mA, between 0 and 500mA.
 
#define CONFIG_USB_DEFAULT_LANGID   0x0409 /* EN-US */
 Default LANG ID reported to the host.
 

Macro Definition Documentation

◆ CONFIG_USB_CONFIGURATION_STR

#define CONFIG_USB_CONFIGURATION_STR   "USB config"

USB peripheral configuration string.

Definition at line 104 of file usb.h.

◆ CONFIG_USB_DEFAULT_LANGID

#define CONFIG_USB_DEFAULT_LANGID   0x0409 /* EN-US */

Default LANG ID reported to the host.

Definition at line 181 of file usb.h.

◆ CONFIG_USB_MANUF_STR

#define CONFIG_USB_MANUF_STR   "RIOT-os.org"

USB peripheral manufacturer string.

Definition at line 90 of file usb.h.

◆ CONFIG_USB_MAX_POWER

#define CONFIG_USB_MAX_POWER   (100)

USB device max power draw in mA, between 0 and 500mA.

Definition at line 174 of file usb.h.

◆ CONFIG_USB_PID

#define CONFIG_USB_PID

USB peripheral device product ID.

Note
You must provide your own VID/PID combination when manufacturing a device with USB.

Definition at line 83 of file usb.h.

◆ CONFIG_USB_PRODUCT_BCDVERSION

#define CONFIG_USB_PRODUCT_BCDVERSION   0x0100

USB peripheral serial string length.

Maximum value is 63. Sensible values are between 8 to 32 depending on the number of expected devices.

The length here is in bytes. The generated hex string is twice as many chars in length due to conversion from bytes to hex chars.

USB peripheral device version

This is the version number of this peripheral

Note
Not to be be confused with the USB version number

Definition at line 140 of file usb.h.

◆ CONFIG_USB_PRODUCT_STR

#define CONFIG_USB_PRODUCT_STR   RIOT_BOARD

USB peripheral product string.

Definition at line 97 of file usb.h.

◆ CONFIG_USB_REM_WAKEUP

#define CONFIG_USB_REM_WAKEUP   (0)

USB peripheral setting to indicate remote wakeup capability.

Definition at line 167 of file usb.h.

◆ CONFIG_USB_SELF_POWERED

#define CONFIG_USB_SELF_POWERED   (0)

USB peripheral setting to indicate self powered devices.

Definition at line 160 of file usb.h.

◆ CONFIG_USB_SERIAL_STR

#define CONFIG_USB_SERIAL_STR   "RIOT-12345"

USB peripheral serial string.

Compile-time value to override the serial string with. An LUID-based hex string is generated when this value is not used.

This string does not have to be a number, but it must be unique between devices with identical VID:PID combination.

Definition at line 117 of file usb.h.

◆ CONFIG_USB_SPEC_BCDVERSION

#define CONFIG_USB_SPEC_BCDVERSION   0x0200

USB specification version.

Definition at line 152 of file usb.h.

◆ CONFIG_USB_VID

#define CONFIG_USB_VID

USB peripheral device vendor ID.

Note
You must provide your own VID/PID combination when manufacturing a device with USB.

Definition at line 73 of file usb.h.

◆ INTERNAL_PERIPHERAL_PID

#define INTERNAL_PERIPHERAL_PID   (0x7D00)

Reserved for RIOT standard peripherals as per http://pid.codes/1209/7D00/.

Definition at line 45 of file usb.h.

◆ INTERNAL_PERIPHERAL_VID

#define INTERNAL_PERIPHERAL_VID   (0x1209)

Reserved for RIOT standard peripherals as per http://pid.codes/1209/7D00/.

Definition at line 41 of file usb.h.