From cbde2f9c018a92de27e0314a56f19976bdb0123b Mon Sep 17 00:00:00 2001 From: James Sarrett Date: Sun, 26 Jan 2025 22:07:02 -0800 Subject: [PATCH] add shtc3 to i2c-sensors This patch adds the shtc3 device tree parameters to the i2c-sensors overlay. The shtc3 driver needs no other configuration parameters, as the i2c address is permanently baked in to the silicon. --- arch/arm/boot/dts/overlays/README | 3 ++ .../boot/dts/overlays/i2c-sensor-common.dtsi | 34 ++++++++++++++----- 2 files changed, 28 insertions(+), 9 deletions(-) --- a/arch/arm/boot/dts/overlays/README +++ b/arch/arm/boot/dts/overlays/README @@ -2605,6 +2605,9 @@ Params: addr Set the humidity sensors. Valid addresses 0x44-0x45, default 0x44 + shtc3 Select the Sensirion SHTC3 temperature and + humidity sensors. + si7020 Select the Silicon Labs Si7013/20/21 humidity/ temperature sensor --- a/arch/arm/boot/dts/overlays/i2c-sensor-common.dtsi +++ b/arch/arm/boot/dts/overlays/i2c-sensor-common.dtsi @@ -554,6 +554,21 @@ #size-cells = <0>; status = "okay"; + shtc3: shtc3@70 { + compatible = "sensirion,shtc3"; + reg = <0x70>; + status = "okay"; + }; + }; + }; + + fragment@37 { + target = <&i2cbus>; + __dormant__ { + #address-cells = <1>; + #size-cells = <0>; + status = "okay"; + hts221: hts221@5f { compatible = "st,hts221-humid", "st,hts221"; reg = <0x5f>; @@ -565,7 +580,7 @@ }; }; - fragment@37 { + fragment@38 { target = <&i2cbus>; __dormant__ { #address-cells = <1>; @@ -579,7 +594,7 @@ }; }; - fragment@38 { + fragment@39 { target = <&i2cbus>; __dormant__ { #address-cells = <1>; @@ -597,7 +612,7 @@ }; }; - fragment@39 { + fragment@40 { target = <&i2cbus>; __dormant__ { #address-cells = <1>; @@ -615,7 +630,7 @@ }; }; - fragment@40 { + fragment@41 { target = <&i2cbus>; __dormant__ { #address-cells = <1>; @@ -681,11 +696,12 @@ sht4x = <0>,"+32"; adt7410 = <0>,"+34"; ina238 = <0>,"+35"; - hts221 = <0>,"+36+99"; - veml6075 = <0>,"+37"; - hdc3020 = <0>,"+38+99"; - as73211 = <0>,"+39+99"; - as7331 = <0>,"+40+99"; + shtc3 = <0>,"+36"; + hts221 = <0>,"+37+99"; + veml6075 = <0>,"+38"; + hdc3020 = <0>,"+39+99"; + as73211 = <0>,"+40+99"; + as7331 = <0>,"+41+99"; addr = <&bme280>,"reg:0", <&bmp280>,"reg:0", <&tmp102>,"reg:0", <&lm75>,"reg:0", <&hdc100x>,"reg:0", <&sht3x>,"reg:0",