6 #ifndef PROJECT_ROBOTINTERFACE_H 7 #define PROJECT_ROBOTINTERFACE_H 12 #include <cheetah_visualization_lcmt.hpp> 13 #include <condition_variable> 14 #include <lcm-cpp.hpp> 18 #include "control_parameter_request_lcmt.hpp" 19 #include "control_parameter_respones_lcmt.hpp" 20 #include "gamepad_lcmt.hpp" 22 #define ROBOT_INTERFACE_UPDATE_PERIOD (1.f / 60.f) 23 #define INTERFACE_LCM_NAME "interface" 24 #define TIMES_TO_RESEND_CONTROL_PARAM 5 28 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
40 const std::string& chan,
41 const control_parameter_respones_lcmt* msg);
44 const std::string& chan,
45 const cheetah_visualization_lcmt* msg);
82 #endif // PROJECT_ROBOTINTERFACE_H
FloatingBaseModel< double > _model
void sendControlParameter(const std::string &name, ControlParameterValue value, ControlParameterValueKind kind, bool isUser)
ControlParameterValueKind
EIGEN_MAKE_ALIGNED_OPERATOR_NEW RobotInterface(RobotType robotType, Graphics3D *gfx, PeriodicTaskManager *tm, ControlParameters &userParameters)
Data structure containing parameters for quadruped robot.
Implementation of a periodic function running in a separate thread. Periodic tasks have a task manage...
FBModelState< double > _fwdKinState
void handleControlParameter(const lcm::ReceiveBuffer *rbuf, const std::string &chan, const control_parameter_respones_lcmt *msg)
PeriodicTaskManager _taskManager
virtual ~RobotInterface()
RobotControlParameters & getParams()
Quadruped< double > _quadruped
void handleVisualizationData(const lcm::ReceiveBuffer *rbuf, const std::string &chan, const cheetah_visualization_lcmt *msg)
VisualizationData _visualizationData
control_parameter_request_lcmt _parameter_request_lcmt
DynamicsSimulator< double > * _simulator
bool _pendingControlParameterSend
bool _waitingForLcmResponse
std::condition_variable _lcmCV
gamepad_lcmt _gamepad_lcmt
RobotControlParameters _controlParameters
ControlParameters & _userParameters
Visualizer window for simulator.