Add stop drainage automatically after 30 seconds.

This commit is contained in:
sunwen
2023-12-12 10:13:59 +08:00
parent fc98971904
commit c2fbcf0c02
3 changed files with 16 additions and 1 deletions

View File

@@ -138,6 +138,10 @@ void DeviceManager::initDevice()
mShutDownAction->setTimeoutInterval(SHUT_DOWN_TIMEOUT);
mPumpControlAction = new DmsAsyncAction(USRV_CONTROL, ACT_CTL_PUMP, this, "responsePumpControl(const QString&)", this);
mPumpControlAction->setTimeoutInterval(PUMP_TIMEOUT);
connect(mPumpControlAction, &DmsAsyncAction::timeout, this, [this]()
{
this->processPumpResult("{\"code\":-1}");
});
connect(mGetScanProgressAction, &DmsAsyncAction::timeout, this, &DeviceManager::scanTimeout);
connect(mShutDownAction, &DmsAsyncAction::timeout, this, &DeviceManager::shutdownDmsFailed);