boards: nucleo_f103rb: Configure serial console pins using dt
usart2 pin configuration is now done through device tree. Signed-off-by: Erwan Gouriou <erwan.gouriou@linaro.org>
This commit is contained in:
parent
346d2ab92f
commit
e4e60a4a0f
2 changed files with 2 additions and 4 deletions
|
@ -6,6 +6,7 @@
|
|||
|
||||
/dts-v1/;
|
||||
#include <st/f1/stm32f103Xb.dtsi>
|
||||
#include <st/f1/stm32f103r(8-b)tx-pinctrl.dtsi>
|
||||
#include "arduino_r3_connector.dtsi"
|
||||
|
||||
/ {
|
||||
|
@ -46,6 +47,7 @@
|
|||
};
|
||||
|
||||
&usart2 {
|
||||
pinctrl-0 = <&usart2_tx_pa2 &usart2_rx_pa3>;
|
||||
current-speed = <115200>;
|
||||
status = "okay";
|
||||
};
|
||||
|
|
|
@ -18,10 +18,6 @@ static const struct pin_config pinconf[] = {
|
|||
{STM32_PIN_PA9, STM32F1_PINMUX_FUNC_PA9_USART1_TX},
|
||||
{STM32_PIN_PA10, STM32F1_PINMUX_FUNC_PA10_USART1_RX},
|
||||
#endif
|
||||
#if DT_NODE_HAS_STATUS(DT_NODELABEL(usart2), okay) && CONFIG_SERIAL
|
||||
{STM32_PIN_PA2, STM32F1_PINMUX_FUNC_PA2_USART2_TX},
|
||||
{STM32_PIN_PA3, STM32F1_PINMUX_FUNC_PA3_USART2_RX},
|
||||
#endif
|
||||
#if DT_NODE_HAS_STATUS(DT_NODELABEL(usart3), okay) && CONFIG_SERIAL
|
||||
{STM32_PIN_PB10, STM32F1_PINMUX_FUNC_PB10_USART3_TX},
|
||||
{STM32_PIN_PB11, STM32F1_PINMUX_FUNC_PB11_USART3_RX},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue