Symbian3/PDK/Source/GUID-CCEAFF83-11E6-511D-9A3E-E5D986F4FCF8.dita
author Graeme Price <GRAEME.PRICE@NOKIA.COM>
Fri, 15 Oct 2010 14:32:18 +0100
changeset 15 307f4279f433
parent 9 59758314f811
permissions -rw-r--r--
Initial contribution of the Adaptation Documentation.

<?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 id="GUID-CCEAFF83-11E6-511D-9A3E-E5D986F4FCF8" xml:lang="en"><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 id="GUID-6B7BCA18-2C7B-405D-AAF5-6F2A9B6DE074"><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 id="GUID-5303CC1B-0A5D-4F0F-977E-7E9B31F48F20"><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 id="GUID-E16E33C1-6B45-4131-ABE7-ED6DCA0BFF7F"><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 href="http://www.nmea.org/content/nmea_standards/nmea_standards.asp" scope="external">The NMEA 0183 Protocol</xref>  </p> </li>
<li id="GUID-C33FA805-D195-57EA-93C4-D9D1E82D5C70"><p> <xref href="http://www.sirf.com/" scope="external">SiRF Binary Protocol
Reference Manual</xref>  </p> </li>
<li id="GUID-786BCAA8-399D-5B9D-8D37-3314F1318CE5"><p> <xref href="http://www.sirf.com/" scope="external">SiRF NMEA Reference Manual</xref>  </p> </li>
</ul> </section>
<section id="GUID-A9400274-9901-40F6-ACE0-090E8C19A56C"><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 id="GUID-AD39B01E-8806-4268-86A1-9AD05B3CBE91"><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>