Go Down

Topic: Interfacing 3.3v CMOS and 5v TTL (Read 4393 times) previous topic - next topic

emyr666

Hi,
I have an Arduino Mega 2560 and I've got a Nokia 6100 Knock-off LCD screen and an RN41 Bluetooth module.
I'm planning to have the arduino control some motors for a telescope and have a laptop send signals to the arduino telescope controller via bluetooth and to have it display various things on the LCD screen to aid debugging and so on.

I can control both from the arduino using serial communication but my problem is that the i/o pins on the arduino are 5v TTL but the screen & bluetooth are both 3.3v CMOS. A while back I came across an IC that allowed bidirectional communication between the 2 - a kind of buffer /  translator thing, with them both being electrically isolated from each other. Now I come to try to do the programming and electronics I can't seem to find the chip I identified a while back as being what I needed.

I want a single IC solution without having to fiddle with putting in any extra resistors / capacitors etc. Does anyone know of any suitable chips ? Do I need something from the 74HCT family or are there any optocoupler type things that would be better ?

Thanks,

Emyr

johnwasser

Too bad you don't want to use resistors.  That's works for me.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

emyr666

For 5v ->3v yes a simple voltage divider would suffice, but what about going the other way ? Need bidirectional communication.

emyr666

I think this might do it...

http://focus.ti.com/lit/ds/symlink/txb0108.pdf

wayneft

Quote
I think this might do it...

http://focus.ti.com/lit/ds/symlink/txb0108.pdf

If you're going to use this IC make sure your Rx/Tx lines can source at least 2mA or else it won't work.  If they can't source at least 2mA you can switch to the TXS series IC instead as long as your data rate is below 20MHz.
I2C GPS Shield

Checkout my Open Source GPS Tracker on Kickstarter

jluciani

The AHC series has 5V tolerant inputs. These are not isolated.

There should be parts in the series that are bi-directional.

(* jcl *)
www: http://www.wiblocks.com
twitter: http://twitter.com/wiblocks

MarkT

The Arduino can read 3V3 CMOS signals directly, and a resistor divider will work the other way. At 5V supply the 328 recognises low as less than 1.5v and high as more than 3.0v - so its just within spec.
[ I won't respond to messages, use the forum please ]

johnwasser

The case I can see for a bi-directional level shifter would be for a bi-directional signal such as 1-Wire or a shared data bus.

For simple cases, two resistors for 5V->3.3V and nothing for 3.3V->5V.  Two equal resistors of 1K to 10K will work, giving a logic level of 2.5V, but a high-side resistor of 2.2K and a low-side resistor of 3.3K will get 3V, much closer to 3.3V.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

dshay

Resistor dividers work but only up to a certain data rate. For faster data rates it is recommended to use the following type of tranciever device:

The type of device you're thinking of is a 74LVC245

http://focus.ti.com/lit/ds/symlink/sn74lvc245a.pdf



retrolefty


Resistor dividers work but only up to a certain data rate. For faster data rates it is recommended to use the following type of tranciever device:

The type of device you're thinking of is a 74LVC245

http://focus.ti.com/lit/ds/symlink/sn74lvc245a.pdf





I don't necessarily agree with that. A simple two resistor divider would not be speed limited, only if there was a large capacitance associated with the load would there then be a R/C time constant to be concerned about.

My take on voltage divider Vs voltage translator is mostly dependent on the input impedance of the load being driven at the reduced voltage level.

Lefty

dshay

#10
Jun 26, 2011, 10:49 pm Last Edit: Jun 26, 2011, 10:51 pm by dshay Reason: 1



The type of device you're thinking of is a 74LVC245

http://focus.ti.com/lit/ds/symlink/sn74lvc245a.pdf


I don't necessarily agree with that. A simple two resistor divider would not be speed limited, only if there was a large capacitance associated with the load would there then be a R/C time constant to be concerned about.

My take on voltage divider Vs voltage translator is mostly dependent on the input impedance of the load being driven at the reduced voltage level.

Lefty


If you're dealing with your standard 9600 baud resistor divider will not be a problem. Capacitance isn't the only thing going on, your average resistor also has inductance. There is a reason the tranciever I linked has been invented and standardly used. Our original poster also stated a desire to buffer the two circuits.

Original poster, if you want I can also link up some trancievers that do bidirectional with individual directional controls/output enables, as the one I gave you can only do one direction at a time.

retrolefty

#11
Jun 26, 2011, 11:14 pm Last Edit: Jun 26, 2011, 11:15 pm by retrolefty Reason: 1
Quote
Original poster, if you want I can also link up some trancievers that do bidirectional with individual directional controls/output enables, as the one I gave you can only do one direction at a time.


Well at a higher level the OP says he just needs to interface two serial devices, a bluetooth modem and a serial LCD to his arduino, but that the devices were 3.3vdc and an arduino is 5vdc.

As a 3.3vdc signal can be wired to an arduino input pin without modification and two simple voltage dividers can handle both the arduino 5vdc to 3.3vdc pins used for serial output,  I see little reason to spend the costs and board space for voltage translator devices. I run a simple 3.3vdc bluetooth modem at 57,600 baud with no problems using just a divider for the 5v to 3v signal line.

Not saying there is anything wrong with using active voltage translation devices, just that for many applications a simple voltage divider is all that is required. I just suggest that a serial LCD display and a bluetooth modem are two such applications.

Lefty
 

Bryanpl


Do I need something from the 74HCT family or are there any optocoupler type things that would be better ?



I use a 74HC4050 as a 5v to 3.3v translator and it works well.
-=Bryan=-

Go Up