import pantilthat import time pantilthat.idle_timeout(0.5) pantilthat.tilt(-45) time.sleep(3)
def _init_pantilt(self): pantilthat.idle_timeout(0.5) pantilthat.servo_pulse_min(LaserPen.servo_p, LaserPen.pan_min) pantilthat.servo_pulse_max(LaserPen.servo_p, LaserPen.pan_max) pantilthat.servo_pulse_min(LaserPen.servo_t, LaserPen.tilt_min) pantilthat.servo_pulse_max(LaserPen.servo_t, LaserPen.tilt_max)