Robot Control Basics: Dynamics, Feedback, and Tracking Error

3 minute read

Published:

TL;DR: Dynamics describes how forces and torques change motion. A feedback controller compares measured behaviour with a target and updates its commands. A learned policy must match the controller's action interface, units, and timing.

Reaching a pose is also a physical problem

Intuition first. The same joint-position target can produce different motion when an arm holds an empty gripper or a heavy object. Kinematics describes the target geometry. Dynamics accounts for inertia, gravity, and other forces along the way.

A simplified rigid-joint robot equation is

\[ M(q)\ddot q+C(q,\dot q)\dot q+g(q) =\tau+\tau_{\mathrm{ext}}. \]

Here \(M\) is the inertia matrix, \(C\dot q\) collects velocity-dependent terms, \(g\) is gravity torque, \(\tau\) is actuator torque, and \(\tau_{\mathrm{ext}}\) represents external joint torques. Real systems may also need friction and actuator models. Dynamics background.

Feedback closes the loop

Let \(q_d\) be the desired joint position and \(e=q_d-q\) the tracking error. A proportional-derivative torque controller has the form

\[ \tau=K_p(q_d-q)+K_d(\dot q_d-\dot q). \]

The position term reacts to displacement error; the velocity term can provide damping. A PID controller adds an accumulated-error term. Integral action can remove some persistent offsets, but needs care when commands saturate because the integral can keep growing.

The Modern Robotics control introduction distinguishes motion, force, and impedance objectives. Tracking position is only one possible control task.

Feedback turns tracking error into a commandThe measured motion returns to the comparison at the next update. A disturbance changes what must be corrected. Target minus estimateController commandMeasured motion
The measured motion returns to the comparison at the next update. A disturbance changes what must be corrected.

Worked example: a single-joint command

Take a stationary target \(q_d=1.0\) radian, current position \(q=0.8\) radians, and velocity \(\dot q=0.1\) radians per second. Let \(K_p=10\;\mathrm{N\,m/rad}\) and \(K_d=2\;\mathrm{N\,m\,s/rad}\). Then

\[ \tau=10(1.0-0.8)+2(0-0.1) =1.8\;\mathrm{N\,m}. \]

The derivative term reduces the torque because the joint is already moving towards the target. If the velocity instead were \(-0.1\) radians per second, the command would be 2.2 newton-metres.

These numbers illustrate the law, not gains validated for a particular robot. Whether the joint accelerates as desired also depends on gravity, inertia, disturbances, and actuator limits.

Increasing a gain is not an unlimited improvement

A larger proportional gain can reduce position error in some regimes, but delay, sampling, noise, and unmodelled dynamics can produce oscillations. A torque limit also means the actual input may differ from the requested one. Analyse the controlled system, not the formula in isolation.

For contact tasks, an impedance objective specifies a relationship between displacement and force, like a virtual spring and damper. It can permit compliant interaction instead of insisting on an exact position against a rigid surface. The appropriate objective depends on the task and available sensing.

Where learning connects

A policy may output position targets tracked by a lower-level controller. Another policy may output torque directly. Those systems have different responsibilities even when both are described as “end-to-end robot learning.”

Residual RL learns corrections to a baseline controller. Learned MPC predicts candidate futures and replans. Both still rely on measurements and an explicit command interface.

Key Insight: A desired action and an achieved motion are different objects. Feedback supplies the correction between them; dynamics determines how that correction affects the physical system.

Continue with robot-learning basics to compare the signals used to train a policy.

References

  1. Lynch, K. M., & Park, F. C. Modern Robotics: Control System Overview.
  2. Tedrake, R. Underactuated Robotics: Introduction.