Skip to content

Commit

Permalink
tests: boards: nrf: qdec: Add common configuration for nrf54l
Browse files Browse the repository at this point in the history
Add common overlay for nrf54l15pdk targets.

Signed-off-by: Krzysztof Chruściński <[email protected]>
  • Loading branch information
nordic-krch authored and dleach02 committed Oct 15, 2024
1 parent b773306 commit 7fc7361
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 76 deletions.
39 changes: 1 addition & 38 deletions tests/boards/nrf/qdec/boards/nrf54l15dk_nrf54l15_cpuapp.overlay
Original file line number Diff line number Diff line change
Expand Up @@ -3,41 +3,4 @@
* SPDX-License-Identifier: Apache-2.0
*/

/ {
aliases {
qdec0 = &qdec20;
qenca = &phase_a;
qencb = &phase_b;
};

encoder-emulate {
compatible = "gpio-leds";
phase_a: phase_a {
gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
};
phase_b: phase_b {
gpios = <&gpio1 11 GPIO_ACTIVE_HIGH>;
};
};
};

&pinctrl {
qdec_pinctrl: qdec_pinctrl {
group1 {
psels = <NRF_PSEL(QDEC_A, 1, 8)>,
<NRF_PSEL(QDEC_B, 1, 10)>;
};
};
};

&gpio1 {
status = "okay";
};

&qdec20 {
status = "okay";
pinctrl-0 = <&qdec_pinctrl>;
pinctrl-names = "default";
steps = <127>;
led-pre = <500>;
};
#include "nrf54l15pdk_nrf54l15_common.dtsi"
39 changes: 1 addition & 38 deletions tests/boards/nrf/qdec/boards/nrf54l15dk_nrf54l15_cpuflpr.overlay
Original file line number Diff line number Diff line change
Expand Up @@ -3,41 +3,4 @@
* SPDX-License-Identifier: Apache-2.0
*/

/ {
aliases {
qdec0 = &qdec20;
qenca = &phase_a;
qencb = &phase_b;
};

encoder-emulate {
compatible = "gpio-leds";
phase_a: phase_a {
gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
};
phase_b: phase_b {
gpios = <&gpio1 11 GPIO_ACTIVE_HIGH>;
};
};
};

&pinctrl {
qdec_pinctrl: qdec_pinctrl {
group1 {
psels = <NRF_PSEL(QDEC_A, 1, 8)>,
<NRF_PSEL(QDEC_B, 1, 10)>;
};
};
};

&gpio1 {
status = "okay";
};

&qdec20 {
status = "okay";
pinctrl-0 = <&qdec_pinctrl>;
pinctrl-names = "default";
steps = <127>;
led-pre = <500>;
};
#include "nrf54l15pdk_nrf54l15_common.dtsi"
43 changes: 43 additions & 0 deletions tests/boards/nrf/qdec/boards/nrf54l15pdk_nrf54l15_common.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
/*
* Copyright 2024 Nordic Semiconductor ASA
* SPDX-License-Identifier: Apache-2.0
*/

/ {
aliases {
qdec0 = &qdec20;
qenca = &phase_a;
qencb = &phase_b;
};

encoder-emulate {
compatible = "gpio-leds";
phase_a: phase_a {
gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
};
phase_b: phase_b {
gpios = <&gpio1 11 GPIO_ACTIVE_HIGH>;
};
};
};

&pinctrl {
qdec_pinctrl: qdec_pinctrl {
group1 {
psels = <NRF_PSEL(QDEC_A, 1, 8)>,
<NRF_PSEL(QDEC_B, 1, 10)>;
};
};
};

&gpio1 {
status = "okay";
};

&qdec20 {
status = "okay";
pinctrl-0 = <&qdec_pinctrl>;
pinctrl-names = "default";
steps = <127>;
led-pre = <500>;
};

0 comments on commit 7fc7361

Please sign in to comment.