调试窗修改
增加断开工控机连接功能入口
This commit is contained in:
@@ -207,6 +207,13 @@ class MoGoAutopilotProvider :
|
||||
}, 1000, TimeUnit.MILLISECONDS)
|
||||
}
|
||||
|
||||
/**
|
||||
* 断开与工控机的连接
|
||||
*/
|
||||
override fun disconnectIpc() {
|
||||
AdasManager.getInstance().disconnect()
|
||||
}
|
||||
|
||||
override fun onMapCollectStart(cmdId: Int, cmdTime: Long) {
|
||||
val result = recordPackage(2, cmdId)
|
||||
CallerLogger.d("$M_ADAS_IMPL$TAG", "开始记录包: [$cmdId, $result]")
|
||||
|
||||
@@ -396,9 +396,6 @@ class DebugSettingView @JvmOverloads constructor(
|
||||
//日志中心事件点击监听
|
||||
setLogCheckedChangeListener()
|
||||
|
||||
|
||||
|
||||
|
||||
//OBU配置信息
|
||||
tvObuInfo.text = CallerObuListenerManager.getObuStatusInfoJsonString()
|
||||
|
||||
@@ -527,6 +524,10 @@ class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
//断开与工控机的连接
|
||||
btnDisconnectIpc.setOnClickListener {
|
||||
CallerAutoPilotManager.disconnectIpc()
|
||||
}
|
||||
|
||||
updateSpeedSettingViews()
|
||||
|
||||
@@ -966,7 +967,7 @@ class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
|
||||
override fun upgradeVersionUrls(urls: Map<String, String>?) {
|
||||
//todo 版本信息更新
|
||||
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
@@ -604,13 +604,28 @@
|
||||
app:layout_constraintTop_toTopOf="@id/btnSetAutopilotIP"
|
||||
app:layout_constraintBottom_toBottomOf="@id/btnSetAutopilotIP"
|
||||
app:layout_constraintLeft_toRightOf="@id/btnSetAutopilotIP"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@id/btnDisconnectIpc"
|
||||
android:layout_marginStart="@dimen/dp_30"
|
||||
android:layout_marginEnd="@dimen/dp_30"
|
||||
android:layout_marginEnd="@dimen/dp_20"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnDisconnectIpc"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="断开工控机连接"
|
||||
android:textSize="@dimen/dp_24"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@id/btnSetAutopilotIP"
|
||||
app:layout_constraintBottom_toBottomOf="@id/btnSetAutopilotIP"
|
||||
android:layout_marginEnd="@dimen/dp_30"
|
||||
android:paddingStart="@dimen/dp_15"
|
||||
android:paddingEnd="@dimen/dp_15"
|
||||
/>
|
||||
|
||||
<View
|
||||
android:id="@+id/autopilotIPDivider"
|
||||
android:layout_width="match_parent"
|
||||
@@ -1557,7 +1572,6 @@
|
||||
android:textSize="@dimen/dp_24" />
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</ScrollView>
|
||||
|
||||
@@ -17,6 +17,11 @@ interface IMoGoAutopilotProvider : IMoGoFunctionServerProvider {
|
||||
*/
|
||||
fun resetIpAddress(autoPilotIp: String)
|
||||
|
||||
/**
|
||||
* 断开与工控机的连接
|
||||
*/
|
||||
fun disconnectIpc()
|
||||
|
||||
/**
|
||||
* 开启自动驾驶
|
||||
*
|
||||
|
||||
@@ -31,6 +31,13 @@ object CallerAutoPilotManager {
|
||||
providerApi?.resetIpAddress(autoPilotIp)
|
||||
}
|
||||
|
||||
/**
|
||||
* 断开与工控机的连接
|
||||
*/
|
||||
fun disconnectIpc(){
|
||||
providerApi?.disconnectIpc()
|
||||
}
|
||||
|
||||
/**
|
||||
* 开启自动驾驶
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user