Skip to content

Commit b96c9b6

Browse files
authored
Merge pull request #3 from adafruit/tannewt-patch-1
Update parameter docs
2 parents 5833bd0 + f12b805 commit b96c9b6

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

adafruit_motor/servo.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,9 @@
3737
class _BaseServo: # pylint: disable-msg=too-few-public-methods
3838
"""Shared base class that handles pulse output based on a value between 0 and 1.0
3939
40+
:param ~pulseio.PWMOut pwm_out: PWM output object.
4041
:param int min_pulse: The minimum pulse length of the servo in microseconds.
41-
:param int max_pulse: The maximum pulse length of the servo in microseconds.
42-
:param int range: The physical range of the servo corresponding to the signal's duty in
43-
degrees."""
42+
:param int max_pulse: The maximum pulse length of the servo in microseconds."""
4443
def __init__(self, pwm_out, *, min_pulse=1000, max_pulse=2000):
4544
self._min_duty = int((min_pulse * pwm_out.frequency) / 1000000 * 0xffff)
4645
max_duty = (max_pulse * pwm_out.frequency) / 1000000 * 0xffff
@@ -60,11 +59,11 @@ def _fraction(self, value):
6059
class Servo(_BaseServo):
6160
"""Control the position of a servo.
6261
62+
:param ~pulseio.PWMOut pwm_out: PWM output object.
6363
:param int actuation_range: The physical range of the servo corresponding to the signal's
6464
duty in degrees.
6565
:param int min_pulse: The minimum pulse length of the servo in microseconds.
66-
:param int max_pulse: The maximum pulse length of the servo in microseconds.
67-
:param int trim: Slight shift of values to calibrate stopped value in microseconds."""
66+
:param int max_pulse: The maximum pulse length of the servo in microseconds."""
6867
def __init__(self, pwm_out, *, actuation_range=180, min_pulse=1000, max_pulse=2000):
6968
super().__init__(pwm_out, min_pulse=min_pulse, max_pulse=max_pulse)
7069
self._actuation_range = actuation_range
@@ -85,8 +84,7 @@ class ContinuousServo(_BaseServo):
8584
"""Control a continuous rotation servo.
8685
8786
:param int min_pulse: The minimum pulse length of the servo in microseconds.
88-
:param int max_pulse: The maximum pulse length of the servo in microseconds.
89-
:param int trim: Slight shift of values to calibrate stopped value in microseconds."""
87+
:param int max_pulse: The maximum pulse length of the servo in microseconds."""
9088
@property
9189
def throttle(self):
9290
"""How much power is being delivered to the motor. Values range from ``-1.0`` (full

0 commit comments

Comments
 (0)