PWM and motor control -- request clarification

Could some electronics guru please clarify the following. I understand that Pulse Width Modulation (PWM) uses a high fixed frequency carrier signal (e.g., triangle wave) and a low frequency modulation signal -- or even a DC level. If I were to use PWM for motor control, and use a fixed frequency triangle wave carrier, what would be the modulating signal in this case ? Is the output PWM signal being fed back in ? Any hints, suggestions would be helpful.

Reply to
Daku
Loading thread data ...

That would depend on the kind of motor. For DC motors, the modulation signal can simply be a DC level. For AC motors, it will generally be a sine signal. What you basically want to do is to feed the motor with a signal that, when smoothed out, will resemble the signal you would normally want to feed. There are several advantages to this approach, including a harmonic content that's easier to filter and a conceptually simpler control (once you get the hang of it) with good efficiency.

Unless you want to do some additional fancy control and processing, you don't normally need to feed the output PWM signal back in.

--
weland@sdf.org
SDF Public Access UNIX System - http://sdf.org
% grep me no patterns and I'll tell you no lines
Reply to
Weland

You are seriously confused. The triangular wave isn't any kind of carrier, but a signal generated inside the controlling electronics which is fed into a comparator along with a DC level. The output of the comparator is the PWM signal which controls the power feeds to the motor.

The motor coil spends its time clamped to either the positive or the negative supply rail.Careful designers make sure that the connection to the positve rail is cut before the connection to the negative rail is made and vice versa - search on "shoot-through current".

formatting link
/gpk/1040

The frequency of the triangular wave determines how often the coil switches between the rails, while the DC level controlls the ratio between the time spent connected to the positive ril and time spent connected to the negative rail.

-- Bill Sloman, Nijmegen

Reply to
Bill Sloman

formatting link

You are not in any position to tell some one what is and what isn't. Hell you don't even know what a carrier is, obviously.

Go back to bed in the insane asylum, you neighbor, next bed over, is wondering where you are. Or do they share beds there ? I get confused at times. Socialistic GOV.s do try to save money at times so that the King can add another cruise liner to his inventory of private bays.

Jamie

Reply to
Jamie

The triangle wave is only a reference to a voltage comparator circuit.

If you were to use a comparator you can use lets say the (+) input to place your triangle reference to and the (-)input as the modulated signal, to regulate output.

Remember that since in this example, you are using a (-) input for the set point, you must think backwards, unless you invert your control signal to correct the behavior, which most people do.

Ok, so lets say your speed set point is at near 0 volts on the (-) input of the comparator, since this does work backwards, it would mean that when the triangle wave is at the very bottom of the base line or just above the value of the (-) input, it'll force the comparator to a full on state. This will give you a nice looking fast raise in the wave.

Because you are now turning this on virtually at base you'll see either a pulse train that has a near 100% duty cycle, meaning, the off state is very short. You can even adjust it so that it remains on constantly for 100% output. Normally this signal drives a switching transistor into saturation so that no heat is generated in the transistor, because it is virtually 0 ohms or not much above it, depending on the device you use as the switch. A Mosfet is a good candidate for this.

Now, when you adjust your (-) input to 50% of the level of your triangle wave, the comparator will not switch on the output until the triangle reaches the same or slightly higher voltage than the (-) input. you will see a 50% duty cycle at this point which will give a DC motor full power 50% of the time.

Now for some helpful tips in selecting base frequency that carries this PWM signal, What I do is determine the induction of the motor and set the base frequency so that you'll get 50% current at 50% duty cycle. This ofrcouse only holds true with a DC motor at or near locked/stalled rotor. When they get spinning they back generate, like a DC generator would and thus it is like having an increase of induction which will relieve the load from your supply. Of course, if you have a load on the shaft that back generation isn't going to happen so much and thus your supply will feel the pain! :)

As far as feed back is concerned? You can operate what is called armature feed back to maintain speed or using some kind of resolver, encoder, tach what ever to monitor the actual rotor speed. In precision applications this is required.

