jacdac.servo

Submodules

Package Contents

Classes

ServoClient

Servo is a small motor with arm that can be pointing at a specific direction.

class jacdac.servo.ServoClient(bus: jacdac.bus.Bus, role: str, *, missing_actual_angle_value: Optional[float] = None)

Bases: jacdac.bus.SensorClient

Servo is a small motor with arm that can be pointing at a specific direction.
  • Typically a servo angle is between 0° and 180° where 90° is the middle resting position.

  • The min_pulse/max_pulse may be read-only if the servo is permanently affixed to its Jacdac controller.

Implements a client for the Servo service.

property angle Optional[float]

Specifies the angle of the arm (request)., _: °

property enabled Optional[bool]

Turn the power to the servo on/off.,

property offset Optional[float]

Correction applied to the angle to account for the servo arm drift., _: °

property min_angle Optional[float]

Lowest angle that can be set, typiclly 0 °., _: °

property min_pulse Optional[int]

(Optional) The length of pulse corresponding to lowest angle., _: us

property max_angle Optional[float]

Highest angle that can be set, typically 180°., _: °

property max_pulse Optional[int]

(Optional) The length of pulse corresponding to highest angle., _: us

property stall_torque Optional[float]

(Optional) The servo motor will stop rotating when it is trying to move a stall_torque weight at a radial distance of 1.0 cm., _: kg/cm

property response_speed Optional[float]

(Optional) Time to move 60°., _: s/60°

property actual_angle Optional[float]

(Optional) The current physical position of the arm, if the device has a way to sense the position., _: °