Control a servo to sweep from one extreme position to the other, creating a smooth and rhythmic motion.
Continuously transition the Servo A
position from one end to the other.
basic.forever(function () { sb.transitionServoPosition(sb.servo(SBServo.ServoA), 0, 3, sb.easing(SBEasing.Linear)) sb.transitionServoPosition(sb.servo(SBServo.ServoA), 100, 3, sb.easing(SBEasing.Linear)) })
If using micro:bit for the first time, follow this setup.