Merge branch 'ImproveE255Handling' into improveDeviceControllerDiag
This commit is contained in:
commit
0467db23d1
@ -62,7 +62,6 @@ void DeviceControllerDiag::diagRequest()
|
|||||||
qCritical() << "DeviceControllerDiag::diagRequest() is already running";
|
qCritical() << "DeviceControllerDiag::diagRequest() is already running";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this->machineEventSet.clear();
|
|
||||||
this->isRequestRunning = true;
|
this->isRequestRunning = true;
|
||||||
this->diagRequestTimeoutTimer->start();
|
this->diagRequestTimeoutTimer->start();
|
||||||
|
|
||||||
@ -114,7 +113,7 @@ void DeviceControllerDiag::private_startDiag()
|
|||||||
qCritical() << "DeviceControllerDiag::private_startDiag() interrupted!";
|
qCritical() << "DeviceControllerDiag::private_startDiag() interrupted!";
|
||||||
DCMachineEvent E255Event = DCMachineEvent(DeviceController::State::E255);
|
DCMachineEvent E255Event = DCMachineEvent(DeviceController::State::E255);
|
||||||
if (!this->previousMachineEventSet.contains(E255Event)) {
|
if (!this->previousMachineEventSet.contains(E255Event)) {
|
||||||
previousMachineEventSet.insert(E255Event);
|
machineEventSet.insert(E255Event);
|
||||||
private_sendDiagEvent(E255Event, DeviceController::Action::SET);
|
private_sendDiagEvent(E255Event, DeviceController::Action::SET);
|
||||||
}
|
}
|
||||||
if (this->E255counter > 5) {
|
if (this->E255counter > 5) {
|
||||||
@ -179,7 +178,7 @@ void DeviceControllerDiag::sys_superviseSystem()
|
|||||||
// send
|
// send
|
||||||
DCMachineEvent E255Event = DCMachineEvent(DeviceController::State::E255);
|
DCMachineEvent E255Event = DCMachineEvent(DeviceController::State::E255);
|
||||||
if (!this->previousMachineEventSet.contains(E255Event)) {
|
if (!this->previousMachineEventSet.contains(E255Event)) {
|
||||||
previousMachineEventSet.insert(E255Event);
|
machineEventSet.insert(E255Event);
|
||||||
private_sendDiagEvent(E255Event, DeviceController::Action::SET);
|
private_sendDiagEvent(E255Event, DeviceController::Action::SET);
|
||||||
}
|
}
|
||||||
if (this->E255counter > 5) { this->restartCArun(); }
|
if (this->E255counter > 5) { this->restartCArun(); }
|
||||||
@ -238,6 +237,8 @@ void DeviceControllerDiag::sys_superviseSystem()
|
|||||||
|
|
||||||
void DeviceControllerDiag::sub_componentAssessment()
|
void DeviceControllerDiag::sub_componentAssessment()
|
||||||
{
|
{
|
||||||
|
this->machineEventSet.clear();
|
||||||
|
|
||||||
bool flag_sendOperate = true;
|
bool flag_sendOperate = true;
|
||||||
|
|
||||||
struct T_moduleCondition modCond = {};
|
struct T_moduleCondition modCond = {};
|
||||||
@ -722,8 +723,10 @@ void DeviceControllerDiag::restartCArun()
|
|||||||
|
|
||||||
|
|
||||||
DCMachineEvent W255Event = DCMachineEvent(DeviceController::State::W255);
|
DCMachineEvent W255Event = DCMachineEvent(DeviceController::State::W255);
|
||||||
machineEventSet.insert(W255Event);
|
if (!this->previousMachineEventSet.contains(W255Event)) {
|
||||||
private_sendDiagEvent(W255Event, DeviceController::Action::SET);
|
machineEventSet.insert(W255Event);
|
||||||
|
private_sendDiagEvent(W255Event, DeviceController::Action::SET);
|
||||||
|
}
|
||||||
|
|
||||||
QProcess::startDetached("/bin/systemctl", {"restart", "carun"});
|
QProcess::startDetached("/bin/systemctl", {"restart", "carun"});
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user