20 "JointPositionExampleController: Error getting position joint interface from hardware!");
24 if (!node_handle.
getParam(
"joint_names", joint_names)) {
25 ROS_ERROR(
"JointPositionExampleController: Could not parse joint names");
27 if (joint_names.size() != 7) {
28 ROS_ERROR_STREAM(
"JointPositionExampleController: Wrong number of joint names, got " 29 << joint_names.size() <<
" instead of 7 names!");
33 for (
size_t i = 0; i < 7; ++i) {
38 "JointPositionExampleController: Exception getting joint handles: " << e.
what());
43 std::array<double, 7> q_start{{0, -M_PI_4, 0, -3 * M_PI_4, 0,
M_PI_2, M_PI_4}};
44 for (
size_t i = 0; i < q_start.size(); i++) {
47 "JointPositionExampleController: Robot is not in the expected starting position for " 48 "running this example. Run `roslaunch franka_example_controllers move_to_start.launch " 49 "robot_ip:=<robot-ip> load_gripper:=<has-attached-gripper>` first.");
58 for (
size_t i = 0; i < 7; ++i) {
69 for (
size_t i = 0; i < 7; ++i) {
virtual const char * what() const
std::array< double, 7 > initial_pose_
std::vector< hardware_interface::JointHandle > position_joint_handles_
std::array< std::string, 7 > joint_names
void update(const ros::Time &, const ros::Duration &period) override
hardware_interface::PositionJointInterface * position_joint_interface_
bool init(hardware_interface::RobotHW *robot_hardware, ros::NodeHandle &node_handle) override
JointHandle getHandle(const std::string &name)
ros::Duration elapsed_time_
void starting(const ros::Time &) override
bool getParam(const std::string &key, std::string &s) const
PLUGINLIB_EXPORT_CLASS(moveit_fake_controller_manager::MoveItFakeControllerManager, moveit_controller_manager::MoveItControllerManager)
#define ROS_ERROR_STREAM(args)