Is it common to put a "catch diode" to ground after the switch in these applications? If the motor appears as an inductive load, the current will ramp up when the switch is closed and ramp down (through the diode) when the switch is open. The voltages present, the inductance, and the PWM frequency would determine the ripple in the current. Harold On Thu, 5 Apr 2001 19:24:30 -0000 Thomas N writes: > I am a bit confused. Let's say I have: > > +5V---0/ 0--------(0)-------/\/\/\------------| > > +5V switch motor Sense Resistor Ground > > > Let's say the switch is closed and the motor is running, then > suddenly I > open the switch, should the voltage drop across the sense resitor be > at 0 > mA? If not, where is the current comming from? > > I am planing to use PWM (open and close the switch) at around 10Khz. > How to > I measure the average current flowing thru the motor while it is > running > accurately? > > Thomas > > > > >From: "Eisermann, Phil [Ridg/CO]" > >Reply-To: pic microcontroller discussion list > > >To: PICLIST@MITVMA.MIT.EDU > >Subject: Re: [OT]:Current Sensor > >Date: Thu, 5 Apr 2001 14:05:44 -0500 > > > >No, it won't :) well, it depends on the off time, i suppose. The > motor > >current can't decay instantaneously to zero because the motor is > inductive. > >The current will decay somewhat during the off period, but it's not > going > >to > >be zero unless you have a *very* slow PWM frequency. I don't > suppose you > >have access to a scope, so you? If you do, look at the current > waveform of > >the dropping resistor during PWM. But then, if you had a scope, you > >probably > >would have done that already. > > > >You should add a low pass filter anyway. Obviously, you want to set > the > >break frequency lower than your PWM frequency. That will go a long > way > >towards removing noise. Or you could add a peak-detect circuit if > you want > >the peak current instead of the average. But I don't think that is > >necessary > >if your PWM frequency is reasonable (depends on the motor). How > fast are > >you > >running (or planning on running) the PWM? > > > >-----Original Message----- > >From: Thomas N [mailto:thomasn101@HOTMAIL.COM] > >Sent: Thursday, April 05, 2001 2:19 PM > >To: PICLIST@MITVMA.MIT.EDU > >Subject: Re: [OT]:Current Sensor > > > > > >I will use PWM to control the speed of the Motor. If I put the > sensing > >resistor in series with it and feed the resistor's voltage drop to > the ADC, > >then the input to the ADC will be a square wave! (has the frequency > and > >duty > >cycle of the PWM) which is bad. I think I will need some circuit > to > >average > >it out... > > > >Thomas > > > > > > >From: "Eisermann, Phil [Ridg/CO]" > > >Reply-To: pic microcontroller discussion list > > > >To: PICLIST@MITVMA.MIT.EDU > > >Subject: Re: [OT]:Current Sensor > > >Date: Thu, 5 Apr 2001 13:04:44 -0500 > > > > > > The resistor *is* your current to voltage converter. Not > sure > >how > > >you're controlling the motor (PWM? FET/BJT? simple on/off?), but > if one > > >side > > >of the resistor is tied to ground, you can use an op-amp > (non-inverting > > >configuration) to scale the small voltage drop across the > resistor into > > >0-5V > > >for A/D conversion. Beware, though. The motor current will have a > lot of > > >noise. Some low-pass filtering before the A/D wouldn't hurt. > > > > > > I like the SenseFET for this application. International > >Rectifier > > >IRCZ44 comes to mind, although you might not get much accuracy > because > > >that's a 50A device. It's a 5 pin MOSFET. The extra two pins are > an > > >integrated 'current tap' This current tap reflects a fraction of > the > > >drain-source current. You convert this scaled down current with a > >resistor. > > >The advantage is that you don't have the current-sensing resistor > wasting > > >power. You only have the on-state resistance of the FET to worry > about. > >For > > >the IRZC44, that's 0.028 Ohm. Only drawback is that since the > motor is > >2.5A > > >and the FET is 50A, you might not get much accuracy because the > load is > > >such > > >a small fraction. You'd need a large gain on the op-amp, and > possibly > > >correlate some actual current readings with output to get good > results. > >Or > > >you could use a different version of this FET (one with less > range). > > >DigiKey > > >now carries these types of FET's, so you might start there to see > what > >you > > >can easily get. > > > > > > > > >-----Original Message----- > > >From: Thomas N [mailto:thomasn101@HOTMAIL.COM] > > >Sent: Thursday, April 05, 2001 12:28 PM > > >To: PICLIST@MITVMA.MIT.EDU > > >Subject: Re: [OT]:Current Sensor > > > > > > > > >Do you know the part number for the current to Voltage converter > IC? > > >THomas > > > > > > > > > >From: Vasile Surducan > > > > > > > >Use a small resistor and a curent to voltage converter. > > > >example: 0.1 ohm , 25mV to 250mV drop-out, > > > >convert this potential with a good operational amplifier to > 0-5V > > > >Vasile > > > > > > > > > >-- > > >http://www.piclist.com#nomail Going offline? Don't AutoReply us! > > >email listserv@mitvma.mit.edu with SET PICList DIGEST in the body > > > > > > > > > >________________________________________________________________________ _ > >Get Your Private, Free E-mail from MSN Hotmail at > http://www.hotmail.com. > > > >-- > >http://www.piclist.com#nomail Going offline? Don't AutoReply us! > >email listserv@mitvma.mit.edu with SET PICList DIGEST in the body > > > >-- > >http://www.piclist.com#nomail Going offline? Don't AutoReply us! > >email listserv@mitvma.mit.edu with SET PICList DIGEST in the body > > > > > > _________________________________________________________________________ > Get Your Private, Free E-mail from MSN Hotmail at > http://www.hotmail.com. > > -- > http://www.piclist.com#nomail Going offline? Don't AutoReply us! > email listserv@mitvma.mit.edu with SET PICList DIGEST in the body > > ________________________________________________________________ GET INTERNET ACCESS FROM JUNO! Juno offers FREE or PREMIUM Internet access for less! Join Juno today! For your FREE software, visit: http://dl.www.juno.com/get/tagj. -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu