Introduction: Intel Edison: Radar

About: 31 years old tinker and diy hobbyist. From Oulu, Finland. IG @mkarvonen_instructables

This is a simple homemade radar using Intel Edison, HC-SR04 and Tower Pro micro servo.

Follow this guide to make your own.

Remember to vote for me if you like my project!

The video included can be viewed with mobile from HERE!

Step 1: Things Needed.

Few things needed to make this work.

First of all, programmable Arduino based board. I used Intel Edison.

Then you will need HC-SR04 ultrasound sensor.

And lastly a micro servo.

Optionally i made a shaft to the servo to hang the ultrasound sensor to it. The shaft is basic breadboard cut in size. This also allows to easily solder jumper wires to the sensor.

Step 2: Build the Sensor Shaft.

You will need 4 holes for the sensor and 4 holes for the cables. The length of the shaft is about 15 cm.

Solder the sensor to the other end of the shaft, add jumper wires and lastly solder the connector from the other end. It's simple but very reliable.

Step 3: Connections.

I made a simple shield for the whole thing just to keep all cables in a neat order.

The basics of this is that the Edison (With external power supply) will power the ultrasound sensor and the servo.

The basic USB power wont last long with this since the servo need's steady current and it draws much of it.

So this is how the connection is.

HC-SR04 Edison

Vcc-------------------Edison Vcc

GND-----------------GND

Echo---------------- Pin 6

Trigger--------------Pin 5

And for the micro servo

Vcc-----------------Vcc

GND---------------GND

Signal------------ Pin 9

After soldering i attached the micro servo on to the shield with hot glue.

The shaft goes straight on the servo with hot glue and zip ties.

Step 4: Insert It on the Edison and Start Coding!

The code basic's is pretty simple, just make the servo rotate in steps from right to left and back and then make the ultrasound sensor to look up the distance to the current position.

All the information is printed to serial, witch we will be using later to draw a describer from the data collected.

The code goes like this.

Define components and setup global variables.

#define ECHOPIN 6
#define TRIGPIN 5 #include

Servo myservo; int pos = 0;

Then lets get the setup right.

void setup() {
Serial.begin(115200);

myservo.attach(9);

pinMode(ECHOPIN, INPUT); pinMode(TRIGPIN, OUTPUT); }

And then the main program. If you want to adjust the angle of the servo just adjust the pos=10 and pos=170.

This is the servos movement in servo position. The pos+=3 means that each step is 3 steps for the servo motor.

oid loop() {
myservo.write(10); delay(1000); for(pos = 10; pos <= 170; pos += 3) { myservo.write(pos); Print(Distance() , pos); delay(15); } delay(1000); for(pos = 170; pos>=10; pos-=3) { myservo.write(pos); Print(Distance() , pos);

delay(15); }}

Then we make few subroutines to run in the loop. This will just make the main program look much more cleaner.

void Print (int R , int T)
{ Serial.print(R);Serial.print(", "); Serial.print(T);Serial.println("."); delay(100); }

float Distance () { digitalWrite(TRIGPIN, LOW); delayMicroseconds(2); digitalWrite(TRIGPIN, HIGH); delayMicroseconds(10); digitalWrite(TRIGPIN, LOW); // Distance Calculation float distance = pulseIn(ECHOPIN, HIGH); distance= distance/58.2; return(distance); }

Step 5: Run the Programm.

Download Processing 2 and insert the code from the file to the program and run it when the board is running.

If you need any assistance with this, Go to this project to get the info---> Intel Edison: Heart rate monitor

You can see the drawing what it does in the last picture.

That about it. If you have any guestion's just ask. I will try to answer them.

Thank's for reading!

Explore Science Contest

Participated in the
Explore Science Contest

Protected Contest

Participated in the
Protected Contest

On a Budget Contest

Participated in the
On a Budget Contest