Making Radar Using Arduino, Ultrasonic Sensor, and MATLAB

Introduction: Making Radar Using Arduino, Ultrasonic Sensor, and MATLAB

In this project we are going to make a simple radar to detect obstacles.
Range depends on the range of the Ultrasonic sensor we used (in this project : 3 meter) .

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Components

Components :

1 - Arduino Uno
2 - Ultrasonic Distance Sensor ( link : https://www.parallax.com/product/28015).
3- Servo Motor.

Step 2: Wiring and Connections

1- Connect Ultrasonic sensor (5V and GND) to Arduino (5V and GND).
2- Connect Ultrasonic sensor (SIG) to Arduino (Digital pin 8).

3- Connect Servo motor (5V and GND) to Arduino (5V and GND).
4- Connect Servo motor (SIG) to Arduino (Digital pin 9).

5- Connect Arduino Uno to your Computer using USB cable.

Step 3: Coding

There are two code files attached in this step :
The first one for Arduino and the other of MATLAB.

for Arduino code :
you don't need to modify it , just upload it on Arduino.

for MATLAB code :
you need to modify line 28 ( s1 = serial('COM12'); )
to your new com port # .

NOTE : Before closing MATLAB, close the serial port by writing "s1.close()" in MATLAB workspace.

3 People Made This Project!

Recommendations

  • Backyard Contest

    Backyard Contest
  • Silly Hats Speed Challenge

    Silly Hats Speed Challenge
  • Finish It Already Speed Challenge

    Finish It Already Speed Challenge

36 Discussions

0
VarunS125
VarunS125

Question 1 year ago

Can you please help me as I'm using a4 pin Ultrasonic sensor and it has distinguished echo and trigger ports in place of singular signal port. What changes I should make?

0
Hediyeh-M
Hediyeh-M

Question 1 year ago on Step 3

Hi, I'm trying to do this project by AVR . I have a problem in matlab code, it gives a warning
" unsuccessful read : a timeout occurred before the terminator was reached."
Did you not face such warnings?
Can you please help me, I don't know what to do with that.

0
_arshp
_arshp

Question 2 years ago on Step 3

Can u please explain the Matlab code to me on my email id harshp1697@gmail.com.. have doubts regarding the number specification used in the code

0
AkshayA44
AkshayA44

2 years ago

i want to do that using python. can uh pls help me?

0
enriqueibarrasilva
enriqueibarrasilva

3 years ago

Hi, i'd like to know, how can include two ultrasonic sensors in the program?

0
enriqueibarrasilva
enriqueibarrasilva

Reply 3 years ago

I'm using the matlab one btw

0
thebookthief01
thebookthief01

3 years ago

Can you make the radar sensor thing screen show up with Arduino? I've tried uploading the Arduino code to my Arduino Uno, but am not sure how you view the radar using Arduino. I have also tried looking at the Arduino serial monitor.

1
sukeshr
sukeshr

4 years ago

I WANT TO USE HCSR04

PLEASE HELP ME IN CONNECTING WITH ARDUINO

0
MrinalS
MrinalS

Reply 3 years ago

need it yet?

0
MinhN55
MinhN55

Reply 4 years ago

I also want. You've done it yet?

0
RaheelZ2
RaheelZ2

3 years ago

hello.where is the coding for visual?

0
dannybarh
dannybarh

4 years ago

Hey,

Nice work there. I like to know if the rotation can be 360' and will it work as same. Can it calculate the distance of objects it pick up too?

0
KiyingiA
KiyingiA

4 years ago

how do i get the my computer to display the radar

0
Aditya Goyal
Aditya Goyal

4 years ago

hey, when i did the project seeing your site, there was a problem with the speed. the speed of my servo motor while rotating is toooooo slow. how would i solve this problem. please give me a correct suggestion because i need to do it for my science fair. hope for your fast response

0
lheise
lheise

4 years ago

Hello, i have a mac, and how do i do to know what its my port#???

Thanks

0
bushan
bushan

Reply 4 years ago

can you tell me y proxy is needed

0
bushan
bushan

Reply 4 years ago

can you tell me y proxy is needed

0
bushan
bushan

Reply 4 years ago

can you tell me y proxy is needed

0
bushan
bushan

Reply 4 years ago

can you tell me y proxy is needed