Browse Source
Support adc example for NXP frdm_mcxa153 Signed-off-by: Neil Chen <cheng.chen_1@nxp.com>pull/89078/head
1 changed files with 36 additions and 0 deletions
@ -0,0 +1,36 @@
@@ -0,0 +1,36 @@
|
||||
/* |
||||
* Copyright 2025 NXP |
||||
* |
||||
* SPDX-License-Identifier: Apache-2.0 |
||||
*/ |
||||
|
||||
#include <zephyr/dt-bindings/adc/adc.h> |
||||
#include <zephyr/dt-bindings/adc/mcux-lpadc.h> |
||||
|
||||
/ { |
||||
zephyr,user { |
||||
/* adjust channel number according to pinmux in board.dts */ |
||||
io-channels = <&lpadc0 0>; |
||||
}; |
||||
}; |
||||
|
||||
&lpadc0 { |
||||
#address-cells = <1>; |
||||
#size-cells = <0>; |
||||
|
||||
/* |
||||
* To use this sample: |
||||
* LPADC0 CH0A is set up in single ended mode |
||||
* - Connect LPADC0 CH0A signal to voltage between 0~3.3V (J4 pin 8) |
||||
*/ |
||||
|
||||
channel@0 { |
||||
reg = <0>; |
||||
zephyr,gain = "ADC_GAIN_1"; |
||||
zephyr,reference = "ADC_REF_EXTERNAL0"; |
||||
zephyr,vref-mv = <3300>; |
||||
zephyr,acquisition-time = <ADC_ACQ_TIME_DEFAULT>; |
||||
zephyr,resolution = <16>; |
||||
zephyr,input-positive = <MCUX_LPADC_CH0A>; |
||||
}; |
||||
}; |
Loading…
Reference in new issue