0% found this document useful (0 votes)
13 views

Expt 12

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views

Expt 12

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 4

Expt.No.

12
DESIGN AN IOT BASED SYSTEM
Date:

Aim

To design and implement an Arduino-based radar system capable of detecting and


displaying the presence of objects within a designated range using ultrasonic sensors and
servo motors, thereby illustrating the principles of radar technology in a hands-on laboratory
experiment.

HARDWARE & SOFTWARE TOOLS REQUIRED

S.No Hardware & Software Quantity


Requirements

1 Ultrasonic Distance Sensor (4-pin) 1

2 Arduino Uno R3 1

3 Positional Micro Servo 1

THEORY:

The Arduino Radar Project utilizes ultrasonic sensors and servo motors to replicate
the functionality of a radar system. Ultrasonic sensors emit waves and measure their
reflection time to determine object distances, while servo motors rotate the sensor module
akin to a radar antenna, expanding the detection area. Acting as the system's central
processing unit, the Arduino board interprets sensor data, computes object distances, and
orchestrates servo motor movements. Radar is a long-range object detection system that uses
radio waves to establish certain parameters of an object like its range, speed and position.
Radar technology is used in aircrafts, missiles, marine, weather predictions and automobiles.
Through this project, the fundamentals of radar technology merge with Arduino's
programming capabilities, offering an educational exploration into practical radar
implementation.

PROCEDURE:

 Connect the VCC pin of the HC-SR04 to the +5V pin of the Arduino.
 Connect the GND pin of the HC-SR04 to the GND pin of the Arduino.
 Connect the Trigger pin of the HC-SR04 to a digital pin (e.g., pin 9) of the Arduino.
 Connect the Echo pin of the HC-SR04 to another digital pin (e.g., pin 10) of the
Arduino.
 Connect the Signal pin of the Servo Motor to a PWM-enabled pin (e.g., pin 11) of the
Arduino.
 Connect the GND pin of the Servo Motor to the GND pin of the Arduino.
PROGRAM:
#include <Servo.h>
const int trigPin = 9;
const int echoPin = 10;
long duration;
int distinCM;
Servo radarServo;
void setup()
{
pinMode(trigPin, OUTPUT);
pinMode(echoPin, INPUT);
Serial.begin(9600);
radarServo.attach(11);
}
void loop()
{
for(int i=0;i<=180;i++)
{
radarServo.write(i);
delay(50);
digitalWrite(trigPin, LOW);
delayMicroseconds(2);
digitalWrite(trigPin, HIGH);
delayMicroseconds(10);
digitalWrite(trigPin, LOW);
duration = pulseIn(echoPin, HIGH);
distinCM = duration*0.034/2;
Serial.print(i);
Serial.print("*");
Serial.print(distinCM);
Serial.print("#");
}
for(int i=180;i>=0;i--)
{
radarServo.write(i);
delay(50);
digitalWrite(trigPin, LOW);
delayMicroseconds(2);
digitalWrite(trigPin, HIGH);
delayMicroseconds(10);
digitalWrite(trigPin, LOW);
duration = pulseIn(echoPin, HIGH);
distinCM = duration*0.034/2;
Serial.print(i);
Serial.print("*");
Serial.print(distinCM);
Serial.print("#");
}
}

CIRCUIT DIAGRAM OF ARDUINO RADAR PROJECT


RESULT:

Thus, the implementation of an Arduino-based radar system capable of detecting and


displaying the presence of objects within a designated range using ultrasonic sensors and
servo motors was verified using TinkerCAD.

You might also like