Skip to content

Commit

Permalink
tests: uart_elementary: esp32: Add test configs
Browse files Browse the repository at this point in the history
Add test configuration for ESP32 devices.

Signed-off-by: Raffael Rostagno <[email protected]>
  • Loading branch information
Raffael Rostagno committed Nov 9, 2024
1 parent a882c4e commit 339219f
Show file tree
Hide file tree
Showing 8 changed files with 182 additions and 0 deletions.
1 change: 1 addition & 0 deletions tests/drivers/uart/uart_elementary/socs/esp32_procpu.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
CONFIG_DUAL_UART_TEST=y
42 changes: 42 additions & 0 deletions tests/drivers/uart/uart_elementary/socs/esp32_procpu.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
/*
* Copyright (c) 2024 Espressif Systems (Shanghai) Co., Ltd.
* SPDX-License-Identifier: Apache-2.0
*/

&pinctrl {
uart1_test: uart1_test {
group1 {
pinmux = <UART1_TX_GPIO2>;
input-enable;
};
group2 {
pinmux = <UART1_RX_GPIO3>;
output-enable;
};
};

uart2_test: uart2_test {
group1 {
pinmux = <UART2_TX_GPIO3>;
input-enable;
};
group2 {
pinmux = <UART2_RX_GPIO2>;
output-enable;
};
};
};

dut: &uart1 {
status = "okay";
pinctrl-0 = <&uart1_test>;
pinctrl-names = "default";
current-speed = <115200>;
};

dut_aux: &uart2 {
status = "okay";
pinctrl-0 = <&uart2_test>;
pinctrl-names = "default";
current-speed = <115200>;
};
24 changes: 24 additions & 0 deletions tests/drivers/uart/uart_elementary/socs/esp32c2.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/*
* Copyright (c) 2024 Espressif Systems (Shanghai) Co., Ltd.
* SPDX-License-Identifier: Apache-2.0
*/

&pinctrl {
uart1_test: uart1_test {
group1 {
pinmux = <UART1_TX_GPIO2>;
input-enable;
};
group2 {
pinmux = <UART1_RX_GPIO2>;
output-enable;
};
};
};

dut: &uart1 {
status = "okay";
pinctrl-0 = <&uart1_test>;
pinctrl-names = "default";
current-speed = <74880>;
};
24 changes: 24 additions & 0 deletions tests/drivers/uart/uart_elementary/socs/esp32c3.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/*
* Copyright (c) 2024 Espressif Systems (Shanghai) Co., Ltd.
* SPDX-License-Identifier: Apache-2.0
*/

&pinctrl {
uart1_test: uart1_test {
group1 {
pinmux = <UART1_TX_GPIO2>;
input-enable;
};
group2 {
pinmux = <UART1_RX_GPIO2>;
output-enable;
};
};
};

dut: &uart1 {
status = "okay";
pinctrl-0 = <&uart1_test>;
pinctrl-names = "default";
current-speed = <115200>;
};
24 changes: 24 additions & 0 deletions tests/drivers/uart/uart_elementary/socs/esp32c6.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/*
* Copyright (c) 2024 Espressif Systems (Shanghai) Co., Ltd.
* SPDX-License-Identifier: Apache-2.0
*/

&pinctrl {
uart1_test: uart1_test {
group1 {
pinmux = <UART1_TX_GPIO2>;
input-enable;
};
group2 {
pinmux = <UART1_RX_GPIO2>;
output-enable;
};
};
};

dut: &uart1 {
status = "okay";
pinctrl-0 = <&uart1_test>;
pinctrl-names = "default";
current-speed = <115200>;
};
24 changes: 24 additions & 0 deletions tests/drivers/uart/uart_elementary/socs/esp32s2.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/*
* Copyright (c) 2024 Espressif Systems (Shanghai) Co., Ltd.
* SPDX-License-Identifier: Apache-2.0
*/

&pinctrl {
uart1_test: uart1_test {
group1 {
pinmux = <UART1_TX_GPIO2>;
input-enable;
};
group2 {
pinmux = <UART1_RX_GPIO2>;
output-enable;
};
};
};

dut: &uart1 {
status = "okay";
pinctrl-0 = <&uart1_test>;
pinctrl-names = "default";
current-speed = <115200>;
};
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
CONFIG_DUAL_UART_TEST=y
42 changes: 42 additions & 0 deletions tests/drivers/uart/uart_elementary/socs/esp32s3_procpu.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
/*
* Copyright (c) 2024 Espressif Systems (Shanghai) Co., Ltd.
* SPDX-License-Identifier: Apache-2.0
*/

&pinctrl {
uart1_test: uart1_test {
group1 {
pinmux = <UART1_TX_GPIO2>;
input-enable;
};
group2 {
pinmux = <UART1_RX_GPIO3>;
output-enable;
};
};

uart2_test: uart2_test {
group1 {
pinmux = <UART2_TX_GPIO3>;
input-enable;
};
group2 {
pinmux = <UART2_RX_GPIO2>;
output-enable;
};
};
};

dut: &uart1 {
status = "okay";
pinctrl-0 = <&uart1_test>;
pinctrl-names = "default";
current-speed = <115200>;
};

dut_aux: &uart2 {
status = "okay";
pinctrl-0 = <&uart2_test>;
pinctrl-names = "default";
current-speed = <115200>;
};

0 comments on commit 339219f

Please sign in to comment.