Smart GPS Tracker Using Arduino

Ashwini Kumar Sinha

6253
Advertisement

Parents often worry about their children when they are away from them. Have they safely reached school? Are they alone at home? Or are they at the playground with friends? – these are some of the questions that bothers parents all over the world.  

So, today we are going to make a smart tracker that can keep track of a child. Besides this, the device can also be used to track your vehicle location and other objects. Let’s begin. 

First, collect the following components. 

Components 

  • GPS Module
  • Arduino Nano
  • SIM800L 
  • 2G SIM card 
  • OLED Display
  • Small 3V battery 
  • Wires 

Prerequisites 

First we need to install the libraries ‘Tiny GPS ++’ and ‘FONA’  in Arduino IDE. To do so, go to tools → click on library manager → search the required library → install the library.

Coding 

In first part of the code, initialise the library in code. Next, create some variables that will store the message, GPS location and other data. Then we define the pins for GPS module and SIM800L module.

After that, we will create the setup function where the baud rate of SIM800L and GPS modules for serial communication are set to 4800 and 9600 respectively. 

Fig 1.
Fig 2.

Here, we have created a loop function to check whether the incoming message has been received by SIM800L or not. If the message has been received, then convert it into a readable string. It will check the message for a ‘get location’ command, after which the collected data (with respect to location) will be sent back to the original device..

Within the same loop function, a function named get location() will be called .This function will keep updating the GPS data and return the results to the loop function

Fig 3

Connection 

Now connect the components as shown in the pic below:

Fig 4.Connection created in Fritzzing

Testing

Power the device with a battery and wait for a few minutes. The device will then become ready for use. 

Send the message ‘get location’ to the smart device and you will receive a message with the location URL, which you can check on Google Maps.

Fig 5.

Code

Advertisement


11 COMMENTS

    • Code is attached at the bottom of page you can download directly.Just click on the “Code” written in DEEP Red color

  1. Good evening,
    I have a project for my Baschelor that deals with the same subject and I really need your help. I’m begging you.
    Here’s my email. You can write me so we can exchange ideas.

    I would really appreciate it if you can help me.

    Thank you in advance
    004917687888597 (Watzap)

    Lukas

SHARE YOUR THOUGHTS & COMMENTS

Please enter your comment!
Please enter your name here