chojaebingledel
Published © GPL3+

Arduino Robot Arm

Make a robot arm with Arduino and laser cutter.

BeginnerShowcase (no instructions)2 hours706
Arduino Robot Arm

Things used in this project

Hardware components

Arduino UNO & Genuino UNO
Arduino UNO & Genuino UNO
×1
Servos (Tower Pro MG996R)
×3
Analog joystick (Generic)
×1
Breadboard (generic)
Breadboard (generic)
×1
laser cut body
×1

Software apps and online services

Arduino IDE
Arduino IDE

Story

Read more

Code

arduino robot arm

Arduino
It is a code to play my robot arm
#include <Servo.h>
Servo servo;
Servo servo2;
Servo servo3;
int Xval, Yval , posx,posy;
void setup (){
  Serial.begin(9600);
  servo.attach (5);
  servo2.attach (6);
  servo3.attach (7);
}
void loop (){
  Xval = analogRead(A0);
  Yval = analogRead(A1);        
  Serial.print(Xval);  
  Serial.print('\t');
  Serial.print(Yval);
  Serial.print('\t');
  posx=map(Xval,0,1023,0,180);
  Serial.print(posx);
  posy=map(Yval,0,1023,0,180);
  Serial.print(posy);
  servo.write(posx);
  servo3.write(posx);
  delay(15);
  servo2.write(posy);
  delay (15);
  servo2.write(posy);
  delay(15);
}

Credits

chojaebin

chojaebin

1 project • 0 followers
gledel

gledel

100 projects • 91 followers
Looking back on my childhood, I was happy when I was making something and I was proud of myself. "Making is instinct!"

Comments