Troubleshooting
Why a PTO stepper axis inflates S7-1200 cycle time
Short answer
Hardware PTO pulse generation runs outside the cyclic scan, so a 10 kHz axis on a CPU 1212C should not by itself push cycle time from about 13 ms at idle to over 150 ms. The load comes from configuration or software: interrupt-enabled inputs wired from the pulse signals, a too-short motion processing interval, or blocks left in OB1. Run the checks in order before buying a larger CPU.

On this page
- What the pulse hardware does not do
- Confirm the scaling before anything else
- Run the control panel test with an empty OB1
- Audit interrupt-enabled inputs wired from the pulse signals
- Check how often the motion calculations run
- Read the diagnostic buffer, then decide about the controller
- The checks in order, and the decision each one gives
- Questions asked
A stepper axis on a hardware pulse output is one of the lightest loads a small PLC can carry: the pulse generator produces the pulses in dedicated hardware, and the cyclic program never touches them. The data sheet for this CPU, the 1212C with order number 6ES7 212-1AE40-0XB0, lists the pulse output limit frequency as 100 kHz, so the 10 kHz command in the reported commissioning case uses a tenth of what the hardware can do. When cycle time climbs from about 13 ms at idle to over 150 ms with the axis moving, the pulses are not the cause; configuration and software are. The suspects, cheapest to check first, are an interrupt-enabled digital input wired from the pulse or direction signal, the interval at which the axis's motion calculations run, and application blocks still executing in OB1. Work down that list before selecting a larger controller family.
What the pulse hardware does not do #
In pulse-and-direction mode, output A carries the pulse train and output B carries the direction level. Both belong to a single pulse channel configured in the device configuration, which is also where the channel's maximum PTO frequency is set. Once enabled and given a frequency, the generator toggles the outputs in hardware, and the scan does not execute once per pulse; pulse generation is deliberately kept off the processor's cyclic path.
So the pulse rate itself cannot add scan time. If cycle time rises only while the axis is commanded to move, something tied to motion is being executed by the scan: an input interrupting on every pulse edge, motion processing on a very short schedule, or application logic that runs while the axis moves. Those are the places to look, in that order.
Confirm the scaling before anything else #
The reported operating point is 20 mm/s at a 10 kHz command frequency. From those two reported readings, the implied command scaling is:
10,000 pulses/s ÷ 20 mm/s = 500 pulses/mm
That is a calculated example from the reported numbers, not an independent measurement of travel. Confirm it against the axis configuration and the drive: pulses per motor revolution, the gearbox or belt ratio between motor and screw, and the screw pitch have to multiply out to the same pulses per millimetre. The step-by-step conversion is set out in How to Calculate Step and Direction Servo Pulse Scaling.
A mismatch decides whether the pulse hardware can deliver the speed target at all. If the configured scaling were, for example, 5,000 pulses/mm — ten times what the mechanics need — holding 20 mm/s would demand 5,000 × 20 = 100,000 pulses/s, which is 100 kHz, right at this CPU's pulse limit, and any speed above the current target would be out of reach. Correcting the scaling brings the commanded frequency back down; it does not by itself remove scan load, because the hardware still generates whatever frequency is commanded.
Run the control panel test with an empty OB1 #
The axis control panel is built for this: it moves the axis in manual mode and tests the system without the application sequence. From a backed-up project, comment out the calls in OB1, download, and command motion from the control panel while watching the cycle time online.
The reported result of exactly that test: with nothing of the user program executing in OB1, cycle time still sat above 100 ms while the control panel moved the drive. That largely clears the sequence logic, and it narrows the field to what still runs in an emptied scan — hardware interrupts, communication, and the technology object's own motion processing.
The fork in this test is the diagnosis. If cycle time falls back to the idle baseline once OB1 is emptied, the load lived in the user program, and the fix is scheduling rather than silicon: fixed-interval work such as sampling or PID belongs in a cyclic interrupt with a chosen execution time instead of piled into OB1, which is exactly the split covered by the guide on when to use cyclic interrupts instead of OB1. If the cycle stays high, go to the interrupt audit next.
Audit interrupt-enabled inputs wired from the pulse signals #
The configuration fault that best matches these symptoms is a pulse or direction line wired to a digital input whose channel has a hardware interrupt or a counter function enabled. Every edge on that input then costs the processor work, so scan load rises in step with axis speed — cycle time that tracks the moving axis, and a CPU that faults when the speed target goes up, is precisely this pattern.
Check the device configuration channel by channel: every digital input with an interrupt or counting function enabled needs an intentional reason to exist. Anything wired from the pulse or direction outputs that is not deliberate feedback should be rewired or have its interrupt disabled. Counting a pulse output as if it were an encoder is a known trap; Counting Encoder Pulses on a PLC Without Losing Position shows where genuine feedback counts belong and how to keep them from losing position.
Treat this as the first prime suspect rather than a theoretical one: it is the only mechanism in this list that makes scan load proportional to pulse frequency.
Check how often the motion calculations run #
The technology object's motion processing runs on its own schedule, and that schedule is a configuration setting: an execution interval, distinct from the period of each output pulse. A very short interval spends processor time on every pass without changing what the hardware pulse generator produces — the pulses stay exactly as commanded while the scan carries the motion arithmetic at the configured pace.
Read the configured interval in the axis technology settings and compare it with the documented range for motion control on this CPU family in the S7-1200 Motion Control function manual, rather than substituting a guessed value. If it was set aggressively short during commissioning, set the documented value, download, and re-measure at the same commanded speed. A correct interval shows up as a lower steady cycle time with the axis running; it should not change the motion itself.
Read the diagnostic buffer, then decide about the controller #
Two things live here. The STOP itself is the first: the CPU properties carry a cycle monitoring time, and a cyclic scan that overruns it faults the CPU to STOP — the reported stop past 300 ms of cycle time is that watchdog doing its job, not a separate fault. Raising the limit only lets an overloaded scan keep running, so use it at most to finish a diagnosis, and leave the documented value in place for anything that runs production.
The evidence is the second. The diagnostic buffer stores events in a circular buffer with the newest event as number 1 and the oldest as number 50; read it immediately after a stop and record the entry texts in order, because continued running pushes the earliest entries out. A buffer entry naming a cycle-time overrun while the axis moves, read together with the control panel test and the interrupt audit, names the cause explicitly instead of leaving a large number in the online cycle display.
Only one outcome justifies a larger controller: a minimal project — OB1 emptied, no enabled input interrupts, the documented motion interval — that still overruns while the axis alone runs at a frequency well inside the pulse limit. Then the motion workload has genuinely saturated this CPU size. Nothing in the reported readings has reached that point yet.
The checks in order, and the decision each one gives #
- Baseline with motion off: read the current cycle time online and expect roughly the reported idle figure of 13 ms.
- Scaling: compute pulses per millimetre from commanded speed and frequency — here 500 pulses/mm implied — and match the technology object and the drive to it.
- Control panel test with OB1 emptied: a falling cycle clears the user program; a staying cycle points at interrupts or motion scheduling.
- Interrupt audit: every digital input with interrupt or counting functions enabled must have an intentional reason, and nothing may be wired from pulse A or direction B unless it is deliberate.
- Motion interval: set the documented value from the function manual and re-measure at the same commanded speed.
- Diagnostic buffer after any stop: record the entry text before continued running overwrites it.
- A larger CPU only if the minimal project from steps 3 and 4 still overruns at a frequency well inside the pulse limit.
| Result during the tests | What it tells you |
|---|---|
| Cycle falls back to the idle baseline with OB1 emptied | The user program carried the load; reschedule fixed-interval work into a cyclic interrupt |
| Cycle rises the moment pulses run, even in the minimal project | An interrupt-enabled input or the motion interval, not the pulse hardware |
| Cycle rises only as the axis speeds up | Per-edge work: a pulse or direction line feeding an interrupt or counter input |
| STOP, and the buffer names a time overrun | The cycle monitoring time was hit; treat it as the symptom and fix the load |
For the reported axis, steps 3 to 5 carry the answer: the control panel result already points away from the user program and toward interrupts or motion scheduling, and a 10 kHz PTO axis is nowhere near a reason to move controller families.
Questions asked
Can the pulse output be driven without the positioning technology object?
Yes. The CTRL_PTO instruction outputs a pulse train at a frequency the program sets, with no positioning axis technology object involved. Driving the stepper drive with it while the motion instructions are removed separates plain pulse generation from motion processing: if the scan stays long even then, the technology object is not the source, and the search moves to interrupts and the user program.
Can the diagnostic buffer be read without a TIA Portal connection?
Yes. With the CPU's web server enabled in the device configuration, the standard Diagnostics Buffer page lists the same events in a browser, newest first. Record the entries right after a stop, because the buffer is circular and keeps 50 events; continued running pushes the stop entry toward the end and eventually out.
What do the time base and pulse duration format fields do?
They describe how the pulse channel expresses pulse width and duration; in the reported configuration the time base read milliseconds and the pulse duration format read hundredths, and neither field could be changed. They are representation settings for the pulse channel, not performance settings, so reading or changing them cannot reduce scan load or explain a long cycle.
Which cycle time figure should be compared between tests?
Compare the current reading, and clear or note the maximum separately: online diagnostics show current, minimum and maximum since the last reset, and a stored maximum keeps an earlier excursion visible after the present load has fallen. Record the axis state alongside each reading too, so acceleration, steady travel and dwell are not mixed into one number.