mirror of
				https://github.com/Ysurac/openmptcprouter.git
				synced 2025-03-09 15:40:20 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			78 lines
		
	
	
	
		
			2.8 KiB
		
	
	
	
		
			Diff
		
	
	
	
	
	
			
		
		
	
	
			78 lines
		
	
	
	
		
			2.8 KiB
		
	
	
	
		
			Diff
		
	
	
	
	
	
| From 627df0e37c708e6be31d49a5f263056ffdbfe9d6 Mon Sep 17 00:00:00 2001
 | |
| From: Phil Elwell <phil@raspberrypi.com>
 | |
| Date: Sun, 30 Jul 2023 18:27:03 +0100
 | |
| Subject: [PATCH] overlays: Add bmp380 to i2c-sensor overlay
 | |
| 
 | |
| Add support for the BMP380 pressor sensor to the i2c-sensor overlay.
 | |
| 
 | |
| See: https://github.com/raspberrypi/linux/issues/5558
 | |
| 
 | |
| Signed-off-by: Phil Elwell <phil@raspberrypi.com>
 | |
| ---
 | |
|  arch/arm/boot/dts/overlays/README             |  7 +++++--
 | |
|  .../boot/dts/overlays/i2c-sensor-common.dtsi  | 19 ++++++++++++++++++-
 | |
|  2 files changed, 23 insertions(+), 3 deletions(-)
 | |
| 
 | |
| --- a/arch/arm/boot/dts/overlays/README
 | |
| +++ b/arch/arm/boot/dts/overlays/README
 | |
| @@ -2052,8 +2052,8 @@ Info:   Adds support for a number of I2C
 | |
|          light level and chemical sensors on i2c_arm
 | |
|  Load:   dtoverlay=i2c-sensor,<param>=<val>
 | |
|  Params: addr                    Set the address for the BH1750, BME280, BME680,
 | |
| -                                BMP280, CCS811, DS1621, HDC100X, JC42, LM75,
 | |
| -                                MCP980x, MPU6050, MPU9250, MS5637, MS5803,
 | |
| +                                BMP280, BMP380, CCS811, DS1621, HDC100X, JC42,
 | |
| +                                LM75, MCP980x, MPU6050, MPU9250, MS5637, MS5803,
 | |
|                                  MS5805, MS5837, MS8607, SHT3x or TMP102
 | |
|  
 | |
|          aht10                   Select the Aosong AHT10 temperature and humidity
 | |
| @@ -2075,6 +2075,9 @@ Params: addr                    Set the
 | |
|          bmp280                  Select the Bosch Sensortronic BMP280
 | |
|                                  Valid addresses 0x76-0x77, default 0x76
 | |
|  
 | |
| +        bmp380                  Select the Bosch Sensortronic BMP380
 | |
| +                                Valid addresses 0x76-0x77, default 0x76
 | |
| +
 | |
|          bno055                  Select the Bosch Sensortronic BNO055 IMU
 | |
|                                  Valid address 0x28-0x29, default 0x29
 | |
|  
 | |
| --- a/arch/arm/boot/dts/overlays/i2c-sensor-common.dtsi
 | |
| +++ b/arch/arm/boot/dts/overlays/i2c-sensor-common.dtsi
 | |
| @@ -493,11 +493,27 @@
 | |
|  		};
 | |
|  	};
 | |
|  
 | |
| +	fragment@33 {
 | |
| +		target = <&i2cbus>;
 | |
| +		__dormant__ {
 | |
| +			#address-cells = <1>;
 | |
| +			#size-cells = <0>;
 | |
| +			status = "okay";
 | |
| +
 | |
| +			bmp380: bmp380@76 {
 | |
| +				compatible = "bosch,bmp380";
 | |
| +				reg = <0x76>;
 | |
| +				status = "okay";
 | |
| +			};
 | |
| +		};
 | |
| +	};
 | |
| +
 | |
|  	__overrides__ {
 | |
|  		bme280 = <0>,"+0";
 | |
|  		bmp085 = <0>,"+1";
 | |
|  		bmp180 = <0>,"+2";
 | |
|  		bmp280 = <0>,"+3";
 | |
| +		bmp380 = <0>,"+33";
 | |
|  		htu21 = <0>,"+4";
 | |
|  		lm75 = <0>,"+5";
 | |
|  		lm75addr = <&lm75>,"reg:0";
 | |
| @@ -535,7 +551,8 @@
 | |
|  			<&ms5637>,"reg:0", <&ms5803>,"reg:0", <&ms5805>,"reg:0",
 | |
|  			<&ms5837>,"reg:0", <&ms8607>,"reg:0",
 | |
|  			<&mpu6050>,"reg:0", <&mpu9250>,"reg:0",
 | |
| -			<&bno055>,"reg:0", <&sht4x>,"reg:0";
 | |
| +			<&bno055>,"reg:0", <&sht4x>,"reg:0",
 | |
| +			<&bmp380>,"reg:0";
 | |
|  		int_pin = <&max30102>, "interrupts:0",
 | |
|  			<&mpu6050>, "interrupts:0",
 | |
|  			<&mpu9250>, "interrupts:0";
 |