Data Query
get_base_data()
Python
get_base_data(key: str) -> list[float]
Reads base (torso) kinematic data, updated at ~100 Hz.
key value | Dimensions | Description |
|---|---|---|
'quat_xyzw' | 4 | Orientation quaternion (x, y, z, w), base → world |
'quat_wxyz' | 4 | Orientation quaternion (w, x, y, z), base → world |
'rpy' | 3 | Roll / pitch / yaw angles (rad) |
'omega_W' | 3 | Angular velocity, world frame (rad/s) |
'omega_B' | 3 | Angular velocity, body frame (rad/s) |
'acc_W' | 3 | Linear acceleration, world frame (m/s²) |
'acc_B' | 3 | Linear acceleration, body frame (m/s²) |
'vel_W' | 3 | Linear velocity, world frame (m/s) |
'vel_B' | 3 | Linear velocity, body frame (m/s) |
'pos_W' | 3 | Position, world frame (m) |
Example
Python
rpy = client.get_base_data("rpy")
print(f"roll={rpy[0]:.3f}, pitch={rpy[1]:.3f}, yaw={rpy[2]:.3f}")
get_true_data()
Python
get_true_data(key: str) -> list[float]
Reads simulation or estimated ground-truth data.
key value | Description |
|---|---|
'vel_B' | Linear velocity, body frame (m/s) |
'vel_W' | Linear velocity, world frame (m/s) |
'pos_W' | Position, world frame (m) |
'contact_fz' | Normal contact force per foot (N) |
'contact_prob' | Contact probability per foot [0, 1] |
get_contact_data()
Python
get_contact_data(key: str) -> list[float]
Reads foot contact sensor data.
key value | Description |
|---|---|
'contact_force' | Contact force per foot (N) |
'contact_prob' | Contact probability per foot [0, 1] |
Example
Python
force = client.get_contact_data("contact_force")
prob = client.get_contact_data("contact_prob")
print(f"contact force: {force}, prob: {prob}")
get_cartesian_state()
Python
get_cartesian_state(group_name: str, key: str = 'pose') -> list[float]
Reads the Cartesian state of a specified end-effector.
| Parameter | Type | Description |
|---|---|---|
group_name | str | Joint group name (e.g. "left_manipulator") |
key | str | State type — see table below |
key value | Description |
|---|---|
'pose' | End-effector pose (position + quaternion), default |
'twist' | End-effector velocity (linear + angular) |
'wrench' | End-effector force / torque |
Example
Python
pose = client.get_cartesian_state("left_manipulator", key="pose")
print(f"left end-effector pose: {pose}")