feathersdk.robot.actuator_systems.arms_system Module

class feathersdk.robot.actuator_systems.arms_system.ArmsSystemConfig(*, module_name='arms_system', safe_stop_policy=SafeStopPolicy.COMPLIANCE_MODE, operating_frequency=30, actuators_share_same_endpoint=True)

Bases: ActuatorSystemConfig

Configuration for the arms system.

Parameters:
module_name: str

The name of the module.

model_config: ClassVar[ConfigDict] = {'frozen': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class feathersdk.robot.actuator_systems.arms_system.ArmsSystem(config, *args, **kwargs)

Bases: ActuatorSystem[TArmsSystemConfig], Generic[TArmsSystemConfig]

A system that controls both arms.

Parameters:

config (TArmsSystemConfig)

class feathersdk.robot.actuator_systems.arms_system.OpCmd(torque, angle, velocity, kp, kd)

Bases: tuple

A single operation command for a motor.

Parameters:
  • torque (float) – The target torque in Newtons-meters.

  • angle (float) – The target angle in radians.

  • velocity (float) – The target velocity in radians per second.

  • kp (float) – The proportional gain, applied to the position error.

  • kd (float) – The derivative gain, applied to the velocity error.

angle: float

Alias for field number 1

kd: float

Alias for field number 4

kp: float

Alias for field number 3

torque: float

Alias for field number 0

velocity: float

Alias for field number 2

class feathersdk.robot.actuator_systems.arms_system.Robstride7MArmConfig(*, module_name='arm', safe_stop_policy=SafeStopPolicy.COMPLIANCE_MODE, operating_frequency=30, actuators_share_same_endpoint=True, side='left', shoulder_pitch_motor, shoulder_roll_motor, shoulder_yaw_motor, elbow_motor, wrist_yaw_motor, wrist_pitch_motor, wrist_roll_motor, require_approval_for_calibration=True, on_abort_action='disable', velocity_update_threshold=0.001, position_update_threshold=0.001, kp_update_threshold=0.001)

Bases: ActuatorSystemConfig

Configuration for a single Robstride arm.

Parameters:
module_name: str

The name of the module.

side: Literal['left', 'right']

The side of the robot that the arm is on.

shoulder_pitch_motor: RobstrideMotorConfig

Configuration for the shoulder pitch motor.

shoulder_roll_motor: RobstrideMotorConfig

Configuration for the shoulder roll motor.

shoulder_yaw_motor: RobstrideMotorConfig

Configuration for the shoulder yaw motor.

elbow_motor: RobstrideMotorConfig

Configuration for the elbow motor.

wrist_yaw_motor: RobstrideMotorConfig

Configuration for the wrist yaw motor.

wrist_pitch_motor: RobstrideMotorConfig

Configuration for the wrist pitch motor.

wrist_roll_motor: RobstrideMotorConfig

Configuration for the wrist roll motor.

require_approval_for_calibration: bool

Whether to require approval for calibration by prompting the user for permission. Should always be True for production systems for safety!

on_abort_action: Literal['disable', 'freeze']

What to do when the arm is aborted. “disable” to home/disable motors, “freeze” to freeze the arm in place.

velocity_update_threshold: float

The threshold for updating the velocity of a motor. If new velocity is within this threshold of the last sent velocity, will not send an update.

position_update_threshold: float

The threshold for updating the position of a motor. If new position is within this threshold of the last sent position, will not send an update.

kp_update_threshold: float

The threshold for updating the kp of a motor. If new kp is within this threshold of the last sent kp, will not send an update.

model_config: ClassVar[ConfigDict] = {'frozen': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class feathersdk.robot.actuator_systems.arms_system.Robstride7MArm(config, *args, **kwargs)

Bases: ActuatorSystem[Robstride7MArmConfig]

A single Robstride arm with 7 motor design.

Parameters:

config (Robstride7MArmConfig)

shoulder_pitch_motor: RobstrideMotor

The shoulder pitch motor.

shoulder_roll_motor: RobstrideMotor

The shoulder roll motor.

shoulder_yaw_motor: RobstrideMotor

The shoulder yaw motor.

elbow_motor: RobstrideMotor

The elbow motor.

wrist_yaw_motor: RobstrideMotor

The wrist yaw motor.

wrist_pitch_motor: RobstrideMotor

The wrist pitch motor.

wrist_roll_motor: RobstrideMotor

The wrist roll motor.

set_mode(mode)

Set the mode of the arm.

Parameters:

mode (Literal['position', 'operation']) – The mode to set the arm to.

Return type:

None

capture_position(fresh_values=True, trigger_feedback=True)

Capture the position of the arm.

Parameters:
  • fresh_values (bool) – Whether to get fresh values from the motors. If False, will use the last cached values.

  • trigger_feedback (bool) – If True, will trigger a feedback frame for the motors to request the latest values. However, we may not get the latest values on this call as they may not have arrived yet. This will instead ensure that future calls within a short time frame will get the latest values.

Returns:

Dict mapping motor name to current position.

Return type:

dict[str, float]

set_op_targets(torques=None, positions=None, velocities=None, kps=None, kds=None)

Set the operation-mode targets of the arm.

Will only update the targets that are provided for the motors that are provided.

Parameters:
  • torques (dict[str, float]) – Dict mapping motor name to torque.

  • positions (dict[str, float]) – Dict mapping motor name to position.

  • velocities (dict[str, float]) – Dict mapping motor name to velocity.

  • kps (dict[str, float] | None) – Dict mapping motor name to kp.

  • kds (dict[str, float] | None) – Dict mapping motor name to kd.

Return type:

None

set_position(positions, velocities=None, kps=None)

Set the position of the arm.

Parameters:
  • position – Dict mapping motor name to position. If values for any motors are missing or None, will not update the position for that motor.

  • velocities (dict[str, float] | None) – Dict mapping motor name to velocity. If None, will not update velocities. If values for any motors are missing or None, will not update the velocity for that motor.

  • kps (dict[str, float] | None) – Dict mapping motor name to kp. If None, will not update kps. If values for any motors are missing or None, will not update the kp for that motor.

  • positions (dict[str, float])

Return type:

None

go_to(positions, total_time, kps=None)

Go to the given positions in the given time.

Parameters:
  • positions (dict[str, float]) – Dict mapping motor name to position. Will only move the motors that are present.

  • total_time (float) – The total time to reach the positions.

  • kps (dict[str, float] | None) – Dict mapping motor name to kp.

Return type:

None

enable()

Enable the arm.

Return type:

None

disable()

Disable the arm. Moves to home position first.

Return type:

None

home(block=True)

Home the arm.

Parameters:

block (bool) – Whether to block the current thread until the home is complete.

Return type:

None

freeze()

Freeze the arm.

Return type:

None

recalibrate(allow_load=None)

Recalibrate the arm.

Parameters:

allow_load (bool | None)

Return type:

None

class feathersdk.robot.actuator_systems.arms_system.Robstride7MArmSystemConfig(*, module_name='arms_system', safe_stop_policy=SafeStopPolicy.COMPLIANCE_MODE, operating_frequency=30, actuators_share_same_endpoint=True, right_arm, left_arm)

Bases: ArmsSystemConfig

Configuration for a full Robstride arm system.

Parameters:
model_config: ClassVar[ConfigDict] = {'frozen': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

right_arm: Robstride7MArmConfig | None

Configuration for the right arm. Leave None to not include a right arm.

left_arm: Robstride7MArmConfig | None

Configuration for the left arm. Leave None to not include a left arm.

class feathersdk.robot.actuator_systems.arms_system.Robstride7MArmSystem(config, *args, **kwargs)

Bases: ArmsSystem[Robstride7MArmSystemConfig]

A system that controls 1-2 Robstride arms.

Parameters:

config (Robstride7MArmSystemConfig)

right_arm: Robstride7MArm | None

The right arm. None if not using a right arm.

left_arm: Robstride7MArm | None

The left arm. None if not using a left arm.

recalibrate(allow_load=None)

Recalibrate the arms system.

Parameters:

allow_load (bool | None)

Return type:

None

capture_position()

Capture the position of the arms.

Returns:

Dict mapping arm name to dict mapping motor name to current position.

Return type:

dict[str, dict[str, float]]

set_position(left_arm, right_arm, kps=None)

Set the position of the arms.

Parameters:
  • left_arm (dict[str, float]) – Dict mapping motor name to position.

  • right_arm (dict[str, float]) – Dict mapping motor name to position.

  • kps (dict[str, float] | None) – Dict mapping motor name to kp. Includes all motors, left arm and right, if using

Return type:

None

enable()

Enable the arms system.

Return type:

None

disable()

Disable the arms system. Moves to home position first.

Return type:

None

home()

Home the arms system.

Return type:

None

freeze()

Freeze the arms system.

Return type:

None