TaskspaceAdmittanceController Class Reference

#include <armarx/control/common/control_law/TaskspaceAdmittanceController.h>

Classes

struct  Config
 you can set the following values from outside of the rt controller via Ice interfaces More...
 
struct  NonRtStatus
 
struct  RtStatus
 internal status of the controller, containing intermediate variables, mutable targets More...
 

Public Member Functions

void firstRun ()
 
void initialize (const VirtualRobot::RobotNodeSetPtr &rns)
 
void preactivateInit (const VirtualRobot::RobotNodeSetPtr &rns)
 
void run (const Config &cfg, ControlTarget &targets, double deltaT)
 
bool updateControlStatus (const Config &cfg, const RobotStatus &robotStatus)
 
void updateFT (const common::ft::FTSensor::FTConfig &c, double deltaT)
 

Public Attributes

TripleBuffer< NonRtStatusbufferNonRtToOnPublish
 
TripleBuffer< NonRtStatusbufferNonRtToRt
 
TripleBuffer< RtStatusbufferRtToOnPublish
 
common::ft::FTSensor ftsensor
 
std::atomic< bool > isInitialized {false}
 
VirtualRobot::RobotNodePtr tcp
 

Detailed Description

Definition at line 39 of file TaskspaceAdmittanceController.h.

Member Function Documentation

◆ firstRun()

void firstRun ( )

Definition at line 164 of file TaskspaceAdmittanceController.cpp.

+ Here is the call graph for this function:

◆ initialize()

void initialize ( const VirtualRobot::RobotNodeSetPtr &  rns)

Definition at line 21 of file TaskspaceAdmittanceController.cpp.

+ Here is the call graph for this function:

◆ preactivateInit()

void preactivateInit ( const VirtualRobot::RobotNodeSetPtr &  rns)

Definition at line 123 of file TaskspaceAdmittanceController.cpp.

+ Here is the call graph for this function:

◆ run()

void run ( const Config cfg,
ControlTarget targets,
double  deltaT 
)

run in rt thread

only when the ft sensor is calibrated can we allow the admittance controller to have virtual pose modulation out of force/torque information.

-------------------------— admittance control ------------------------------------------— calculate pose error between the virtual pose and the target pose

admittance control law and Euler Integration -> virtual pose

--------------------------— Impedance control ------------------------------------------— calculate pose error between target pose and current pose !!! This is very important: you have to keep postion and orientation both with UI unit (meter, radian) to calculate impedance force.

--------------------------— Nullspace PD Control -----------------------------------------------—

--------------------------— Map TS target force to JS -----------------------------------------------—

--------------------------— write torque target -----------------------------------------------—

Definition at line 260 of file TaskspaceAdmittanceController.cpp.

+ Here is the call graph for this function:

◆ updateControlStatus()

bool updateControlStatus ( const Config cfg,
const RobotStatus robotStatus 
)

check size and value

--------------------------— get current status of robot ------------------------------------------— original data in ArmarX use the following units: position in mm, joint angles and orientation in radian, velocity in mm/s and radian/s, etc. here we convert mm to m, if you use MP from outside, make sure to convert it back to mm

Definition at line 184 of file TaskspaceAdmittanceController.cpp.

+ Here is the call graph for this function:

◆ updateFT()

void updateFT ( const common::ft::FTSensor::FTConfig c,
double  deltaT 
)

run in rt thread

TODO how to toggle recalibration?

Definition at line 235 of file TaskspaceAdmittanceController.cpp.

+ Here is the call graph for this function:

Member Data Documentation

◆ bufferNonRtToOnPublish

TripleBuffer<NonRtStatus> bufferNonRtToOnPublish

Definition at line 121 of file TaskspaceAdmittanceController.h.

◆ bufferNonRtToRt

TripleBuffer<NonRtStatus> bufferNonRtToRt

Definition at line 120 of file TaskspaceAdmittanceController.h.

◆ bufferRtToOnPublish

TripleBuffer<RtStatus> bufferRtToOnPublish

Definition at line 118 of file TaskspaceAdmittanceController.h.

◆ ftsensor

Definition at line 124 of file TaskspaceAdmittanceController.h.

◆ isInitialized

std::atomic<bool> isInitialized {false}

Definition at line 136 of file TaskspaceAdmittanceController.h.

◆ tcp

VirtualRobot::RobotNodePtr tcp

Definition at line 123 of file TaskspaceAdmittanceController.h.


The documentation for this class was generated from the following files: