From: Paul Kocialkowski <paulk@sys-base.io>
To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Cc: Jonathan Cameron <jic23@kernel.org>,
Lars-Peter Clausen <lars@metafoo.de>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Paul Kocialkowski <paulk@sys-base.io>
Subject: [PATCH 1/2] dt-bindings: iio: Add AMS TCS3430 color sensor bindings
Date: Sat, 30 Nov 2024 18:42:38 +0100 [thread overview]
Message-ID: <20241130174239.3298414-1-paulk@sys-base.io> (raw)
The AMS TCS3430 is a XYZ tristimulus color sensor.
It requires a VDD power supply and can optionally support an interrupt.
Signed-off-by: Paul Kocialkowski <paulk@sys-base.io>
---
.../bindings/iio/light/ams,tcs3430.yaml | 51 +++++++++++++++++++
1 file changed, 51 insertions(+)
create mode 100644 Documentation/devicetree/bindings/iio/light/ams,tcs3430.yaml
diff --git a/Documentation/devicetree/bindings/iio/light/ams,tcs3430.yaml b/Documentation/devicetree/bindings/iio/light/ams,tcs3430.yaml
new file mode 100644
index 000000000000..7ecdd86932e8
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/light/ams,tcs3430.yaml
@@ -0,0 +1,51 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/light/ams,tcs3430.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: AMS TCS3430 XYZ tristimulus color sensor
+
+maintainers:
+ - Paul Kocialkowski <paulk@sys-base.io>
+
+description: |
+ The device supports both interrupt-driven and interrupt-less operation,
+ depending on whether an interrupt property is present in the device-tree.
+
+properties:
+ compatible:
+ const: ams,tcs3430
+
+ reg:
+ maxItems: 1
+
+ interrupts:
+ maxItems: 1
+ description: The interrupt is detected on a low level.
+
+ vdd-supply: true
+
+additionalProperties: false
+
+required:
+ - compatible
+ - reg
+ - vdd-supply
+
+examples:
+ - |
+ #include <dt-bindings/interrupt-controller/irq.h>
+ i2c {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ light-sensor@39 {
+ compatible = "ams,tcs3430";
+ reg = <0x39>;
+ interrupt-parent = <&pio>;
+ interrupts = <0 8 IRQ_TYPE_EDGE_FALLING>;
+ vdd-supply = <®_vcc_io>;
+ };
+ };
+...
--
2.47.0
next reply other threads:[~2024-11-30 17:43 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-30 17:42 Paul Kocialkowski [this message]
2024-11-30 17:42 ` [PATCH 2/2] iio: light: Add support for the AMS TCS3430 color sensor Paul Kocialkowski
2024-12-01 3:15 ` kernel test robot
2024-12-01 11:58 ` Jonathan Cameron
2024-12-01 17:57 ` Paul Kocialkowski
2024-12-02 8:42 ` [PATCH 1/2] dt-bindings: iio: Add AMS TCS3430 color sensor bindings Krzysztof Kozlowski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241130174239.3298414-1-paulk@sys-base.io \
--to=paulk@sys-base.io \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=jic23@kernel.org \
--cc=krzk+dt@kernel.org \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=robh@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox