Streaming Information from the Robot¶
YuMSubscriber¶
-
class
yumipy.
YuMiSubscriber
(include_left=True, include_right=True, left_includes=('torques', 'states', 'poses'), right_includes=('torques', 'states', 'poses'))¶ Interface to stream pose and state information from an ABB YuMI robot over ethernet.
-
__init__
(include_left=True, include_right=True, left_includes=('torques', 'states', 'poses'), right_includes=('torques', 'states', 'poses'))¶ Initializes a YuMiSubscriber
Parameters: - include_left (bool, optional) – If True, the left arm subscriber is included and instantiated. Defaults to True
- include_right (bool, optional) – If True, the right arm subscriber is included and instantiated. Defaults to True
Raises: YuMiCommException
– If communication times out or socket error.
-
stop
()¶ Calls the stop function for each instantiated arm subscriber object.
-
start
()¶ Calls the start function for each instantiated arm subscriber object.
-
YuMiSubcriber Example¶
sub = YuMiSubcriber()
sub.start()
left_pose = sub.left.get_pose()
right_pose = sub.right.get_pose()
left_state = sub.left.get_state()
right_state = sub.right.get_state()
left_torque = sub.left.get_torque()
right_torque = sub.right.get_torque()
sub.stop()