-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathusb_desc.h.diff
More file actions
82 lines (78 loc) · 2.75 KB
/
usb_desc.h.diff
File metadata and controls
82 lines (78 loc) · 2.75 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
--- packages/framework-arduinoteensy/cores/teensy3/usb_desc.h 2023-12-11 17:01:49.298069192 +0800
+++ packages/framework-arduinoteensy/cores/teensy3/usb_desc.h 2023-12-11 17:17:28.601424569 +0800
@@ -116,7 +116,7 @@
*/
-#if defined(USB_SERIAL)
+#if defined(USB_SERIAL) && FALSE
#define VENDOR_ID 0x16C0
#define PRODUCT_ID 0x0483
#define DEVICE_CLASS 2 // 2 = Communication Class
@@ -986,6 +986,70 @@
#define ENDPOINT13_CONFIG (ENDPOINT_RECEIVE_ISOCHRONOUS|ENDPOINT_TRANSMIT_ISOCHRONOUS)
#define ENDPOINT14_CONFIG ENDPOINT_TRANSMIT_ISOCHRONOUS
#define ENDPOINT15_CONFIG ENDPOINT_TRANSMIT_ONLY
+#elif defined(USB_RAWHID_TRIPLESERIAL)
+ #define VENDOR_ID 0x16C0
+ #define PRODUCT_ID 0x048C
+ #define RAWHID_USAGE_PAGE 0xFFAB // recommended: 0xFF00 to 0xFFFF
+ #define RAWHID_USAGE 0x0200 // recommended: 0x0100 to 0xFFFF
+ #define MANUFACTURER_NAME {'T','e','e','n','s','y','d','u','i','n','o'}
+ #define MANUFACTURER_NAME_LEN 11
+ #define PRODUCT_NAME {'C','M','S','I','S','-','D','A','P'}
+ #define PRODUCT_NAME_LEN 9
+ #define EP0_SIZE 64
+ #define NUM_ENDPOINTS 12
+ #define NUM_USB_BUFFERS 32
+ #define NUM_INTERFACE 7
+
+ #define CDC_IAD_DESCRIPTOR 1 // Serial
+ #define CDC_STATUS_INTERFACE 0
+ #define CDC_DATA_INTERFACE 1
+ #define CDC_ACM_ENDPOINT 2
+ #define CDC_RX_ENDPOINT 3
+ #define CDC_TX_ENDPOINT 4
+ #define CDC_ACM_SIZE 16
+ #define CDC_RX_SIZE 64
+ #define CDC_TX_SIZE 64
+
+ #define CDC2_STATUS_INTERFACE 2 // SerialUSB1
+ #define CDC2_DATA_INTERFACE 3
+ #define CDC2_ACM_ENDPOINT 5
+ #define CDC2_RX_ENDPOINT 6
+ #define CDC2_TX_ENDPOINT 7
+ #define CDC2_ACM_SIZE 16
+ #define CDC2_RX_SIZE 64
+ #define CDC2_TX_SIZE 64
+
+ #define CDC3_STATUS_INTERFACE 4 // SerialUSB2
+ #define CDC3_DATA_INTERFACE 5
+ #define CDC3_ACM_ENDPOINT 8
+ #define CDC3_RX_ENDPOINT 9
+ #define CDC3_TX_ENDPOINT 10
+ #define CDC3_ACM_SIZE 16
+ #define CDC3_RX_SIZE 64
+ #define CDC3_TX_SIZE 64
+
+ #define RAWHID_INTERFACE 6 // RawHID
+ #define RAWHID_TX_ENDPOINT 11
+ #define RAWHID_TX_SIZE 64
+ #define RAWHID_TX_INTERVAL 1
+ #define RAWHID_RX_ENDPOINT 12
+ #define RAWHID_RX_SIZE 64
+ #define RAWHID_RX_INTERVAL 1
+
+ #define ENDPOINT2_CONFIG ENDPOINT_TRANSMIT_ONLY
+ #define ENDPOINT3_CONFIG ENDPOINT_RECEIVE_ONLY
+ #define ENDPOINT4_CONFIG ENDPOINT_TRANSMIT_ONLY
+
+ #define ENDPOINT5_CONFIG ENDPOINT_TRANSMIT_ONLY
+ #define ENDPOINT6_CONFIG ENDPOINT_RECEIVE_ONLY
+ #define ENDPOINT7_CONFIG ENDPOINT_TRANSMIT_ONLY
+
+ #define ENDPOINT8_CONFIG ENDPOINT_TRANSMIT_ONLY
+ #define ENDPOINT9_CONFIG ENDPOINT_RECEIVE_ONLY
+ #define ENDPOINT10_CONFIG ENDPOINT_TRANSMIT_ONLY
+
+ #define ENDPOINT11_CONFIG ENDPOINT_TRANSMIT_ONLY
+ #define ENDPOINT12_CONFIG ENDPOINT_RECEIVE_ONLY
#endif