ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
You can use a Pose Array
def talker():
obj = get_poses()
pub = rospy.Publisher('topic', PoseArray, queue_size=len(obj))
rospy.init_node('pose_array')
rate = rospy.Rate(60) # 10hz
while not rospy.is_shutdown():
Poses = PoseArray()
Poses.header.frame_id = "/surface"
Poses.header.stamp = rospy.Time.now()
for i in range(len(obj)):
Poses.poses.append(obj[i])
pub.publish(Poses)
rate.sleep()