In armature feed back, speed sensing can be tricky because you need to separate the PWM on duty time verses the regenerated energy coming back. The regenerated energy is what you need to look at for a precise speed reference however, for a general purpose reference, many simply take the output with motor connector and pass it through a smoothing filter RC network that gives them and average between the on cycle and the return energy as a feed back to add to the (-) input in this example, which would throttle back the width of the demand. as motor speed picks up, so does the regenerated energy and this keeps happening until they find a happy stable home! With no load, you may find the output signal looking like there is very little PWM pulse higth there, at full speed. It may look like a stair step shape with a variable height on the step going down.

so, if you were to use a dual comparator you could use one as the PWM referenced from your triangle source and speed set point and another comparator to trigger cancel effect from the feed back of your speed demand..

I hope you enjoyed that long winded explanation, I am still recovering from yesterdays Xmas.

P.S. If you need base line examples? We can plot some idea here in ASCII text.

Jamie

Reply to
Jamie

Perhaps you might be kind enough to inform us what the carrier wave might be in a PWM motor control circuit. The concept is useful in FM and AM radio, but no explanation of PWM that I've ever read has felt the need to invoke it.

Jamie, you seem to be confused pretty much all the time. The current Dutch government would resent being described as socialist, even though they do continue to run a system of universal health care, paid for by the system of compulsory health insurance originally invented by that notorious socialist, Bismark. The Netherlands has a Queen at the moment, rather than a King. She does have a royal yacht

formatting link

at the moment, but it's scarcely a cruise liner, and may yet fall victim to government economies.

For tonight my bed is in the Grand Hotel des Terreaux in Lyon (not an insane ayslum) and my neighbour is my wife, who knows exactly where I am. If there is a lunatic aslyum anywhere in the universe of discourse, it would be the one accomodating your poor deluded imagination.

-- Bill Sloman, Nijmegen

Reply to
Bill Sloman

Well, not really. PWM uses a _square_ wave of varying duty cycle ("duty cycle" means the ratio of on time to total cycle time). This square wave is usually at a high enough frequency that the motor current is significantly smoothed by the motor inductance (but not always, depending on the goal of the system designer).

One way that you _can_ generate a PWM signal is to have a triangle (or other sawtooth) wave generator, and compare that with a DC level using a comparator. But that's just one way -- the "modern" way to do this is to use a microcontroller, DSP chip, or FPGA with a purpose-built PWM generator that does everything digitally.

There are yet more methods -- just brainstorm on how you might make a variable duty cycle square wave; if you can think of it, it's probably been done.

If you're generating your PWM with a triangle wave generator and comparator, then you would be getting the DC duty cycle command from some form of feedback from your motor or following mechanism, plus some controller circuitry.

Probably the most common feedback would be the average current in the motor, since controlling the motor current will provide fairly direct control of the motor torque. The second-most common would be the motor speed or position, to make a servo mechanism out of the whole thing.

Again, possibilities abound, it all depends on what you want to do.

--
Tim Wescott
Control system and signal processing consulting
www.wescottdesign.com
Reply to
Tim Wescott

Minimum would be the speed control level, then add ramping, reversing, current limit and braking controls, depends on motor use.

Grant.

Reply to
omg

.

the

otor

ed

PWM

II

Thanks for the detailed explanation. As for the regenerated energy that you mention, are referring to the case when the when the motor inductor reverses polarity and causes the current to flow in the reverse direction -- back EMF. I have used PWM before, using a triangle wave carrier and a sine wave modulator, but for the DC motor case, I was not sure about what would the second input signal (other than the triangle wave) to the basic comparator based PWM scheme.

Reply to
Daku

Motors *always* generate a back EMF, opposing the applied voltage, while ever they're rotating. That's why the current goes up when you load them, and the speed falls. Think of a motor as a reverse EMF, proportional to rotational speed, in series with the resistance of the windings, brushgear, etc.

The "second signal" would be the controlling DC voltage.

It's customary to incorporate some sort of current feedback, to make the controlling voltage into a current, ie. torque, demand.

--
"For a successful technology, reality must take precedence 
over public relations, for nature cannot be fooled."
                                       (Richard Feynman)
Reply to
Fred Abse

No, I am not talking about the EMF collapsing energy, that should be quenched via a high speed diode, which will be much higher than the supply voltage in most cases.

What I am talking about is the fact that DC brushed motors are infact a DC generator when the input voltage is less than the output coming back from the motor or equal to.

