To control the vessel, guidance systems will be expected to continuously output a vector of 3 forces, in surge (forward/backward), sway (lateral) and yaw.
The example_ros_client node is published to the /force_control topic and expects ‘GeneralizedForce’ messages. The message is built up of 3 forces, one for each translational degree of freedom, as well as 3 torques, for each rotational degree of freedom.
x = force.x,
y = force.y,
z = force.z,
k = force.k,
m = force.m,
n = force.n,
As the vessel is only actuated in 3 degrees of freedom (x, y and n), the remaining 3 forces (z, k and m) are ignored and should be set to 0.
The force controller accepts inputs between -100 and 100, where 100 results in full throttle. Larger inputs will be constrained back down to ±100.
The force controller can be tested by opening a terminal window in the virtual machine and tweaking the values in the following command: