def to_parameters(self):
"""
Fetches a calibration from ROS parameters in the namespace of the current node into this object.
:rtype: None
"""
calib_dict = self.to_dict()
root_params = ['eye_on_hand', 'tracking_base_frame']
if calib_dict['eye_on_hand']:
root_params.append('robot_effector_frame')
else:
root_params.append('robot_base_frame')
for rp in root_params:
rospy.set_param(rp, calib_dict[rp])
transf_params = 'x', 'y', 'z', 'qx', 'qy', 'qz', 'qw'
for tp in transf_params:
rospy.set_param('transformation/'+tp, calib_dict['transformation'][tp])
评论列表
文章目录