For example. You put a volt meter on the DC motor terminals A1 and A2, spin it, It will generate voltage. This voltage is proportional to the shaft's RRM.

In a PWM system, the idea is to give a short pulse of full on power, which will be enough to cause some forward spin in the rotor of the DC motor. AT the time when the pulse turns off (Off cycle), The motor's shaft will be spinning, and since the DC motor is also a generator, it will be producing DC voltage in the off duration of the PWM time frame.

So for example, lets say the PWM drive signal has determine the on time duty cycle needed to keep the DC motor at 50% speed. when the PWM duty cycle goes into the off state, the returned DC generated voltage should be ~ 50% of Voltage that would be required to drive that motor at 50% speed. Example 100 V DC motor at 50% speed will require 50 VDC. of course motors are not perfect that is a close analogy for you. Let me see if I can draw a chart of what the PWM should look like

PWM Full On Pulse On Duty again Off duty ------------------| --------------------- On Duty | | | | | | | Generated DC | | | ----------------| from motor

+----------------------------------------------------+ 0 Volts (base line )

The above assumes the motor has reach 50% speed and you can see the generated DC coming back from the motor.

A simple transistor gate switch can be used to isolate the on PWM pulse, resulting in regenerated DC voltage for a feed back reference. As for the EMF kick back, you will get that when the motor is at stall! or generating very little output from spinning rotor to cancel that effects. Even then you still want protection against that when the brushes are passing over the commutator bars.

For single direction it is simple, just put a diode across A1 and A2 of the drive output. In cases where you want regen type drive (full 4Q bridge) for example, you place the diodes across the transistors..

Jamie

Reply to
Jamie

They are *always* a generator, irrespective of whether the input voltage is greater than, or less than the generated EMF. The voltage at the terminals is always equal to back EMF and IR in the motor resistance.

The only difference between operating as a motor or a generator is the sign of the IR component;

Generator; V=E-IR Motor: V=E+IR

-snip-

The idea is to produce a waveform whose integral can be easily varied by a controlling signal, whose PRF is high enough for the pulsed torque to be smoothly integrated by the motor inertia.

AT the time when the pulse turns off (Off cycle), The motor's

It will be producing DC voltage in *all* duration of the PWM time frame.

-snip-

Commonly held misapprehension. Continuously monitoring the voltage at the motor's armature terminals has been used for speed feedback since time immemorial. there is no need to gate the feedback. Better systems use some sort of bridge arrangement (lots of patents, IIRC), to cancel out the IR component of the voltage. Look up "IR compensation".

This has been going on since the days of thyratrons, right up to IGBT bridge PWM.

No, you won't. At stall, there is no rotation, hence no generated EMF. Current is limited solely by resistance, and applied voltage.

-snip-

It's all an application of Thevenin.

--
"For a successful technology, reality must take precedence 
over public relations, for nature cannot be fooled."
                                       (Richard Feynman)
Reply to
Fred Abse

act

A2,

me

ors

On Duty again

----------

|

=A0 =A0 |

=A0 =A0 |

=A0 =A0 |

This is bizarre. You can drive a motor this way - in a very odd and specialised application - but in general a PWM drive for a motor involves connected the motor winding between the positive and negative supply rails.

You can do it with two switches, if you return the motor winding to ground, or with four if you configure the swtiches as an H-bridge.

You switch between putting full positive and full negative volts across the coil fast enough that the motor inductance smooths out the motor current to something that doesn't vary too much from what you'd get if you applied a steady voltage equal to the average of the PWM waveform.

Obviously, you make sure that each switch connecting to the positive rail is fully off before you turn on the associated switch connecting to the negative rail, but that's suually a very brief interval covered by the stray capacitance across the winding.

Presumably Jamie has built up his expertise in some strange application where they do things differently, but his advice wouldn't have been all that useful in the applications I've worked on.

Spinning DC motors (and stepper motors) produce back emf, which makes it a good idea to drive them from a low-impedance source which can both sink and source current. Single transistors and catching diodes are pretty much confined to motors used to drive clocks and other similarly specialised mechanical loads.

-- Bill Sloman, Nijmegen

