R >From 12v _____/\/\/\____________ To windows |__ | \>| | |--/\/\/\---+ /| 4k7 | | To PIC (needs dropping to 5v for PIC) This is a classic overcurrent detection scheme. If you can't recogize the hideous ascii art, the transistor is a PNP device. Resistor R is chosen so that at the current you want to detect, the voltage drop across it is enough to switch on the transistor, say about 0.6 volts. The other resistor is to limit the current through the base/emitter junction. So for 10 Amps this would give 0.6/10 =0.06 ohms. Not a very easilly obtainable value! But to achieve this kind of resistance you can experiment with a small coil of copper wire, you won't need much. Some commercial designs use a PCB track as the curent sense resistor. Note that is circuit is not a precision design, the current at which it activates will vary a bit with temperature etc, but it should be OK just for detecting a stalling motor. Regards Mike Rigby-Jones > -----Original Message----- > From: Peter Marinsek [SMTP:peterm@FLUX.FE.UNI-LJ.SI] > Sent: Thursday, July 15, 1999 11:16 AM > To: PICLIST@MITVMA.MIT.EDU > Subject: car window project > > Hello, > > I'm currently working in a car project where I want to drive opening and > closing car windows (car alarm). > And the question is: > a simple circuit to detect when a DC motor is overloaded (when the > window full close or full open the motor current increase) > > Thanks, Peter