Merge branch 'dev_robotaxi-d_230809_6.0.0' into dev_robotaxi-d_230809_6.0.0_refactor

This commit is contained in:
wangmingjun
2023-08-22 11:03:30 +08:00
12 changed files with 43 additions and 57 deletions

View File

@@ -128,6 +128,10 @@ class LockAndUnlockView : ConstraintLayout, LockManager.LockStatusCallback {
setImageStatus(statusView,LockManager.getLockStatus())
}
/**
* @param statusView UnlockView的显示和隐藏
* @param lockStatus 锁屏状态
*/
private fun setImageStatus(statusView: Int,lockStatus: LockManager.LockStatus){
when (statusView) {
View.GONE -> {

View File

@@ -128,7 +128,7 @@ class UnlockView : ConstraintLayout, LockManager.LockStatusCallback {
when (isLock) {
LockManager.LockStatus.LOCKED -> {
// 锁定
actv_lock_status.text = "长按开锁键1秒,快速解锁"
actv_lock_status.text = "长按开锁键2秒,快速解锁"
aciv_only_unlock.setImageResource(R.drawable.charter_p_only_lock)
}
LockManager.LockStatus.UNLOCKING -> {

View File

@@ -29,7 +29,7 @@
<androidx.appcompat.widget.AppCompatTextView
android:id="@+id/actv_lock_status"
android:text="长按开锁键1秒杀,快速解锁"
android:text="长按开锁键2秒杀,快速解锁"
app:layout_constraintStart_toStartOf="@+id/aciv_only_unlock"
app:layout_constraintEnd_toEndOf="@+id/aciv_only_unlock"
app:layout_constraintTop_toBottomOf="@+id/aciv_only_unlock"

View File

@@ -8,10 +8,11 @@ import com.amap.api.maps.model.LatLng
import com.google.gson.reflect.TypeToken
import com.mogo.eagle.core.data.enums.DataSourceType
import com.mogo.eagle.core.data.map.MogoLocation
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager
import com.mogo.eagle.core.function.call.autopilot.CallerChassisDoorStateListenerManager
import com.mogo.eagle.core.function.call.autopilot.CallerChassisGnssListenerManager
import com.mogo.eagle.core.function.call.autopilot.CallerChassisLocationGCJ02ListenerManager
import com.mogo.eagle.core.function.call.autopilot.CallerPlanningRottingListenerManager
import com.mogo.eagle.core.utilcode.geometry.S2LaxPolygonShape.MultiList
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
import com.mogo.eagle.core.utilcode.util.GsonUtils
@@ -19,6 +20,7 @@ import com.mogo.eagle.core.utilcode.util.ThreadUtils
import com.mogo.och.common.module.debug.location.MogoLocationExit
import com.mogo.och.common.module.utils.CoordinateCalculateRouteUtil
import mogo.telematics.pad.MessagePad
import mogo_msg.MogoReportMsg
import java.io.BufferedReader
import java.io.File
import java.io.FileInputStream
@@ -32,10 +34,12 @@ object DebugDataDispatch {
const val globalPathMock = "globalPath"
const val locationMock = "location"
const val carDoorMock = "carDoor"
const val carNeedTurnAround = "trunAroud"
// adb shell am broadcast -a com.mogo.launcher.debug -f 0x011000000 --es type "location" --es path "sy73_log.json"
// adb shell am broadcast -a com.mogo.launcher.debug -f 0x011000000 --es type "globalPath" --es path "sy73.json"
// adb shell am broadcast -a com.mogo.launcher.debug -f 0x011000000 --es type "carDoor" --ei doorPostion 1 --ei doorStatus 1
// adb shell am broadcast -a com.mogo.launcher.debug -f 0x011000000 --es type "trunAroud" --es code "IMAP_TRA_LOADED"
val ROOT_PATH =
@@ -68,6 +72,17 @@ object DebugDataDispatch {
CallerChassisDoorStateListenerManager.invokeAutopilotDoorState(multiList)
}
carNeedTurnAround -> {
// 1--5
val intArrayExtra = intent.getStringExtra("code")
val newBuilder = MogoReportMsg.MogoReportMessage.newBuilder()
newBuilder.code = intArrayExtra
newBuilder.timestampBuilder.sec = 0
newBuilder.timestampBuilder.nsec = 0
newBuilder.src = "2"
newBuilder.level = ""
CallerAutoPilotStatusListenerManager.invokeAutopilotGuardian(newBuilder.build())
}
else -> {}
}
}
@@ -83,15 +98,12 @@ object DebugDataDispatch {
line.toString(),
object : TypeToken<MogoLocationExit>() {}.type
)
val mogoLocation = MogoLocation()
mogoLocation.latitude = list.msg.GnssInfo.latitude
mogoLocation.longitude = list.msg.GnssInfo.longitude
mogoLocation.heading = list.msg.GnssInfo.heading
mogoLocation.gnssSpeed = list.msg.GnssInfo.gnssSpeed.toFloat()
CallerChassisLocationGCJ02ListenerManager.invokeChassisLocationGCJ02(
mogoLocation,
DataSourceType.OBU
)
val newBuilder = MessagePad.GnssInfo.newBuilder()
newBuilder.latitude = list.msg.GnssInfo.latitude
newBuilder.longitude = list.msg.GnssInfo.longitude
newBuilder.heading = list.msg.GnssInfo.heading
newBuilder.gnssSpeed = list.msg.GnssInfo.gnssSpeed
CallerChassisGnssListenerManager.invokeChassisGnssListener(newBuilder.build())
Thread.sleep(100)
}
} catch (e: IOException) {

View File

@@ -51,6 +51,7 @@ public class TaxiPassengerOrderQueryRespBean extends BaseData {
public String passengerNum;
public long lineId = -1; //路线id默认-1
public String lineName = ""; //路线名称,默认""
public String csvFileUrl = ""; //轨迹文件下载的cos url默认“”
public String csvFileMd5 = ""; //轨迹文件md5默认“”
public String txtFileUrl = ""; //打点文件下载的cos url默认“”

View File

@@ -108,6 +108,7 @@ object AutopilotManager : IMoGoAutopilotStatusListener {
if (parameters.autoPilotLine == null) {
parameters.autoPilotLine = AutopilotControlParameters.AutoPilotLine(
TaxiPassengerModel.currentOCHOrder!!.lineId,
TaxiPassengerModel.currentOCHOrder!!.lineName,
TaxiPassengerModel.currentOCHOrder!!.csvFileUrl,
TaxiPassengerModel.currentOCHOrder!!.csvFileMd5,
TaxiPassengerModel.currentOCHOrder!!.txtFileUrl,

View File

@@ -344,8 +344,11 @@ class TaxiUnmannedViewModel : BaseViewModel<UnmannedState, UnmannedIntent>(){
if (result.taskType <= TaskTypeEnum.ToOrderStartTask.code
&& result.currentStatus == TaskStatusEnum.GetTask.code){//自动去启动自驾
d(TAG, "queryCurrentTaskOnce1 = autoStartDriving" )
TaxiModel.autoStartDriving()
if (result.order != null && result.order!!.orderStatus < TaxiOrderStatusEnum.ArriveAtStart.code){
d(TAG, "queryCurrentTaskOnce1 = autoStartDriving" )
TaxiModel.autoStartDriving()
return
}
}
}
}
@@ -430,9 +433,7 @@ class TaxiUnmannedViewModel : BaseViewModel<UnmannedState, UnmannedIntent>(){
private fun startPrepareTask30S(siteId: Long) {
UiThreadHandler.postDelayed({
if (isLogin() && isOpeningOrderStatus()){
pullTask(siteId)
}
pullTask(siteId)
}, TaxiUnmannedConst.TIMER_PREPARE_TASK_INTERVAL)
}

View File

@@ -52,6 +52,7 @@ public class OrderQueryRespBean extends BaseData {
//线路轨迹相关字段
public long lineId = -1; //路线id默认-1
public String lineName = ""; //路线名称,默认""
public String csvFileUrl = ""; //轨迹文件下载的cos url默认“”
public String csvFileMd5 = ""; //轨迹文件md5默认“”
public String txtFileUrl = ""; //打点文件下载的cos url默认“”

View File

@@ -1001,7 +1001,7 @@ public class TaxiModel {
parameters.endLatLon = new AutopilotControlParameters.AutoPilotLonLat(endWgsLat, endWgsLon);
if (parameters.autoPilotLine == null) {
parameters.autoPilotLine = new AutopilotControlParameters.AutoPilotLine(
mCurrentOCHOrder.lineId,
mCurrentOCHOrder.lineId, mCurrentOCHOrder.lineName,
mCurrentOCHOrder.csvFileUrl, mCurrentOCHOrder.csvFileMd5,
mCurrentOCHOrder.txtFileUrl, mCurrentOCHOrder.txtFileMd5,
mCurrentOCHOrder.contrailSaveTime, mCurrentOCHOrder.carModel,

View File

@@ -41,7 +41,7 @@ public class TaxiTrajectoryManager {
private String mPrevOrderNo = "";
public TaxiTrajectoryManager() {
mAutoPilotLine = new AutopilotControlParameters.AutoPilotLine(-1,
mAutoPilotLine = new AutopilotControlParameters.AutoPilotLine(-1, "",
"", "", "", "", 0, "",
"", "", "", "", 0);
}
@@ -110,13 +110,14 @@ public class TaxiTrajectoryManager {
return;
} else {
if (mAutoPilotLine == null) {
mAutoPilotLine = new AutopilotControlParameters.AutoPilotLine(order.lineId,
mAutoPilotLine = new AutopilotControlParameters.AutoPilotLine(order.lineId, order.lineName,
order.csvFileUrl, order.csvFileMd5, order.txtFileUrl, order.txtFileMd5,
order.contrailSaveTime, order.carModel,
order.csvFileUrlDPQP, order.csvFileMd5DPQP, order.txtFileUrlDPQP, order.txtFileMd5DPQP,
order.contrailSaveTimeDPQP);
} else {
mAutoPilotLine.setLineId(order.lineId);
mAutoPilotLine.setLineName(order.lineName);
mAutoPilotLine.setTrajUrl(order.csvFileUrl);
mAutoPilotLine.setTrajMd5(order.csvFileMd5);
mAutoPilotLine.setStopUrl(order.txtFileUrl);
@@ -135,6 +136,7 @@ public class TaxiTrajectoryManager {
private void clearAutoPilotLine() {
if (mAutoPilotLine == null) return;
mAutoPilotLine.setLineId(-1);
mAutoPilotLine.setLineName("");
mAutoPilotLine.setTrajUrl("");
mAutoPilotLine.setTrajMd5("");
mAutoPilotLine.setStopUrl("");
@@ -185,25 +187,6 @@ public class TaxiTrajectoryManager {
return;
}
// TODO: 2022/6/24
// test1
// mAutoPilotLine.setLineId(148);
// mAutoPilotLine.setTrajUrl("http://file-qa.zhidaozhixing.com/fileServer/upload/downloadFileStream?key=fileServer/online_car_hailing/e27c20c2da32481021d934c3ef084536/traj_148.csv");
// mAutoPilotLine.setTrajMd5("e27c20c2da32481021d934c3ef084536");
// mAutoPilotLine.setStopUrl("http://file-qa.zhidaozhixing.com/fileServer/upload/downloadFileStream?key=fileServer/online_car_hailing/6224c9dd2c0e2bd990c6482c0464de45/stop_148.txt");
// mAutoPilotLine.setStopMd5("6224c9dd2c0e2bd990c6482c0464de45");
// mAutoPilotLine.setTimestamp(1654596000000L); //20220607 18:00
// mAutoPilotLine.setVehicleModel("红旗H9");
// test2
// mAutoPilotLine.setLineId(148);
// mAutoPilotLine.setTrajUrl("http://file-qa.zhidaozhixing.com/fileServer/upload/downloadFileStream?key=fileServer/online_car_hailing/8654497cf918be461a59c7ad8e22920d/traj_148.csv");
// mAutoPilotLine.setTrajMd5("8654497cf918be461a59c7ad8e22920d");
// mAutoPilotLine.setStopUrl("http://file-qa.zhidaozhixing.com/fileServer/upload/downloadFileStream?key=fileServer/online_car_hailing/1bb098b244922649bf3e7bada0d3950f/stop_148.txt");
// mAutoPilotLine.setStopMd5("1bb098b244922649bf3e7bada0d3950f");
// mAutoPilotLine.setTimestamp(1654761600000L); //20220609 16:00
// mAutoPilotLine.setVehicleModel("红旗H9");
CallerAutoPilotControlManager.INSTANCE.sendTrajectoryDownloadReq(mAutoPilotLine);
CallerLogger.INSTANCE.d(M_TAXI + TAG, "sendTrajectoryReq(): "
+ GsonUtils.toJson(mAutoPilotLine));

View File

@@ -167,23 +167,6 @@ class AutopilotControlParameters {
this.vehicleModel = vehicleModel
}
constructor(lineId: Long, trajUrl: String, trajMd5: String, stopUrl: String, stopMd5: String,
timestamp: Long, vehicleModel: String, trajUrl_dpqp: String, trajMd5_dpqp: String,
stopUrl_dpqp: String, stopMd5_dpqp: String, timestamp_dpqp: Long) {
this.lineId = lineId
this.trajUrl = trajUrl
this.trajMd5 = trajMd5
this.stopUrl = stopUrl
this.stopMd5 = stopMd5
this.timestamp = timestamp
this.vehicleModel = vehicleModel
this.trajUrl_dpqp = trajUrl_dpqp
this.trajMd5_dpqp = trajMd5_dpqp
this.stopUrl_dpqp = stopUrl_dpqp
this.stopMd5_dpqp = stopMd5_dpqp
this.timestamp_dpqp = timestamp_dpqp
}
constructor(lineId: Long, lineName: String, trajUrl: String,
trajMd5: String, stopUrl: String, stopMd5: String, timestamp: Long, vehicleModel: String,
trajUrl_dpqp: String, trajMd5_dpqp: String, stopUrl_dpqp: String, stopMd5_dpqp: String, timestamp_dpqp: Long) {

View File

@@ -58,7 +58,7 @@ bytex.ASM_API=ASM7
################ 外部依赖引用 ################
# loglib
LOGLIB_VERSION=1.9.0
LOGLIB_VERSION=1.9.1
######## MogoAiCloudSDK Version ########
# 网络请求LOGLIB_VERSION
MOGO_NETWORK_VERSION=1.4.7.12