summaryrefslogtreecommitdiff
path: root/src/device
diff options
context:
space:
mode:
authorhathach <[email protected]>2026-02-13 19:45:09 +0700
committerhathach <[email protected]>2026-02-13 19:45:09 +0700
commit8f14cf4bfa061690084c7c32b3f8b70301f5e0ff (patch)
tree130ffc9c47db1608406a37ea36aa3fc0b267f895 /src/device
parent35a90f213d75a4630adf576f50d2b5bc8f03456c (diff)
add CFG_TUD_VBUS_SENSE, that could allow to skip tud_configure() for fixed vbus sensing
simplify dwc2_stm32_gccfg_cfg() using guid value
Diffstat (limited to 'src/device')
-rw-r--r--src/device/usbd.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/device/usbd.h b/src/device/usbd.h
index 7d7604c81..eaf07b81e 100644
--- a/src/device/usbd.h
+++ b/src/device/usbd.h
@@ -44,6 +44,8 @@ typedef struct {
bool vbus_sensing; // Vbus pin is used for device connection detection, mandatory for tud_umount_cb()
} tud_configure_dwc2_t;
+#define TUD_CONFIGURE_DWC2_DEFAULT { .bm_double_buffered = 0, .vbus_sensing = CFG_TUD_VBUS_SENSE }
+
typedef union {
tud_configure_dwc2_t dwc2;
} tud_configure_param_t;