Re: Favorite 3V / 5V interfacing technique?

"H" schrieb im Newsbeitrag news: snipped-for-privacy@news-server.san.rr.com...

Hi. > > I'm working on a microcontroller app. An SPI peripheral only works at > 3.3V while the micro only wants 5V. This SPI has to be bi-directional. > > I'm trying to figure out a cost effective way of interfacing the two. > Micro's SPI pins are not open-drain. Trying to make it power efficient, > this is battery powered. > > Most simple level translators are NPNs, but that ends up with voltage > inversion...maybe mess with CPHA and CPOL? > > Voltage divider on 5V micro output and use a blocking diode + pull-up to > go from 3.3V to 5V? SPI needs to run at 1 MBit+. > > Ideas? > > H.

Straight forward (and maybe boring) solution:

Use 3/4 74AHC125 or VHC125 (VCC connected to 3,3V) to translate levels for spice,spiclk,spimosi. These chips allow higher input levels as their VCC:

formatting link

Use a single gate HCT125 (VCC connected to 5V) buffer for spimiso.

formatting link

MIKE

Reply to
M.Randelzhofer
Loading thread data ...

If You will use divider ( resistors 18k and 33k) it will work but the shape of signal could be too flat for such speed (1Mbit). I'm using that for speed about 250 Kbps (an it works). For transmission 3,3V->5V signal is high enough (for most cases everything higher than 2,1V is known as '1').

Good luck, Dominik

Reply to
Dominik Domanski

Hi,

I am using such circuit. Baudrate is approx 1.7M and it uses transistor. I am 1's complementing the byte as and when it is received. Also sending the 1's complement to the peripheral.

Regards, Mehta

Reply to
SSM

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.