Darren Gibbs wrote: > So the answer appears to be the diode. When it's in parallel with > the transistor as the book shows, it causes the latching behavior. > When I put the diode in parallel with the solenoid, no more latching. > > So now I know what's wrong, but not why it does what it does. Can > anyone explain why the transistor would stay on because of a path for > current to get from E back to C? It stays on because the 1000 volts or so the solenoid produced when you tried to turn off the transistor was rather beyond maximum ratings. Anything the transistor does after that should not be a surprise. It has nothing to do with the E-B diode. That diode was essentially not there. ****************************************************************** Embed Inc, Littleton Massachusetts, (978) 742-9014. #1 PIC consultant in 2004 program year. http://www.embedinc.com/products -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist