Author Topic: Adjustable voltage bidirectional level shifter  (Read 5693 times)

0 Members and 1 Guest are viewing this topic.

Offline leonerdTopic starter

  • Regular Contributor
  • *
  • Posts: 167
  • Country: gb
Adjustable voltage bidirectional level shifter
« on: November 02, 2015, 02:00:22 pm »
I'm looking at building a device around an FT232H chip, to act as a computer-programmable IO source (GPIOs plus SPI/I²C/JTAG). The FT232H has 3.3V logic, but for flexibility I want the eventual device I make to have switchable 5/3.3/2.5V (and maybe 1.8V as well).

What are my options for a bidirectional level shifter here? I have a breakout board with a TXB0108 onboard, which looks almost ideal for the task - the A port supports 1.2V to 3.6V, the B port supports 1.2V to 5V. Great. My plan was to attach the A port to the FT232H chip and use the B port as the device's IO lines, giving it some controllable voltage on VccB.

Except - there's one problem: the chip requires that VccB be no lower than VccA. This would be fine for doing 5V or 3.3V output, but would mean I can't drop it down to 2.5V (or 1.8V) on the B port side, because the A port has 3.3V.

Aside from this one small snag, this chip looks ideal for me - it's automatically bidirectional using push/pull drivers, in a nice way that avoids having to preprogram the direction per line. It doesn't work so well for I²C and the line pullups, but I can buffer around that myself anyway.

Does anyone know of a similar chip with these properties, but lacking the voltage comparison? I want a single chip that could shift levels either up or down depending on voltages supplied to it, and didn't have this restriction.
 

Offline leonerdTopic starter

  • Regular Contributor
  • *
  • Posts: 167
  • Country: gb
Re: Adjustable voltage bidirectional level shifter
« Reply #1 on: November 02, 2015, 02:30:32 pm »
One particularly hideous thought occurs to me - I could just use two levelshifters. Shift the 3.3V from the FT232H chip up to a fixed 5V, then optionally apply a second shifter to bring that down to 3.3V/2.5V/1.8V, or else leave it at 5V. It does quite massively complicate my IO frontend though.
 

Offline jt

  • Regular Contributor
  • *
  • Posts: 91
Re: Adjustable voltage bidirectional level shifter
« Reply #2 on: November 09, 2015, 05:12:47 pm »
Having gone down this path myself, I've found the FXMA2102L8X is an ideal solution for I2C. 
https://www.fairchildsemi.com/datasheets/FX/FXMA2102.pdf

Either supply can be 1.65-5.5V; or if one side of the chip is unpowered, it will power isolate.  There is no restriction on the power-up/down sequence.  It will also capacitively isolate, extending the distance you can route the I2C.

Package size may be a downside depending on your application.  I wish they came in larger, easier to solder packages for my lower density boards.

 

 

Offline miguelvp

  • Super Contributor
  • ***
  • Posts: 5550
  • Country: us
Re: Adjustable voltage bidirectional level shifter
« Reply #3 on: November 09, 2015, 06:40:12 pm »
I recently posted this in another thread, but it seems the OP in there required just unidirectional level shifting. But it does apply to your needs, except the variable voltage that might need a variable resistor  for this to work:

There is an app note from Phillips for I2C level shifting using a MOSFET.

The following site has an example and a link to the old appnote, there is a newer updated appnote from NXP
https://sites.google.com/site/fpgaandco/level-shifting-i2c

Old Phillips app note 97055:
https://www.adafruit.com/datasheets/an97055.pdf

Newer NXP ones:
http://www.nxp.com/documents/application_note/AN10441.pdf
http://www.nxp.com/documents/application_note/AN10418.pdf

One of those might be a rewrite of the original one, didn't open the files since I'm on my tablet right now.

What transmission speed are you aiming for on the UART? because I think this is limited to around 400Kbps but not sure.
« Last Edit: November 09, 2015, 06:42:12 pm by miguelvp »
 

Offline leonerdTopic starter

  • Regular Contributor
  • *
  • Posts: 167
  • Country: gb
