Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/openarm_control/qp/arm_joint_limit.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ def __init__(
or int(model.jnt_qposadr[joint_id]) not in selected_qpos
):
continue
if model.jnt_type[joint_id] not in (
mujoco.mjtJoint.mjJNT_HINGE,
mujoco.mjtJoint.mjJNT_SLIDE,
if int(model.jnt_type[joint_id]) not in (
int(mujoco.mjtJoint.mjJNT_HINGE),
int(mujoco.mjtJoint.mjJNT_SLIDE),
):
raise ValueError("ArmConfigurationLimit only supports scalar joints.")
active_dofs.append(int(model.jnt_dofadr[joint_id]))
Expand Down Expand Up @@ -106,9 +106,9 @@ def __init__(
"its velocity limit will be skipped."
)
continue
if model.jnt_type[joint_id] not in (
mujoco.mjtJoint.mjJNT_HINGE,
mujoco.mjtJoint.mjJNT_SLIDE,
if int(model.jnt_type[joint_id]) not in (
int(mujoco.mjtJoint.mjJNT_HINGE),
int(mujoco.mjtJoint.mjJNT_SLIDE),
):
raise ValueError("ArmJointLimit only supports scalar joints.")

Expand Down