IoT GAT: Global Asset Tracking System
The Problem
Tracking assets in the field — trucks, containers, agricultural equipment, construction machinery — requires a device that runs for years without maintenance. Commercial trackers either drain fast or cost too much per unit to deploy at scale. The client needed a custom GPS/GSM module that could survive a 2-year field deployment on a single battery charge.
What We Built
A compact GPS tracking module based on the STM32 microcontroller (ARM Cortex-M) and the SIM808 combined GPS+GSM module. The device records location via GNSS and transmits it to a cloud backend over GSM, GPRS, or USSD — whichever channel is available on the network. An ADXL345 accelerometer detects motion and wakes the device from deep sleep only when the asset moves, avoiding wasted transmissions when equipment is stationary.
The cloud backend ingests location events, stores the track history, and exposes it to a mobile app where operators monitor their assets in real time.
Power Architecture
Two operating modes:
Continuous mode — GPS fix every 30 seconds, immediate GSM transmission. Battery life: ~10 hours. For high-value assets during active transit where real-time position is critical.
Sleep mode — MCU in deep sleep, ADXL345 on interrupt watch. Device wakes on movement, acquires GPS fix, transmits, returns to sleep. Battery life: 2.2 years on a single 3.7V Li-Ion cell.
The 2.2-year figure was achieved through peripheral power gating, RTC-based sleep scheduling, and transmission batching: several location records are buffered locally and sent in one burst rather than one request per fix.
Technical Stack
- MCU: STM32 (STM32F103C8 Blue Pill board in the prototype firmware, Cortex-M3), later firmware on ATmega328
- GPS + GSM: SIM808 — combined GNSS receiver and quad-band GSM/GPRS modem
- Motion: ADXL345 three-axis accelerometer on interrupt line
- Transmission: GPRS (primary), USSD (fallback on networks without data)
- Cloud backend: REST API, time-series location storage, geofence alerting
- Mobile: iOS and Android app with live map, track history, and alert settings
Applications
Fleet management — logistics companies tracking trucks and vans across routes. Geofence alerts when a vehicle enters or exits a zone. Idle detection to flag unauthorized use.
Cold chain — containers and refrigerated units where remote monitoring eliminates manual check-ins at each stop.
Agricultural equipment — tractors and harvesters spread across large farms. The 2.2-year battery means no seasonal charging; hardware is installed and forgotten. For full-stack agritech platforms combining GPS tracking with crop monitoring and irrigation control, see our agritech software development practice.
Construction and rental equipment — high-theft-risk machinery tracked across job sites. Instant alert on movement outside working hours.
Result
Prototype hardware, firmware, cloud and mobile app. The tracker travelled from a SIM808 breadboard through a custom STM32 PCB and a 3D-printed enclosure to a documented design prepared for manufacturing. The device sends over USSD even on networks that throttle or block GPRS data, a requirement specific to certain emerging-market deployments. This is our own R&D line for animal and asset tracking; we report no deployment or fleet figures.
Engineering at a glance
- Three firmware lines, five repositories, 266 commits. STM32 on a Blue Pill board with SIM808 and TinyGSM, a separate A9G firmware on the Ai-Thinker C SDK (GPS, MQTT, USSD, SMS and power-management tasks), and an ATmega328 line that stayed in development until 2024-04.
- Modem and power parts compared before the final board. SIM868, SIM808 and A9G modems, then a prototype on SIM800 + L80-R GPS with a TPL5110 timer for ultra-low-power wake-up.
- Power gating. The ATmega328 board switches the GPS and GSM rails with separate MOSFETs. The STM32 firmware cuts modem power the same way between sends.
- GSM sleeps while GPS searches. The modem registers, sends pending alarms, then sleeps until the 2D/3D fix arrives. Registering on a cell tower is the most power-hungry step, so the firmware does it once per cycle.
- Wake source and recovery. ADXL345 activity and inactivity interrupts wake the MCU, an 8-second hardware watchdog guards sleep, and the settings and last program step live in EEPROM so the device resumes after a reset. Armed and disarmed modes use separate send intervals.
- Four uplinks. MQTT, USSD through an Emnify gateway, SMS and HTTP POST. We timed USSD delivery against 3G with MQTT.
- Backend and app. NestJS 7 with TypeORM, MySQL, Socket.IO and Swagger (105 commits); React Native 0.63 app with a map view (93 commits).
- Effort. About 712 engineering hours between 2019-12 and 2022-07. Battery capacity was sized for 6 and 12 months at one ping a day, and consumption was measured in several scenarios (about 63 engineering hours).
Need a low-power GPS/GSM device? Our IoT engineering team covers modem selection, PCB, firmware, cloud backend and mobile app. Tell us about your project.