Re: EMC Feb 29 & Stepper speed




---------------------------------------
At 11:50 PM 2/29/2000 -0500, Tim wrote:
<snip>
>In spite of everyone's best efforts I am still clueless as to what P,
>CYCLE_TIME, and period are really doing. OK, I think I understand period as
>determining the base frequency that is generated to issue the stepper
>pulses. But, I still don't understand the P and CYCLE_TIME entries. Is it
>good to set then to the lowest values possible?
------------------------------------------------

Tim and other new freqmod/smdromod users.

This is a rather long post about P but this axis tuning stuff becomes
critical for stepper users with these new tools.  This is an IMHO view of
P, I, D. (with flame suit in place)  BTW I've seen some excellent stuff on
the web regarding PID tuning but don't have specific links handy.  There
are also a bunch of auto tuning and computational tuning procedures but I
know nothing about any of them.

All three variables (6+ really) look at what is happening between commanded
and actual position in the emc.  My comments below may be a bit
unsatisfying for those who are accustomed to very precise things but they
come from a number of years of twiddling with servo controls.


P - process variable. 
---------------------
This is the gain control.  It is a bit like the volume on a music system.
If it is set too low you can't follow the lyrics.  If it's set too high the
windows rattle and the neighbors fuss.  

Some authors refer to P as proportional band.  Think of it as a pair of
lines, one ahead of the commanded position and one behind it.  Actual
position should be somewhere between the lines.  If the actual position is
farther behind then that below line the controller will run the axis flat
out to reach the slower line.  Conversely, if the actual position is ahead
of the above line the controller will do all it can to bring actual
position down to that upper bound.

As long as the actual position is between the lines, the controller will
ramp gain up and down so that actual approaches commanded.

The larger the P number the narrower the space between these lines.  Set P
too low and your axis works like a dedicated couch potato during super bowl
or world soccer finals -- even a fire may not rouse it.  This condition is
rather easy to spot because the axis is sluggish.  

Set P too high and your axis will develop palsy.  On most machines you can
hear this condition by putting your ear to the motor.  You may want to do
this when others aren't watching -- or use a stethoscope or a long socket
extension -- or perhaps the graph function.  

Palsy will sound like a hum or grind when the motor is sitting still or
moving very slowly. You can also feel palsy if you wrap your hand around
the ball screw or grip the drive belt or pulley.  (disclaimer -- This
demonstration is done by a professional with only three remaining fingers,
don't try this at home) 

Deadband may mask too much P when a motor is sitting still so you may want
to move the axis very slowly and listen to the sounds around each step.  If
the axis keeps up with commanded position at high speed and during
acceleration and there is not a lot of ringing, grinding, jumping at very
low speed, then you are real close.  


I - Integral variable.
----------------------

Integral works a bit like a shock absorber.  Any change in either actual or
commanded position gets rounded off or averaged in so that
acceleration/deceleration brought about by P is absorbed and released more
slowly over time.  

No integral and you get the full P effect of change in commanded position.
Too much integral and the axis seems to wander off on it's own without much
regard for P.  A little integral may smooth out some of the frequency jumps
when a stepper is running right near one of those troublesome rates.  


D - Derivative variable
-----------------------

Derivative works like passing gear for acceleration or a jake-brake for
stopping.  Whenever commanded position changes rapidly, d will really kick
the amp/motor in the *** to follow the rate-of-change of the axis command
rather than the difference between commanded and actual position. 

Derivative works against inertia so if you've got lots of iron to start or
stop dial some in.  But derivative will increase palsy so you have to
balance it against gain.


T - Test
--------

The final proof of tuning is in the cutting.  So after your best guess with
all the watching, hearing, feeling done to each axis, get out a chunk of
soft aluminum, a small end or ball mill, and begin to mill circles or arcs
that pass 90 degrees between each pair of axis.  I like outside circles
because you can hold them up to the light and see how the finish looks near
the quadrants.  

Digital systems will give you some steps as one axis approaches zero and
the other approaches the set feedrate so don't expect a perfect mirror arc
finish.  Backlash and backlash compensation also affect the appearance
here.  Servo drives will work better than steppers. (digital vs analog)
But the smoother the saw teeth the better.

Be prepared to spend some metal on this!  And make a list of your settings,
changes, and a better/worse judgement about the result of each change.  On
occasion I've spent pages of paper and made piles of swarf to get a
stubborn machine to where I wanted it.

Good luck and may the force be with you.  

Ray






Date Index | Thread Index | Back to archive index | Back to Mailing List Page

Problems or questions? Contact