Skip to main content
FItal
Associate II
July 15, 2019
Question

Hello, i have a question....could i use 10 lps22hb on same I2C bus?

  • July 15, 2019
  • 5 replies
  • 1139 views

..

    This topic has been closed for replies.

    5 replies

    Eleon BORLINI
    ST Employee
    July 15, 2019

    ​Hi @FItal​ , you can use max n.2 lps22hb on the same physical lines by setting the SA0 pad (SAD[0] bit in the Slave address) high (Vdd) or low (GND). However, you can of course share the communication lines by using the SPI protocol and lowering the CS when you want to communicate with a specific device. Regards

    FItal
    FItalAuthor
    Associate II
    July 15, 2019

    Thanks for the reply.

    best regards,

    Francesco

    Ozone
    Principal
    July 15, 2019

    With "dirty" tricks, one can use 10 or more I2C bus slaves with the same address in one bus.

    You can gate the SCL line (or better both SCL and SDA) to the slaves, having only two slaves accessible at the bus on any time (at different addresses, set by SA0 pin).

    The effort would be similar to managing /CS lines.

    Uwe Bonnes
    Chief
    July 15, 2019

    There are also I2C Muxes like the PCA9543.

    S.Ma
    Principal
    July 15, 2019

    Connect each pressure sensor slave address select pin to an individual GPIO of the MCU, and make sure only one of them is high (or low) to talk to the one.

    Running out of pins on the MCU? Use an I2C IO Expander.