Killed Two I/O Pins!

Hi, everyone.

I recently "killed" two I/O pins, I believe due to a wiring error. I had set up one of the I/O pins as a PWM output to provide a "position" signal to a linear actuator (itself containing some sort of micro-controller). However, I believe that I temporarily connected the linear actuator's position feedback to this I/O pin... The position feedback is a voltage ranging from 0 Vdc to 3.2 Vdc (don't know what the max current output is, but again, it's coming from some other micro-controller). I cannot remember what my I/O PWM output voltage was as the time, but I know that it can be anywhere between 0 Vdc and 5 Vdc. It seems like I effectively connected two dissimilar voltage sources in parallel, with no load - a bad thing, from what I understand. Now, this specific I/O pin, when configured as either a PWM or digital output - does nothing.

Q1: Is there a way to "fix" this? Already tried reloading other sketches to make use of this pin... nothing!

Q2: Any advice on how to prevent damage to I/O pins due to a mistake like this again (other than being more careful)?

Q3: I killed the adjacent I/O pin too (probably when I input the 0 to 3.2 Vdc signal from the motor's micro)... But I had not set it up to do anything within my sketch. Is this also explainable?

Thanks to all in advance.

Q1: Is there a way to "fix" this? Already tried reloading other sketches to make use of this pin... nothing!

You didn't say which type of arduino board you are using, but if it's a 328 based board you would need to buy a replacement chip with bootloader installed: http://www.sparkfun.com/products/9217 . If it's a mega1280 or 2560 based board, then you might have a problem as they are SMD packaged devices and a bitch to unsolder, etc.

Q2: Any advice on how to prevent damage to I/O pins due to a mistake like this again (other than being more careful)?

Well one method to prevent over current situations for output pins is to have the pin wired through a current limiting resistor before it wires to external components. This will limit how much output current is avalibe to whatever you are controlling with the pin and that may or may not be a problem for your applications. Hardware design and wiring is unforgiving in that you often get smoke instead of just compiler errors. A good understanding of electronics fundementals will go a long way to cut down on these kind of mistakes. Now it's harder to damage digital input pins, as they draw no/very little current, however applying voltages above +5vdc or and negaitive voltage to a input pin will also cause damage.

Q3: I killed the adjacent I/O pin too (probably when I input the 0 to 3.2 Vdc signal from the motor's micro)... But I had not set it up to do anything within my sketch. Is this also explainable?

Yes, electrical hardware problem can result no matter if you are using a pin in software or not, the electrons don't care.

Lefty

Thanks for the response, Lefty. I'll do what you suggested and get a replacement 328 chip with the bootloader.

Oh, and I thought about using a current limiting resistor... but I needed the full 0V to 5V range (for the actuator's commanded position). With the current limiting resistor in place, I couldn't get there, right? Anyway, it was a trade off and my carelessness betrayed me in the end.

but I needed the full 0V to 5V range (for the actuator’s commanded position). With the current limiting resistor in place, I couldn’t get there, right?

Its a current limiting resistor, not voltage limiting, unless the thing you are driving has a very low input impedance, the using say a 1K resistor should have pretty much no effect on the voltage.

Q3: I killed the adjacent I/O pin too (probably when I input the 0 to 3.2 Vdc signal from the motor's micro)... But I had not set it up to do anything within my sketch. Is this also explainable?

I'd explain it by suggesting there's now a small crater on some of the transistors on your 328 chip and the second pin was collateral damage. Small crater means of micro-metre dimensions.. More realistically there will have been local thermal damage affecting many devices associated with the pin and neighbouring circuitry.