@@ -438,8 +438,8 @@ class LinkerHand : public rclcpp::Node
438438 {
439439 auto message = sensor_msgs::msg::JointState ();
440440
441- (is_arc) ? message.position = hand->getStateArc () : message.position = convert<uint8_t ,
442- double >(hand->getState ());
441+ (is_arc) ? message.position = hand->getPositionArc () : message.position = convert<uint8_t ,
442+ double >(hand->getPosition ());
443443 message.velocity = convert<uint8_t , double >(hand->getSpeed ());
444444 message.effort = convert<uint8_t , double >(hand->getTorque ());
445445
@@ -540,7 +540,7 @@ class LinkerHand : public rclcpp::Node
540540 hand->setTorque (effort);
541541 }
542542 if (send_position) {
543- (is_arc) ? hand->fingerMoveArc (msg->position ) : hand->fingerMove (position);
543+ (is_arc) ? hand->setPositionArc (msg->position ) : hand->setPosition (position);
544544 }
545545 }
546546
@@ -553,7 +553,7 @@ class LinkerHand : public rclcpp::Node
553553 if (hand_name == " L21" ) {return 21 ;}
554554 if (hand_name == " L25" ) {return 25 ;}
555555 if (hand_name == " G20" ) {return 16 ;}
556- if (hand_name == " O20" ) {return 34 ;}
556+ if (hand_name == " O20" ) {return 16 ;}
557557 return 0 ;
558558 }
559559
@@ -577,7 +577,7 @@ class LinkerHand : public rclcpp::Node
577577 const auto joint_count = getJointCount (hand_name);
578578 hand->setSpeed (std::vector<uint8_t >(joint_count, hand_speed)); // speed
579579 hand->setTorque (std::vector<uint8_t >(joint_count, hand_effort)); // torque
580- hand->fingerMove ({255 , 128 , 255 , 255 , 255 , 255 , 128 , 128 , 128 , 128 }); // joint position
580+ hand->setPosition ({255 , 128 , 255 , 255 , 255 , 255 , 128 , 128 , 128 , 128 }); // joint position
581581 }
582582 }
583583
0 commit comments