1.8v to 5v logic level converter *solved*

I have an ARM platform with a 1.8v UART and I want to connect my Arduino to it, but I'm afraid of ruining it. I heard about using logic level converters but surprisingly many of the sources recommending this don't have a particular model to recommend, and I can't find any that work at a 1.8v to 5v range.

I'm open to using transistors and resistors to get the job done (I have a resistor that'll do the trick) but I can't figure out how to use a transistor to amplify the 1.8v TX signal to 5v. I know how to use a transistor for something that has an input pin and an output/ground, but I don't know how to use one for something that's basically a direct shot, and I'm afraid of ruining something.

I'm sure this is a stupid question to ask but after an hour or two of searching I can't seem to get a complete answer anywhere.

Try one of these http://www.ftdichip.com/Products/Cables/USBTTLSerial.htm
This one TTL-232RG-VREG1V8-WE

How about TXB0102?

1.8V Vcc on one side, 5V on the other.

I'm looking to avoid USB, so the TTL-232RG-VREG1V8-WE won't work for me. The TXB0102 looks nice but is there a breakout board or a DIP version of it? Also, while I didn't read it very thoroughly, it the datasheet doesn't explicitly say whether you can do 1.8v to 5v. I get the impression that many of these logic converters work in increments (so for example 1.8 to 3.3, then 3.3 to 5) but like I said in my OP, I can't seem to get a complete, definite answer. Also, are the data pins bi-directional?

"This allows for universal low-voltage bidirectional translation between any of the 1.2-V, 1.5-V, 1.8-V, 2.5-V, 3.3-V, and 5-V voltage nodes."

"The TXB0102 architecture (see Figure 2) does not require a direction-control signal to control the direction of
data flow from A to B or from B to A."

You can get a breakout board for any part. Check dipmicro.com, e-bay, whatever your favorite source is.

Hi!

I had a similar question a couple of days ago how to convert a 2.65v signal to 5v with transistors.
I ended up using 2*NPN transistors and it worked fine (serial communication)

Breakout board for TXB0108.

olof_n:
Hi!

I had a similar question a couple of days ago how to convert a 2.65v signal to 5v with transistors.
I ended up using 2*NPN transistors and it worked fine (serial communication)

Hmm interesting. I'm going to have to try that before I buy anything TXB010* related.

Just wondering though, but why is R6 necessary? Why not simply just use R5 and increase the ohms?

@lemming
I saw that later last night and might consider it. It's a little overkill but at least I don't have to worry about making a mistake.

Hi!

R5 and R6 are a voltage divider.
In this case the output voltage is 3.33V if the input is 5V.

Vout = (R6 / R5 + R6) * VIN

3.33 = (2 / (1+2)) * 5

schmidtbag:
Just wondering though, but why is R6 necessary? Why not simply just use R5 and increase the ohms?

To make it switch fast - the divider circuit has a significantly lower impedance than just a high-value
series resistor - the 2k + 2k divider has an impedance of 1k, whereas using a 10k series resistor
would be 10k. Every input has a few pF of input capacitance and the lower source impedance will drive
that capacitance faster, might make the difference between a 20MHz top frequency and 5MHz,
something like that.

Thanks for the replies everyone, and sorry about the late reply - I haven't had much time to work on this until now.

The unidirectional output diagram olof_n showed seems to work fine but it revolves around a 3.3v source - mine is 1.8v. The transistor I'm using is the 2222A. What do I need to change to make it accept the 1.8v source? I tried removing the resistor between the odroid TX and the T1 base, but it didn't seem to make a difference.

The receiving end works fine, I just used 1.1k and 2.2k resistors instead of the 1k and 2k, I switched their positions, and now I seem to get approximately 1.8v. I have an analog multimeter so I'm not sure how far off from 1.8 I really am but the odroid didn't blow up knock on wood and it's receiving data.

schmidtbag:
The unidirectional output diagram olof_n showed seems to work fine but it revolves around a 3.3v source - mine is 1.8v. The transistor I'm using is the 2222A. What do I need to change to make it accept the 1.8v source?

No "1.8V" modifications necessary (exc., perhaps a somewhat lower value for R1?)
I don't see R3 as necessary, T2_B could go directly to junction of T1_C & R2.
I'd consider adding a pulldown on the input (with a >= 22K from T1_B to Gnd.)

schmidtbag:
I tried removing the resistor between the odroid TX and the T1 base, but it didn't seem to make a difference.

So, I guess you tried that out and "no joy". Perhaps a wiring error?
Don't remove resistors recklessly.

I added a 27K from T1_B to gnd and it seemed to make the problem worse. Before, simply nothing was happening, but now on odroid when I run "cat /dev/zero > /dev/ttySAC1", it claims there's an I/O error and stops. However, it doesn't fail if I unplug the wire at T2_C.

I quadruple checked everything. Like I said, it seems to work but only if the voltage is high enough. If I try putting the 3.3v source from the arduino at the T1_B and then use the multimeter to check T2_C, the output is about 5v. As a side note, when doing that (in the current setup), I've noticed T1_B is only getting about 1.5v. Seems like a lot of resistance over there.

You are doing like so:

?

Yes, that is how I have it set up. But the picture you supplied confuses me a little. T1 and T2 are NPN, but the transistor you showed me in the picture is, if I'm not mistaken, PNP:

schmidtbag:
T1 and T2 are NPN,...

Yes.

schmidtbag:
...but the transistor you showed me in the picture is, if I'm not mistaken, PNP:
http://3.bp.blogspot.com/-iTo2cABnytE/UAmCx3gD34I/AAAAAAAAFBc/_xjB__ClEuI/s1600/NPNvsPNP.png

No, Sir!
I added the inset, with the leads labelled, but the schematic's symbols remained unchanged.
http://www.jameco.com/Jameco/Products/ProdDS/178511.pdf

A test:
Disconnect "the circuit" from the RPi.
If you put the input resistor to +5 then T1's collector should be Gnd/0V and T2's collector should be +5.
If you put the input resistor to Gnd then T1's collector should be +5 and T2's collector should be Gnd/0V.

If you have access to the RPi's "1.8V", do the same using that instead +5 for the input.

I hope we have the Grounds in common: the RPi's goes to the circuit's goes to the TTL device's. Please confirm.

what's the point of the 2nd transistor?

except increasing propergation time?

cjdelphi:
what's the point of the 2nd transistor?
except increasing propergation time?

T1 and T2 are both inverters.
A --> /A --> A

So here's what's going on at this point:

Apparently I had the transistors in backwards, not much of a surprise since I'm pretty terrible with electronics. Anyways, it seems to have a better end result but it's not the end result I'm looking for. The situation is if I replace the odroid TX with the 1.8v source (also from the odroid), T2_C shows the 5v as it should - I didn't get that far before with the transistors in backwards. However, doing this seems to make the odroid crash, as though it's draining all of it's power just for this serial port. I am running the system in a lower power rating than recommended, but I currently have no display, no USB devices, or processor intensive tasks running. When using the actual TX pin from odroid, the arduino doesn't seem to read it but the multimeter seems to show results.

The "odroid" is what's represented as the RPi ?

You may benefit from a couple of new transistors.
Tried that yet?

Please confirm.