Arduino Product Display

by goks_lf in Circuits > Arduino

553 Views, 1 Favorites, 0 Comments

Arduino Product Display

2.6.png

Have you ever seen product rotating on its own ???Yes, today we are creating the same product displayed using simple item i.e a servo motor and Arduino.I forgot to introduce myself, I'm Gokul.I have said you initially what's today project we are about to deal now.Let's now get Components required to make this ibles .

Components Required

2.2.png
2.3.png
2.5.png
2.4.png

components required are as above:

  • Arduino
  • Servo
  • Knife
  • cardboard
  • tape

Servo Connection

IMG_20170817_192319.jpg
IMG_20170817_192412.jpg
IMG_20170817_192415.jpg
IMG_20170817_192427.jpg
IMG_20170817_192445.jpg
IMG_20170817_192456.jpg

servo connection is a type of motor that is used to control the angular rotation and speed of the rotating shaft.

Here Servo is connected is as follow:

  • The VCC pin or red wire is connected to the 5v pin on the Arduino Uno.
  • The GND pin or the maroon wire is connected to the GND pin of the Arduino Uno.
  • The signal wire or the orange wire is connected to the digital pin of 3 of Arduino Uno.

Cutting and Fixing

IMG_20170817_192831.jpg
IMG_20170817_192847.jpg
IMG_20170817_192938.jpg
IMG_20170817_193014.jpg
IMG_20170817_193039.jpg

cut a cardboard into circle or any of shape as you wish to.Then place your horn on the cardboard,Then stick the horn on the cardboard using a tape or hot glue.

Coding

#include "Servo.h"
Servo myservo;  // create servo object to control a servo
// twelve servo objects can be created on most boards
int pos = 0;    // variable to store the servo position
void setup() {
  myservo.attach(7);  // attaches the servo on pin 9 to the servo object
}
void loop() {
  for (pos = 0; pos <= 180; pos += 1) { // goes from 0 degrees to 180 degrees
    // in steps of 1 degree
    myservo.write(pos);              // tell servo to go to position in variable 'pos'
    delay(15);                       // waits 15ms for the servo to reach the position
  }
  for (pos = 180; pos >= 0; pos -= 1) { // goes from 180 degrees to 0 degrees
    myservo.write(pos);              // tell servo to go to position in variable 'pos'
    delay(15);                       // waits 15ms for the servo to reach the position
  }
}