@@ -30,7 +30,7 @@ import com.mogo.och.bus.bean.UpdateSiteStatusRequest;
|
||||
import com.mogo.och.bus.fragment.OchBusFragment;
|
||||
import com.mogo.och.bus.net.IOchBusApiService;
|
||||
import com.mogo.service.adas.IMogoAdasOCHCallback;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotStationInfo;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
import com.mogo.utils.network.RequestOptions;
|
||||
@@ -307,10 +307,10 @@ public class OchBusPresenter extends Presenter< OchBusFragment > implements IMog
|
||||
currentStation.setIsCurrentSite( STATION_STATUS_LEAVING );
|
||||
nextStation.setIsCurrentSite( STATION_STATUS_ARRIVING );
|
||||
|
||||
AutopilotControlParameters currentAutopilot = new AutopilotControlParameters();
|
||||
AutopilotControlPam currentAutopilot = new AutopilotControlPam();
|
||||
currentAutopilot.isSpeakVoice = !isRestart;
|
||||
currentAutopilot.startLatLon = new AutopilotControlParameters.AutoPilotLonLat( currentStation.getLat(), currentStation.getLon() );
|
||||
currentAutopilot.endLatLon = new AutopilotControlParameters.AutoPilotLonLat( nextStation.getLat(), nextStation.getLon() );
|
||||
currentAutopilot.startLatLon = new AutopilotControlPam.AutoPilotLonLat( currentStation.getLat(), currentStation.getLon() );
|
||||
currentAutopilot.endLatLon = new AutopilotControlPam.AutoPilotLonLat( nextStation.getLat(), nextStation.getLon() );
|
||||
currentAutopilot.vehicleType = VEHICLE_TYPE;
|
||||
Logger.d( TAG, "开启自动驾驶====" + currentAutopilot );
|
||||
MogoApisHandler.getInstance().getApis().getAdasControllerApi().aiCloudToAdasData( currentAutopilot );
|
||||
|
||||
@@ -15,7 +15,7 @@ import com.mogo.module.common.MogoApisHandler;
|
||||
import com.mogo.module.common.constants.HostConst;
|
||||
import com.mogo.och.taxi.ui.OCHTaxiUiController;
|
||||
import com.mogo.service.adas.IMogoAdasOCHCallback;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotStationInfo;
|
||||
import com.mogo.service.cloud.socket.IMogoLifecycleListener;
|
||||
import com.mogo.service.cloud.socket.IMogoOnMessageListener;
|
||||
@@ -853,10 +853,10 @@ class MogoOCHTaxiModel {
|
||||
return;
|
||||
}
|
||||
|
||||
AutopilotControlParameters parameters = new AutopilotControlParameters();
|
||||
AutopilotControlPam parameters = new AutopilotControlPam();
|
||||
parameters.vehicleType = mCurrentOCHOrder.orderType;
|
||||
parameters.startLatLon = new AutopilotControlParameters.AutoPilotLonLat( mCurrentOCHOrder.drivingRoutes.get( 0 ).wgsLat, mCurrentOCHOrder.drivingRoutes.get( 0 ).wgsLon );
|
||||
parameters.endLatLon = new AutopilotControlParameters.AutoPilotLonLat( mCurrentOCHOrder.drivingRoutes.get( 1 ).wgsLat, mCurrentOCHOrder.drivingRoutes.get( 1 ).wgsLon );
|
||||
parameters.startLatLon = new AutopilotControlPam.AutoPilotLonLat( mCurrentOCHOrder.drivingRoutes.get( 0 ).wgsLat, mCurrentOCHOrder.drivingRoutes.get( 0 ).wgsLon );
|
||||
parameters.endLatLon = new AutopilotControlPam.AutoPilotLonLat( mCurrentOCHOrder.drivingRoutes.get( 1 ).wgsLat, mCurrentOCHOrder.drivingRoutes.get( 1 ).wgsLon );
|
||||
MogoApisHandler.getInstance()
|
||||
.getApis()
|
||||
.getAdasControllerApi()
|
||||
|
||||
@@ -17,7 +17,7 @@ import com.mogo.module.common.MogoApisHandler;
|
||||
import com.mogo.module.common.view.OnPreventFastClickListener;
|
||||
import com.mogo.och.view.SlidePanelView;
|
||||
import com.mogo.service.adas.IMogoAdasOCHCallback;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
|
||||
/**
|
||||
@@ -135,12 +135,12 @@ public abstract class BaseOchFragment<V extends IView, P extends Presenter<V>> e
|
||||
findViewById(R.id.btnAutopilotControl).setOnClickListener(view ->
|
||||
{
|
||||
// Logger.d("lianglihui","模拟 站点下发工控");
|
||||
AutopilotControlParameters currentAutopilot = new AutopilotControlParameters();
|
||||
AutopilotControlPam currentAutopilot = new AutopilotControlPam();
|
||||
currentAutopilot.isSpeakVoice = true;
|
||||
// 万集东门站
|
||||
currentAutopilot.startLatLon = new AutopilotControlParameters.AutoPilotLonLat(40.194795425,116.724476409);
|
||||
currentAutopilot.startLatLon = new AutopilotControlPam.AutoPilotLonLat(40.194795425,116.724476409);
|
||||
// 市政府前街18号
|
||||
currentAutopilot.endLatLon = new AutopilotControlParameters.AutoPilotLonLat(40.1939540844,116.720067);
|
||||
currentAutopilot.endLatLon = new AutopilotControlPam.AutoPilotLonLat(40.1939540844,116.720067);
|
||||
// 订单运营类型 (9出租车,10小巴)
|
||||
currentAutopilot.vehicleType = 10;
|
||||
Logger.d(TAG, "模拟 订单站点下发:" + currentAutopilot);
|
||||
|
||||
@@ -2,8 +2,8 @@ package com.mogo.eagle.core.function.autopilot
|
||||
|
||||
import android.content.Context
|
||||
import com.alibaba.android.arouter.facade.annotation.Route
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlCmdParameter
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlCmdPam
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam
|
||||
import com.mogo.eagle.core.data.constants.MogoServicePaths
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotProvider
|
||||
import com.mogo.eagle.core.utilcode.util.GsonUtils
|
||||
@@ -37,10 +37,10 @@ class MoGoAutopilotProvider :
|
||||
}
|
||||
|
||||
|
||||
override fun startAutoPilot(result: AutopilotControlParameters) {
|
||||
override fun startAutoPilot(result: AutopilotControlPam) {
|
||||
if (AdasManager.getInstance().isSocketConnect) {
|
||||
val parameter =
|
||||
AutopilotControlCmdParameter(
|
||||
AutopilotControlCmdPam(
|
||||
TAG,
|
||||
result
|
||||
)
|
||||
|
||||
@@ -5,7 +5,7 @@ import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotStationInfo
|
||||
import com.mogo.eagle.core.function.call.hmi.CallerHmiListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
@@ -68,10 +68,10 @@ class AutoPilotStatusView @JvmOverloads constructor(
|
||||
}
|
||||
private fun startAutoPilot() {
|
||||
val currentAutopilot =
|
||||
AutopilotControlParameters()
|
||||
AutopilotControlPam()
|
||||
currentAutopilot.isSpeakVoice = false
|
||||
currentAutopilot.startLatLon = AutopilotControlParameters.AutoPilotLonLat(40.199157289445921,116.73675895051454);
|
||||
currentAutopilot.endLatLon = AutopilotControlParameters.AutoPilotLonLat(40.199255159538758,116.73274535677977);
|
||||
currentAutopilot.startLatLon = AutopilotControlPam.AutoPilotLonLat(40.199157289445921,116.73675895051454);
|
||||
currentAutopilot.endLatLon = AutopilotControlPam.AutoPilotLonLat(40.199255159538758,116.73274535677977);
|
||||
currentAutopilot.vehicleType = 10
|
||||
MogoApisHandler.getInstance().apis.adasControllerApi.aiCloudToAdasData(currentAutopilot)
|
||||
}
|
||||
|
||||
@@ -8,12 +8,12 @@ package com.mogo.eagle.core.data.autopilot;
|
||||
* 域控制器 控制指令发送
|
||||
*
|
||||
*/
|
||||
public class AutopilotControlCmdParameter {
|
||||
public class AutopilotControlCmdPam {
|
||||
|
||||
public String action;
|
||||
public Object result;
|
||||
|
||||
public AutopilotControlCmdParameter(String action, Object result) {
|
||||
public AutopilotControlCmdPam(String action, Object result) {
|
||||
this.action = action;
|
||||
this.result = result;
|
||||
}
|
||||
@@ -9,7 +9,7 @@ import java.util.List;
|
||||
* 启动自动驾驶参数
|
||||
*
|
||||
*/
|
||||
public class AutopilotControlParameters {
|
||||
public class AutopilotControlPam {
|
||||
|
||||
public AutoPilotLonLat startLatLon;
|
||||
public List<AutoPilotLonLat> wayLatLons;
|
||||
@@ -1,6 +1,6 @@
|
||||
package com.mogo.eagle.core.function.api.autopilot;
|
||||
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam;
|
||||
import com.mogo.eagle.core.function.api.base.IMoGoFunctionServerProvider;
|
||||
|
||||
/**
|
||||
@@ -21,7 +21,7 @@ public interface IMoGoAutopilotProvider extends IMoGoFunctionServerProvider {
|
||||
*
|
||||
* @param result
|
||||
*/
|
||||
void startAutoPilot(AutopilotControlParameters result);
|
||||
void startAutoPilot(AutopilotControlPam result);
|
||||
|
||||
/**
|
||||
* 结束自动驾驶
|
||||
|
||||
@@ -2,7 +2,7 @@ package com.mogo.module.service.autopilot;
|
||||
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.module.common.MogoApisHandler;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam;
|
||||
import com.mogo.service.cloud.socket.IMogoOnMessageListener;
|
||||
import com.mogo.service.cloud.socket.IMogoSocketManager;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
@@ -23,14 +23,14 @@ class AutoPilotRemoteController {
|
||||
|
||||
private IMogoSocketManager mMogoSocketManager;
|
||||
|
||||
private IMogoOnMessageListener<AutopilotControlParameters> mParametersListener = new IMogoOnMessageListener<AutopilotControlParameters>() {
|
||||
private IMogoOnMessageListener<AutopilotControlPam> mParametersListener = new IMogoOnMessageListener<AutopilotControlPam>() {
|
||||
@Override
|
||||
public Class<AutopilotControlParameters> target() {
|
||||
return AutopilotControlParameters.class;
|
||||
public Class<AutopilotControlPam> target() {
|
||||
return AutopilotControlPam.class;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMsgReceived( AutopilotControlParameters obj ) {
|
||||
public void onMsgReceived( AutopilotControlPam obj ) {
|
||||
if ( obj == null ) {
|
||||
Logger.e( TAG, "远端控制参数为null", new NullPointerException() );
|
||||
return;
|
||||
|
||||
@@ -11,7 +11,7 @@ import android.os.Message;
|
||||
|
||||
import com.mogo.cloud.commons.utils.CoordinateUtils;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotStationInfo;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam;
|
||||
import com.mogo.eagle.core.data.map.MogoLatLng;
|
||||
import com.mogo.eagle.core.function.api.hmi.autopilot.IMoGoCheckAutoPilotBtnListener;
|
||||
import com.mogo.eagle.core.function.call.hmi.CallerHmiListenerManager;
|
||||
@@ -137,17 +137,17 @@ public class DispatchAutoPilotManager implements IMogoOnMessageListener<Dispatch
|
||||
}
|
||||
|
||||
private void startAutoPilot() {
|
||||
AutopilotControlParameters currentAutopilot = new AutopilotControlParameters();
|
||||
AutopilotControlPam currentAutopilot = new AutopilotControlPam();
|
||||
currentAutopilot.isSpeakVoice = false;
|
||||
List<AutopilotControlParameters.AutoPilotLonLat> wayLatLon = new ArrayList<>();
|
||||
List<AutopilotControlPam.AutoPilotLonLat> wayLatLon = new ArrayList<>();
|
||||
if (receiverBean!=null && receiverBean.getStopsList()!= null){
|
||||
for (MogoLatLng mogoLatLng : receiverBean.getStopsList()) {
|
||||
wayLatLon.add(new AutopilotControlParameters.AutoPilotLonLat(mogoLatLng.lat, mogoLatLng.lon));
|
||||
wayLatLon.add(new AutopilotControlPam.AutoPilotLonLat(mogoLatLng.lat, mogoLatLng.lon));
|
||||
}
|
||||
}
|
||||
currentAutopilot.wayLatLons = wayLatLon;
|
||||
currentAutopilot.startLatLon = new AutopilotControlParameters.AutoPilotLonLat(receiverBean.getStartLat(), receiverBean.getStartLon());
|
||||
currentAutopilot.endLatLon = new AutopilotControlParameters.AutoPilotLonLat(receiverBean.getEndLat(), receiverBean.getEndLon());
|
||||
currentAutopilot.startLatLon = new AutopilotControlPam.AutoPilotLonLat(receiverBean.getStartLat(), receiverBean.getStartLon());
|
||||
currentAutopilot.endLatLon = new AutopilotControlPam.AutoPilotLonLat(receiverBean.getEndLat(), receiverBean.getEndLon());
|
||||
currentAutopilot.vehicleType = 10;
|
||||
Logger.d(TAG, "开启自动驾驶====" + currentAutopilot);
|
||||
mApis.getAdasControllerApi().aiCloudToAdasData(currentAutopilot);
|
||||
|
||||
@@ -18,7 +18,7 @@ import com.mogo.cloud.socket.entity.SocketDownDataHelper;
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.commons.voice.AIAssist;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam;
|
||||
import com.mogo.eagle.core.data.map.MogoLatLng;
|
||||
import com.mogo.eagle.core.data.traffic.TrafficData;
|
||||
import com.mogo.map.marker.IMogoMarker;
|
||||
@@ -523,10 +523,10 @@ public class MockIntentHandler implements IntentHandler {
|
||||
.onAutopilotArriveLike(intent.getIntExtra("type", 8));
|
||||
break;
|
||||
case 44:// 控制自动驾驶
|
||||
AutopilotControlParameters parameters = new AutopilotControlParameters();
|
||||
AutopilotControlPam parameters = new AutopilotControlPam();
|
||||
parameters.vehicleType = 9;
|
||||
parameters.startLatLon = new AutopilotControlParameters.AutoPilotLonLat(40.1690522746, 116.567374558);
|
||||
parameters.endLatLon = new AutopilotControlParameters.AutoPilotLonLat(40.1651999405, 116.567217441);
|
||||
parameters.startLatLon = new AutopilotControlPam.AutoPilotLonLat(40.1690522746, 116.567374558);
|
||||
parameters.endLatLon = new AutopilotControlPam.AutoPilotLonLat(40.1651999405, 116.567217441);
|
||||
MogoApisHandler.getInstance()
|
||||
.getApis()
|
||||
.getAdasControllerApi()
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
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.AutopilotControlPam;
|
||||
import com.mogo.eagle.core.data.traffic.TrafficData;
|
||||
import com.mogo.map.uicontroller.EnumMapUI;
|
||||
|
||||
@@ -57,7 +57,7 @@ public interface IMogoADASController extends IProvider {
|
||||
*
|
||||
* @param result
|
||||
*/
|
||||
void aiCloudToAdasData(AutopilotControlParameters result);
|
||||
void aiCloudToAdasData(AutopilotControlPam result);
|
||||
|
||||
/**
|
||||
* 添加adas数据回调接口
|
||||
|
||||
@@ -12,8 +12,8 @@ import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotCarStateInfo;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlCmdParameter;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlCmdPam;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlPam;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotRouteInfo;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotStationInfo;
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotStatusInfo;
|
||||
@@ -449,7 +449,7 @@ public class MogoADASController implements IMogoADASController {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void aiCloudToAdasData(AutopilotControlParameters result) {
|
||||
public void aiCloudToAdasData(AutopilotControlPam result) {
|
||||
try {
|
||||
syncControlCmdToADAS("aiCloudToStartAutopilot", result);
|
||||
} catch (Exception e) {
|
||||
@@ -462,7 +462,7 @@ public class MogoADASController implements IMogoADASController {
|
||||
* @param result
|
||||
*/
|
||||
private void syncControlCmdToADAS(String action, Object result) {
|
||||
AutopilotControlCmdParameter parameter = new AutopilotControlCmdParameter(action, result);
|
||||
AutopilotControlCmdPam parameter = new AutopilotControlCmdPam(action, result);
|
||||
//位置信息 action是aiCloudToStartAutopilot
|
||||
try {
|
||||
adasProvider.sendWsMessage(GsonUtil.jsonFromObject(parameter));
|
||||
|
||||
Reference in New Issue
Block a user