GPS Tracker using Arduino and SIM800L

 

The GPS Tracker using Arduino and SIM800L project is a device that allows you to track the location of a vehicle or any other object in real-time. The project is built using an Arduino board and a SIM800L module, which is a GSM/GPRS module that can be used to send and receive SMS messages and make phone calls.

The project uses the GPS module to get the location coordinates (latitude and longitude) of the device and sends it to the SIM800L module. The SIM800L module then sends the location coordinates to a designated phone number using the GPRS feature of the module.

Here is a basic outline of how the project works:

  1. The Arduino board is connected to the GPS module and the SIM800L module.

  2. The GPS module is used to get the location coordinates of the device.

  3. The Arduino board reads the location coordinates and sends them to the SIM800L module.

  4. The SIM800L module uses the GPRS feature to send the location coordinates to a designated phone number.

    You may like these posts

  5. The user can track the location of the device by receiving the location coordinates on their phone.

     




The project can be easily customized to suit your needs. For example, you can add a button to the device to send the location coordinates on demand, or you can set a time interval for the device to send the location coordinates automatically.

To build this project you will need an Arduino board, a SIM800L module, a GPS module and a power source such as a battery. You will also need a SIM card with GPRS and SMS services enabled, and a phone number to receive the location coordinates.

It is important to note that the project requires some basic knowledge of programming and electronics. Additionally, you may need to consult the documentation of the specific modules and components you are using to properly wire and program them.

 

shematic

 


  

 code:

