I have trouble setting up a wemos esp32-s2 mini with a TCA9548A I²C Multiplexer and BME280 sensor. In fact, when I set the scan option no I2C device is found. I have attached a Lux and Accelerometer to other 2 channels just to see, but I think not even the multiplexer is found.
now the mutliplexer is found with i2c scan. I got a lux sensor to work, but only with pullup resistors 4.7K on SDA and SCL of the multiplexer and on the i2c lines of the lux sensor.
bme280 is still not working, BUT:
If I change it’s address tp 0x76 then the board will not boot. When I pull the VCC wire of the bme280 it boots again. VCC plugged, does not boot. But this behavior is only with address 0x76, which should be the correct address.
I tried another BME280 with the same behaviour.
I wired and soldered the board from scratch. I can see the mutiplexer, I can see the bh1750 light sensor, have a PIR connected to GPIO, it works, except for the bme280.
When I set address: 0x76 the board will not boot. So it seems once it somehow talks to the sensor, something bad happens and the board wont boot until I flash another image via USB where address 0x76 for bme280 is not set.
Another experiment: Set bme280 to bmp280 with address 0x76. It boots then, but says:
[E][bmp280.sensor:131]: BMP280 has wrong chip ID! Is it a BME280?
Yes, obviosly, but how the hell do know it’s the wrong chipID, so there must be some communication going on…
I got it! I used the esp-idf framework because I was not able to initially boot the s2 mini with the default settings. Dont know why i boots now with the default. But the bme280 started working once I switched the framework.