Re: [PATCH v4 1/2] dt-bindings: iio: adc: add support for PAC1944
From: Conor Dooley
Date: Fri May 15 2026 - 13:31:08 EST
On Fri, May 15, 2026 at 12:29:45PM +0300, marius.cristea@xxxxxxxxxxxxx wrote:
> +
> + microchip,accumulation-mode:
> + $ref: /schemas/types.yaml#/definitions/uint32
> + description:
> + The Hardware Accumulator may be used to accumulate VPOWER or VSENSE
> + values for any channel. By setting the accumulator for a channel
> + to accumulate the VPOWER values gives a measure of accumulated power
> + over a time period, which is equivalent to energy. Setting the
> + accumulator for a channel to accumulate VSENSE values gives a measure
> + of accumulated current, which is equivalent to charge. This allows the
> + accumulator to be used as a coulomb counter.
> + This functionality needs to be setup once and must not be changed
> + during the runtime, just in case the user wants to measure the charge
> + or the energy consumed from board power up till the user has control
> + or during a reboot of the system.
> + The Hardware Accumulator could be configured to accumulate VPOWER
> + or VSENSE
> + <0> - Accumulator accumulates VPOWER (default)
> + <1> - Accumulator accumulates VSENSE
> + enum: [0, 1]
> + default: 0
I think you should make this a string property, 0/1 don't mean anything
here, whereas "vpower" and "vsense" would be very clear.
Otherwise, this looks okay to me I think, other than
> + - if:
> + required:
> + - slow-gpios
> + then:
> + properties:
> + interrupts:
> + maxItems: 1
> + interrupt-names:
> + oneOf:
> + - items:
> + - const: alert2
this, which shouldn't need the "oneOf" at all.
Attachment:
signature.asc
Description: PGP signature