Photon & Adafruit BME280 troubleshooting

I’m trying to use the Adafruit BME280 sensor with my photon. I’ve been using the Adafruit_BME280 particle library, and in that I’ve been using the example code. Every time I’ve tried to run it, I get the “Could not find a valid BME280 sensor, check wiring!” message. This has happened when I’ve tried both the I2C and SPI options. I’ve tried the SPARKFUNBME280 library as well(didn’t expect anything from that) and got 0.00 for all the readings.
I have looked over my SPI and I2C wiring a million times and I know the pins are correct in both cases. I’ve connected the VIN to the 3v3 pin and the VIN particle pins to no avail. It is grounded, as well.

VIN -> Particle VIN / 3v3
GND -> Particle GND
SCK -> D0
SDI -> D1

I haven’t been connecting it to anything with an extreme voltage. is it possible i shorted out my sensor? I can provide any details needed.


Hmm, you said you tried SPI and I2C and “mega checked” the wiring, but then you post this

That is definetly not correct for neither SPI nor I2C.



Since the logic levels on the Photon are 3.3V you should power the sensor via Photon 3v3 -> Sensor Vin

And don’t forget pull-ups for i2c!

1 Like

I have righted this mistake, and flipped the pins. It is now
SCK -> D1
SDI -> D0
And I am still getting the same result.

Hi @karica2

Maybe you should share a picture of the wiring, just so we can help more.

Also I would try running i2c scanner code on your Photon to see if it can find the device at address 0x77.

1 Like

When changing the configuration of wires to take a clean picture, I ran the test code as a hail mary and it just started working. I’m not sure what I changed, or if it was faulty wires. Thank you to everybody who helped!!!