Skip to content

Commit 6522596

Browse files
EmilioCBenkartben
authored andcommitted
tests: drivers: Add FRDM_MCXW72 Overlays
Add FRDM_MCXW72 Overlay for PWM, ADC, SPI testing Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
1 parent 30ee855 commit 6522596

File tree

6 files changed

+104
-0
lines changed

6 files changed

+104
-0
lines changed
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
/*
2+
* Copyright 2024 NXP
3+
* SPDX-License-Identifier: Apache-2.0
4+
*/
5+
6+
#include <zephyr/dt-bindings/adc/adc.h>
7+
#include <zephyr/dt-bindings/adc/mcux-lpadc.h>
8+
9+
/ {
10+
zephyr,user {
11+
io-channels = <&adc0 0>;
12+
};
13+
};
14+
15+
&adc0 {
16+
#address-cells = <1>;
17+
#size-cells = <0>;
18+
19+
channel@0 {
20+
reg = <0>;
21+
zephyr,gain = "ADC_GAIN_1";
22+
zephyr,reference = "ADC_REF_EXTERNAL1";
23+
zephyr,acquisition-time = <ADC_ACQ_TIME_DEFAULT>;
24+
zephyr,resolution = <12>;
25+
zephyr,vref-mv = <1800>;
26+
/* channel 2 signal 6A */
27+
zephyr,input-positive = <MCUX_LPADC_CH2A>;
28+
};
29+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
CONFIG_I2C_VIRTUAL=n
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
/*
2+
* Copyright 2025 NXP
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
/*
8+
* This is a loopback setup for the frdm_mcxw72
9+
* To test this sample, connect J2.1 <-> J1.5 and J2.2 <-> J2.9
10+
*/
11+
&lpi2c1 {
12+
status = "okay";
13+
eeprom0: eeprom@54 {
14+
compatible = "zephyr,i2c-target-eeprom";
15+
reg = <0x54>;
16+
size = <256>;
17+
};
18+
};
19+
20+
&lpi2c0 {
21+
status = "okay";
22+
pinctrl-0 = <&pinmux_lpi2c0>;
23+
pinctrl-names = "default";
24+
eeprom1: eeprom@56 {
25+
compatible = "zephyr,i2c-target-eeprom";
26+
reg = <0x56>;
27+
size = <256>;
28+
};
29+
};
30+
31+
&gpiob {
32+
status = "okay";
33+
};
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/*
2+
* Copyright 2024 NXP
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
/ {
8+
aliases {
9+
pwm-0 = &tpm0;
10+
};
11+
};
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#
2+
# Copyright 2025 NXP
3+
#
4+
# SPDX-License-Identifier: Apache-2.0
5+
#
6+
CONFIG_SPI_MCUX_LPSPI_DMA=y
7+
CONFIG_SPI_ASYNC=n
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
/*
2+
* Copyright 2024 NXP
3+
*
4+
* SPDX-License-Identifier: Apache-2.0
5+
*/
6+
7+
8+
/*
9+
* This is a loopback setup for the frdm_mcxw72
10+
* To test this sample, connect J2.6 <-> J2.7
11+
*/
12+
&lpspi1 {
13+
slow@0 {
14+
compatible = "test-spi-loopback-slow";
15+
reg = <0>;
16+
spi-max-frequency = <500000>;
17+
};
18+
fast@0 {
19+
compatible = "test-spi-loopback-fast";
20+
reg = <0>;
21+
spi-max-frequency = <16000000>;
22+
};
23+
};

0 commit comments

Comments
 (0)