Skip to content

Commit 57dddd9

Browse files
pelwellpopcornmix
authored andcommitted
overlays: i2c-sensor: Add the ad799x ADC family
Add support for the AD799[1,2,3,4,5,7,8,9] ADCs to the i2c-sensor overlay. Signed-off-by: Phil Elwell <phil@raspberrypi.com>
1 parent dfd4c72 commit 57dddd9

File tree

2 files changed

+52
-5
lines changed

2 files changed

+52
-5
lines changed

arch/arm/boot/dts/overlays/README

Lines changed: 28 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2421,16 +2421,40 @@ Name: i2c-sensor
24212421
Info: Adds support for a number of I2C barometric pressure, temperature,
24222422
light level and chemical sensors on i2c_arm
24232423
Load: dtoverlay=i2c-sensor,<param>=<val>
2424-
Params: addr Set the address for the ADS7828, ADS7830,
2425-
ADT7410, AS73211, AS7331, BH1750, BME280,
2426-
BME680, BMP280, BMP380, BMP58x, CCS811, DS1621,
2427-
HDC100X, HDC3020, JC42, LM75, MCP980x,
2424+
Params: addr Set the address for the AD799X, ADS7828,
2425+
ADS7830, ADT7410, AS73211, AS7331, BH1750,
2426+
BME280, BME680, BMP280, BMP380, BMP58x, CCS811,
2427+
DS1621, HDC100X, HDC3020, JC42, LM75, MCP980x,
24282428
MPU6050, MPU9250, MS5637, MS5803, MS5805,
24292429
MS5837, MS8607, SHT3x, TMP102 or VEML6030.
24302430

24312431
i2c-bus Supports all the standard I2C bus selection
24322432
parameters - see "dtoverlay -h i2c-bus"
24332433

2434+
ad7991 Select the Analog Devices AD7991 ADC
2435+
Valid addresses 0x28-0x29, default 0x28
2436+
2437+
ad7992 Select the Analog Devices AD7992 ADC
2438+
Valid addresses 0x20-0x24, default 0x20
2439+
2440+
ad7993 Select the Analog Devices AD7993 ADC
2441+
Valid addresses 0x20-0x24, default 0x20
2442+
2443+
ad7994 Select the Analog Devices AD7994 ADC
2444+
Valid addresses 0x20-0x24, default 0x20
2445+
2446+
ad7995 Select the Analog Devices AD7995 ADC
2447+
Valid addresses 0x28-0x29, default 0x28
2448+
2449+
ad7997 Select the Analog Devices AD7997 ADC
2450+
Valid addresses 0x20-0x24, default 0x20
2451+
2452+
ad7998 Select the Analog Devices AD7998 ADC
2453+
Valid addresses 0x20-0x24, default 0x20
2454+
2455+
ad7999 Select the Analog Devices AD7999 ADC
2456+
Valid address 0x29 (the default)
2457+
24342458
ads7828 Select the TI ADS7828 50kHz 8-channel 12bit ADC
24352459
Valid addresses 0x48-0x4b, default 0x48
24362460

arch/arm/boot/dts/overlays/i2c-sensor-common.dtsi

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -864,6 +864,20 @@
864864
};
865865
};
866866

867+
fragment@56 {
868+
target = <&i2cbus>;
869+
__dormant__ {
870+
#address-cells = <1>;
871+
#size-cells = <0>;
872+
status = "okay";
873+
874+
ad799x: ad799x@20 {
875+
compatible = "adi,ad799x"; // To be overridden
876+
reg = <0x20>;
877+
};
878+
};
879+
};
880+
867881
fragment@98 {
868882
target-path = "/";
869883
__dormant__ {
@@ -945,6 +959,14 @@
945959
veml3235 = <0>,"+53";
946960
tmp117 = <0>,"+54+98";
947961
scd4x = <0>,"+55";
962+
ad7991 = <0>,"+56", <&ad799x>,"compatible=adi,ad7991", <&ad799x>,"reg:0=0x28";
963+
ad7992 = <0>,"+56", <&ad799x>,"compatible=adi,ad7992";
964+
ad7993 = <0>,"+56", <&ad799x>,"compatible=adi,ad7993";
965+
ad7994 = <0>,"+56", <&ad799x>,"compatible=adi,ad7994";
966+
ad7995 = <0>,"+56", <&ad799x>,"compatible=adi,ad7995", <&ad799x>,"reg:0=0x28";
967+
ad7997 = <0>,"+56", <&ad799x>,"compatible=adi,ad7997";
968+
ad7998 = <0>,"+56", <&ad799x>,"compatible=adi,ad7998";
969+
ad7999 = <0>,"+56", <&ad799x>,"compatible=adi,ad7999", <&ad799x>,"reg:0=0x29";
948970

949971
addr = <&bme280>,"reg:0", <&bmp280>,"reg:0", <&tmp102>,"reg:0",
950972
<&lm75>,"reg:0", <&hdc100x>,"reg:0", <&sht3x>,"reg:0",
@@ -959,7 +981,8 @@
959981
<&as7331>,"reg:0", <&adxl345>,"reg:0",
960982
<&ads7828>,"reg:0", <&ads7830>,"reg:0",
961983
<&adxl355>,"reg:0", <&bmp58x>,"reg:0",
962-
<&veml6030>,"reg:0", <&tmp117>,"reg:0";
984+
<&veml6030>,"reg:0", <&tmp117>,"reg:0",
985+
<&ad799x>,"reg:0";
963986
int_pin = <&int_pins>, "brcm,pins:0",
964987
<&int_pins>, "reg:0",
965988
<&max30102>, "interrupts:0",

0 commit comments

Comments
 (0)