How do you test motion control in custom machines before FAT?
10 min read · By the neexo engineering team · Vejle, Denmark
Published: 25 August 2026
You can test motion sequences, handshakes, axis states, and restart after a fault before the machine is assembled. The twin has to react to the same commands and give the same feedback the PLC expects. Drive tuning, mechanical tolerances, and safety functions still have to be checked on the real machine.
Read the PLC platform guide first
How is testing motion different from connecting the PLC?
A PLC connection only shows that tags can move between the controller and the twin. A motion test asks whether the model answers commands with the timing, states, limits, and faults the production sequence expects. That stops a smooth animation from being treated as proof that commissioning is done.
Use the PLC platform guide for controller setup, communication, and tag mapping. Use this guide to decide how detailed the model needs to be, which commands and feedback the axis must have, how you test restart after a fault, and what still belongs on physical FAT.
The twin should react to commands such as enable, home, move, halt, abort, and reset. It should report standstill, homed, busy, in position, aborted, and error. It must not hide a bad command or report success after a collision or after a limit is passed.
The PLC guide is about getting the controller connected. This one is about whether motion in the twin behaves like the real axis, and which tests you can actually trust.
How detailed does the model need to be?
Choose the detail per test, not as one level for the whole project. Signals with no movement can be enough to see whether the sequence takes the right path. You need positions and zones in the model when the result depends on reach, clearance, or several axes hitting each other in time. A model with forces, or hardware in the loop, only pays off when load, controller timing, or a specific drive behaviour is part of what you must prove.
Write the chosen level and what it does not cover into the test. If backlash, resonance, thermal drift, or torque response is not in the model, do not treat the result as proof of those things.
| Model | Good for | Does not prove |
|---|---|---|
| Signals only | Whether the sequence takes the right path, plus timeout and handshake | Reach, clearance or move time |
| Kinematic model | Position, zones, reach, collision and coordinated timing | Torque, resonance or stopping time |
| Dynamic model | Selected loads or drive behaviour with checked parameters | Certified safety performance |
| Hardware in the loop | Real controller execution and interface timing | Mechanical acceptance without the machine |
Which commands and feedback should a servo axis have?
Keep what you ask the axis to do separate from what it actually reports. Commands can include power or enable, home, an absolute or relative move, halt, abort, and reset. Parameters can include target position, velocity, acceleration, deceleration, and jerk. Feedback should include actual position, standstill, homed, busy, in position, aborted, error, and an error ID.
Take a multi-axis transfer as an example. MoveAbsolute sets busy, position moves through the model, and in position only becomes true inside the agreed tolerance. If a guard or interlock changes, or a software position limit is passed, the model reports the matching fault or abort. The sequence then has to follow the documented reset or home again.
That is less than a full drive emulator on purpose. You reproduce the interface the PLC uses, without claiming that drive tuning or motor physics are in the model.
- Write down who is allowed to send commands, so the PLC, motion controller, and twin do not command the same axis at once
- Say whether each command is a pulse or a held bit, and how it is acknowledged
- Test timeouts and invalid command combinations, not only successful moves
From command to feedback
- 1PLC or motion controllerEnable, home, move, halt, abort, reset
- 2Motion modelPosition, timing, zones, limits, faults you put in
- 3Feedback the PLC seesBusy, homed, in position, aborted, error
Which faults and restarts should you run again after every change?
Restart after a fault is where hidden assumptions in the motion sequence usually show up. For each test, write the starting condition, the fault you put in, the expected order of feedback, what the operator is allowed to do, and the safe end state. Judge the result from the signals, not from the animation.
A short set you rerun after every relevant change should cover lost home, move timeout, abort during motion, a software position limit, drive not ready, in position that never arrives, a robot handshake timeout, a CNC cycle abort, and restart after an emergency stop.
If a command is impossible, make that visible. Reject it, set a defined error, or report collision and limit. Quietly changing the target can hide the same defect that later stops the physical machine.
Make the interface testable before the machine is assembled
We write motion and integration logic and connect it to a testable machine model. Who owns robot and CNC programming is agreed per project.
Explore automation engineeringHow do you test robot and CNC interfaces without copying the whole controller?
On a robot cell the PLC usually exchanges mode, zone, permission, start, busy, complete, and fault with the robot controller. A simplified moving model can test that handshake when paths and robot-specific logic are out of scope. You need current cell geometry when reach or clearance is the question.
On a CNC station, model the line handshake: ready for load, clamped, cycle start, cycle active, cycle complete, alarm, and reset. Do not simulate G-code or cutting unless a specific acceptance test depends on it.
Robot and CNC program versions still matter. Tie the interface test to the PLC version, parameter set, robot or CNC program version, twin version, and signal list, so a timing change cannot pass against an old baseline.
How should limits, zones, and safety functions show up in the twin?
Keep four things separate. Hardware travel limits come from physical switches or drive inputs. Software position limits are configured positions that make the controller or drive react. Zones describe allowed or forbidden geometry. Safety functions such as STO, SS1, SOS, or SLS have defined behaviour in the safety system.
The twin can run the standard control sequence around these conditions and can report simulated status for testing. It does not prove certified safety hardware, how fast the machine stops, where guards sit, or the safety calculation.
Tie every modelled limit and zone to the drawing or parameter version it came from. When stroke, tooling, frames, or guarding change, the model and the affected tests have to change with them.
What still has to wait for physical FAT?
From the twin you should keep the interface definition, scenario inputs, expected and actual state changes, software versions, deviations, and pass criteria. Save enough to rerun a failed test after a PLC or model change.
Physical FAT still checks drive tuning, following error under load, backlash, mechanical tolerances, vibration, thermal behaviour, stopping, guards, sensors, wiring, and safety functions. The virtual result lowers integration risk. It does not prove things you never put in the model.
neexo writes motion and integration logic and connects it to a testable machine model. Who owns robot and CNC programming is agreed per project, together with what you expect from virtual commissioning and from physical FAT.
Frequently asked questions
Can virtual commissioning tune a servo drive?
Not as a default. A representative move time can support sequence testing. Gain, resonance, torque response, and following error under load still need the physical drive, mechanics, and measurement, unless a checked dynamic model is explicitly part of the job.
How accurate must the robot kinematics be?
Match the accuracy to the test. Handshake and state tests can use a simplified moving model. Reach, clearance, collision, and shared zones need current geometry, tool frames, and an agreed tolerance.
Should the twin stop an invalid move by itself?
It should make the invalid condition visible on the agreed interface. Reject the command, or report a defined limit, collision, abort, or error. Quietly changing the target can hide a defect in the PLC sequence.
Can OPC UA replace a real-time motion bus?
No. OPC UA is useful for higher-level commands, state exchange, and a visualization link. Hard real-time servo loops and certified safety communication stay on the controller and the networks built for that.
Does a passed virtual test replace physical FAT?
No. It documents the modelled interface and the scenarios you ran. Physical FAT still covers mechanical, electrical, drive, sensor, stopping, guarding, and safety properties that the model does not prove.
Technical sources
Related reading
Start with one axis interface and one restart after a fault. Lock the PLC version, motion parameters, signal list, and twin version, then rerun the same test after every relevant change.
Book a clarification call