Arduino & USB = Dangerous
One of the many little tidbits of advice I found when reading up on Arduino was to protect your computer’s USB port. By that I mean buy a powered USB hub to plug the Arduino into. That way if you do something epicly stupid, you’d burn out a USB hub, instead of your computer’s USB ports. I thought that while this was a fair idea, I need not bother. After all, I’m a smart guy and I’m not going to be working with any serious amounts of power. Turns out… that suggestion was a much better idea than it seemed.
This past weekend I was finally putting in some decent time with building Arduino projects. I got an RGB LED wired up properly, mucked about with coding different variations, stuff like that. As time went on, I tried to make things more complex. One of my last steps in complexity for that evening was adding a photo-resistor for input to control the LED. This is where, of course, things went screwy.
I wasn’t paying as much attention as I should have been (since I was watching NCIS with some friends at the same time) and plugged a line from the 5V rail directly into the Ground. This had the immediate effect of killing my Arduino and my USB ports. At first, I wasn’t sure the extent of damage as I didn’t think grounding the power would cause that much of a problem. The Arduino unit powered on which was a sign that the USB port was still alive, but the computer no longer recognized anything. On top of that, the TX & RX lights on the Arduino were no longer lighting up (which they were before). Also, not good signs.
In good diagnostic fashion, I swapped the Arduino over to another computer to test. It picked up the unit and started the driver install, generally a good sign. I was working on a serial data project, so I hit up the COM port to check that out. I started getting data back and the TX/RX lights came back – more good signs. I tried plugging back into my main computer, I had light on the Arduino board but still no data connection. Swapped to a different set of USB ports on that machine and it worked. Proof that I had managed to kill two of my USB ports. Damn.
Last resort: I rebooted. Lo and behold, power AND data from my “dead” USB ports. I guess that my Dell has some sort of built in protection circuit on the USB ports to prevent you from frying them… while doing something stupid. Very good thing for me. The moral of the story? Use a damn USB hub with your Arduino, for when you’re not so lucky. $20 is a small price for peace of mind.