Close
0%
0%

UART - Retrieve GPS Position

Using Adafruit Ultimate GPS Breakout to retrieve GPS Position

Similar projects worth following
50 views
0 followers
In this example, we use Adafruit Ultimate GPS Breakout. Its data format is pure text, so we can connect it to USB to TTL Adapter and observe.

It follows the NMEA sentence format (refer to http://aprs.gids.nl/nmea/)The GPS signal is weak in indoor environment. The status that the GPS signal is not received is called “not fix”. Bring the GPS module outdoors, when the GPS signal is “fix”, you would get message similar to the figure below.

3

In this example we are only interested in the “$GPRMC (Global Positioning Recommended Minimum Coordinates)”:
$GPRMC,032122.000,A,2446.8181,N,12059.7251,E,0.39,78.89,270116,,,A*53
Each field is separated by a comma.

    • First field is the GMT time (Greenwich Mean Time), that is 032122.000 in this example. The time format is HH:MM:SS.SSS, i.e., 03:21:22.000. Note that the time zone and the daylight-saving time adjustment should be handled on your own.
    • Second field represents the status code
      • V: Void (Invalid)
      • A: Active, meaning the GPS signal is fix.
    • The third to sixth fields represent the geolocation

In this example, 2446.8181,N represents 24 degrees 46.8181 minutes north latitude, and 12059.7251,E represents 120 degrees 59.7251 minutes east longitude.

We can search +24 46.8181’, +120 59.7251’ in Google map to check whether the position is correct.

4

  • The seventh field is relative speed(knot). 1 knot = 1.852km/hr, in this example the relative speed is 0.39 knot.
  • The eighth field is the moving angle, which is calculated by its moving orbit.
  • The ninth field is the date with format ddMMyy. In this example, “270116” stands for day 27, January, year 2016.
  • The last field is checksum. In the example we have *53 as checksum.

  • 1 × AmebaD [ AMB23 / AMB21 / AMB22 / BW16 / AW-CU488 Thing Plus ]
  • 1 × Adafruit Ultimate GPS Breakout

  • 1
    Wiring Diagram

    AMB21/ AMB22:5AMB23:

    5BW16:

    5BW16 TypeC:

    5AW-CU488 Thing Plus:

    5

  • 2
    Open Example on Arduino IDE

    Open the example in “Files” -> “Examples” -> “AmebaSoftwareSerial” -> “Adafruit_GPS_parsing”.

  • 3
    Run example

    Compile and upload to Ameba, then press the reset button.
    The result will be output to Serial Monitor:

    67

View all 3 instructions

Enjoy this project?

Share

Discussions

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates