TweakTown
Tech content trusted by users in North America and around the world
5,934 Reviews & Articles | 38,225 News Posts

Project M.A.R.V: The Multi-Rotor Aerial Reconnaissance Vehicle, Part 2

Project M.A.R.V: The Multi-Rotor Aerial Reconnaissance Vehicle, Part 2

In this installment, we cover the tiny GPS Data Logger that will mount directly to the frame of the quad-copter and allow recording its flight path.

| Editorials in Maker & DIY | Posted: Apr 22, 2014 2:05 am

GPS Data Logging

 

TweakTown image content/6/2/6266_1_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

 

When I decided to build a multi-rotor, I knew I that I wanted to track its flight path, as I would be flying several hundred yards once I had the FPV setup going. I spent weeks searching for and reading up on small-scale GPS Data Loggers that were simple to use and easy to program. Then one day, I stumbled upon an article on Make.com that was exactly what I was looking for, and I had everything already on hand to build it.

 

TweakTown image content/6/2/6266_3_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

 

You might remember a review I did on the TinyCircuit's Arduino-compatible development kit a few months back. Turns out that the hardware used in the Make.com article utilized this same hardware, and was in fact, written by the founder of TinyCircuits. So with hardware in hand, and the code pre-existing, I had a quick head start to get this small sub-project off the ground.

 

TweakTown image content/6/2/6266_2_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

 

Included in the kit I received was a fully functional micro-GPS shield that was not much larger than a quarter, an SD card shield, and an Arduino. When stacked together, the entire package is about 1-inch cubed, which makes the stack the perfect size for attaching to RC aircraft. With everything I needed to develop my GPS logger, I sat down at my bench to get the party started.

 

The GPS data logging project I found on Make.com was designed to track the author's cat, but the code I needed to get my project off the ground would do the job whether it was tracking a cat or tracking the flight path of my quad copter.

 

TweakTown image content/6/2/6266_4_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.png

 

The TinyDuino series is pretty cool because you have a full Arduino Pro / Pro Mini packed onto a board the size of a quarter. I won't go into great detail about the boards and what makes them so special, but if you would like further information on them, check out the full overview I wrote that is located here on TweakTown. Below is a list of everything you need to create a simple GPS Data Logger of your own using the TinyCircuits hardware. You can find all of the code and needed files on the Github Repository I made for this sub-project. I will eventually update the QuadCopter repository to include these files as well.

 

  • TinyDuino
  • TinyShield microSD
  • TinyShield GPS
  • TinyShield USB & ICP
  • TinyDuino Mounting Kit
  • 3D Printed Case
  • Code
  • Class 4 or higher 4GB microSD Card

 

TweakTown image content/6/2/6266_5_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

 

There really is not much to building the GPS Data Logger other than stacking the shields in the correct order, uploading the code to the Arduino, and then getting outside and logging some data. The stack should be built-in the following order. The bottom most board should be the TinyDuino, which should then be followed by the TinyShield microSD board. Up next would be the TinyShield GPS, which is followed by the TinyShield USB and ICP.

 

TweakTown image content/6/2/6266_6_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

 

I chose to power my GPS Logger using an 18650 powered USB cellphone charger instead of the CR2023 or JST methods that the TinyDuino also supports. If you chose to go this route, you will need to arrange your stack with the TinyShield USB & ICP board placed between the TinyDuino and TinyShield GPS; I chose this route because I had several spare USB cellphone chargers laying around.

 

TweakTown image content/6/2/6266_7_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

 

With everything stacked together, let's prepare the TinyDuino for coding. Plug a microUSB cable into the TinyShield USB & ICP board, then select the appropriate USB port that the TinyDuino is now connected to. Once the correct port has been selected, we need to set the Arduino IDE to recognize the correct Arduino-compatible board. Since we are using a TinyDuino, we need to select Arduino Pro or Pro Mini (3.3V, 8MHz) w/ ATmega328. Once finished, we should be ready to import some test code to the TinyDuino to test that everything is working correctly.

 

Before we upload any code, we will need to make a minor change to the SoftwareSerial library in the Arduino IDE. You will need to replace the SoftwareSerial.cpp and SoftwareSerial.h Library files with the ones found in the GitHub repo for this tutorial. Replacing the files is quite easy, and you simply need to navigate to Arduino>libraries>SoftwareSerial and rename the existing files to SoftwareSerial_cpp.bak and SoftwareSerial_h.bak and then download the new files into this directory.

 

Now that that is complete, let's upload some test code to make sure that everything was configured correctly and the TinyShield GPS module is sending raw NMEA data to the Tiny Duino. Upload the code that is embedded below (also found in the Git repo titled GPS_Test_Firmware.ino and then open the serial terminal in Arduino and set the baud rate to 9600. You should see some weird strings that look like the pasted code below the GPS Test Firmware code.

 

TweakTown image content/6/2/6266_17_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

 

TweakTown image content/6/2/6266_18_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

 

If the data that appears in the serial terminal does not look like this, then you will need to re-upload the SoftwareSerial files and upload the test code again.

 

Now that everything is working fine, we need to upload the actual GPS Data Logging code to the TinyDuino. I have pasted the code below, and remember to insert a properly formatted microSD (read how to do this here) card into the TinyShield microSD.

 

TweakTown image content/6/2/6266_19_project_m_a_r_v_the_multi_rotor_aerial_reconnaissance_vehicle_part_2.jpg

Related Tags

Further Reading: Read and find more Maker & DIY content at our Maker & DIY reviews, guides and articles index page.

Do you get our RSS feed? Get It!

Post a Comment about this content

Latest Tech News Posts

View More News Posts

TweakTown Web Poll

Question: Facebook's acquisition of Oculus VR will...

Improve Oculus Rift Development

Hamper Oculus Rift Development

Completely destroy Oculus Rift Development

Let's wait and see, I'm not sure

or View the Results

View More Polls

Forum Activity

View More Forum Posts

Press Releases

View More Press Releases