boards: thingy53: define ADC channel for battery
Define the ADC channel for battery monitoring so that `voltage-divider` driver works. Signed-off-by: Jordan Yates <jordan@embeint.com>
This commit is contained in:
parent
fdd6627df9
commit
ed1c78ec15
1 changed files with 13 additions and 1 deletions
|
@ -88,7 +88,7 @@
|
||||||
regulator-boot-on;
|
regulator-boot-on;
|
||||||
};
|
};
|
||||||
|
|
||||||
vbatt {
|
vbatt: vbatt {
|
||||||
compatible = "voltage-divider";
|
compatible = "voltage-divider";
|
||||||
io-channels = <&adc 2>;
|
io-channels = <&adc 2>;
|
||||||
output-ohms = <180000>;
|
output-ohms = <180000>;
|
||||||
|
@ -155,7 +155,19 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
&adc {
|
&adc {
|
||||||
|
#address-cells = <1>;
|
||||||
|
#size-cells = <0>;
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
|
||||||
|
channel@2 {
|
||||||
|
reg = <2>;
|
||||||
|
zephyr,gain = "ADC_GAIN_1";
|
||||||
|
zephyr,reference = "ADC_REF_INTERNAL";
|
||||||
|
zephyr,vref-mv = <600>;
|
||||||
|
zephyr,acquisition-time = <ADC_ACQ_TIME_DEFAULT>;
|
||||||
|
zephyr,resolution = <12>;
|
||||||
|
zephyr,input-positive = <NRF_SAADC_AIN2>;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
&gpiote {
|
&gpiote {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue