0001 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
0002 %YAML 1.2
0003 ---
0004 $id: http://devicetree.org/schemas/iio/light/stk33xx.yaml#
0005 $schema: http://devicetree.org/meta-schemas/core.yaml#
0006
0007 title: |
0008 Sensortek STK33xx I2C Ambient Light and Proximity sensor
0009
0010 maintainers:
0011 - Jonathan Cameron <jic23@kernel.org>
0012
0013 description: |
0014 Ambient light and proximity sensor over an i2c interface.
0015
0016 allOf:
0017 - $ref: ../common.yaml#
0018
0019 properties:
0020 compatible:
0021 enum:
0022 - sensortek,stk3310
0023 - sensortek,stk3311
0024 - sensortek,stk3335
0025
0026 reg:
0027 maxItems: 1
0028
0029 interrupts:
0030 maxItems: 1
0031
0032 proximity-near-level: true
0033
0034 required:
0035 - compatible
0036 - reg
0037
0038 additionalProperties: false
0039
0040 examples:
0041 - |
0042 #include <dt-bindings/interrupt-controller/irq.h>
0043
0044 i2c {
0045
0046 #address-cells = <1>;
0047 #size-cells = <0>;
0048
0049 stk3310@48 {
0050 compatible = "sensortek,stk3310";
0051 reg = <0x48>;
0052 proximity-near-level = <25>;
0053 interrupt-parent = <&gpio1>;
0054 interrupts = <5 IRQ_TYPE_LEVEL_LOW>;
0055 };
0056 };
0057 ...