The Controller module is responsible for execution of planned trajectories on the robot. It does this by tracking the trajectory, and thus is sometimes referred to as a trajectory tracker.
The Controller module receives a time series of robot states, then interpolates to find the desired state to achieve. It generates a control command to achieve this state using the algorithms described below. It is configured to run as fast as or faster than the odometry rate, which is typically set to 50-100Hz.
Currently, the following drive trains are supported:
Differential drive
Inputs
PoseTree: The library providing the pose frame transform queries
Trajectory: The input trajectory to track
State: The state estimate to indicate the robot’s current pose
Robot remote control: An optional link to the remote controller, so as to only send commands when in Autonomy mode. The robot can operate in three modes: Autonomy, Manual, and Teleoperation.
The controller codelet additionally has algorithmic parameters, which are detailed in the API documentation.
Outputs
Command: A tuple of linear and rotational (angular) velocities to drive the robot
Currently, the Controller module supports two algorithms: Backstepping Controller and PID Controller.
Backstepping Controller
This is the default controller, which computes errors in the state variables (position, heading) and uses the errors to select commands to drive the robot.
PID Controller
When the use_pid_controller
parameter is set to True
, the PID controller is enabled and used
to track the trajectory while controlling for drift and error.
NvIsaacControllerExtension
Extension containing control operators.
nvidia::isaac::AckermannControlOperator
Generates control messages for an Ackermann base from a trajectory
Parameters:
- name
- lookup_name
- description
- flags
- type
- default
Atlas
atlas
Link to ATLAS
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Allocator
allocator
Memory allocator for tensor
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Command
command
Calculated Ackermann base command
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
State
state
Robot state from Odometry
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Trajectory
trajectory
Timeseries of Ackermann base states
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Use PID Controller
use_pid_controller
Whether to use the Ackermann PID controller
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_BOOL
N/A
- name
- lookup_name
- description
- flags
- type
- default
PID Controller Baseline
pid_controller_baseline
Baseline in meters of the robot, for use in the PID controller
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_FLOAT64
0.5
- name
- lookup_name
- description
- flags
- type
- default
Time Offset to Compensate for Command Delay
command_delay
A look-ahead time (in seconds) to get the current command from the received plan in order to compensate delay in execution of the command. Control at current_time + command_delay is sent.
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_FLOAT64
0.0
nvidia::isaac::DifferentialBaseController
Generates control messages for a differential base from a trajectory
Parameters:
- name
- lookup_name
- description
- flags
- type
- default
Sight
sight
A sight transmitter handle.
GXF_PARAMETER_FLAGS_OPTIONAL
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Rebot Remote Control
robot_remote_control
Optional link to a RebotRemoteControl, if provided, the controller will only be active if isAutonomyOn is true.
GXF_PARAMETER_FLAGS_OPTIONAL
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Atlas
atlas
Link to ATLAS
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Allocator
allocator
Memory allocator for tensor
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Output Command
tx_command
The command to be executed to follow the trajectory
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Input State
rx_state
Current state of the robot.
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Input Trajectory
rx_trajectory
The trajectory we aim to follow.
GXF_PARAMETER_FLAGS_NONE
GXF_PARAMETER_TYPE_HANDLE
N/A
- name
- lookup_name
- description
- flags
- type
- default
Estimate Delay
estimate_delay
Estimate the delay between the command and its execution automatically. If false the command_delay will be used instead.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_BOOL
True
- name
- lookup_name
- description
- flags
- type
- default
Delay Estimation Half Period
delay_estimation_half_period
Amount of time accounting for half of the current average.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_FLOAT64
1.0
- name
- lookup_name
- description
- flags
- type
- default
Delay Estimation Minimum Score
delay_estimation_minimum_score
Minimum score to accept the estimated delay.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_FLOAT64
0.98
- name
- lookup_name
- description
- flags
- type
- default
Forward Command
forward_command
Simply forward the command from the trajectory
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_BOOL
True
- name
- lookup_name
- description
- flags
- type
- default
Use PID Controller
use_pid_controller
Whether to use the Differential PID controller
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_BOOL
False
- name
- lookup_name
- description
- flags
- type
- default
Controller Epsilon Gain
controller_epsilon_gain
Gain used to compute the forward gain.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_FLOAT64
1.0
- name
- lookup_name
- description
- flags
- type
- default
Controller B Gain
controller_b_gain
Gain used to compute the heading gain.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_FLOAT64
1.0
- name
- lookup_name
- description
- flags
- type
- default
Time Offset to Compensate for Command Delay
command_delay
A look-ahead time (in seconds) to get the current command from the received plan in order to compensate delay in execution of the command. Control at current_time + command_delay is sent.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_FLOAT64
0.2
- name
- lookup_name
- description
- flags
- type
- default
Forward Error PID parameters
pid_pos_x
Parameters of the PID controller for the forward error.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_FLOAT64
2.7794473e-316
- name
- lookup_name
- description
- flags
- type
- default
Latteral Error PID parameters
pid_pos_y
Parameters of the PID controller for the latteral error.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_FLOAT64
3.206754e-316
- name
- lookup_name
- description
- flags
- type
- default
Heading Error PID parameters
pid_heading
Parameters of the PID controller for the heading error.
GXF_PARAMETER_FLAGS_DYNAMIC
GXF_PARAMETER_TYPE_FLOAT64
2.6972411e-316