Merge branch 'master' into dev_robo_240612_6.5.0_tmp
This commit is contained in:
@@ -4,6 +4,8 @@ import android.os.SystemClock
|
||||
import chassis.SpecialVehicleTaskCmdOuterClass
|
||||
import com.mogo.commons.voice.AIAssist
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters
|
||||
import com.mogo.eagle.core.data.autopilot.toAutoPilotLine
|
||||
import com.mogo.eagle.core.data.autopilot.toRouteInfo
|
||||
import com.mogo.eagle.core.data.deva.badcase.BagManagerEntity
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.data.constants.MogoServicePaths
|
||||
@@ -177,12 +179,24 @@ object CallerAutoPilotControlManager {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 发送 轨迹下载请求
|
||||
*/
|
||||
fun sendTrajectoryDownloadReq(autopilotControlParameters: AutopilotControlParameters) {
|
||||
if (AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)) {
|
||||
// Routing 需要传参 routeInfo
|
||||
providerApi?.sendTrajectoryDownloadReq(autopilotControlParameters.autoPilotLine!!, autopilotControlParameters.toRouteInfo())
|
||||
CallerAutoPilotStatusListenerManager.invokeTrajectoryDownloadReq(autopilotControlParameters.autoPilotLine!!, 0)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 发送 轨迹下载请求
|
||||
*/
|
||||
fun sendTrajectoryDownloadReq(autoPilotLine: AutopilotControlParameters.AutoPilotLine) {
|
||||
if (AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)) {
|
||||
providerApi?.sendTrajectoryDownloadReq(autoPilotLine)
|
||||
//TODO Routing 需要传参 routeInfo,这里建议业务侧重新整合到同一个数据实体内传入
|
||||
providerApi?.sendTrajectoryDownloadReq(autoPilotLine, null)
|
||||
CallerAutoPilotStatusListenerManager.invokeTrajectoryDownloadReq(autoPilotLine, 0)
|
||||
}
|
||||
}
|
||||
@@ -193,7 +207,8 @@ object CallerAutoPilotControlManager {
|
||||
*/
|
||||
fun sendTrajectoryDownloadReq(autoPilotLine: AutopilotControlParameters.AutoPilotLine, downloadType: Int) {
|
||||
if (AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)) {
|
||||
providerApi?.sendTrajectoryDownloadReq(autoPilotLine, downloadType)
|
||||
//TODO Routing 需要传参 routeInfo,这里建议业务侧重新整合到同一个数据实体内传入
|
||||
providerApi?.sendTrajectoryDownloadReq(autoPilotLine, downloadType, null)
|
||||
CallerAutoPilotStatusListenerManager.invokeTrajectoryDownloadReq(autoPilotLine, downloadType)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
package com.mogo.eagle.core.function.call.autopilot
|
||||
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoFsm2024Listener
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoV2nNioEventListener
|
||||
import com.mogo.eagle.core.function.call.base.CallerBase
|
||||
import fsm.Fsm2024
|
||||
import mogo.telematics.pad.MessagePad
|
||||
|
||||
@@ -396,4 +396,8 @@ object CallerDevaToolsManager {
|
||||
fun unRegisterStartAutopilotStateListener(tag: String) {
|
||||
devaToolsProviderApi?.unRegisterStartAutopilotStateListener(tag)
|
||||
}
|
||||
|
||||
fun setRouteDynamicColorEnable(enable: Boolean) {
|
||||
devaToolsProviderApi?.setRouteDynamicColorEnable(enable)
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
package com.mogo.eagle.core.function.call.map
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter
|
||||
import com.mogo.eagle.core.data.constants.MogoServicePaths
|
||||
import com.mogo.eagle.core.function.api.map.trajectory.IMoGoGlobalTrajectoryDrawListener
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
|
||||
|
||||
object CallerMapGlobalTrajectoryDrawManager {
|
||||
|
||||
private val provider by lazy {
|
||||
ARouter.getInstance().build(MogoServicePaths.PATH_MAP_GLOBAL_TRAJECTORY)
|
||||
.navigation() as? IMoGoGlobalTrajectoryDrawListener
|
||||
}
|
||||
|
||||
fun init() {
|
||||
provider?.let {
|
||||
CallerLogger.i("CallerMapGlobalTrajectoryDrawManager", "--- init ---")
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 是否已经在高精地图绘制了全局轨迹
|
||||
*/
|
||||
fun hasDrawnGlobalTrajectory(): Boolean {
|
||||
return provider?.hasDrawnGlobalTrajectory() ?: false
|
||||
}
|
||||
|
||||
/**
|
||||
* 在高精地图绘制全局轨迹
|
||||
* @return boolean-是否绘制成功, string-未绘制原因
|
||||
*/
|
||||
fun drawGlobalTrajectory(): Pair<Boolean, String> {
|
||||
return provider?.drawGlobalTrajectory() ?: Pair(false, "provider=null")
|
||||
}
|
||||
|
||||
/**
|
||||
* 清除高精地图中的全局轨迹
|
||||
*/
|
||||
fun clearGlobalTrajectory(isClearData: Boolean) {
|
||||
provider?.clearGlobalTrajectory(isClearData)
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user