Skip to content

Commit 994b835

Browse files
committed
boards: arduino: add pull-ups to all stm32 UART RX lines
Add pull-up configuration to the RX lines of all UART peripherals to avoid floating inputs when no connection is made to the UART pins. Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
1 parent 3a6bdf0 commit 994b835

File tree

4 files changed

+48
-2
lines changed

4 files changed

+48
-2
lines changed

boards/arduino/giga_r1/arduino_giga_r1_stm32h747xx_m7.dts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,20 +76,32 @@
7676
clock-frequency = <DT_FREQ_M(480)>;
7777
};
7878

79+
&usart1_rx_pb7 {
80+
bias-pull-up;
81+
};
82+
7983
&usart1 {
8084
status = "okay";
8185
pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pb7>;
8286
pinctrl-names = "default";
8387
current-speed = <115200>;
8488
};
8589

90+
&usart6_rx_pc7 {
91+
bias-pull-up;
92+
};
93+
8694
&usart6 {
8795
status = "disabled";
8896
pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pc7>;
8997
pinctrl-names = "default";
9098
current-speed = <115200>;
9199
};
92100

101+
&uart4_rx_pi9 {
102+
bias-pull-up;
103+
};
104+
93105
&uart4 {
94106
status = "disabled";
95107
pinctrl-0 = <&uart4_tx_ph13 &uart4_rx_pi9>;

boards/arduino/opta/arduino_opta-common.dtsi

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,16 @@
104104
};
105105
};
106106

107+
&usart6_rx_pg9 {
108+
bias-pull-up;
109+
};
110+
111+
&usart6 {
112+
pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>;
113+
pinctrl-names = "default";
114+
current-speed = <115200>;
115+
};
116+
107117
&adc1 {
108118
pinctrl-0 = <&adc1_inp0_pa0_c &adc1_inp6_pf12>;
109119
pinctrl-names = "default";

boards/arduino/portenta_h7/arduino_portenta_h7-common.dtsi

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,27 +49,43 @@
4949
};
5050

5151
/* UART0 in datasheet */
52+
&uart4_rx_pi9 {
53+
bias-pull-up;
54+
};
55+
5256
&uart4 {
5357
pinctrl-0 = <&uart4_tx_pa0 &uart4_rx_pi9>;
5458
pinctrl-names = "default";
5559
current-speed = <115200>;
5660
};
5761

5862
/* UART1 in datasheet */
63+
&usart1_rx_pa10 {
64+
bias-pull-up;
65+
};
66+
5967
&usart1 {
6068
pinctrl-0 = <&usart1_tx_pa9 &usart1_rx_pa10>;
6169
pinctrl-names = "default";
6270
current-speed = <115200>;
6371
};
6472

6573
/* UART2 in datasheet */
74+
&usart6_rx_pg9 {
75+
bias-pull-up;
76+
};
77+
6678
&usart6 {
6779
pinctrl-0 = <&usart6_tx_pg14 &usart6_rx_pg9>;
6880
pinctrl-names = "default";
6981
current-speed = <115200>;
7082
};
7183

7284
/* UART3 in datasheet */
85+
&uart8_rx_pj9 {
86+
bias-pull-up;
87+
};
88+
7389
&uart8 {
7490
pinctrl-0 = <&uart8_tx_pj8 &uart8_rx_pj9>;
7591
pinctrl-names = "default";

boards/arduino/uno_q/arduino_uno_q-common.dtsi

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,14 +98,22 @@ stm32_lp_tick_source: &lptim1 {
9898
status = "okay";
9999
};
100100

101+
&lpuart1_rx_pg8 {
102+
bias-pull-up;
103+
};
104+
101105
&lpuart1 {
102106
pinctrl-0 = <&lpuart1_tx_pg7 &lpuart1_rx_pg8
103-
&lpuart1_rts_pg6 &lpuart1_cts_pg5>;
107+
&lpuart1_rts_pg6 &lpuart1_cts_pg5>;
104108
pinctrl-names = "default";
105109
current-speed = <115200>;
106110
status = "okay";
107111
};
108112

113+
&usart1_rx_pb7 {
114+
bias-pull-up;
115+
};
116+
109117
&usart1 {
110118
status = "okay";
111119
pinctrl-0 = <&usart1_tx_pb6 &usart1_rx_pb7>;
@@ -245,4 +253,4 @@ zephyr_udc0: &usbotg_fs {
245253

246254
&gpiog {
247255
status = "okay";
248-
};
256+
};

0 commit comments

Comments
 (0)