Skip to main content
artemis1992
Associate II
March 19, 2014
Question

I2C and sensors

  • March 19, 2014
  • 5 replies
  • 1198 views
Posted on March 19, 2014 at 16:08

Hello, I have a STM32F100RBT6B board, and I should use some sensors

LSM303D

with I2C

.

Just a question: wich is the maximum number of sensors that I can use with an I2C interface?

#sensor #i2c
This topic has been closed for replies.

5 replies

Tesla DeLorean
Guru
March 19, 2014
Posted on March 19, 2014 at 16:18

wich is the maximum number of sensors that I can use with an I2C interface?

Will be limited by the number of unique addresses you can assign to the devices you plan on using, in the case of the part you mentioned that would be TWO, controlled by the SA0 pin
Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
artemis1992
Associate II
March 19, 2014
Posted on March 19, 2014 at 16:23

Thanks for the answer. So if I would like to control 4 sensors, should I use both I2C interface? In this case, is it impossible to control 5 sensor?

frankmeyer9
Associate III
March 19, 2014
Posted on March 19, 2014 at 16:46

So if I would like to control 4 sensors, ...

 

Not correct.

I2C uses the LSB to differ between read and write access, so you can attach only two devices to one bus without interference.

That is even described in the LSM303D datasheet (see sect. 6.1.1).

artemis1992
Associate II
March 19, 2014
Posted on March 19, 2014 at 17:00

Thank you very much

artemis1992
Associate II
March 19, 2014
Posted on March 19, 2014 at 17:06

Thank you very much