Symbian3/PDK/Source/GUID-CCEAFF83-11E6-511D-9A3E-E5D986F4FCF8.dita
author Dominic Pinkman <Dominic.Pinkman@Nokia.com>
Fri, 22 Jan 2010 18:26:19 +0000
changeset 1 25a17d01db0c
child 3 46218c8b8afa
permissions -rw-r--r--
Addition of the PDK content and example code for Documentation_content according to Feature bug 1607 and bug 1608

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
<!-- This component and the accompanying materials are made available under the terms of the License 
"Eclipse Public License v1.0" which accompanies this distribution, 
and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
<!-- Initial Contributors:
    Nokia Corporation - initial contribution.
Contributors: 
-->
<!DOCTYPE reference
  PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
<reference xml:lang="en" id="GUID-CCEAFF83-11E6-511D-9A3E-E5D986F4FCF8"><title> NMEA Messages</title><shortdesc>This document describes the NMEA messages supported by the Bluetooth GPS PSY. </shortdesc><prolog><metadata><keywords/></metadata></prolog><refbody><section><p>The target audiences for this document are device creators and GPS hardware vendors who want to know which NMEA messages are sent from the PSY to a GPS device and which messages the PSY expects to receive from the device. </p> </section> <section><title>Introduction</title> <p>The Bluetooth GPS PSY communicates with a GPS device using the NMEA 0183 protocol. </p> <p>The messages used for communication between the PSY and a GPS device are listed in the following sections. </p> <p>Note: The SiRF NMEA messages (those beginning with <codeph>$PSRF</codeph>) are not sent when a GPS device reports that it supports PNOK extensions. Positioning and power management messages for PNOK compatible GPS devices are described in <xref href="GUID-B143DF73-98F6-5491-8328-F5E12AE493A0.dita">PNOK messages</xref>. </p> </section> <section><title>Required background</title> <p>Familiarity with the following is helpful in understanding this document: </p> <ul><li id="GUID-F41B3CC6-67D9-59D8-9027-1F0DE6067899"><p> <xref scope="external" href="http://www.nmea.org/content/nmea_standards/nmea_standards.asp">The NMEA 0183 Protocol</xref>  </p> </li> <li id="GUID-C33FA805-D195-57EA-93C4-D9D1E82D5C70"><p> <xref scope="external" href="www.sirf.com">SiRF Binary Protocol Reference Manual</xref>  </p> </li> <li id="GUID-786BCAA8-399D-5B9D-8D37-3314F1318CE5"><p> <xref scope="external" href="www.sirf.com">SiRF NMEA Reference Manual</xref>  </p> </li> </ul> </section> <section><title>GPS initialisation messages</title> <p>The PSY sends initialisation messages to the GPS device in order to: </p> <ul><li id="GUID-F842CA2B-7B7E-5980-BF6E-D542409A8771"><p>Set the device to NMEA mode (to return messages defined by NMEA 0183). </p> </li> <li id="GUID-54F71FA5-D896-58AA-B4D6-B9F8BE9485D7"><p>Initialise the device's power mode. </p> </li> <li id="GUID-87108C5F-7785-547F-99FB-24CDB26B71C7"><p>Specify which NMEA messages to return, and their rate of return. </p> </li> </ul> <p><b>Setting NMEA mode</b> </p> <p>The PSY sends an SiRF binary protocol initialisation message to switch the GPS device to NMEA mode. The message is "Switch To NMEA Protocol – Message ID 129" (<codeph>0x81</codeph> hexadecimal). This message switches a serial port from binary to NMEA protocol and sets message output rates and bit rate on the port. </p> <p>The message is: <codeph>\xA0\xA2\x00\x18\x81\x02\x01\x01\x00\x01\x05\x01\x05\x01\x00\x01\x00\x01\x00\x01\x00\x01\x00\x01\x00\x01\x12\xC0\x01\x6A\xB0\xB3\r\n</codeph>. </p> <p><b>Requesting NMEA messages</b> </p> <p>The PSY sends SiRF NMEA messages "103—Query/Rate Control" to specify which NMEA messages the device must return and the rate at which to return them. </p> <p>The NMEA messages <codeph>GPGGA</codeph>, <codeph>GPRMC</codeph>, <codeph>GPGSV</codeph> and <codeph>GPGSA</codeph> are required with an update interval of one second. </p> <p>The PSY sends <codeph>$PSRF103</codeph> messages to the GPS device as a concatenated message list. The following table contains the details of the messages sent from the PSY to the GPS device. </p> <table id="GUID-722D5AA5-4C24-59DD-A875-105D4798A20A"><tgroup cols="3"><colspec colname="col0"/><colspec colname="col1"/><colspec colname="col2"/><thead><row><entry>Sent Messages</entry> <entry>Meaning</entry> <entry>Notes</entry> </row> </thead> <tbody><row><entry><p> <codeph> $PSRF103,0,0,1,1*25\r\n</codeph>  </p> </entry> <entry><p>Sets the device to return GGA messages with an interval of 1 second. </p> </entry> <entry><p>Message GGA returns time, position fix and fix type data. </p> </entry> </row> <row><entry><p> <codeph>$PSRF103,2,0,1,1*27\r\n</codeph>  </p> </entry> <entry><p>Sets the device to return GSA messages with an interval of 1 second. </p> </entry> <entry><p>Message GSA returns GPS receiver operating mode, information about the satellites used to obtain the position fix, and Dilution of Position (DOP) data. </p> </entry> </row> <row><entry><p> <codeph>$PSRF103,3,0,1,1*26\r\n</codeph>  </p> </entry> <entry><p>Sets the device to return GSV messages with an interval of 1 second. </p> </entry> <entry><p>Message GSV returns the number of GPS satellites in view, satellite ID numbers, elevation, azimuth and Signal to Noise Ratio (SNR) data. </p> </entry> </row> <row><entry><p> <codeph> $PSRF103,4,0,1,1*21\r\n</codeph>  </p> </entry> <entry><p>Sets the device to return RMC messages with an interval of 1 second. </p> </entry> <entry><p>Message RMC returns time, date, position, course and speed data. </p> </entry> </row> </tbody> </tgroup> </table> <p>The concatenated message list that is sent to the device is: <codeph>$PSRF103,0,0,1,1*25\r\n$PSRF103,2,0,1,1*27\r\n\
             $PSRF103,3,0,1,1*26\r\n$PSRF103,4,0,1,1*21\r\n</codeph>. </p> <p><b>Controlling device power mode</b> </p> <p>The PSY sends a full power mode message (see below) when it initialises the GPS device. </p> </section> <section><title>Full power mode message</title> <p>The PSY sends $PSRF107 messages with the parameters to switch the device to full power mode when required. This message turns off device trickle power mode if this is the current power state of the GPS device. </p> <p>The message sent is: <codeph>$PSRF107,0,1000,1000*3d\r\n</codeph>. </p> </section> </refbody></reference>