|
@ -50,8 +50,11 @@ void DisinfectionCtrlServiceExt::initialize() { |
|
|
REG_EXTFN_VOID(getServiceConfig, void()); |
|
|
REG_EXTFN_VOID(getServiceConfig, void()); |
|
|
REG_EXTFN_VOID(startStateReport, void()); |
|
|
REG_EXTFN_VOID(startStateReport, void()); |
|
|
REG_EXTFN_VOID(stopStateReport, void()); |
|
|
REG_EXTFN_VOID(stopStateReport, void()); |
|
|
REG_EXTFN_VOID(clearHandleStopPumpInjectionFlag, void()); |
|
|
|
|
|
|
|
|
REG_EXTFN_VOID(handleStopPumpInjection, void()); |
|
|
|
|
|
REG_EXTFN_VOID(handleStartPumpInjection, void()); |
|
|
REG_EXTFN_VOID(setHandleStopPumpInjectionFlag, void()); |
|
|
REG_EXTFN_VOID(setHandleStopPumpInjectionFlag, void()); |
|
|
|
|
|
REG_EXTFN_VOID(clearHandleStopPumpInjectionFlag, void()); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
stateUpdateThread.reset(new Thread("DisinfectionCtrlServiceExt-stateUpdateThread", [this]() { |
|
|
stateUpdateThread.reset(new Thread("DisinfectionCtrlServiceExt-stateUpdateThread", [this]() { |
|
|
ThisThread thisThread; |
|
|
ThisThread thisThread; |
|
@ -109,12 +112,21 @@ void DisinfectionCtrlServiceExt::setRealtimeConfig(shared_ptr<MsgProcessContext> |
|
|
dcs->getRealtimeCfg()[key] = val; |
|
|
dcs->getRealtimeCfg()[key] = val; |
|
|
dcs->updateCfg(); |
|
|
dcs->updateCfg(); |
|
|
} |
|
|
} |
|
|
|
|
|
void DisinfectionCtrlServiceExt::handleStopPumpInjection(shared_ptr<MsgProcessContext> cxt) { |
|
|
|
|
|
dcs->handleStopPumpInjection(); |
|
|
|
|
|
if (stateUpdateThread) stateUpdateThread->wake(); |
|
|
|
|
|
} |
|
|
|
|
|
void DisinfectionCtrlServiceExt::handleStartPumpInjection(shared_ptr<MsgProcessContext> cxt) { |
|
|
|
|
|
dcs->handleStartPumpInjection(); |
|
|
|
|
|
if (stateUpdateThread) stateUpdateThread->wake(); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
void DisinfectionCtrlServiceExt::clearHandleStopPumpInjectionFlag(shared_ptr<MsgProcessContext> cxt) { |
|
|
void DisinfectionCtrlServiceExt::clearHandleStopPumpInjectionFlag(shared_ptr<MsgProcessContext> cxt) { |
|
|
dcs->clearHandleStopPumpInjectionFlag(); |
|
|
|
|
|
|
|
|
dcs->handleStopPumpInjection(); |
|
|
if (stateUpdateThread) stateUpdateThread->wake(); |
|
|
if (stateUpdateThread) stateUpdateThread->wake(); |
|
|
} |
|
|
} |
|
|
void DisinfectionCtrlServiceExt::setHandleStopPumpInjectionFlag(shared_ptr<MsgProcessContext> cxt) { |
|
|
void DisinfectionCtrlServiceExt::setHandleStopPumpInjectionFlag(shared_ptr<MsgProcessContext> cxt) { |
|
|
dcs->setHandleStopPumpInjectionFlag(); |
|
|
|
|
|
|
|
|
dcs->handleStartPumpInjection(); |
|
|
if (stateUpdateThread) stateUpdateThread->wake(); |
|
|
if (stateUpdateThread) stateUpdateThread->wake(); |
|
|
} |
|
|
} |
|
|
void DisinfectionCtrlServiceExt::getState(shared_ptr<MsgProcessContext> cxt) { cxt->rely = getState(); } |
|
|
void DisinfectionCtrlServiceExt::getState(shared_ptr<MsgProcessContext> cxt) { cxt->rely = getState(); } |
|
|