详解NMEA数据格式

 NMEA是"National Marine Electronics Association"(国际海洋电子协会)缩写,同时也是数据传输标准工业协会,在这里,实际上应为NMEA 0183。它是一套定义接收机输出的标准信息,有几种不同的格式,每种都是独立相关的ASCII格式,逗点隔开数据流,数据流长度从30-100字符不等,通常以每秒间隔选择输出,最常用的格式为"GGA",它包含了定位时间,纬度,经度,高度,定位所用的卫星数,DOP值,差分状态和校正时段等,其他的有速度,跟踪,日期等。NMEA实际上已成为所有的GPS接收机和最通用的数据输出格式,同时它也被用于与GPS接收机接口的大多数的软件包里。

NMEA数据如下: $GPGGA,121252.000,3937.3032,N,11611.6046,E,1,05,2.0,45.9,M,-5.7,M,,0000*77 $GPRMC,121252.000,A,3958.3032,N,11629.6046,E,15.15,359.95,070306,,,A*54 $GPVTG,359.95,T,,M,15.15,N,28.0,K,A*04 $GPGGA,121253.000,3937.3090,N,11611.6057,E,1,06,1.2,44.6,M,-5.7,M,,0000*72 $GPGSA,A,3,14,15,05,22,18,26,,,,,,,2.1,1.2,1.7*3D $GPGSV,3,1,10,18,84,067,23,09,67,067,27,22,49,312,28,15,47,231,30*70 $GPGSV,3,2,10,21,32,199,23,14,25,272,24,05,21,140,32,26,14,070,20*7E $GPGSV,3,3,10,29,07,074,,30,07,163,28*7D $GPGGA,032648.00,2307.595860,N,11321.993373,E,1,09,0.9,30.7,M,-5.2,M,,*4C

$PSAT,HPR,032714.00,74.19,-23.16,,N*1F

说明:NMEA0183格式以“$”开始,常用语句有GPGGA,GPVTG,GPZDA等

1、 GPS DOP and Active Satellites(GSA)当前卫星信息

$GPGSA,<1>,<2>,<3>,<3>,,,,,<3>,<3>,<3>,<4>,<5>,<6>,<7>

<1>模式 :M = 手动, A = 自动。 <2>定位型式 1 = 未定位, 2 = 二维定位, 3 = 三维定位。 <3>PRN 数字:01 至 32 表天空使用中的卫星编号,最多可接收12颗卫星信息。 <4> PDOP位置精度因子(0.5~99.9) <5> HDOP水平精度因子(0.5~99.9) <6> VDOP垂直精度因子(0.5~99.9) <7> Checksum.(检查位).

2、 GPS Satellites in View(GSV)可见卫星信息 $GPGSV, <1>,<2>,<3>,<4>,<5>,<6>,<7>,?<4>,<5>,<6>,<7>,<8>

<1> GSV语句的总数 <2> 本句GSV的编号 <3> 可见卫星的总数,00 至 12。 <4> 卫星编号, 01 至 32。 <5>卫星仰角, 00 至 90 度。 <6>卫星方位角, 000 至 359 度。实际值。 <7>讯号噪声比(C/No), 00 至 99 dB;无表未接收到讯号。 <8>Checksum.(检查位).

第<4>,<5>,<6>,<7>项个别卫星会重复出现,每行最多有四颗卫星。其余卫星信息会于次一行出现,若未使用,这些字段会空白。

3、Global Positioning System Fix Data(GGA)GPS定位信息

$GPGGA,<1>,<2>,<3>,<4>,<5>,<6>,<7>,<8>,<9>,M,<10>,M,<11>,<12>*hh

