rofunc.devices.xsens.record#
1. Module Contents#
1.1. Classes#
1.2. Functions#
record xsens motion data :param root_dir: root directory :param exp_name: npy file location :param ip: ip address of server computer :param port: port number of optitrack server :param ref_frame: reference frame :return: |
1.3. Data#
1.4. API#
- rofunc.devices.xsens.record.event = None#
- class rofunc.devices.xsens.record.Header(header)[source]#
Initialization
- property is_valid#
- property is_object#
External tracked object’s datagram have less segments than body datagram.
- property item_num#
- property item_size#
Define how many bytes in a item
- class rofunc.devices.xsens.record.Datagram(header, payload)[source]#
Bases:
objectInitialization
- property is_object#
- decode_to_pose_array_msg(ref_frame, ref_frame_id=None, scaling_factor=1.0)[source]#
Decode the bytes in the streaming data to pose array message. Args:
ref_frame: str Reference frame name of the generated pose array message. ref_frame_id: None/int If not None, all poses will be shifted subject to
the frame with this ID. This frame should belong to the human.
- scaling_factor: float Scale the position of the pose if src_frame_id is not None.
Its value equals to the robot/human body dimension ratio
- Returns:
pose_array_msg:
- class rofunc.devices.xsens.record.XsensInterface(udp_ip, udp_port, ref_frame, scaling=1.0, buffer_size=4096, **kwargs)[source]#
Bases:
objectInitialization
- rofunc.devices.xsens.record.record(root_dir: str, exp_name: str, ip: str, port: int, ref_frame: str = None) None[source]#
record xsens motion data :param root_dir: root directory :param exp_name: npy file location :param ip: ip address of server computer :param port: port number of optitrack server :param ref_frame: reference frame :return: