Concept
Both the Payload Estimator and Payload Compensator are implemented as classes, designed for use in Object-Oriented Programming (OOP) frameworks. Implementations are available for C++, Python and ROS2, each with corresponding SDKs.
Key Concepts
FT Stack Compatibility
Designed to be easily used in combination with other components.
JSON-Based Configuration
Configuration is handled through a JSON file passed to the class constructor.
Important
For the both estimator and compensator, the wrench and IMU measurements are expected to be in the same frame.
Usage pattern
To be able to discount the payload effects from the force-torque measurements, one must follow the next steps:
Step 1. Payload estimation
The first step is to know the payload properties, such as its mass, center of mass and inertia.
These properties could be obtained either through manufacturer specifications if available, or physical measurements.
If the payload is unknown, it needs to be estimated through physical measurements. An algorithm to do so is encapsulated in Bota Payload Estimation block. The algorithm leverages the wrench and IMU measurements offered by Bota’s FT Sensors.
The usage pattern for this block is shown in the image below. The FT Sensor driver should be connected to the Payload Estimator, which will then process the sensor data to estimate the payload properties. If desired, an input filter can be stacked between the driver and the estimator, so as to improve the signal quality for the estimation, for example, reducing the noise level.
Payload estimation pipeline
While the algorithm is running and the data is flowing from the driver to the estimator, the payload must be moved around, generating enough rich data for the estimator to work.
If the estimation is successful, the estimated payload properties will be returned.
Step 2. Payload compensation
Once the payload properties are known, they can be used to discount their effect from the raw wrench measurements.
Note
For the payload compensator to work, the payload properties must be expressed with respect to the measuring frame in which the wrench measurements are provided.
The usage pattern for the compensator block is shown in the image below. The FT Sensor driver should be connected to the Payload Compensator, which will then process the sensor data to compensate for the payload effects. If desired, an input filter can be stacked between the driver and the compensator to improve the signal quality for the compensation, for example, reducing the noise level. Likewise, an output filter can also be added on the compensated wrench, before the application.
Payload compensator pipeline
Configuration files
Payload Estimator
The JSON configuration file required to construct a payload estimator object must have the following structure:
Payload Estimation Configuration JSON File Structure
Basic configuration
output_config_file_name
string
Name of the JSON file to which the estimated payload will be written.
The exported file will follow the structure of Payload Compensator JSON file
runtime_verbosity
bool
Enable/disable console output at runtime
min_time
double
Minimum time the algorithm will run
max_time
double
Maximum time the algorithm will run
Prior Payload Properties
prior_payload_properties
object
It must have the following fields:
mass
double
Prior estimate of payload mass, in kg.
com
double[3]
[x,y,z] Prior estimate of payload center of mass, in m.
inertia
double[6]
[Ixx, Ixy, Ixz, Iyy, Iyy, Iyz, Izz] Prior estimate of payload inertia tensor, in kg·m².
Measurement noise covariance
measurement_noise_covariance
object
It must have the following fields:
force
double[3]
[x,y,z] Noise covariance of the force measurement, in (N)².
torque
double[3]
[x,y,z] Noise covariance of the torque measurement, in (N·m)².
linear_acc
double[3]
[x,y,z] Noise covariance of the linear acceleration measurement, in (m/s²)².
angular_vel
double[3]
[x,y,z] Noise covariance of the angular velocity measurement, in (rad/s)².
angular_acc
double[3]
[x,y,z] Noise covariance of the angular acceleration estimated from angular velocity measurement, in (rad/s²)².
Estimation covariance convergence threshold
estimation_covariance_convergence_threshold
object
It must have the following fields:
mass
double
Convergence covariance threshold for the mass estimation, in (kg)².
com
double
Convergence covariance threshold for the center of mass estimation, in (m)².
inertia
double
Convergence covariance threshold for the inertia estimation, in (kg·m²)².
wrench_bias
double
Convergence covariance threshold for the wrench bias estimation, in (N·m)².
Payload Compensator
The JSON configuration file required to construct a payload compensator object must have the following structure:
Payload Compensator Configuration JSON File Structure
Basic configuration
runtime_verbosity
bool
Enable/disable dynamic compensation.
If disabled, only static gravity compensation, if enabled intertial compensation also applied
Payload Properties
payload_properties
object
It must have the following fields:
mass
double
Payload mass, in kg.
com
double[3]
[x,y,z] Payload center of mass, in m.
inertia
double[6]
[Ixx, Ixy, Ixz, Iyy, Iyy, Iyz, Izz] Payload inertia tensor, in kg·m².
JSON File Templates
Templates for JSON configuration files are included in the examples provided with our SDKs.