Re: Adjustable voltage bidirectional level shifter
« Reply #4 on: November 12, 2015, 06:51:46 pm »
Having gone down this path myself, I've found the FXMA2102L8X is an ideal solution for I2C. 
https://www.fairchildsemi.com/datasheets/FX/FXMA2102.pdf

Either supply can be 1.65-5.5V; or if one side of the chip is unpowered, it will power isolate.  There is no restriction on the power-up/down sequence.  It will also capacitively isolate, extending the distance you can route the I2C.

That looks a useful one for I²C though quite specialised for that case; doesn't seem like it would do very well for other kinds of IO lines.

Package size may be a downside depending on your application.  I wish they came in larger, easier to solder packages for my lower density boards.

Mmm... I usually do 0603, SOIC and occasional QFP sizes, that looks like it could be fun indeed... :) Maybe someone makes a little breakout board with it on.
 

Offline leonerdTopic starter

  • Regular Contributor
  • *
  • Posts: 167
  • Country: gb
Re: Adjustable voltage bidirectional level shifter
« Reply #5 on: November 12, 2015, 06:54:21 pm »
I recently posted this in another thread, but it seems the OP in there required just unidirectional level shifting. But it does apply to your needs, except the variable voltage that might need a variable resistor  for this to work:

...

All four of those again look to be I²C isolators. Those are all open-drain on both sides, effectively, and require some kind of pullup resistor. I don't know how well that would work in non-I²C cases, such as SPI or other GPIOs.

What transmission speed are you aiming for on the UART? because I think this is limited to around 400Kbps but not sure.

I was hoping I could get up to around 20MHz or so - given as the FT232H itself can theoretically clock out SPI at 30Mbit/sec I feel if I can not slow it down in my shifting/isolation frontend that'd be lovely. Though in practice if I found a solution that was otherwise-nice but limited me to 5 or 10Mbit/sec I wouldn't lose sleep over it. 400k is a bit slow though.
 

Offline jt

  • Regular Contributor
  • *
  • Posts: 91
Re: Adjustable voltage bidirectional level shifter
« Reply #6 on: November 13, 2015, 05:10:22 am »
Quote
That looks a useful one for I²C though quite specialised for that case; doesn't seem like it would do very well for other kinds of IO lines.

Yes, I would only use the FXMA2102L8X for your I2C bus (you listed it as one of your computer-programmable IO sources).  For the other lines I would use uni-directional buffers.  The bidirectional buffers can be pretty temperamental in my experience so I avoid them unless the buss requires it.  If you are hand soldering this might be a no-go; certainly doable with patience and practice and the right tools though. 

You might consider the SN74LVC1T45 as unidirectional options (you'll need to use one or more components for one direction and one or more for the other direction).  These level convert, power isolate and buffer.  I've had a hard time finding a device with more channels that can operate at 5V (lots of options for 3.3).  If someone can suggest a good multi-channel option I would be grateful for the lead. 

Edit:  Adding SN74LVC1T45 datasheet link:
http://www.ti.com/lit/ds/symlink/sn74lvc1t45.pdf
« Last Edit: November 13, 2015, 05:15:09 am by jt »
 

Offline leonerdTopic starter

  • Regular Contributor
  • *
  • Posts: 167
  • Country: gb
Re: Adjustable voltage bidirectional level shifter
« Reply #7 on: November 16, 2015, 05:20:07 pm »
You might consider the SN74LVC1T45 as unidirectional options (you'll need to use one or more components for one direction and one or more for the other direction).  These level convert, power isolate and buffer.  I've had a hard time finding a device with more channels that can operate at 5V (lots of options for 3.3).  If someone can suggest a good multi-channel option I would be grateful for the lead. 

I'm aware of the various 74-series unidirectional level shifters. They won't really work here. What I have is just a bunch of GPIO pins. I don't know in advance whether the application will program them into output or input mode. Some might even swap and change dynamically during the test time. That's why I liked the look of the TXB0108 - you don't need to know. It contains a symmetric arrangement of two back-to-back connected bus keeper interfaces, so it can cope with changes in either direction. It only has a problem with the relative levels of Vcc, but I feel a better chip internal architecture with bus keeper IOs could solve that. I was wondering if anyone would know of such a device.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf