AutomateDirectUSAMotion LibraryIndustrial monitors & PCs

Troubleshooting

Servo speed change during motion: distance and instruction support

Servo and stepper motion Published 10 min read By AutomateDirectUSA engineering team

Short answer

A mid-move servo speed change works only when the executing pulse-output instruction accepts velocity updates while the move runs, and when the slowdown trigger fires before the axis has travelled the deceleration distance between the old and new speeds. That distance is the difference of the speed squares divided by twice the deceleration, so the trigger position comes from the calculation, not from a fixed clearance.

On this page
  1. Why does a servo axis ignore a new speed written mid move?
  2. Which pulse-output instruction accepts a speed change during a move?
  3. How much travel does an axis need to slow from one speed to another?
  4. Is a slowdown trigger 3 mm before the target early enough?
  5. What shapes the deceleration once the new speed value lands?
  6. Why does the speed register write still do nothing?
  7. How do I sequence and verify the change on a live axis?
  8. When is a mid-move speed change the wrong tool?
  9. Questions asked

A pulse-output servo axis can change speed while a move is running, but only two conditions make it happen: the executing instruction must re-read its velocity while active, and the slowdown must be commanded early enough that the axis still has its deceleration distance left to travel. Write a new value to the speed register of an instruction that samples velocity once at start, and nothing happens. Write it too late, and the axis arrives at the target still fast. What follows is the instruction-support pattern to look for in the manual, the deceleration-distance calculation with a worked example, and the checks that find a dead write, ordered from cheapest to run.

Why does a servo axis ignore a new speed written mid move? #

Because most pulse-output instructions read their speed exactly once, at the moment the move starts; while such a move is active, a new value in the speed register sits unread until the move ends and another instruction call presents it.

The capability is built into the instruction, not into a register you can set from outside: an enabling setting only unlocks the behavior where the instruction supports it in the first place. Start in online mode and watch which instruction is actually executing on the channel that moves the axis, because a program can contain a supported instruction and an unsupported one side by side, and the enable plus the register write only mean something for the one that is running.

One controller family's own pulse-output help makes the split concrete. In the CLICK PLC help, the Velocity Move instruction for a pulse-train-output axis takes a change in velocity during the move, with the transition shaped by the axis configuration; the help for the plain Pulse Train Output instruction states that its speed is fixed and cannot be changed and that in-motion changes are not supported. Same cabinet, same axis hardware, opposite behavior — the deciding difference is which function the scan is executing.

Decision: confirm the executing instruction in online mode before writing any register; if it samples speed only at move start, no register write will help.

Which pulse-output instruction accepts a speed change during a move? #

On controller families that number their pulse functions, support is decided function by function: in one such family, FUN140 accepts an in-motion speed update, FUN147 does not, and the feature is unlocked by writing decimal 90 to the system register R4056.

That pattern has three parts worth copying as a checklist when you read your own controller's high-speed output manual. First, an enable value in a system register: decimal 90 in R4056, which holds for every pulse-output channel on the controller, so it is set once and not per channel. Second, instruction support: the in-motion update belongs to FUN140, FUN147 does not offer it, and rewriting the register more often does not add a capability the executing function lacks. Third, the delivery path: with the enable present and FUN140 executing, a new speed value written to the HSPS0 pulse register changes the commanded pulse rate without ending the move.

Check the radix the programming software shows beside the entry field before typing: decimal 90 is the required value, and the same two characters entered into a field interpreted as hexadecimal store 144, which selects something else entirely.

Decision: enable value present, supported function executing, write aimed at the register that function re-reads — all three together, or the write is decorative.

How much travel does an axis need to slow from one speed to another? #

For a constant decel the axis needs d = (v1² - v2²) / (2a) of travel, where v1 is the speed before the change, v2 the requested lower speed and a the deceleration magnitude, all three in one unit system.

Worked example — calculated for these inputs, not measured on a machine: a linear axis cruising at v1 = 500 mm/s must be settled at v2 = 50 mm/s, with the axis configuration set to a deceleration of a = 500 mm/s².

  • 500² = 250,000 mm²/s² and 50² = 2,500 mm²/s²
  • difference: 250,000 - 2,500 = 247,500 mm²/s²
  • 2a = 2 × 500 mm/s² = 1,000 mm/s²
  • d = 247,500 ÷ 1,000 = 247.5 mm

