diff --git a/LFtid1056/client2.h b/LFtid1056/client2.h index 3672eb3..688ad4f 100644 --- a/LFtid1056/client2.h +++ b/LFtid1056/client2.h @@ -62,6 +62,8 @@ enum class DeviceState { READING_DEVVERSION, // 读取装置版本配置信息 SET_RIGHTTIME, // 设置装置对时 READING_EVENTLOG, // 补招事件日志 + READING_EVENTFILE, // 补招暂态波形文件 + READING_STATSFILE, // 补招稳态数据文件 // 可根据需要添加更多状态 CUSTOM_ACTION // 自定义动作 }; diff --git a/LFtid1056/main_thread.cpp b/LFtid1056/main_thread.cpp index e873484..930f0c8 100644 --- a/LFtid1056/main_thread.cpp +++ b/LFtid1056/main_thread.cpp @@ -154,24 +154,24 @@ void* client_manager_thread(void* arg) { printf("Started client connections\n"); // 创建测点数据 - //std::vector points1 = { - // {"P001", "Main Voltage", "D001",1 ,1, 1, 1, 1,"0.38k",0}, - // {"P002", "Backup Voltage", "D001",2 ,1, 1, 1, 1,"0.38k",0} - //}; - ////00B78DA800D6 00-B7-8D-01-79-06 00-B7-8D-A8-00-D6 00-B7-8D-01-71-09 00-B7-8D-01-88-7f - //// 创建装置列表 - //std::vector devices = { - // { - // "D001", "Primary Device", "Model-X", "00-B7-8D-01-79-06", - // 1, points1,true - // } - //}; + std::vector points1 = { + {"P001", "Main Voltage", "D001",1 ,1, 1, 1, 1,"0.38k",0}, + {"P002", "Backup Voltage", "D001",2 ,1, 1, 1, 1,"0.38k",0} + }; + //00B78DA800D6 00-B7-8D-01-79-06 00-B7-8D-A8-00-D6 00-B7-8D-01-71-09 00-B7-8D-01-88-7f + // 创建装置列表 + std::vector devices = { + { + "D001", "Primary Device", "Model-X", "00-B7-8D-01-79-06", + 1, points1,true + } + }; // 生成100个测试装置 //std::vector test_devices = generate_test_devices(100); //lnk从台账读取设备 - std::vector devices = GenerateDeviceInfoFromLedger(terminal_devlist);//lnk添加 + //std::vector devices = GenerateDeviceInfoFromLedger(terminal_devlist);//lnk添加 //台账打印 PrintDevices(devices); @@ -302,7 +302,7 @@ int main(int argc ,char** argv) {// std::cerr << "process param error,exit" << std::endl; return 1; } - init_daemon(); + //init_daemon(); srand(time(NULL)); // 初始化随机数种子 // 初始化线程数组