aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h
diff options
context:
space:
mode:
Diffstat (limited to 'os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h')
-rw-r--r--os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h b/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h
index 7c2019685..8b8e39b7f 100644
--- a/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h
+++ b/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h
@@ -241,6 +241,16 @@
#define STM32_USBCLK STM32_OTGFSCLK
#elif defined(STM32L4XX)
#define STM32_USBCLK STM32_48CLK
+#elif defined(STM32H7XX)
+/* Defines directly STM32_USBCLK.*/
+#define rccEnableOTG_FS rccEnableUSB1_OTG_HS
+#define rccDisableOTG_FS rccDisableUSB1_OTG_HS
+#define rccResetOTG_FS rccResetUSB1_OTG_HS
+#define rccEnableOTG_HS rccEnableUSB2_OTG_HS
+#define rccDisableOTG_HS rccDisableUSB2_OTG_HS
+#define rccResetOTG_HS rccResetUSB2_OTG_HS
+#define rccEnableOTG_HSULPI rccEnableUSB2_HSULPI
+#define rccDisableOTG_HSULPI rccDisableUSB2_HSULPI
#else
#error "unsupported STM32 platform for OTG functionality"
#endif