element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Single-Board Computers
  • Products
  • Dev Tools
  • Single-Board Computers
  • More
  • Cancel
Single-Board Computers
Forum 5V UARTs on SBCs?
  • Blog
  • Forum
  • Documents
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Single-Board Computers to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • Replies 28 replies
  • Subscribers 60 subscribers
  • Views 2876 views
  • Users 0 members are here
  • uart-to-usb
  • noftdi
  • uart
  • no-ftdi
  • usb-to-uart
Related

5V UARTs on SBCs?

shabaz
shabaz over 9 years ago

Hi!

I'm thinking of turning this project into a PCB:

Building a USB UART Serial Adapter

 

As part of that, I thought a few bits of functionality could be added at low cost:

(a) an MSP430 programmer

(b) perhaps a voltage monitoring capability since there is an ADC on the MCP2221

 

However, I wanted it to be a super-simple project. The current project uses jumpers to select 5V or 3.3V logic level UARTs. One solution could be

a switch, but it would be nice to not have a switch either.

To eliminate that, I'm thinking of making the Rx pin 5V tolerant, but leave the Tx pin at 3.3V logic levels. This should therefore be compatible with any boards

that use 3.3V levels, but also the 5V Arduino Uno (it should be fine with 3.3V logic level input according to the ATmega datasheet).

