Libbarrett  1.2.4
include/barrett/cdlbt/calgrav.h
Go to the documentation of this file.
00001 
00061 #ifndef BARRETT_CDLBT_CALGRAV_H_
00062 #define BARRETT_CDLBT_CALGRAV_H_
00063 #ifdef __cplusplus
00064 extern "C" {
00065 #endif
00066 
00067 #include <gsl/gsl_vector.h>
00068    
00069 #include <barrett/cdlbt/kinematics.h>
00070 
00071 
00072 /* gravity compensation
00073  * only needs a couple of additional
00074  * parameters in each link*/
00075 
00079 struct bt_calgrav
00080 {
00082    /*struct bt_kinematics * kin;*/
00083         size_t dof;
00084 
00087    gsl_vector * world_g;
00088    
00089    gsl_vector ** g;  
00090    gsl_vector ** mu; 
00091    gsl_vector ** t;  
00092    gsl_vector ** pt; 
00093 };
00094 
00095 
00107 int bt_calgrav_create(struct bt_calgrav ** gravptr,
00108                       config_setting_t * gravconfig, size_t dof);
00109 
00110 
00119 int bt_calgrav_destroy(struct bt_calgrav * grav);
00120 
00121 
00134 int bt_calgrav_eval(struct bt_calgrav * grav,
00135         struct bt_kinematics * kin, gsl_vector * jtorque);
00136 
00146 int bt_calgrav_update(struct bt_calgrav * grav, double val);
00147 #ifdef __cplusplus
00148 }
00149 #endif
00150 #endif /* BARRETT_CDLBT_CALGRAV_H_ */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Defines