Laser Fighting Robot

2,661

60

7

Published

Introduction: Laser Fighting Robot

Hello, Everyone. This is a series of courses, I will share how to use cartons and arduino to make something interesting,today,I'll share with you a laser fighting robot, and I'll show you how to make a robot. By the way,I am very poor standard of English.Hope you will understand me.

Game rules, through the production of two or more battle robots, remote control of the laser head movement, when the laser light to the other side of the photosensitive resistor on the carton, the description was hit, the robot stopped working

Step 1: You Need to Prepare These Materials

Step 2: Circuit Diagram

Step 3: Assembly

In this step, I will show how to build a laser fighting robot. Servo base was use of 3d printing, of course,you can also buy in the Amazon or other web site

Step 4: Code

#include<Servo.h>

Servo servo_8;

Servo servo_9;

void setup()

{

Serial.begin(9600);

pinMode(13, OUTPUT);

pinMode(2, OUTPUT);

servo_8.attach(8);

servo_9.attach(9);

}

void loop()

{

Serial.println(analogRead(A2));

digitalWrite(13,HIGH);

if (analogRead(A2) > 150) {

digitalWrite(13,LOW);

tone(2,131);

delay(500);

noTone(2);

delay(500);

while(true);

} else {

servo_8.write((map(analogRead(A1), 1, 1023, 1, 180)));

delay(50);

servo_9.write((map(analogRead(A0), 1, 1023, 45, 135)));

delay(50);

}

}

Step 5: GameRules

You need to make two laser fighting robots.Use the joystick to control the movement of the laser head. When the laser irradiates the other side of the photosensitive resistor on the carton of the opposite party,The robot stopped working.

Share

    Recommendations

    • Casting Contest

      Casting Contest
    • Woodworking Contest

      Woodworking Contest
    • Make it Move Contest

      Make it Move Contest
    user

    We have a be nice policy.
    Please be positive and constructive.

    Tips

    Questions

    7 Comments

    Cool, I love projects involving 3D printing and Arduino! And it looks easy to make, and fun to use.

    I agree with the comments below, please post a video!

    This would be a great project for an intro to robotics class. To add another layer of difficulty, you could mount this on top of a RC car. So they have to steer and aim from different locations.

    1 reply

    Yes, so this is going to be a project that I will do in the future

    Wow!! These 3D models are mine!!

    Looks awesome.

    And I agree with BrownDogGadgets; video!

    1 reply

    I'll make up the video as soon as possible