**6. Path following**

While the REMUS UUV and SeaFox USV are both commercial vehicles with proprietary autopilots, both provide communications interfaces that allow experimental sensor and computer payloads to override the primary autopilot via high-level commands. The REMUS RECON interface, for example, closely resembles the augmented autopilot depicted in Figs. 2 and 3 (although direct actuator inputs are only available for propeller and cross-body thrusters settings). For full overriding control, a payload module must periodically send valid commands containing all of the following: i) desired depth or altitude, ii) desired vehicle or propeller speed, and iii) desired heading, turn rate, or waypoint location. The developed trajectory generator (described in Section 3) outputs reference trajectories as parameterized expressions for each coordinate in a spatial curve plus a speed factor to use while traversing that curve. Using these expressions as reference trajectories, the 3D path following controller developed earlier (Kaminer et al., 2007) can compute turn rate and pitch rate commands required to drive a vehicle onto (and along) the desired trajectory. The RECON interface, however, does not accept pitch rate commands (for vehicle safety reasons). Therefore, in order to use the aforementioned path following controller to track 3D trajectories with the REMUS UUV, controller outputs must be partitioned into horizontal (turn rate) and vertical (depth or altitude) commands as described in the following section (obviously, the SeaFox USV only uses the turn rate commands).