Reply to
Bill Sloman

I won't even bother to outline all the places you made yourself look like a fool..

Please get off the bozo before posting.

I don't care how many years of experience you have etc, etc, etc...

I know it won't mean anything at all to you however, I just happen to have some DC drives using PWM that use the exact model of how I described the whole process, working exactly as I quoted.

I won't waste my time arguing with you any more.. I can see that it is going to be a useless process with you.

You are correct no matter how wrong you could be, and I won't outline the areas that you were incorrect in your assessments.. I Didn't even quote it, just trying to be polite about it. But if you are one that likes to twist things around to start a flaming discussion that most likely will end bad on your side, I'll just sit off the side and let some one else do that for me.

P.S. I've seen several replies you have made recently to others and you were in error in couple of them, very much in error in deed.

I guess this isn't the place to come get help with people like hanging around unloading.

Jamie

Reply to
Jamie

SLow-Man, Until you, yourself have actually done this, I would not say to much.

H bridge is not needed in this application unless there is a need to regen braking or motor reversing, it was not specified as that, it was simply asked about feed back in general. Also, this assumes that we are talking about DC bus drives, not thyristor antiques.

Sure that will work if you want the motor to drain off it's back spin EMF generated energy instead of allowing the motor to free spin its load to the next cycle. This will also needlessly heat up the motor and the shunting bridge. For handling over speed conditions, this would be regenerative braking. Why would you want to be doing this at all times is beyond me?

And even here, this is only speed braking using the regenerating currents from the motor to cause drag on the motor. A full regen drive operates bipolar mode and takes advantage of not only shunting the regen EMF voltage but applying reversing currents for a stronger braking and reversing the rotor..

I won't get into it more because it's way out of your league. Go back to bed, the nurses are calling you.

The rest is just not worth replying to.

Jamie

Reply to
Jamie

You are arguing with people who have a lot more knowledge in this area than you have. That much is obvious from your posts. You would do much better to think through what they said and try to analyze their responses rather than getting your hackles up. Perhaps they are responding to what they *think* you are saying and that's not what you actually meant. You should discuss it with them in more detail rather than flying off the handle, while thinking that they have insulted you.

If you're lucky, they will not respond to your posts. If you're not, well, you get what you deserve. It doesn't hurt to be a gentleman, you know.

Reply to
John S

act

A2,

,

time

ors

=A0On Duty again

----------

|

=A0 =A0 |

=A0 =A0 |

=A0 =A0 |

You are letting your imagination run away with you again.

Back EMF isn't energy; the energy involved is product of the moment of intertia of the rotating parts and square of the rate at which they are rotating. If the voltage across the motor coil matches the average voltage produced by the PWM waveform, the current through the motor coil neither increases nor decreases significantly during the PWM cycle. Normally you need to be driving some current through the coil to balance frictional losses, and prevent the rotor from slowing down.

Trying to stop current flowing during some part of the PWM cycle is usually futile - the coil inductance keeps it going, with a much longer time-constant than the pulse periods normally used in PWM

True, but irrelevant. PWM does involve some - usually small - fluctuations in motor current during the period of the modulation, and since heat dissipation is proportional to the square of the current, this does increase the dissipation in the resistances of the motor coil and the switches, but this is - almost always - a very small increase indeed, and perfectly justifiable.

It allows you to control the average voltage across the motor from the maximum available postive voltage to the maxiumn available negative voltage without dissipating significant energy anywhere except in the motor's coil resistance. You can usually arrange that the voltage drops in the switching transistors are low enough that dissipation in the motor is all that you have to worry about (unless you are into very big motors).

Of course. The current through the motor determines the torque generated by the motor - either accelerating or decelerating. You've got to be able to apply enough volts across the coil to exceed the back EMF and the ohmic losses in coil to get the current you need (which isn't a problem during deceleration).

If the motor gets too hot, the magnetic components become less effective, and the maximum torque available can decline, but this is all second order stuff

You really are a fatuous clown.

-- Bill Sloman, Nijmegen

Reply to
Bill Sloman

excuse me ?

#1... You don't know me and that is all that matters.

#2. You don't know what I do for a living and It does not matter nor do I care for you know, I have to many people calling me for bull shit as it is.

