Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp535529rwd; Tue, 16 May 2023 04:47:10 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6E9b6s3lQIrW/SnChTj4V4XVQjmUxEvQ622Ayv7deIHsMYZyq9bm2hSEgnW0UlwPaOM+XX X-Received: by 2002:a17:90a:ee88:b0:246:f8a8:af02 with SMTP id i8-20020a17090aee8800b00246f8a8af02mr35634713pjz.5.1684237629873; Tue, 16 May 2023 04:47:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684237629; cv=none; d=google.com; s=arc-20160816; b=Gh2O7K77e+vCGSnVjvzZja/aRFNMsBMp8fr3Jx/E4ZMqOav3+Nt8pmIGvgQFEdVqmF Dmizy47Ez/8TaG10E66BGKXCNujd73RN7Empw+2YvKLW+bacgluPlXsp2szMccyFsf5i 0Z8Hw/BI8mpPqlzvNSehPYGcMXTRminWLItKSaI61bx+wUTfAu4cgwkacF1JgJLpJr9y Or8gXiT+LCluC3wQ+CZp8Ny4x4bDwHowWCBcw4C+xvuosxhnzHS/DYn6EEnNqQsrNuxQ Lmj0TMydXqjPbqYD81RC/fooIW6aE7Mrt5kH2bqCjjs1lg+EeHxY+JOgY6WWk1ygLmr3 msfw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:ui-outboundreport:in-reply-to :content-disposition:mime-version:message-id:subject:cc:to:from:date; bh=K248OZDTxEB14utU/4/gBca7qH3d8OHgJzuJp1H/95U=; b=u/Oj0cho67WAQIFJBLf5CbsrFCfo8/l+EVBtJHqkQw8uo7faXPNX6JkGUys0/YdOXl SS/44yV6e8Wbn354zAM+yC4+Y9iPcU6JBXVbmbb86F7kRQy4ANhlmA2oAbBX3WrqcB9Z bq2oEQn3pnkJD4XBnSeagZXcVAuOhjbYSVBxILhnpuSTEbqznibPc9Cwnj2CFAqgjc64 udYyqgkhGig/gQgiIR4cZLwda6nhRMQK/bwcXp0/mMG06aq+AZOgw9f+BIsSbLak5Fal gaDWI76EosoXfSrcMa0vMgvVTNX3gKjsvRUaiDky98YN3QnxsKMy0LyIuRhUBV6mx1MI i+cQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id mn23-20020a17090b189700b00250d2e5df8esi1569334pjb.45.2023.05.16.04.46.57; Tue, 16 May 2023 04:47:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232957AbjEPLcd (ORCPT + 99 others); Tue, 16 May 2023 07:32:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59084 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232952AbjEPLcc (ORCPT ); Tue, 16 May 2023 07:32:32 -0400 Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 63BBD18E; Tue, 16 May 2023 04:32:31 -0700 (PDT) Received: from localhost ([31.220.116.19]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.167]) with ESMTPSA (Nemesis) id 1M3D3N-1q1u790aZ3-003hzl; Tue, 16 May 2023 13:32:14 +0200 Date: Tue, 16 May 2023 13:32:13 +0200 From: Andreas Klinger To: linux-iio@vger.kernel.org, devicetree@vger.kernel.org Cc: Jonathan Cameron , Lars-Peter Clausen , Rob Herring , Krzysztof Kozlowski , Angel Iglesias , linux-kernel@vger.kernel.org Subject: [PATCH v5 1/3] dt-bindings: iio: pressure: Support Honeywell mprls0025pa sensor Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Provags-ID: V03:K1:Vffq3MgGOTKI+sFsILoLHDUpq9prObFOT0t+R8yOKq5742j+KHO EIkiZUpSIvrsjHV2t0fC2XYNTD2p1mFd1KL0Nl0hAB2fbulRJIOYGAVdMMcCK2wBiklvcfT 4ASWPPj+XWiDyjEOaI2YeMO6ReGGS14IDYS1MdtjqUGtbmG6ohpT126S2hCsp7mTS015+pu zD6xbvwz408IAHfh51BxQ== UI-OutboundReport: notjunk:1;M01:P0:4XDL6aAvKGc=;mzMEevf4c7Z2YKmN6nQ7iH4T1ec KO7GyrZvVweVQUvrqDSSsYgRO64OPgMmybEJ7Ne31k73uzetcBWZBn8jpKpsIePqBVhyUDjuG Y1S7SXkMmymI15HDhRFbhjOVHKModLUGHQ9eCg0bdHvGy/H9A3AF+ODgMLavwvJz1YMKQmm5/ srCmWYxdiKlKj6aGtPAcaUbu8oPuertkz4Nbm87dFqdbLJaB0GL9SGdoNB17rZUvq00YLiss+ jmYbnODO6BNOnhP/UR86912PQaAUV9loyy7j/HHL0PXc6WkszDD9SPvCXIsmYmT8//w6ikScK jQIPTF0k+S6AltqYLC2tYDCEtMNJzLoYDuzDli+Dys68zREOVc20IOOK9UfBnA0EmRkPjjtLy 6fIrxbFUXA9Ej23of7mYgm9E7WcQ66OVsRCgR9KPuXDlFAMvatF9pnxvKpy4mWiH5Mwjg/DES 5pVmEpQxUIbNKrjNQ7Y8MdFRnaDDq8RvWbcisRUwmCUDPSLPk5m4ZoJ0oPnh88BLYMJwO38zh qLLiEAgwxSD9tcDTvFDDuTgSQBX/2lDgK3zVJn9vd/jMU5dF9Zv/DQ5Imnc/gtHkWL/JpeLk4 1ZOgmmOCyLdIzv9JJtbBM831abRui39MNxOY+aF1LpyFLFCGxeVDpjB9wLm7PxdKJM3xahRxE vG/mQ88yFJerizl0F2mVsL201u1QeNargBf7jwJlVA== X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Honeywell mprls0025pa is a pressure sensor series. There are many different models with different pressure ranges, units and transfer functions. The range and transfer function need to be set up in the dt. Therefore new properties honeywell,pmin-pascal, honeywell,pmax-pascal, honeywell,transfer-function are introduced. Add dt-bindings. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Andreas Klinger --- .../iio/pressure/honeywell,mprls0025pa.yaml | 104 ++++++++++++++++++ 1 file changed, 104 insertions(+) create mode 100644 Documentation/devicetree/bindings/iio/pressure/honeywell,mprls0025pa.yaml diff --git a/Documentation/devicetree/bindings/iio/pressure/honeywell,mprls0025pa.yaml b/Documentation/devicetree/bindings/iio/pressure/honeywell,mprls0025pa.yaml new file mode 100644 index 000000000000..c0a923febf13 --- /dev/null +++ b/Documentation/devicetree/bindings/iio/pressure/honeywell,mprls0025pa.yaml @@ -0,0 +1,104 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/iio/pressure/honeywell,mprls0025pa.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Honeywell mprls0025pa pressure sensor + +maintainers: + - Andreas Klinger + +description: | + Honeywell pressure sensor of model mprls0025pa. + + This sensor has an I2C and SPI interface. Only the I2C interface is + implemented. + + There are many models with different pressure ranges available. The vendor + calls them "mpr series". All of them have the identical programming model and + differ in the pressure range, unit and transfer function. + + To support different models one need to specify the pressure range as well as + the transfer function. Pressure range needs to be converted from its unit to + pascal. + + The transfer function defines the ranges of numerical values delivered by the + sensor. The minimal range value stands for the minimum pressure and the + maximum value also for the maximum pressure with linear relation inside the + range. + + 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,mprls0025pa + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + reset-gpios: + description: + Optional GPIO for resetting the device. + If not present the device is not resetted during the probe. + maxItems: 1 + + honeywell,pmin-pascal: + description: + Minimum pressure value the sensor can measure in pascal. + $ref: /schemas/types.yaml#/definitions/uint32 + + honeywell,pmax-pascal: + description: + Maximum pressure value the sensor can measure in pascal. + $ref: /schemas/types.yaml#/definitions/uint32 + + honeywell,transfer-function: + description: | + Transfer function which defines the range of valid values delivered by the + sensor. + 1 - A, 10% to 90% of 2^24 (1677722 .. 15099494) + 2 - B, 2.5% to 22.5% of 2^24 (419430 .. 3774874) + 3 - C, 20% to 80% of 2^24 (3355443 .. 13421773) + $ref: /schemas/types.yaml#/definitions/uint32 + + vdd-supply: + description: provide VDD power to the sensor. + +required: + - compatible + - reg + - honeywell,pmin-pascal + - honeywell,pmax-pascal + - honeywell,transfer-function + - vdd-supply + +additionalProperties: false + +examples: + - | + #include + #include + i2c { + #address-cells = <1>; + #size-cells = <0>; + + pressure@18 { + compatible = "honeywell,mprls0025pa"; + reg = <0x18>; + reset-gpios = <&gpio3 19 GPIO_ACTIVE_HIGH>; + interrupt-parent = <&gpio3>; + interrupts = <21 IRQ_TYPE_EDGE_FALLING>; + honeywell,pmin-pascal = <0>; + honeywell,pmax-pascal = <172369>; + honeywell,transfer-function = <1>; + vdd-supply = <&vcc_3v3>; + }; + }; -- 2.30.2 -- Andreas Klinger Grabenreith 27 84508 Burgkirchen +49 8623 919966 ak@it-klinger.de www.it-klinger.de www.grabenreith.de