Troubleshooting
Why a pulse-command servo axis will not tune closed loop
Short answer
A pulse-command servo axis cannot be tuned while two devices fight over the position loop, the feedback sign is reversed or the pulse-to-distance scale is wrong. Establish which device closes each loop, prove direction and travel with a small move, then tune inner loops before any outer loop.

On this page
A pulse-command servo axis that refuses to tune almost never has a gain problem. It has an architecture, polarity or scaling problem, and no amount of gain adjustment fixes those. Work through the checks below in this order, cheapest first, and do not touch a gain until every one passes. If the axis also drifts between moves, the causes overlap with those in why a pulse-command servo axis loses position between moves.
Establish which device owns each loop #
A pulse-command system is cascaded by design. The drive closes the current and velocity loops on the motor encoder, and in the common case it closes the position loop too: the controller's pulse output is only a position command, and the controller has no feedback of its own. A controller axis card may also close an outer position loop, but only when a second feedback device (a linear scale or an external encoder) is wired back to it. The consequences of that choice are covered in where the position loop closes decides your servo conversion.
Two devices both closing a position loop around the same axis fight each other: the axis oscillates or hunts no matter how the gains are set. Before anything else, record which device receives the motor feedback and which receives any axis feedback, and make sure exactly one of them owns position. When the controller sends pulses and receives nothing back, all tuning happens in the drive.
Confirm the pulse interface settings #
A pulse input on the drive has a type setting (the format the pulses arrive in, for example sign-and-pulse or quadrature) and a polarity or direction setting that decides which electrical sign means positive. The controller's pulse output has matching settings. If the two sides disagree on format, the drive counts the wrong edges and the axis runs at a fraction of its commanded speed or not at all. Take the setting names and allowed values from the manual of the exact drive and controller you have; there is no common naming across brands.
Check enable, limits and alarm states #
Before the first move, confirm the drive is enabled, has no active alarm, and is not held by an inhibit, a travel limit or a missing enable signal. An axis that will not move at all is an interface or state problem, not a tuning one, and the wiring logic for the enable is its own subject in why a servo amplifier enable should follow the software axis state.
Run the direction test #
With the load disconnected where the machine design allows, the machine's safety controls active and the gains at their safe starting values, command a small move in the positive direction. Confirm three things: the motor actually turns, it turns the commanded way, and the position value the drive reports changes with the same sign as the command. If the motor runs the wrong way or the reported position runs opposite to the command, you have a polarity fault: positive feedback, which is why the axis buzzed or faulted when you raised the gain. Fix the documented command or feedback polarity setting and repeat the move. Never compensate a reversed sign with a negative gain; it hides the fault and breaks the first maintenance technician who inherits the axis.
Prove the pulse-to-distance scale #
Direction correct, the next failure is magnitude. Command a known distance and measure what the axis actually travels, or read the drive's position indication. A consistent ratio between commanded and measured travel is a scaling error, not a tuning error.
Worked example, calculated from these example inputs, not a measured result: the controller commands 10.00 mm, the axis moves 8.00 mm, and the controller is configured for 10000 pulses per mm of command. Pulses sent: 10.00 mm x 10000 pulses/mm = 100000 pulses. The axis moved 8.00 mm, so the drive actually consumes 100000 pulses / 8.00 mm = 12500 pulses per mm of travel. Correct the drive's electronic gear ratio (or the controller's output scale) so both sides agree, then re-command the 10.00 mm move and confirm 10.00 mm of travel before going further. The same class of fault produces the symptom described in stepper axis travels 1.25 times the commanded distance.
If the ratio between commanded and measured travel is not consistent but wanders, the cause is mechanical (slipping coupling, lost pulses on a noisy line) and scaling will not fix it; chase the pulses and the mechanics first.
Tune in the right order #
Only now touch gains, and tune inside out:
- If the drive offers real-time auto tuning, use it: the drive estimates the ratio of load to motor inertia and sets its internal control parameters for that load. Run it with the motor connected to the real load.
- Tune or verify the drive's current and velocity loops before any position loop; an outer loop cannot stabilize an inner loop that is already unstable.
- Tune the drive's position loop (following error at constant velocity, overshoot at the end of a move) with conservative gains, raising them while watching for oscillation.
- Tune a controller-side outer loop last, and only if the architecture genuinely has one.
- At any instability, stop and re-run the checks above: a fault found here is nearly always polarity, scaling or loop ownership, not a gain that is too high.
Verify closed-loop operation #
Run repeated moves in both directions at working speed and compare the commanded position, the measured position and the final error at rest. The setup passes when direction and travel are consistent, the final error settles with no drift and there is no sustained oscillation. If it still fails, capture the command pulse count, the drive's position indication, the drive state and any alarm during one small move: those traces separate a command-interface fault from a scaling, polarity, mechanical or gain fault, and that capture is what you take to the drive vendor's support line.
The decision, per case: axis dead, fix enable, limits and pulse format first; axis runs the wrong way or oscillates at any gain, fix polarity; axis travels a consistent wrong distance, fix the scaling; axis travels correctly but performs poorly, now tune, inner loops before outer, auto tuning first if the drive has it.
Questions asked
Can auto tuning fix a pulse-command axis that will not close?
Auto tuning inside the drive estimates the load inertia ratio and sets the motor-side loops, but it cannot correct a reversed command-to-feedback sign, a wrong pulse format or a scaling mismatch between the controller and the drive. Run those checks first; auto tuning only helps once the drive's own loops are the ones being tuned.
The drive buzzes and faults as soon as I raise the gain. What does that point to?
Sustained oscillation at low gain usually means positive feedback: the counted direction of the pulse input or the encoder sign is opposite to the command direction. It can also mean two devices both close position loops around the same axis. Check the direction test and loop ownership before raising any gain again.
Which device should close the position loop on a pulse-command axis?
By default the drive closes position, velocity and current loops on its motor encoder, and the controller only issues pulses as a position command with no feedback of its own. Add an outer loop in the controller only when the machine has a second feedback device, such as a linear scale, and the axis is configured for it. Never let both devices close position loops on the same axis at once.
How small should the first test move be?
Small enough that a wrong direction or a runaway cannot damage the machine: a few millimetres or a few degrees at low speed, with the load disconnected where the design allows and the machine's safety controls active. The point of the move is to read direction and travel, not performance, so keep gains at their safe starting values.