The units close cleanly: (mm/s)² divided by mm/s² leaves millimetres. The distance grows with the square of the entry speed — raise v1 to 1,000 mm/s with v2 and a unchanged and d = (1,000,000 - 2,500) ÷ 1,000 = 997.5 mm, roughly four times the distance for roughly twice the speed. The decel in the formula is the configured value, and the decel the machine can actually deliver is bounded by the torque the motor and drive produce, so take both numbers from the axis configuration and the datasheet of the exact drive and motor installed.

Decision: compute d for your own speed pair and configured decel; the slowdown write must land before that much travel remains, with a margin for response delay added on top.

Is a slowdown trigger 3 mm before the target early enough? #

No — at the example speeds 3 mm is about 80 times too little: the axis needs 247.5 mm to fall from 500 mm/s to 50 mm/s at 500 mm/s², so the write must land at least 250 mm before the point where the axis must be slow.

That 247.5 mm result answers the question outright: with the response delay from the next section included, roughly 260 mm is the honest trigger position. A 3 mm trigger closes only in a creeping-speed regime: with v1 = 20 mm/s falling to v2 = 10 mm/s at a = 50 mm/s², d = (400 - 100) ÷ 100 = 3 mm, exactly zero margin, so place the trigger earlier even here — 5 mm, say — because one scan of delay eats the budget. If the move also has to stop at the target afterwards, the final decel from the lower cruise speed adds v2² ÷ 2a = 2,500 ÷ 1,000 = 2.5 mm at the example values.

The trigger position is not where the axis is slow — it is where the command changes. The axis is still travelling at close to its entry speed when the comparison becomes true, and it consumes nearly the whole calculated distance while slowing.

Decision: for the example pair put the trigger at about 260 mm before the slow point; for your own pair, at d plus the delay margin, never at a bare minimum with nothing in reserve.

What shapes the deceleration once the new speed value lands? #

Once the new speed lands, the transition itself is shaped by four configured settings — Minimum Velocity, Acceleration, Deceleration and S-Curve — and every millisecond of response delay between trigger and write costs distance: an illustrative 25 ms of combined delay consumes 12.5 mm at the example cruise speed.

The delay arithmetic, illustrative values: a 10 ms scan plus a 5 ms output refresh plus a 10 ms drive pickup totals 25 ms, and 25 ms × 500 mm/s = 12.5 mm — more than four times the entire budget of the creeping example above. Minimum Velocity floors how low the update can take the axis, S-Curve smooths the corners of the transition at the cost of a slightly longer one, and the configured Acceleration and Deceleration set the ramp the instruction rides. How tightly actual velocity follows that ramp is a matter of the drive's tuned loop, which is why the same transition looks different on two mechanically identical axes — see why the KV factor varies from axis to axis.

One caution: a downward command step with too little travel left asks the drive for full decel torque at the worst moment, and motor current and heating rise even when every register write succeeds — keep the configured decel inside what the drive and motor datasheets allow, and treat a current trip as a limit to design around, not a nuisance to clear and retry.

Decision: keep the configured decel at or below what the drive datasheet supports, and buy margin by moving the trigger earlier, not by steepening the ramp.

Why does the speed register write still do nothing? #

Most dead writes trace to one of four causes, and the first three take minutes to check with the programming software in online mode: the wrong executing function, a missing or overwritten enable, a write aimed at the wrong address, or a threshold comparison running in the wrong scale.

Work the list in this order, cheapest first:

  1. Wrong executing function. The unsupported sibling from the section above — the FUN147 case — ignores the update even with the enable present. Confirm which function is executing on the moving channel in the online status display; the fix is instruction selection, not more register writes.
  2. Enable missing or overwritten. R4056 must hold decimal 90 before the write happens, and another block — initialization, mode logic, a second channel's routine — can replace it later in the scan. Confirm with a register monitor showing the value steady through the whole move, plus a program search for every write to that address.
  3. Write aimed elsewhere. The speed value must land in the register the active function was handed at start — HSPS0 in that family — for the channel that is actually moving. Confirm by tracing the written address and the live pulse-output frequency together; the frequency is the truth.
  4. Scale mismatch. A threshold computed in millimetres and compared against raw pulses fires at the wrong physical position or never fires. Convert the threshold with the machine's real scaling — pulse count per revolution, mechanical ratio, travel per revolution — and validate the converted value with a measured slow move. Getting that setup right is the same work as configuring a PLC pulse-output axis before its first moves.

Decision: work top down; a pulse-frequency trace separates a logic fault (frequency never moves) from a scale or tuning fault (frequency moves, motion does not match).

How do I sequence and verify the change on a live axis? #

