aboutsummaryrefslogtreecommitdiff
path: root/ports/stm32/mpconfigboard_common.h
diff options
context:
space:
mode:
authorDamien George2019-05-18 23:01:36 +1000
committerDamien George2019-05-30 21:11:04 +1000
commit0c29502ad995cfacc3b11f26a135707a06b8c27d (patch)
tree02f59087040aa360865af801ade5232340714abe /ports/stm32/mpconfigboard_common.h
parenta4f1d82757b8e95c21a095c99b7c3f04ded88104 (diff)
stm32/usb: Refactor CDC VCP code to enable N CDC interfaces.
The board config option MICROPY_HW_USB_ENABLE_CDC2 is now changed to MICROPY_HW_USB_CDC_NUM, and the latter should be defined to the maximum number of CDC interfaces to support (defaults to 1).
Diffstat (limited to 'ports/stm32/mpconfigboard_common.h')
-rw-r--r--ports/stm32/mpconfigboard_common.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/ports/stm32/mpconfigboard_common.h b/ports/stm32/mpconfigboard_common.h
index b9fa3833e..036e1f6cc 100644
--- a/ports/stm32/mpconfigboard_common.h
+++ b/ports/stm32/mpconfigboard_common.h
@@ -264,6 +264,10 @@
#define MICROPY_HW_MAX_CAN (1)
#endif
+// Configure maximum number of CDC VCP interfaces
+#ifndef MICROPY_HW_USB_CDC_NUM
+#define MICROPY_HW_USB_CDC_NUM (1)
+#endif
// Pin definition header file
#define MICROPY_PIN_DEFS_PORT_H "pin_defs_stm32.h"