1
\$\begingroup\$

I'm trying to create an interface PCB to a 32 channel USB GPIO device which has 3.3v IO, and I want the flexibility to use 1.8, 3.3 or 5v - across all pins, or at most in 2x banks of 16 - I don't need different voltages on a per-pin basis.

Speed-wise I'd be looking for at most 1MHz switching frequency, but as low as 200kHz would probably be fine.

When searching through Farnell (UK version) I've found lots of 16-channel level shifters that are technically bi-directional, but only with a switchable direction using a DIR pin handling an 8 channel bank. I need something that will give true bi-directionality on each pin without having to set the direction.

As an example, what I currently use for level shifting is this SparkFun board: SparkFun Logic Level Converter - Bi-Directional but this requires a 'low' side and a 'high' side. I suppose I could shift everything to 5v and then back down to 3.3v, but I'd prefer a simpler packaged solution.

Is there some terminology I'm missing that would help me narrow down my search to find what I need? If it even exists, that is.

\$\endgroup\$
  • \$\begingroup\$ @Bort I think the issue is he may need to shift up (from 1.8 V) or shift down (from 5V) depending on the application, so he won't know which side is the high and low. \$\endgroup\$ – Jim Feb 14 at 21:49
  • \$\begingroup\$ @Bort yea, the external voltage he has to interface with may be variable, I think. \$\endgroup\$ – Jim Feb 14 at 21:53
  • 1
    \$\begingroup\$ I get it now, the issue is that the external voltage may be higher OR lower than 3.3V, not that the shifter has two levels. Durp. \$\endgroup\$ – Bort Feb 14 at 21:53
1
\$\begingroup\$

There are bidirectional level shifters with automatic direction sensing, but that ability requires compromises in other electrical parameters.

There are two widespread architectures for automatic direction sensing:

  • TI's TXB010x (and equivalent chips from other manufacturers) have the outputs in both directions active at all times:

    TXB architecture
    source: A Guide to Voltage Translation With TXB-Type Translators

    The output drivers have a high impedance to allow other devices to override the voltage level. This means that those other devices need to have enough drive strength (at least 2 mA), and that the TXB's outputs have a very low drive strength (only 20 µA guaranteed).

  • TI's TXS010x (and equivalent chips from other manufacturers) use passive switches to pass low voltage levels, and rely on pull-up resistors to generate high voltage levels:

    TXS architecture
    source: A Guide to Voltage Translation With TXS-Type Translators

    For a low signal, other devices must have enough drive strength to sink the current from the pull-up resistors and to drive the input(s) on the other side of the translator. A high signal is generated by the pullups.

    There are level translators based on discrete MOSFETs; their architecture is essentially the same (without the one-shot edge accelerators).

TXB-type translators are appropriate only when connecting directly to CMOS outputs and inputs; pull-up/-down resistors will not work (except when extremely weak), neither will any load, such as a LED.
TXS-type translators are appropriate only when an open-drain signal is possible.

In the general case, you should use unidirectional or direction-controlled (with DIR) translators, if possible. (And for the same reasons, most GPIO pins are designed so that they must be explicitly configured as input or output.)

\$\endgroup\$
  • \$\begingroup\$ I'm accepting this as the answer as it's a very good explanation of why what I was aiming for, a 'one size fits all' solution, isn't really practical. I think I'll need to go back to the drawing board and perhaps have separate plug in modules that adapt the GPIOs to particular use cases, and those can then have unidirectional level shifting. \$\endgroup\$ – PeterBelm Feb 14 at 23:26
0
\$\begingroup\$

The TXB0102 is a good bidirectional level shifter that can take multiple voltages and automatically determines the direction. (the Vcc determines the switching and the B side needs to be higher voltage than the A side if I remember right). enter image description here enter image description here

\$\endgroup\$
  • \$\begingroup\$ Be very careful using parts like these, not all outputs have the drive to reliably switch the direction. Voice of experience.. \$\endgroup\$ – Spehro Pefhany Feb 14 at 22:11
  • \$\begingroup\$ You need to have at least 3mA of current for switching from the source \$\endgroup\$ – Voltage Spike Feb 14 at 22:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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