File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
usb/Adafruit_TinyUSB_core Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -76,7 +76,8 @@ int main( void )
7676
7777#ifdef NRF52840_XXAA
7878 USBDevice.addInterface ( (Adafruit_USBD_Interface&) Serial);
79- USBDevice.begin (USB_VID, USB_PID);
79+ USBDevice.setID (USB_VID, USB_PID);
80+ USBDevice.begin ();
8081 usb_init ();
8182#endif
8283
Original file line number Diff line number Diff line change @@ -173,11 +173,14 @@ bool Adafruit_USBD_Device::addInterface(Adafruit_USBD_Interface& itf)
173173 return true ;
174174}
175175
176- bool Adafruit_USBD_Device::begin (uint16_t vid, uint16_t pid)
176+ void Adafruit_USBD_Device::setID (uint16_t vid, uint16_t pid)
177177{
178178 _desc_device.idVendor = vid;
179179 _desc_device.idProduct = pid;
180+ }
180181
182+ bool Adafruit_USBD_Device::begin (void )
183+ {
181184 return true ;
182185}
183186
Original file line number Diff line number Diff line change @@ -51,7 +51,8 @@ class Adafruit_USBD_Device
5151
5252 bool addInterface (Adafruit_USBD_Interface& itf);
5353
54- bool begin (uint16_t vid, uint16_t pid);
54+ void setID (uint16_t vid, uint16_t pid);
55+ bool begin (void );
5556
5657 bool mounted (void ) { return tud_mounted (); }
5758 bool suspended (void ) { return tud_suspended (); }
You can’t perform that action at this time.
0 commit comments