From 09bc958ac9d9d0a31d56b61509f2fb1430169b25 Mon Sep 17 00:00:00 2001 From: zhaohe Date: Fri, 16 Aug 2024 09:32:41 +0800 Subject: [PATCH] recode --- appsrc/appbase/appbasedep.hpp | 16 +++++ appsrc/appbase/appbean/hardware_component.hpp | 6 +- appsrc/appbase/dep.hpp | 29 ++++----- appsrc/appbase/disinfection_snapshot.hpp | 14 ++--- appsrc/appbase/gconfig.hpp | 35 ----------- appsrc/appbase/project_setting.hpp | 36 ----------- appsrc/appbase/project_setting_mgr.cpp | 64 -------------------- appsrc/appbase/project_setting_mgr.hpp | 69 ---------------------- .../transmit_disinfection_can_master.cpp | 2 +- .../transmit_disinfection_can_master.hpp | 10 ++-- appsrc/appsetting/appsetting.hpp | 3 + .../project_setting/basic/componentid.hpp | 25 ++++++++ .../appsetting/project_setting/basic/gconfig.hpp | 32 ++++++++++ .../project_setting/basic/project_constant.hpp | 34 +++++++++++ .../project_setting/component_id_mgr.cpp | 68 +++++++++++++++++++++ .../project_setting/component_id_mgr.hpp | 0 .../appsetting/project_setting/project_setting.hpp | 58 ++++++++++++++++++ .../project_setting/project_setting_mgr.cpp | 63 ++++++++++++++++++++ .../project_setting/project_setting_mgr.hpp | 47 +++++++++++++++ appsrc/baseservice/db/setting_db_dao.hpp | 4 +- .../iflytop_front_end_service.hpp | 2 + appsrc/baseservice/udisk_mgr_service.hpp | 2 +- appsrc/main.cpp | 1 + appsrc/service/app/air_tightness_test.cpp | 26 ++++---- appsrc/service/app/air_tightness_test.hpp | 2 +- appsrc/service/disinfection_logs_service.hpp | 2 + appsrc/service/hardware/base/component_id_mgr.cpp | 55 ----------------- appsrc/service/hardware/base/component_id_mgr.hpp | 41 ------------- appsrc/service/hardware/device_ctrl_service.cpp | 13 ++-- appsrc/service/hardware/device_ctrl_service.hpp | 10 ++-- appsrc/service/main_control_service.cpp | 3 +- appsrc/service/main_control_service.hpp | 1 + 32 files changed, 409 insertions(+), 364 deletions(-) create mode 100644 appsrc/appbase/appbasedep.hpp delete mode 100644 appsrc/appbase/gconfig.hpp delete mode 100644 appsrc/appbase/project_setting.hpp delete mode 100644 appsrc/appbase/project_setting_mgr.cpp delete mode 100644 appsrc/appbase/project_setting_mgr.hpp create mode 100644 appsrc/appsetting/appsetting.hpp create mode 100644 appsrc/appsetting/project_setting/basic/componentid.hpp create mode 100644 appsrc/appsetting/project_setting/basic/gconfig.hpp create mode 100644 appsrc/appsetting/project_setting/basic/project_constant.hpp create mode 100644 appsrc/appsetting/project_setting/component_id_mgr.cpp create mode 100644 appsrc/appsetting/project_setting/component_id_mgr.hpp create mode 100644 appsrc/appsetting/project_setting/project_setting.hpp create mode 100644 appsrc/appsetting/project_setting/project_setting_mgr.cpp create mode 100644 appsrc/appsetting/project_setting/project_setting_mgr.hpp delete mode 100644 appsrc/service/hardware/base/component_id_mgr.cpp delete mode 100644 appsrc/service/hardware/base/component_id_mgr.hpp diff --git a/appsrc/appbase/appbasedep.hpp b/appsrc/appbase/appbasedep.hpp new file mode 100644 index 0000000..80207f4 --- /dev/null +++ b/appsrc/appbase/appbasedep.hpp @@ -0,0 +1,16 @@ +#pragma once + +#include "iflytop/core/components/jobs/work_queue.hpp" +#include "iflytop/core/components/stringutils.hpp" +#include "iflytop/core/components/timeutils.hpp" +#include "iflytop/core/core.hpp" +#include "iflytop/core/utils/uuid/uuid.hpp" +// +#include "app_protocols/apperrorcode/apperrorcode.hpp" +#include "app_protocols/appexception/appexception.hpp" +#include "app_protocols/transmit_disfection_protocol/transmit_disfection_protocol.hpp" + +// +#include "components/sqlite_orm/sqlite_orm.hpp" +#include "components/uart_printer/uart_printer.hpp" +#include "components/zservice_container/zservice_container.hpp" \ No newline at end of file diff --git a/appsrc/appbase/appbean/hardware_component.hpp b/appsrc/appbase/appbean/hardware_component.hpp index 58e5304..91603a9 100644 --- a/appsrc/appbase/appbean/hardware_component.hpp +++ b/appsrc/appbase/appbean/hardware_component.hpp @@ -12,12 +12,14 @@ marco(type, WarningLight) /**/ \ marco(type, PositivePressureProportional) /**/ \ marco(type, NegativePressureProportional) /**/ \ - marco(type, LeakDetectTest) /**/ \ + marco(type, AirLeakDetectTestAC) /**/ \ + marco(type, AirLeakDetectTestChannelCtrl) /**/ \ marco(type, ExtChSelector) /**/ \ marco(type, EvaporationBinWS) /**/ \ marco(type, DeviceBottomWS) /**/ \ marco(type, MainH2O2Sensor) /**/ \ - marco(type, LeakDetectPS) /**/ \ + marco(type, ACPostPS) /**/ \ + marco(type, AirLeakDetectPS) /**/ \ marco(type, LiquidWeightPS) /**/ \ marco(type, SprayPumpPostPS) /**/ \ marco(type, AddLiquidPumpPostPS) /**/ diff --git a/appsrc/appbase/dep.hpp b/appsrc/appbase/dep.hpp index 546bcf3..23c98d9 100644 --- a/appsrc/appbase/dep.hpp +++ b/appsrc/appbase/dep.hpp @@ -1,23 +1,14 @@ #pragma once - -#include "iflytop/core/components/jobs/work_queue.hpp" -#include "iflytop/core/components/stringutils.hpp" -#include "iflytop/core/components/timeutils.hpp" -#include "iflytop/core/core.hpp" -#include "iflytop/core/utils/uuid/uuid.hpp" -// -#include "app_protocols/apperrorcode/apperrorcode.hpp" -#include "app_protocols/appexception/appexception.hpp" +#include "appbasedep.hpp" // -#include "components/sqlite_orm/sqlite_orm.hpp" -#include "components/uart_printer/uart_printer.hpp" -#include "components/zservice_container/zservice_container.hpp" - -// -#include "gconfig.hpp" -#include "project_setting.hpp" -#include "project_setting_mgr.hpp" -#include "utils/zdictionary.hpp" -#include "disinfection_state.hpp" #include "appbase/appbean/setting_id.hpp" #include "appbean/pumpid.hpp" +#include "disinfection_state.hpp" +#include "utils/zdictionary.hpp" + +#include "appbase/appbean/disinfection_record_csv_header.hpp" +#include "appbase/appbean/disinfection_state.hpp" +#include "appbase/appbean/hardware_component.hpp" +#include "appbase/appbean/setting_id.hpp" +#include "appbase/appbean/pumpid.hpp" +#include "appbase/appbean/test_page_iterm.hpp" \ No newline at end of file diff --git a/appsrc/appbase/disinfection_snapshot.hpp b/appsrc/appbase/disinfection_snapshot.hpp index 556b3fd..42bd0b5 100644 --- a/appsrc/appbase/disinfection_snapshot.hpp +++ b/appsrc/appbase/disinfection_snapshot.hpp @@ -1,20 +1,20 @@ #pragma once +#include "appbean/disinfection_state.hpp" #include "disinfection_state.hpp" #include "iflytop/core/components/timeutils.hpp" -#include "project_setting.hpp" namespace iflytop { using namespace core; class StateSnapshot { public: - disinfection_state_t state; - zsystem_tp time; + DisinfectionState state; + zsystem_tp time; - int32_t h2o2[MAX_SUPPORT_SENSOR]; // ppm - int32_t humid[MAX_SUPPORT_SENSOR]; // %RH - int32_t temp[MAX_SUPPORT_SENSOR]; // °C - int32_t saturation[MAX_SUPPORT_SENSOR]; // %RS + int32_t h2o2[10]; // ppm + int32_t humid[10]; // %RH + int32_t temp[10]; // °C + int32_t saturation[10]; // %RS int min_h2o2; int max_h2o2; diff --git a/appsrc/appbase/gconfig.hpp b/appsrc/appbase/gconfig.hpp deleted file mode 100644 index 568920a..0000000 --- a/appsrc/appbase/gconfig.hpp +++ /dev/null @@ -1,35 +0,0 @@ - -#pragma once -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "iflytop/core/components/config_template/config_template.hpp" - -#define PROJECT_LARGE_SPACE_DM "LargeSpaceDM" -#define PROJECT_SMALL_SPACE_DM "SmallSpaceDM" -#define PROJECT_PIPE_DM "PipeDM" -#define PROJECT_DRAW_BAR_DM "DrawBarDM" - -#define ConfigELEMENT_LIST(marco) \ - marco(string /* */, deviceId, "") /*设备ID*/ \ - marco(string /* */, canIF, "can0") /*子设备Can设备名称*/ \ - marco(int32_t /* */, canBitrate, 500000) /*子设备Can设备波特率*/ \ - marco(float /* */, dvalueCoefficient, 2) /*数值越小,相对消毒时间越长*/ \ - marco(float /* */, disinfectantWeightCorrectionFactor, 0.8500000238418579) /**/ \ - marco(string /* */, printerUart, "/dev/ttyS5") /**/ \ - marco(string /* */, projectType, PROJECT_LARGE_SPACE_DM) /**/ \ - marco(bool /* */, testMode, false) /**/ - -configTemplateDEFILE_CONFIG_SERVICE2( // - GConfig, // - ConfigELEMENT_LIST, // - "./configs/config.json", {}); diff --git a/appsrc/appbase/project_setting.hpp b/appsrc/appbase/project_setting.hpp deleted file mode 100644 index 9f3b828..0000000 --- a/appsrc/appbase/project_setting.hpp +++ /dev/null @@ -1,36 +0,0 @@ -#pragma once -#define LINUX_HARDWARE_ID (0x02) - -/******************************************************************************* - * LINUX_HARDWARE_REG * - *******************************************************************************/ - -#define REG_REBOOT_FLAG 0x0000 // 重启标识 -#define REG_DEVICE_ID 0x0001 // 重启标识 -#define REG_EXCEPTION_FLAG 0x0100 // 异常标志位 - -#define EMTPTY_LINE_WHEN_DISINFECTION 60 - -#define MAX_DISINFECTIONLOGGER_FILE_NUM 10 // 最大日志文件数量 -#define USER_BEHAVIOR_RECORD_DB_MAX_RECORDS 3000 // -#define SENSOR_PREHEART_TIME_S (5 * 60) // 传感器预热时间 - -#define VERSION "1.0.0" -#define PROJECT_NAME "TRANSMIT_DM" - -#define MAX_SUPPORT_SENSOR 3 - -// GPM_TO_SPEED_RADIO -#define LARGE_SPACE_DM_GPM_TO_SPEED_RADIO (11.0250) -#define SMALL_SPACE_DM_GPM_TO_SPEED_RADIO (11.0250) -#define PIPE_DM_GPM_TO_SPEED_RADIO (11.0250) -#define DRAW_BAR_DM_GPM_TO_SPEED_RADIO (41.97) - -// EXT_SENSOR_NUM -#define LARGE_SPACE_DM_EXT_SENSOR_NUM (2) -#define SMALL_SPACE_DM_EXT_SENSOR_NUM (2) -#define PIPE_DM_EXT_SENSOR_NUM (0) -#define DRAW_BAR_DM_EXT_SENSOR_NUM (0) - -#define POSITIVE_PRESSURE_PROPORTIONAL_ID 0x01 -#define NEGATIVE_PRESSURE_PROPORTIONAL_ID 0x02 diff --git a/appsrc/appbase/project_setting_mgr.cpp b/appsrc/appbase/project_setting_mgr.cpp deleted file mode 100644 index 8c6b829..0000000 --- a/appsrc/appbase/project_setting_mgr.cpp +++ /dev/null @@ -1,64 +0,0 @@ -#include "project_setting_mgr.hpp" - -#include "components/zservice_container/zservice_container.hpp" -#include "project_setting.hpp" -using namespace std; -using namespace iflytop; - -static string projectType2Str(int val) { - switch (val) { - case klarge_space_disinfection_machine: - return PROJECT_LARGE_SPACE_DM; - case ksmall_space_disinfection_machine: - return PROJECT_SMALL_SPACE_DM; - case kpipe_disinfection_machine: - return PROJECT_PIPE_DM; - case kdraw_bar_disinfection_box: - return PROJECT_DRAW_BAR_DM; - default: - return "not-support"; - } -} - -void ProjectSettingMgr::initialize() { - GET_TO_SERVICE(gConfig); - - projectSettingsMap[PROJECT_LARGE_SPACE_DM] = createProjectSetting(klarge_space_disinfection_machine); - projectSettingsMap[PROJECT_SMALL_SPACE_DM] = createProjectSetting(ksmall_space_disinfection_machine); - projectSettingsMap[PROJECT_PIPE_DM] = createProjectSetting(kpipe_disinfection_machine); - projectSettingsMap[PROJECT_DRAW_BAR_DM] = createProjectSetting(kdraw_bar_disinfection_box); -} - -shared_ptr ProjectSettingMgr::createProjectSetting(int projectTypeInt) { - shared_ptr projectSetting = make_shared(); - projectSetting->projectTypeInt = projectTypeInt; - projectSetting->projectType = projectType2Str(projectTypeInt); - - if (projectTypeInt == klarge_space_disinfection_machine) { - projectSetting->extSensorNum = LARGE_SPACE_DM_EXT_SENSOR_NUM; - projectSetting->gpmToSpeedRadio = LARGE_SPACE_DM_GPM_TO_SPEED_RADIO; - } else if (projectTypeInt == ksmall_space_disinfection_machine) { - projectSetting->extSensorNum = SMALL_SPACE_DM_EXT_SENSOR_NUM; - projectSetting->gpmToSpeedRadio = SMALL_SPACE_DM_GPM_TO_SPEED_RADIO; - } else if (projectTypeInt == kpipe_disinfection_machine) { - projectSetting->extSensorNum = PIPE_DM_EXT_SENSOR_NUM; - projectSetting->gpmToSpeedRadio = PIPE_DM_GPM_TO_SPEED_RADIO; - } else if (projectTypeInt == kdraw_bar_disinfection_box) { - projectSetting->extSensorNum = DRAW_BAR_DM_EXT_SENSOR_NUM; - projectSetting->gpmToSpeedRadio = DRAW_BAR_DM_GPM_TO_SPEED_RADIO; - } else { - ZCHECK(false, "projectTypeInt not support: " + to_string(projectTypeInt)); - } - - return projectSetting; -} -shared_ptr ProjectSettingMgr::getProjectSetting() { return getProjectSetting(gConfig->get_projectType()); } - -shared_ptr ProjectSettingMgr::getProjectSetting(string projectType) { - auto val = projectSettingsMap[projectType]; - ZCHECK(val != nullptr, "projectType not found: " + projectType); - return val; -} -shared_ptr ProjectSettingMgr::getProjectSetting(int projectTypeInt) { return getProjectSetting(projectType2Str(projectTypeInt)); } - -int32_t ProjectSettingMgr::getProjType() { return getProjectSetting()->projectTypeInt; } diff --git a/appsrc/appbase/project_setting_mgr.hpp b/appsrc/appbase/project_setting_mgr.hpp deleted file mode 100644 index c46461b..0000000 --- a/appsrc/appbase/project_setting_mgr.hpp +++ /dev/null @@ -1,69 +0,0 @@ -#pragma once -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "gconfig.hpp" -// -#include "app_protocols/transmit_disfection_protocol/transmit_disfection_protocol.hpp" -// -namespace iflytop { -using namespace std; -using namespace transmit_disfection_protocol; - -class ProjectSetting { - public: - string projectType = PROJECT_LARGE_SPACE_DM; - int projectTypeInt = klarge_space_disinfection_machine; - - // - // some properties - // - int extSensorNum = 0; - double gpmToSpeedRadio = 0; - - public: - bool isLageSpaceDM() { return projectTypeInt == klarge_space_disinfection_machine; } - bool isSmallSpaceDM() { return projectTypeInt == ksmall_space_disinfection_machine; } - bool isPipeDM() { return projectTypeInt == kpipe_disinfection_machine; } - bool isDrawBarDM() { return projectTypeInt == kdraw_bar_disinfection_box; } - - bool isProjectType(int id) { return id == projectTypeInt; } - bool isProjectType(int id0, int id1) { return id0 == projectTypeInt || id1 == projectTypeInt; } - bool isProjectType(int id0, int id1, int id2) { return id0 == projectTypeInt || id1 == projectTypeInt || id2 == projectTypeInt; } - bool isProjectType(int id0, int id1, int id2, int id3) { return id0 == projectTypeInt || id1 == projectTypeInt || id2 == projectTypeInt || id3 == projectTypeInt; } -}; - -class ProjectSettingMgr { - THISCLASS(ProjectSettingMgr); - - private: - /* data */ - - map> projectSettingsMap; - shared_ptr gConfig; - - public: - void initialize(); - - public: - shared_ptr getProjectSetting(); - int32_t getProjType(); - - private: - shared_ptr getProjectSetting(string projectType); - shared_ptr getProjectSetting(int projectTypeInt); - shared_ptr createProjectSetting(int projectTypeInt); -}; - -} // namespace iflytop - -#define PROJECT_TYPE (GET_SERVICE(ProjectSettingMgr)->getProjType()) -#define PROJECT_SETTING (GET_SERVICE(ProjectSettingMgr)->getProjectSetting()) \ No newline at end of file diff --git a/appsrc/appcomponents/canchannel/transmit_disinfection_can_master.cpp b/appsrc/appcomponents/canchannel/transmit_disinfection_can_master.cpp index fccfd2a..0798bb0 100644 --- a/appsrc/appcomponents/canchannel/transmit_disinfection_can_master.cpp +++ b/appsrc/appcomponents/canchannel/transmit_disinfection_can_master.cpp @@ -86,7 +86,7 @@ int TransmitDisinfectionCanMaster::airCompressorReadEIAdcRaw(int boardid) { // return rec->getContent(0); } -int TransmitDisinfectionCanMaster::leakDetectTestACCtrl(int boardid, int32_t val) { +int TransmitDisinfectionCanMaster::airLeakDetectTestACCtrl(int boardid, int32_t val) { auto rec = m_com->callcmd1(boardid, kfn_air_tightness_test_ac_ctrl, val); return rec->getContent(0); } diff --git a/appsrc/appcomponents/canchannel/transmit_disinfection_can_master.hpp b/appsrc/appcomponents/canchannel/transmit_disinfection_can_master.hpp index 174e060..44c9739 100644 --- a/appsrc/appcomponents/canchannel/transmit_disinfection_can_master.hpp +++ b/appsrc/appcomponents/canchannel/transmit_disinfection_can_master.hpp @@ -90,8 +90,8 @@ class TransmitDisinfectionCanMaster { int airCompressorReadEIAdcRaw(int boardid); int airCompressorIsOpen(int boardid) { return m_com->callcmd0(boardid, kfn_air_compressor_is_open, DEFUALT_OVERTIME)->getContent(0); } - int leakDetectTestACCtrl(int boardid, int32_t val); - int leakDetectTestACIsOpen(int boardid) { return m_com->callcmd0(boardid, kfn_air_tightness_test_ac_is_open, DEFUALT_OVERTIME)->getContent(0); } + int airLeakDetectTestACCtrl(int boardid, int32_t val); + int airLeakDetectTestACIsOpen(int boardid) { return m_com->callcmd0(boardid, kfn_air_tightness_test_ac_is_open, DEFUALT_OVERTIME)->getContent(0); } /*********************************************************************************************************************** * heater * @@ -126,9 +126,9 @@ class TransmitDisinfectionCanMaster { int proportionalIsBusy(int boardid, int valveId) { return m_com->callcmd1(boardid, kfn_proportional_is_busy, valveId, DEFUALT_OVERTIME)->getContent(0); } // kfn_air_tightness_test_is_cutoff - void leakDetectTestCloseOffCh(int boardid) { m_com->callcmd0(boardid, kfn_air_tightness_test_cutoff_ch, DEFUALT_OVERTIME); } - void leakDetectTestReleaseCh(int boardid) { m_com->callcmd0(boardid, kfn_air_tightness_test_release_ch, DEFUALT_OVERTIME); } - int leakDetectTestIsCutoff(int boardid) { return m_com->callcmd0(boardid, kfn_air_tightness_test_is_cutoff, DEFUALT_OVERTIME)->getContent(0); } + void airLeakDetectTestCloseOffCh(int boardid) { m_com->callcmd0(boardid, kfn_air_tightness_test_cutoff_ch, DEFUALT_OVERTIME); } + void airLeakDetectTestReleaseCh(int boardid) { m_com->callcmd0(boardid, kfn_air_tightness_test_release_ch, DEFUALT_OVERTIME); } + int airLeakDetectTestIsCutoff(int boardid) { return m_com->callcmd0(boardid, kfn_air_tightness_test_is_cutoff, DEFUALT_OVERTIME)->getContent(0); } void extChSelectorSetCh(int boardid, int ch) { m_com->callcmd1(boardid, kfn_ext_ch_selector_set_ch, ch, DEFUALT_OVERTIME); } int extChSelectorGetCh(int boardid) { return m_com->callcmd0(boardid, kfn_ext_ch_selector_get_ch, DEFUALT_OVERTIME)->getContent(0); } diff --git a/appsrc/appsetting/appsetting.hpp b/appsrc/appsetting/appsetting.hpp new file mode 100644 index 0000000..3dac55a --- /dev/null +++ b/appsrc/appsetting/appsetting.hpp @@ -0,0 +1,3 @@ +#pragma once +#include "project_setting/project_setting_mgr.hpp" + diff --git a/appsrc/appsetting/project_setting/basic/componentid.hpp b/appsrc/appsetting/project_setting/basic/componentid.hpp new file mode 100644 index 0000000..b10b980 --- /dev/null +++ b/appsrc/appsetting/project_setting/basic/componentid.hpp @@ -0,0 +1,25 @@ +#pragma once +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "appbase/appbasedep.hpp" + +namespace iflytop { +using namespace std; + +class ComponentId { + public: + ComponentId(int boardId, int subId) : boardId(boardId), subId(subId) {} + int boardId; + int subId; +}; + +} // namespace iflytop \ No newline at end of file diff --git a/appsrc/appsetting/project_setting/basic/gconfig.hpp b/appsrc/appsetting/project_setting/basic/gconfig.hpp new file mode 100644 index 0000000..24f8b12 --- /dev/null +++ b/appsrc/appsetting/project_setting/basic/gconfig.hpp @@ -0,0 +1,32 @@ + +#pragma once +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "iflytop/core/components/config_template/config_template.hpp" +#include "project_constant.hpp" + + +#define ConfigELEMENT_LIST(marco) \ + marco(string /* */, deviceId, "") /*设备ID*/ \ + marco(string /* */, canIF, "can0") /*子设备Can设备名称*/ \ + marco(int32_t /* */, canBitrate, 500000) /*子设备Can设备波特率*/ \ + marco(float /* */, dvalueCoefficient, 2) /*数值越小,相对消毒时间越长*/ \ + marco(float /* */, disinfectantWeightCorrectionFactor, 0.8500000238418579) /**/ \ + marco(string /* */, printerUart, "/dev/ttyS5") /**/ \ + marco(string /* */, projectType, PROJECT_LARGE_SPACE_DM) /**/ \ + marco(bool /* */, testMode, false) /**/ + +configTemplateDEFILE_CONFIG_SERVICE2( // + GConfig, // + ConfigELEMENT_LIST, // + "./configs/config.json", {}); diff --git a/appsrc/appsetting/project_setting/basic/project_constant.hpp b/appsrc/appsetting/project_setting/basic/project_constant.hpp new file mode 100644 index 0000000..6f3a4dc --- /dev/null +++ b/appsrc/appsetting/project_setting/basic/project_constant.hpp @@ -0,0 +1,34 @@ +#pragma once +#define VERSION "1.0.0" +#define PROJECT_NAME "TRANSMIT_DM" + +#define PROJECT_LARGE_SPACE_DM "LargeSpaceDM" +#define PROJECT_SMALL_SPACE_DM "SmallSpaceDM" +#define PROJECT_PIPE_DM "PipeDM" +#define PROJECT_DRAW_BAR_DM "DrawBarDM" + +/******************************************************************************* + * LINUX_HARDWARE_REG * + *******************************************************************************/ +#define EMTPTY_LINE_WHEN_DISINFECTION 60 + +#define MAX_DISINFECTIONLOGGER_FILE_NUM 10 // 最大日志文件数量 +#define USER_BEHAVIOR_RECORD_DB_MAX_RECORDS 3000 // +#define SENSOR_PREHEART_TIME_S (5 * 60) // 传感器预热时间 + +#define MAX_SUPPORT_SENSOR 3 + +// GPM_TO_SPEED_RADIO +#define LARGE_SPACE_DM_GPM_TO_SPEED_RADIO (11.0250) +#define SMALL_SPACE_DM_GPM_TO_SPEED_RADIO (11.0250) +#define PIPE_DM_GPM_TO_SPEED_RADIO (11.0250) +#define DRAW_BAR_DM_GPM_TO_SPEED_RADIO (41.97) + +// EXT_SENSOR_NUM +#define LARGE_SPACE_DM_EXT_SENSOR_NUM (2) +#define SMALL_SPACE_DM_EXT_SENSOR_NUM (2) +#define PIPE_DM_EXT_SENSOR_NUM (0) +#define DRAW_BAR_DM_EXT_SENSOR_NUM (0) + +#define POSITIVE_PRESSURE_PROPORTIONAL_ID 0x01 +#define NEGATIVE_PRESSURE_PROPORTIONAL_ID 0x02 diff --git a/appsrc/appsetting/project_setting/component_id_mgr.cpp b/appsrc/appsetting/project_setting/component_id_mgr.cpp new file mode 100644 index 0000000..eaa8c43 --- /dev/null +++ b/appsrc/appsetting/project_setting/component_id_mgr.cpp @@ -0,0 +1,68 @@ +#include "component_id_mgr.hpp" +#if 0 +using namespace std; +using namespace iflytop; +using namespace core; + +#define HC HardwareComponent + +#define INSERT(id, boardId, subId) m_componentIdMap.insert({id, {boardId, subId}}) + +void ComponentIdMgr::initialize() { // + auto projSet = PROJECT_SETTING; + + if (projSet->isLageSpaceDM() || projSet->isSmallSpaceDM() || projSet->isPipeDM()) { + // 加液泵 + INSERT(HardwareComponent::kAddLiquidPump, kFixBoardId_LiquidCtrl, kpumpid_add_liquid); + // 喷雾泵 + INSERT(HardwareComponent::kSprayPump, kFixBoardId_LiquidCtrl, kpumpid_spray); + // 风机 + INSERT(HardwareComponent::kBlower, kFixBoardId_PowerControl, 0); + // 空压机 + INSERT(HardwareComponent::kAirCompressor, kFixBoardId_PowerControl, 0); + // 加热器 + INSERT(HardwareComponent::kHeater, kFixBoardId_PowerControl, 0); + // 报警灯 + INSERT(HardwareComponent::kWarningLight, kFixBoardId_LiquidCtrl, 0); + // 蒸发仓水浸 + INSERT(HardwareComponent::kEvaporationBinWS, kFixBoardId_LiquidCtrl, 0); + // 底部水浸 + INSERT(HardwareComponent::kDeviceBottomWS, kFixBoardId_LiquidCtrl, 0); + // 主H2O2传感器 + INSERT(HardwareComponent::kMainH2O2Sensor, kFixBoardId_PowerControl, 0); + // 液体重量传感器 + INSERT(HardwareComponent::kLiquidWeightPS, kFixBoardId_LiquidCtrl, 1); + // 空压机后压力传感器 + INSERT(HardwareComponent::kACPostPS, kFixBoardId_LiquidCtrl, 0); + // 喷雾泵后压力传感器 + INSERT(HardwareComponent::kSprayPumpPostPS, kFixBoardId_LiquidCtrl, 0); + // 加液泵后压力传感器 + INSERT(HardwareComponent::kAddLiquidPumpPostPS, kFixBoardId_LiquidCtrl, 0); + + if (projSet->isPipeDM()) { + // 正压比例阀 + INSERT(HardwareComponent::kPositivePressureProportional, kFixBoardId_LiquidCtrl, POSITIVE_PRESSURE_PROPORTIONAL_ID); + // 负压比例阀 + INSERT(HardwareComponent::kNegativePressureProportional, kFixBoardId_LiquidCtrl, NEGATIVE_PRESSURE_PROPORTIONAL_ID); + // 气密传感器 + INSERT(HardwareComponent::kAirLeakDetectPS, kFixBoardId_LiquidCtrl, 0); + // 空气密度测试空压机 + INSERT(HardwareComponent::kAirLeakDetectTestAC, kFixBoardId_LiquidCtrl, 0); + // 空气密度测试通道控制 + INSERT(HardwareComponent::kAirLeakDetectTestChannelCtrl, kFixBoardId_LiquidCtrl, 0); + } + } + if (projSet->isDrawBarDM()) { + } + // 外部通道选择器 + // INSERT(HardwareComponent::kExtChSelector, kFixBoardId_ExtChSelector, 0); +} + +ComponentId ComponentIdMgr::getId(HardwareComponent component) { + auto it = m_componentIdMap.find(component); + if (it != m_componentIdMap.end()) { + return it->second; + } + THROW_APP_EXCEPTION(err::kappe_code_error, "ComponentIdMgr::getId: component not found"); +} +#endif \ No newline at end of file diff --git a/appsrc/appsetting/project_setting/component_id_mgr.hpp b/appsrc/appsetting/project_setting/component_id_mgr.hpp new file mode 100644 index 0000000..e69de29 diff --git a/appsrc/appsetting/project_setting/project_setting.hpp b/appsrc/appsetting/project_setting/project_setting.hpp new file mode 100644 index 0000000..33e5d84 --- /dev/null +++ b/appsrc/appsetting/project_setting/project_setting.hpp @@ -0,0 +1,58 @@ +#pragma once +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "appbase/appbasedep.hpp" +#include "appbase/appbean/hardware_component.hpp" +// +#include "basic/componentid.hpp" +#include "basic/gconfig.hpp" +#include "basic/project_constant.hpp" +namespace iflytop { +using namespace std; +using namespace transmit_disfection_protocol; + +class ProjectSetting { + THISCLASS(ProjectSetting); + + public: + map m_componentIdMap; + + string projectType = PROJECT_LARGE_SPACE_DM; + int projectTypeInt = klarge_space_disinfection_machine; + + // + // some properties + // + int extSensorNum = 0; + double gpmToSpeedRadio = 0; + + public: + bool isLageSpaceDM() { return projectTypeInt == klarge_space_disinfection_machine; } + bool isSmallSpaceDM() { return projectTypeInt == ksmall_space_disinfection_machine; } + bool isPipeDM() { return projectTypeInt == kpipe_disinfection_machine; } + bool isDrawBarDM() { return projectTypeInt == kdraw_bar_disinfection_box; } + + bool isProjectType(int id) { return id == projectTypeInt; } + bool isProjectType(int id0, int id1) { return id0 == projectTypeInt || id1 == projectTypeInt; } + bool isProjectType(int id0, int id1, int id2) { return id0 == projectTypeInt || id1 == projectTypeInt || id2 == projectTypeInt; } + bool isProjectType(int id0, int id1, int id2, int id3) { return id0 == projectTypeInt || id1 == projectTypeInt || id2 == projectTypeInt || id3 == projectTypeInt; } + + ComponentId getId(HardwareComponent component) { + auto it = m_componentIdMap.find(component); + if (it != m_componentIdMap.end()) { + return it->second; + } + THROW_APP_EXCEPTION(err::kappe_code_error, "ComponentIdMgr::getId: component not found"); + } +}; + +} // namespace iflytop \ No newline at end of file diff --git a/appsrc/appsetting/project_setting/project_setting_mgr.cpp b/appsrc/appsetting/project_setting/project_setting_mgr.cpp new file mode 100644 index 0000000..a06d869 --- /dev/null +++ b/appsrc/appsetting/project_setting/project_setting_mgr.cpp @@ -0,0 +1,63 @@ +#include "project_setting_mgr.hpp" + +#include "components/zservice_container/zservice_container.hpp" +using namespace std; +using namespace iflytop; + +static string projectType2Str(int val) { + switch (val) { + case klarge_space_disinfection_machine: + return PROJECT_LARGE_SPACE_DM; + case ksmall_space_disinfection_machine: + return PROJECT_SMALL_SPACE_DM; + case kpipe_disinfection_machine: + return PROJECT_PIPE_DM; + case kdraw_bar_disinfection_box: + return PROJECT_DRAW_BAR_DM; + default: + return "not-support"; + } +} + +void ProjectSettingMgr::initialize() { + GET_TO_SERVICE(gConfig); + + projectSettingsMap[PROJECT_LARGE_SPACE_DM] = createProjectSetting(klarge_space_disinfection_machine); + projectSettingsMap[PROJECT_SMALL_SPACE_DM] = createProjectSetting(ksmall_space_disinfection_machine); + projectSettingsMap[PROJECT_PIPE_DM] = createProjectSetting(kpipe_disinfection_machine); + projectSettingsMap[PROJECT_DRAW_BAR_DM] = createProjectSetting(kdraw_bar_disinfection_box); +} + +shared_ptr ProjectSettingMgr::createProjectSetting(int projectTypeInt) { + shared_ptr projectSetting = make_shared(); + projectSetting->projectTypeInt = projectTypeInt; + projectSetting->projectType = projectType2Str(projectTypeInt); + + if (projectTypeInt == klarge_space_disinfection_machine) { + projectSetting->extSensorNum = LARGE_SPACE_DM_EXT_SENSOR_NUM; + projectSetting->gpmToSpeedRadio = LARGE_SPACE_DM_GPM_TO_SPEED_RADIO; + } else if (projectTypeInt == ksmall_space_disinfection_machine) { + projectSetting->extSensorNum = SMALL_SPACE_DM_EXT_SENSOR_NUM; + projectSetting->gpmToSpeedRadio = SMALL_SPACE_DM_GPM_TO_SPEED_RADIO; + } else if (projectTypeInt == kpipe_disinfection_machine) { + projectSetting->extSensorNum = PIPE_DM_EXT_SENSOR_NUM; + projectSetting->gpmToSpeedRadio = PIPE_DM_GPM_TO_SPEED_RADIO; + } else if (projectTypeInt == kdraw_bar_disinfection_box) { + projectSetting->extSensorNum = DRAW_BAR_DM_EXT_SENSOR_NUM; + projectSetting->gpmToSpeedRadio = DRAW_BAR_DM_GPM_TO_SPEED_RADIO; + } else { + ZCHECK(false, "projectTypeInt not support: " + to_string(projectTypeInt)); + } + + return projectSetting; +} +shared_ptr ProjectSettingMgr::getProjectSetting() { return getProjectSetting(gConfig->get_projectType()); } + +shared_ptr ProjectSettingMgr::getProjectSetting(string projectType) { + auto val = projectSettingsMap[projectType]; + ZCHECK(val != nullptr, "projectType not found: " + projectType); + return val; +} +shared_ptr ProjectSettingMgr::getProjectSetting(int projectTypeInt) { return getProjectSetting(projectType2Str(projectTypeInt)); } + +int32_t ProjectSettingMgr::getProjType() { return getProjectSetting()->projectTypeInt; } diff --git a/appsrc/appsetting/project_setting/project_setting_mgr.hpp b/appsrc/appsetting/project_setting/project_setting_mgr.hpp new file mode 100644 index 0000000..56d1295 --- /dev/null +++ b/appsrc/appsetting/project_setting/project_setting_mgr.hpp @@ -0,0 +1,47 @@ +#pragma once +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "project_setting.hpp" + +// +#include "app_protocols/transmit_disfection_protocol/transmit_disfection_protocol.hpp" +// +namespace iflytop { +using namespace std; +using namespace transmit_disfection_protocol; + +class ProjectSettingMgr { + THISCLASS(ProjectSettingMgr); + + private: + /* data */ + + map> projectSettingsMap; + shared_ptr gConfig; + + public: + void initialize(); + + public: + shared_ptr getProjectSetting(); + int32_t getProjType(); + + private: + shared_ptr getProjectSetting(string projectType); + shared_ptr getProjectSetting(int projectTypeInt); + shared_ptr createProjectSetting(int projectTypeInt); +}; + +} // namespace iflytop + +#define PROJECT_TYPE (GET_SERVICE(ProjectSettingMgr)->getProjType()) +#define PROJECT_SETTING (GET_SERVICE(ProjectSettingMgr)->getProjectSetting()) \ No newline at end of file diff --git a/appsrc/baseservice/db/setting_db_dao.hpp b/appsrc/baseservice/db/setting_db_dao.hpp index da45e04..6c8d848 100644 --- a/appsrc/baseservice/db/setting_db_dao.hpp +++ b/appsrc/baseservice/db/setting_db_dao.hpp @@ -15,8 +15,10 @@ #include #include -#include "appbase/appbean/setting_id.hpp" #include "appbase/dep.hpp" +#include "appsetting/appsetting.hpp" +// + #include "base/dbbase.hpp" #include "base/keyvaldb.hpp" #include "user_behavior_des.hpp" diff --git a/appsrc/baseservice/iflytop_front_end_service/iflytop_front_end_service.hpp b/appsrc/baseservice/iflytop_front_end_service/iflytop_front_end_service.hpp index 562c6c3..b887137 100644 --- a/appsrc/baseservice/iflytop_front_end_service/iflytop_front_end_service.hpp +++ b/appsrc/baseservice/iflytop_front_end_service/iflytop_front_end_service.hpp @@ -16,6 +16,8 @@ #include #include "appbase/dep.hpp" +#include "appsetting/appsetting.hpp" + /** * @brief * diff --git a/appsrc/baseservice/udisk_mgr_service.hpp b/appsrc/baseservice/udisk_mgr_service.hpp index ddef734..e75071d 100644 --- a/appsrc/baseservice/udisk_mgr_service.hpp +++ b/appsrc/baseservice/udisk_mgr_service.hpp @@ -15,7 +15,7 @@ #include #include "appbase/dep.hpp" - +#include "appsetting/appsetting.hpp" namespace iflytop { class UDiskMgrService { diff --git a/appsrc/main.cpp b/appsrc/main.cpp index 1ea93b3..9578835 100644 --- a/appsrc/main.cpp +++ b/appsrc/main.cpp @@ -3,6 +3,7 @@ #include #include "appbase/dep.hpp" +#include "appsetting/appsetting.hpp" #include "service/main_control_service.hpp" using namespace iflytop; diff --git a/appsrc/service/app/air_tightness_test.cpp b/appsrc/service/app/air_tightness_test.cpp index 431fdd1..5792109 100644 --- a/appsrc/service/app/air_tightness_test.cpp +++ b/appsrc/service/app/air_tightness_test.cpp @@ -1,27 +1,27 @@ #include "air_tightness_test.hpp" using namespace iflytop; -void LeakDetectTest::initialize() { - logger->info("LeakDetectTest initialize"); - REGFNV2(LeakDetectTest, start); - REGFNV2(LeakDetectTest, stop); - REGFNV2(LeakDetectTest, getState); - REGFNV2(LeakDetectTest, getServiceConfig); +void AirLeakDetectTest::initialize() { + logger->info("AirLeakDetectTest initialize"); + REGFNV2(AirLeakDetectTest, start); + REGFNV2(AirLeakDetectTest, stop); + REGFNV2(AirLeakDetectTest, getState); + REGFNV2(AirLeakDetectTest, getServiceConfig); } -void LeakDetectTest::start() { m_workstate = kleakTesting; } -void LeakDetectTest::stop() { m_workstate = kidle; } -LeakDetectTest::state_t LeakDetectTest::getWorkstate() { return m_workstate; } +void AirLeakDetectTest::start() { m_workstate = kleakTesting; } +void AirLeakDetectTest::stop() { m_workstate = kidle; } +AirLeakDetectTest::state_t AirLeakDetectTest::getWorkstate() { return m_workstate; } -void LeakDetectTest::fn_start(shared_ptr cxt) { // +void AirLeakDetectTest::fn_start(shared_ptr cxt) { // start(); } -void LeakDetectTest::fn_stop(shared_ptr cxt) { stop(); } -void LeakDetectTest::fn_getState(shared_ptr cxt) { // +void AirLeakDetectTest::fn_stop(shared_ptr cxt) { stop(); } +void AirLeakDetectTest::fn_getState(shared_ptr cxt) { // cxt->content["workState"] = state2str(getWorkstate()); cxt->content["workStateDisplay"] = state2chstr(getWorkstate()); cxt->content["pressure"] = 3.1; } -void LeakDetectTest::fn_getServiceConfig(shared_ptr cxt) { +void AirLeakDetectTest::fn_getServiceConfig(shared_ptr cxt) { json cfg; cfg["pressureUint"] = "kPa"; cfg["pressureMax"] = 5.0; diff --git a/appsrc/service/app/air_tightness_test.hpp b/appsrc/service/app/air_tightness_test.hpp index c241c32..6983c02 100644 --- a/appsrc/service/app/air_tightness_test.hpp +++ b/appsrc/service/app/air_tightness_test.hpp @@ -11,7 +11,7 @@ // #include "baseservice/baseservice.hpp" namespace iflytop { -class LeakDetectTest : public enable_shared_from_this { +class AirLeakDetectTest : public enable_shared_from_this { THISCLASS(AddLiquidService); public: diff --git a/appsrc/service/disinfection_logs_service.hpp b/appsrc/service/disinfection_logs_service.hpp index d03ad4a..e533352 100644 --- a/appsrc/service/disinfection_logs_service.hpp +++ b/appsrc/service/disinfection_logs_service.hpp @@ -10,6 +10,8 @@ #include // #include "appbase/dep.hpp" +#include "appsetting/appsetting.hpp" + #include "baseservice/baseservice.hpp" #include "iflytop/core/components/zcsv/zcsv.hpp" diff --git a/appsrc/service/hardware/base/component_id_mgr.cpp b/appsrc/service/hardware/base/component_id_mgr.cpp deleted file mode 100644 index e2d710d..0000000 --- a/appsrc/service/hardware/base/component_id_mgr.cpp +++ /dev/null @@ -1,55 +0,0 @@ -#include "component_id_mgr.hpp" - -using namespace std; -using namespace iflytop; -using namespace core; - -#define HC HardwareComponent - -#define INSERT(id, boardId, subId) m_componentIdMap.insert({id, {boardId, subId}}) - -void ComponentIdMgr::initialize() { // - auto projSet = PROJECT_SETTING; - // 加液泵 - INSERT(HardwareComponent::kAddLiquidPump, kFixBoardId_LiquidCtrl, kpumpid_add_liquid); - // 喷雾泵 - INSERT(HardwareComponent::kSprayPump, kFixBoardId_LiquidCtrl, kpumpid_spray); - // 风机 - INSERT(HardwareComponent::kBlower, kFixBoardId_PowerControl, 0); - // 空压机 - INSERT(HardwareComponent::kAirCompressor, kFixBoardId_PowerControl, 0); - // 加热器 - INSERT(HardwareComponent::kHeater, kFixBoardId_PowerControl, 0); - // 报警灯 - INSERT(HardwareComponent::kWarningLight, kFixBoardId_LiquidCtrl, 0); - // 正压比例阀 - INSERT(HardwareComponent::kPositivePressureProportional, kFixBoardId_LiquidCtrl, POSITIVE_PRESSURE_PROPORTIONAL_ID); - // 负压比例阀 - INSERT(HardwareComponent::kNegativePressureProportional, kFixBoardId_LiquidCtrl, NEGATIVE_PRESSURE_PROPORTIONAL_ID); - // 空气密度测试 - INSERT(HardwareComponent::kLeakDetectTest, kFixBoardId_LiquidCtrl, 0); - // 外部通道选择器 - INSERT(HardwareComponent::kExtChSelector, kFixBoardId_ExtChSelector, 0); - // 蒸发仓水浸 - INSERT(HardwareComponent::kEvaporationBinWS, kFixBoardId_LiquidCtrl, 0); - // 底部水浸 - INSERT(HardwareComponent::kDeviceBottomWS, kFixBoardId_LiquidCtrl, 0); - // 主H2O2传感器 - INSERT(HardwareComponent::kMainH2O2Sensor, kFixBoardId_PowerControl, 0); - // 气密传感器 - INSERT(HardwareComponent::kLeakDetectPS, kFixBoardId_LiquidCtrl, 0); - // 液体重量传感器 - INSERT(HardwareComponent::kLiquidWeightPS, kFixBoardId_LiquidCtrl, 0); - // 喷雾泵后压力传感器 - INSERT(HardwareComponent::kSprayPumpPostPS, kFixBoardId_LiquidCtrl, 0); - // 加液泵后压力传感器 - INSERT(HardwareComponent::kAddLiquidPumpPostPS, kFixBoardId_LiquidCtrl, 0); -} - -ComponentId ComponentIdMgr::getId(HardwareComponent component) { - auto it = m_componentIdMap.find(component); - if (it != m_componentIdMap.end()) { - return it->second; - } - THROW_APP_EXCEPTION(err::kappe_code_error,"ComponentIdMgr::getId: component not found"); -} \ No newline at end of file diff --git a/appsrc/service/hardware/base/component_id_mgr.hpp b/appsrc/service/hardware/base/component_id_mgr.hpp deleted file mode 100644 index 7c4585a..0000000 --- a/appsrc/service/hardware/base/component_id_mgr.hpp +++ /dev/null @@ -1,41 +0,0 @@ -#pragma once -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -// -#include "appbase/appbean/hardware_component.hpp" -#include "baseservice/baseservice.hpp" - -namespace iflytop { -using namespace std; -using namespace core; - -class ComponentId { - public: - ComponentId(int boardId, int subId) : boardId(boardId), subId(subId) {} - int boardId; - int subId; -}; - -class ComponentIdMgr : public enable_shared_from_this { - THISCLASS(ComponentIdMgr); - - shared_ptr m_projectSetting; - map m_componentIdMap; - - public: - void initialize(); - ComponentId getId(HardwareComponent component); - - private: -}; - -} // namespace iflytop \ No newline at end of file diff --git a/appsrc/service/hardware/device_ctrl_service.cpp b/appsrc/service/hardware/device_ctrl_service.cpp index d54c232..d6d5704 100644 --- a/appsrc/service/hardware/device_ctrl_service.cpp +++ b/appsrc/service/hardware/device_ctrl_service.cpp @@ -1,5 +1,5 @@ #include "device_ctrl_service.hpp" - +#if 0 using namespace iflytop; using namespace std; using namespace core; @@ -131,9 +131,9 @@ int DeviceIoControlService::NegaPressureProp_readPos() { return CAN_MASTER->pro bool DeviceIoControlService::NegaPressureProp_isBusy() { return CAN_MASTER->proportionalIsBusy(GET_BOARDID(), GET_SUBID()); } #undef COMPONENT -#define COMPONENT HardwareComponent::LeakDetectTest -void DeviceIoControlService::LeakDetectTest_cutoffCh() { CAN_MASTER->leakDetectTestCloseOffCh(GET_BOARDID()); } -void DeviceIoControlService::LeakDetectTest_releaseCh() { CAN_MASTER->leakDetectTestReleaseCh(GET_BOARDID()); } +#define COMPONENT HardwareComponent::AirLeakDetectTest +void DeviceIoControlService::AirLeakDetectTest_cutoffCh() { CAN_MASTER->airLeakDetectTestCloseOffCh(GET_BOARDID()); } +void DeviceIoControlService::AirLeakDetectTest_releaseCh() { CAN_MASTER->airLeakDetectTestReleaseCh(GET_BOARDID()); } #undef COMPONENT // ExtChSelector @@ -159,5 +159,6 @@ bool DeviceIoControlService::WaterSensor_readDeviceBottom() { return CAN_MASTER- int DeviceIoControlService::PressureSensor_readValPa(int sensorId) { return 0; } // Pa // 气体密性测试压力传感器 -#define COMPONENT HardwareComponent::LeakDetectPressureSensor -int DeviceIoControlService::LeakDetectPressureSensor_readValPa() { return 0; } // Pa \ No newline at end of file +#define COMPONENT HardwareComponent::AirLeakDetectPressureSensor +int DeviceIoControlService::AirLeakDetectPressureSensor_readValPa() { return 0; } // Pa +#endif \ No newline at end of file diff --git a/appsrc/service/hardware/device_ctrl_service.hpp b/appsrc/service/hardware/device_ctrl_service.hpp index cb423d9..9b309f2 100644 --- a/appsrc/service/hardware/device_ctrl_service.hpp +++ b/appsrc/service/hardware/device_ctrl_service.hpp @@ -12,7 +12,6 @@ #include "baseservice/baseservice.hpp" // #include "base/can_packet_dumper.hpp" -#include "base/component_id_mgr.hpp" #include "base/h2o2_sensor_data_mgr.hpp" #include "base/uint_convert_mgr.hpp" /** @@ -40,7 +39,6 @@ class DeviceIoControlService : public enable_shared_from_this m_h2o2SensorDataMgr = make_shared(); shared_ptr m_uintConvertMgr = make_shared(); - shared_ptr m_boardIdMgr = make_shared(); public: void initialize(); @@ -96,10 +94,10 @@ class DeviceIoControlService : public enable_shared_from_this #include "appbase/dep.hpp" +#include "appsetting/appsetting.hpp" /** * @brief