test
This commit is contained in:
@@ -1004,19 +1004,27 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
if (gnssInfo.getLongitude() == -1) {
|
||||
return;
|
||||
}
|
||||
RTKAutopilotLocationBean bean = new RTKAutopilotLocationBean();
|
||||
bean.setYaw_rate(gnssInfo.getYawRate());
|
||||
bean.setHeading(gnssInfo.getHeading());
|
||||
bean.setAcceleration(gnssInfo.getAcceleration());
|
||||
bean.setAlt(gnssInfo.getAltitude());
|
||||
bean.setSystemTime(Double.valueOf(gnssInfo.getSystemTime()).longValue());
|
||||
LonLatPoint bean = new LonLatPoint();
|
||||
bean.setAngle(gnssInfo.getHeading());
|
||||
bean.setAltitude(gnssInfo.getAltitude());
|
||||
bean.setLongitude(gnssInfo.getLongitude());
|
||||
bean.setLatitude(gnssInfo.getLatitude());
|
||||
bean.setSatelliteTime(Double.valueOf(gnssInfo.getSatelliteTime() * 1000).longValue());
|
||||
bean.setLon(gnssInfo.getLongitude());
|
||||
bean.setLat(gnssInfo.getLatitude());
|
||||
bean.setGnss_speed(((float) gnssInfo.getGnssSpeed()));
|
||||
bean.setReceiverDataTime(System.currentTimeMillis());
|
||||
bean.setSpeed((float) gnssInfo.getGnssSpeed());
|
||||
// RTKAutopilotLocationBean bean = new RTKAutopilotLocationBean();
|
||||
// bean.setYaw_rate(gnssInfo.getYawRate());
|
||||
// bean.setHeading(gnssInfo.getHeading());
|
||||
// bean.setAcceleration(gnssInfo.getAcceleration());
|
||||
// bean.setAlt(gnssInfo.getAltitude());
|
||||
// bean.setSystemTime(Double.valueOf(gnssInfo.getSystemTime()).longValue());
|
||||
// bean.setSatelliteTime(Double.valueOf(gnssInfo.getSatelliteTime() * 1000).longValue());
|
||||
// bean.setLon(gnssInfo.getLongitude());
|
||||
// bean.setLat(gnssInfo.getLatitude());
|
||||
// bean.setGnss_speed(((float) gnssInfo.getGnssSpeed()));
|
||||
// bean.setReceiverDataTime(System.currentTimeMillis());
|
||||
// 使用外部定位数据修改自车位置
|
||||
mMapView.getLocationClient().updateRTKAutoPilotLocation(bean);
|
||||
// mMapView.getLocationClient().updateRTKAutoPilotLocation(bean);
|
||||
mMapView.getLocationClient().updateLocation(bean);
|
||||
CallerMapUIServiceManager.INSTANCE.getSingletonLocationClient(getContext()).updateLocation(bean);
|
||||
CallerMapDataCollectorManager.INSTANCE.setIsInit();
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ import com.mogo.map.utils.ObjectUtils;
|
||||
import com.zhidaoauto.map.sdk.open.location.LocationClient;
|
||||
import com.zhidaoauto.map.sdk.open.location.LocationListener;
|
||||
import com.zhidaoauto.map.sdk.open.location.RTKAutopilotLocationBean;
|
||||
import com.zhidaoauto.map.sdk.open.query.LonLatPoint;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
@@ -140,10 +141,16 @@ public class ALocationClient implements IMogoLocationClient {
|
||||
if (locationToUpdate instanceof MogoLocation) {
|
||||
return;
|
||||
}
|
||||
if (locationToUpdate instanceof RTKAutopilotLocationBean) {
|
||||
RTKAutopilotLocationBean current = (RTKAutopilotLocationBean) locationToUpdate;
|
||||
// if (locationToUpdate instanceof RTKAutopilotLocationBean) {
|
||||
// RTKAutopilotLocationBean current = (RTKAutopilotLocationBean) locationToUpdate;
|
||||
// if (mClient != null) {
|
||||
// mClient.updateRTKAutoPilotLocation(current);
|
||||
// }
|
||||
// }
|
||||
if (locationToUpdate instanceof com.zhidaoauto.map.sdk.open.query.LonLatPoint) {
|
||||
LonLatPoint current = (LonLatPoint) locationToUpdate;
|
||||
if (mClient != null) {
|
||||
mClient.updateRTKAutoPilotLocation(current);
|
||||
mClient.updateLocation(current);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user