merge
This commit is contained in:
@@ -19,6 +19,7 @@ import androidx.core.content.ContextCompat
|
||||
import androidx.core.view.*
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import chassis.Chassis
|
||||
import chassis.VehicleStateOuterClass
|
||||
import com.mogo.cloud.passport.MoGoAiCloudClient
|
||||
import com.mogo.cloud.passport.MoGoAiCloudClientConfig
|
||||
import com.mogo.commons.debug.DebugConfig
|
||||
@@ -2092,6 +2093,13 @@ class DebugSettingView @JvmOverloads constructor(
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 清扫车(福田)清扫控制系统状态
|
||||
*/
|
||||
override fun onSweeperFutianCleanSystemState(cleanSystemState: VehicleStateOuterClass.SweeperFuTianCleanSystemState) {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 吐司提示
|
||||
*/
|
||||
|
||||
@@ -7,6 +7,7 @@ import android.graphics.Color
|
||||
import android.graphics.drawable.ColorDrawable
|
||||
import android.os.Process
|
||||
import android.util.AttributeSet
|
||||
import android.util.Log
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.widget.FrameLayout
|
||||
@@ -113,51 +114,45 @@ class AutoPilotAndCheckView @JvmOverloads constructor(
|
||||
// if (maxAcceleration > 0) {
|
||||
// tvAcceleration.text = "加速度 $maxAcceleration m/s²"
|
||||
// }
|
||||
tvAcceleration.text = "每次调整车速±5km/h"
|
||||
tvAcceleration.text = "每次调整车速±5km/h,点击确定生效"
|
||||
if (speedLimit > 0) {
|
||||
tvSpeed.text = speedLimit.toString()
|
||||
}else{
|
||||
tvSpeed.text = "0"
|
||||
}
|
||||
|
||||
ivSpeedReduce.setOnClickListener {
|
||||
if(speedLimit>=5){
|
||||
speedLimit -= 5
|
||||
//速度显示
|
||||
val isSuccess = CallerAutoPilotManager.setAutoPilotSpeed(speedLimit)
|
||||
when {
|
||||
isSuccess -> {
|
||||
//速度显示
|
||||
tvSpeed.text = speedLimit.toString()
|
||||
ToastUtils.showShort("车速设置成功,立即生效")
|
||||
}
|
||||
else -> {
|
||||
ToastUtils.showShort("设置车速失败,请启动域控制器")
|
||||
}
|
||||
}
|
||||
tvSpeed.text = speedLimit.toString()
|
||||
}else{
|
||||
ToastUtils.showShort("车速不能再减了")
|
||||
}
|
||||
}
|
||||
|
||||
ivSpeedAdd.setOnClickListener {
|
||||
if(speedLimit<=55){
|
||||
speedLimit += 5
|
||||
//速度显示
|
||||
val isSuccess = CallerAutoPilotManager.setAutoPilotSpeed(speedLimit)
|
||||
when {
|
||||
isSuccess -> {
|
||||
//速度显示
|
||||
tvSpeed.text = speedLimit.toString()
|
||||
ToastUtils.showShort("车速设置成功,立即生效")
|
||||
}
|
||||
else -> {
|
||||
ToastUtils.showShort("设置车速失败,请启动域控制器")
|
||||
}
|
||||
}
|
||||
tvSpeed.text = speedLimit.toString()
|
||||
}else{
|
||||
ToastUtils.showShort("车速不能再加了")
|
||||
}
|
||||
}
|
||||
|
||||
//速度确认
|
||||
tvSureModify.setOnClickListener {
|
||||
val isSuccess = CallerAutoPilotManager.setAutoPilotSpeed(speedLimit)
|
||||
when {
|
||||
isSuccess -> {
|
||||
//速度显示
|
||||
tvSpeed.text = speedLimit.toString()
|
||||
ToastUtils.showShort("车速设置成功,立即生效")
|
||||
}
|
||||
else -> {
|
||||
ToastUtils.showShort("设置车速失败,请启动域控制器")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
initOchView()
|
||||
}
|
||||
|
||||
@@ -18,7 +18,6 @@ import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_HMI
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.module.common.MogoApisHandler
|
||||
import kotlinx.android.synthetic.main.view_autopilot_status.view.*
|
||||
|
||||
/**
|
||||
|
||||
@@ -27,6 +27,7 @@ import com.mogo.eagle.core.utilcode.util.ThreadUtils;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import chassis.Chassis;
|
||||
import chassis.VehicleStateOuterClass;
|
||||
import mogo.telematics.pad.MessagePad;
|
||||
import mogo_msg.MogoReportMsg;
|
||||
import system_master.SystemStatusInfo;
|
||||
@@ -164,6 +165,10 @@ public class SteeringWheelView extends ConstraintLayout {
|
||||
|
||||
private final IMoGoAutopilotVehicleStateListener mIMoGoAutopilotVehicleStateListener = new IMoGoAutopilotVehicleStateListener() {
|
||||
|
||||
@Override
|
||||
public void onSweeperFutianCleanSystemState(@NonNull VehicleStateOuterClass.SweeperFuTianCleanSystemState cleanSystemState) {
|
||||
}
|
||||
|
||||
/**
|
||||
* @param brake 刹车
|
||||
*/
|
||||
|
||||
@@ -26,6 +26,7 @@ import com.mogo.eagle.core.utilcode.util.ThreadUtils;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import chassis.Chassis;
|
||||
import chassis.VehicleStateOuterClass;
|
||||
import mogo.telematics.pad.MessagePad;
|
||||
|
||||
/**
|
||||
@@ -122,6 +123,10 @@ public class TrafficDataView extends ConstraintLayout {
|
||||
}
|
||||
|
||||
private final IMoGoAutopilotVehicleStateListener mIMoGoAutopilotVehicleStateListener = new IMoGoAutopilotVehicleStateListener() {
|
||||
@Override
|
||||
public void onSweeperFutianCleanSystemState(@NonNull VehicleStateOuterClass.SweeperFuTianCleanSystemState cleanSystemState) {
|
||||
}
|
||||
|
||||
/**
|
||||
* 车辆转向灯
|
||||
* @param lightSwitch
|
||||
|
||||
@@ -60,8 +60,6 @@ import com.mogo.map.listener.MogoMapListenerHandler;
|
||||
import com.mogo.map.location.IMogoLocationListener;
|
||||
import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.module.common.MogoApisHandler;
|
||||
import com.mogo.service.IMogoServiceApis;
|
||||
import com.rousetime.android_startup.StartupManager;
|
||||
import com.rousetime.android_startup.model.LoggerLevel;
|
||||
import com.rousetime.android_startup.model.StartupConfig;
|
||||
@@ -90,8 +88,6 @@ public class MainActivity extends MvpActivity<MainView, MainPresenter> implement
|
||||
protected static final String TAG = "MainActivity";
|
||||
private static final int REQUEST_CODE_DIALOG = 100;
|
||||
|
||||
protected IMogoServiceApis mServiceApis;
|
||||
|
||||
protected FrameLayout mFloatingLayout;
|
||||
protected View mCoverUpLayout;
|
||||
|
||||
@@ -221,9 +217,6 @@ public class MainActivity extends MvpActivity<MainView, MainPresenter> implement
|
||||
}
|
||||
|
||||
private void init() {
|
||||
if (mServiceApis == null) {
|
||||
mServiceApis = MogoApisHandler.getInstance().getApis();
|
||||
}
|
||||
MogoStatusManager.getInstance().setMainPageLaunchedStatus(TAG, true);
|
||||
}
|
||||
|
||||
@@ -417,14 +410,6 @@ public class MainActivity extends MvpActivity<MainView, MainPresenter> implement
|
||||
super.onNewIntent(intent);
|
||||
}
|
||||
|
||||
@Override
|
||||
public IMogoServiceApis getApis() {
|
||||
if (mServiceApis == null) {
|
||||
mServiceApis = MogoApisHandler.getInstance().getApis();
|
||||
}
|
||||
return mServiceApis;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onAutopilotStatusResponse(@NonNull AutopilotStatusInfo autoPilotStatusInfo) {
|
||||
int status = autoPilotStatusInfo.getIpcConnStatus();
|
||||
|
||||
@@ -26,11 +26,4 @@ public interface MainView extends IView {
|
||||
*/
|
||||
void loadModules();
|
||||
|
||||
/**
|
||||
* 接口水龙头
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
IMogoServiceApis getApis();
|
||||
|
||||
}
|
||||
|
||||
@@ -21,8 +21,6 @@ import com.mogo.eagle.core.utilcode.util.UiThreadHandler;
|
||||
import com.mogo.map.location.IMogoLocationClient;
|
||||
import com.mogo.map.location.IMogoLocationListener;
|
||||
import com.mogo.map.navi.MogoCarLocationChangedListenerRegister;
|
||||
import com.mogo.module.common.MogoApisHandler;
|
||||
import com.mogo.service.IMogoServiceApis;
|
||||
|
||||
public
|
||||
/**
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="24px"/>
|
||||
<solid android:color="#1E3062" />
|
||||
</shape>
|
||||
@@ -241,6 +241,7 @@
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvUnit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="km/h"
|
||||
@@ -249,8 +250,22 @@
|
||||
app:layout_constraintTop_toTopOf="@id/ivSpeedAdd"
|
||||
app:layout_constraintBottom_toBottomOf="@id/ivSpeedAdd"
|
||||
app:layout_constraintLeft_toRightOf="@id/ivSpeedAdd"
|
||||
android:layout_marginStart="40px"
|
||||
/>x`
|
||||
android:layout_marginStart="40px" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/tvSureModify"
|
||||
android:layout_width="200px"
|
||||
android:layout_height="135px"
|
||||
android:background="@drawable/taxi_loginout_sure_bg"
|
||||
android:gravity="center"
|
||||
android:text="确定"
|
||||
android:textColor="@android:color/white"
|
||||
android:textSize="42px"
|
||||
android:layout_marginLeft="50px"
|
||||
app:layout_constraintTop_toTopOf="@id/tvSpeed"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvSpeed"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvUnit"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvAcceleration"
|
||||
|
||||
Reference in New Issue
Block a user