From 5b59947b0f6d34e33117593276d84e65fc805529 Mon Sep 17 00:00:00 2001 From: chenfufeng Date: Thu, 8 Dec 2022 21:14:18 +0800 Subject: [PATCH] =?UTF-8?q?[2.13.0][Update]=E5=A2=9E=E5=8A=A0=E6=B6=88?= =?UTF-8?q?=E6=81=AF=E7=9B=92=E5=AD=90=E7=9A=84=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hmi/receiver/V2XWarningBroadcastReceiver.kt | 4 ++++ .../function/obu/mogo/MogoPrivateObuManager.kt | 15 +++++++++++++++ .../function/obu/mogo/MogoPrivateObuNewManager.kt | 12 ++++++++++++ .../core/function/v2x/events/V2XEventManager.kt | 5 ++++- .../scenario/scene/road/V2XRoadEventScenario.java | 6 ++++++ .../scene/warning/V2XFrontWarningScenario.java | 7 +++++++ .../v2x/redlightwarning/RedLightWarningManager.kt | 4 ++++ .../eagle/core/function/v2x/vip/VipCarManager.kt | 4 ++++ 8 files changed, 56 insertions(+), 1 deletion(-) diff --git a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/receiver/V2XWarningBroadcastReceiver.kt b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/receiver/V2XWarningBroadcastReceiver.kt index 244d170bfa..6207e5eb1b 100644 --- a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/receiver/V2XWarningBroadcastReceiver.kt +++ b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/receiver/V2XWarningBroadcastReceiver.kt @@ -3,6 +3,7 @@ package com.mogo.eagle.core.function.hmi.receiver import android.content.BroadcastReceiver import android.content.Context import android.content.Intent +import android.util.Log import com.mogo.eagle.core.function.call.hmi.CallerHmiManager import com.mogo.eagle.core.function.hmi.WaringConst import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger @@ -77,6 +78,9 @@ class V2XWarningBroadcastReceiver : BroadcastReceiver() { if (EventTypeEnum.TYPE_USECASE_ID_IVP.poiType == v2xType.toString()) { CallerHmiManager.showLimitingVelocity(1) } + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-V2XWarningBR", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.V2X, diff --git a/core/function-impl/mogo-core-function-obu-mogo/src/main/java/com/mogo/eagle/core/function/obu/mogo/MogoPrivateObuManager.kt b/core/function-impl/mogo-core-function-obu-mogo/src/main/java/com/mogo/eagle/core/function/obu/mogo/MogoPrivateObuManager.kt index 1be115a6a7..66988e4d97 100644 --- a/core/function-impl/mogo-core-function-obu-mogo/src/main/java/com/mogo/eagle/core/function/obu/mogo/MogoPrivateObuManager.kt +++ b/core/function-impl/mogo-core-function-obu-mogo/src/main/java/com/mogo/eagle/core/function/obu/mogo/MogoPrivateObuManager.kt @@ -375,6 +375,9 @@ class MogoPrivateObuManager private constructor() { ObuConstants.STATUS.ADD -> { //不显示弹框,其它保留 CallerLogger.d("$M_OBU${MogoObuConst.TAG_MOGO_OBU}", "old onCvxRtiThreatIndInfo ------> appId = $appId --- alertContent = $alertContent --- ttsContent = $ttsContent ") + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuManager4", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.OBU, @@ -508,6 +511,9 @@ class MogoPrivateObuManager private constructor() { //显示警告红边 CallerHmiManager.showWarning(direction) CallerLogger.d("$M_OBU${MogoObuConst.TAG_MOGO_OBU}", "old onCvxPtcThreatIndInfo ------> v2xType = $v2xType --- alertContent = $alertContent --- ttsContent = $ttsContent ") + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuManager5", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.OBU, @@ -729,6 +735,9 @@ class MogoPrivateObuManager private constructor() { ttsContent = EventTypeEnum.getWarningTts(appId.toString()) alertContent = EventTypeEnum.getWarningContent(appId.toString()) CallerLogger.d("$M_OBU${MogoObuConst.TAG_MOGO_OBU}", "old changeTrafficLightStatus ------> appId.toString() = ${appId.toString()} --- alertContent = $alertContent --- ttsContent = $ttsContent ") + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuManager1", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.OBU, @@ -803,6 +812,9 @@ class MogoPrivateObuManager private constructor() { val maxSpeed = currentLight.glosa_suggested_speed_max.toInt() if (maxSpeed > 0) { CallerLogger.d("$M_OBU${MogoObuConst.TAG_MOGO_OBU}", "old changeTrafficLightStatus ------> TYPE_USECASE_ID_IVP_GREEN --- alertContent = $alertContent --- ttsContent = $ttsContent ") + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuManager2", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.OBU, @@ -938,6 +950,9 @@ class MogoPrivateObuManager private constructor() { CallerLogger.d("$M_OBU${MogoObuConst.TAG_MOGO_OBU}", "old handleSdkObu appId2 = $appId --- level = $level ---ttsContent = $ttsContent --- alertContent = $alertContent --- direction = $direction" ) + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuManager3", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.OBU, diff --git a/core/function-impl/mogo-core-function-obu-mogo/src/main/java/com/mogo/eagle/core/function/obu/mogo/MogoPrivateObuNewManager.kt b/core/function-impl/mogo-core-function-obu-mogo/src/main/java/com/mogo/eagle/core/function/obu/mogo/MogoPrivateObuNewManager.kt index fcae6b1da0..ce58eb45db 100644 --- a/core/function-impl/mogo-core-function-obu-mogo/src/main/java/com/mogo/eagle/core/function/obu/mogo/MogoPrivateObuNewManager.kt +++ b/core/function-impl/mogo-core-function-obu-mogo/src/main/java/com/mogo/eagle/core/function/obu/mogo/MogoPrivateObuNewManager.kt @@ -407,6 +407,9 @@ class MogoPrivateObuNewManager private constructor() { //显示警告红边 // CallerHmiManager.showWarning(direction) //不显示弹框,语音提示,数据在消息盒子里面展示,此处不在处理弹框 + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuNewMana1", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.OBU, @@ -509,6 +512,9 @@ class MogoPrivateObuNewManager private constructor() { // if (level == 2 || level == 3) { //不考虑level //显示警告红边 CallerHmiManager.showWarning(direction) + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuNewMana2", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.OBU, @@ -738,6 +744,9 @@ class MogoPrivateObuNewManager private constructor() { "new handleSdkObu appId2 = $appId --- level = $level ---ttsContent = $ttsContent --- alertContent = $alertContent --- direction = $direction" ) if (level == 2 || level == 3) { + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuNewManager2", "alertContent或ttsContent为空!") + } //不显示弹框,其它保留 CallerMsgBoxManager.saveMsgBox( MsgBoxBean( @@ -888,6 +897,9 @@ class MogoPrivateObuNewManager private constructor() { val maxSpeed = currentLight.suggestMaxSpeed if (maxSpeed > 0) { + if (alertContent.isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-PriObuNewManager1", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.OBU, diff --git a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/V2XEventManager.kt b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/V2XEventManager.kt index 759be5b25f..86c0e3b634 100644 --- a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/V2XEventManager.kt +++ b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/V2XEventManager.kt @@ -557,7 +557,7 @@ object V2XEventManager : IMoGoMapLocationListener, IMoGoTokenCallback, IV2XCallb tempContent = EventTypeEnum.TYPE_USECASE_ID_IVP.content } 2001 -> { - // 最优车道 + // 最优车道100061 EventTypeHelper.getOptLine{ appId, tts, content -> tempAppId = appId tempTts = tts @@ -574,6 +574,9 @@ object V2XEventManager : IMoGoMapLocationListener, IMoGoTokenCallback, IV2XCallb } } // 不显示弹框,其它保留 + if (tempContent.isNullOrEmpty() || tempTts.isNullOrEmpty()) { + Log.d("MsgBox-V2XEventManager", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.V2X, diff --git a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/scenario/scene/road/V2XRoadEventScenario.java b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/scenario/scene/road/V2XRoadEventScenario.java index 1a2289cbbf..cf448413a1 100644 --- a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/scenario/scene/road/V2XRoadEventScenario.java +++ b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/scenario/scene/road/V2XRoadEventScenario.java @@ -2,6 +2,8 @@ package com.mogo.eagle.core.function.v2x.events.scenario.scene.road; import static com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.M_V2X; +import android.util.Log; + import com.mogo.commons.analytics.AnalyticsUtils; import com.mogo.eagle.core.data.enums.WarningDirectionEnum; import com.mogo.eagle.core.data.map.entity.MarkerExploreWay; @@ -98,6 +100,10 @@ public class V2XRoadEventScenario extends AbsV2XScenario imp V2XRoadEventEntity content = entity != null ? entity.getContent() : null; if (content != null) { // //显示警告红边 + if (content.getAlarmContent() == null || content.getAlarmContent().isEmpty() + || content.getTts() == null || content.getTts().isEmpty()) { + Log.d("MsgBox-V2XRoadScenario", "alertContent或ttsContent为空!"); + } CallerMsgBoxManager.INSTANCE.saveMsgBox( new MsgBoxBean( MsgBoxType.V2X, diff --git a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/scenario/scene/warning/V2XFrontWarningScenario.java b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/scenario/scene/warning/V2XFrontWarningScenario.java index b53b27f6ea..c4d1d6f357 100644 --- a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/scenario/scene/warning/V2XFrontWarningScenario.java +++ b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/events/scenario/scene/warning/V2XFrontWarningScenario.java @@ -6,6 +6,8 @@ import android.graphics.Color; import android.text.Spannable; import android.text.SpannableStringBuilder; import android.text.style.ForegroundColorSpan; +import android.util.Log; + import androidx.annotation.Nullable; import com.mogo.eagle.core.data.enums.WarningDirectionEnum; import com.mogo.eagle.core.data.map.MogoLocation; @@ -63,6 +65,11 @@ public class V2XFrontWarningScenario extends AbsV2XScenario implements IMoGoMapL int v2xType = getV2XTypeForFrontWarning(mMarkerEntity); V2XMessageEntity entity = getV2XMessageEntity(); if (v2xType != 0) { + if (getAlertContentForFrontWarning(mMarkerEntity).toString() == null + || getAlertContentForFrontWarning(mMarkerEntity).toString().isEmpty() + || mMarkerEntity.getTts() == null || mMarkerEntity.getTts().isEmpty()) { + Log.d("MsgBox-FrontWarScenario", "alertContent或ttsContent为空!"); + } CallerMsgBoxManager.INSTANCE.saveMsgBox( new MsgBoxBean( MsgBoxType.V2X, diff --git a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/redlightwarning/RedLightWarningManager.kt b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/redlightwarning/RedLightWarningManager.kt index 40c412f93e..49004bae3e 100644 --- a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/redlightwarning/RedLightWarningManager.kt +++ b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/redlightwarning/RedLightWarningManager.kt @@ -1,5 +1,6 @@ package com.mogo.eagle.core.function.v2x.redlightwarning +import android.util.Log import com.mogo.eagle.core.data.deva.bizconfig.FuncBizConfig.Companion.BIZ_IVP import com.mogo.eagle.core.data.deva.bizconfig.FuncBizConfig.Companion.BIZ_IVP_GREEN import com.mogo.eagle.core.data.deva.bizconfig.FuncBizConfig.Companion.V2I @@ -239,6 +240,9 @@ class RedLightWarningManager : IMoGoTrafficLightListener, IMoGoVipSetListener, EventTypeEnum.getWarningTts(EventTypeEnum.TYPE_USECASE_ID_IVP_GREEN.poiType), speed ) + if (content.isNullOrEmpty() || tts.isNullOrEmpty()) { + Log.d("MsgBox-RedLightWarManaG", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean( MsgBoxType.V2X, diff --git a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/vip/VipCarManager.kt b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/vip/VipCarManager.kt index f4659f54ab..61bd434cb7 100644 --- a/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/vip/VipCarManager.kt +++ b/core/function-impl/mogo-core-function-v2x/src/main/java/com/mogo/eagle/core/function/v2x/vip/VipCarManager.kt @@ -4,6 +4,7 @@ import android.content.Context import android.os.Handler import android.os.Looper import android.os.Message +import android.util.Log import com.mogo.aicloud.services.socket.IMogoOnMessageListener import com.mogo.aicloud.services.socket.MogoAiCloudSocketManager import com.mogo.cloud.passport.MoGoAiCloudClientConfig @@ -275,6 +276,9 @@ class VipCarManager : IMogoOnMessageListener, IMoGoTrafficLightListe ttsContent: String, tag: String ) { + if (alertContent.toString().isNullOrEmpty() || ttsContent.isNullOrEmpty()) { + Log.d("MsgBox-VipCarManager", "alertContent或ttsContent为空!") + } CallerMsgBoxManager.saveMsgBox( MsgBoxBean(MsgBoxType.V2X, V2XMsg(v2xType, alertContent.toString(), ttsContent)) )