Skip to content

Commit 765b3aa

Browse files
NeilChen93kartben
authored andcommitted
tests: drivers/adc/adc_api: Support adc api test for NXP frdm_mcxa156
Support adc api test for NXP frdm_mcxa156 Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>
1 parent 3f389d5 commit 765b3aa

File tree

2 files changed

+29
-0
lines changed

2 files changed

+29
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
CONFIG_LPADC_DO_OFFSET_CALIBRATION=y
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
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 = <&lpadc0 0>;
12+
};
13+
};
14+
15+
&lpadc0 {
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_EXTERNAL0";
23+
zephyr,vref-mv = <3300>;
24+
zephyr,acquisition-time = <ADC_ACQ_TIME_DEFAULT>;
25+
zephyr,resolution = <16>;
26+
zephyr,input-positive = <MCUX_LPADC_CH0A>;
27+
};
28+
};

0 commit comments

Comments
 (0)