mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-29 14:52:12 +01:00
OP-25 Flight/GPS: Heading and GroundSpeed used, speed in knots?
git-svn-id: svn://svn.openpilot.org/OpenPilot/trunk@687 ebee16cc-31ac-478f-84a7-5cbb03baadba
This commit is contained in:
parent
c2a30176de
commit
4f4391708e
@ -511,10 +511,16 @@ void nmeaProcessGPRMC(char* packet)
|
||||
// next field: speed (knots)
|
||||
// get speed in knots
|
||||
tokens = strsep(&packet, delimiter);
|
||||
deg=strtol (tokens,&pEnd,10);
|
||||
desim=strtol (pEnd+1,NULL,10);
|
||||
GpsData.GroundSpeed = deg+(desim/100.0); //OPGPS style
|
||||
|
||||
// next field: True course
|
||||
// get True course
|
||||
tokens = strsep(&packet, delimiter);
|
||||
deg=strtol (tokens,&pEnd,10);
|
||||
desim=strtol (pEnd+1,NULL,10);
|
||||
GpsData.Heading = deg+(desim/100.0); //OPGPS style
|
||||
|
||||
// next field: Date of fix
|
||||
// get Date of fix
|
||||
|
Loading…
x
Reference in New Issue
Block a user