EEVblog Electronics Community Forum
Electronics => Projects, Designs, and Technical Stuff => Topic started by: prasimix on July 19, 2015, 11:06:22 am
-
I made a short investigation about level shifting that I'll require in my project. I found interesting discussion in thread: A question about logic level shifting, 74LVC74, and 74HC(T) vs 74AHC(T) (https://www.eevblog.com/forum/projects/a-question-about-logic-level-shifting-74lvc74-and-74hc%28t%29-vs-74ahc%28t%29/) where general 3.3 to 5V and vice versa is covered. I need something on top of that, first here is an block diagram:
(https://i.imgur.com/zGN8DCL.png)
The system is consists of two parts: removable where MCU resides, and fixed with peripherals. MCU could be 3.3 or 5V and peripherals are only 3.3V. In case of 5V MCU a logic shifting/translation is required. But the same translators have to work properly even without translation when 3.3V MCU is connected. So, selected level shifting logic cannot be removed since it's on the fixed part of the system. Only power supply voltage is possible to manipulate.
In general three types of connection is possible: bidirectional, output only and input only. In the next schematic I listed few parts that I hope are usable when 5V MCU is used:
(https://i.imgur.com/I8Tim8h.png)
The SN74LVCC3245A (https://www.ti.com/product/sn74lvcc3245a) that is listed under bidirectional section is currently my favorite since it can be used in all scenarios. Its price also seems reasonable (i.e. Farnell code: 2342537 (http://export.farnell.com/texas-instruments/sn74lvcc3245adbr/ic-8bit-bus-transceiver-ssop-24/dp/2342537)). But I also added other devices in one place just as an exercise to see what is possible in each of mentioned scenarios. Things starts to be a little bit challenging when the same translators that ensure level shifting should works transparently in case when 3.3V MCU is used:
(https://i.imgur.com/VV9yrBx.png)
Input only scenario is tricky since in that case it's not possible to use the same devices used for level shifting from 3.3 to 5V. For example HCT instead of HC has to be used to ensure proper level shifting with 5V MCU, but it cannot be used with 3.3V since recommended Vcc is usually in range of 4.5 to 5.5V.
A "rare animal" seems that is MC74VHC1GT50 (https://www.onsemi.com/pub/Collateral/MC74VHC1GT50-D.PDF) that has VHC label but can be used for 3.3 to 5V translation what is not a feature of VHC family. Unfortunately this is single gate (1-bit) device and I need at least 10 of them what does not looks economical. ONsemi has i.e. NLSV and NLSX devices (http://www.onsemi.com/PowerSolutions/parametrics.do?id=649&lctn=header) but they doesn't looks as something generally available.
I put GTL devices only in 5V case for the sake of simplicity but it can be used in 3.3V case (no translation) and hopefully in all scenarios not inputs only. I'm not familiar with such devices and I found only one thread (https://www.eevblog.com/forum/projects/gtl2003-problems-at-higher-fequencies/msg215684/#msg215684[url=http://thread) where GTL2003 is mentioned.
Please let me know about your opinions, suggestions about selected devices and this basic idea how to get configurable solution which can provide reliable communication between 3.3V peripherals and 3.3 or 5V MCU.
-
Take a look at the Texas Instruments TXS0108E level translator. It can do what you require.
-
For low speed (up to 400kb/s) for I2C
Old Philips app note:
http://www.adafruit.com/datasheets/an97055.pdf (http://www.adafruit.com/datasheets/an97055.pdf)
New app note from NXP (formerly Philips) but I think the old one has more information :)
http://www.nxp.com/documents/application_note/AN10441.pdf (http://www.nxp.com/documents/application_note/AN10441.pdf)
So I guess it depends on what protocol are you using for your peripherals.
I guess you could get this cheap board to test (only 4 channels)
http://www.adafruit.com/products/757 (http://www.adafruit.com/products/757)
-
There is a whole web page or website entirely dedicated to logic level translation - check it out:
http://www.interfacebus.com/Design_Translation.html#h (http://www.interfacebus.com/Design_Translation.html#h)
-
Just to note that the Phillips app note is for bidirectional signals without the need to specify direction on the signal.
But again, limited depending on what speeds are needed.
-
Thanks everyone for your inputs. Regarding application notes I found particularly interesting the TI's Voltage-Level-Translation Devices (http://www.ti.com.cn/cn/lit/an/scea021a/scea021a.pdf). I'm aware of TXS0108E but price-wise it's not so attractive as SN74LVCC3245A.
EDIT: Something that I missed to mention initially is the speed: I need parallel and SPI data transfer (so it's more in range of MHz then hundred of KHz like in case od I2C).