At the moment I’m designing a multi functional device with various sensors.
I’m using the LPC2148 as CPU. Mainly all sensors are connected to the I2C bus because I use both SPI’s for an OLED display, SD-Card, MP3-Codec (VS1053).
Unfortunately I can use only one of theI2C buses, because of the pin multiplexing (UART).
I’m planning to connect 6 devices with different addresses to the I2C bus.
Those devices are:
Capacitive Touch Senosr (AD7147)
Temp Sensor (LM73)
Accel Sensor (LIS302DL)
Barometer (SCP1000)
Battery Monitor (Bq27210)
GPIO Expander (PCA9539)
When I connect all those devices to one bus, do I have to be worry about something?
Is it better to use a I2C buffer?
A friend of mine showed me a technique which I would like to call the “Poor man’s clock distributor”
He said that it would be good to route the I2C clock from the cpu to a 8channel buffer (inverted or non-inverted).
Then connect the clock with all inputs of the buffer and route all outputs of the buffer to the according device.
Even if the I2C clock frequency is only 400kHz, I’m sure that there can be problems in routing to so many devices.
"The number of ICs that can be connected to the same
bus is limited only by a maximum bus capacitance of
400 pF"
…so if you keep your traces short, you’re probably okay. If you’re not too sure, check the device datasheets to see if they say how much capacitance each device adds. It probably wouldn’t hurt to add a buffer just to be certain (check out [www.nxp.com for some), but I myself would not worry about it.](http://www.nxp.com)
messi:
He said that it would be good to route the I2C clock from the cpu to a 8channel buffer (inverted or non-inverted).
Then connect the clock with all inputs of the buffer and route all outputs of the buffer to the according device.
That isn’t allowed by the I2C spec! Any slave device may hold the clock low if it needs more time to respond - that would no longer be possible in this case, and could easily damage the slave device as it probably can’t sink as much current as the buffer can source.
Now, many I2C devices never actually perform clock stretching. However, do you really want to have to verify this for every device you’re currently using, may add to the bus in the future, or may need to replace a current device with if the original part becomes unavailable?
Have you successfully integratqed SCP1000 I2C INTO any ATMEGA BOARDs?
I need some help with a working code, also how to integrate the 3v SCP1000-D11 to an Atmega128?
response would be greatly appreciated.
messi:
Hi everybody.
At the moment I’m designing a multi functional device with various sensors.
I’m using the LPC2148 as CPU. Mainly all sensors are connected to the I2C bus because I use both SPI’s for an OLED display, SD-Card, MP3-Codec (VS1053).
Unfortunately I can use only one of theI2C buses, because of the pin multiplexing (UART).
I’m planning to connect 6 devices with different addresses to the I2C bus.
Those devices are:
Capacitive Touch Senosr (AD7147)
Temp Sensor (LM73)
Accel Sensor (LIS302DL)
Barometer (SCP1000)
Battery Monitor (Bq27210)
GPIO Expander (PCA9539)
When I connect all those devices to one bus, do I have to be worry about something?
Is it better to use a I2C buffer?
A friend of mine showed me a technique which I would like to call the “Poor man’s clock distributor”
He said that it would be good to route the I2C clock from the cpu to a 8channel buffer (inverted or non-inverted).
Then connect the clock with all inputs of the buffer and route all outputs of the buffer to the according device.
Even if the I2C clock frequency is only 400kHz, I’m sure that there can be problems in routing to so many devices.