diff --git a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/DataDistribution.java b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/DataDistribution.java index 49d225165e..b5141a1909 100644 --- a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/DataDistribution.java +++ b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/DataDistribution.java @@ -115,6 +115,8 @@ public class DataDistribution { public final List listObuRsi = new ArrayList<>(); public final List listObuRsm = new ArrayList<>(); public final List listObuMap = new ArrayList<>(); + public final List listV2nCongestionEvent = new ArrayList<>(); + public final List listV2nGlobalPathEvents = new ArrayList<>(); private long listTrajectorySize = 0; private long listTrackedObjectsSize = 0; @@ -143,7 +145,8 @@ public class DataDistribution { private long listObuRsiSize = 0; private long listObuRsmSize = 0; private long listObuMapSize = 0; - + private long listV2nCongestionEventSize = 0; + private long listV2nGlobalPathEventsSize = 0; public void clearCount() { listTrajectorySize = 1; @@ -173,6 +176,8 @@ public class DataDistribution { listObuRsiSize = 1; listObuRsmSize = 1; listObuMapSize = 1; + listV2nCongestionEventSize = 1; + listV2nGlobalPathEventsSize = 1; } public String cutDown(String str) { @@ -369,6 +374,22 @@ public class DataDistribution { if (listener != null && Constants.TITLE.RECEIVE_BACK_CAMERA_VIDEO.equals(listener.first)) { listener.second.onRefresh(); } + } else if (messageType == MessagePad.MessageType.MsgTypeV2nCongestionEvent) { + listV2nCongestionEvent.add(0, new DataShow(listV2nCongestionEventSize++, time + str)); + if (listV2nCongestionEvent.size() > LIST_SIZE) { + listV2nCongestionEvent.remove(listV2nCongestionEvent.size() - 1); + } + if (listener != null && Constants.TITLE.RECEIVE_V2N_CONGESTION_EVENT.equals(listener.first)) { + listener.second.onRefresh(); + } + } else if (messageType == MessagePad.MessageType.MsgTypeV2nGlobalPathEvents) { + listV2nGlobalPathEvents.add(0, new DataShow(listV2nGlobalPathEventsSize++, time + str)); + if (listV2nGlobalPathEvents.size() > LIST_SIZE) { + listV2nGlobalPathEvents.remove(listV2nGlobalPathEvents.size() - 1); + } + if (listener != null && Constants.TITLE.RECEIVE_V2N_GLOBAL_PATH_EVENTS.equals(listener.first)) { + listener.second.onRefresh(); + } } else if (data instanceof PerceptionTrafficLight) { listPerceptionTrafficLight.add(0, new DataShow(listPerceptionTrafficLightSize++, time + str)); if (listPerceptionTrafficLight.size() > LIST_SIZE) { diff --git a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/bean/V2nGlobalPathEventsReceiveData.java b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/bean/V2nGlobalPathEventsReceiveData.java new file mode 100644 index 0000000000..1dc55915a2 --- /dev/null +++ b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/bean/V2nGlobalPathEventsReceiveData.java @@ -0,0 +1,59 @@ +package com.zhidao.adas.client.bean; + +import com.google.protobuf.TextFormat; +import com.zhidao.support.adas.high.common.ByteUtil; + +import java.text.SimpleDateFormat; + +import mogo.telematics.pad.MessagePad; +import mogo.v2x.MogoV2X; +import mogo.v2x.RoadOverviewEvents; + +public class V2nGlobalPathEventsReceiveData extends BaseInfo { + public final RoadOverviewEvents.RoadOverviewData roadOverview; + public final MogoV2X.RSI_PB construct; + public final MogoV2X.RSI_PB triangle; + public final MogoV2X.RSI_PB congestion; + public final MogoV2X.RSM_PB parkingViolation; + + public V2nGlobalPathEventsReceiveData(MessagePad.Header header, RoadOverviewEvents.RoadOverviewData roadOverview, MogoV2X.RSI_PB construct, MogoV2X.RSI_PB triangle, MogoV2X.RSI_PB congestion, MogoV2X.RSM_PB parkingViolation, SimpleDateFormat sdf) { + super("接收", roadOverview.getSerializedSize(), header, sdf); + this.roadOverview = roadOverview; + this.construct = construct; + this.triangle = triangle; + this.congestion = congestion; + this.parkingViolation = parkingViolation; + } + + + @Override + public String toString() { + StringBuilder builder = new StringBuilder(); + builder.append('\n').append("施工:"); + if (construct != null) { + builder.append(TextFormat.printer().escapingNonAscii(false).printToString(construct)); + } else { + builder.append("null"); + } + builder.append('\n').append("三角牌:"); + if (triangle != null) { + builder.append(TextFormat.printer().escapingNonAscii(false).printToString(triangle)); + } else { + builder.append("null"); + } + builder.append('\n').append("拥堵:"); + if (congestion != null) { + builder.append(TextFormat.printer().escapingNonAscii(false).printToString(congestion)); + } else { + builder.append("null"); + } + builder.append('\n').append("违停:"); + if (parkingViolation != null) { + builder.append(TextFormat.printer().escapingNonAscii(false).printToString(parkingViolation)); + } else { + builder.append("null"); + } + return super.toString() + "Payload原始数据:" + ByteUtil.byteArrToHex(roadOverview.toByteArray()) + builder.toString(); + } + +} diff --git a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/ui/InfoFragment.java b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/ui/InfoFragment.java index cae37b48c3..def9da6227 100644 --- a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/ui/InfoFragment.java +++ b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/ui/InfoFragment.java @@ -227,6 +227,10 @@ public class InfoFragment extends BaseFragment { adapter.setData(DataDistribution.getInstance().listBackCameraVideo); } else if (Constants.TITLE.RECEIVE_SWEEPER_TASK_INDEX_DATA.equals(title)) { adapter.setData(DataDistribution.getInstance().listRoboSweeperTaskIndex); + } else if (Constants.TITLE.RECEIVE_V2N_CONGESTION_EVENT.equals(title)) { + adapter.setData(DataDistribution.getInstance().listV2nCongestionEvent); + } else if (Constants.TITLE.RECEIVE_V2N_GLOBAL_PATH_EVENTS.equals(title)) { + adapter.setData(DataDistribution.getInstance().listV2nGlobalPathEvents); } else { adapter.setData(DataDistribution.getInstance().listErrorData); } diff --git a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/ui/MainActivity.java b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/ui/MainActivity.java index 2b00adea2d..e6aa42d2a5 100644 --- a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/ui/MainActivity.java +++ b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/ui/MainActivity.java @@ -64,6 +64,7 @@ import com.zhidao.adas.client.bean.ReceiveBytesData; import com.zhidao.adas.client.bean.ReceiveData; import com.zhidao.adas.client.bean.SendCmd; import com.zhidao.adas.client.bean.SpecialVehicleBean; +import com.zhidao.adas.client.bean.V2nGlobalPathEventsReceiveData; import com.zhidao.adas.client.log.ConnectStatusSave; import com.zhidao.adas.client.log.LogSave; import com.zhidao.adas.client.other.permission.BackgrounderPermission; @@ -85,6 +86,7 @@ import com.zhidao.support.adas.high.common.RegexUtils; import com.zhjt.mogo.adas.data.bean.AutopilotStatistics; import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; import java.net.Inet4Address; import java.net.InetAddress; @@ -104,6 +106,8 @@ import chassis.ChassisStatesOuterClass; import chassis.VehicleStateOuterClass; import function_state_management.FunctionStates; import mogo.telematics.pad.MessagePad; +import mogo.v2x.MogoV2X; +import mogo.v2x.RoadOverviewEvents; import mogo_msg.MogoReportMsg; import perception.TrafficLightOuterClass; import planning.RoboSweeperTaskIndexOuterClass; @@ -711,6 +715,8 @@ public class MainActivity extends BaseActivity implements OnAdasListener, OnAdas titleFragmentData.add(Constants.TITLE.RECEIVE_OBU_MAP); titleFragmentData.add(Constants.TITLE.RECEIVE_SWEEPER_TASK_INDEX_DATA); titleFragmentData.add(Constants.TITLE.RECEIVE_BACK_CAMERA_VIDEO); + titleFragmentData.add(Constants.TITLE.RECEIVE_V2N_CONGESTION_EVENT); + titleFragmentData.add(Constants.TITLE.RECEIVE_V2N_GLOBAL_PATH_EVENTS); titleFragmentData.add(Constants.TITLE.RECEIVE_WARN); titleFragmentData.add(Constants.TITLE.RECEIVE_ERROR); @@ -1137,6 +1143,18 @@ public class MainActivity extends BaseActivity implements OnAdasListener, OnAdas DataDistribution.getInstance().addData(base); } + @Override + public void onV2nCongestionEvent(@NotNull MessagePad.Header header, @NotNull MogoV2X.RSI_PB rsi) { + ReceiveData base = new ReceiveData(header, rsi, sdf); + DataDistribution.getInstance().addData(base); + } + + @Override + public void onV2nGlobalPathEvents(@NotNull MessagePad.Header header, @NotNull RoadOverviewEvents.RoadOverviewData roadOverview, @Nullable MogoV2X.RSI_PB construct, @Nullable MogoV2X.RSI_PB triangle, @Nullable MogoV2X.RSI_PB congestion, @Nullable MogoV2X.RSM_PB parkingViolation) { + V2nGlobalPathEventsReceiveData base = new V2nGlobalPathEventsReceiveData(header, roadOverview, construct, triangle, congestion, parkingViolation, sdf); + DataDistribution.getInstance().addData(base); + } + private void initAdas() { CupidLogUtils.e(TAG, "--->初始化"); AdasOptions options; diff --git a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/utils/Constants.java b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/utils/Constants.java index ba0998ca62..6c743f2245 100644 --- a/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/utils/Constants.java +++ b/app_ipc_monitoring/src/main/java/com/zhidao/adas/client/utils/Constants.java @@ -162,6 +162,8 @@ public class Constants { String RECEIVE_PLANNING_OBJECTS = MessageType.TYPE_RECEIVE_PLANNING_OBJECTS.desc; String RECEIVE_PLANNING_DECISION_STATE = MessageType.TYPE_RECEIVE_PLANNING_DECISION_STATE.desc; String RECEIVE_SWEEPER_TASK_INDEX_DATA = MessageType.TYPE_RECEIVE_SWEEPER_TASK_INDEX_DATA.desc; + String RECEIVE_V2N_CONGESTION_EVENT = MessageType.TYPE_RECEIVE_V2N_CONGESTION_EVENT.desc; + String RECEIVE_V2N_GLOBAL_PATH_EVENTS = MessageType.TYPE_RECEIVE_V2N_GLOBAL_PATH_EVENTS.desc; // String RECEIVE_BASIC_INFO_REQ = "自动驾驶设备基础信息请求"; String TITLE_CAR_CONFIG_RESP = "工控机版本\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t配置"; diff --git a/core/function-impl/mogo-core-function-datacenter/src/main/java/com/mogo/eagle/core/function/datacenter/autopilot/adapter/MoGoAdasListenerImpl.kt b/core/function-impl/mogo-core-function-datacenter/src/main/java/com/mogo/eagle/core/function/datacenter/autopilot/adapter/MoGoAdasListenerImpl.kt index bc791705a3..68066f6bf9 100644 --- a/core/function-impl/mogo-core-function-datacenter/src/main/java/com/mogo/eagle/core/function/datacenter/autopilot/adapter/MoGoAdasListenerImpl.kt +++ b/core/function-impl/mogo-core-function-datacenter/src/main/java/com/mogo/eagle/core/function/datacenter/autopilot/adapter/MoGoAdasListenerImpl.kt @@ -65,6 +65,8 @@ import com.zhjt.service.chain.TracingConstants.Endpoint.Companion.PAD import function_state_management.FunctionStates import mogo.telematics.pad.MessagePad import mogo.telematics.pad.MessagePad.TrackedObject +import mogo.v2x.MogoV2X +import mogo.v2x.RoadOverviewEvents import mogo_msg.MogoReportMsg import perception.TrafficLightOuterClass import planning.RoboSweeperTaskIndexOuterClass @@ -631,6 +633,30 @@ class MoGoAdasListenerImpl : OnAdasListener { } } + /** + * 主车附近事件推送 + * + * @param header 头 + * @param rsi 数据 + */ + override fun onV2nCongestionEvent(header: MessagePad.Header, rsi: MogoV2X.RSI_PB) { + + } + + /** + * 主车路径全局事件推送 + * + * @param header 头 + * @param roadOverview 主车路径全局事件推送 + * @param construct 施工 + * @param triangle 三角牌 + * @param congestion 拥堵 + * @param parkingViolation 违停 ---包含 静态障碍车 + */ + override fun onV2nGlobalPathEvents(header: MessagePad.Header, roadOverview: RoadOverviewEvents.RoadOverviewData, construct: MogoV2X.RSI_PB?, triangle: MogoV2X.RSI_PB?, congestion: MogoV2X.RSI_PB?, parkingViolation: MogoV2X.RSM_PB?) { + + } + /** * 是否可以启动自动驾驶 * 使用方法查看:app_ipc_monitoring/uiMainActivity/onAutopilotAbility diff --git a/libraries/mogo-adas-data/src/main/proto/message_pad.proto b/libraries/mogo-adas-data/src/main/proto/message_pad.proto index ef5eaf508c..daa7cbe5e7 100644 --- a/libraries/mogo-adas-data/src/main/proto/message_pad.proto +++ b/libraries/mogo-adas-data/src/main/proto/message_pad.proto @@ -62,6 +62,8 @@ enum MessageType MsgTypeBagManagerCmd = 0x1011b; //bag管理 MsgTypePlanningCmd = 0x1011c; //给planning的指令 MsgTypeSetParamReqV2 = 0x1011d; //设置参数命令V2 + MsgTypeV2nCongestionEvent = 0x1011e; //主车附近拥堵事件推送, 透传 + MsgTypeV2nGlobalPathEvents = 0x1011f; //主车路径全局事件推送, 透传 } message Header @@ -629,3 +631,10 @@ message PlanningCmd //message definition for MsgTypeBackCameraVideo //payload:jpeg data + +//message definition for MsgTypeV2nCongestionEvent +//refer to RSI_PB in mogo_v2x.proto for details + +//message definition for MsgTypeV2nGlobalPathEvents +//refer to road_overview_events.proto for details + diff --git a/libraries/mogo-adas-data/src/main/proto/mogo_v2x.proto b/libraries/mogo-adas-data/src/main/proto/mogo_v2x.proto index 987485620f..429678a969 100644 --- a/libraries/mogo-adas-data/src/main/proto/mogo_v2x.proto +++ b/libraries/mogo-adas-data/src/main/proto/mogo_v2x.proto @@ -1,88 +1,573 @@ syntax = "proto2"; package mogo.v2x; +import "header.proto"; message VerticalOffset_PB{ - oneof VerticalOffset{ - int32 offset1 = 1; - int32 offset2 = 2; - int32 offset3 = 3; - int32 offset4 = 4; - int32 offset5 = 5; - int32 offset6 = 6; - int32 elevation = 7; - } + //-- Vertical Offset + //-- All below in steps of 10cm above or below the reference ellipsoid + //offset1 VertOffset-B07, -- with a range of +- 6.3 meters vertical + //offset2 VertOffset-B08, -- with a range of +- 12.7 meters vertical + //offset3 VertOffset-B09, -- with a range of +- 25.5 meters vertical + //offset4 VertOffset-B10, -- with a range of +- 51.1 meters vertical + //offset5 VertOffset-B11, -- with a range of +- 102.3 meters vertical + //offset6 VertOffset-B12, -- with a range of +- 204.7 meters vertical + //elevation Elevation -- with a range of -409.5 to + 6143.9 meters + oneof VerticalOffset{ + int32 offset1 = 1; + int32 offset2 = 2; + int32 offset3 = 3; + int32 offset4 = 4; + int32 offset5 = 5; + int32 offset6 = 6; + int32 elevation = 7; + } } message VehicleSize_PB { - required int32 width = 1; - required int32 length = 2; - optional int32 height = 3; + required int32 width = 1; + required int32 length = 2; + optional int32 height = 3; } message AccelerationSet4Way_PB { - required int32 lon = 1; - required int32 lat = 2; - required int32 vert = 3; - required int32 yaw = 4; + required int32 lon = 1; + required int32 lat = 2; + required int32 vert = 3; + required int32 yaw = 4; } ////////////////////////////////////////////////////////////////// //经纬度偏差,来描述一个坐标点的相对位置。约定偏差值等于真实值减去参考值。 //提供了 7 种尺度的描述方式 message PositionOffsetLL_PB{ - oneof PositionOffsetLL{ - Position_LL_24B position_LL1 = 1; - Position_LL_28B position_LL2 = 2; - Position_LL_32B position_LL3 = 3; - Position_LL_36B position_LL4 = 4; - Position_LL_44B position_LL5 = 5; - Position_LL_48B position_LL6 = 6; - Position_LLmD_64b position_LatLon = 7; - } + //position-LL1 Position-LL-24B, + //-- within +- 22.634554 meters of the reference position + //position-LL2 Position-LL-28B, + //-- within +- 90.571389 meters of the reference position + //position-LL3 Position-LL-32B, + //-- within +- 362.31873 meters of the reference position + //position-LL4 Position-LL-36B, + //-- within +- 01.449308 Kmeters of the reference position + //position-LL5 Position-LL-44B, + //-- within +- 23.189096 Kmeters of the reference position + //position-LL6 Position-LL-48B, + //-- within +- 92.756481 Kmeters of the reference position + //position-LatLon Position-LLmD-64b + oneof PositionOffsetLL{ + Position_LL_24B position_LL1 = 1; + Position_LL_28B position_LL2 = 2; + Position_LL_32B position_LL3 = 3; + Position_LL_36B position_LL4 = 4; + Position_LL_44B position_LL5 = 5; + Position_LL_48B position_LL6 = 6; + Position_LLmD_64b position_LatLon = 7; + } } + message Position_LL_24B{ - // (-2048..2047) - required int64 lon = 1; - required int64 lat = 2; + // (-2048..2047) + required int64 lon = 1; + required int64 lat = 2; } message Position_LL_28B{ - // (-8192..8191) - required int64 lon = 1; - required int64 lat = 2; + // (-8192..8191) + required int64 lon = 1; + required int64 lat = 2; } message Position_LL_32B{ - // (-32768..32767) - required int64 lon = 1; - required int64 lat = 2; + // (-32768..32767) + required int64 lon = 1; + required int64 lat = 2; } message Position_LL_36B{ - // (-131072..131071) - required int64 lon = 1; - required int64 lat = 2; + // (-131072..131071) + required int64 lon = 1; + required int64 lat = 2; } message Position_LL_44B{ - // (-2097152..2097151) - required int64 lon = 1; - required int64 lat = 2; + // (-2097152..2097151) + required int64 lon = 1; + required int64 lat = 2; } message Position_LL_48B{ - // (-8388608..8388607) - required int64 lon = 1; - required int64 lat = 2; + // (-8388608..8388607) + required int64 lon = 1; + required int64 lat = 2; } message Position_LLmD_64b{ - // 定义经度数值。东经为正,西经为负。 - //分辨率为1e-7°。 - required int64 lon = 1; - required int64 lat = 2; + // 定义经度数值。东经为正,西经为负。 + //分辨率为1e-7°。 + required int64 lon = 1; + required int64 lat = 2; } ////////////////////////////////////////////////////////////////// message PositionOffsetLLV_PB{ - required PositionOffsetLL_PB offsetLL = 1; + required PositionOffsetLL_PB offsetLL = 1; + optional VerticalOffset_PB offsetV = 2; +} - optional VerticalOffset_PB offsetV = 2; +/************************************************/ +message RoadSideInformation_PB { + //发送方为自己发送的同类消息,依次进行编号。编号数值为0~127,循环使用。 + //该数据字段用于接收方对来自同一发送方的同一类消息,进行连续收包的监控和丢包的统计。 + required int64 msgCnt = 1; + //数值用来表示当前年份,已经过去的总分钟数(UTC时间)。 + //其分辨率为1分钟。该数值配合DSecond数值,则可以表示以毫秒记的全年已过去的总时间。 + optional int64 moy = 2; + //RSU_ID + required String_PB id = 3; + //RSU 对应坐标 + required Position3D_PB refPos = 4; + //交通事件内容 + optional RTEList_PB rtes = 5; + //交通标志内容 + optional RTSList_PB rtss = 6; +} + +message String_PB { + required uint32 string_type = 1; + required string str_value = 2; +} + +message Position3D_PB { + required int64 lat = 1; + required int64 Long = 2; + optional int64 elevation = 3; +} + +message RTEList_PB { + //定义道路交通事件集合。 + //至少包含1个道路交通事件信息,最多包含8个。 + repeated RTEData_PB rteData = 1; +} + +message RTEData_PB { + //(0..255) + required int64 rteId = 1; + // required EventType_PB eventType=2; + required int32 eventType = 2; + required EventSource_PB eventSource = 3; + optional PositionOffsetLLV_PB eventPos = 4; + // 分辨率为10 cm。 + // (0..65535) + optional int64 eventRadius = 5; + //提供ASCII字符文本形式,支持长度1字节到512字节。该类型不提供 + //提供中文编码形式,符合GB2312-80的编码规则,1个中文字符由2字节信息编码,支持长度1到256 + //个中文字符 + //Description + optional String_PB description = 6; + + optional RSITimeDetails_PB timeDetails = 7; + // 表示RSI消息中不同类型交通事件或交通标志的优先级。数值长度占8位,其中低五位为0,为无效 + //位,高三位为有效数据位。数值有效范围是B00000000到B11100000,分别表示8档由低到高的优先级。 + //对应 RSIPriority + optional String_PB priority = 8; + optional ReferencePathList_PB referencePaths = 9; + optional ReferenceLinkList_PB referenceLinks = 10; + //定义置信度。 + //分辨率为0.005。 + // 0-200 + optional int32 eventConfidence = 11; +} + +message EventSource_PB { + //unknown(0), -- 0 Unknown + //police(1), -- 1 traffic police + //government(2), -- 2 govenment + //meteorological(3), -- 3 meteorological department + //internet(4), -- 4 internet services + //detection(5), -- 5 local detection + enum EventSource{ + EventSource_unknown = 0; + EventSource_police = 1; + EventSource_government = 2; + EventSource_meteorological = 3; + EventSource_internet = 4; + EventSource_detection = 5; + }; + required EventSource event_source = 1; +} + +message RSITimeDetails_PB{ + //数值用来表示当前年份,已经过去的总分钟数(UTC时间)。 + //其分辨率为1分钟。该数值配合DSecond数值,则可以表示以毫秒记的全年已过去的总时间。 + //(0..527040) + optional int64 startTime = 1; + optional int64 endTime = 2; + optional TimeConfidence_PB endTimeConfidence = 3; +} + +message TimeConfidence_PB { + //unavailable (0), -- Not Equipped or unavailable + //time-100-000 (1), -- Better than 100 Seconds + //time-050-000 (2), -- Better than 50 Seconds + //time-020-000 (3), -- Better than 20 Seconds + //time-010-000 (4), -- Better than 10 Seconds + //time-002-000 (5), -- Better than 2 Seconds + //time-001-000 (6), -- Better than 1 Second + //time-000-500 (7), -- Better than 0.5 Seconds + //time-000-200 (8), -- Better than 0.2 Seconds + //time-000-100 (9), -- Better than 0.1 Seconds + //time-000-050 (10), -- Better than 0.05 Seconds + //time-000-020 (11), -- Better than 0.02 Seconds + //time-000-010 (12), -- Better than 0.01 Seconds + //time-000-005 (13), -- Better than 0.005 Seconds + //time-000-002 (14), -- Better than 0.002 Seconds + //time-000-001 (15), -- Better than 0.001 Seconds + //-- Better than one millisecond + //time-000-000-5 (16), -- Better than 0.000,5 Seconds + //time-000-000-2 (17), -- Better than 0.000,2 Seconds + //time-000-000-1 (18), -- Better than 0.000,1 Seconds + //time-000-000-05 (19), -- Better than 0.000,05 Seconds + //time-000-000-02 (20), -- Better than 0.000,02 Seconds + //time-000-000-01 (21), -- Better than 0.000,01 Seconds + //time-000-000-005 (22), -- Better than 0.000,005 Seconds + //time-000-000-002 (23), -- Better than 0.000,002 Seconds + //time-000-000-001 (24), -- Better than 0.000,001 Seconds + //-- Better than one micro second + //time-000-000-000-5 (25), -- Better than 0.000,000,5 Seconds + //time-000-000-000-2 (26), -- Better than 0.000,000,2 Seconds + //time-000-000-000-1 (27), -- Better than 0.000,000,1 Seconds + //time-000-000-000-05 (28), -- Better than 0.000,000,05 Seconds + //time-000-000-000-02 (29), -- Better than 0.000,000,02 Seconds + //time-000-000-000-01 (30), -- Better than 0.000,000,01 Seconds + //time-000-000-000-005 (31), -- Better than 0.000,000,005 Seconds + //time-000-000-000-002 (32), -- Better than 0.000,000,002 Seconds + //time-000-000-000-001 (33), -- Better than 0.000,000,001 Seconds + //-- Better than one nano second + //time-000-000-000-000-5 (34), -- Better than 0.000,000,000,5 Seconds + //time-000-000-000-000-2 (35), -- Better than 0.000,000,000,2 Seconds + //time-000-000-000-000-1 (36), -- Better than 0.000,000,000,1 Seconds + //time-000-000-000-000-05 (37), -- Better than 0.000,000,000,05 Seconds + //time-000-000-000-000-02 (38), -- Better than 0.000,000,000,02 Seconds + //time-000-000-000-000-01 (39) -- Better than 0.000,000,000,01 Seconds + enum TimeConfidence { + TimeConfidence_unavailable = 0; + TimeConfidence_time_100_000 = 1; + TimeConfidence_time_050_000 = 2; + TimeConfidence_time_020_000 = 3; + TimeConfidence_time_010_000 = 4; + TimeConfidence_time_002_000 = 5; + TimeConfidence_time_001_000 = 6; + TimeConfidence_time_000_500 = 7; + TimeConfidence_time_000_200 = 8; + TimeConfidence_time_000_100 = 9; + TimeConfidence_time_000_050 = 10; + TimeConfidence_time_000_020 = 11; + TimeConfidence_time_000_010 = 12; + TimeConfidence_time_000_005 = 13; + TimeConfidence_time_000_002 = 14; + TimeConfidence_time_000_001 = 15; + TimeConfidence_time_000_000_5 = 16; + TimeConfidence_time_000_000_2 = 17; + TimeConfidence_time_000_000_1 = 18; + TimeConfidence_time_000_000_05 = 19; + TimeConfidence_time_000_000_02 = 20; + TimeConfidence_time_000_000_01 = 21; + TimeConfidence_time_000_000_005 = 22; + TimeConfidence_time_000_000_002 = 23; + TimeConfidence_time_000_000_001 = 24; + TimeConfidence_time_000_000_000_5 = 25; + TimeConfidence_time_000_000_000_2 = 26; + TimeConfidence_time_000_000_000_1 = 27; + TimeConfidence_time_000_000_000_05 = 28; + TimeConfidence_time_000_000_000_02 = 29; + TimeConfidence_time_000_000_000_01 = 30; + TimeConfidence_time_000_000_000_005 = 31; + TimeConfidence_time_000_000_000_002 = 32; + TimeConfidence_time_000_000_000_001 = 33; + TimeConfidence_time_000_000_000_000_5 = 34; + TimeConfidence_time_000_000_000_000_2 = 35; + TimeConfidence_time_000_000_000_000_1 = 36; + TimeConfidence_time_000_000_000_000_05 = 37; + TimeConfidence_time_000_000_000_000_02 = 38; + TimeConfidence_time_000_000_000_000_01 = 39; + }; + optional TimeConfidence time_confidence = 1; + +} + +message ReferencePathList_PB { + //SIZE(1..8) + repeated ReferencePath_PB referencePath = 1; +} + +message ReferenceLinkList_PB { + //(1-16) + repeated ReferenceLink_PB ReferenceLink = 1; +} + +message RTSList_PB { + //定义道路交通标志集合。 + //至少包含1个道路交通标志信息,最多包含16个 + repeated RTSData_PB rtsData = 1; +} + +message RTSData_PB { + //(0..255) + required int64 rtsId = 1; + // required SignType_PB signType=2; + required int32 signType = 2; + optional PositionOffsetLLV_PB signPos = 3; + optional String_PB description = 4; + optional RSITimeDetails_PB timeDetails = 5; + optional String_PB priority = 6; + optional ReferencePathList_PB referencePaths = 7; + optional ReferenceLinkList_PB referenceLinks = 8; +} + +message ReferencePath_PB { + required PathPointList_PB activePath = 1; + //表示绝对值半径大小。 + //分辨率为10 cm。 + //(0..65535) + required int64 pathRadius = 2; +} + +message PathPointList_PB { + //(1..32)) + repeated PositionOffsetLLV_PB offsetLLV = 1; +} + +message ReferenceLink_PB { + required NodeReferenceID_PB upstreamNodeId = 1; + required NodeReferenceID_PB downstreamNodeId = 2; + optional ReferenceLanes_PB referenceLanes = 3; +} + +message NodeReferenceID_PB { + //0-65535 + optional int64 region = 1; + //0-65535 + required int64 id = 2; +} + +message ReferenceLanes_PB { + enum ReferenceLanesType{ + ReferenceLanesType_reserved = 0; + ReferenceLanesType_lane1 = 1; + ReferenceLanesType_lane2 = 2; + ReferenceLanesType_lane3 = 3; + ReferenceLanesType_lane4 = 4; + ReferenceLanesType_lane5 = 5; + ReferenceLanesType_lane6 = 6; + ReferenceLanesType_lane7 = 7; + ReferenceLanesType_lane8 = 8; + ReferenceLanesType_lane9 = 9; + ReferenceLanesType_lane10 = 10; + ReferenceLanesType_lane11 = 11; + ReferenceLanesType_lane12 = 12; + ReferenceLanesType_lane13 = 13; + ReferenceLanesType_lane14 = 14; + ReferenceLanesType_lane15 = 15; + }; + required ReferenceLanesType lane = 1; +} + +message RSI_PB { + required RoadSideInformation_PB rsiFrame = 1; + optional common.Header header = 2; } + + + +message VehicleClassification_PB { + required int32 classification = 1; + optional int32 fuelType = 2; +} + +message MotionConfidenceSet_PB { + enum SpeedConfidence_PB { + SpeedConfidence_unavailable = 0; + SpeedConfidence_prec100ms = 1; + SpeedConfidence_prec10ms = 2; + SpeedConfidence_prec5ms = 3; + SpeedConfidence_prec1ms = 4; + SpeedConfidence_prec0_1ms = 5; + SpeedConfidence_prec0_05ms = 6; + SpeedConfidence_prec0_01ms = 7; + } + optional SpeedConfidence_PB speedCfd = 1; + enum HeadingConfidence_PB { + HeadingConfidence_unavailable = 0; + HeadingConfidence_prec10deg = 1; + HeadingConfidence_prec05deg = 2; + HeadingConfidence_prec01deg = 3; + HeadingConfidence_prec0_d1deg = 4; + HeadingConfidence_prec0_d05deg = 5; + HeadingConfidence_prec0_d01deg = 6; + HeadingConfidence_prec0_d0125deg = 7; + } + optional HeadingConfidence_PB headingCfd = 2; + enum SteeringWheelAngleConfidence_PB { + SteeringWheelAngleConfidence_unavailable = 0; + SteeringWheelAngleConfidence_prec2deg = 1; + SteeringWheelAngleConfidence_prec1deg = 2; + SteeringWheelAngleConfidence_prec0_02deg = 3; + } + optional SteeringWheelAngleConfidence_PB steerCfd = 3; +} + + +message TransmissionState_PB{ + // neutral (0), -- Neutral + //park (1), -- Park + //forwardGears (2), -- Forward gears + //reverseGears (3), -- Reverse gears + //reserved1 (4), + //reserved2 (5), + //reserved3 (6), + //unavailable (7)-- not-equipped or unavailable value, + //-- Any related speed is relative to the vehicle reference frame used + enum TransmissionState{ + TransmissionState_neutral = 1; + TransmissionState_park = 2; + TransmissionState_forwardGears = 3; + TransmissionState_reverseGears = 4; + TransmissionState_reserved1 = 5; + TransmissionState_reserved2 = 6; + TransmissionState_reserved3 = 7; + TransmissionState_unavailable = 8; + }; + required TransmissionState transmission_state = 1; +} + +message PositionConfidenceSet_PB { + enum PositionConfidence_PB { + PositionConfidence_unavailable = 0; + PositionConfidence_a500m = 1; + PositionConfidence_a200m = 2; + PositionConfidence_a100m = 3; + PositionConfidence_a50m = 4; + PositionConfidence_a20m = 5; + PositionConfidence_a10m = 6; + PositionConfidence_a5m = 7; + PositionConfidence_a2m = 8; + PositionConfidence_a1m = 9; + PositionConfidence_a50cm = 10; + PositionConfidence_a20cm = 11; + PositionConfidence_a10cm = 12; + PositionConfidence_a5cm = 13; + PositionConfidence_a2cm = 14; + PositionConfidence_a1cm = 15; + } + required PositionConfidence_PB poscon = 1; + + enum ElevationConfidence_PB { + ElevationConfidence_unavailable = 0; + ElevationConfidence_elev_500_00 = 1; + ElevationConfidence_elev_200_00 = 2; + ElevationConfidence_elev_100_00 = 3; + ElevationConfidence_elev_050_00 = 4; + ElevationConfidence_elev_020_00 = 5; + ElevationConfidence_elev_010_00 = 6; + ElevationConfidence_elev_005_00 = 7; + ElevationConfidence_elev_002_00 = 8; + ElevationConfidence_elev_001_00 = 9; + ElevationConfidence_elev_000_50 = 10; + ElevationConfidence_elev_000_20 = 11; + ElevationConfidence_elev_000_10 = 12; + ElevationConfidence_elev_000_05 = 13; + ElevationConfidence_elev_000_02 = 14; + ElevationConfidence_elev_000_01 = 15; + } + optional ElevationConfidence_PB elevationCon = 2; +} + +message SourceType_PB{ + //定义交通参与者数据的来源。包括以下类型: + //——unknown:未知数据源类型; + //——selfinfo:RSU 自身信息; + //——v2x:来源于参与者自身的 v2x 广播消息; + //——video:来源于视频传感器; + //——microwaveRadar:来源于微波雷达传感器; + //——loop:来源于地磁线圈传感器; + //——lidar:来源于激光雷达传感器; + //——integrated:2 类或以上感知数据的融合结果。 + enum SourceType{ + SourceType_unknown = 1; + SourceType_selfinfo = 2; + SourceType_v2x = 3; + SourceType_video = 4; + SourceType_microwaveRadar = 5; + SourceType_loop = 6; + SourceType_lidar = 7; + SourceType_integrated = 8; + }; + required SourceType source_type = 1; +} + + +message ParticipantData_PB{ + //ptcType ParticipantType, + //ptcId INTEGER (0..65535), + //-- temporary ID set by RSU + //-- 0 is RSU itself + //-- 1..255 represent participants detected by RSU + //-- ptcId of different participant needs to be unique in RSU + //source SourceType, + //id OCTET STRING (SIZE(8)) OPTIONAL, + //-- temperary vehicle ID from BSM + //secMark DSecond, + //pos PositionOffsetLLV, + //posConfidence PositionConfidenceSet, + //transmission TransmissionState OPTIONAL, + //speed Speed, + //heading Heading, + //angle SteeringWheelAngle OPTIONAL, + //motionCfd MotionConfidenceSet OPTIONAL, + //accelSet AccelerationSet4Way OPTIONAL, + //size VehicleSize, + //-- Size of participant including motor/non-motor/pedestrian/rsu + //-- is represented by DE_VehilceSize + //vehicleClass VehicleClassification OPTIONAL, + + // required ParticipantType_PB ptcType = 1; + required int64 ptcType = 1; + required int32 ptcId = 2;//不同参与者的ptcId在RSU中需要是唯一的, + required SourceType_PB source = 3; + optional String_PB id = 4; // 车的临时id,跟BSM消息一致 + /* DSecond */ //1分钟内的毫秒级时刻分辨率为1毫秒,有效范围时0~59999.60000及以上表示未知或无效数值 + required int64 secMark = 5; + required PositionOffsetLLV_PB pos = 6; // 中心位置 + required PositionConfidenceSet_PB posConfidence = 7; + optional TransmissionState_PB transmission = 8; // 车辆挡位 + //速度 0.02m/s + required int32 speed = 9; + //航向角 + required int32 heading = 10; + //SteeringWheelAngle_t 方向盘转角(-126..127) + optional int32 angle = 11; + optional MotionConfidenceSet_PB motionCfd = 12; + optional AccelerationSet4Way_PB accelSet = 13; + required VehicleSize_PB size = 14; + optional VehicleClassification_PB vehicleClass = 15; +} + +message ParticipantList_PB{ + // 定义交通参与者列表。应用于RSM消息中,表示RSU当前探测到的所有或者部分交通参与者信息 + // size 为1-16个 + repeated ParticipantData_PB participantData = 1; +} + +message RoadsideSafetyMessage_PB { + /* MsgCount */ + //发送方为自己发送的同类消息,依次进行编号。编号数值为 0 ~ 127。 + //当发送方开始发起某一类数据时,它可以随机选择起始编号,随后依次递增。发送方也可以在 + //连续发送相同的数据帧时,选择使用相同的 MsgCount 消息编号。编号到达 127 后,则下一个回到 0。 + required int64 msgCnt = 1; + required String_PB id = 2; //RSU_ID + required Position3D_PB refPos = 3; // 三维坐标 + required ParticipantList_PB participants = 4; //交通参与者信息 +} + + +message RSM_PB { + required RoadsideSafetyMessage_PB rsmFrame = 1; + optional common.Header header = 2; +} + diff --git a/libraries/mogo-adas-data/src/main/proto/road_overview_events.proto b/libraries/mogo-adas-data/src/main/proto/road_overview_events.proto new file mode 100644 index 0000000000..77e8e653b4 --- /dev/null +++ b/libraries/mogo-adas-data/src/main/proto/road_overview_events.proto @@ -0,0 +1,11 @@ +syntax = "proto3"; +package mogo.v2x; + +message RoadOverviewData { + uint64 msgId = 1; // 消息ID + uint64 timestamp = 2; //unix时间戳 + bytes constructData= 3; //施工 RSI_PB + bytes triangleData= 4; //三角牌 RSI_PB + bytes congestionData= 5; //拥堵 RSI_PB + bytes parkingViolationData= 6; //违停 ---包含 静态障碍车 RSM_PB +} diff --git a/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/OnAdasListener.java b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/OnAdasListener.java index a979279247..d78445c63b 100644 --- a/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/OnAdasListener.java +++ b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/OnAdasListener.java @@ -5,12 +5,15 @@ import com.zhidao.support.adas.high.common.ProtocolStatus; import com.zhjt.mogo.adas.data.bean.AutopilotStatistics; import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; import bag_manager.BagManagerOuterClass; import chassis.ChassisStatesOuterClass; import chassis.VehicleStateOuterClass; import function_state_management.FunctionStates; import mogo.telematics.pad.MessagePad; +import mogo.v2x.MogoV2X; +import mogo.v2x.RoadOverviewEvents; import mogo_msg.MogoReportMsg; import perception.TrafficLightOuterClass; import planning.RoboSweeperTaskIndexOuterClass; @@ -261,6 +264,26 @@ public interface OnAdasListener { */ void onBagManagerCmd(MessagePad.Header header, BagManagerOuterClass.BagManager bagManager); + /** + * 主车附近事件推送 + * + * @param header 头 + * @param rsi 数据 + */ + void onV2nCongestionEvent(@NotNull MessagePad.Header header, @NotNull MogoV2X.RSI_PB rsi); + + /** + * 主车路径全局事件推送 + * + * @param header 头 + * @param roadOverview 主车路径全局事件推送 + * @param construct 施工 + * @param triangle 三角牌 + * @param congestion 拥堵 + * @param parkingViolation 违停 ---包含 静态障碍车 + */ + void onV2nGlobalPathEvents(@NotNull MessagePad.Header header, @NotNull RoadOverviewEvents.RoadOverviewData roadOverview, @Nullable MogoV2X.RSI_PB construct, @Nullable MogoV2X.RSI_PB triangle, @Nullable MogoV2X.RSI_PB congestion, MogoV2X.RSM_PB parkingViolation); + /** * 是否有能力启动自动驾驶 * diff --git a/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/common/MessageType.java b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/common/MessageType.java index 1e4ab16c9b..1372784e3f 100644 --- a/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/common/MessageType.java +++ b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/common/MessageType.java @@ -60,6 +60,8 @@ public enum MessageType { TYPE_RECEIVE_BAG_MANAGER_CMD(MessagePad.MessageType.MsgTypeBagManagerCmd, "Bag管理应答"), TYPE_SEND_PLANNING_CMD(MessagePad.MessageType.MsgTypePlanningCmd, "给Planning指令"), TYPE_SEND_SET_PARAM_REQ_V2(MessagePad.MessageType.MsgTypeSetParamReqV2, "设置参数命令V2"), + TYPE_RECEIVE_V2N_CONGESTION_EVENT(MessagePad.MessageType.MsgTypeV2nCongestionEvent, "主车附近事件推送"), + TYPE_RECEIVE_V2N_GLOBAL_PATH_EVENTS(MessagePad.MessageType.MsgTypeV2nGlobalPathEvents, "主车路径全局事件推送"), //TODO 透传原始pb文件中不存在以下type。由于Java中无法强转,所以在mogo-adas-data/message_pad.proto中放开注释 TYPE_RECEIVE_PLANNING_DECISION_STATE(MessagePad.MessageType.MsgTypePlanningDecisionState, "Planning决策状态"), TYPE_RECEIVE_SWEEPER_TASK_INDEX_DATA(MessagePad.MessageType.MsgTypeSweeperTaskIndexData, "清扫车指标数据"), diff --git a/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/MyMessageFactory.java b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/MyMessageFactory.java index 1597921140..00c6b36f15 100644 --- a/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/MyMessageFactory.java +++ b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/MyMessageFactory.java @@ -38,6 +38,8 @@ public class MyMessageFactory implements IMyMessageFactory { private IMsg bagManagerMessage;//Bag管理应答 private IMsg backCameraVideoMessage;//清扫车后摄像头 private IMsg pointCloudMessage;//3D点云 + private IMsg v2nCongestionEventMessage;//主车附近事件推送 + private IMsg v2nGlobalPathEventsMessage;//主车路径全局事件推送 private final AutopilotReview autopilotReview; @@ -197,6 +199,18 @@ public class MyMessageFactory implements IMyMessageFactory { backCameraVideoMessage = new BackCameraVideoMessage(); } return backCameraVideoMessage; + } else if (messageType == MessageType.TYPE_RECEIVE_V2N_CONGESTION_EVENT.typeCode) { + //主车附近事件推送 + if (v2nCongestionEventMessage == null) { + v2nCongestionEventMessage = new V2nCongestionEventMessage(); + } + return v2nCongestionEventMessage; + } else if (messageType == MessageType.TYPE_RECEIVE_V2N_GLOBAL_PATH_EVENTS.typeCode) { + //主车路径全局事件推送 + if (v2nGlobalPathEventsMessage == null) { + v2nGlobalPathEventsMessage = new V2nGlobalPathEventsMessage(); + } + return v2nGlobalPathEventsMessage; } else { //MessageType.TYPE_DEFAULT.typeCode return null; diff --git a/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/V2nCongestionEventMessage.java b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/V2nCongestionEventMessage.java new file mode 100644 index 0000000000..a643ba43d4 --- /dev/null +++ b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/V2nCongestionEventMessage.java @@ -0,0 +1,31 @@ +package com.zhidao.support.adas.high.msg; + + +import android.os.SystemClock; + +import com.google.protobuf.InvalidProtocolBufferException; +import com.zhidao.support.adas.high.AdasChannel; +import com.zhidao.support.adas.high.OnAdasListener; +import com.zhidao.support.adas.high.common.CupidLogUtils; +import com.zhidao.support.adas.high.protocol.RawData; + +import mogo.v2x.MogoV2X; + +/** + * 主车附近事件推送 + */ +public class V2nCongestionEventMessage extends MyAbstractMessageHandler { + + @Override + public void handlerMsg(RawData raw, OnAdasListener adasListener) throws InvalidProtocolBufferException { + MogoV2X.RSI_PB rsi = MogoV2X.RSI_PB.parser().parseFrom(raw.originalData.toByteArray(), raw.getOffsetValue(), raw.getPackageLengthValue() - raw.getOffsetValue()); + AdasChannel.calculateTimeConsumingOnDispatchRaw("主车附近事件推送", raw.receiveTime); + long nowTime = 0; + if (CupidLogUtils.isEnableLog()) + nowTime = SystemClock.elapsedRealtime(); + if (adasListener != null) { + adasListener.onV2nCongestionEvent(raw.getHeader(), rsi); + } + AdasChannel.calculateTimeConsumingBusiness("主车附近事件推送", nowTime); + } +} diff --git a/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/V2nGlobalPathEventsMessage.java b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/V2nGlobalPathEventsMessage.java new file mode 100644 index 0000000000..12fc1684d0 --- /dev/null +++ b/libraries/mogo-adas/src/main/java/com/zhidao/support/adas/high/msg/V2nGlobalPathEventsMessage.java @@ -0,0 +1,57 @@ +package com.zhidao.support.adas.high.msg; + + +import android.os.SystemClock; + +import com.google.protobuf.ByteString; +import com.google.protobuf.InvalidProtocolBufferException; +import com.zhidao.support.adas.high.AdasChannel; +import com.zhidao.support.adas.high.OnAdasListener; +import com.zhidao.support.adas.high.common.CupidLogUtils; +import com.zhidao.support.adas.high.protocol.RawData; + +import mogo.v2x.MogoV2X; +import mogo.v2x.RoadOverviewEvents; + +/** + * 主车路径全局事件推送 + */ +public class V2nGlobalPathEventsMessage extends MyAbstractMessageHandler { + + @Override + public void handlerMsg(RawData raw, OnAdasListener adasListener) throws InvalidProtocolBufferException { + RoadOverviewEvents.RoadOverviewData roadOverview = RoadOverviewEvents.RoadOverviewData.parser().parseFrom(raw.originalData.toByteArray(), raw.getOffsetValue(), raw.getPackageLengthValue() - raw.getOffsetValue()); + MogoV2X.RSI_PB construct = null; + MogoV2X.RSI_PB triangle = null; + MogoV2X.RSI_PB congestion = null; + MogoV2X.RSM_PB parkingViolation = null; + //施工 RSI_PB + ByteString constructData = roadOverview.getConstructData(); + if (!constructData.isEmpty()) { + construct = MogoV2X.RSI_PB.parseFrom(constructData); + } + //三角牌 RSI_PB + ByteString triangleData = roadOverview.getTriangleData(); + if (!triangleData.isEmpty()) { + triangle = MogoV2X.RSI_PB.parseFrom(triangleData); + } + //拥堵 RSI_PB + ByteString congestionData = roadOverview.getCongestionData(); + if (!congestionData.isEmpty()) { + congestion = MogoV2X.RSI_PB.parseFrom(congestionData); + } + //违停 ---包含 静态障碍车 RSM_PB + ByteString parkingViolationData = roadOverview.getParkingViolationData(); + if (!parkingViolationData.isEmpty()) { + parkingViolation = MogoV2X.RSM_PB.parseFrom(parkingViolationData); + } + AdasChannel.calculateTimeConsumingOnDispatchRaw("主车路径全局事件推送", raw.receiveTime); + long nowTime = 0; + if (CupidLogUtils.isEnableLog()) + nowTime = SystemClock.elapsedRealtime(); + if (adasListener != null) { + adasListener.onV2nGlobalPathEvents(raw.getHeader(), roadOverview, construct, triangle, congestion, parkingViolation); + } + AdasChannel.calculateTimeConsumingBusiness("主车路径全局事件推送", nowTime); + } +}