Introduction: Arduino Motion Tracker

Hi everyone!

This is my first arduino based instructable i hope you will like it:) I'm a big fan of the first Alien movie and the "old-sci-fi" gadgets, so I decided to make a fully operational portable motion-tracker. In this tutorial I will show you every step how I made it so you can make your own one. Plus at the end I will give you some advice according to my experiences so you can make an even better one. This was the first time I used a tft-lcd monitor and some faild attempt I was so happy when I realised how can I use it:)(Of course i will show you how can you use it properly)

I hope you are gonna enjoy this instructable and maybe some of you will make his/her own one. So let's start the making:)

Step 1: What You Need:

Materials and parts:

  • Arduino Mega (because of the pins )
  • 2.4" TFT display (I used one from mcufriend)
  • 3 pcs PIR sensor (HC-SR501)
  • 1pcs ultrasonic distance sensor (HC-SR04)
  • 1pcs piezo buzzer
  • 1pcs 100ohm resistor
  • some male-male jumper cable
  • many male-female jumper cable (for the display and the sensors)
  • 1pcs 11*11 cm junction box
  • 1pcs 15*11*7 cm junction box
  • 1pcs toggle switch
  • plastic sheet(I used some oddments)
  • a few screw with the screw nuts
  • 1 paif of bicycle handlebar grip
  • warning tape (for the good looking )
  • 1pcs 9v battery
  • 1pcs 9v battery clip
  • 1pcs Male Power Jack Plug 5.5 x 2.1mm
  • 2.1*5.5 male plug
  • some shrink tube
  • electrical tape
  • mini breadboard
  • pvc tube

Tools:

  • paint spary (coloring the junction boxes)
  • soldering iron
  • rotary tool
  • glue gun
  • Jig saw
  • Hole saw cutter
  • rasp
  • forceps

Step 2: The Circuit

The plan was a device what can sensing motion in three different way, so I needed three PIR motion sensors on the three different sides of the device. And an ultrasonic distance module on the front. For the sensors I used a part of the mini breadboard for the common 5V and common GND. And one of the 9V clip's cable soldered to the toggle switch so i can turn it ON/OFF. I soldered a 100Ohm resisitor to the piezo buzzer it protect the arduino board. I had to use an arduino MEGA because of the display it needs a lot of pins and an UNO doesn't have enough for the display and the sensors. Good to know the ultrasonic sensor maximum range is about 4 meter and the PIR motion sensor's maximum range is about 7 meter. But you can modify The PIR sensor's range and the delay time with 2 tiny potentiometer on the sensor. In the first picture you can see there is a lot of jumper wire so i mad a schematic picture with fritzing. It makes easier to connect correctly the sensors:)

Step 3: The Code

This part was a bit tricky, because when I tried to use the tft lcd screen always got a white screen. After some reading I realized it's not a rare problem if you use clone arduino board with not adafruit displays .I needed some hour to find the solution. (I find it in someone's instructable:) ). To save you some time you can download the modified libraries and the code what I used. After I learned how to avoid the whitescreen problem it was really fun to learn how to draw on the tft display. I'm sure i will do some other project with this type of displayshield. When I read about these sensors I noticed that they need some time to calibrate themself so to fill this time I write a "boot display" in the setup part. In the code you can check how to code a PIR sensor and the ultrasound module. I learned to use them from otherone's instructables and some great website:) I write a code that calculate the distance in cm so you need to rewrite it if you want to see it in inch. If you have any suggestion about to improve the code pls leave a comment:)

I put here 2 videos to show you the device in progress.

(Here the URLs so you can check it from phone too)

Boot monitor

Motion tracking

I tried to leave a comment for every important line or function, but if you have anny question about a code pls ask i will answer as soon as i can.

!IMPORTANT:This code is only working on arduino mega if you want to use it on an uno board you need to modify the SWTFT library uncomment uno_line and comment the mega_line!

(I want say a big thank you for these people who amended these libriaries)

Step 4: The Shell

For the shell of the device i used 2 junction boxes. The bigger one contains the arduino mega and the batteries. The other one contains the tft display. I painted the boxes with a paintspray. Good to know the plastic is becoming dry in a few hours, but on the rubber caps the paint can't be completly dry. It seems I shouldn't use this paint for rubber. After the painting I cutted 2 parts from an old unsed plastic sheet. With this 2 parts i fixed the 2 junction boxes with some screws and screw nuts. For the handle I used a piece of PVC tube. I cutted the surplusage. And I had to cut a line for the wires from the display and the distance module. I also cutted a rectangle shape hole on the top of the little junction boxe for the display. After the cutting with the jig saw I drilled the holes for the handle. Then i painted the parts. For the toggle switch i used the junction box's cutted part. After everything is dried i put the rubber caps back to their places.

Step 5: Assembling

The first step was the cabling. That was a bit meticulous work. Because there wasn't soo much place and i needed to put every jumper cable into the proper hole. After that i putted the buzzer and the left and right PIR sensor into the junction box, connect to the arduino. Good to know these sensors really sensitive so i had to overshadow them somehow. For that i used the rubber caps. I cutted a little hole on them as you see on the pictures. I fixed the sensors with some electric tape. I also used electric tape to fix the utrasonic module and the front PIR sensor. I cutted in half and vertical the bicycle grips for the handler. I don't like wasting so i used the unused grip part as a spacer for the display in the smaller junction box. I hided the orange edges of the display with some black electric tape. I glued one of the unused rubber cap to the bottom of the device so it can hide the end of the green pvc tube. For the good look i put some yellow/black warning tape on the device. Last step was to unplug the usb connector and plug the male power jack plug. Switch it ON and start Tracking motion:)

