This project details how to connect a Garmin GPS unit to a Futurlec AT90S2313 development board and decode the NMEA protocol onto an LCD display. The LCD display will cycle through the following information; Longitude, Latitude and the current date/time, holding each one for 2 seconds.

GPS LCD Source code as a ZIP file

Hardware Description
Atmel AVR Microcontroller Development System
This kit was kindly provided to me by the friendly people over at
lcd1x16.jpg 1×16 LCD Display
Details of how to wire up a 1×16 display to the development board can be found at (see the LCD Project). If you use a larger display then you will have to modifying the code to suit.
GPS Unit
I used an eTrex Vista but any GPS unit that emits the NMEA protocol should be ok.
A GPS to RS232 breakout cable.
AVR board RS232 cable
4 Pin Molex wired to DB9-F
This cable should be supplied with the development board.
Null MODEM Adapter
DB9-M to DB9-M
Wiring details for this adapter are given below
  • As the ATMEL AT90S2313 only has 2k of code space the demo version of BASCOM can be used without hitting any of it's restrictions.
  • Hyperterminal or any suitable terminal emulation package. Useful for making sure that your GPS unit is tranmitted data.

GPS to Computer

First we make sure that your GPS unit is transmitted NMEA data.

  • Connect the GPS-RS232 cable to your GPS unit
  • Plug the cable into your computer
  • Fire up your terminal emulator and configure to 4800 baud, 8 data bits, No parity, 1 stop bit. 4800-N81

You should see a stream of communication beginning with the $ sign. The one that we are interested in is gprmc

$PGRMM,WGS 84*06

GPS to AVR board

The RS232 cable that comes with AVR development board is wired as a DTE, as the GPS unit is also a DTE we need an adapter.

You need to purchase or make a short cable to join the two, this is sometimes called a NULL modem cable and simply swaps pins 2 and 3 over.

Below is a wiring diagram for the 9 pin connectors

Connector1 Connector2 Function
2 3 Rx ← Tx
3 2 Tx → Rx
5 5 Signal ground
  • atmel/gpslcd.txt
  • Last modified: 2009/11/27 17:53
  • by