调试窗

司机屏增加重启工控机节点按钮
This commit is contained in:
xuxinchao
2022-06-14 17:22:27 +08:00
committed by liujing
parent 6d0e7fa565
commit 5fdea95846
5 changed files with 40 additions and 0 deletions

View File

@@ -371,6 +371,14 @@ class MoGoAutopilotProvider :
}
}
/**
* 发送工控机所有节点重启命令
*/
override fun sendIpcReboot() {
//重启所有节点
AdasManager.getInstance().sendSystemCmdReq(MessagePad.SystemCmdType.SYSTEMCMD_REBOOT)
}
/**
* 办公室调试使用,强制开启自动驾驶,将 statuspilotModecontrol_pilotMode强追设置为 1
* isEnable = true 开启

View File

@@ -553,6 +553,16 @@ class DebugSettingView @JvmOverloads constructor(
tbIsRainMode.visibility = View.GONE
}
//重启工控机所有节点
btnIpcReboot.onClick{
CallerAutoPilotManager.sendIpcReboot()
ToastUtils.showLong("重启命令已发送")
}
//只在司机端设置工控机节点重启功能
if(AppIdentityModeUtils.isPassenger(FunctionBuildConfig.appIdentityMode)){
btnIpcReboot.visibility = View.GONE
}
// 强制绘制引导线
tbIsDrawAutopilotTrajectoryData.setOnCheckedChangeListener { _, isChecked ->
FunctionBuildConfig.isIgnoreConditionsDrawAutopilotTrajectoryData = isChecked

View File

@@ -232,6 +232,16 @@
android:textSize="@dimen/dp_24"
android:background="@drawable/radio_button_normal_background_right"/>
<Button
android:id="@+id/btnIpcReboot"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="@dimen/dp_10"
android:text="重启IPC节点"
android:textSize="@dimen/dp_24"
android:background="@drawable/radio_button_normal_background_right"
/>
<ToggleButton
android:id="@+id/tbDeviceBind"
android:layout_width="match_parent"

View File

@@ -127,6 +127,11 @@ interface IMoGoAutopilotProvider : IMoGoFunctionServerProvider {
*/
fun setRainMode(isEnable: Boolean)
/**
* 发送工控机所有节点重启命令
*/
fun sendIpcReboot()
/**
* 办公室调试使用,强制开启自动驾驶,将 statuspilotmodecontrol_pilotmode强追设置为 1
* isEnable = true 开启

View File

@@ -165,6 +165,13 @@ object CallerAutoPilotManager {
providerApi?.setRainMode(isEnable)
}
/**
* 发送工控机所有节点重启命令
*/
fun sendIpcReboot(){
providerApi?.sendIpcReboot()
}
/**
* 办公室调试使用,强制开启自动驾驶,将 statuspilotmodecontrol_pilotmode强追设置为 1
* isEnable = true 开启