完成新架构的域控制器的监听及数据改造

Signed-off-by: 董宏宇 <martindhy@gmail.com>
This commit is contained in:
董宏宇
2021-10-18 19:16:41 +08:00
parent a4650ca514
commit 8a3e122518
76 changed files with 1895 additions and 1516 deletions

View File

@@ -1,9 +1,9 @@
package com.mogo.service.adas;
import com.alibaba.android.arouter.facade.template.IProvider;
import com.mogo.eagle.core.data.autopilot.AutoPilotControlParameters;
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
import com.mogo.eagle.core.data.traffic.TrafficData;
import com.mogo.map.uicontroller.EnumMapUI;
import com.mogo.service.adas.entity.ADASRecognizedResult;
import java.util.List;
@@ -57,7 +57,7 @@ public interface IMogoADASController extends IProvider {
*
* @param result
*/
void aiCloudToAdasData(AutoPilotControlParameters result);
void aiCloudToAdasData(AutopilotControlParameters result);
/**
* 添加adas数据回调接口
@@ -183,6 +183,6 @@ public interface IMogoADASController extends IProvider {
*/
void cancelAutopilot();
void mockAdasRecognized(List<ADASRecognizedResult> recognizedResults);
void mockAdasRecognized(List<TrafficData> recognizedResults);
}

View File

@@ -1,6 +1,6 @@
package com.mogo.service.adas;
import com.mogo.service.adas.entity.ADASCarStateInfo;
import com.mogo.eagle.core.data.autopilot.AutopilotCarStateInfo;
/**
* adas 自车位置数据回调
@@ -13,5 +13,5 @@ public interface IMogoAdasCarDataCallback {
*
* @param msg 具体数据
*/
void onAdasCarDataCallback( ADASCarStateInfo msg );
void onAdasCarDataCallback( AutopilotCarStateInfo msg );
}

View File

@@ -1,6 +1,6 @@
package com.mogo.service.adas;
import com.mogo.eagle.core.data.autopilot.AutoPilotStationInfo;
import com.mogo.eagle.core.data.autopilot.AutopilotStationInfo;
public
/**
@@ -29,7 +29,7 @@ interface IMogoAdasOCHCallback {
* 到站
* @param data 所到车站的简单信息
*/
void onArriveAt( AutoPilotStationInfo data );
void onArriveAt( AutopilotStationInfo data );
/**
* 自动驾驶状态发生改变

View File

@@ -1,7 +1,7 @@
package com.mogo.service.adas;
import com.mogo.service.adas.entity.ADASRecognizedResult;
import com.mogo.eagle.core.data.traffic.TrafficData;
import java.util.List;
@@ -16,5 +16,5 @@ public interface IMogoAdasRecognizedDataCallback {
*
* @param resultList 具体识别的物体数据
*/
void onAdasDataCallback(List<ADASRecognizedResult> resultList);
void onAdasDataCallback(List<TrafficData> resultList);
}

View File

@@ -1,6 +1,6 @@
package com.mogo.service.adas;
import com.mogo.service.adas.entity.ADASWarnMessage;
import com.mogo.eagle.core.data.autopilot.AutopilotWarnMessage;
/**
* adas 数据回调接口
@@ -12,5 +12,5 @@ public interface IMogoAdasWarnMessageCallback {
* adas 数据回调
* @param msg 具体数据
*/
void onReceiveData( ADASWarnMessage msg );
void onReceiveData( AutopilotWarnMessage msg );
}

View File

@@ -1,64 +0,0 @@
package com.mogo.service.adas;
public
/**
* @author congtaowang
* @since 2020/10/25
*
* 描述
*/
interface MogoADASWarnType {
/**
* 行人报警
*/
int ADAS_WARNING_PERSON = 16;
/**
* 前车起步
*/
int ADAS_WARNING_FRONT_CAR_GO = 17;
/**
* ldw 类型 左侧车道线
*/
int ADAS_WARNING_SENCE_LANE_LEFT_LOST = 18;
/**
* 右侧车道线
*/
int ADAS_WARNING_SENCE_LANE_RIGHT_LOST = 19;
/**
* fcw 类型
*/
int ADAS_WARNING_FRONT_CAR = 20;
/**
* 摩托车碰撞
*/
int ADAS_WARNING_MOTORCYCLE = 23;
/**
* 急刹车
*/
int ADAS_WARNING_QUICK_BRAKE = 30;
/**
* 禁止掉头
*/
int ADAS_WARNING_NOT_U_TURN = 40;
/**
* 禁止左转
*/
int ADAS_WARNING_NOT_LEFT_TURN = 41;
/**
* 禁止右转
*/
int ADAS_WARNING_NOT_RIGHT_TURN = 42;
/**
* 禁止鸣喇叭
*/
int ADAS_WARNING_NOT_VOICE = 43;
/**
* 禁止通行
*/
int ADAS_WARNING_DO_NOT_ENTER = 44;
/**
* 限速
*/
int ADAS_WARNING_LIMIT_SPEED = 45;
}

View File

