Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of C027_Support by
Diff: GPS.cpp
- Revision:
- 24:0e287a85ac9e
- Parent:
- 21:c4d64830bf02
- Parent:
- 20:535ef78655df
- Child:
- 31:a0bed6c1e05d
diff -r 05a1aeeb5fd9 -r 0e287a85ac9e GPS.cpp --- a/GPS.cpp Tue Apr 08 11:11:20 2014 +0000 +++ b/GPS.cpp Tue Apr 08 11:15:33 2014 +0000 @@ -204,10 +204,9 @@ return false; } -bool GPSParser::getNmeaAngle(int ix, char* buf, int len, double& d) +bool GPSParser::getNmeaAngle(int ix, char* buf, int len, double& val) { char ch; - double val; if (getNmeaItem(ix,buf,len,val) && getNmeaItem(ix+1,buf,len,ch) && ((ch == 'S') || (ch == 'N') || (ch == 'E') || (ch == 'W'))) { @@ -216,7 +215,6 @@ val = (val - i) / 0.6 + i; if (ch == 'S' || ch == 'W') val = -val; - d = val; return true; } return false;