arm_joint_pose.py 文件源码

python
阅读 22 收藏 0 点赞 0 评论 0

项目:AS_6Dof_Arm 作者: yao62995 项目源码 文件源码
def __init__(self):
        self.joint_names = ['base_joint', 'shoulder_joint', 'elbow_joint', 'wrist_flex_joint', 'wrist_rot_joint',
                            'finger_joint1', 'finger_joint2']
        # subscriber for setting joints position
        self.states_sub = rospy.Subscriber("/as_arm/set_joints_states", JointState, self.callback,
                                           queue_size=2)
        # a list of publisher
        self.joint_pub = dict()
        self.joint_pose = dict()
        for idx, name in enumerate(self.joint_names):
            pub = rospy.Publisher("/as_arm/joint%d_position_controller/command" % (idx + 1), Float64, queue_size=3)
            self.joint_pub[name] = pub
            self.joint_pose[name] = Float64()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号