@@ -1,181 +0,0 @@
package com.mogo.service.adas.entity;
import java.io.Serializable;
/**
* @author nie yunlong
* @des 车辆状态
* @date 2020/3/12
*/
public class ADASCarStateInfo implements Serializable {
/**
* action : “state”
* values : {"lon":116.8,"lat":39.4,"alt":22.3,"heading":87.5,"acceleration":0.5,"yaw_rate":0.3}
*/
private String action;
private ValuesBean values;
public String getAction() {
return action;
}
public void setAction(String action) {
this.action = action;
}
public ValuesBean getValues() {
return values;
}
public void setValues(ValuesBean values) {
this.values = values;
}
public static class ValuesBean {
/**
* lon : 116.8
* lat : 39.4
* alt : 22.3
* heading : 87.5
* acceleration : 0.5
* yaw_rate : 0.3
*/
private double lon;
private double lat;
private double alt;
private double heading;
private double acceleration;
private double yaw_rate;
//惯导车速 m/s
private float gnss_speed;
//gps 时间
private String satelliteTime;
private String systemTime;
//接收到数据的时间
private String receiverDataTime;
// udp收到数据的时间
private String startReceiverDataTime;
private String adasSatelliteTime;
public String getAdasSatelliteTime() {
return adasSatelliteTime;
}
public void setAdasSatelliteTime( String adasSatelliteTime ) {
this.adasSatelliteTime = adasSatelliteTime;
}
public String getStartReceiverDataTime() {
return startReceiverDataTime;
}
public void setStartReceiverDataTime( String startReceiverDataTime ) {
this.startReceiverDataTime = startReceiverDataTime;
}
public float getGnss_speed() {
return gnss_speed;
}
public void setGnss_speed( float gnss_speed ) {
this.gnss_speed = gnss_speed;
}
public String getSatelliteTime() {
return satelliteTime;
}
public void setSatelliteTime( String satelliteTime ) {
this.satelliteTime = satelliteTime;
}
public double getLon() {
return lon;
}
public void setLon(double lon) {
this.lon = lon;
}
public double getLat() {
return lat;
}
public void setLat(double lat) {
this.lat = lat;
}
public double getAlt() {
return alt;
}
public void setAlt(double alt) {
this.alt = alt;
}
public double getHeading() {
return heading;
}
public void setHeading(double heading) {
this.heading = heading;
}
public double getAcceleration() {
return acceleration;
}
public void setAcceleration(double acceleration) {
this.acceleration = acceleration;
}
public double getYaw_rate() {
return yaw_rate;
}
public void setYaw_rate(double yaw_rate) {
this.yaw_rate = yaw_rate;
}
public String getSystemTime() {
return systemTime;
}
public void setSystemTime( String systemTime ) {
this.systemTime = systemTime;
}
public String getReceiverDataTime() {
return receiverDataTime;
}
public void setReceiverDataTime( String receiverDataTime ) {
this.receiverDataTime = receiverDataTime;
}
@Override
public String toString() {
return "ValuesBean{" +
"lon=" + lon +
", lat=" + lat +
", alt=" + alt +
", heading=" + heading +
", acceleration=" + acceleration +
", yaw_rate=" + yaw_rate +
'}';
}
}
@Override
public String toString() {
return "CarStateInfo{" +
"action='" + action + '\'' +
", values=" + values +
'}';
}
}

View File

@@ -1,115 +0,0 @@
package com.mogo.service.adas.entity;
/*
* adas 识别物体参数
*/
public class ADASRecognizedResult {
/**
* 识别物体类型
*/
public int type;
/**
* 识别物体唯一标识
*/
public String uuid;
/**
* 红绿灯颜色
*/
public String color;
/**
* 车ID
*/
public String carId;
/**
* 识别物体的纬度
*/
public double lat;
/**
* 识别物体的经度
*/
public double lon;
/**
* 车头朝向
*/
public double heading;
/**
* 系统时间
*/
public long systemTime;
/**
* 定位卫星时间
*/
public long satelliteTime;
/**
* 海拔
*/
public double alt;
/**
* 速度
*/
public double speed;
/**
* 莫顿码
*/
public long mortonCode;
/**
* 实际距离
* 使用distanceX和distanceY计算
*/
public double distance;
/**
* 数据来源精度
* 0普通定位
* 1高精定位
*/
public int dataAccuracy;
/**
* 道路ID
*/
public String roadId;
/**
* 车道ID-2D路段
*/
public String laneId;
/**
* 车道号中心线编号为0中心线右侧编号为负数3车道通行Road的车道编号0-1-2-3
*/
public int laneNum;
/**
* 限速
*/
public double rateLimiting;
/**
* 瓦片id
*/
public String tileId;
/**
* 车道宽度
*/
public double roadWidth;
/**
* 1 绿, 2 黄, 3 红
*/
public int drawlevel;
}

View File

@@ -1,32 +0,0 @@
package com.mogo.service.adas.entity;
public
/**
* @author congtaowang
* @since 2020/10/25
*
* 描述
*/
class ADASWarnMessage {
public String content;
public String level;
/**
* 警告消息类型
* <p>
* {@link com.mogo.service.adas.MogoADASWarnType}
*/
public int type;
public String value;
@Override
public String toString() {
return "ADASWarnMessage{" +
"content='" + content + '\'' +
", level='" + level + '\'' +
", type=" + type +
", value='" + value + '\'' +
'}';
}
}