[3.3.0] reset log tag
This commit is contained in:
@@ -36,7 +36,7 @@ import com.mogo.eagle.core.function.datacenter.autopilot.telematic.TeleMsgHandle
|
||||
import com.mogo.eagle.core.function.call.telematic.CallerTelematicStatusListenerManager
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_ADAS_IMPL
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_D_C
|
||||
import com.mogo.eagle.core.utilcode.mogo.storage.SharedPrefsMgr
|
||||
import com.mogo.eagle.core.utilcode.util.ParseVersionUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils
|
||||
@@ -92,7 +92,7 @@ class MoGoAutopilotControlProvider :
|
||||
get() = TAG
|
||||
|
||||
override fun init(context: Context) {
|
||||
CallerLogger.i("$M_ADAS_IMPL$TAG", "初始化工控机连接……")
|
||||
CallerLogger.i("$M_D_C$TAG", "初始化工控机连接……")
|
||||
mContext = context
|
||||
// 初始化ADAS 域控制器
|
||||
CupidLogUtils.setEnableLog(false)
|
||||
@@ -159,7 +159,7 @@ class MoGoAutopilotControlProvider :
|
||||
}
|
||||
|
||||
override fun onChannelDisConnect(channel: Channel?) {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "onChannelDisConnect")
|
||||
CallerLogger.d("$M_D_C$TAG", "onChannelDisConnect")
|
||||
}
|
||||
|
||||
override fun onReceiveClientSign(channel: Channel?, sn: String?) {
|
||||
@@ -222,7 +222,7 @@ class MoGoAutopilotControlProvider :
|
||||
}
|
||||
})
|
||||
CallerAutopilotCarConfigListenerManager.addListener(TAG, this)
|
||||
CallerLogger.i("$M_ADAS_IMPL$TAG", "initServer……")
|
||||
CallerLogger.i("$M_D_C$TAG", "initServer……")
|
||||
// 同步数据给工控机的服务
|
||||
AsyncDataToAutopilotServer.INSTANCE.initServer()
|
||||
}
|
||||
@@ -255,7 +255,7 @@ class MoGoAutopilotControlProvider :
|
||||
NSDNettyManager.getInstance()
|
||||
.sendMsgToAllClients(MogoProtocolMsg(NORMAL_DATA, bytes.size, bytes))
|
||||
} else {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "司机端Server未启动!")
|
||||
CallerLogger.d("$M_D_C$TAG", "司机端Server未启动!")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -313,12 +313,12 @@ class MoGoAutopilotControlProvider :
|
||||
|
||||
override fun onMapCollectStart(cmdId: Int, cmdTime: Long) {
|
||||
val result = recordPackage(2, cmdId)
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "开始记录包: [$cmdId, $result]")
|
||||
CallerLogger.d("$M_D_C$TAG", "开始记录包: [$cmdId, $result]")
|
||||
}
|
||||
|
||||
override fun onMapCollectEnd(cmdId: Int, cmdTime: Long) {
|
||||
val result = stopRecord(2, cmdId)
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "结束记录包: [$cmdId, $result]")
|
||||
CallerLogger.d("$M_D_C$TAG", "结束记录包: [$cmdId, $result]")
|
||||
}
|
||||
|
||||
override fun startAutoPilot(controlParameters: AutopilotControlParameters) {
|
||||
@@ -333,7 +333,7 @@ class MoGoAutopilotControlProvider :
|
||||
invokeAutoPilotResult(if (invokeResult) "自动驾驶调用成功" else "自动驾驶调用失败, socket 或者 rawPack 可能为空")
|
||||
} else {
|
||||
invokeAutoPilotResult("车机与工控机链接失败,无法开启自动驾驶")
|
||||
CallerLogger.e("$M_ADAS_IMPL$TAG", "车机与工控机链接失败,无法开启自动驾驶")
|
||||
CallerLogger.e("$M_D_C$TAG", "车机与工控机链接失败,无法开启自动驾驶")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -346,7 +346,7 @@ class MoGoAutopilotControlProvider :
|
||||
paramIndexes = [0]
|
||||
)
|
||||
private fun invokeAutoPilotResult(status: String) {
|
||||
CallerLogger.e("$M_ADAS_IMPL$TAG", status)
|
||||
CallerLogger.e("$M_D_C$TAG", status)
|
||||
}
|
||||
|
||||
override fun sendTrafficLightData(trafficLightResult: TrafficLightResult) {
|
||||
@@ -373,7 +373,7 @@ class MoGoAutopilotControlProvider :
|
||||
if (AdasManager.getInstance().ipcConnectionStatus == Constants.IPC_CONNECTION_STATUS.CONNECTED) {
|
||||
AdasManager.getInstance().sendAutoPilotModeReq(0, 1, null)
|
||||
} else {
|
||||
CallerLogger.e("$M_ADAS_IMPL$TAG", "车机与工控机链接失败,无法断开自动驾驶")
|
||||
CallerLogger.e("$M_D_C$TAG", "车机与工控机链接失败,无法断开自动驾驶")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -467,7 +467,7 @@ class MoGoAutopilotControlProvider :
|
||||
)
|
||||
)
|
||||
} else {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "同步美化模式状态时司机端Server未启动!")
|
||||
CallerLogger.d("$M_D_C$TAG", "同步美化模式状态时司机端Server未启动!")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -490,7 +490,7 @@ class MoGoAutopilotControlProvider :
|
||||
)
|
||||
)
|
||||
} else {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "同步美化模式状态时司机端Server未启动!")
|
||||
CallerLogger.d("$M_D_C$TAG", "同步美化模式状态时司机端Server未启动!")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -877,7 +877,7 @@ class MoGoAutopilotControlProvider :
|
||||
paramIndexes = [0]
|
||||
)
|
||||
private fun invokeNettyConnResult(status: String) {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", status)
|
||||
CallerLogger.d("$M_D_C$TAG", status)
|
||||
}
|
||||
|
||||
override fun getTeleTimeStamp(): Long {
|
||||
|
||||
@@ -11,7 +11,7 @@ import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListener
|
||||
import com.mogo.eagle.core.function.call.cloud.CallerCloudListenerManager
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_ADAS_IMPL
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_D_C
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.zhidao.support.adas.high.AdasManager
|
||||
import com.zhidao.support.adas.high.OnAdasConnectStatusListener
|
||||
@@ -47,7 +47,7 @@ class MoGoAdasMsgConnectStatusListenerImpl :
|
||||
AppConfigInfo.connectStatusDescribe = reason
|
||||
when (ipcConnectionStatus) {
|
||||
Constants.IPC_CONNECTION_STATUS.CONNECTED -> {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "webSocket 连接成功")
|
||||
CallerLogger.d("$M_D_C$TAG", "webSocket 连接成功")
|
||||
connectStatus = true
|
||||
// 初始化自动驾驶状态信息
|
||||
CallerAutoPilotStatusListenerManager.getAutoPilotStatusInfo().connectIP =
|
||||
@@ -70,7 +70,7 @@ class MoGoAdasMsgConnectStatusListenerImpl :
|
||||
CallerAutoPilotControlManager.setRainMode(FunctionBuildConfig.isRainMode)
|
||||
}
|
||||
Constants.IPC_CONNECTION_STATUS.DISCONNECTED -> {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "webSocket 连接失败 reason:$reason")
|
||||
CallerLogger.d("$M_D_C$TAG", "webSocket 连接失败 reason:$reason")
|
||||
if (connectStatus) {
|
||||
reason?.let {
|
||||
ToastUtils.showLong("工控机连接断开,原因:$it , 等待重连")
|
||||
@@ -88,13 +88,13 @@ class MoGoAdasMsgConnectStatusListenerImpl :
|
||||
CallerAutoPilotStatusListenerManager.getAutoPilotStatusInfo().pilotmode = 0
|
||||
}
|
||||
Constants.IPC_CONNECTION_STATUS.CONNECTING -> {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "webSocket 正在连接")
|
||||
CallerLogger.d("$M_D_C$TAG", "webSocket 正在连接")
|
||||
}
|
||||
Constants.IPC_CONNECTION_STATUS.SEARCH_ADDRESS -> {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "webSocket 正在搜索工控机IP")
|
||||
CallerLogger.d("$M_D_C$TAG", "webSocket 正在搜索工控机IP")
|
||||
}
|
||||
Constants.IPC_CONNECTION_STATUS.NOT_FOUND_ADDRESS -> {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "webSocket 找不到可用IP 传入的IP不可用或固定IP列表中所有IP不可用")
|
||||
CallerLogger.d("$M_D_C$TAG", "webSocket 找不到可用IP 传入的IP不可用或固定IP列表中所有IP不可用")
|
||||
}
|
||||
}
|
||||
CallerAutoPilotStatusListenerManager.getAutoPilotStatusInfo().ipcConnStatus = ipcConnectionStatus
|
||||
@@ -117,7 +117,7 @@ class MoGoAdasMsgConnectStatusListenerImpl :
|
||||
* 同步SN信息给工控机
|
||||
*/
|
||||
private fun syncBasicInfoToAutopilot() {
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "同步PAD的SN给工控机……")
|
||||
CallerLogger.d("$M_D_C$TAG", "同步PAD的SN给工控机……")
|
||||
if (AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)) {
|
||||
// 设置PAD-SN给工控,网络环境
|
||||
AdasManager.getInstance()
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
package com.mogo.eagle.core.function.datacenter.autopilot.server
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import com.mogo.eagle.core.data.biz.trafficlight.TrafficLightResult
|
||||
import com.mogo.eagle.core.data.deva.chain.ChainConstant
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
@@ -16,7 +15,6 @@ import io.reactivex.Observable
|
||||
import io.reactivex.android.schedulers.AndroidSchedulers
|
||||
import io.reactivex.disposables.Disposable
|
||||
import java.util.concurrent.TimeUnit
|
||||
import java.util.concurrent.atomic.AtomicInteger
|
||||
|
||||
/**
|
||||
* @author xiaoyuzhou
|
||||
@@ -45,7 +43,7 @@ class AsyncDataToAutopilotServer private constructor() : IMoGoTrafficLightListen
|
||||
override fun onAutopilotStatusResponse(state: Int) {
|
||||
createSubscribe?.let {
|
||||
if (!it.isDisposed) {
|
||||
bizLog(SceneConstant.M_ADAS_IMPL + TAG, "自动驾驶状态变化,取消前置轨迹请求,间隔2s重新请求底盘轨迹")
|
||||
bizLog(SceneConstant.M_D_C + TAG, "自动驾驶状态变化,取消前置轨迹请求,间隔2s重新请求底盘轨迹")
|
||||
createSubscribe?.dispose()
|
||||
}
|
||||
when (state) {
|
||||
@@ -53,7 +51,7 @@ class AsyncDataToAutopilotServer private constructor() : IMoGoTrafficLightListen
|
||||
createSubscribe = Observable.timer(2000L, TimeUnit.MILLISECONDS)
|
||||
.observeOn(AndroidSchedulers.mainThread())
|
||||
.subscribe {
|
||||
bizLog(SceneConstant.M_ADAS_IMPL + TAG, "请求底盘轨迹")
|
||||
bizLog(SceneConstant.M_D_C + TAG, "请求底盘轨迹")
|
||||
CallerAutoPilotControlManager.getGlobalPath()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -228,7 +228,7 @@ class TeleMsgHandler : IMsgHandler {
|
||||
|
||||
override fun handleClientConn2Server(channel: Channel?) {
|
||||
val socketAddress = channel?.remoteAddress().toString()
|
||||
CallerLogger.d("${SceneConstant.M_ADAS_IMPL}$TAG", "Client ip is:${socketAddress}")
|
||||
CallerLogger.d("${SceneConstant.M_D_C}$TAG", "Client ip is:${socketAddress}")
|
||||
setDemoMode(FunctionBuildConfig.isDemoMode)
|
||||
setIgnoreConditionDraw(FunctionBuildConfig.isIgnoreConditionsDrawAutopilotTrajectoryData)
|
||||
}
|
||||
@@ -286,7 +286,7 @@ class TeleMsgHandler : IMsgHandler {
|
||||
paramIndexes = [0]
|
||||
)
|
||||
private fun invokeNettyConnResult(status: String) {
|
||||
CallerLogger.d("${SceneConstant.M_ADAS_IMPL}$TAG", status)
|
||||
CallerLogger.d("${SceneConstant.M_D_C}$TAG", status)
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -83,7 +83,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
*/
|
||||
override fun onAutopilotPerceptionTrafficLight(trafficLights: TrafficLightOuterClass.TrafficLights?) {
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_OBU}${TAG}",
|
||||
"${SceneConstant.M_D_C}${TAG}",
|
||||
"onAutopilotPerceptionTrafficLight ---- hasObuLightStatus = $hasObuLightStatus ----hasAiLightStatus = $hasAiLightStatus "
|
||||
)
|
||||
if (!hasObuLightStatus) {
|
||||
@@ -122,7 +122,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
light = it.uTurn
|
||||
}
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_OBU}${TAG}",
|
||||
"${SceneConstant.M_D_C}${TAG}",
|
||||
"onAutopilotPerceptionTrafficLight light = $light "
|
||||
)
|
||||
if (light == null) {
|
||||
@@ -149,7 +149,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
if (!hasObuLightStatus) {
|
||||
hasAiLightStatus = true
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_OBU}${TAG}",
|
||||
"${SceneConstant.M_D_C}${TAG}",
|
||||
"onTrafficLightStatus trafficLightResult = $trafficLightResult "
|
||||
)
|
||||
updateTrafficLight(trafficLightResult)
|
||||
@@ -161,7 +161,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
* @param enter true:进入路口;false:离开路口
|
||||
*/
|
||||
override fun onEnterCrossRoad(enter: Boolean) {
|
||||
CallerLogger.d("${SceneConstant.M_OBU}${TAG}", "onEnterCrossRoad enter = $enter ")
|
||||
CallerLogger.d("${SceneConstant.M_D_C}${TAG}", "onEnterCrossRoad enter = $enter ")
|
||||
if (!enter) {
|
||||
Handler().postDelayed({
|
||||
hasAiLightStatus = false
|
||||
@@ -187,7 +187,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
override fun onTrafficRequestError() {
|
||||
hasAiLightStatus = false
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_OBU}${TAG}",
|
||||
"${SceneConstant.M_D_C}${TAG}",
|
||||
"onTrafficRequestError hasObuLightStatus = $hasObuLightStatus ------> "
|
||||
)
|
||||
CallerTrafficLightListenerManager.resetTrafficLightStatus(!hasObuLightStatus)
|
||||
@@ -200,7 +200,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
* obu数据消失
|
||||
*/
|
||||
override fun onObuTrafficLightDisapper() {
|
||||
CallerLogger.d("${SceneConstant.M_OBU}${TAG}", "onObuTrafficLightDisapper ------> ")
|
||||
CallerLogger.d("${SceneConstant.M_D_C}${TAG}", "onObuTrafficLightDisapper ------> ")
|
||||
hasObuLightStatus = false
|
||||
hide("OBU红绿灯消息关闭隐藏", DataSourceType.OBU)
|
||||
}
|
||||
@@ -210,7 +210,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
*/
|
||||
override fun resetTrafficLight(isReset: Boolean) {
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_OBU}${TAG}",
|
||||
"${SceneConstant.M_D_C}${TAG}",
|
||||
"resetTrafficLight ------> isReset = $isReset ---hasObuLightStatus = $hasObuLightStatus"
|
||||
)
|
||||
if (!hasObuLightStatus) {
|
||||
@@ -227,7 +227,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
paramIndexes = [0, 1]
|
||||
)
|
||||
private fun hide(msg: String, sourceType: DataSourceType) {
|
||||
CallerLogger.d("${SceneConstant.M_OBU}${TAG}", "hide() :$msg type :$sourceType")
|
||||
CallerLogger.d("${SceneConstant.M_D_C}${TAG}", "hide() :$msg type :$sourceType")
|
||||
CallerTrafficLightListenerManager.disableTrafficLight()
|
||||
}
|
||||
|
||||
@@ -250,7 +250,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
hasObuLightStatus = true
|
||||
}
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_OBU}${TAG}",
|
||||
"${SceneConstant.M_D_C}${TAG}",
|
||||
"onTrafficLightPlusSource ----- light = $light ---remain = $remain ---lightSource = $lightSource ---hasObuLightStatus = $hasObuLightStatus ---hasAiLightStatus = $hasAiLightStatus"
|
||||
)
|
||||
CallerTrafficLightListenerManager.showTrafficLight(light, lightSource)
|
||||
@@ -282,7 +282,7 @@ class TrafficLightDispatcher : IMoGoAutopilotIdentifyListener, IMoGoTrafficLight
|
||||
private fun updateTrafficLight(trafficLightResult: TrafficLightResult) {
|
||||
val currentTrafficLight = trafficLightResult.currentRoadTrafficLight()
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_OBU}${TAG}",
|
||||
"${SceneConstant.M_D_C}${TAG}",
|
||||
"updateTrafficLight ----- currentTrafficLight = $currentTrafficLight"
|
||||
)
|
||||
currentTrafficLight?.let {
|
||||
|
||||
Reference in New Issue
Block a user