<1> UTC时间,hhmmss(时分秒)格式 <2> 纬度ddmm.mmmm(度分)格式(前面的0也将被传输) <3> 纬度半球N(北半球)或S(南半球) <4> 经度dddmm.mmmm(度分)格式(前面的0也将被传输) <5> 经度半球E(东经)或W(西经) <6> GPS状态:0=未定位,1=非差分定位,2=差分定位,6=正在估算 <7> 正在使用解算位置的卫星数量(00~12)(前面的0也将被传输) <8> HDOP水平精度因子(0.5~99.9) <9> 海拔高度(-9999.9~99999.9) <10> 地球椭球面相对大地水准面的高度 <11> 差分时间(从最近一次接收到差分信号开始的秒数,如果不是差分定位将为空) <12> 差分站ID号0000~1023(前面的0也将被传输,如果不是差分定位将为空)

4、Recommended Minimum Specific GPS/TRANSIT Data(RMC)推荐定位信息

$GPRMC,<1>,<2>,<3>,<4>,<5>,<6>,<7>,<8>,<9>,<10>,<11>,<12>*hh

<1> UTC时间,hhmmss(时分秒)格式 <2> 定位状态,A=有效定位,V=无效定位 <3> 纬度ddmm.mmmm(度分)格式(前面的0也将被传输) <4> 纬度半球N(北半球)或S(南半球) <5> 经度dddmm.mmmm(度分)格式(前面的0也将被传输) <6> 经度半球E(东经)或W(西经) <7> 地面速率(000.0~999.9节,前面的0也将被传输) <8> 地面航向(000.0~359.9度,以真北为参考基准,前面的0也将被传输) <9> UTC日期,ddmmyy(日月年)格式 <10> 磁偏角(000.0~180.0度,前面的0也将被传输) <11> 磁偏角方向,E(东)或W(西) <12> 模式指示(仅NMEA0183 3.00版本输出,A=自主定位,D=差分,E=估算,N=数据无效)

5、 Track Made Good and Ground Speed(VTG)地面速度信息 $GPVTG,<1>,T,<2>,M,<3>,N,<4>,K,<5>*hh <1> 以真北为参考基准的地面航向(000~359度,前面的0也将被传输) <2> 以磁北为参考基准的地面航向(000~359度,前面的0也将被传输) <3> 地面速率(000.0~999.9节,前面的0也将被传输) <4> 地面速率(0000.0~1851.8公里/小时,前面的0也将被传输) <5> 模式指示(仅NMEA0183 3.00版本输出,A=自主定位,D=差分,E=估算,N=数据无效)

 

以下是英文手册摘要

-------------------------------------------------------------------------------------- $GPGST GPS Pseudorange Noise Statistics

Example: $GPGST,024603.00,3.2,6.6,4.7,47.3,5.8,5.6,22.0*58

Field  Example Comments  Sentence ID $GPGST   UTC Time 024603.00 UTC time of associated GGA fix RMS deviation 3.2 Total RMS standard deviation of ranges inputs to the navigation solution Semi-major deviation 6.6 Standard deviation (meters) of semi-major axis of error ellipse Semi-minor deviation 4.7 Standard deviation (meters) of semi-minor axis of error ellipse Semi-major orientation 47.3 Orientation of semi-major axis of error ellipse (true north degrees) Latitude error deviation 5.8 Standard deviation (meters) of latitude error Longitude error deviation 5.6 Standard deviation (meters) of longitude error Altitude error deviation 22.0 Standard deviation (meters) of latitude error Checksum *58  

 

--------------------------------------------------------------------------------

$GPGSV GPS Satellites in view

eg. $GPGSV,3,1,11,03,03,111,00,04,15,270,00,06,01,010,00,13,06,292,00*74     $GPGSV,3,2,11,14,25,170,00,16,57,208,39,18,67,296,40,19,40,246,00*74     $GPGSV,3,3,11,22,42,067,42,24,14,311,43,27,05,244,00,,,,*4D

    $GPGSV,1,1,13,02,02,213,,03,-3,000,,11,00,121,,14,13,172,05*62

