Hmmm - I2C VS SPI

I've used I2C with a small RTC i bought, works fine.

But, i've been looking at SPI lately as it's a bit more involved but also a lot faster, so i've been learning the ins and outs, MOSI MISO Clock etc... and I'm starting to get the hang of it lol...

I don't understand the "addressable" side, if each IC that supports I2C or something that has an address (to tell it who you're talking to on the BUS line) - surely you're going to run out of addresses right? for example who decides the value to begin with and what if another company who makes chips also use the same address?

or 2 devices with the same address ID on the same line? what happens then?

There seems to be a convention amongst manufacturers so far that dissimilar products use different addresses. But yes, there are only 119 available (1 to 119). Two devices cannot share the same address on one bus. You might have to use a I2C multiplexor or something like that if you had two that did.

I don't know about SPI being "a lot" faster. If you increase I2C to the maximum you get about 40,000 bytes per second, but with SPI you can get around 333,000 bytes per second. So yes, about 8 times as fast.

http://www.gammon.com.au/forum/?id=10918

But with SPI you have to have a slave select line for each one, so you will run of of slave select lines faster than you will run out of I2C addresses.

True True... But you answered my questions mucho gracias senor :)

De nada.