I bought the snesors and the arduino from ebay the other materials from local home improvement store. The final cost of the device is about 15-20 USD.

The final conclusion of the project is you can make literally everything what you want with the proper arduino board and some sensor and module. You can make a better looking shell if you have a 3D printer and your device could have a longer working time if you replace the 9v battery with a rechargeable or Lipo battery. And with a bigger display it looks better. Or if you use more distance mesure module you can mesure the distance in multiple way.

Now you now how to make a Motion Tracker if one of you make his/her own please leave a "I made it" comment and share with me the result. I would love to see your own gadgets.

Maybe this device will help you avoid Xenomorphs.

If you have any question please feel free asking me!

Happy making:)

Comments

author
LordneverW (author)2017-07-19

how much did it cost to make? would ever build one to sell? and if so how much.

author
BrianH116 (author)2016-11-11

I need this!!

I've downloaded everything but it proper scares me now I've looked at it. This will be my first project with Arduino

author
Dylan91 (author)BrianH1162016-11-11

If you never ever used an arduino i guess you need some practice. But i'm sure you can easily make it:) If you have any question pls feel free to ask it i will answer as soon as i can.

hint: i think the best training if you try to use the different sensors separatedly. I think i left enough comment in the cod, but you can find tons of tutorials for the arduino sensors. Good luck for the making.

P.S. pls send me a picture if ready.

author
BrianH116 (author)Dylan912016-11-12

Thank you v much, that would be a great help. If you don't mind, when im ready to order my components, if you could just check my list to make sure im ordering the right bits and pieces that would be a great help! I dont want to spend a ton on my first project just in case i mess up ;) and the world of Arduino boards is still a minefield to me.

author
Dylan91 (author)BrianH1162016-11-12

Sure:)

author
BrianH116 (author)Dylan912016-12-05

well, its taking some time but ive sourced these, what do you think?

Cant seem to get a tft that's not touch screen, guess that doesn't matter?

http://www.ebay.co.uk/itm/TFT-LCD-Display-Arduino-...

http://www.ebay.co.uk/itm/Microcontroller-Board-AT...

Anyway, appreciate your help. cheers :)

author
Dylan91 (author)BrianH1162016-12-05

Hy!

Of coourse. I also used and lcd/touch screen. The only difference is the size. My screen is only 2,4, but its not a problem with a bigger screen it will look much cooler. And yes i used the same arduino board, but you stell need 3pcss inrared sensor and 1pcs ulrasound distance sensor.

author
BrianH116 (author)Dylan912017-01-23

Hey Dylan,

Just to update you on my progress. Its taken a while but I've got the screen working and i have all the sensors hooked up but these still need fine tuning. Getting some random readings which i want to try and sort out and am going to start on constructing the body very soon. Im basing it on the tracker from the film Aliens, been doing my research ;)

WP_20170123_22_11_09_Pro.jpgWP_20170123_22_11_05_Pro.jpg
author
BrianH116 (author)Dylan912016-12-06

Awesome, many thanks. Will take a while to arrive from hong kong but i cant wait to get started :)

author
Ortiz73 (author)2016-12-16

This is an amazing ible. Can't wait to get started. One question; is it possible I'll be able to draw a different image onto thetft but still have the same concept(same function etc)

author
Dylan91 (author)Ortiz732016-12-16

Thank you! Of course you can draw almost anything, if you can program it. My design try to copy the design of the motion tracker from Alien: Isolation:) Pls leave a picture if you finished your one. Happy making!

author
ok_computer_ (author)2016-08-02

Amazing!

author
Dylan91 (author)ok_computer_2016-08-03

Thank you so much:)

author
Wolf321 (author)2016-07-13

*Le instantly votes for this project

author
Dylan91 (author)Wolf3212016-07-14

Thanks a lot for your awsome comment and and your vote. I'm happy to see when someone lika my work:) Have a nice day!!

author
Wolf321 (author)2016-07-13

ERMAGERSH! THIS IS AMAZING!

author
Bay Yolal (author)2016-06-17

Awesome! Very good idea for detection! Thank you!

author
Dylan91 (author)Bay Yolal2016-06-17

Thank you for this positive response:)

author
mrwillcreates (author)2016-06-16

Wouldn't the sound waves from each individual module interfere?

author
Dylan91 (author)mrwillcreates2016-06-16

Yes they would if put them in a line. But this module has a 15degree range, so if you put the modules in askew (15degree) they won't interfere. Thanks for the question:)

author
PranavN6 (author)2016-06-09

Can you provide video link of working model

author
Dylan91 (author)PranavN62016-06-09

Hi:) There are 2 video at the code section.

author
Arty Marty (author)Dylan912016-06-09

Can you please edit your article and put the actual URL for the videos in the text, unfortunately on the Instructable app they don't show up otherwise.

... and I have to say, this is frikkin awesome!
Well done!!!
It's amazing in the original movie, the scanner props they used had an actual cathode ray tube TV and a huge cable delivering the video signal. You've made it all self contained for $50!

author
Dylan91 (author)Arty Marty2016-06-09

Hy Thank you soo much:) Of course i will put the URLs into the tutorial. And it's not cost $50 just only $15-20. And thank you one more time this comment made my day:)

author
Dylan91 (author)PranavN62016-06-09

But you have a point i will try to make a better video.

author
mrwillcreates (author)2016-06-09

Wow! really cool i'ible. can it detect multiple objects at once?

author
Dylan91 (author)mrwillcreates2016-06-09

Thank you. Unfortunatly it can't but if you use more ultrasonic module it can detect more target:)