Page 1 of 1

Failed to open the i2c bus

Posted: Tuesday 30 January 2018 17:35
by romeo
HI,

I would like to use my BME280 sensor. This sensor uses the I2C bus.

In settings => Hardware
I add a I2C sensor type ans I2C sensor BME280 as subtype.
and connect SDA, SCL, Vcc & GND pin

In the log I have

Code: Select all

I2C Start HW witf ID: 12 Name: I2C_BME280 Address: 0 Port: undefined Invert:0
 I2C_BME280: Worker started... 
But every minutes

Code: Select all

Error: I2C_BME280: Failed to open the i2c bus!...
 Error: I2C_BME280: Check to see if you have a bus: undefined
 Error: I2C_BME280: We might only be able to access this as root user
 Error: I2C_BME280: Error opening device!... 
Why this bus is undefined ?

When I test this sensor with a python script, all is ok. I got tmp, Hum & baro correctly.

Code: Select all

./bme280.py

Chip ID     : 96
Version     : 0
Temperature :  18.83 C
Pressure :  1020.56011709 hPa
Humidity :  57.5370776855 %

Code: Select all

sudo i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- 76 --
For info, I use Domoticz beta 3.8872 and a RPI3

What's wrong with domoticz ??