Acceleration and Deceleration Ramping

AccelerationClosed The change in velocity as a function of time. and deceleration ramping lets the speed of the motion ramp cleanly between two different setpoints. The Automation1 controller uses accelerationClosed The change in velocity as a function of time. and deceleration ramping when it creates the velocity profile for moves generated by MoveAbsolute(), MoveIncremental(), MoveFreerun(), MoveRapid(), MoveLinear(), MoveCw(), and MoveCcw(). The controller also uses accelerationClosed The change in velocity as a function of time. and deceleration ramping during home moves and when it aborts moves.

Velocity Profile of a Move

When an axis is commanded to move, the controller generates a velocity profile, which is used to calculate position and velocity values at the time interval specified by the MotionUpdateRate Parameter and send these values to the position loop of the servo loop. The velocity profile usually includes the ramp segments that follow.

  • AccelerationClosed The change in velocity as a function of time. segment - the portion of the velocity profile in which the velocity ramps between the starting velocity and the target velocity.
  • Constant velocity segment - the portion of the velocity profile during which the velocity stays at the target velocity.
  • Deceleration segment - the portion of the velocity profile in which the velocity ramps between the target velocity and the ending velocity.

Figure: AccelerationClosed The change in velocity as a function of time. and Deceleration

Ramp Types

The Automation1 controller lets you select one of three different ramp types to use when you generate a velocity profile for a move.

  • Linear
  • Sinusoidal (Half-Sine)
  • S-Curve

Figure: Linear, Half-Sine, and S-curve Ramping

For each ramp type, the ramp rate that you specify is the average accelerationClosed The change in velocity as a function of time. value of the full ramp. Thus, different ramp types have different peak accelerations, as in the above figure.

Linear Ramp Type

For a linear ramp, the controller uses a constant accelerationClosed The change in velocity as a function of time. value, the configured ramp rate, to ramp the velocity from one setpoint to another. A linear ramp has these properties:

To set the ramp type to Linear, specify the Linear ramp type in the SetupCoordinatedRampType() function.

SetupCoordinatedRampType(RampType.Linear)

Sinusoidal (Half-Sine) Ramp Type

A half-sine ramp type uses an accelerationClosed The change in velocity as a function of time. value that follows a half-cycle of a sine wave whose amplitude is set so that the average value across the ramp is equal to the configured ramp rate. A half-sine ramp has these properties:

To set the ramp type to Sinusoidal, specify the Sine ramp type in the SetupCoordinatedRampType() function.

SetupCoordinatedRampType(RampType.Sine)

S-Curve Ramp Type

An S-Curve ramp type uses a percentage value to find how much of the accelerationClosed The change in velocity as a function of time. ramp is non-constant accelerationClosed The change in velocity as a function of time..

Figure: Velocity Profile - S-CURVE 50

During the curved portions of the accelerationClosed The change in velocity as a function of time. ramp, the jerk is constant. A larger S-Curve percentage causes a lower constant jerk value.

An S-Curve ramp with 0% curvature is the same as a Linear ramp and has a peak accelerationClosed The change in velocity as a function of time. of 1.0 times the average accelerationClosed The change in velocity as a function of time.. An S-Curve ramp with 100% curvature has a peak accelerationClosed The change in velocity as a function of time. of 2.0 times the average accelerationClosed The change in velocity as a function of time..

An S-Curve ramp has these properties:

To set the ramp type to S-Curve, specify the SCurve ramp type and the curvature percentage that you want in the SetupCoordinatedRampType() function.

SetupCoordinatedRampType(RampType.SCurve, 50.0)

Ramp Modes

The Automation1 controller supports two ramp modes:

  • Rate-based ramping
  • Time-based ramping

These modes affect how the controller generates accelerationClosed The change in velocity as a function of time. and deceleration ramps.

Rate-based Ramping

When the ramp mode of the controller is set to rate-based ramping, the controller generates accelerationClosed The change in velocity as a function of time. and deceleration ramps based on the ramp rate that the user gives. This ramp rate is in user units/s2. The average accelerationClosed The change in velocity as a function of time. across each accelerationClosed The change in velocity as a function of time. and deceleration ramp is equal in magnitude to the user-supplied rate, no matter what the target velocity is.

To set the ramp mode to rate-based ramping, specify the Rate ramp mode and the ramp rate that you want in the SetupCoordinatedRampValue() function.

SetupCoordinatedRampValue(RampMode.Rate, 2000.0)

Time-based Ramping

When the ramp mode of the controller is set to time-based ramping, the controller generates accelerationClosed The change in velocity as a function of time. and deceleration ramps based on the ramp time supplied by the user. This ramp time is given in seconds, with a resolution of 0.001 seconds (1 millisecond).

When time-based ramping is active, the controller calculates an accelerationClosed The change in velocity as a function of time. or deceleration rate that causes the accelerationClosed The change in velocity as a function of time. or deceleration segment to take the fixed amount of time given by the user. Thus, the average and maximum accelerationClosed The change in velocity as a function of time. across these ramps change based on the target velocity.

If a move does not have enough distance to reach full speed, a shorter ramp time can occur. The ramp rate will be the same as if there was enough distance in the move, but the ramp is cut short because the distance is not sufficient. The result is a ramp time that is shorter than the user-specified ramp time.

