On Mon, 07 Feb 2011 22:08 -0700, "Vitaliy" wrote: > Bob Blick wrote: > > I've always had to deal with that problem on the board, preferably clos= e > > to the part of the circuit that dumps the current into the rails. For > > protecting against positive swings, a PNP transistor with collector to > > ground, emitter to your input pin. A small diode from positive supply t= o > > base and a resistor from ground to base. =20 > In this circuit, the anode (+) of the diode is connected to positive > supply?=20 > What is the typical resistor value? Anode to positive supply. It points away from the positive supply toward the base of the transistor.=20 Resistor is chosen for a milliamp or so, if you can afford that much wasted current. So figure 4k3 in a five volt circuit. The amount of current you can absorb is the current through the resistor multiplied by the gain of the transistor, or about 100 milliamps with your typical PN2907. If you share one diode and resistor among several clamp transistors then one pin or the total of all can clamp 100 milliamps.=20 As a little side note, with bridge rectifiers the terminal marked (+) is the junction of two cathodes. So I usually don't refer to either terminal of a diode as (+) since it's just a perspective thing depending on the application of the diode. Further aside, I don't understand why tantalum capacitors have the stripe on the positive side and electrolytics have it on the negative. Cheers, Bob --=20 http://www.fastmail.fm - Does exactly what it says on the tin --=20 http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .