Volt Docs

Reference

TCA9548A

I2C multiplexer (8 channels).

Connects over
I²C
Address
0x70 (or 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, 0x77)
Made by
Texas Instruments
Datasheet
ti.com

Use it

main.volt
hardware {
    device tca9548a: TCA9548A
}

every 1s {
    tca9548a.select(1)
}

On its own, the declaration puts the TCA9548A on the first I²C bus (SDA 21, SCL 22 on the ESP32) at 0x70. To choose the pins or the address, declare the bus and attach the device: device tca9548a: TCA9548A on i2c0 at 0x71 with i2c i2c0(sda: 21, scl: 22).

Methods

  • tca9548a.select(channel: int)

    Select I2C channel 0-7

  • tca9548a.disable()

    Disable all channels

Wiring

PinConnect to
VCC3.3V or 5V
GNDGround
SDAPull-up to VCC (often on breakout board)
SCLPull-up to VCC
A0..A2Address select (8 unique addresses 0x70 – 0x77)
RSTActive-low reset
SDx/SCxDownstream I²C buses (8 pairs)

Specifications

Voltage
1.65V – 5.5V
Current
75 μA standby
Channels
8 independent I²C buses
Interface speed
I²C up to 400 kHz on each channel

Tips

  • Use when you need multiple devices with the same fixed I²C address (e.g. four BH1750s).
  • Each downstream bus needs its own pull-up resistors.
  • Select channel by writing a bitmask — multiple channels can be active at once (but reading from two devices with same address is ambiguous).

Alternatives worth knowing:

  • PCA9548A: NXP equivalent — same datasheet behaviour.
  • TCA9544A: 4-channel version — cheaper if you don't need 8.