This commit is contained in:
2024-12-25 22:52:10 +01:00
parent 65247a1249
commit acff12d123
12 changed files with 0 additions and 0 deletions

20
old_stuff/testwalk2.py Normal file
View File

@@ -0,0 +1,20 @@
# SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries
# SPDX-License-Identifier: MIT
"""Simple test for a standard servo on channel 0 and a continuous rotation servo on channel 1."""
import time
from adafruit_servokit import ServoKit
# Set channels to the number of servo channels on your kit.
# 8 for FeatherWing, 16 for Shield/HAT/Bonnet.
kit = ServoKit(channels=16)
kit.servo[12].set_pulse_width_range(1000, 2000)
#kit.servo[12].angle = 180
#time.sleep(1)
kit.continuous_servo[12].throttle = 1
time.sleep(3)
kit.continuous_servo[12].throttle = -1
time.sleep(3)
kit.servo[0].angle = 0
kit.continuous_servo[12].throttle = 0