03-11-2021 09:21 AM
Good morning,
I have successfully developed and tested this sketch (https://github.com/jordan1982/temperaturino) on d1 mini. Then I bought a new d1 mini and a new sensor bme680, loaded the sketch but at startup it goes into error with the following error: BME680 error code: -2
I tried to change the line "iaqSensor.begin (BME680_I2C_ADDR_SECONDARY, Wire);" to BME680_I2C_ADDR_PRIMARY, but the sensor fails. I get the same error with the basic sketch included in the library. Can someone help me? Thank you
Solved! Go to Solution.
03-12-2021 07:20 PM
Thanks for the replies. I tried to use the default sketch of the Adafruit library, both with the primary and secondary addresses get the error -2. I think the manufacturers of the sensor are different. Could the problem be the welds?
03-15-2021 04:11 PM
Hello Jordan,
-2 error means communication error, so your i2c interface might have some issue.
Could you capture i2c and check whether i2c data is coming correctly?
If yes, could you please share it as well?
Thanks,
03-16-2021 05:53 PM
It was a cable soldering problem.
Thank you all.