Skip to content Skip to sidebar Skip to footer

How To Solve Raspberry Pi 3b & Bme280 Remote I/o Error

Let me start off with the components used: GPIO extension board to connect the raspberry pi to components Bme280 Pi 3B Problem description: This problem was intermittent at first

Solution 1:

I've tried to respond, but there is a few pitfalls in SMBus and i2c, so to break the question into smaller bits I've quoted your original message with an indent. The response is provided beneath.

This problem was intermittent at first. We were receiving reading and the error occurred out of nowhere, made adjustment to the sensor(taking out and putting it back in) which solved it but when we touch the sensor the error showed up again.

I locked onto the statement, "Touched the sensor". Is there a chance the BME280 experienced an ESD discharge? And therefore is now partially or fully broken?

Are you using an ESD safe room? or at least ESD bracelet. You will not notice small ESD discharges, and for small electronics even a sub 1000V discharge can cause damage instantly or over time. (Fundamentals of Electrostatic Discarge - incompliancemag.com)

I followed this BME280 installation guide, however when prompting for 'i2cdetect -y 1' there were lines but no number showing up.

The I2Cdetect -y 1 Will send a ReadBit message to each possible slave 0-127. Then listens for the ACK on the slave address. The message is very simple, but does the trick for detecting working i2c slaves. As you stated there is no "Lines", i would suggest the slave either has issues responding, if the BME280 has the correct 3v3+GND supplied.

As another possability, could you redo this step dtparam=i2c_arm=on,i2c_baudrate=400000

(Set the baudrate way down to 10000 /10k. Should this solve the issue and you need higher bandwidth, attempt on "50000 /50k" or "100000 /100k") This is just to eliminate the possibility the slave cannot opperate on this high frequency. 400k Baudrate for SMBus is high for a prototype/testing scenario. Very small amounts of interference can corrupt the data over SDA.

Another possibility is the Sink-Current which i've learned the hard way is not the same on i2c and SMBus over i2c. Is you Pull-up resistor appropriate for the limited sink-current?

The SMBus specifies a minimum sink current of 100µA, and a maximum of 350µA, compared to 3mA for the I²C bus (Ampere=Voltage/Resistance Ohm).

Now to the Software issue.

From your supplied picture on imgur. File "newcodes_''''''''''''''.py" line 2, in

Your compiler cannot find "bme" where you attempt to import bme280. Reference/path issue? This can be the cause for other issues further into the code calls.

I don't know what SW you are writing the code in, but if there is an option to insert a breakpoint and run a debug build. I would suggest starting there :)

Solution 2:

Alright I have resolved the issue, I changed the wire from jumper wire to hard wire. Thank you guys for your response. I appreciate all of them :D

Post a Comment for "How To Solve Raspberry Pi 3b & Bme280 Remote I/o Error"