atmel:gpslcd

no way to compare when less than two revisions

Differences

This shows you the differences between two versions of the page.


atmel:gpslcd [2009/11/27 17:53] (current) – created - external edit 127.0.0.1
Line 1: Line 1:
 +======Introduction ======
  
 +{{ gpslcd.jpg }}
 +
 +This project details how to connect a [[http://www.garmin.com/|Garmin]] GPS unit to a Futurlec [[http://www.futurlec.com/ATDevBoard.shtml|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.
 +
 +[[GpsLcdSource|GPS LCD Source code]] as a {{gpslcd.zip|ZIP file}}
 +
 +=====What is needed=====
 +
 +^ Hardware ^ Description ^
 +| {{devbrd.gif}} | **Atmel AVR Microcontroller Development System**\\  This kit was kindly provided to me by the friendly people over at http://www.btinternet.com/~e2one/avrbrd/ |
 +| {{lcd1x16.jpg}} | **1x16 LCD Display** \\ Details of how to wire up a 1x16 display to the development board can be found at http://www.btinternet.com/~e2one/avrbrd/ (see the LCD Project). If you use a larger display then you will have to modifying the code to suit. |
 +| {{vistapic.gif}} | **GPS Unit** \\ I used an [[http://www.garmin.com/products/etrexVista/|eTrex Vista]] but any GPS unit that emits the NMEA protocol should be ok. |
 +| {{010-10206-00.gif}} | A GPS to RS232 breakout cable. |
 +| {{avr232cable.gif}} | **AVR board RS232 cable**\\ 4 Pin Molex wired to DB9-F\\ This cable should be supplied with the development board. |
 +| {{nullmodem.gif}} | **Null MODEM Adapter**\\ DB9-M to DB9-M\\ Wiring details for this adapter are given below |
 +
 +====The Software====
 +  * As the ATMEL AT90S2313 only has 2k of code space the demo version of [[http://www.mcselec.com/bascom-avr.htm|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 [[nmea#gprmc]]
 +<code>
 +$GPRTE,1,1,c,*37
 +$GPRMC,103044,A,5125.5210,N,00012.3645,W,0.0,304.9,290105,2.6,W,A*1E
 +$GPRMB,A,,,,,,,,,,,,A,A*0B
 +$GPGGA,103044,5125.5210,N,00012.3645,W,1,03,2.8,6.0,M,47.2,M,,*5E
 +$GPGSA,A,2,06,,,,,,21,,25,,,,2.9,2.8,1.0*31
 +$GPGSV,3,2,10,16,48,296,00,17,20,041,00,21,48,154,44,23,11,306,00*75
 +$GPGLL,5125.5210,N,00012.3645,W,103044,A,A*55
 +$GPBOD,,T,,M,,*47
 +$GPVTG,304.9,T,307.5,M,0.0,N,0.0,K*41
 +$PGRME,11.2,M,50.0,M,51.2,M*1F
 +$PGRMZ,-266,f*2B
 +$PGRMM,WGS 84*06
 +$HCHDG,200.1,,,2.6,W*3C
 +</code>
 +
 +======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
 +{{ db9_null_dumb.png }}
 +
 +^ Connector1 ^ Connector2 ^ Function ^
 +| 2 | 3 | Rx <- Tx |
 +| 3 | 2 | Tx -> Rx |
 +| 5 | 5 | Signal ground |
 +
 +{{tag>avr}}
  • atmel/gpslcd.txt
  • Last modified: 2009/11/27 17:53
  • by 127.0.0.1