Servo Script icon Servo Script — Bind scripts to servo moves (V1-V99); triggers on position/speed/accel changes and provides ports, positions and speeds arrays for custom control. Try it →

ARC Pro

Upgrade to ARC Pro

Stay at the forefront of robot programming innovation with ARC Pro, ensuring your robot is always equipped with the latest advancements.

#1  

Add the ultrasonic sensor control or use in a script..


repeatuntil(0)
$dist=GetPing(D0,D1) #choose other ports if you want
print($dist)
sleep(250)
endrepeatuntil