38 #ifndef vpRobotFrankaSim_h
39 #define vpRobotFrankaSim_h
45 #include <visp3/core/vpConfig.h>
46 #include <visp3/core/vpPoseVector.h>
47 #include <visp3/core/vpThetaUVector.h>
48 #include <visp3/robot/vpRobot.h>
50 #if defined( VISP_HAVE_OROCOS_KDL )
52 #ifdef VISP_HAVE_OROCOS_KDL
53 #include <kdl/chain.hpp>
54 #include <kdl/chainfksolver.hpp>
55 #include <kdl/chainfksolverpos_recursive.hpp>
56 #include <kdl/chainiksolverpos_nr.hpp>
57 #include <kdl/chainiksolverpos_nr_jl.hpp>
58 #include <kdl/chainiksolvervel_pinv.hpp>
59 #include <kdl/chainjnttojacsolver.hpp>
60 #include <kdl/frames_io.hpp>
61 #include <kdl/solveri.hpp>
73 vpRobot::vpRobotStateType getRobotState(
void );
75 void get_fJe( vpMatrix &fJe );
76 void get_fJe(
const vpColVector &q, vpMatrix &fJe );
77 void get_eJe( vpMatrix &eJe_ );
78 void get_eJe(
const vpColVector &q, vpMatrix &fJe );
79 vpHomogeneousMatrix get_eMc()
const;
80 vpHomogeneousMatrix get_fMe(
const vpColVector &q );
81 vpHomogeneousMatrix get_fMe();
82 vpHomogeneousMatrix get_flMe()
const;
83 vpHomogeneousMatrix get_flMcom()
const;
84 double get_tool_mass()
const;
86 void getGravity( vpColVector &gravity );
87 void getMass( vpMatrix &mass );
88 void getCoriolis( vpColVector &coriolis );
89 void getCoriolisMatrix( vpMatrix &coriolis );
90 void getFriction( vpColVector &
friction );
92 virtual void getForceTorque(
const vpRobot::vpControlFrameType frame, vpColVector &force );
93 virtual void getPosition(
const vpRobot::vpControlFrameType frame, vpColVector &position );
94 virtual void getPosition(
const vpRobot::vpControlFrameType frame, vpPoseVector &position );
95 virtual void getVelocity(
const vpRobot::vpControlFrameType frame, vpColVector &d_position );
97 virtual void set_eMc(
const vpHomogeneousMatrix &eMc );
98 virtual void setForceTorque(
const vpRobot::vpControlFrameType frame,
const vpColVector &force );
99 virtual void setPosition(
const vpRobot::vpControlFrameType frame,
const vpColVector &position );
100 virtual void setVelocity(
const vpRobot::vpControlFrameType frame,
const vpColVector &vel );
102 virtual void add_tool(
const vpHomogeneousMatrix &flMe,
const double mL,
const vpHomogeneousMatrix &flMcom,
103 const vpMatrix &I_L );
104 virtual void set_flMe(
const vpHomogeneousMatrix &flMe );
105 virtual void set_g0(
const vpColVector &g0 );
111 inline void setVerbose(
bool verbose ) { m_verbose = verbose; }
129 vpColVector solveIK(
const vpHomogeneousMatrix &edMw );
130 vpColVector getVelDes();
132 #ifdef VISP_HAVE_OROCOS_KDL