dg_blmc_robots
All Classes Files Functions Variables Pages
dgm_teststand.hpp
1 
11 #ifndef DGM_TESTSTAND_HH
12 #define DGM_TESTSTAND_HH
13 
14 #include <dynamic_graph_manager/dynamic_graph_manager.hh>
15 #include <blmc_robots/teststand.hpp>
16 #include "dg_blmc_robots/JointCalibration.h"
17 #include "yaml_cpp_catkin/yaml_cpp_fwd.hpp"
18 
19 namespace dg_blmc_robots
20 {
21 
22  class DGMTeststand : public dynamic_graph::DynamicGraphManager
23  {
24  public:
28  DGMTeststand();
29 
33  ~DGMTeststand();
34 
40 
46  void get_sensors_to_map(dynamic_graph::VectorDGMap& map);
47 
53  void set_motor_controls_from_map(const dynamic_graph::VectorDGMap& map);
54 
58  virtual bool is_in_safety_mode();
59 
69  dg_blmc_robots::JointCalibration::Request& req,
70  dg_blmc_robots::JointCalibration::Response& res);
71 
72  private:
79  void calibrate_joint_position(const Eigen::Vector2d& zero_to_index_angle);
80 
88  blmc_robots::Teststand teststand_;
89 
93  Eigen::Vector2d ctrl_joint_torques_;
94 
101 
106  };
107 
108 
109 } // namespace dg_blmc_robots
110 
111 #endif // DGM_TEST_BENCH_8_MOTORS_HH
bool was_in_safety_mode_
was_in_safety_mode_ Toggle to keep in safety mode once it was entered.
Definition: dgm_teststand.hpp:105
Definition: dgm_teststand.hpp:22
void set_motor_controls_from_map(const dynamic_graph::VectorDGMap &map)
set_motor_controls_from_map reads the input map that contains the controls and send these controls to...
Definition: dgm_teststand.cpp:104
bool calibrate_joint_position_callback(dg_blmc_robots::JointCalibration::Request &req, dg_blmc_robots::JointCalibration::Response &res)
ROS callback.
Definition: dgm_teststand.cpp:115
Definition: dgm_single_motor.hpp:17
Eigen::Vector2d ctrl_joint_torques_
ctrl_joint_torques_ the joint torques to be sent
Definition: dgm_teststand.hpp:93
void get_sensors_to_map(dynamic_graph::VectorDGMap &map)
get_sensors_to_map acquires the sensors data and feeds it to the input/output map ...
Definition: dgm_teststand.cpp:57
void initialize_hardware_communication_process()
initialize_hardware_communication_process is the function that initialize the hardware.
Definition: dgm_teststand.cpp:22
blmc_robots::Teststand teststand_
Entries for the real hardware.
Definition: dgm_teststand.hpp:88
void calibrate_joint_position(const Eigen::Vector2d &zero_to_index_angle)
Calibrate the robot joint position.
Definition: dgm_teststand.cpp:130
Eigen::Vector2d zero_to_index_angle_from_file_
These are the calibration value extracted from the paramters.
Definition: dgm_teststand.hpp:100
virtual bool is_in_safety_mode()
is_in_safety_mode Implement custom safe-mode detection.
Definition: dgm_teststand.cpp:46
DGMTeststand()
DGMTeststand is the constructor.
Definition: dgm_teststand.cpp:14
~DGMTeststand()
~DGMTeststand is the destructor.
Definition: dgm_teststand.cpp:18