[PATCH 1/3] dt-bindings: iio: pressure: Support Honeywell mpr sensors

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Honeywell mpr is a pressure sensor family. There are many different
types with different pressure ranges. The range needs to be set up in
the dt. Therefore new properties honeywell,pmin and honeywell,pmax are
introduced.

Add dt-bindings.

Signed-off-by: Andreas Klinger <ak@xxxxxxxxxxxxx>
---
 .../bindings/iio/pressure/honeywell,mpr.yaml  | 74 +++++++++++++++++++
 1 file changed, 74 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/iio/pressure/honeywell,mpr.yaml

diff --git a/Documentation/devicetree/bindings/iio/pressure/honeywell,mpr.yaml b/Documentation/devicetree/bindings/iio/pressure/honeywell,mpr.yaml
new file mode 100644
index 000000000000..d6fad6f841cf
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/pressure/honeywell,mpr.yaml
@@ -0,0 +1,74 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/pressure/honeywell,mpr.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Honeywell mpr pressure sensor
+
+maintainers:
+  - Andreas Klinger <ak@xxxxxxxxxxxxx>
+
+description: |
+  Honeywell pressure sensor of type mpr. This sensor has an I2C and SPI interface. Only the I2C
+  interface is implemented.
+
+  There are many subtypes with different pressure ranges available. Therefore the minimum and
+  maximum pressure values of the specific sensor needs to be specified in Pascal.
+
+  Specifications about the devices can be found at:
+    https://prod-edam.honeywell.com/content/dam/honeywell-edam/sps/siot/en-us/products/sensors/  \
+      pressure-sensors/board-mount-pressure-sensors/micropressure-mpr-series/documents/          \
+      sps-siot-mpr-series-datasheet-32332628-ciid-172626.pdf
+
+properties:
+  compatible:
+    const: honeywell,mpr
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  reset-gpios:
+    description:
+      Optional GPIO for resetting the device. If not present the device is not resetted.
+    maxItems: 1
+
+  honeywell,pmin:
+    description:
+      Minimum pressure value the sensor can measure in pascal.
+    $ref: /schemas/types.yaml#/definitions/uint32
+
+  honeywell,pmax:
+    description:
+      Maximum pressure value the sensor can measure in pascal.
+    $ref: /schemas/types.yaml#/definitions/uint32
+
+required:
+  - compatible
+  - reg
+  - honeywell,pmin
+  - honeywell,pmax
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    #include <dt-bindings/interrupt-controller/irq.h>
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        pressure@18 {
+            compatible = "honeywell,mpr";
+            reg = <0x18>;
+            reset-gpios = <&gpio3 19 GPIO_ACTIVE_HIGH>;
+            interrupt-parent = <&gpio3>;
+            interrupts = <21 IRQ_TYPE_EDGE_FALLING>;
+            honeywell,pmin = <0>;
+            honeywell,pmax = <172369>;
+        };
+    };
-- 
2.30.2



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux