Notifications
Clear all

BME 280 incorrect readings  

  RSS

Bertf
(@bertf)
Active Member
Joined: 3 months ago
Posts: 10
2020-07-18 1:22 pm  

I could really use some help.

 

My bme 280 sensor is about 20 C higher than it should be, humidity about 8% less and the even weirder thing is that when I cover the sensor temp drops and the humidity goes up.

 

Has anyone seen this before and is there is fix for this?

 

I am running off a nano and connected I2C


Quote
MadMisha
(@madmisha)
Eminent Member
Joined: 5 months ago
Posts: 34
2020-07-18 11:52 pm  

@bertf I think a little more information will help. What brand of module is it exactly? What library are you using? Example of code. What mode is it using? How are you powering it?(direct from 3V pin?) Does it use the Bosch sensor?

 

If it does then this datasheet might help.

Bosch-BME280_DS001-10

 

 


ReplyQuote
Bertf
(@bertf)
Active Member
Joined: 3 months ago
Posts: 10
2020-07-19 5:15 am  

@madmisha

 

Here is the sketch i have been using. I powered from 5 volts and used I2C. The sensor is the bosh and the board model is GY-B11

 

#include <Adafruit_BME280.h>

//Libraries
#include <LiquidCrystal_I2C.h>
#include <wire.h>

//objects
LiquidCrystal_I2C lcd(0x27,20,4);
Adafruit_BME280 bme;

#define SEALEVELPRESSURE_HPA (1013.25)

 

void setup() {
// put your setup code here, to run once:
Serial.begin(9600);
if (!bme.begin(0x76))
{
Serial.println("Could not find a valid BME280 sensor, check wiring!");
while (1);
}
lcd.init();
lcd.backlight();
lcd.clear();
delay (500);

}

void loop() {
// put your main code here, to run repeatedly:
{

lcd.clear ();
lcd.setCursor (0,0);
lcd.print("Temp = ");
lcd.print(bme.readTemperature()); //prints in °C
lcd.print(" C ");
//delay (1000);

lcd.setCursor (0,1);
lcd.print("Pressure = ");
lcd.print(bme.readPressure() / 100.0F);
lcd.print("hPa");
//delay (1000);

lcd.setCursor (0,2);
lcd.print("Humidity = ");
lcd.print(bme.readHumidity());
lcd.print("%");
//delay (1000);
//Serial.println();
delay (2500);
}


ReplyQuote
MadMisha
(@madmisha)
Eminent Member
Joined: 5 months ago
Posts: 34
2020-07-19 10:22 am  

@bertf So, to start, that sensor is not 5 volt. It has a max voltage of 3.6 volts. It can actually heat itself up and effect it's own temperature readings. Same is true about reading at a high rate/higher clock speeds(at-least that's what I've read).

 

I have a new one sitting on front of me but it will be a day or two before I can mess with it. Let me know if correcting the voltage helps.

 

I would also expect something like,

 

bme.begin();

ReplyQuote
billd01
(@billd01)
Active Member
Joined: 1 month ago
Posts: 7
2020-07-20 8:27 am  

@bertf HI,

I have about 10 BME280 sensors scattered around the house/garage, they are quick and easy to use. When I get unexpected results I strip the sketch back to basics and slowly add displays, WiFi connectivity, what ever the enhancement may be.

I cut/pasted your code below, removed the LCD components and simply displayed the results on Serial Monitor - worked perfect first time (I have two other BME280's in my workshop that I could compare the results).

I used Arduino Uno, powered BME280 on 3V3 pin.

image

Try reading values on serial monitor, then add the display.

good luck

billd

 


ReplyQuote
billd01
(@billd01)
Active Member
Joined: 1 month ago
Posts: 7
2020-07-20 9:11 am  

PS: I did a quick experiment with an IC 16x4 LCD . . . The LCD had minor formatting issues, but the BME280 worked fine, displayed accurate values on Serial Monitor and LCD. Powered both the LCD and BME280 from 5V . . . no problem.

You may have a dud BME280, do you have a spare?

image

cul

billd

 


ReplyQuote
billd01
(@billd01)
Active Member
Joined: 1 month ago
Posts: 7
2020-07-20 9:29 am  

@madmisha the bme.begin() is here . . .

Posted by: @bertf

if (!bme.begin(0x76))
{
Serial.println("Could not find a valid BME280 sensor, check wiring!");
while (1);
}

cul

billd


ReplyQuote
Bertf
(@bertf)
Active Member
Joined: 3 months ago
Posts: 10
2020-07-22 3:41 am  

Thanks for the help. I think i Have a dud. If I put my finger on the sensor the temp goes down rather than up.

 

Still waiting for my suppliers stock. They are not easy to find in South Africa.......


ReplyQuote
MadMisha
(@madmisha)
Eminent Member
Joined: 5 months ago
Posts: 34
2020-07-25 1:21 am  

@bertf There are some things you can do that are listed in the datasheet but since they are so cheap you might as well get a new one.

 

But never power it on 5 Volts. Since the manufacturer of the module and the datasheet list operating voltage as 3.6 max operating(the sensor datasheet warns that max voltage on any pin is 4.25V.), you will likely cause damage.

 

It is normal for the sensor to tend to read slightly higher temperatures than other sensors but not as high as you have seen them.


ReplyQuote
Bertf
(@bertf)
Active Member
Joined: 3 months ago
Posts: 10
2020-08-02 5:02 am  

Thanks for all the advice. I have ordered a new sensor. Once I have that I will see what the readings are and how they compare. But I said, I think it may well be a dud.


ReplyQuote