Voting resources, early voting, and poll worker information - VOTE. ... Adafruit is open and shipping.
0

Adafruit TCA9548A with two VL53L1(!)X sensors
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Adafruit TCA9548A with two VL53L1(!)X sensors

by pede on Sun Jul 12, 2020 2:44 pm

Hi guys,

I own the adafruit TCA9548A i2c mux and saw on learning adafruit that there are Python Blinka drivers for the i2c Mux board and drivers for your VL53L0X ToF sensor is available. In my project I use a raspi and I need to VL53-toTofs (problem both use hard i2c hex29 address. So my question now is, can I use your i2c mux board togehter with the pimoroni VL53L1(!)X sensors? Does your driver for your VL53L0X Tof works with it or do I had to buy yours ones?
Many thx in advance

Peter

pede
 
Posts: 3
Joined: Sun Jul 12, 2020 2:16 pm

Re: Adafruit TCA9548A with two VL53L1(!)X sensors

by adafruit_support_mike on Wed Jul 15, 2020 3:07 pm

The TCA9548A will work with any I2C device.

The TCA9548A is basically a grid of switches that connect the input SDA and SCL pins to some combination of the output SDA and SCL pins. It doesn't do protocol translation or anything else that might interfere with other I2C devices.

Each pair of switches for the output SDA/SCL pins is controlled by one bit in an 8-bit register. Setting the bit to 1 closes the switches (connecting the output pins to the input SDA/SCl pins) and setting the bit to 0 opens the switches.

The TCA9548A has its own I2C circuit, so you can use I2C to set the 8-bit value that controls the switches. That's the only value the TCA9548A needs to know, so the code for a 'controller' just needs to send the TCA9548A's I2C address and the 8-bit control mask.

Once a given set of output SDA/SCL lines are connected to the input SDA/SCL lines, any I2C devices connected to the output lines will see what looks like a direct connection to the microcontroller.

adafruit_support_mike
 
Posts: 61407
Joined: Thu Feb 11, 2010 2:51 pm

Re: Adafruit TCA9548A with two VL53L1(!)X sensors

by pede on Thu Jul 16, 2020 10:48 am

Hi Mike,

that quit clear my thx for your explanantion. Perhaps my question was not clearly stated. Can I use the Pimoroni VL531LX Tof sensors with your lib (https://learn.adafruit.com/adafruit-vl5 ... cuitpython).
I tried to use it as guided in this tutorial. Before this I installed Blinka on my raspi 3+. Doing this it fails with many error from the lib.

regardly

Peter

pede
 
Posts: 3
Joined: Sun Jul 12, 2020 2:16 pm

Re: Adafruit TCA9548A with two VL53L1(!)X sensors

by adafruit_support_mike on Sun Jul 19, 2020 2:09 am

Ah.. thanks for the clarification.

The VS53L1X won't work with our VS53L0X library by default because the two devices have different built-in ID numbers. The code checks those to make sure it's talking to the right kind of device before moving on.

I don't know how well the VS53L0X commands and register mappings carry over to the VS53L1X, but would guess that there are some differences. ST Micro's documentation kind of hides the hardware details and leans heavily on the "we've written code libraries for the device, so just use those" message. It would probably take a deep dive into both libraries to find out how much they overlap.

adafruit_support_mike
 
Posts: 61407
Joined: Thu Feb 11, 2010 2:51 pm

Re: Adafruit TCA9548A with two VL53L1(!)X sensors

by pede on Sun Jul 19, 2020 6:42 am

Hi,

my thx for your message (what I feared :-(. I already ordered your VL53L0X :-)

Peter

pede
 
Posts: 3
Joined: Sun Jul 12, 2020 2:16 pm

Please be positive and constructive with your questions and comments.