Making Radar Using Arduino, Ultrasonic Sensor, and MATLAB

Intro: 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) .

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

  • Plastics Contest

    Plastics Contest
  • Optics Contest

    Optics Contest
  • Audio Contest 2018

    Audio Contest 2018

35 Discussions

0
None
Hediyeh-M

Question 3 months 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
None
_arshp

Question 6 months 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
None
AkshayA44

1 year ago

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

0
None
thebookthief01

1 year 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.

0
None
sukeshr

2 years ago

I WANT TO USE HCSR04

PLEASE HELP ME IN CONNECTING WITH ARDUINO

2 replies
0
None
MinhN55sukeshr

Reply 2 years ago

I also want. You've done it yet?

0
None
RaheelZ2

1 year ago

hello.where is the coding for visual?

0
None
dannybarh

2 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
None
KiyingiA

2 years ago

how do i get the my computer to display the radar

0
None
Aditya Goyal

2 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
None
lheise

3 years ago

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

Thanks

5 replies
0
None
bushanlheise

Reply 2 years ago

can you tell me y proxy is needed

0
None
bushanlheise

Reply 2 years ago

can you tell me y proxy is needed

0
None
bushanlheise

Reply 2 years ago

can you tell me y proxy is needed

0
None
bushanlheise

Reply 2 years ago

can you tell me y proxy is needed

0
None
bushanlheise

Reply 2 years ago

can you tell me y proxy is needed