4
\$\begingroup\$

I am working on a project which involves reading from multiple IMU sensors on i2c protocol. They have a fixed i2c address and hence I feel the requirement of some sort of multiplexer.

On some research, I found two components which appear to be doing same job. Here are the brief descriptions that these devices carry on TI website:

1) TCA9544A Low Voltage 4-Channel I2C and SMBus Multiplexer With Interrupt Logic

The TCA9544A is a quad bidirectional translating switch controlled via the I2C bus. The SCL/SDA upstream pair fans out to four downstream pairs, or channels. Any individual SCn/SDn channel or combination of channels can be selected, determined by the contents of the programmable control register. Four interrupt inputs (INT3–INT0), one for each of the downstream pairs, are provided. One interrupt output (INT) acts as an AND of the four interrupt inputs.

2) TCA9546A Low Voltage 4-Channel I2C and SMBus Switch with Reset Function

The TCA9546A is a quad bidirectional translating switch controlled via the I2C bus. The SCL/SDA upstream pair fans out to four downstream pairs, or channels. Any individual SCn/SDn channel or combination of channels can be selected, determined by the contents of the programmable control register.

To me, both appear to be the same. If anyone can point out the key difference between these two things, it will be really helpful.

Also, I want to ask what will be more suited for my purpose - I want to read the sensor data from all sensors at the maximum possible rate and stream it to a host PC or mobile phone using UART/wifi/bluetooth.

\$\endgroup\$

4 Answers 4

3
\$\begingroup\$

They are the same, and section 3 in both descriptions designates both as "switch". The only difference is an ability of 9544A IC to log interrupts. I even think they are coming from the same wafer/die, just bonded out differently.

CORRECTION: David.A is right, 9544 can only multiplex 1<=>4, while 9546 can connect any combination of channels, although I am not sure what would be the purpose for this, since ACKs will collide then. Technically both ICs can be controlled as a MUX, just the control should be different.

\$\endgroup\$
5
  • \$\begingroup\$ I am not sure what you mean under "log interrupts"? TCA9544A has an additional interrupt line for each SCL/SDA pair. It simply passes interrupt to master, not logging anything. Otherwise, you are right. They are the same. \$\endgroup\$
    – Maple
    Commented May 7, 2018 at 17:35
  • \$\begingroup\$ Re: which one is more suited for your purpose. If your IMU sensors have interrupt that can be programmed to "data ready" event then the switch with interrupt support could be better. If your MCU is fast enough AND I2C is running on fast clock AND the data rate of your sensors is slow enough then you can have extra CPU ticks to do something else efficiently (like communicate to host) \$\endgroup\$
    – Maple
    Commented May 7, 2018 at 18:16
  • \$\begingroup\$ @Maple By logged he means you can read the mux to know which int is set. When an interrupt is generated by any device .... the interrupt output is driven LOW. The channel does not need to be active for detection of the interrupt. A bit is also set in the control register \$\endgroup\$
    – Henry Crun
    Commented Jul 21, 2018 at 5:12
  • \$\begingroup\$ ACKs colliding is not a problem, as long as there are no colliding addresses on simultaneously enabled sections. There are several reasons why a switch would still be beneficial: * power down some sections of the board (without having the chips phantom-power themselves from the I2C lines), * to split a large I2C bus with too high a capacitance into multiple smaller buses, * to have multiple buses with different voltage levels act as a single logical I2C bus. \$\endgroup\$
    – Jostikas
    Commented Sep 11, 2022 at 15:15
  • 1
    \$\begingroup\$ @Jostikas, per OP description, ALL devices behind the mux are IDENTICAL. That's why you need a mux/switch in the first place. \$\endgroup\$ Commented Sep 11, 2022 at 17:42
8
\$\begingroup\$

The two chips are NOT the same:

The TCA9544A is an I2C Mux. An I2C Mux multiplexes any one of N downstream ports to the upstream port (1 to 1).

The TCA9546A is an I2C Switch. An I2C Switch connects one or more of the N downstream ports to the upstream port (1 to many).

The control registers also differ.

\$\endgroup\$
4
  • \$\begingroup\$ Looks like both let you select any combination of downstream ports to connect, neither are limited to connecting a single port \$\endgroup\$ Commented May 7, 2018 at 22:32
  • 1
    \$\begingroup\$ The Mux is limited to 1-to-1 connections by design. Read the TCA9544A data sheet carefully -- sections 9.6.2 and 9.6.3 show that Control Register bits B1,B0 select ports 0-3. Compare with the TCA9546A Control Register Bits B3,B2,B1,B0 are a bit field of enabled ports. \$\endgroup\$
    – David A.
    Commented May 8, 2018 at 16:27
  • 1
    \$\begingroup\$ Well then, that datasheet is rather self-contradictory. It states multiple times that you can connect any combination of channels, but you're right that the control register doesn't seem to allow this. \$\endgroup\$ Commented May 8, 2018 at 17:18
  • \$\begingroup\$ Hmm, you're quite right. I've reported this to TI along with suggested corrections... \$\endgroup\$
    – David A.
    Commented May 10, 2018 at 16:28
3
\$\begingroup\$

I want to read the sensor data … at the maximum possible rate …

Consider using I²C address translators. At least LT (now part of Analog Devices) have them in their portfolio (product family overview). It sits between two bus sections and normally connects them. It watches for Start Conditions and tinkers the connection during the following address byte in a way that the address on the downhill bus section becomes exored by a preset value.

The advantage considering your needs ("maximum possible rate") is that no I²C transactions to control the switch/mux are necessary – at the disadvantage that, depending on the number of sensors, you may run out of I²C addresses.

\$\endgroup\$
2
\$\begingroup\$

You might simply use analog switches and port pins to select them. This is fast, easy and cheap. A single 74HC4051 switching SDA alone would give you 8 I2C buses, or a 74hc4052 switching SDA and SCL gives you 4.

You might also consider our product BL233. This is a serial to I2C convertor, with up to 4 separate channels. It could read 4 sets of these sensors stand alone, connected to an off the shelf bluetooth serial module. No micro is needed.

A significant advantage is that this is truly portable across all platforms - it doesn't stop working when your $FRUITNAME$Pi changes chip, or Windows 11,12,13 breaks the drivers.

BTW, we used the 9545 bus switch, and stopped using the 9544 bus mux as a switch is more versatile. With a switch you have the option to write to all the chips at once, and read them separately, which can speed some things up. Also they are useful as level shifters, when you don't want to switch the ports at all.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.