mirror of
https://github.com/S3NEO/android_device_samsung_msm8226-common.git
synced 2024-11-06 21:55:45 +00:00
msm8226-common: gps: Sub milli sec part in the relevant NMEA Strings
NMEA Strings should introduce the sub milli sec part in the relevant NMEA Strings for NHZ Sessions Change-Id: I9bac4caa26e87741e5e82e16a8047af20ac8012b CRs-Fixed: 951144
This commit is contained in:
parent
a08bb59d7b
commit
57aa215504
1 changed files with 5 additions and 4 deletions
|
@ -136,6 +136,7 @@ void loc_eng_nmea_generate_pos(loc_eng_data_s_type *loc_eng_data_p,
|
||||||
int utcHours = pTm->tm_hour;
|
int utcHours = pTm->tm_hour;
|
||||||
int utcMinutes = pTm->tm_min;
|
int utcMinutes = pTm->tm_min;
|
||||||
int utcSeconds = pTm->tm_sec;
|
int utcSeconds = pTm->tm_sec;
|
||||||
|
int utcMSeconds = (location.gpsLocation.timestamp)%1000;
|
||||||
|
|
||||||
if (generate_nmea) {
|
if (generate_nmea) {
|
||||||
// ------------------
|
// ------------------
|
||||||
|
@ -281,8 +282,8 @@ void loc_eng_nmea_generate_pos(loc_eng_data_s_type *loc_eng_data_p,
|
||||||
pMarker = sentence;
|
pMarker = sentence;
|
||||||
lengthRemaining = sizeof(sentence);
|
lengthRemaining = sizeof(sentence);
|
||||||
|
|
||||||
length = snprintf(pMarker, lengthRemaining, "$GPRMC,%02d%02d%02d,A," ,
|
length = snprintf(pMarker, lengthRemaining, "$GPRMC,%02d%02d%02d.%02d,A," ,
|
||||||
utcHours, utcMinutes, utcSeconds);
|
utcHours, utcMinutes, utcSeconds,utcMSeconds/10);
|
||||||
|
|
||||||
if (length < 0 || length >= lengthRemaining)
|
if (length < 0 || length >= lengthRemaining)
|
||||||
{
|
{
|
||||||
|
@ -434,8 +435,8 @@ void loc_eng_nmea_generate_pos(loc_eng_data_s_type *loc_eng_data_p,
|
||||||
pMarker = sentence;
|
pMarker = sentence;
|
||||||
lengthRemaining = sizeof(sentence);
|
lengthRemaining = sizeof(sentence);
|
||||||
|
|
||||||
length = snprintf(pMarker, lengthRemaining, "$GPGGA,%02d%02d%02d," ,
|
length = snprintf(pMarker, lengthRemaining, "$GPGGA,%02d%02d%02d.%02d," ,
|
||||||
utcHours, utcMinutes, utcSeconds);
|
utcHours, utcMinutes, utcSeconds, utcMSeconds/10);
|
||||||
|
|
||||||
if (length < 0 || length >= lengthRemaining)
|
if (length < 0 || length >= lengthRemaining)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue