[6.3.0][V2N] 修正新链路乘客屏道路事件触发时不绘制

This commit is contained in:
renwj
2024-03-19 20:28:11 +08:00
parent 59c02705dd
commit 2fcc8d680b
3 changed files with 33 additions and 0 deletions

View File

@@ -76,6 +76,24 @@ class TeleMsgHandler : IMsgHandler {
}
return
}
if (it.protocolType == TelematicConstant.V2N_NEW_LINK_SWITCH) {
try {
Log.d(TAG, "乘客屏收到司机屏转发的新链路开关 --- 1 ---")
val content = String(it.body, Charset.defaultCharset())
Log.d(TAG, "乘客屏收到司机屏转发的新链路开关 --- 2 ---:$content")
val data = GsonUtils.fromJson(content, Map::class.java)
val f1 = data["f1"] as Boolean
val f2 = data["f2"] as Boolean
Log.d(TAG, "乘客屏收到司机屏转发的新链路开关 --- 3 ---:$data, f1: $f1, f2:$f2")
FunctionBuildConfig.v2nMainSwitch = f1
FunctionBuildConfig.isNewV2NData = f2
} catch (t: Throwable) {
t.printStackTrace()
Log.e(TAG, "乘客屏收到司机屏转发的新链路开关异常", t)
}
return
}
when (it.protocolType) {
MogoProtocolMsg.NORMAL_DATA -> {
try {