From a5759a6120d6e316f5dca19bffa35ae3d73118cf Mon Sep 17 00:00:00 2001 From: Declan Snyder Date: Thu, 6 Jul 2023 11:14:20 -0500 Subject: [PATCH] tests: regulator voltage: Support LPC55S36 board Support lpcxpresso55s36 on regulator voltage test using VREF Signed-off-by: Declan Snyder --- .../regulator/voltage/lpcxpresso55s36.overlay | 39 +++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 tests/drivers/regulator/voltage/lpcxpresso55s36.overlay diff --git a/tests/drivers/regulator/voltage/lpcxpresso55s36.overlay b/tests/drivers/regulator/voltage/lpcxpresso55s36.overlay new file mode 100644 index 000000000000000..a6414a494ca9a45 --- /dev/null +++ b/tests/drivers/regulator/voltage/lpcxpresso55s36.overlay @@ -0,0 +1,39 @@ +/* + * Copyright 2023 NXP + * SPDX-License-Identifier: Apache-2.0 + */ + +#include +#include + +/* To do this test, connect AN (J7-1) to VREF_OUT (J12-16) */ + +/ { + resources: resources { + compatible = "test-regulator-voltage"; + regulators = <&vref0>; + tolerance-microvolt = <1000000>; + set-read-delay-ms = <10>; + adc-avg-count = <10>; + io-channels = <&adc0 0>; + }; +}; + +&vref0 { + regulator-initial-mode = ; +}; + +&adc0 { + #address-cells = <1>; + #size-cells = <0>; + + channel@0 { + reg = <0>; + zephyr,gain = "ADC_GAIN_1"; + zephyr,reference = "ADC_REF_EXTERNAL0"; + zephyr,vref-mv = <1800>; + zephyr,acquisition-time = ; + zephyr,resolution = <12>; + zephyr,input-positive = ; + }; +};