3
\$\begingroup\$

I'm trying to convert a digital signal which, when high, is a bit less than 3 V, to an equivalent signal where the high is 5 V. I have at my disposal the signal wire, a ground wire, and a 5 V wire. This signal runs at around 2.5 MHz.

I know there are a few different ways I could do this. For example, in this question: What's wrong with this single-transistor level-shifter? There is a circuit involving 3 resistors and 2 transistors which I think would work perfectly. However, I'm interested in finding a solution that uses the fewest number of extra components. Ideally, it would be great if I could find a single IC that does what I need. Does such a beast exist?

\$\endgroup\$
6
  • 2
    \$\begingroup\$ Yes, such devices exist. However, recommending a specific one is off-topic for this site. You might want to search for a "level translator" at your favorite distributor's site. \$\endgroup\$ Commented Sep 8, 2021 at 23:19
  • 1
    \$\begingroup\$ I remember at my first job, before I knew about level translator ICs, designing a PCB with several transistor based level shifters. I thought my mentor would be impressed with my application of discrete transistors, but instead he took one look at it and asked, “why didn’t you just use a level translator IC?” It was a good lesson to always look for an IC that does what you want before you go on reinventing the wheel. \$\endgroup\$
    – Ryan
    Commented Sep 9, 2021 at 2:24
  • 1
    \$\begingroup\$ Standard logic ICs can do that. Just do a search on this site for questions on level conversion and there's dozens of questions that although worded differectly, are asking basically the same thing, maybe even asking why a certain way to do it won't work depending on what purpose the signal is used. \$\endgroup\$
    – Justme
    Commented Sep 9, 2021 at 4:53
  • \$\begingroup\$ Google 3.3v 5v tolerant buffer. You want a buffer (or other logic gate) that runs off of 5v but is compatible with 3.3v input. \$\endgroup\$ Commented Sep 9, 2021 at 7:01
  • 2
    \$\begingroup\$ What is the input device that needs a 5 volt signal? You may already find that it will work quite happily with a 3 volt level. \$\endgroup\$
    – Andy aka
    Commented Sep 9, 2021 at 7:30

2 Answers 2

3
\$\begingroup\$

The schematic you linked to is an "emitter follower", whose output is always 0.7V lower than its input, so it can't be used to produce a 5V signal from 3.3V. The alternative (still using a single transistor) would be a "common-emitter" configuration, which is able to produce 5V and 0V from a 0V and 3.3V input, but it also inverts the logic level, which may not be what you want.

There are many ICs that do what you ask. Here are a couple designed for this very purpose:

The most overlooked option (in my opinion), though, is the use of 74HCT logic ICs. These CMOS devices can be powered from 5V, thereby having outputs which are 0V or 5V logic signals, but their inputs are designed to be compatible with the outputs from older 74LS TTL technology. Interestingly, TTL outputs are guaranteed to be at least 2.4V for logic high, and this is the threshold that the 74HCT devices are designed operate with, which happens to be perfect for 3.3V logic signals too.

In other words, a simple 74HCT08 (4 AND gates) or 74HCT32 (4 OR gates) can do what you need (as could many 74HCT ICs), and have the advantage of being:

  1. Cheap
  2. Modern
  3. Readily available
  4. Very fast
  5. Also compatible with regular CMOS outputs
  6. Usable in any logic circuit powered from 2V to 6V

They are really good jelly-bean parts for your workshop.

Oh, I nearly forgot, if you have noisy or slow slewing inputs, the tool for the job is the 74HCT132. This consists of 4 schmitt trigger input NAND gates. This is one of my favourite devices, and I use them a lot. Even a plumber should have a couple of these in his tool box.

\$\endgroup\$
1
  • \$\begingroup\$ Thanks for this detailed answer! \$\endgroup\$ Commented Sep 10, 2021 at 1:37
1
\$\begingroup\$

That level shifter won't work for you -- VOUT = VIN-0.7 V.

If you can invert the signal, then use an NPN: E = GND; C = 1k to 5 V; B = 10k to the input. The output is the collector. This is 1 NPN + 2 resistors.

If you can't invert, then use an NPN: B = 10k to +5 V and 8.2k to GND (10k would do); E = input directly; C = 1k to +5 V. This is 1 NPN + 3 resistors.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.