The controller node should not call resetSetpoint() in headingHold and depthHold when they are not active.
if (activate_headinghold)
{
...
}
else
{
resetSetpoints();
tau.setZero();
}
This is a problem when the different controllers is combined; like in depth and heading hold control mode.
The controllers should only be able to change the setpoint of the state they are regulating. Eg. depthHold should only be able to change the heave setpoint.
Fixing this fixes the ROV "floating" away from its depth hold setpoint when we are changing the yaw state with control command from joystick.
The controller node should not call
resetSetpoint()
in headingHold and depthHold when they are not active.This is a problem when the different controllers is combined; like in depth and heading hold control mode.
The controllers should only be able to change the setpoint of the state they are regulating. Eg. depthHold should only be able to change the heave setpoint.
Fixing this fixes the ROV "floating" away from its depth hold setpoint when we are changing the yaw state with control command from joystick.