From 49eaecb096e034c17b5d20be0e27f36f9fbb92a6 Mon Sep 17 00:00:00 2001 From: xuxinchao Date: Mon, 17 Apr 2023 12:32:52 +0800 Subject: [PATCH] =?UTF-8?q?[dev=5Frobobus-d=5F230413=5F3.1.0]fix=E4=B8=8D?= =?UTF-8?q?=E5=A4=84=E4=BA=8E=E5=B9=B3=E8=A1=8C=E9=A9=BE=E9=A9=B6=E7=8A=B6?= =?UTF-8?q?=E6=80=81=E4=B8=8B=E5=BC=B1=E7=BD=91=E4=B9=9F=E6=8F=90=E7=A4=BA?= =?UTF-8?q?=E5=B9=B3=E8=A1=8C=E9=A9=BE=E9=A9=B6=E6=8E=A5=E7=AE=A1=E8=A1=A5?= =?UTF-8?q?=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../eagle/core/function/hmi/ui/vehicle/TakeOverView.kt | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/vehicle/TakeOverView.kt b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/vehicle/TakeOverView.kt index b54aeaf049..179f964123 100644 --- a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/vehicle/TakeOverView.kt +++ b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/vehicle/TakeOverView.kt @@ -34,6 +34,8 @@ class TakeOverView @JvmOverloads constructor( } private var autopilotStatus: Int = 0 //自动驾驶状态 0代表不可自动驾驶,1代表可自动驾驶,2代表自动驾驶中,7:平行驾驶中 + private var isParallel: Boolean = false //是否是平行驾驶 + init { LayoutInflater.from(context).inflate(R.layout.view_take_over, this, true) @@ -53,6 +55,11 @@ class TakeOverView @JvmOverloads constructor( */ override fun onAutopilotStatusResponse(autoPilotStatusInfo: AutopilotStatusInfo) { autopilotStatus = autoPilotStatusInfo.state + if(autoPilotStatusInfo.state == 7){ + isParallel = true + }else if(autoPilotStatusInfo.state == 2){ + isParallel = false + } Log.i(TAG,"自动驾驶状态${autopilotStatus}") } @@ -106,7 +113,7 @@ class TakeOverView @JvmOverloads constructor( MogoReport.Code.Error.EMAP.EPARALLEL_AICLOUD_CONNECTION_ERROR -> { //如果是平行驾驶状态下,提示弱网接管 Log.i(TAG,"弱网时自动驾驶状态:${autopilotStatus}") - if(autopilotStatus == 7){ + if(autopilotStatus == 7 || isParallel){ CallerHmiManager.warningV2X( EventTypeEnumNew.NETWORK_WEAK_EVENT.poiType, EventTypeEnumNew.NETWORK_WEAK_EVENT.content,