mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-08-18 16:05:05 +00:00
20 lines
650 B
YAML
20 lines
650 B
YAML
description: Battery voltage sense via an ADC channel behind a voltage divider
|
|
|
|
compatible: "battery-sense"
|
|
|
|
properties:
|
|
io-channels:
|
|
type: phandles
|
|
required: true
|
|
description: The ADC channel connected to the battery sense circuit, e.g. `<&adc1 3>`
|
|
reference-voltage-mv:
|
|
type: int
|
|
required: true
|
|
description: The ADC's effective full-scale reference voltage at the channel's configured attenuation, in mV.
|
|
multiplier:
|
|
type: int
|
|
default: 1000
|
|
description: |
|
|
Voltage divider correction factor, fixed-point with 3 decimals (1000 = 1.000, i.e. no division).
|
|
battery_mv = adc_mv * multiplier / 1000.
|