[dev_arch_opt_3.0]
[Change] [ 1、完成工控机数据和高德GPS地图数据的数据中心,以及工控机数据超时后的自动切换为高德地图GPS数据 定位监听已重构,CallerChassisLocationGCJ20ListenerManager---高的坐标系,CallerChassisLocationWGS84ListenerManager--高精坐标系,之前代码已修改,大家后续项目中根据需要进行订阅,如需控制频率可在订阅时 // 设置数据回调频率,单位HZ,1HZ的周期是1秒;50HZ的周期是1/50=0.02秒;10HZ的周期是1/10=0.1秒。 CallerChassisLocationWGS84ListenerManager.setListenerHz(Companion.functionName, 20) CallerChassisLocationGCJ20ListenerManagersetListenerHz(Companion.functionName, 20) ] Signed-off-by: donghongyu <donghongyu@zhidaoauto.com>
This commit is contained in:
@@ -324,9 +324,6 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
CallerLogger.INSTANCE.d(M_MAP + TAG, "map onDestroy");
|
||||
}
|
||||
|
||||
// if (mLocationTask != null) {
|
||||
// mainHandler.removeCallbacks(mLocationTask);
|
||||
// }
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1051,7 +1048,7 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
|
||||
|
||||
@Override
|
||||
public void setExtraGPSData(MessagePad.GnssInfo gnssInfo) {
|
||||
public void setExtraGPSData(MogoLocation gnssInfo) {
|
||||
LocationClient locationClient = mMapView.getLocationClient();
|
||||
if (locationClient != null) {
|
||||
locationClient.setIsUseExtraGPSData(true);//设置是否使用外界坐标
|
||||
|
||||
@@ -7,6 +7,7 @@ import android.view.View;
|
||||
|
||||
import com.mogo.eagle.core.data.map.CenterLine;
|
||||
import com.mogo.eagle.core.data.map.MogoLatLng;
|
||||
import com.mogo.eagle.core.data.map.MogoLocation;
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger;
|
||||
import com.mogo.map.uicontroller.CarCursorOption;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
@@ -414,7 +415,7 @@ public class MogoMapUIController implements IMogoMapUIController {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setExtraGPSData(MessagePad.GnssInfo gnssInfo) {
|
||||
public void setExtraGPSData(MogoLocation gnssInfo) {
|
||||
initDelegate();
|
||||
if (mDelegate != null) {
|
||||
mDelegate.setExtraGPSData(gnssInfo);
|
||||
|
||||
@@ -9,6 +9,7 @@ import android.widget.FrameLayout;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.mogo.eagle.core.data.map.MogoLocation;
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger;
|
||||
import com.zhidaoauto.map.sdk.open.view.MapAutoView;
|
||||
|
||||
@@ -88,7 +89,7 @@ public class MogoMapView extends MogoBaseMapView implements ILifeCycle {
|
||||
super.onLowMemory();
|
||||
}
|
||||
|
||||
public void setExtraGPSData(MessagePad.GnssInfo gnssInfo) {
|
||||
public void setExtraGPSData(MogoLocation gnssInfo) {
|
||||
getMap().getUIController().setExtraGPSData(gnssInfo);
|
||||
}
|
||||
|
||||
|
||||
@@ -8,6 +8,7 @@ import android.view.View;
|
||||
|
||||
import com.mogo.eagle.core.data.map.CenterLine;
|
||||
import com.mogo.eagle.core.data.map.MogoLatLng;
|
||||
import com.mogo.eagle.core.data.map.MogoLocation;
|
||||
import com.zhidaoauto.map.sdk.open.MapAutoApi;
|
||||
|
||||
import org.json.JSONObject;
|
||||
@@ -355,7 +356,7 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setExtraGPSData(MessagePad.GnssInfo gnssInfo) {
|
||||
public void setExtraGPSData(MogoLocation gnssInfo) {
|
||||
if (mClient != null) {
|
||||
mClient.setExtraGPSData(gnssInfo);
|
||||
}
|
||||
|
||||
@@ -152,11 +152,11 @@ public class ObjectUtils {
|
||||
location.setLocType(0);
|
||||
}
|
||||
location.setSatellite(4);
|
||||
location.setSpeed(aLocation.getSpeed());
|
||||
location.setGnssSpeed(aLocation.getSpeed());
|
||||
location.setLatitude(aLocation.getLat());
|
||||
location.setLongitude(aLocation.getLon());
|
||||
location.setAltitude(aLocation.getAltitude());
|
||||
location.setBearing((float) aLocation.getHeading());
|
||||
location.setHeading((float) aLocation.getHeading());
|
||||
location.setCityCode(aLocation.getCityCode());
|
||||
location.setCityName(aLocation.getCity());
|
||||
location.setProvider(aLocation.getProvider());
|
||||
|
||||
Reference in New Issue
Block a user