Welcome to Synthiam!

Program robots using technologies created by industry experts. ARC is our free-to-use robot programming software that makes features like vision recognition, navigation, and artificial intelligence easy.

Get Started
Asked — Edited

Ssc-32 Servo Control Via Script

Someone on the forum contacted me via email and wanted a sample script of how to control the Lynxmotion ssc-32 servo board via a script.... I am posting it here in case anyone else might be interested...

FYI ... EZ Builder now has an SSC-32 control which is also supported in the auto-positioner....

Code:


#This is an example of controlling servos on the ssc-32 servo board via scripts
#However you can now use the auto positioner if you wish to make it easier
#It assumes you have set the SSC-32 for 38,400 baud
#It is connected to URAT port 0 with ground and TX on the EZB
#On the SSC-32 you connect to ground and Rx

UARTInit(0,0,38400) #initialize the ssc-32 on UART port 0, call only once
sleep(1000)

#This will move 5 servos to centre position (90)

$pw = "1500" #1500 = 90, 500~ min and 2500~ max for 1 to 180...
$m = "1000" #is speed control


UARTWrite(0,0,"#1P"+$pw+"S"+$m,13) #right index on port 1
UARTWrite(0,0,"#2P"+$pw+"S"+$m,13) #right middle on port 2
UARTWrite(0,0,"#3P"+$pw+"S"+$m,13) #right ring on port 3
UARTWrite(0,0,"#4P"+$pw+"S"+$m,13) #right baby on port 4

sleep(500)
UARTWrite(0,0,"#0P"+$pw+"S"+$m,13) #right thumb on port 0


ARC Pro

Upgrade to ARC Pro

Experience early access to the latest features and updates. You'll have everything that is needed to unleash your robot's potential.

AI Support Bot
Related Content
Synthiam
PRO
Synthiam
#1  
And it's also supported using Servo() command. Just use the Vx servo ports.:)