Aerotech recommends using rate-based ramping so that average and maximum accelerationClosed The change in velocity as a function of time. values do not change because of the target velocity.

To set the ramp mode to time-based ramping, specify the Time ramp mode and the ramp time that you want in the SetupCoordinatedRampValue() function.

SetupCoordinatedRampValue(RampMode.Time, 0.5)		

Ramping Commands and Parameters

The Automation1 controller supplies AeroScript API functions and controller parameters to configure the ramping behavior.

Configure Ramping for Independent Axis Motion

For independent axis moves such as MoveAbsolute(), MoveIncremental(), MoveFreerun(), and MoveRapid() use the functions that follow to configure ramping. Because the controller does motion on each axis independently, you must configure ramping for each axis.

function SetupAxisRampValue($axis as axis, $rampMode as RampMode, $rampValue as real)

Sets a ramp value for both accelerations and decelerations simultaneously for an axis.

function SetupAxisRampValue($axes[] as axis, $rampMode as RampMode, $rampValue as real)

Sets a ramp value for both accelerations and decelerations simultaneously for axes.

function SetupAxisRampValue($axis as axis, $rampModeAccel as RampMode, $rampValueAccel as real, $rampModeDecel as RampMode, $rampValueDecel as real)

Sets a ramp value for accelerations and decelerations separately for an axis.

function SetupAxisRampValue($axes[] as axis, $rampModeAccel as RampMode, $rampValueAccel as real, $rampModeDecel as RampMode, $rampValueDecel as real)

Sets a ramp value for accelerations and decelerations separately for axes.

function SetupAxisRampType($axis as axis, $rampType as RampType)

Sets a ramp type for both accelerations and decelerations simultaneously for an axis.

function SetupAxisRampType($axes[] as axis, $rampType as RampType)

Sets a ramp type for both accelerations and decelerations simultaneously for an axis.

function SetupAxisRampType($axis as axis, $rampType as RampType, $rampTypeArg as real)

Sets a ramp type along with a ramp type value for both accelerations and decelerations simultaneously for an axis.

function SetupAxisRampType($axes[] as axis, $rampType as RampType, $rampTypeArg as real)

Sets a ramp type along with a ramp type value for both accelerations and decelerations simultaneously for axes.

function SetupAxisRampType($axis as axis, $rampTypeAccel as RampType, $rampTypeArgAccel as real, $rampTypeDecel as RampType, $rampTypeArgDecel as real)

Sets a ramp type along with a ramp type value for accelerations and decelerations separately for an axis.

function SetupAxisRampType($axes[] as axis, $rampTypeAccel as RampType, $rampTypeArgAccel as real, $rampTypeDecel as RampType, $rampTypeArgDecel as real)

Sets a ramp type along with a ramp type value for accelerations and decelerations separately for axes.

The controller also supplies the axis parameters that follow to configure the default ramping behavior of axis-based moves:

Refer to Motion Setup Functions for more information on the available functions.

Configure Ramping for Coordinated Motion

For coordinated moves such as MoveLinear(), MoveCw(), MoveCcw(), use the functions that follow to configure ramping. Because coordinated motion synchronizes motions on multiple axes, you must configure ramping for each task instead of for each axis.

function SetupCoordinatedRampValue($rampMode as RampMode, $rampValue as real)

Sets a coordinated ramp value for both accelerations and decelerations simultaneously for dominant axes on the current task.

function SetupCoordinatedRampValue($rampModeAccel as RampMode, $rampValueAccel as real, $rampModeDecel as RampMode, $rampValueDecel as real)

Sets a coordinated ramp value for accelerations and decelerations separately for dominant axes on the current task.

function SetupCoordinatedRampType($rampType as RampType)

Sets a coordinated ramp type for both accelerations and decelerations simultaneously for dominant axes on the current task.

function SetupCoordinatedRampType($rampType as RampType, $rampTypeArg as real)

Sets a coordinated ramp type along with a ramp type value for both accelerations and decelerations simultaneously for dominant axes on the current task.

function SetupCoordinatedRampType($rampTypeAccel as RampType, $rampTypeArgAccel as real, $rampTypeDecel as RampType, $rampTypeArgDecel as real)

Sets a coordinated ramp type along with a ramp type value for accelerations and decelerations separately for dominant axes on the current task.

The controller supplies the task parameters that follow to configure the default ramping behavior of coordinated moves:

Refer to Motion Setup Functions for more information on the available functions.

Configure Ramping for Home Motion

For motion that occurs during a Home() sequence, the controller uses the value specified by the HomeRampRate Parameter for each axis. If this parameter is set to 0, the controller uses an infinite value. Because the controller homes each axis independently, you must configure ramping for each axis.

Configure Ramping for Abort Motion

The abort deceleration rate and deceleration behavior is based on the type of motion being executed.

To abort coordinated motion, the controller uses the task defined deceleration parameters to decelerate along the programmed path. Each axis does not decelerate independently.

For most other types of motion, the controller uses the AbortDecelRate Parameter to find the abort deceleration value. Because the controller can abort each axis independently, you must configure ramping for each axis. Refer to the AbortDecelRate Parameter for more information on the abort deceleration value that the controller uses.