#3. Putting #1 and #2 together, maybe you should be the one sitting back and not joining this party..

#4. I didn't even bother to read the rest of your post, the first few words was enough to tell me exactly where this is going and how ill sided you made your choices that.

#5. Facts are facts, Putting a gold star on something or some one does not make it the #1 authority, I don't claim that, and neither should any one else here. However, it really bothers me when bad information and smart arse remarks are made to others, from those that are suppose to have that "GOLD shiny STAR" so bright on their foreheads.

Yes, this is USenet or what ever you want to call it. It is not an excuse for the professional minded to go off on a tangent just because they maybe having a bad day and offer very little or incorrect information to those that are really seeking help and on top of that, spitting out smart ass, pissy remarks in the process that makes them lose all credibility and respect, if they ever had much to start with.

People do make mistakes, including a few here that should know better. I won't get into the most recent list because I finger at some point they'll finger it out. But it seems they would rather lay back and not say anything in fear they may be sot out.

Jesus

I've never seen so many side blinded ignoramuses congregating.

There are a few that deserved a lot more credit than they get, no names stated because they most likely don't fit the criteria of those prima donnas here that have been over credited, far to long.

I am beginning to understand Phil's pain, as obnoxious as he can be, he does have some valid points at times. He just needs to direct them to the correct individuals. No Phil, I am not trying to make friends with you, I have enough already.

This place is starting to deteriorate greatly, I've been here for years,years! , using various names over the past and there used to be some very talented people here, no, I don't mean the ones that talk the talk and you know the rest.

I guess with the older generation dying off and the younger play station educated, we're all in big trouble.

45 years of electronics have tough me this, and that is, to recognize bull shit when I see it.

Jamie

Reply to
Jamie

Well, I'll try, but it will be taxing.

What makes you think I don't?

What makes you think I don't? You've left a lot of clues lying around.

The meaning of that phrase is lost on me. Is English your second language?

Well, like me, you cannot decide that. Might as well live with it. And, I have more to say about that below.

You see? Your lack of comprehension by not reading and trying to understand other people's foibles can mislead you. How can you determine that "ill sided you made your choices that." (whatever that means) is true if you do not read the whole thing? And, since you insist that I know nothing about you, how can you know anything about me?

Does this have anything to do with what I posted, or are you just ranting? Maybe this is part of your inability to comprehend. If you cannot express yourself clearly, maybe you have a reading impairment of some kind. Perhaps you should seek help.

I can call it anything you like. Just give me the rules.

You really need to control your temper. It seems to make you harder to understand.

Of course. I've been very red-faced here. Many times. I've admitted it when it was pointed out to me.

I wasn't going to say anything about a typo, but you did it twice and so...

By "finger", I assume you mean "figure". I can make the connection because of syntax. Not so bad. However "they may be sot out" made me pause a bit longer. And my assumption is "sorted". My advice on this is to relax and not get so heated when you are typing. The sentence meaning is not understandable to me, however.

Whoa! At first I thought you were signing this post as, you know, Him.

Welcome to the mix you so hate.

Well, I tend to agree somewhat on those who should get more credit. I don't think there are many "first ladies" of the opera here, though. Do you, by any chance mean "primo uomo" which is the male counterpart?

Phil has pain? Phil is obnoxious? The man has credentials that make you look smaller than an amoeba compared to the Universe. How many books or articles have you published? Do you own a company? What credentials do you have other than as a ham radio guy with a Web page. What the hell do you know about this? What makes you think you he even wants to establish a friendship with you? That's extremely presumptuous on part! You will probably not see him respond to your post because he is one of the gentlemen here.

If you really have enough friends already, you don't need this group and I suggest that you remove yourself from it.

They might appear to be more talented even now if you would develop the attitude that maybe you don't know it all. Maybe the deterioration is with you rather than the Group and you should go away until you learn which is which.

It appears that *you* are, at least.

Not "tough", its taught (probably).

It is really hard to believe that all you learned in 45 years in electronics is to recognize bull shit when you see it.

Come visit sometime.

Cheers, John S

Reply to
John S

infact

back

Umm, plus shaft output power if you please; it has to come into account somewhere in input power.

Reply to
josephkk

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.