simple microcontroller + level shifter question - Page 1
Forum section: electronics / beginners

author: ultrageek.lloyd
author_rank: Contributor
timestamp: August 09, 2012, 01:22:48 am
content: Hi all,I've got a PIC32 microcontroller port controlling a bus that will be operating at several MHz. It will be connected to a TI SN74AVC8T245 dual supply bus transceiver for level shifting. I'm basing my design somewhat on the Digilent picKIT. It uses 200 ohm resistors on all of the communications ports that are broken out. My question is, should I have resistors between then microcontroller port and the level shifter or not? I can see that being a good thing for current limiting, but wouldn't it drop a certain amount of voltage across the resistor? How does ohm's law apply in this situation?Thanks,ultrageek

author: TerminalJack505
author_rank: Super Contributor
timestamp: August 09, 2012, 02:21:49 am
content: This schematic?If so then those resistors are to limit the current when the diodes are clamping.If you're using the level converter IC then one reason you might want resistors is to prevent you from accidentally configuring the pin as an output and driving too much current through it.Whether this is possible or not depends on your circuit. This could happen, for example, if the SN74AVC8T245 is supposed to be an input to your pins. In this case, your pins should then be inputs. If you screw up and make any of them an output then you could fry the pin and/or part.

author: TerminalJack505
author_rank: Super Contributor
timestamp: August 09, 2012, 02:42:06 am
content: Oh, and to answer your question, yes, those resistors can affect the bandwidth. They will limit theslew rateof the signals. So you most likely want to avoid them.

author: free_electron
author_rank: Super Contributor
timestamp: August 09, 2012, 03:19:49 am
content: Quote from: TerminalJack505 on August 09, 2012, 02:42:06 am200 ohm with the few pF of the diode... Methinks bandwidth is not an issue. That pic can never get in the GHz range...

author: ultrageek.lloyd
author_rank: Contributor
timestamp: August 09, 2012, 10:47:55 am
content: Quote from: TerminalJack505 on August 09, 2012, 02:21:49 amOK, that makes sense. I won't be using the diodes, so that shouldn't matter.Quote from: TerminalJack505 on August 09, 2012, 02:21:49 amThere will be /one/ input. Obviously this situation should never happen, as the ports are configured to be turned off on startup, but it's a possibility if I mess up in my code. I guess I'll stay away from the resistors and just not mess up my codeOne more question, though. Are the PIC's output pins internally current-limited, then? How does the circuit keep it from sourcing too much current to the level-shifter?Thanks for all your help, guysultrageek

author: TerminalJack505
author_rank: Super Contributor
timestamp: August 09, 2012, 04:01:55 pm
content: No, the PIC's output pins aren't current limited. The level shifter's input's are (as are most IC's inputs) high impedance so they will draw only minimal current. (Somewhere on the order of nanoamps.)

author: ultrageek.lloyd
author_rank: Contributor
timestamp: August 09, 2012, 06:41:27 pm
content: Quote from: TerminalJack505 on August 09, 2012, 04:01:55 pmawesome. that's all the information i need for right nowThanks,ultrageek