logic level converters and rpi etc

Thread Starter

pibeans

Joined Jan 11, 2013
3
First post - and hope its in the right place.

I am newly returned to electronics having been re-enthused by the r-pi and at the same time discovering the arduinos.

I understand the need to do logic level conversion from the RPI's 3.3v GPIO to most real projects.

Am I right in thinking I just need to do this on the data & clock (and chip-select) lines of the I2C or SPI assuming I am using either of these to talk to the rest of the project?

TIA / pibeans
 

ErnieM

Joined Apr 24, 2011
8,377
I've basically come to the conclusion a year or two ago that in complex microcontrollers there was a paradigm shift away from the fixed 5 volt supply to somewhere around 3.3 volts.

The trick today is to look for the other parts to have a compatible supply voltage: my current project's I2C runs at 3.3 cause all the chips do.

5 volts isn't going away, and there are several techniques to handle the transition, from just a simple resistor* to voltage level translating IC's such as a 3.3 to 5V I2C translator I once needed: yet, it translates signals in both directions.

Exactly what needs to be translated needs to be handled on a case by case basis.

* If your device has 5V tolerant I/O pins you can use a pull-up resistor to get a 5V high by making that pin an input, then make it an output set to 0 for a low output.
 
Last edited:

Thread Starter

pibeans

Joined Jan 11, 2013
3
Thanks

I've already built several PI GPIO projects with I2C and SPI with ADCs and expanders in both flavours - but everything so far at 3.3v.

I now need to start mixing in some 5v devices. So I've ordered up a couple of 4ch bi-dir converters that do both I2C and SPI.

I see the need now to cover all lines.

Pibeans
 
Top