> From: James[SMTP:james@2-BIT-TOYS.COM] > Sent: Saturday, May 01, 2004 2:52 PM > To: PICLIST@MITVMA.MIT.EDU > Subject: Re: [EE:] Interfacing an Active Low signal from a USB device with a Transistor for controlling a motor > Thanks for all the useful information! > To turn "on" the PNP transistor, the base has to be at least 0.6V less > than the emitter (and also a small current needs to flow) right? > So if my active low signal goes between 0 and 5V...and my motor power, > which is connected to the emitter is 5V, then I'm set. > What if my motor power was let's say 9V? Does that mean, even though > the microcontroller is holding the pin at 5V, the transistor would > still turn on, because the emitter is at 9V and the base is at 5V? > -James The emitter cannot be at +9V with the base at +5V unless the transistor is defective. Your first statement should read " . . the base can be no more than 0.6V less than the emitter . . .". You must use a resistor from the base of the PNP to a circuit which sinks current to ground. Typically an NPN transistor is used for this. The emitter of the NPN is grounded, and the resistor referred to above goes to the collector. A resistor from the base of the NPN is connected to the signal which turns on the NPN, and therefore, the PNP. This source would be the microcontroller output pin. When the I/O pin goes high, it sources current into the base of the NPN. This current is limited by the NPN's base resistor. That current is multiplied by the beta (current gain) of the NPN to produce an amplified collector current, which becomes the base current of the PNP. The current is amplified again by the beta of the PNP, giving a collector current which drives the load. The current from the I/O pin is multiplied by the product of the two betas, giving a result similar to that of a Darlington configuration, but the arrangement of the transistors provides for limiting the currents to reasonable limits. The NPN bipolar transistor can be replaced by an N channel MOSFET. In this case, the resistor from the I./O pin can be left out, but the first resistor, from the PNP's base to the MOSFET is essential. John Power -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics