from servo import*
from time import sleep
from machine import Pin,ADC
pot = ADC(Pin(27))     # create ADC object on ADC pin

while 1:
    angle=pot.read_u16()*180/65535 # read pot value
    angle2=180-angle
    servo1_angle(angle)
    servo2_angle(angle2)
    sleep(0.1)
BOOTSELLED1239USBRaspberryPiPico©2020RP2-8020/21P64M15.00TTT