File tree Expand file tree Collapse file tree 3 files changed +13
-18
lines changed Expand file tree Collapse file tree 3 files changed +13
-18
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ arduino_due_x_dbg.upload.wait_for_upload_port=false
1212arduino_due_x_dbg.upload.native_usb=false
1313arduino_due_x_dbg.build.mcu=cortex-m3
1414arduino_due_x_dbg.build.f_cpu=84000000L
15+ arduino_due_x_dbg.build.usb_manufacturer="Arduino LLC"
1516arduino_due_x_dbg.build.usb_product="Arduino Due"
1617arduino_due_x_dbg.build.board=SAM_DUE
1718arduino_due_x_dbg.build.core=arduino
@@ -35,6 +36,7 @@ arduino_due_x.upload.wait_for_upload_port=true
3536arduino_due_x.upload.native_usb=true
3637arduino_due_x.build.mcu=cortex-m3
3738arduino_due_x.build.f_cpu=84000000L
39+ arduino_due_x.build.usb_manufacturer="Arduino LLC"
3840arduino_due_x.build.usb_product="Arduino Due"
3941arduino_due_x.build.board=SAM_DUE
4042arduino_due_x.build.core=arduino
Original file line number Diff line number Diff line change @@ -209,10 +209,14 @@ extern const PinDescription g_APinDescription[] ;
209209#include "watchdog.h"
210210
211211// USB Device
212- #define USB_VID 0x2341 // arduino LLC vid
213- #define USB_PID_LEONARDO 0x0034
214- #define USB_PID_MICRO 0x0035
215- #define USB_PID_DUE 0x003E
212+ #ifndef USB_VID
213+ #define USB_VID 0x2341 // arduino LLC vid
214+ #endif
215+
216+ #ifndef USB_PID
217+ #define USB_PID 0x003E // arduino Due pid
218+ #endif
219+
216220#include "USB/USBDesc.h"
217221#include "USB/USBCore.h"
218222#include "USB/USBAPI.h"
Original file line number Diff line number Diff line change @@ -66,27 +66,16 @@ const uint16_t STRING_LANGUAGE[2] = {
6666};
6767
6868#ifndef USB_PRODUCT
69- // Use a hardcoded product name if none is provided
70- #if USB_PID == USB_PID_DUE
7169#define USB_PRODUCT " Arduino Due"
72- #else
73- #define USB_PRODUCT " USB IO Board"
74- #endif
7570#endif
7671
7772const uint8_t STRING_PRODUCT[] = USB_PRODUCT;
7873
79- #if USB_VID == 0x2341
80- # if defined(USB_MANUFACTURER)
81- # undef USB_MANUFACTURER
82- # endif
83- # define USB_MANUFACTURER " Arduino LLC"
84- #elif !defined(USB_MANUFACTURER)
85- // Fall through to unknown if no manufacturer name was provided in a macro
86- # define USB_MANUFACTURER " Unknown"
74+ #ifndef USB_MANUFACTURER
75+ #define USB_MANUFACTURER " Arduino LLC"
8776#endif
8877
89- const uint8_t STRING_MANUFACTURER[12 ] = USB_MANUFACTURER;
78+ const uint8_t STRING_MANUFACTURER[] = USB_MANUFACTURER;
9079
9180#ifdef CDC_ENABLED
9281#define DEVICE_CLASS 0x02
You can’t perform that action at this time.
0 commit comments