Merge remote-tracking branch 'origin/dev_robobus-m1-p-app-module_1.1.0_230112_1.1.0' into dev_robobus-m1-p-app-module_1.1.0_230112_1.1.0
This commit is contained in:
@@ -104,7 +104,7 @@ class PM2DrivingModel private constructor() {
|
||||
CallerAutoPilotStatusListenerManager.addListener(TAG, mAutoPilotStatusListener)
|
||||
|
||||
// 定位监听
|
||||
CallerChassisLocationGCJ02ListenerManager.addListener(TAG, mMapLocationListener)
|
||||
CallerChassisLocationGCJ02ListenerManager.addListener(TAG,20, mMapLocationListener)
|
||||
// CallerChassisLocationGCJ02ListenerManager.setListenerHz(TAG,2)//设置2hz, 1s返回2次
|
||||
|
||||
//司乘屏通信监听
|
||||
|
||||
@@ -38,9 +38,9 @@ class PM2DrivingPresenter(view: PM2DrivingInfoFragment?) :
|
||||
}
|
||||
|
||||
override fun updateSpeed(speed: Int) {
|
||||
CallerLogger.d(
|
||||
SceneConstant.M_BUS_P + "speed = ",speed.toString()
|
||||
)
|
||||
// CallerLogger.d(
|
||||
// SceneConstant.M_BUS_P + "speed = ",speed.toString()
|
||||
// )
|
||||
ThreadUtils.runOnUiThread {
|
||||
mView?.updateSpeed(speed)
|
||||
}
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 83 KiB After Width: | Height: | Size: 528 KiB |
@@ -156,7 +156,7 @@ public class OrderModel {
|
||||
mContext = AbsMogoApplication.getApp();
|
||||
loginService = (LoginService) ARouter.getInstance().build(OchCommonConst.LOGINSERVICE).navigation();
|
||||
// 定位监听
|
||||
CallerChassisLocationGCJ02ListenerManager.INSTANCE.addListener(TAG, mMapLocationListener);
|
||||
CallerChassisLocationGCJ02ListenerManager.INSTANCE.addListener(TAG, 20,mMapLocationListener);
|
||||
// CallerChassisLocationGCJ02ListenerManager.INSTANCE.setListenerHz(TAG,2);//设置5hz, 1s返回一次
|
||||
|
||||
MogoStatusManager.getInstance().registerStatusChangedListener(TAG, StatusDescriptor.VR_MODE, mMogoStatusChangedListener);
|
||||
|
||||
@@ -44,7 +44,7 @@ public class MogoRouteOverlayManager implements
|
||||
public void init() {
|
||||
CallerPlanningTrajectoryListenerManager.INSTANCE.addListener(TAG, this);
|
||||
CallerAutoPilotStatusListenerManager.INSTANCE.addListener(TAG, this);
|
||||
CallerChassisLocationGCJ02ListenerManager.INSTANCE.addListener(TAG, this);
|
||||
CallerChassisLocationGCJ02ListenerManager.INSTANCE.addListener(TAG, 20,this);
|
||||
}
|
||||
|
||||
public static MogoRouteOverlayManager getInstance() {
|
||||
|
||||
@@ -32,7 +32,7 @@ class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context,
|
||||
initMapView()
|
||||
|
||||
CallerSkinModeListenerManager.addListener(TAG, this)
|
||||
CallerChassisLocationWGS84ListenerManager.addListener(TAG, this)
|
||||
CallerChassisLocationWGS84ListenerManager.addListener(TAG, 20,this)
|
||||
CallerChassisLamplightListenerManager.addListener(TAG, this)
|
||||
|
||||
}
|
||||
|
||||
@@ -74,7 +74,19 @@ object CallerChassisLocationGCJ02ListenerManager : CallerBase<IMoGoChassisLocati
|
||||
syncLocationCallback(tag, it, mGnssInfo!!, sourceType)
|
||||
}
|
||||
} else {
|
||||
syncLocationCallback(tag, it, mGnssInfo!!, sourceType)
|
||||
//Logger.d(TAG, "没设置监听频率,使用默认5HZ")
|
||||
val hzTime = (1.0 / 5) * 1000
|
||||
// 获取最后一次回调的时间
|
||||
val hzLastSendTime = M_LISTENERS_HZ_LAST_SEND_TIME[tag]
|
||||
if (hzLastSendTime != null && hzLastSendTime > 0) {
|
||||
// 计算是否进入下一次回调周期
|
||||
val nowTime = TimeUtils.getNowMills()
|
||||
if (nowTime - hzLastSendTime > hzTime) {
|
||||
syncLocationCallback(tag, it, mGnssInfo!!, sourceType)
|
||||
}
|
||||
} else {
|
||||
syncLocationCallback(tag, it, mGnssInfo!!, sourceType)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,7 +59,19 @@ object CallerChassisLocationWGS84ListenerManager : CallerBase<IMoGoChassisLocati
|
||||
syncLocationCallback(tag, it, mGnssInfo, sourceType)
|
||||
}
|
||||
} else {
|
||||
syncLocationCallback(tag, it, mGnssInfo, sourceType)
|
||||
//Logger.d(TAG, "没设置监听频率,使用默认5HZ")
|
||||
val hzTime = (1.0 / 5) * 1000
|
||||
// 获取最后一次回调的时间
|
||||
val hzLastSendTime = M_LISTENERS_HZ_LAST_SEND_TIME[tag]
|
||||
if (hzLastSendTime != null && hzLastSendTime > 0) {
|
||||
// 计算是否进入下一次回调周期
|
||||
val nowTime = TimeUtils.getNowMills()
|
||||
if (nowTime - hzLastSendTime > hzTime) {
|
||||
syncLocationCallback(tag, it, mGnssInfo, sourceType)
|
||||
}
|
||||
} else {
|
||||
syncLocationCallback(tag, it, mGnssInfo, sourceType)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user