User manual

www.sainsmart.com
Copyright © 2013 SainSmart All Rights Reserved
to its corresponding angle. Some servos will turn more or less than 180 degrees, so you may
need to experiment.
Programming:
The Arduino software comes with a sample servo sketch and servo library that will get you up
and running quickly. Simply load it from the menu as shown below. Their example uses pin 9 for
the pulse wire, so to keep it simple, that’s what I used. You could use any of the data pins and, if
you add more than one servo, you will need to. The Sweep sample simply rotates the servo back
and forth from 0 degrees to 180. There is another sample sketch that uses a potentiometer as an
input to control the angle of the motor, but I’ll get in to that later.
The code is pretty basic and well documented. It first loads the library needed and sets up which