Merge remote-tracking branch 'origin/dev_robotaxi-d_240807_6.6.0' into dev_robotaxi-d_240807_6.6.0
This commit is contained in:
@@ -140,52 +140,6 @@ internal object V2NIdentifyDrawer: IEventDismissListener {
|
||||
car.longitude,
|
||||
car.latitude
|
||||
)
|
||||
// if (polygon.isNotEmpty()) {
|
||||
// val decision = V2NUtils.computeOccupyLanesInfo(Triple(car.longitude, car.latitude, car.heading.toFloat()), Triple(itx.longitude, itx.latitude, itx.heading.toFloat()), polygon.map { kotlin.Pair(it.first, it.second) })
|
||||
// if (decision != null) {
|
||||
// val isDriver = AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)
|
||||
// val total = decision.total
|
||||
// val occupy = decision.occupy
|
||||
// val laneId = decision.laneId
|
||||
// val sb = StringBuilder()
|
||||
// V2XBizTrace.onAck(decision, "计算出道路事件占道决策数据1")
|
||||
// if (laneId != null) {
|
||||
// val isOccupy = occupy.find { it.id == laneId } != null
|
||||
// if (isOccupy) {
|
||||
// if (isDriver) {
|
||||
// val bestLane = V2NUtils.computeBestLane(laneId, occupy, total)
|
||||
// V2XBizTrace.onAck(bestLane, "计算出最优车道")
|
||||
// sb.append("发现前方${distance.toInt()}米${ if (poiType == EventTypeEnumNew.TYPE_SOCKET_ROAD_SHIGONG.poiType) "车道施工" else "车道事故" }@@, 蘑菇建议您尽快${bestLane.second}")
|
||||
// } else {
|
||||
// sb.append("发现前方${distance.toInt()}米${ if (poiType == EventTypeEnumNew.TYPE_SOCKET_ROAD_SHIGONG.poiType) "车道施工" else "车道事故" }@@, 蘑菇时刻为您守护")
|
||||
// }
|
||||
// } else {
|
||||
// if (isDriver) {
|
||||
// sb.append("发现前方${distance.toInt()}米${ if (poiType == EventTypeEnumNew.TYPE_SOCKET_ROAD_SHIGONG.poiType) "车道施工" else "车道事故" }@@, 蘑菇提醒您小心${ if (computeDirection(laneId, occupy) > 0) "右侧" else "左侧" }行人及来车")
|
||||
// } else {
|
||||
// sb.append("发现前方${distance.toInt()}米${ if (poiType == EventTypeEnumNew.TYPE_SOCKET_ROAD_SHIGONG.poiType) "车道施工" else "车道事故" }@@, 蘑菇时刻为您守护")
|
||||
// }
|
||||
// }
|
||||
// } else {
|
||||
// sb.append("发现前方${distance.toInt()}米${ if (poiType == EventTypeEnumNew.TYPE_SOCKET_ROAD_SHIGONG.poiType) "车道施工" else "车道事故" }@@, 蘑菇时刻为您守护")
|
||||
// }
|
||||
// if (AppIdentityModeUtils.isPassenger(FunctionBuildConfig.appIdentityMode)) {
|
||||
// runCatching {
|
||||
// CallerHmiManager.notifyXiaoZhiStatusChanged(V2N(EventTypeEnumNew.getEnumType(poiType)), START)
|
||||
// }
|
||||
// scope.launch {
|
||||
// delay(5000)
|
||||
// runCatching {
|
||||
// CallerHmiManager.notifyXiaoZhiStatusChanged(V2N(EventTypeEnumNew.getEnumType(poiType)), STOP)
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// val ss = sb.toString()
|
||||
// val content = ss.substring(0, ss.indexOf("@@"))
|
||||
// val tts = ss.replace("@@", "")
|
||||
// CallerRoadV2NEventWindowListenerManager.showLiveVideo(id, itx.detectStartTime.takeIf { it > 0 } ?: System.currentTimeMillis(), EventTypeEnumNew.getUpdateIconRes(poiType), content, isDriver, tts, itx.cameraIp, itx.longitude, itx.latitude)
|
||||
// }
|
||||
// }
|
||||
val isDriver = AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)
|
||||
if (!isDriver) {
|
||||
runCatching {
|
||||
|
||||
@@ -46,7 +46,7 @@ class AiRoadMarker {
|
||||
val aiMakers = ConcurrentHashMap<String, AiRoadMarker>()
|
||||
|
||||
private const val TAG = "AiRoadMarker"
|
||||
private val COLOR_START = Color.parseColor("#002ABAD9")
|
||||
private val COLOR_START = Color.parseColor("#0030A3FF")
|
||||
private val COLOR_END = Color.parseColor("#66FF7A30")
|
||||
private val builders by lazy { ConcurrentHashMap<String, Point.Options.Builder>() }
|
||||
|
||||
|
||||
@@ -38,12 +38,12 @@ class V2XAiRoadEventMarker {
|
||||
if (AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)) {
|
||||
val colors = ArrayList<Int>()
|
||||
colors.add(Color.argb(204, 237, 172, 21))
|
||||
colors.add(Color.argb(0, 255, 255, 255))
|
||||
colors.add(Color.argb(0, 48, 163, 255))
|
||||
builder.colors(colors)
|
||||
} else {
|
||||
val colors = ArrayList<Int>()
|
||||
colors.add(Color.parseColor("#99FF8F2A"))
|
||||
colors.add(Color.argb(0, 255, 255, 255))
|
||||
colors.add(Color.argb(0, 48, 163, 255))
|
||||
builder.colors(colors)
|
||||
}
|
||||
val dispersedPoints = getDispersedPoints(polygon.map { Pair<Double, Double>(it.first, it.second) }, 3)
|
||||
|
||||
@@ -214,6 +214,7 @@ object StatusManager {
|
||||
is DoubleFlashStatus -> "双闪"
|
||||
is GearStatus -> "档位"
|
||||
is RouteDownloadStatus -> if (item.state == RouteStart) "轨迹下载中" else "轨迹下载失败"
|
||||
is FSMStatus -> "FSM"
|
||||
else -> "其它"
|
||||
}
|
||||
}
|
||||
@@ -239,7 +240,6 @@ object StatusManager {
|
||||
} else {
|
||||
ret or shl
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
return ret
|
||||
|
||||
@@ -49,11 +49,11 @@ internal class StatusView(private val model: StatusModel, ctx: Context): Constra
|
||||
.horizontalInnerSpace(10.PX)
|
||||
.build()
|
||||
)
|
||||
val adapter = model.status.value?.let { data -> StatusAdapter(context, data.second.filter { (it !is IAutopilotPreLaunchStatus) && (it !is FSMStatus)}) }?.also { adapter -> itx.adapter = adapter }
|
||||
val adapter = model.status.value?.let { data -> StatusAdapter(context, data.second.filter { (it !is IAutopilotPreLaunchStatus) || (it is FSMStatus)}) }?.also { adapter -> itx.adapter = adapter }
|
||||
adapter?.let { _ ->
|
||||
model.status.observeForever(Observer<Pair<Status?, ArrayList<Status>>> { data ->
|
||||
val old = adapter.data
|
||||
val update = data.second.filter { (it !is IAutopilotPreLaunchStatus) && (it !is FSMStatus) }
|
||||
val update = data.second.filter { (it !is IAutopilotPreLaunchStatus) || (it is FSMStatus) }
|
||||
val result = DiffUtil.calculateDiff(StatusDiffCallback(old, update))
|
||||
adapter.data = update
|
||||
result.dispatchUpdatesTo(adapter)
|
||||
|
||||
@@ -73,7 +73,7 @@ public class RouteOverlayDrawer {
|
||||
List<Integer> alphas = MapTools.INSTANCE.getColorAlpha(temps);
|
||||
if (alphas != null && !alphas.isEmpty()) {
|
||||
for (int i : alphas) {
|
||||
greenWaveColors.add(Color.argb(i, 109,254,208));
|
||||
greenWaveColors.add(Color.argb(i, 48, 163, 255));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -151,7 +151,7 @@ public class RouteOverlayDrawer {
|
||||
if (alphas != null && !alphas.isEmpty()) {
|
||||
colors = new CopyOnWriteArrayList<>();
|
||||
for (int i : alphas) {
|
||||
colors.add(Color.argb(i, 48,203,251));
|
||||
colors.add(Color.argb(i, 48,163,255));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -93,34 +93,35 @@ object CallerAutoPilotControlManager {
|
||||
*/
|
||||
fun isCanStartAutopilot(isShowTip: Boolean, source: Int = 0): Boolean {
|
||||
/**
|
||||
* 方向盘: 1<<0
|
||||
* 油门 : 1<<1
|
||||
* 刹车: 1<<2
|
||||
* 双闪: 1<<3
|
||||
* 档位: 1<<4
|
||||
* 轨迹下载: (下载中) 1<<5; (下载失败)1<<6
|
||||
* FSM: 1<<0
|
||||
* 方向盘: 1<<1
|
||||
* 油门 : 1<<2
|
||||
* 刹车: 1<<3
|
||||
* 双闪: 1<<4
|
||||
* 档位: 1<<5
|
||||
* 轨迹下载: (下载中) 1<<6; (下载失败)1<<7
|
||||
*/
|
||||
val exceptionValue = CallerDevaToolsManager.getExceptionStatusBeforeLaunchAutopilot(source)
|
||||
if (exceptionValue != 0) {
|
||||
if (isShowTip) {
|
||||
val sb = StringBuilder("请检查车辆")
|
||||
if ((exceptionValue and 1) != 0) {
|
||||
sb.append("FSM$")
|
||||
}
|
||||
if ((exceptionValue and (1 shl 1)) != 0) {
|
||||
sb.append("方向盘$")
|
||||
}
|
||||
if (((exceptionValue and (1 shl 1)) != 0)) {
|
||||
if (((exceptionValue and (1 shl 2)) != 0)) {
|
||||
sb.append("油门$")
|
||||
}
|
||||
if ((exceptionValue and (1 shl 2)) != 0) {
|
||||
if ((exceptionValue and (1 shl 3)) != 0) {
|
||||
sb.append("刹车$")
|
||||
}
|
||||
if ((exceptionValue and (1 shl 3)) != 0) {
|
||||
if ((exceptionValue and (1 shl 4)) != 0) {
|
||||
sb.append("双闪$")
|
||||
}
|
||||
if ((exceptionValue and (1 shl 4)) != 0) {
|
||||
sb.append("档位$")
|
||||
}
|
||||
if ((exceptionValue and (1 shl 5)) != 0) {
|
||||
sb.append("FSM$")
|
||||
sb.append("档位$")
|
||||
}
|
||||
if ((exceptionValue and (1 shl 6)) != 0 || ((exceptionValue and (1 shl 7)) != 0)) {
|
||||
if (!sb.contains("$")) {
|
||||
|
||||
Reference in New Issue
Block a user