2

I have an Adaruit Motor Shield v2, and a Tower Pro SG92R micro servo. I've got it setup so the shield works with my Arduino Uno, and I've successfully tested using other types of motors on the shield. I could not find any sample code for working with a servomotor though. The shield has two dedicated spots for a servo (labeled "Servo 1" and "Servo 2"). I'm planning to use wall wart transformer to power the motor separately from the Arduino. Any pointers/links to documentation/sample code would be appreciated.

asked Jul 3, 2014 at 3:29
2
  • 1
    Does the standard servo example work? Commented Jul 3, 2014 at 5:00
  • With the shield mounted on the Arduino, I don't have access to those pins. Also I if I understand correctly, that would not let the servo be powered by a separate power supply. Commented Jul 3, 2014 at 13:59

1 Answer 1

3

On the Motor shield the servo headers are directly connected to pins 9 and 10 (I think 9 is servo 2 and 10 is servo 1). So you can use the standard servo examples using pins 9 and 10.

If you need to power the servos with an external power supply you must cut a trace on the back of the board -- the silk screen tells you where to cut. Then you need to connect power to the "Opt Servo" input.

The power to the servos is not changed by the power jumper used for the DC/stepper motors.

answered Jul 3, 2014 at 15:50

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.