(I'll also make it somewhat tolerant to accidentally swapping round of Rx and Tx).

 

My question is, does anyone know, are there any popular 5V boards that would not be OK with 3.3V logic level?

 

(I know now there are 1.8V boards too, like the Odroids, but that is a complication too far, so this board will only handle 3.3V and have the tolerance for 5V).

 

Thanks!

  • Sign in to reply
  • Cancel

Top Replies

  • rachaelp
    rachaelp over 9 years ago +3
    You can get bi-directional level translator IC's that will run either side from differing voltages. You could use one of these with one side powered from your circuit and the other side either powered…
  • jc2048
    jc2048 over 9 years ago in reply to shabaz +3
    It's not "totally insane", it just falls in that grey area between hacking and good design. Reverse biassed diodes are a very common way to protect the input/output from ESD [electro-static discharge]…
  • dougw
    dougw over 9 years ago in reply to shabaz +2
    Lets see - if going through hole is like going from touch screen back to pushbutton then wire-wrap must be like rotary dial. (point-to-point wiring would be like switchboard phoning?)
Parents
  • rachaelp
    rachaelp over 9 years ago

    You can get bi-directional level translator IC's that will run either side from differing voltages. You could use one of these with one side powered from your circuit and the other side either powered by or have it's voltage slaved to the target boards power. This will give a wide voltage range of operation without having to manually switch anything and it's just one simple IC so very simple to implement.

     

    Best Regards,


    Rachael

    • Cancel
    • Vote Up +3 Vote Down
    • Sign in to reply
    • Cancel
  • shabaz
    shabaz over 9 years ago in reply to rachaelp

    Hi Rachael!

     

    I should have mentioned but I forgot, the plan is an entirely through-hole project, and most of the level translators are SMD except for the large LVC244/245. I'm still open to doing it that way (I have an FTDI cable which too requires connecting to the supply so that it can figure out the logic levels) but I'm wondering if it can be avoided nowadays since modern microcontrollers/SBCs seem to have 3.3V logic tolerant inputs even if they are running at 5V. I still need to figure out some trick for the 1.8V SBCs though : ( Possibly relying on the fact that the baud rate won't be higher than 115200 (that is the limit of the MCP2221) and limiting current a lot at the expense of waveform shape). I don't know if there would be long-term damage, I need to go some calculations.

    It would also save the headache of double-checking it is connected to the right level, e.g. the Odroid U3 is 1.8V serial, whereas the Odroid C1 is 3.3V, etc.

    Maybe it's not possible though..

     

    As for the input side to the project, that will be easier, a couple of BJTs to provide the high voltage tolerance into the MCP2221.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • rachaelp
    rachaelp over 9 years ago in reply to shabaz

    Ah, through hole! Yes I haven't done anything that was entirely through hole for so long I forget that lots of things I take for granted in SMT aren't available! I've just done some searching and limiting my results to through hole and it really does make for quite a challenge. I think it probably makes you have to be more inventive to find ways around the limitations of what is available.

     

    So with that in mind, I have spent a few mins searching and haven't done any real in depth analysis of whether this would work but.... ignoring it says I2C in the datasheet title, if you read further I think it can be used for generic logic signals (I have never used this part, I just found it on Digikey) how about this as a possible level translation device?

     

    http://www.ixysic.com/home/pdfs.nsf/www/CPC5902.pdf/$file/CPC5902.pdf

     

    It's through hole and two channels so I think should work for your UART so long as you are only using TX/RX although you could use additional devices for other UART signals and your speed is within the I2C limits of 400KHz so that shouldn't be an issue. It only goes down to 2.7V but it's likely easier to make a 2.7V output work with 1.8V logic.

     

    Best Regards,


    Rachael

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • shabaz
    shabaz over 9 years ago in reply to rachaelp

    Going through-hole these days feels a lot like going to a burger place and seeking vegetarian dishes : )

    Interesting find, I'd not seen this part before.. I'll have to read up and experiment a bit, hopefully this weekend.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • mcb1
    mcb1 over 9 years ago in reply to shabaz

    going to a burger place and seeking vegetarian dishes : )

    And nothing that a good steak wouldn't fix (as I keep telling my son)

     

    A quick search came up with this

    Arduino Playground - I2CBi-directionalLevelShifter

    https://www.intersil.com/content/dam/Intersil/documents/an16/an1637.pdf

     

    I know the fet version should be fast enough.

     

    Mark

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • dougw
    dougw over 9 years ago in reply to shabaz

    Lets see - if going through hole is like going from touch screen back to pushbutton then wire-wrap must be like rotary dial. (point-to-point wiring would be like switchboard phoning?)

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Cancel
  • shabaz
    shabaz over 9 years ago in reply to dougw

    Lol. Speaking of rotary dial I still have some phones like that : ) They are too beautiful outside and inside to throw out. Just a shame they are so impractical to use now, dialing so many digits..

    We saw so much interesting vintage technology at Bletchley and the Computer Museum when mcb1 was around. It was a lot of fun. If you ever visit the UK it would be great to arrange a trip, especially if Mark could re-visit too! I'm fairly sure we could spend weeks there and not get bored..

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • mcb1
    mcb1 over 9 years ago in reply to shabaz

    I'm fairly certain we could find lots to look at.

     

    I once saw this use for a rotary phone.

    https://www.sparkfun.com/tutorials/51

     

    Brilliant idea.

    I'm tempted to make one into a cordless phone around home.

     

     

    Mark

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • dougw
    dougw over 9 years ago in reply to shabaz

    In the town where I grew up our phone number was exactly 3 digits. You could easily remember all the numbers you needed to call - or you could dial a random number and the person answering would know the number you were trying to reach. Phonebook? We are talking pamphlet.

    The sparkfun rotary cell phone concept mentioned by Mark could be smart enough to use the rotary sequence as a 2 or 3 digit speed dial....

    The UK is definitely high on my list of places to visit - more points of interest and higher density of interesting places than just about anywhere on the planet - and I can almost speak the language.

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Cancel
  • gihu
    gihu over 9 years ago in reply to shabaz

    Maybe it would be posible emulate the IC that rachaelp says with two rail-to-rail opamp like MCP6041 comparator, and voltage dividers with resistors.

    I am searching, but the only compators working from 1V8 that I have found,are SMD image, too slow, or both.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • rachaelp
    rachaelp over 9 years ago in reply to gihu

    Can I ask why you would want to emulate the IC rather than just use the one that's available? Is this to try and get down to proper 1V8 operation? The other advantage of the one I linked to is it's opto-isolated and so provides for potentially quite a robust interface for something that will likely be plugged into many different boards.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Reply
  • rachaelp
    rachaelp over 9 years ago in reply to gihu

    Can I ask why you would want to emulate the IC rather than just use the one that's available? Is this to try and get down to proper 1V8 operation? The other advantage of the one I linked to is it's opto-isolated and so provides for potentially quite a robust interface for something that will likely be plugged into many different boards.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Children
  • shabaz
    shabaz over 9 years ago in reply to rachaelp

    Agree, the opto-isolation is cool. Just as a side note, not related to what I'll implement, but just wanted to share what I'd found kind-of related to gihu's suggestion, I was browsing op-amp circuits and found this really unusual one for bidirectional capability, based on positive feedback (PDF doc) http://www.ti.com/lit/an/slaa148/slaa148.pdf

    page  14.

     

    Cool thing is in an SMD circuit where just a single line needs it, you could do it with a SOT23-5 or whatever.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • gihu
    gihu over 9 years ago in reply to rachaelp

    Dedicated IC are easier and faster to implement, I just wanted to suggest shabaz an alternative in case not finding one which fits all his expectations.

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube