I'm working with an excellent script for a pinewood derby timer (many thanks to David at misjunk.org for this project!).
The project has several (six in my case) Adafruit 0.56" I2C Backpack 7 Segment Displays to show the race time of each track. I wanted to add another duplicate set of displays on the back side of the finish gate. It seems that these displays don't transmit any data on the I2C, so I'd think I can have two displays on the same I2C address. Can I do this?
All I2C devices put signals on the line, whether or not they're sending data. They have to do handshaking and acknowledge data transmitted from the master.
Will two identical I2C devices at the same address work in parallel and produce the same output? I think there's a good chance that they might. Try it and see.
If it doesn't work out then it's easy to do I2C in software so you can use two other pins to connect the screens. Google for "Arduino softi2c" or something like that.
You will need a multiplexer on the I2C lines to switch devices. You can't use the same bus as although nothing gets sent back an I2C device will acknolwage the end of the byte by pulling down the data line. If you have two devices doing that you will exceed the permitted current even if by some fluke it does work.
When I built this timer last year for my son's scout troop, I had one set of timers and was using a 12v power supply. This year, when I added the other six timers, nothing worked and I presumed that there wasn't enough current, so I put in a 12v 5A power supply. When I hooked it up, some of the diodes blew on the display backpacks.
So, I looked back at the schematics and noticed that the timers said 5v on the supply side, and I assumed that there was something different about this power supply (which I metered at 12.5v), and that was the issue. So, I found a 5v 1.5A supply and hooked it up.
Right now, I have 5 of 12 of the displays up and running, and two pair of those are duplicates, but apparently by some fluke of engineering. LOL. I'll go back to the original six timer design then.
Grumpy_Mike:
You can't use the same bus as although nothing gets sent back an I2C device will acknolwage the end of the byte by pulling down the data line. If you have two devices doing that you will exceed the permitted current even if by some fluke it does work.
??
One of the key design features of I2C is that it uses open collector inputs and external pullup resistors. Multiple devices are allowed to pull down the data lines (in fact the protocol doesn't work if they can't!)
so I put in a 12v 5A power supply. When I hooked it up, some of the diodes blew on the display backpacks.
That sounds like there is something else wrong. If a 5A power supply blows some diodes yet a 1.5A supply does not then you have something else wrong with your circuit and the 1.5A supply is going into current limit to "save" these diodes.
Multiple devices are allowed to pull down the data lines (in fact the protocol doesn't work if they can't!)
No only the responding device can pull down the data line. It is in the protocol.
I meant that multiple devices are allowed to hold I2C lines low. It's in the specification. The clock and data lines are identical, electrically.
But that's getting away from the subject. I'm more interested in your statement that "you will exceed the permitted current". What current would that be? The only source of current on the bus is the pullup resistor and it makes no difference to the resistor how many devices pull the lines low at the same time.
I've just had a think ... and I can't come up with any reason why two identical slave devices which only receive data can't be connected to the same I2C bus.
Even if they hold the clock line low to throttle the master the protocol will still work, it will just run at the speed of the slowest device.
FYI , if you can drop that 12V down to 9V , your regulators will run cooler because they don't have to dissipate
the difference.
If you can measure the current of your entire load on the 12V supply you use a dropping resistor.
R (dropping) = (Vin-Vload)/I (load) | I load = load current, => (12.5V-9V)/(total load current)=> 3.5V/(load current)
3.5V/(load current)
Power dissipation =[(total load current) x 9V] (in Watts)
if total load current = 1.5A,
Power dissipation of R (dropping ) = (1.5A x 9V) = 13.5W. (15W to 20W resistor would work.
R (dropping) = (3.5V/1.5A)=2.33 ohm ,20W
Grumpy_Mike:
You will need a multiplexer on the I2C lines to switch devices. You can't use the same bus as although nothing gets sent back an I2C device will acknolwage the end of the byte by pulling down the data line. If you have two devices doing that you will exceed the permitted current even if by some fluke it does work.
So my question is how do you draw too much current on an open collector signal that is never driven?