

def attach(self, pwm_pin):
    ' Attach servo to PWM pin; alternative to passing PWM pin to\n        __init__(). Can also be used to change pins. '
    if self.pwm_pin:
        self.detach()
    self.pwm_pin = pwm_pin
    pwmFrequency(self.pwm_pin, self.pwm_freq)
    self.period_ms = (1000.0 / self.pwm_freq)

dataset/ETHPy150Open graycatlabs/PyBBIO/bbio/libraries/Servo/Servo.py Servo.attach/original