wbc
JointIntegrator.hpp
Go to the documentation of this file.
1#ifndef JOINT_INTEGRATOR_HPP
2#define JOINT_INTEGRATOR_HPP
3
6
12
13namespace wbc {
14
19 bool initialized;
20 types::JointCommand prev_cmd;
21 types::JointState cur_joint_state;
22public:
23 JointIntegrator() : initialized(false){}
33 void integrate(const types::JointState& joint_state, types::JointCommand &cmd, double cycle_time, types::CommandMode mode, IntegrationMethod method = RECTANGULAR, bool use_cur_state = false);
39 void integrateRectangular(types::JointCommand &cmd, double cycle_time, types::CommandMode mode, bool use_cur_state = false);
45 void integrateTrapezoidal(types::JointCommand &cmd, double cycle_time, types::CommandMode mode, bool use_cur_state = false);
49 void reinit(){initialized = false;}
50};
51
52}
53
54#endif
IntegrationMethod
Definition JointIntegrator.hpp:7
@ TRAPEZOIDAL
Definition JointIntegrator.hpp:10
@ NONE
Definition JointIntegrator.hpp:8
@ RECTANGULAR
Definition JointIntegrator.hpp:9
void integrateTrapezoidal(types::JointCommand &cmd, double cycle_time, types::CommandMode mode, bool use_cur_state=false)
Trapezoidal method for numerical integration.
Definition JointIntegrator.cpp:72
void integrate(const types::JointState &joint_state, types::JointCommand &cmd, double cycle_time, types::CommandMode mode, IntegrationMethod method=RECTANGULAR, bool use_cur_state=false)
Performs numerical from acceleration/velocity to positions.
Definition JointIntegrator.cpp:8
JointIntegrator()
Definition JointIntegrator.hpp:23
void reinit()
Reinitialize state of the integrator.
Definition JointIntegrator.hpp:49
void integrateRectangular(types::JointCommand &cmd, double cycle_time, types::CommandMode mode, bool use_cur_state=false)
Performs numerical from acceleration/velocity to positions using rectangular method.
Definition JointIntegrator.cpp:47
Definition JointCommand.hpp:8
The JointState class describes either the state or the command for a set of joints,...
Definition JointState.hpp:13
CommandMode
Definition JointCommand.hpp:32
Definition ContactsAccelerationConstraint.cpp:3