Robotics & Mechatronics · Closed-loop robot implementation
Test saturation and controller-state recovery
When an actuator request is clamped, a controller’s internal state can continue growing. Compare a supplied integral update with a declared anti-windup rule before interpreting the recovery trace.
All numerical tables, scenarios and records are original constructed teaching data unless a specific external dataset is named. No physical experiment is claimed. A worked simulation model is distinguished from an executed simulator.
Lesson preparation and course links
Use the local explanations and supplied units, diagrams, tables and examples; advanced chapters build on the named local chapters. External links are point-of-need depth, not a requirement to finish an entire map.
Back to the Robotics chapterAfter reading, you can
Compare a supplied integral controller with and without a declared anti-windup treatment under a bounded robot demand.
State the exact discrete model
The fictional controller stores integral contribution I in amperes. Each 0.10 s update proposes I_candidate=
For the comparison, conditional integration accepts the candidate only when it lies within±1 A or the increment moves an already out-of-range state toward the allowed interval. This is the declared simplified rule, not a claim about every framework’s implementation.
Track the internal state as well as the output
Each update adds 0.20×
Both can show the same 1 A output during saturation. Their internal stored state differs, which affects later recovery. Inspecting output alone can hide windup.
Use a supplied reverse-error replay to isolate state recovery
After update 10, a diagnostic replay supplies constant e=
This replay holds error externally for comparison; it is not a closed-loop physical plant simulation. A real reachable-target test must log the actual changing position/error and compare task overshoot, settling and constraints. Anti-windup does not guarantee zero overshoot or correct tuning.
Record the treatment instead of assuming a default
Controllers can use conditional integration, back calculation, reset/tracking or other treatments. Record exact algorithm, gains, output/integral limits, update period and initial state. Official Kilted PID options are version-specific; selecting none differs from enabling a treatment.
On mode switch, stop or restart, specify what happens to I. Clearing a fault without a defined controller-state policy can reapply stored demand. Test that transition separately from nominal tracking.
Follow an unreachable target with a reachable one
A separate executed discrete arithmetic model adds a plant: x_next=
Use r=
Compare target-change recovery
Both controllers share the exact plant and initial state. Each cell is x in mm; I in A; u in A.
| Update/time | r / mm | No treatment: x; I; u | Conditional: x; I; u |
|---|---|---|---|
| 99 / 9.9 s | 10 | 5; 12.7494; 1 | 5; 0.992; 0.992 |
| 100 / 10 s | 2 | 5; 12.6894; 1 | 5; 0.932; 0.932 |
| 109 / 10.9 s | 2 | 5; 12.1494; 1 | 5; 0.392; 0.392 |
| 119 / 11.9 s | 2 | 5; 11.5494; 1 | 4.9736; -0.2072; -0.2072 |
| 149 / 14.9 s | 2 | 5; 9.7494; 1 | 2.603; -0.9984; -0.9984 |
| 200 / 20 s | 2 | 5; 6.6894; 1 | 0.1613; 0.3702; 0.3702 |
State what improved and what did not
At 10 s both plants are at 5 mm. The unrestricted controller still stores about 12.69 A after the target change and remains clamped positive even at 20 s. Conditional integration limits the stored contribution and reverses output by the 11.9 s recorded row, moving toward the reachable target.
The simple integral-only example later overshoots the 2 mm target and is not a well-tuned positioning controller. Anti-windup improves this recovery mechanism; it does not establish settling, stability under arbitrary plants or physical task qualification. Preserve the full calculation record with this example.
Why zero error does not erase stored demand
If the diagnostic error becomes exactly 0 mm, the update increment is zero. I remains 2 A in the unrestricted case or 1 A in the conditional case, and both can still request+1 A. Conditional integration prevented extra storage; it did not automatically reset stored state.
With e=
Try the reasoning
What is the integral increment for e=
3 mm over 0.10 s? Show the answer and reasoning
0.20×
3× 0.10= 0.06 A. Can identical saturated outputs hide different controller state?
Show the answer and reasoning
Yes. Clamping 2 A and 1 A both gives 1 A.
Does zero error force integral state to zero?
Show the answer and reasoning
No. The increment is zero; retained state remains unless another declared rule changes it.
What additional evidence is needed for a physical recovery claim?
Show the answer and reasoning
Actual reference, measured state/error, controller state, applied/measured output, configuration and matched task response.
Does the conditional target-change trace establish a settled 2 mm endpoint?
Show the answer and reasoning
No. It shows earlier controller-state recovery and reversal, then overshoot in this simple supplied model. A task-quality comparison needs its own suitable controller and acceptance evidence.
What to carry forward
Saturation changes the implementation problem. Compare internal state and recovery under a declared algorithm, then test the actual task.
References
Sources supporting this lesson’s explanations and examples.
ros-controls project2 sources