1    = Total number of messages of this type in this cycle 2    = Message number 3    = Total number of SVs in view 4    = SV PRN number 5    = Elevation in degrees, 90 maximum 6    = Azimuth, degrees from true north, 000 to 359 7    = SNR, 00-99 dB (null when not tracking) 8-11 = Information about second SV, same as field 4-7 12-15= Information about third SV, same as field 4-7 16-19= Information about fourth SV, same as field 4-7

--------------------------------------------------------------------------------

$GPHDT Heading, True.

Actual vessel heading in degrees Ture produced by any device or system producing true heading.

$--HDT,x.x,T x.x = Heading, degrees True

--------------------------------------------------------------------------------

$GPMSK Control for a Beacon Receiver

  $GPMSK,318.0,A,100,M,2*45

where:        318.0      Frequency to use        A          Frequency mode, A=auto, M=manual        100        Beacon bit rate        M          Bitrate, A=auto, M=manual        2          frequency for MSS message status (null for no status)        *45        checksum

--------------------------------------------------------------------------------

$GPMSS Beacon Receiver Status

Example 1: $GPMSS,55,27,318.0,100,*66

where:        55         signal strength in dB        27         signal to noise ratio in dB        318.0      Beacon Frequency in KHz        100        Beacon bitrate in bps        *66        checksum Example 2: $GPMSS,0.0,0.0,0.0,25,2*6D

Field Example Comments Sentence ID $GPMSS   Signal strength 0.0 Signal strength (dB 1uV) SNR 0.0 Signal to noise ratio (dB) Frequency 0.0 Beacon frequency (kHz) Data rate 25 Beacon data rate (BPS) Unknown field 2 Unknown field sent by GPS receiver used for test Checksum *6D  

 

--------------------------------------------------------------------------------

$GPR00 List of waypoint IDs in currently active route

eg1. $GPR00,EGLL,EGLM,EGTB,EGUB,EGTK,MBOT,EGTB,,,,,,,*58 eg2. $GPR00,MINST,CHATN,CHAT1,CHATW,CHATM,CHATE,003,004,005,006,007,,,*05

List of waypoints. This alternates with $GPWPL cycle which itself cycles waypoints.

--------------------------------------------------------------------------------

$GPRMA Recommended minimum specific Loran-C data

eg. $GPRMA,A,lll,N,lll,W,x,y,ss.s,ccc,vv.v,W*hh A    = Data status lll  = Latitude N    = N/S lll  = longitude S    = W/E x    = not used y    = not used ss.s = Speed over ground in knots ccc  = Course over ground vv.v = Variation W    = Direction of variation E/W hh   = Checksum

--------------------------------------------------------------------------------

$GPRMB Recommended minimum navigation information (sent by nav. receiver when a destination waypoint is active)

eg1. $GPRMB,A,0.66,L,003,004,4917.24,N,12309.57,W,001.3,052.5,000.5,V*0B

           A            Data status A = OK, V = warning            0.66,L       Cross-track error (nautical miles, 9.9 max.),                                 steer Left to correct (or R = right)            003          Origin waypoint ID            004          Destination waypoint ID            4917.24,N    Destination waypoint latitude 49 deg. 17.24 min. N            12309.57,W   Destination waypoint longitude 123 deg. 09.57 min. W            001.3        Range to destination, nautical miles            052.5        True bearing to destination            000.5        Velocity towards destination, knots            V            Arrival alarm  A = arrived, V = not arrived            *0B          mandatory checksum

eg2. $GPRMB,A,4.08,L,EGLL,EGLM,5130.02,N,00046.34,W,004.6,213.9,122.9,A*3D             1   2  3   4    5    6     7   8      9   10    11    12   13         1    A         validity       2    4.08      off track       3    L         Steer Left (L/R)       4    EGLL      last waypoint       5    EGLM      next waypoint       6    5130.02   Latitude of Next waypoint       7    N         North/South       8    00046.34  Longitude of next waypoint       9    W         East/West       10   004.6     Range       11   213.9     bearing to waypt.       12   122.9     closing velocity       13   A         validity       14   *3D       checksum

