
131Chapter 7: 3D Robotic Arms
to 90 degrees. (From here on out, we will refer to
our motor mounted on the left side of the base as
motor 2 and the motor mounted on the right side
of the base as motor 3.)
#include "Servo.h"
Servo servoOne;
Servo servoTwo;
Servo servoThree;
void setup() {
servoOne.attach(3);
servoTwo.attach(5);
servoThree.attach(6);
}
void loop() {
servoOne.write(90);
servoTwo.write(90);
servoThree.write(90);
}
STEP 7: ATTACHING THE LINK 2 COMPONENTS
Once motors 2 and 3 have been successfully set
to 90 degrees, it’s time to begin assembling the
components that will make up the second link of
our system. The first piece you will need, pictur ...