A working setup shows four events in order on a trace: the enable present before start, the threshold comparison becoming true, the speed value changing, and the pulse rate plus actual speed falling while the original move stays active — if the move restarts, the test proved nothing.

  1. Convert the trigger threshold into the position units the comparison uses, and set it at the calculated distance plus the delay margin.
  2. Confirm the enable value in its register before the move starts.
  3. Start the move at the entry speed and confirm the executing function and channel.
  4. At the threshold, write the lower speed once, on the edge of the comparison, and hold it.
  5. Trend four signals: the enable register, the speed value delivered to the pulse register, the comparison result, and the executing function's active state.
  6. Confirm on hardware that the pulse-output frequency steps down; a changed register value with an unchanged frequency points back to the cause list above.
  7. Mark the commanded position where the write landed and the actual position where the motor reached the lower speed; that gap is the response delay in distance — divide it by the entry speed for the delay in time, and move the trigger earlier by the measured gap if the decel starts too late.

If the pulse rate steps down but the motor never settles at the new lower speed, the transition logic is innocent and the fault is the one described in why a servo axis never reaches its commanded speed.

Decision: the test passes only when the threshold event, the speed-value change and the frequency drop all happen while the same move instruction is still active.

When is a mid-move speed change the wrong tool? #

Skip it when the executing function cannot accept updates: split the travel into two moves, the first ending at an intermediate position at the higher speed and the second starting there at the lower speed, and accept a brief settle at the junction.

The split costs cycle time at the junction and needs no special support, and it verifies with the same trace method as the section above. Where a settle at the junction is unacceptable, the fix is an instruction or controller family with live velocity override, chosen when the axis is specified — not register writes retrofitted onto a function that ignores them. Retargeting an axis that is already decelerating has its own failure mode on stepper axes, the stall covered in why a stepper stalls when retargeted during deceleration, so on steppers prefer the two-move split over a change made mid-decel.

Decision: two-move split when in-motion support is missing and cycle time allows it; live-override hardware when it does not.

Questions asked

Can I speed an axis up mid move with the same method?

Yes, wherever the executing instruction accepts in-motion updates. The same equation applies with the sign flipped: the travel consumed during the speed-up is the difference between the speed squares divided by twice the acceleration setting. A speed-up demands extra torque and current across the whole transition, so check the acceleration setting against the motor and drive ratings before shortening it to save cycle time.

Should the program write the new speed every scan or once?

Once. Trigger the write on the edge of the threshold comparison and hold the lower value afterwards. Rewriting the same value every scan is harmless, but if the axis position hovers around the threshold the logic can toggle between two speeds, restarting the velocity transition repeatedly. That produces surging, extra motor heating and a longer transition than a single clean step.

Where does the deceleration value in the distance formula come from?

From the axis configuration, not from the move instruction on most pulse-output systems. The acceleration and deceleration settings live in the pulse-train-output axis setup and shape every transition, which is why a mid-move velocity change follows those same settings. Read the configured value from your controller's axis configuration, and do not assume the servo drive's own ramp parameters match it.

Does a mid-move speed change move the end position of the move?

No. On controllers that keep the move's target position fixed, a velocity update changes only the cruise speed; the axis still stops where it was commanded. What changes is the travel the final deceleration needs, so recompute that stopping distance from the new cruise speed and the configured decel, and make sure the remaining approach still leaves that much room.

Keep reading

  • How-to

    Configuring a PLC pulse-output servo axis before PLS2 moves

    The drives are not plug and play: keep command scaling in one place, the drive's gearing or the PLC program, and stay under the 100 kHz pulse ceiling, which at 10,000 pulses per revolution caps the motor at 600 rpm. Prove direction, limits and homing first, then tune for the load.

    Servo and stepper motion

  • Troubleshooting

    Make a Servo Jog Follow a Joystick Velocity Demand

    A velocity jog reads its speed operand only when the instruction executes, so a running jog ignores the joystick value until you re-execute it. Strobe the jog every scan with the scaled stick velocity and keep a deadband at neutral; any lag left after that is the acceleration limit, not the command path.

    Servo and stepper motion

  • Troubleshooting

    Troubleshooting a Servo Axis That Faults Mid Move

    An axis that runs a short distance under a held rapid and then stops has tripped the drive's following-error fault. When only the lightly loaded axis of an identical pair fails, and a clean reinstall of the control PC changes nothing, the cause is encoder noise coupled from the motor leads: separate the wiring, ground each shield at one end, and set a 3 µs step pulse before touching tuning.

    Servo and stepper motion

Why one conveyor wobject tracks and two stay still