The end effector trajectory controller computes velocity commands to track a moving object's pose and twist. The controller uses a proportional control law with latency compensation to predict the object's future state.
-
$\mathbf{p}_{ee}(t)$ : End effector position at time$t$ -
$\mathbf{R}_{ee}(t)$ : End effector rotation matrix at time$t$ -
$\mathbf{v}_{ee}(t)$ : End effector linear velocity at time$t$ -
$\boldsymbol{\omega}_{ee}(t)$ : End effector angular velocity at time$t$ -
$\mathbf{p}_{obj}(t)$ : Object position at time$t$ -
$\mathbf{R}_{obj}(t)$ : Object rotation matrix at time$t$ -
$\mathbf{v}_{obj}(t)$ : Object linear velocity at time$t$ -
$\boldsymbol{\omega}_{obj}(t)$ : Object angular velocity at time$t$ -
$k_P^{pos}$ : Position proportional gain -
$k_P^{rot}$ : Rotation proportional gain -
$\tau$ : System latency -
$\Delta t$ : Simulation timestep
The positional error is computed as:
The rotational error is computed in the end effector frame:
The rotational error vector $\mathbf{r}{err}$ is extracted from $\mathbf{R}{err}$ using the rotation vector representation:
The desired linear velocity combines the object's velocity with a proportional correction term:
Similarly, the desired angular velocity is:
The velocity command (delta twist) is the difference between desired and current velocities:
To account for system latency
The rotation is integrated forward:
where
The controller simulates the end effector trajectory over a horizon
-
Initialize: $\mathbf{p}{ee}(0) = \mathbf{p}{ee,0}$, $\mathbf{R}{ee}(0) = \mathbf{R}{ee,0}$, $\mathbf{v}{ee}(0) = \mathbf{v}{ee,0}$, $\boldsymbol{\omega}{ee}(0) = \boldsymbol{\omega}{ee,0}$
-
For each timestep
$k = 1, 2, \ldots, N$ where$N = \lfloor T / \Delta t \rfloor$ :-
Predict object pose at
$t + \tau$ : $$\mathbf{p}{obj}^{pred} = \mathbf{p}{obj}(k) + \mathbf{v}_{obj}(k) \cdot \tau$$ -
Compute velocity command
$\Delta \mathbf{v}(k)$ ,$\Delta \boldsymbol{\omega}(k)$ using the equations above -
Update end effector velocity: $$\mathbf{v}{ee}(k+1) = \mathbf{v}{ee}(k) + \Delta \mathbf{v}(k)$$ $$\boldsymbol{\omega}{ee}(k+1) = \boldsymbol{\omega}{ee}(k) + \Delta \boldsymbol{\omega}(k)$$
-
Integrate end effector pose: $$\mathbf{p}{ee}(k+1) = \mathbf{p}{ee}(k) + \mathbf{v}{ee}(k+1) \cdot \Delta t$$ $$\mathbf{R}{ee}(k+1) = \mathbf{R}{ee}(k) \cdot \exp(\boldsymbol{\omega}{ee}(k+1) \times \Delta t)$$
-
Integrate object pose (assuming constant velocity): $$\mathbf{p}{obj}(k+1) = \mathbf{p}{obj}(k) + \mathbf{v}{obj}(k) \cdot \Delta t$$ $$\mathbf{R}{obj}(k+1) = \mathbf{R}{obj}(k) \cdot \exp(\boldsymbol{\omega}{obj}(k) \times \Delta t)$$
-
The controller configuration includes:
-
$k_P^{pos}$ : Position proportional gain (units: s$^{-1}$) -
$k_P^{rot}$ : Rotation proportional gain (units: s$^{-1}$) -
$\tau$ : System latency (units: s) -
$T$ : Simulation horizon (units: s) -
$\Delta t$ : Timestep (units: s)
- The controller uses feedforward from the object's velocity, enabling tracking of moving targets
- Latency compensation reduces tracking error for delayed systems
- The proportional control law ensures convergence to zero position and rotation error for static targets
- The controller is suitable for real-time trajectory generation and simulation