File tree 3 files changed +9
-0
lines changed
3 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -136,6 +136,7 @@ SHARED_SRC_C += \
136
136
shared/tinyusb/mp_cdc_common.c \
137
137
shared/tinyusb/mp_usbd.c \
138
138
shared/tinyusb/mp_usbd_descriptor.c \
139
+ shared/tinyusb/mp_usbd_runtime.c \
139
140
140
141
ASF4_SRC_C += $(addprefix lib/asf4/$(MCU_SERIES_LOWER ) /,\
141
142
hal/src/hal_atomic.c \
Original file line number Diff line number Diff line change @@ -93,6 +93,9 @@ void samd_main(void) {
93
93
pwm_deinit_all ();
94
94
#endif
95
95
soft_timer_deinit ();
96
+ #if MICROPY_HW_ENABLE_USB_RUNTIME_DEVICE
97
+ mp_usbd_deinit ();
98
+ #endif
96
99
gc_sweep_all ();
97
100
#if MICROPY_PY_MACHINE_I2C || MICROPY_PY_MACHINE_SPI || MICROPY_PY_MACHINE_UART
98
101
sercom_deinit_all ();
Original file line number Diff line number Diff line change 63
63
#ifndef MICROPY_HW_USB_DESC_STR_MAX
64
64
#define MICROPY_HW_USB_DESC_STR_MAX (32)
65
65
#endif
66
+ // Support machine.USBDevice
67
+ #ifndef MICROPY_HW_ENABLE_USB_RUNTIME_DEVICE
68
+ #define MICROPY_HW_ENABLE_USB_RUNTIME_DEVICE (1)
66
69
#endif
67
70
71
+ #endif // MICROPY_HW_ENABLE_USBDEV
72
+
68
73
#define MICROPY_PY_SYS_PLATFORM "samd"
69
74
70
75
// Extended modules
You can’t perform that action at this time.
0 commit comments