eg3. $GPRMB,A,x.x,a,c--c,d--d,llll.ll,e,yyyyy.yy,f,g.g,h.h,i.i,j*kk 1    = Data Status (V=navigation receiver warning) 2    = Crosstrack error in nautical miles 3    = Direction to steer (L or R) to correct error 4    = Origin waypoint ID# 5    = Destination waypoint ID# 6    = Destination waypoint latitude 7    = N or S 8    = Destination waypoint longitude 9    = E or W 10   = Range to destination in nautical miles 11   = Bearing to destination, degrees True 12   = Destination closing velocity in knots 13   = Arrival status; (A=entered or perpendicular passed) 14   = Checksum

--------------------------------------------------------------------------------

$GPRMC Recommended minimum specific GPS/Transit data

eg1. $GPRMC,081836,A,3751.65,S,14507.36,E,000.0,360.0,130998,011.3,E*62 eg2. $GPRMC,225446,A,4916.45,N,12311.12,W,000.5,054.7,191194,020.3,E*68

           225446       Time of fix 22:54:46 UTC            A            Navigation receiver warning A = Valid position, V = Warning            4916.45,N    Latitude 49 deg. 16.45 min. North            12311.12,W   Longitude 123 deg. 11.12 min. West            000.5        Speed over ground, Knots            054.7        Course Made Good, degrees true            191194       UTC Date of fix, 19 November 1994            020.3,E      Magnetic variation, 20.3 deg. East            *68          mandatory checksum

eg3. $GPRMC,220516,A,5133.82,N,00042.24,W,173.8,231.8,130694,004.2,W*70               1    2    3    4    5     6    7    8      9     10  11 12

      1   220516     Time Stamp       2   A          validity - A-ok, V-invalid       3   5133.82    current Latitude       4   N          North/South       5   00042.24   current Longitude       6   W          East/West       7   173.8      Speed in knots       8   231.8      True course       9   130694     Date Stamp       10  004.2      Variation       11  W          East/West       12  *70        checksum

eg4. for NMEA 0183 version 3.00 active the Mode indicator field is added      $GPRMC,hhmmss.ss,A,llll.ll,a,yyyyy.yy,a,x.x,x.x,ddmmyy,x.x,a,m*hh Field # 1    = UTC time of fix 2    = Data status (A=Valid position, V=navigation receiver warning) 3    = Latitude of fix 4    = N or S of longitude 5    = Longitude of fix 6    = E or W of longitude 7    = Speed over ground in knots 8    = Track made good in degrees True 9    = UTC date of fix 10   = Magnetic variation degrees (Easterly var. subtracts from true course) 11   = E or W of magnetic variation 12   = Mode indicator, (A=Autonomous, D=Differential, E=Estimated, N=Data not valid) 13   = Checksum

--------------------------------------------------------------------------------

$GPRTE Routes

eg. $GPRTE,2,1,c,0,PBRCPK,PBRTO,PTELGR,PPLAND,PYAMBU,PPFAIR,PWARRN,PMORTL,PLISMR*73     $GPRTE,2,2,c,0,PCRESY,GRYRIE,GCORIO,GWERR,GWESTG,7FED*34            1 2 3 4 5 .. Number of sentences in sequence Sentence number ''''c'''' = Current active route, ''''w'''' = waypoint list starts with destination waypoint Name or number of the active route onwards, Names of waypoints in Route

--------------------------------------------------------------------------------

$GPTRF Transit Fix Data

Time, date, position, and information related to a TRANSIT Fix.

$--TRF,hhmmss.ss,xxxxxx,llll.ll,a,yyyyy.yy,a,x.x,x.x,x.x,x.x,xxx hhmmss.ss = UTC of position fix xxxxxx = Date: dd/mm/yy llll.ll,a = Latitude of position fix, N/S yyyyy.yy,a = Longitude of position fix, E/W x.x = Elevation angle x.x = Number of iterations x.x = Number of Doppler intervals x.x = Update distance, nautical miles x.x = Satellite ID

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值