Arduino GPS Trip Meter

Hi, I have an arduino and a gy-gps6mv2 GPS.
I want to buils a speedometer and trip meter that I can reset when I refil the fuel tank.

I am guessing for the trip meter. I would have to run a calculation often so to get an accurate distance traveled. As I dont want the distance from a start poit to an end point, I need the actual distance traveled on the road.

Any advice and / or tutorial?

Thanks,

Hi,
Welcome to the forum.

Please read the first post in any forum entitled how to use this forum.
http://forum.arduino.cc/index.php/topic,148850.0.html

Yes it is feasable.
What Arduino have you got?
What display will you be using?

Can you tell us your electronics, programming, Arduino, hardware experience?

Thanks.. Tom,, :slight_smile:

Hi, I hope to use

Nano V3.0 USB ATMEGA328P CH340G 5V 16M Micro-Controller Board For Arduino

IIC/I2C/TWI/SP​​I Serial Interface Blue 1602 16X2 LCD Display Module For Arduino

GPS as mention previously

Code with out display so far

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

SoftwareSerial serial_connection(10, 11); //RX=pin 10, TX=pin 11
TinyGPSPlus gps;//This is the GPS object that will pretty much do all the grunt work with the NMEA data
void setup()
{
Serial.begin(9600);//This opens up communications to the Serial monitor in the Arduino IDE
serial_connection.begin(9600);//This opens up communications to the GPS
Serial.println(“GPS Start”);//Just show to the monitor that the sketch has started
}

void loop()
{
while(serial_connection.available())//While there are characters to come from the GPS
{
gps.encode(serial_connection.read());//This feeds the serial NMEA data into the library one char at a time
}
if(gps.location.isUpdated())//This will pretty much be fired all the time anyway but will at least reduce it to only after a package of NMEA data comes in
{
//Get the latest info from the gps object which it derived from the data sent by the GPS unit
Serial.println(“Satellite Count:”);
Serial.println(gps.satellites.value());
Serial.println(“Latitude:”);
Serial.println(gps.location.lat(), 6);
Serial.println(“Longitude:”);
Serial.println(gps.location.lng(), 6);
Serial.println(“Speed MPH:”);
Serial.println(gps.speed.mph());
Serial.println(“Altitude Feet:”);
Serial.println(gps.altitude.feet());
Serial.println("");
}
}

Thanks, :slight_smile:

Hi,
Good, hope you are getting valid readings.

Now you need to put that code aside and write code JUST for the display, get it working and displaying characters.

Then work towards combining the two.

You will need to get, if you already haven't, the library for your LCD display.
It should have examples of how you control the display.

Tom... :slight_smile:

Arduino71:
Any advice and / or tutorial?

Sure! Here are some speedometer projects that use my NeoGPS library:

GPS Nixie Speedometer
Gps speedometer
GPS Speedometer, problems when still
[GPS Speedometer] Slow display updates on Mode 3 Fix.
Adafruit Ultimate GPS, SSD1306 0.96" 128x64 OLED (Lengthy! Mostly timezone work after that post.)
GPS 7 Segment Speedometer

Here is a project that includes the odometer function ("trip meter"):

Vehicle Tracking System

NeoGPS is smaller, faster, more accurate and more reliable than all other GPS libraries. If you'd like to try it, NeoGPS is available from the Ardino IDE Library Manager, under the menu Sketch -> Include Library -> Manage Libraries.

Pay special attention to Choosing Your Serial Port connection and the required level-shifting for safely connecting the 3.3V NEO-6M to your 5V Arduino.

Cheers,
/dev

Is anybody willing to give me some step by step info please, because I’m an absolute Newby. I want to use an Adafruit Ultimate 3 GPS unit… With an Arduino Uno to create a GPS trip meter. With a screen to display km 999.99 and speed in KPH also real time. Thanks in Advance

How much code have you written so far and can we see it ?

Hi,
Welcome to the forum.

Please read the post at the start of any forum , entitled “How to use this Forum”.
OR

Have you looked at the tutorial on the Adafruit site.

Can you please tell us your electronics, programming, arduino, hardware experience?

Thanks… Tom… :+1: :coffee: :australia:

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.