A DIY GPS navigator built using ESP32, uBlox Neo M8N GPS module, and an OLED display.
- Real-time GPS tracking
- Display of latitude and longitude
- Altitude measurement
- Current speed in km/h
- Number of satellites connected
- Time display in IST (UTC+5:30)
- Debug mode via Serial Monitor
- ESP32 Development Board
- uBlox Neo M8N GPS with Compass
- 128x64 0.96 Inch OLED Display Module (I2C Interface)
- Breadboard
- Jumper Wires
All components were sourced from robokits.co.in
You can build this project in different ways depending on your needs:
- For basic tracking: Use cheaper GPS modules
- For high accuracy: Use uBlox Neo M8N
- Current build ($22) offers a great balance of cost and accuracy
- Total cost can range from $15-100 depending on component selection
-
Gather Components
- Purchase all components listed above
- Make sure you have a good USB cable for ESP32
-
Hardware Assembly
- Connect GPS Module to ESP32:
- Red wire: VCC → 3.3V
- Black wire: GND → GND
- Yellow wire: TX → GPIO16 (RX2)
- Connect OLED Display to ESP32:
- VCC → 3.3V
- GND → GND
- SCL → GPIO22
- SDA → GPIO21
- Connect GPS Module to ESP32:
-
Software Setup
- Install Arduino IDE from arduino.cc
- Install ESP32 board support (Guide)
- Install required libraries through Arduino Library Manager:
- TinyGPS++
- Adafruit_GFX
- Adafruit_SSD1306
-
Upload Code
- Open esp32-gps-navigator.ino in Arduino IDE
- Select "ESP32 Dev Module" from Tools > Board menu
- Choose correct COM port
- Click Upload button
-
First Run
- Take the device outdoors for better GPS signal
- Wait for "GPS INIT..." message
- First fix might take 1-2 minutes
- Once connected, you'll see coordinates and other data
Sats:7 Speed:0.0
51.5074 <- Latitude
-0.1278 <- Longitude
ALT:35m 13:45 <- Altitude & Time(IST)
Common issues and solutions:
- No GPS fix: Make sure you're outdoors or near a window
- OLED not working: Check I2C connections and address
- No serial output: Verify correct baud rate (115200)
- GPS not responding: Double-check TX wire connection
- Implementing local map rendering for navigation
- Custom MapForge parser written in Rust (mapsforge-rs)
- This is a separate project to efficiently parse MapForge binary maps
- Written in Rust for better performance and memory safety
- Will be integrated with this GPS navigator for map rendering
- Custom renderer for OLED display
- This is a complex feature under development as it involves building several components from scratch
This project is part of a larger ecosystem:
- diy-gps: Current project for basic GPS functionality (this repo)
- mapsforge-rs: Rust-based MapForge parser (in development)
- Map renderer: Future component for navigation display
Possible enhancements you can try:
- Add map rendering for navigation (work in progress)
- Create a custom PCB design instead of using breadboard
- Add a battery for portable use
- Store coordinates in SD card
- Add a button to change display modes
- Connect to WiFi to log location
- Design a 3D printed case
- This is a basic version that can be enhanced based on your needs
- Component quality affects GPS accuracy and fix time
- Consider soldering components on a PCB for permanent use
- The code is modular and can be adapted for different displays or GPS modules
For developers:
- Set
debugMode = true
in code - Open Serial Monitor at 115200 baud
- View detailed GPS data stream
Feel free to fork this project and submit pull requests for any improvements.
MIT License
If you need help:
- Open an issue in GitHub
- Review open/closed issues
- Contact me: chetanbaliyan10@gmail.com
Note: This project is ideal for learning about GPS, ESP32, and I2C displays. Build responsibly!