import time

from a4988 import A4988  # Importing the A4988 class from a4988.py

stepper = A4988()
print("Starting stepper motor test.")
speed = 200
while True:
    print(f"Speed: {speed} steps/sec.")
    stepper.move_sync(800, speed)
    time.sleep(1.0)

    stepper.move_sync(-800, speed)
    time.sleep(1.0)

    speed *= 1.2
    if speed > 2000:
        speed = 100
BOOTSELLED1239USBRaspberryPiPico©2020RP2-8020/21P64M15.00TTT
A4988