/* 
  #include <SoftwareSerial.h>
#include <TinyGPS++.h>

SoftwareSerial gpsSerial(2, 3); // RX, TX
TinyGPSPlus gps;

#define SIM800L_RX 4
#define SIM800L_TX 5
SoftwareSerial sim800lSerial(SIM800L_RX, SIM800L_TX);

void setup() {
  Serial.begin(9600);
  gpsSerial.begin(9600);
  sim800lSerial.begin(9600);
 
  // Send AT command to SIM800L to ensure it is awake
  sim800lSerial.println("AT");
  delay(1000);
  sim800lSerial.flush();
 
  // Send AT command to SIM800L to enable GPS
  sim800lSerial.println("AT+CGNSPWR=1");
  delay(1000);
  sim800lSerial.flush();
 
  // Send AT command to SIM800L to get GPS data
  sim800lSerial.println("AT+CGNSINF");
  delay(1000);
  sim800lSerial.flush();
}

void loop() {
  // Read data from GPS module
  while (gpsSerial.available()) {
    gps.encode(gpsSerial.read());
  }
 
  // Read data from SIM800L
  while (sim800lSerial.available()) {
    String gpsData = sim800lSerial.readString();
    if (gpsData.indexOf("+CGNSINF:") >= 0) {
      // Extract latitude, longitude, and time
      int latStart = gpsData.indexOf(",") + 1;
      int latEnd = gpsData.indexOf(",", latStart);
      String latitude = gpsData.substring(latStart, latEnd);
      
      int lonStart = latEnd + 1;
      int lonEnd = gpsData.indexOf(",", lonStart);
      String longitude = gpsData.substring(lonStart, lonEnd);
      
      int timeStart = gpsData.lastIndexOf(",") + 1;
      int timeEnd = gpsData.length();
      String time = gpsData.substring(timeStart, timeEnd);
      
      // Print latitude, longitude, and time to serial monitor
      Serial.print("Latitude: ");
      Serial.println(latitude);
      Serial.print("Longitude: ");
      Serial.println(longitude);
      Serial.print("Time: ");
      Serial.println(time);
    }
  }
 
  delay(1000);
}



Commentaires

  1. To insert a code use <i rel="pre">code_here</i>
  2. To insert a quote use <b rel="quote">your_qoute</b>
  3. To insert a picture use <i rel="image">url_image_here</i>
Tinggalkan komentar sesuai topik tulisan, komentar dengan link aktif tidak akan ditampilkan.
Admin dan penulis blog mempunyai hak untuk menampilkan, menghapus, menandai spam, pada komentar yang dikirim
Affordability

Affordability

Design must reflect the practical and aesthetic in business but above all... good design must primarily serve people. Build beautiful websites in mere minutes.

Basic

Create email templates for yourself.

  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
$5 Per User Per Month

Enterprise

Create email templates for yourself.

  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
$10 Per User Per Month
advertise

Business

Create email templates for yourself.

  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
  • White Hat SEO
$19.99 Per User Per Month

Retina Ready

Build trust with prospective clients, delight existing customers, and increase the efficiency

Welcome to

Best website for Blog App. Business. Digital. Marketing. Service.

Even in the most uncertain times, Help Scout keeps you connected with customers.

Frequently asked questions

01. How can I download the app ?
Lorem ipsum dolor sit amet consectetur adipisicing elit. Dignissimos sequi placeat distinctio dolor, amet magnam voluptatibus eos ex vero, sunt veritatis esse. Nostrum voluptatum et repudiandae vel sed, explicabo in?
02. How can I install the app ?
Lorem ipsum dolor sit amet consectetur adipisicing elit. Dignissimos sequi placeat distinctio dolor, amet magnam voluptatibus eos ex vero, sunt veritatis esse. Nostrum voluptatum et repudiandae vel sed, explicabo in?
03. How can I upgrade my current plan ?
Lorem ipsum dolor sit amet consectetur adipisicing elit. Dignissimos sequi placeat distinctio dolor, amet magnam voluptatibus eos ex vero, sunt veritatis esse. Nostrum voluptatum et repudiandae vel sed, explicabo in?
04. How can I active the app's features ?
Lorem ipsum dolor sit amet consectetur adipisicing elit. Dignissimos sequi placeat distinctio dolor, amet magnam voluptatibus eos ex vero, sunt veritatis esse. Nostrum voluptatum et repudiandae vel sed, explicabo in?
05. How can I download the app ?
Lorem ipsum dolor sit amet consectetur adipisicing elit. Dignissimos sequi placeat distinctio dolor, amet magnam voluptatibus eos ex vero, sunt veritatis esse. Nostrum voluptatum et repudiandae vel sed, explicabo in?
06. How can I install the app ?
Lorem ipsum dolor sit amet consectetur adipisicing elit. Dignissimos sequi placeat distinctio dolor, amet magnam voluptatibus eos ex vero, sunt veritatis esse. Nostrum voluptatum et repudiandae vel sed, explicabo in?
07. How can I upgrade my current plan ?
Lorem ipsum dolor sit amet consectetur adipisicing elit. Dignissimos sequi placeat distinctio dolor, amet magnam voluptatibus eos ex vero, sunt veritatis esse. Nostrum voluptatum et repudiandae vel sed, explicabo in?
08. How can I active the app's features ?
Lorem ipsum dolor sit amet consectetur adipisicing elit. Dignissimos sequi placeat distinctio dolor, amet magnam voluptatibus eos ex vero, sunt veritatis esse. Nostrum voluptatum et repudiandae vel sed, explicabo in?

We tried to make

Integrations

Create stunning, effective sales documents with custom-designed theme & template.

Marketing

Create stunning, effective sales documents with custom-designed theme & template.

Dedicated Support

Create stunning, effective sales documents with custom-designed theme & template.

Best Features

Our features will help
to improve busines

Sales teams use PandaDoc to improve deal workflow, insights, and speed while delivering an amazing buying experience. Get your documents out the door fast to keep deals.

Rechercher dans ce blog

advertise
advertise
advertise

Built in Browsers

Build trust with prospective clients, delight existing customers, and increase the efficiency

Extreme Security

Build trust with prospective clients, delight existing customers, and increase the efficiency

Clean Design

Build trust with prospective clients, delight existing customers, and increase the efficiency

Easy Customize

Build trust with prospective clients, delight existing customers, and increase the efficiency

Awesome Design

Build trust with prospective clients, delight existing customers, and increase the efficiency