Saturday, January 28, 2023

GPS Location-Based Alarm

Ashwini Kumar Sinha

- Advertisement -

Have you ever gone out to run errands and ended up forgetting any major ones? 

Many times we create a list for shopping or plan to do something like shopping and any other work that depends on the location but we sometimes forget in such situations we wish to have a device that gives us an alarm based on location. and alerts whenever when we want to plan task based on location like if we plan to buy medicine from the medical shop while returning from the office we might forget so whenever we reach near the medical shop out device alert and gives us alarm to buy medicine so in a similar way it alerts us and give alarm whenever we reach our location like a restaurant, bookshop, mall, medical store and alert as our need to buy stuff and let us remember wor we have planned based on that location or we can use this device as an assistive device like we can fix it on kids bag or patients or visually challenged person that gives them alert when they reach the bus stop, or near a park or home, working place, etc. So let’s start designing this GPS-based alert system with the shopping of the following components

Fig1. GPS location-based device

Bill Of Material

- Advertisement -

Note:- In case the ESP12 chip is being used, a programmer or FTDI USB converter is needed. If the dev board is being used, programming can be done directly on the board.


The ESP board has to be installed and configured in the Arduino IDE. The Ting GPS library has to be installed for coding. AIR 530 uses GPS module to send data via serial communication. Any free pin of the ESP 12F chip can be used for software. Here the 4th and 5th pins are used as a receiver and transmitter for the serial port. The baud rate is set to 9600 as per AIR 530.

Since the setup function is created, next comes the loop function. After extracting data from the GPS, the latitude and longitude are set to the location of the place. Using the ‘if’ condition, the distance from our current location to destination is calculated. If the distance is less than 200m, the digital pin is marked ‘high’, alerting us using a vibration motor or a buzzer. Hence when we are close to the grocery store or any specific place needed, the alert helps us remember our tasks.

Fig 3.
Fig 4.


The code is uploaded to the ESP CHIP using FTDI or Programmer. Connecting GPIO 0, the chip enters the programming mode.

The GPS, ESP chip and battery are connected as seen in figure 5. The components are placed in the enclosure. The enclosure can be any 3D design, one is shown in Fig  6.


Fig 5.

Fig 6. Enclosure design


Fig 7.
Fig 8

The device is powered with a 3.3V battery. It connects to the GPS after a few minutes. Once fixed and the satellite gets your current location. As you move around, you would notice the buzzer ring when your location is within 200m of the desired location. In this manner you could programme your desired location in the code and use the device to alert you when you run errands. Note that the number of desired locations is not restricted to 1, in this project.

Download Code



What's New @

Truly Innovative Tech

MOst Popular Videos

Electronics Components

Tech Contests