Not able to get readings from the BME280 temperature, humidity and pressure sensor.
Anyone having the same problems?
It is connected to a nodemcuv3 board, code below.
Error message simply says “communication with BME280 failed” (see picture)
That didn’t seem to make any difference either unfortunately.
In fact, I tried with 4 different BME280 sensor too, in case it was a faulty sensor. Same results.
I also tried with a ESP32S board in case it was the board. Same result.
So - I am not sure where the problem is.
What board do you use @Florian? Would like to try a non-NodeMCU board and see if that might solve it.
I’m using only Wemos D1 mini boards in combination with the BME280 sensors. I have seven of them running and all are working fine.
Below is one of my device’s config. It’s running in “weather station” configuration (1x oversampling, 60 seconds interval). Remove the mqtt and the filters part if you don’t need it.
I have the same problem. I’m using a wemos d1 mini pro, sda on pin 4 sclk on pin5 and the sensor is a BME280. This is one of the first projects I’m trying to do using hassio and espHome, it is ridiculously simple and it doesn’t work. I have programmed the same exact setup with espEasy and it worked like a charm. Below is my latest code which has been modified numerous times, It is basically from one of the authors in this chain without the password info, but still no love from esphome…
Florian,
Using EspEasy the system works and it’s address is 0x76. Prior to that, I have tried both addresses using EspHome. I’ll try to dig through the ESPHome code for the BME280, I have a feeling the address is not getting changed correctly. But if you have any other ideas I’m all ears
So I tried to change the frequency of the I2C component from 50kHz to 200khz. However when I ran the logs it always says I2C Frequency is 50kHz? I did a clean rebuild but still no luck.
The only other thing i can think of is to check youre i2c wiring configuration again and maybe set scan: true to see if anything is returned. Other than that I’m out of ideas…
@ricreis394
your address: 0x77 needs to go under the i2c component not the individual sensor component. But you’ve already got it scanning, so if you want to add a direct address there, then remove the scan: true
Also, I lied. I just looked at the config the address: line does go within the sensor for some reason. I guess it kind of makes sense, but makes more senese to me to define i2c devices within the i2c config. shrug. Sort out your sda/scl and it will work.