Re: [PATCH v2 1/2] dt-bindings: iio: max30100: Add pulse-width property
From: Jonathan Cameron
Date: Sun Oct 12 2025 - 13:06:52 EST
On Wed, 8 Oct 2025 08:47:36 +0530
Shrikant Raskar <raskar.shree97@xxxxxxxxx> wrote:
> The appropriate LED pulse width for the MAX30100 depends on
> board-specific optical and mechanical design (lens, enclosure,
> LED-to-sensor distance) and the trade-off between measurement
> resolution and power consumption. Encoding it in Device Tree
> documents these platform choices and ensures consistent behavior.
>
> Tested on: Raspberry Pi 3B + MAX30100 breakout board.
>
> Signed-off-by: Shrikant Raskar <raskar.shree97@xxxxxxxxx>
>
> Changes since v1:
> Add unit suffix.
> Drop redundant description.
>
> Link to v1:
> https://lore.kernel.org/all/20251004015623.7019-2-raskar.shree97@xxxxxxxxx/
> ---
> .../devicetree/bindings/iio/health/maxim,max30100.yaml | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/iio/health/maxim,max30100.yaml b/Documentation/devicetree/bindings/iio/health/maxim,max30100.yaml
> index 967778fb0ce8..5c651a0151cc 100644
> --- a/Documentation/devicetree/bindings/iio/health/maxim,max30100.yaml
> +++ b/Documentation/devicetree/bindings/iio/health/maxim,max30100.yaml
> @@ -27,6 +27,11 @@ properties:
> LED current whilst the engine is running. First indexed value is
> the configuration for the RED LED, and second value is for the IR LED.
>
> + maxim,pulse-width-us:
> + maxItems: 1
> + description: Pulse width in microseconds
I continued the discussion on v1 but just to make sure it is not
missed, add a bit more here briefly touching on factors that govern what
the right value is here.
Thanks,
Jonathan
> + enum: [200, 400, 800, 1600]
> +
> additionalProperties: false
>
> required:
> @@ -44,6 +49,7 @@ examples:
> compatible = "maxim,max30100";
> reg = <0x57>;
> maxim,led-current-microamp = <24000 50000>;
> + maxim,pulse-width-us = <1600>;
> interrupt-parent = <&gpio1>;
> interrupts = <16 2>;
> };