Connecting Multiple LSM9DS1 through TCA9548A MUX (Adafruit Sensor/Multiplexer)

Hi,

I am attempting to use the Adafruit TCA9548A multiplexer to connect multiple Adafruit LSM9DS1 to my arduino. To my understanding, I should call tcaselect() with the respective port that my IMU sensor is connected to. However, I am getting “Oops … unable to initialize the LSM9DS1. Check your wiring!”. Is there a problem with the way I am declaring the sensor or the setup part? I combined the sample code for the multiplexer as well as the code from the LSM9DS1 library.

I have attached my code below.

Any help is appreciated! Thanks in advance!

IMU_MUX.ino (4.57 KB)

I can't open your code on my phone, can you paste it into a post between code tags please?

Also can you post a schematic showing how you have connected everything.