merge special relase to m1-p

This commit is contained in:
yangyakun
2023-03-27 20:46:10 +08:00
271 changed files with 8066 additions and 5560 deletions

View File

@@ -10,7 +10,6 @@ import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils
import com.mogo.eagle.core.utilcode.util.ThreadUtils
import com.mogo.eagle.core.utilcode.util.TimeUtils
import mogo_msg.MogoReportMsg
@@ -70,30 +69,29 @@ class IPCReportManager : IMoGoAutopilotStatusListener {
*工控机监控节点上报
*/
override fun onAutopilotGuardian(guardianInfo: MogoReportMsg.MogoReportMessage?) {
ThreadUtils.runOnUiThread {
guardianInfo?.let{
if(it.resultList.contains(RESULT_AUTOPILOT_DISABLE)
|| it.resultList.contains(RESULT_AUTOPILOT_SYSTEM_UNSTARTED)
|| it.resultList.contains(RESULT_REMOTEPILOT_DISABLE)
|| it.resultList.contains(RESULT_AUTOPILOT_INFERIOR)
|| it.resultList.contains(RESULT_SHOW_WARNING)
|| it.resultList.contains(RESULT_REMOTEPILOT_INFERIOR)){
val reportEntity = ReportEntity(TimeUtils.millis2String(System.currentTimeMillis()),
it.src,it.level,it.msg,it.code,it.resultList,it.actionsList,false)
CallerMsgBoxManager.saveMsgBox(MsgBoxBean(MsgBoxType.REPORT, reportEntity))
}
guardianInfo?.let{
if(it.resultList.contains(RESULT_AUTOPILOT_DISABLE)
|| it.resultList.contains(RESULT_AUTOPILOT_SYSTEM_UNSTARTED)
|| it.resultList.contains(RESULT_REMOTEPILOT_DISABLE)
|| it.resultList.contains(RESULT_AUTOPILOT_INFERIOR)
|| it.resultList.contains(RESULT_SHOW_WARNING)
|| it.resultList.contains(RESULT_REMOTEPILOT_INFERIOR)){
val reportEntity = ReportEntity(TimeUtils.millis2String(System.currentTimeMillis()),
it.src,it.level,it.msg,it.code,it.resultList,it.actionsList,false)
CallerMsgBoxManager.saveMsgBox(MsgBoxBean(MsgBoxType.REPORT, reportEntity))
}
if (reportList.size > 49) {
reportList.removeLast()
}
reportList.add(
0,
ReportEntity(
TimeUtils.millis2String(System.currentTimeMillis()),
it.src, it.level, it.msg, it.code, it.resultList, it.actionsList
,false)
)
reportListFloatWindow?.refreshData(reportList)
if (reportList.size > 49) {
reportList.removeLast()
}
reportList.add(
0,
ReportEntity(
TimeUtils.millis2String(System.currentTimeMillis()),
it.src, it.level, it.msg, it.code, it.resultList, it.actionsList
,false)
)
reportListFloatWindow?.refreshData(reportList)
// //Error 弹窗并有提示音
// if(it.resultList.contains(RESULT_AUTOPILOT_DISABLE)
@@ -130,7 +128,6 @@ class IPCReportManager : IMoGoAutopilotStatusListener {
// }
// }
// }
}
}
}

View File

@@ -12,6 +12,7 @@ import com.zhjt.mogo_core_function_devatools.status.entity.CanStatus
import com.zhjt.mogo_core_function_devatools.status.flow.IFlow
import kotlinx.coroutines.Job
import mogo_msg.MogoReportMsg.MogoReportMessage
import planning.RoboSweeperTaskIndexOuterClass
import system_master.SystemStatusInfo.StatusInfo
import java.util.concurrent.atomic.AtomicInteger
@@ -94,10 +95,13 @@ internal class CanImpl(ctx: Context) :
send(CanStatus(isCanEnabled()))
}
override fun onSweeperFutianCleanSystemState(cleanSystemState: ChassisStatesOuterClass.SweeperFuTianTaskSystemStates) {
send(CanStatus(isCanEnabled()))
}
override fun onSweeperFutianTaskIndexData(roboSweeperTaskIndex: RoboSweeperTaskIndexOuterClass.RoboSweeperTaskIndex) {
}
override fun onAutopilotGuardian(guardianInfo: MogoReportMessage?) {
super.onAutopilotGuardian(guardianInfo)
send(CanStatus(isCanEnabled()))