|
@@ -118,20 +118,20 @@ void GpsDataDecode(uint8 *msg)
|
|
|
GpsInfoData.direction[0] = 0xff;
|
|
|
GpsInfoData.direction[1] = 0xff;
|
|
|
}
|
|
|
-// if (speedtemp >= 30 && speedtemp <= 1500 && BattWorkStateDelay == 0x01)
|
|
|
-// {
|
|
|
-// AppDataInfo.appDataModify = true;
|
|
|
-// AppDataInfo.AccMileage = speedtemp / 36 + AppDataInfo.AccMileage;
|
|
|
-// if (AppDataInfo.AccMileage >= 0xfffffffe)
|
|
|
-// {
|
|
|
-// AppDataInfo.AccMileage = 0;
|
|
|
-// }
|
|
|
-// }累计里程的累加
|
|
|
+ if (speedtemp >= 50 && speedtemp <= 1500)
|
|
|
+ {
|
|
|
+ AppConfigInfo.appSaveFlg = true;
|
|
|
+ AppConfigInfo.AppDataInfo.AccMileage = speedtemp / 36 + AppConfigInfo.AppDataInfo.AccMileage;
|
|
|
+ if (AppConfigInfo.AppDataInfo.AccMileage >= 0xfffffffe)
|
|
|
+ {
|
|
|
+ AppConfigInfo.AppDataInfo.AccMileage = 0;
|
|
|
+ }
|
|
|
+ }//累计里程的累加
|
|
|
}
|
|
|
-// GpsInfoData.AccMileage[0] = AppDataInfo.AccMileage >> 24;
|
|
|
-// GpsInfoData.AccMileage[1] = AppDataInfo.AccMileage >> 16;
|
|
|
-// GpsInfoData.AccMileage[2] = AppDataInfo.AccMileage >> 8;
|
|
|
-// GpsInfoData.AccMileage[3] = AppDataInfo.AccMileage;
|
|
|
+ GpsInfoData.AccMileage[0] = AppConfigInfo.AppDataInfo.AccMileage >> 24;
|
|
|
+ GpsInfoData.AccMileage[1] = AppConfigInfo.AppDataInfo.AccMileage >> 16;
|
|
|
+ GpsInfoData.AccMileage[2] = AppConfigInfo.AppDataInfo.AccMileage >> 8;
|
|
|
+ GpsInfoData.AccMileage[3] = AppConfigInfo.AppDataInfo.AccMileage;
|
|
|
}
|
|
|
p2 = strtok(p2, ","); //只取第2行的信息GGA
|
|
|
memset(databuffer, 0x30, 20);
|