-
Notifications
You must be signed in to change notification settings - Fork 8.1k
STM32: add USB support for STM32WBA6 series #97539
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
STM32: add USB support for STM32WBA6 series #97539
Conversation
Add missing OTGHS_SEL macro to STM32WBA clock header. This macro applies only to certain SoCs of STM32WBA6x series. Signed-off-by: Mathieu Choplain <[email protected]>
Add missing nodes for USB feature to STM32WBA6x DTSI. (Note: only WBA65 DTSI exists today, but USB is available in other SoCs of the series - this should be reworked later) Signed-off-by: Mathieu Choplain <[email protected]>
Add support for USB on STM32WBA6x series, along with a tiny rework of how the st,stm32u5-otghs-phy is handled to make the code more generic by actually consuming DT information. Signed-off-by: Mathieu Choplain <[email protected]>
Configure and enable the USB controller on Nucleo-WBA65RI. Signed-off-by: Mathieu Choplain <[email protected]>
902f8a9
to
031a07d
Compare
|
#if defined(CONFIG_SOC_SERIES_STM32U5X) | ||
LL_APB3_GRP1_EnableClock(LL_APB3_GRP1_PERIPH_SYSCFG); | ||
#elif defined(CONFIG_SOC_SERIES_STM32WBAX) | ||
LL_APB7_GRP1_EnableClock(LL_APB7_GRP1_PERIPH_SYSCFG); | ||
#else |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case, use of __HAL_RCC_SYSCFG_CLK_ENABLE()
would enhance readability.
/* OTG HS clock source is 32 MHz HSE */ | ||
clock-reference = "SYSCFG_OTG_HS_PHY_CLK_32MHz"; | ||
status = "okay"; | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alos add - usbd
to .yaml file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Add USB support for STM32WBA6 series:
nucleo_wba65ri
boardTested that
samples/subsys/usb/cdc_acm
builds, runs and works as expected.(Also tested that it still works on
nucleo_u5a5zj_q
to ensure no regression)Fixes #96705