Introduction:
Step 1:
Step 2: Circuit Diagram
here is this connection...
at 1st you have to do..
4 servo motors red wire connect to breadboard with (+)9v battery
then black wire is connect to gnd (-)9v battery
and...yellow wire is connect to arduino to digital pin...
servo motors are connected to 3,5,6,and 9pin of arduino..
then....
bluetooth connection:-
we have used bluetooth as hc-05..
gnd is connect to gnd pin of arduino
and vcc is connect to +5v to arduino
tx of arduino is connect to rx of bluetooth
rx of arduino is connect to tx of bluetooth..
but you have to remember that,when you uploading code to arduino board...this time plz remove tx and rx pin connection..
Step 3: Uploading Code
at 1st copy the code..then paste to in you arduino...then compile and upload...
while uploading must remove tx and rx pin bluetooth and arduino connection
#include <servo.h>
Servo myservo1,
myservo2, myservo3, myservo4, myservo5, myservo6, myservo7, myservo8, myservo9, myservo10; byte serialA;
void setup() { myservo1.attach(3); myservo2.attach(5); myservo3.attach(6); myservo4.attach(9); // myservo7.attach(); fill in pin numbers if you use more then 6 servos i left them blank // myservo8.attach(); // myservo9.attach(); // myservo10.attach(); Serial.begin(9600);//change your baudrate to your Bluetooth modules baudrate if needed. }
void loop() { if (Serial.available() > 2) {serialA = Serial.read();Serial.println(serialA);} { unsigned int servopos = Serial.read(); unsigned int servopos1 = Serial.read(); unsigned int realservo = (servopos1 *256) + servopos; Serial.println(realservo); if (realservo >= 1000 && realservo <1180){ int servo1 = realservo; servo1 = map(servo1, 1000,1180,0,180); myservo1.write(servo1); Serial.println("servo 1 ON"); delay(10);
} if (realservo >=2000 && realservo <2180){ int servo2 = realservo; servo2 = map(servo2,2000,2180,0,180); myservo2.write(servo2); Serial.println("servo 2 On"); delay(10); } if (realservo >=3000 && realservo < 3180){ int servo3 = realservo; servo3 = map(servo3, 3000, 3180,0,180); myservo3.write(servo3); Serial.println("servo 3 On"); delay(10); } if (realservo >=4000 && realservo < 4180){ int servo4 = realservo; servo4 = map(servo4, 4000, 4180,0,180); myservo4.write(servo4); Serial.println("servo 4 On"); delay(10); } } }
Step 4: Bluetooth App Connect
you have to 1st download apk file from here..
https://drive.google.com/file/d/0B8dtZrw1R30WZUdNb...
then install it..
after instllation multiple servo control app ...connect to hc-05 bluetooth..
hurray..you got it..
now play to your smartphone..and control robotic arm..
Step 5: Result
so guys for full information and how to build this project ..
plz visit to this link on you tube of our channel s_r tronics..
so..subscribe our channel..
and do likes and comments also..thankx