Skip to content

Commit 4f82897

Browse files
committed
tests: drivers: pwm: gpio_loopback: enable for LM20 DK
Align PWM output for LED1 pin. Signed-off-by: Piotr Kosycarz <[email protected]>
1 parent d93516d commit 4f82897

File tree

4 files changed

+54
-22
lines changed

4 files changed

+54
-22
lines changed

boards/nordic/nrf54lm20apdk/nrf54lm20apdk_nrf54lm20a_cpuapp_0_2_0.overlay

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,3 +65,18 @@
6565
&gpio3 {
6666
gpio-reserved-ranges = <0 12>;
6767
};
68+
69+
&pinctrl {
70+
/omit-if-no-ref/ pwm20_default: pwm20_default {
71+
group1 {
72+
psels = <NRF_PSEL(PWM_OUT0, 1, 29)>;
73+
};
74+
};
75+
76+
/omit-if-no-ref/ pwm20_sleep: pwm20_sleep {
77+
group1 {
78+
psels = <NRF_PSEL(PWM_OUT0, 1, 29)>;
79+
low-power-enable;
80+
};
81+
};
82+
};

tests/drivers/pwm/gpio_loopback/boards/nrf54lm20apdk_nrf54lm20a_cpuapp.overlay

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -7,31 +7,10 @@
77
#include <zephyr/dt-bindings/pwm/pwm.h>
88
#include <zephyr/dt-bindings/gpio/nordic-nrf-gpio.h>
99

10-
&pinctrl {
11-
pwm20_alt: pwm20_alt {
12-
group1 {
13-
psels = <NRF_PSEL(PWM_OUT0, 1, 10)>;
14-
};
15-
};
16-
17-
pwm20_alt_sleep: pwm20_alt_sleep {
18-
group1 {
19-
psels = <NRF_PSEL(PWM_OUT0, 1, 10)>;
20-
low-power-enable;
21-
};
22-
};
23-
};
24-
25-
&pwm20 {
26-
pinctrl-0 = <&pwm20_alt>;
27-
pinctrl-1 = <&pwm20_alt_sleep>;
28-
pinctrl-names = "default", "sleep";
29-
};
30-
3110
/ {
3211
pwm_to_gpio_loopback: pwm_to_gpio_loopback {
3312
compatible = "test-pwm-to-gpio-loopback";
3413
pwms = <&pwm20 0 0 PWM_POLARITY_NORMAL>;
35-
gpios = <&gpio1 11 GPIO_ACTIVE_HIGH>;
14+
gpios = <&gpio1 19 GPIO_ACTIVE_HIGH>;
3615
};
3716
};
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
/*
2+
* Copyright (c) 2025 Nordic Semiconductor ASA
3+
*
4+
* SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
5+
*/
6+
7+
#include <zephyr/dt-bindings/pwm/pwm.h>
8+
#include <zephyr/dt-bindings/gpio/nordic-nrf-gpio.h>
9+
10+
&pinctrl {
11+
pwm20_alt: pwm20_alt {
12+
group1 {
13+
psels = <NRF_PSEL(PWM_OUT0, 1, 10)>;
14+
};
15+
};
16+
17+
pwm20_alt_sleep: pwm20_alt_sleep {
18+
group1 {
19+
psels = <NRF_PSEL(PWM_OUT0, 1, 10)>;
20+
low-power-enable;
21+
};
22+
};
23+
};
24+
25+
&pwm20 {
26+
pinctrl-0 = <&pwm20_alt>;
27+
pinctrl-1 = <&pwm20_alt_sleep>;
28+
pinctrl-names = "default", "sleep";
29+
};
30+
31+
/ {
32+
pwm_to_gpio_loopback: pwm_to_gpio_loopback {
33+
compatible = "test-pwm-to-gpio-loopback";
34+
pwms = <&pwm20 0 0 PWM_POLARITY_NORMAL>;
35+
gpios = <&gpio1 11 GPIO_ACTIVE_HIGH>;
36+
};
37+
};

tests/drivers/pwm/gpio_loopback/testcase.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ tests:
1717
- nrf54l15dk/nrf54l15/cpuapp
1818
- nrf54l20pdk/nrf54l20/cpuapp
1919
- nrf54lm20apdk/nrf54lm20a/cpuapp
20+
- [email protected]/nrf54lm20a/cpuapp
2021
- nrf7120pdk/nrf7120/cpuapp
2122
integration_platforms:
2223
- nrf54h20dk/nrf54h20/cpuapp

0 commit comments

Comments
 (0)