IOT Projects

GPS Tracker with GSM/GPRS using blynk with SMS and calling features

Learn how to build an accurate GPS Tracker with live location along with latitude, longitude, speed of the vehicle, no of satellites connected. Added some emergency features like SOS call and SMS with location data.

Have you ever thought of adding a GPS tracker to your vehicle to track the live location and speed of your vehicle with a mobile application. Then why don’t you make it by your own by interfacing few simple components to make a best GPS tracker. Follow the below complete article to learn how to do that with easy steps with circuit diagram. So before getting started lets know what are the hardware and software components required.

Project requirements:

Hardware components required:

For Location Tracking:

  • TTGO TCALL ESP32 WROVER-B based board with built in GSM
  • Neo6M GPS Module
  • Mini 3.7V battery  with capacity of your choice
  • SPST 2 pin switch to power on/off the device
  • Few connection wires

For Call and SMS Functions( optional )

  • 2 X 10K ohm Resistors
  • 2 X tactile push button switches

Software Requirements:

  • Arduino IDE
  • Blynk application on mobile device

TTGO T-call :

It is an ESP32 based board with 240MHz Xtensa® dual-core 32-bit LX6 microprocessor. It stands in the best boards with features like inbuilt WiFi, Bluetooth, and GSM800L.


  • WiFi = 802.11 b/g/n(802.11n, speed up to150Mbps)
  • Bluetooth = bluetooth v4.2
  • GSM module = GSM800L with support for Nano sim
Power Supply Specifications
Power Supply ( input) USB 5Volts/1Amp
Charging current 500mA
Battery compatible 3.7V lithium battery
USB Type-C


Circuit Diagram:

Connect all the components mentioned above by following the below schematic diagram.

GPS Tracker with GSM using blynk with SMS circuit diagram
Click the image to enlarge

In the above diagram we connected 3.7V Li-po battery to power up the board with a SPST switch to turn the device ON/OFF.

Connected the Vcc and GND of the GPS module to the 3.3v and GND pins on the TTGO board. and connected the Tx of the GPS module to the Rx of the TTGO and Rx of the GPS module to Tx of the TTGO board.

We connected two push switches with the help of 2 X 10 k ohm resistors to 34 and 35 pins of the TTGO  T-call board as 34 connected button for SMS and 35 connected button for call.

That’s it every thing is ready and lets jump into the working of the device.

Now download the Blynk application from playstore ore apple apple store on your mobile and login or signup and create a new project named GPS Tracker with device as “ESP32 Dev board” and connection type as ” GSM” to get the auth token on your registered mobile email account to paste it in the code.

Uploading the Code and installing on blynk mobile:

Before uploading the code install few required libraries on your Arduino IDE from below links:

  1. TinyGPS++.h  download link: here
  2. TinyGsmClient.h  download link: here
  3. AceButton.h  download link: here
  4. BlynkSimpleSIM800.h download link: here

Our code consists of two files one is main file and another one is dependency you can download the complete code from our github repository here. Download

  • GPS_Tracker_with_ttgoesp32.ino
  • utilities.h

After downloading the code you need to make some changes in the code to add your mobile number to which you need to send the location data by SMS in case of emergency or to make a call and add the blynk auth token which you had got on your mail while creating the project on Blynk mobile.

In Line 39 Replace the “Mobile Number with country code” with “+00 0000000000”

// Emergency Number and Message
String mobile_number = "Mobile Number with country code";
String message = "It's an Emergency. I'm at this location ";

In line 67 Add the network APN to access the internet from the sim card, and in line 74 add your Blynk auth token

// Hardware Serial for builtin GSM Module
#define SerialAT Serial1

const char apn[]  = "YOUR_NETWORK_APN_HERE";

const char user[] = "";
const char pass[] = "";

// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
const char auth[] = "YOUR_BLYNK_AUTH_TOKEN";

That’s it now connect the TTGO T-call to PC and check the port it is connected and select the port in arduino IDE tools section. and select the board as “ESP32 Wrover module”  and click the upload button.

Now open blynk application and click on settings in project to get widget selection side bar and choose a map widget and click ok the map to get its settings. As we assigned the map location to the virtual pin V0 select the imput option as V0 and hit OK.

Add two Value displays one for latitude and another for longitude and assign them with virtual pins V1 and V2 respectively.

Add three more value displays for speed, Direction and No of satellites connected. and assign them with V3, V4 and V5 respectively.

Thats is all the setup is done. Now lets check how the device works below.

Working Of GPS tracker:

After the code upload turn ON the device with the power button to turn on the device but it dint get powered On because of its built in power button, you need to press the on-board power button once to turn on the board. Ok the the LED on the  TTGO T-call board blinks.

After few seconds you will see the LED on the GPS module blinks which indicates that the GPS is connected. But sometimes it won’t gets started if you stay indoors as GPS wont get connected to the satellites. Move on to the outdoors and notice that the GPS module starts blinking indicated the working.

Now start the blynk application by pressing the run button at top right to view all the data coming from the device like live location, lattitude, longitude, speed, direction and number of satellites connected.

GPS location data shown on Blynk application

You can use the emergency SMS and call buttons by clicking one to send the location data by SMS or to call the number emergency  number specified in the code.

That’s it our project is ready you can test it by a simple ride carrying the device.

If you like this project please  share it with your friends and please support us by following our facebook page.

CircuitSchools Staff

We at CircuitSchools publish on basics of electronics and electric components and everything related to evolution of electrical technology with complete analysis of development boards and modules along with latest projects with innovative ideas.

Related Articles

Back to top button