USB Libraries Help > USB Device Libraries > USB Device Layer Library > Configuring the Library > USB_DEVICE_INSTANCES_NUMBER Macro
MPLAB Harmony USB Stack
USB_DEVICE_INSTANCES_NUMBER Macro

Number of Device Layer Instances. 

This configuration macro defines the number of Device Layer instances in the application. In cases of microcontrollers that feature multiple USB peripherals, this allows the application to run multiple instances of the Device Layer. As an example, for a microcontroller containing two USB peripherals, setting USB_DEVICE_INSTANCES_NUMBER to 2 will cause 2 instances of the Device Layer to execute.

C
#define USB_DEVICE_INSTANCES_NUMBER 1
Remarks

Setting this value to more than the number of USB peripheral will result if unused RAM consumption.