samples: usb shell: add DT overlay to support snps,dwc2 on nucleo_f413zh

Add DT overlay to be able to support and test UDC DWC2 driver
(snps,dwc2) on nucleo_f413zh board. This disables STM32 shim
driver described and configured on the SoC and board level.

Obviously,it should work with other STM32F4 boards as well and we
could have a mechanism to apply it generically using snippets.

Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
This commit is contained in:
Johann Fischer 2023-09-14 23:28:32 +02:00 committed by Carles Cufí
parent cc2fdf2053
commit ad25668313

View file

@ -0,0 +1,26 @@
/*
* Copyright (c) 2023 Nordic Semiconductor ASA
*
* SPDX-License-Identifier: Apache-2.0
*/
/delete-node/ &zephyr_udc0;
/ {
soc {
dwc2_fsotg0: usb@50000000 {
compatible = "st,stm32f4-fsotg", "snps,dwc2";
reg = <0x50000000 0x40000>;
interrupts = <67 0>;
interrupt-names = "fsotg";
clocks = <&rcc STM32_CLOCK_BUS_AHB2 0x00000080>,
<&rcc STM32_SRC_PLL_Q NO_SEL>;
};
};
};
zephyr_udc0: &dwc2_fsotg0 {
pinctrl-0 = <&usb_otg_fs_dm_pa11 &usb_otg_fs_dp_pa12>;
pinctrl-names = "default";
status = "okay";
};