So I had interfaced a microcontroller (TI CC3200) with a keypad, using a 5V power supply with maximum current rated at 225mA.

enter image description here

Everything worked fine, until I replaced the 5V power supply with a new one that has a bigger maximum current rating of 2A (Same 5V). This immediately burned my chip.

To investigate why this happened, I looked at the datasheet and realized I've made a very simple mistake that I've pulled the input pins to 5V (PORTX[4]-PORTX[7]) on a 3.3v rated microcontroller. VIH and VIL are rated at 0.65 × VDD and VDD + 0.5 V, so no wonder they would burn out.

enter image description here

However, what I don't understand is why the chip didn't burn out on my first power supply, where it was also 5V. Is it because the power supply had a lower maximum current rating? If this is the case, on top of worrying about the VIH and VOH level, do I also need to calculate exactly how much current I need to pull the input pins with based on the value of IIH and IIL? But then if you look at the datasheet, it only shows the nominal values for IIH and IIL, not min/max.

What is the proper way of doing an interface analysis on voltage/current level?

  • \$\begingroup\$ And what kind of voltage did you apply to power rails of CC3200? \$\endgroup\$ Oct 11 '16 at 1:20
  • \$\begingroup\$ @AliChen The CC3200 launchpad is actually connected via USB power to computer, which is rated at 3.3v according to the datasheet. The 5V is supplied separately to a breadboard, which the input pins & keypad was plugged into. \$\endgroup\$
    – Xiagua
    Oct 11 '16 at 1:26
  • \$\begingroup\$ CC3200 stands for TI ARM Cortex-M4 SoC. Which "launchpad" do you mean? \$\endgroup\$ Oct 11 '16 at 1:28
  • \$\begingroup\$ ti.com/tool/cc3200-launchxl This is the development board TI provides that has CC3200 in it \$\endgroup\$
    – Xiagua
    Oct 11 '16 at 1:30
  • \$\begingroup\$ Might be wise to add some series resistors on the inputs to protect against ESD. If you plan to debounce through hardware, that series resistor could be part of the RC filter and serve two purposes at once. \$\endgroup\$
    – Lundin
    Oct 11 '16 at 11:28

I'm surprised that any 5V supply would burn out a 3.3V chip through 10k pull-ups. That would be less than 2mA through the input protection diodes. (I'm assuming the CC3200 has protection diodes -- it would be weird not to.) If the 3.3V supply can't sink current, maybe the voltage on its output capacitor could build up, but I'd expect the regulator to compensate for that. Perhaps the 2A supply behaves differently at power-up.

Regardless, the solution is the same -- don't put 5V on a 3.3V pin! As you can see from the datasheet, digital input currents are in the nanoamp range, so you should (almost) never have to worry about them. All you should have to do is:

  1. Make sure the pull-up voltage is within the VIH range. Normally, you want the pull-up voltage to be the same as the IO voltage (or VDD if they're the same). If the current's low enough, you can use the same supply.

  2. Make sure the pull-up supply can provide enough current when the pulled-up lines are driven low. In your case, that's:

$$I_{supply} = \frac {3.3 \mathrm V} {10 \mathrm{k\Omega} || 10 \mathrm{k\Omega} || 10 \mathrm{k\Omega} || 10 \mathrm{k\Omega}} = \frac {3.3 \mathrm V} {2.5 \mathrm {k\Omega}} = 1.32 \mathrm {mA}$$

  1. Make sure the output pins (PORTx[0-3]) can sink enough current to pull their lines low. This is the \$I_{OL}\$ spec. According to the datasheet, \$I_{OL}\$ is configurable, and the lowest value is 2mA. Each IO only has to handle one pull-up, so:

$$I_{PU} = \frac {3.3 \mathrm V} {10 \mathrm {k\Omega}} = 0.33 \mathrm {mA}$$ $$I_{OL} >= 2 \mathrm{mA}$$ $$I_{PU} < I_{OL}$$

  • \$\begingroup\$ Could it be that the GPIO were configured for 1.8V? \$\endgroup\$ Oct 11 '16 at 1:40
  • \$\begingroup\$ The user's guide for the LaunchPad says the board provides 3.3V. 1.8V would be an odd choice for an evaluation board given how much 3.3V stuff is out there. \$\endgroup\$
    – Adam Haun
    Oct 11 '16 at 2:18

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.