On Sun, 20 Apr 2008, Anders Wallin wrote:

> Date: Sun, 20 Apr 2008 23:19:29 +0300
> From: Anders Wallin <[EMAIL PROTECTED]>
> Reply-To: "Enhanced Machine Controller (EMC)"
>     <emc-users@lists.sourceforge.net>
> To: "Enhanced Machine Controller (EMC)" <emc-users@lists.sourceforge.net>
> Subject: [Emc-users] PID-tuning
> 
> Hi all,
>
> I got my x-axis servo motor mounted today and ran some tests.
> There is a video and some hal-scope screen shots here:
> http://www.anderswallin.net/2008/04/x-axis-test/
>
> This is a system with no motor current, motor voltage, or velocity
> feedback. An m5i20 generates PWM output for pico-systems DC-brush amps
> and 4000 pulse/rev encoders provide feedback.
> This might make the system a bit different to tune from other systems
> which run another loop on current/voltage/velocity.
>
> I found FF1 worked quite predictably and reduced the cruise-phase error
> to very little. Only P and FF1 was needed for that. (2nd pic on page)

Yes, FF1 is a requirement for straight PWM AMPs to compensate for BEMF

>
> Then I added a lot of I-gain which helped a bit for the acc/dec phases.

I would only add I gain at the end of tuning to keep static errors and errors 
at low speeds to minimum. Enabling I gain early in tuning will only mask the 
effects of the FF1 and FF2 tuning

>
> With FF2 I became confused on a higher level (3rd pic on page). It seems
> to either fix the acc. phase or the dec. phase but not both.

Dont know..
>
> The last pic shows moves at different feed-rates. All of them show
> around 16 to 25 count spikes during the acc/dec. phases. Presumably at
> the moment when acceleration changes and jerk is infinite. How much have
> other people been able to reduce these spikes?
>

1. Is it possible that you are running into current limits of your HBridge?
    (ours have little red LEDS the indicate current limit), sometimes you can
    hear the current limit in the motor if the mechanical noise lets you

2. Are you running out of headroom (in other words what PWM values are
    supplied when you have the large errors) I would have at least 20% of
    headroom available.

3. What sample frequency are you using? with torque mode and straight PWM amps
    you will need a high sample rate than used with velocity mode servos. A
    a higher sample rate will allow higher P gains with these amps, improving
    performance.

4. With straight (voltage mode) PWM amps, large armature (or stator for BLDC)
    current changes are slower than desired, This is because with no current
    feedback (and only position errors to drive the bridge), the motor drive
    voltage (VBridge-VBEMF) will only slowly increase or reverse based on the
    position error. These low initial drive voltages slow the change of current
    in the motors inductance, (meaning the torque lags the desired torque).
    In a current controlled bridge (true torque mode) the current will change
    much more quickly, as the current feedback loop will apply full voltage
    until the current is correct.

    I am convinced that this feature of straight PWM amps can be
    partially corrected with 'inductive lag' feed forward, basically
    feeding a high pass filtered version of FF2 into the PID loop.

Peter Wallace
Mesa Electronics

(\__/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination.


-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to