From b0108a4602e89aeddff619f308324b3e5a9e5ce6 Mon Sep 17 00:00:00 2001 From: yiyi Date: Tue, 27 Jan 2026 23:35:48 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8B=86=E5=8C=85=E6=9B=B4=E6=96=B0=E4=BC=AF?= =?UTF-8?q?=E6=9C=97=E7=89=B9=E7=9A=84=E5=8D=8F=E8=AE=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App/GrabBag/Doc/伯朗特TCP协议对接.md | 55 ++++- .../Presenter/Inc/BolunteProtocol.h | 14 +- .../Presenter/Src/BolunteProtocol.cpp | 40 +++- .../Presenter/Src/GrabBagPresenter.cpp | 6 +- App/GrabBag/GrabBagApp/Version.h | 2 +- App/GrabBag/GrabBagApp/Version.md | 4 + App/GrabBag/GrabBagApp/dialogcamera.cpp | 10 +- App/GrabBag/GrabBagApp/dialogcamera.ui | 221 +++++++++++++++--- App/GrabBag/GrabBagConfig/Inc/IVrConfig.h | 5 +- App/GrabBag/GrabBagConfig/Src/VrConfig.cpp | 42 +++- App/GrabBag/GrabBagConfig/config/config.xml | 5 +- 11 files changed, 337 insertions(+), 67 deletions(-) diff --git a/App/GrabBag/Doc/伯朗特TCP协议对接.md b/App/GrabBag/Doc/伯朗特TCP协议对接.md index 87322e7..94ebe08 100644 --- a/App/GrabBag/Doc/伯朗特TCP协议对接.md +++ b/App/GrabBag/Doc/伯朗特TCP协议对接.md @@ -4,6 +4,7 @@ | 版本 | 日期 | 修改内容 | |------|------|----------| +| v1.3 | 2026-01-27 | 1.附加命令改为根据检测结果动态生成
2.PostCoordinateCommand配置项拆分为DsID、Address、SuccessValue、FailValue
3.检测成功发送SuccessValue(默认10),失败发送FailValue(默认12) | | v1.2 | 2026-01-24 | 1.架构改为视觉系统作为TCP服务端,机械臂作为客户端
2.移除Enabled配置,服务端始终启动
3.移除IpAddress配置,只需配置监听端口
4.camID回复与请求匹配 | | v1.1 | 2026-01-24 | 1.收到拍照命令不再回复结果
2.移除packID字段
3.旋转角度填到U,Angel改为Angle
4.发送坐标后100ms发送附加命令
5.只发送第一个检测结果,并自动生成第二个坐标(Z+偏移量)
6.端口默认改为5000 | | v1.0 | 2026-01-20 | 完善协议说明、添加字段详解、错误处理和使用示例 | @@ -144,22 +145,56 @@ **方向**:视觉系统 → 机械臂 -**说明**:发送坐标数据后100ms自动发送附加命令,内容可配置。 +**说明**:发送坐标数据后100ms自动发送附加命令,**根据检测结果动态生成**: +- **检测成功**(有目标):发送 SuccessValue(默认10) +- **检测失败**(无目标):发送 FailValue(默认12) -**默认JSON格式**: +**JSON格式**: ```json { "dsID":"www.hc-system.com.RemoteMonitor", "reqType":"command", "cmdData":["rewriteData","800","10","0"] } ``` -**配置方法**:在配置文件中设置 `PostCoordinateCommand` 字段,传入空字符串则不发送。 +**字段说明**: + +| 字段 | 类型 | 说明 | +|------|------|------| +| dsID | String | 附加命令的数据源标识,可配置(PostCoordinateDsID) | +| reqType | String | 固定为 "command" | +| cmdData | Array | 命令数据数组 | + +**cmdData 数组说明**: + +| 索引 | 值 | 说明 | +|------|------|------| +| 0 | "rewriteData" | 固定命令类型 | +| 1 | "800" | 地址,可配置(PostCoordinateAddress,默认800) | +| 2 | "10" 或 "12" | 检测结果值:成功=SuccessValue(默认10),失败=FailValue(默认12) | +| 3 | "0" | 固定值 | + +**配置方法**:在配置文件中设置以下字段: +- `PostCoordinateDsID`:附加命令的dsID,为空则不发送附加命令 +- `PostCoordinateAddress`:地址(默认800) +- `PostCoordinateSuccessValue`:检测成功时的值(默认10) +- `PostCoordinateFailValue`:检测失败时的值(默认12) ## 5. 配置说明 视觉系统启动时自动启动TCP服务端,默认监听端口5000。机械臂作为客户端连接到视觉系统即可。 主要配置项: -- **监听端口**:默认5000,可在配置文件中修改 -- **数据源标识(dsID)**:默认 "www.hc-system.com.cam",需与机械臂配置一致 + +| 配置项 | 默认值 | 说明 | +|------|------|------| +| Port | 5000 | TCP服务端监听端口 | +| DsID | www.hc-system.com.cam | 数据源标识,需与机械臂配置一致 | +| ZOffset | 300.0 | 第二个坐标的Z轴偏移量 | +| ZMin | -1500.0 | Z轴最小值限制 | +| ZMax | 2500.0 | Z轴最大值限制 | +| AngleOffset | 0.0 | 旋转角度补偿 | +| PostCoordinateDsID | www.hc-system.com.RemoteMonitor | 附加命令的dsID,为空则不发送 | +| PostCoordinateAddress | 800 | 附加命令的地址 | +| PostCoordinateSuccessValue | 10 | 检测成功时发送的值 | +| PostCoordinateFailValue | 12 | 检测失败时发送的值 | ## 6. 数据格式约束 @@ -215,7 +250,7 @@ ] } -// 100ms后发送附加命令 +// 100ms后发送附加命令(检测成功,发送SuccessValue=10) { "dsID":"www.hc-system.com.RemoteMonitor", "reqType":"command", "cmdData":["rewriteData","800","10","0"] } ``` @@ -233,6 +268,9 @@ } ] } + +// 100ms后发送附加命令(检测失败,发送FailValue=12) +{ "dsID":"www.hc-system.com.RemoteMonitor", "reqType":"command", "cmdData":["rewriteData","800","12","0"] } ``` ## 8. 注意事项 @@ -245,7 +283,10 @@ - 视觉系统发送坐标使用 "AddPoints"(注意大小写) 5. **坐标系统**:所有坐标已通过手眼标定转换到机械臂坐标系,可直接使用 6. **旋转角度**:旋转角度填入U字段,Angle字段固定为0 -7. **附加命令**:发送坐标后100ms自动发送附加命令,可通过配置文件设置 +7. **附加命令**:发送坐标后100ms自动发送附加命令,根据检测结果动态生成 + - 检测成功(有目标):发送 PostCoordinateSuccessValue(默认10) + - 检测失败(无目标):发送 PostCoordinateFailValue(默认12) + - PostCoordinateDsID 为空则不发送附加命令 8. **双坐标输出**:只取第一个检测结果,自动生成第二个坐标 - ModelID=0:Z + ZOffset(偏移后的Z) - ModelID=1:原始Z diff --git a/App/GrabBag/GrabBagApp/Presenter/Inc/BolunteProtocol.h b/App/GrabBag/GrabBagApp/Presenter/Inc/BolunteProtocol.h index e1bc328..c1464d8 100644 --- a/App/GrabBag/GrabBagApp/Presenter/Inc/BolunteProtocol.h +++ b/App/GrabBag/GrabBagApp/Presenter/Inc/BolunteProtocol.h @@ -69,10 +69,13 @@ public: void SetDsID(const std::string& dsID); /** - * @brief 设置坐标发送后的附加命令 - * @param command 附加命令JSON字符串,为空则不发送 + * @brief 设置坐标发送后附加命令的参数 + * @param dsID 附加命令的dsID + * @param address 附加命令的地址 + * @param successValue 检测成功时的值 + * @param failValue 检测失败时的值 */ - void SetPostCoordinateCommand(const std::string& command); + void SetPostCoordinateParams(const std::string& dsID, int address, int successValue, int failValue); /** * @brief 设置第二个坐标的Z轴偏移量 @@ -132,7 +135,10 @@ private: bool m_bConnected; // 连接状态 uint16_t m_nPort; // TCP端口 std::string m_strDsID; // 数据源标识 - std::string m_strPostCoordCmd; // 坐标发送后的附加命令 + std::string m_strPostCoordDsID; // 坐标发送后附加命令的dsID + int m_nPostCoordAddress; // 坐标发送后附加命令的地址 + int m_nPostCoordSuccessValue; // 检测成功时的值 + int m_nPostCoordFailValue; // 检测失败时的值 double m_dZOffset; // 第二个坐标Z轴偏移量 double m_dZMin; // Z轴最小值 double m_dZMax; // Z轴最大值 diff --git a/App/GrabBag/GrabBagApp/Presenter/Src/BolunteProtocol.cpp b/App/GrabBag/GrabBagApp/Presenter/Src/BolunteProtocol.cpp index 9584bf2..0ee5abe 100644 --- a/App/GrabBag/GrabBagApp/Presenter/Src/BolunteProtocol.cpp +++ b/App/GrabBag/GrabBagApp/Presenter/Src/BolunteProtocol.cpp @@ -12,7 +12,10 @@ BolunteProtocol::BolunteProtocol() , m_bConnected(false) , m_nPort(5000) , m_strDsID("www.hc-system.com.cam") - , m_strPostCoordCmd(R"({ "dsID":"www.hc-system.com.RemoteMonitor", "reqType":"command", "cmdData":["rewriteData","800","10","0"] })") + , m_strPostCoordDsID("www.hc-system.com.RemoteMonitor") + , m_nPostCoordAddress(800) + , m_nPostCoordSuccessValue(10) + , m_nPostCoordFailValue(12) , m_dZOffset(300.0) , m_dZMin(-1500.0) , m_dZMax(2500.0) @@ -132,12 +135,32 @@ int BolunteProtocol::SendCoordinateData(const MultiTargetData& multiTargetData) { LOG_INFO("Sent coordinate data: count=%d\n", multiTargetData.count); - // 100ms后发送附加命令 - if (!m_strPostCoordCmd.empty()) + // 100ms后发送附加命令,根据检测结果拼接成功/失败值 + if (!m_strPostCoordDsID.empty()) { std::this_thread::sleep_for(std::chrono::milliseconds(100)); - m_pTcpServer->SendAllData(m_strPostCoordCmd.c_str(), m_strPostCoordCmd.length()); - LOG_INFO("Sent post coordinate command\n"); + + // 根据检测结果选择成功/失败值 + bool detectionSuccess = !multiTargetData.targets.empty(); + int resultValue = detectionSuccess ? m_nPostCoordSuccessValue : m_nPostCoordFailValue; + + // 动态生成附加命令JSON + VA::Json::Value postCmd; + postCmd["dsID"] = m_strPostCoordDsID; + postCmd["reqType"] = "command"; + + VA::Json::Value cmdData(VA::Json::arrayValue); + cmdData.append("rewriteData"); + cmdData.append(std::to_string(m_nPostCoordAddress)); + cmdData.append(std::to_string(resultValue)); + cmdData.append("0"); + postCmd["cmdData"] = cmdData; + + VA::Json::FastWriter writer; + std::string postCmdStr = writer.write(postCmd); + + m_pTcpServer->SendAllData(postCmdStr.c_str(), postCmdStr.length()); + LOG_INFO("Sent post coordinate command: success=%d, value=%d\n", detectionSuccess, resultValue); } return SUCCESS; @@ -169,9 +192,12 @@ void BolunteProtocol::SetDsID(const std::string& dsID) m_strDsID = dsID; } -void BolunteProtocol::SetPostCoordinateCommand(const std::string& command) +void BolunteProtocol::SetPostCoordinateParams(const std::string& dsID, int address, int successValue, int failValue) { - m_strPostCoordCmd = command; + m_strPostCoordDsID = dsID; + m_nPostCoordAddress = address; + m_nPostCoordSuccessValue = successValue; + m_nPostCoordFailValue = failValue; } void BolunteProtocol::SetZOffset(double zOffset) diff --git a/App/GrabBag/GrabBagApp/Presenter/Src/GrabBagPresenter.cpp b/App/GrabBag/GrabBagApp/Presenter/Src/GrabBagPresenter.cpp index 0158f7d..34d9d08 100644 --- a/App/GrabBag/GrabBagApp/Presenter/Src/GrabBagPresenter.cpp +++ b/App/GrabBag/GrabBagApp/Presenter/Src/GrabBagPresenter.cpp @@ -448,7 +448,11 @@ int GrabBagPresenter::InitBolunteProtocol() m_pBolunteProtocol->SetZOffset(configResult.bolunteConfig.zOffset); m_pBolunteProtocol->SetZRange(configResult.bolunteConfig.zMin, configResult.bolunteConfig.zMax); m_pBolunteProtocol->SetAngleOffset(configResult.bolunteConfig.angleOffset); - m_pBolunteProtocol->SetPostCoordinateCommand(configResult.bolunteConfig.postCoordinateCommand); + m_pBolunteProtocol->SetPostCoordinateParams( + configResult.bolunteConfig.postCoordinateDsID, + configResult.bolunteConfig.postCoordinateAddress, + configResult.bolunteConfig.postCoordinateSuccessValue, + configResult.bolunteConfig.postCoordinateFailValue); // 设置连接状态回调 m_pBolunteProtocol->SetConnectionCallback([this](bool connected) { diff --git a/App/GrabBag/GrabBagApp/Version.h b/App/GrabBag/GrabBagApp/Version.h index d75136a..da416bf 100644 --- a/App/GrabBag/GrabBagApp/Version.h +++ b/App/GrabBag/GrabBagApp/Version.h @@ -2,7 +2,7 @@ #define VERSION_H #define GRABBAG_VERSION_STRING "1.3.5" -#define GRABBAG_BUILD_STRING "4" +#define GRABBAG_BUILD_STRING "5" #define GRABBAG_FULL_VERSION_STRING "V" GRABBAG_VERSION_STRING "_" GRABBAG_BUILD_STRING // 获取版本信息的便捷函数 diff --git a/App/GrabBag/GrabBagApp/Version.md b/App/GrabBag/GrabBagApp/Version.md index f4ac521..b4a5714 100644 --- a/App/GrabBag/GrabBagApp/Version.md +++ b/App/GrabBag/GrabBagApp/Version.md @@ -1,4 +1,8 @@ # 1.3.5 +## build_5 20260126 +1. 修改协议附属命令结果 + + ## build_4 20260124 1. 修复算法检测线程在析构时未退出的问题 diff --git a/App/GrabBag/GrabBagApp/dialogcamera.cpp b/App/GrabBag/GrabBagApp/dialogcamera.cpp index 79381a2..0a9d8b0 100644 --- a/App/GrabBag/GrabBagApp/dialogcamera.cpp +++ b/App/GrabBag/GrabBagApp/dialogcamera.cpp @@ -389,7 +389,10 @@ void DialogCamera::LoadBolunteConfig() ui->doubleSpinBox_bolunte_zmin->setValue(configResult->bolunteConfig.zMin); ui->doubleSpinBox_bolunte_zmax->setValue(configResult->bolunteConfig.zMax); ui->doubleSpinBox_bolunte_angleoffset->setValue(configResult->bolunteConfig.angleOffset); - ui->lineEdit_bolunte_postcmd->setText(QString::fromStdString(configResult->bolunteConfig.postCoordinateCommand)); + ui->lineEdit_bolunte_postcmd->setText(QString::fromStdString(configResult->bolunteConfig.postCoordinateDsID)); + ui->spinBox_bolunte_postaddr->setValue(configResult->bolunteConfig.postCoordinateAddress); + ui->spinBox_bolunte_postsuccess->setValue(configResult->bolunteConfig.postCoordinateSuccessValue); + ui->spinBox_bolunte_postfail->setValue(configResult->bolunteConfig.postCoordinateFailValue); LOG_INFO("Loaded Bolunte config: port=%d, zOffset=%.1f\n", configResult->bolunteConfig.port, @@ -418,7 +421,10 @@ bool DialogCamera::SaveBolunteConfig() configResult->bolunteConfig.zMin = ui->doubleSpinBox_bolunte_zmin->value(); configResult->bolunteConfig.zMax = ui->doubleSpinBox_bolunte_zmax->value(); configResult->bolunteConfig.angleOffset = ui->doubleSpinBox_bolunte_angleoffset->value(); - configResult->bolunteConfig.postCoordinateCommand = ui->lineEdit_bolunte_postcmd->text().toStdString(); + configResult->bolunteConfig.postCoordinateDsID = ui->lineEdit_bolunte_postcmd->text().toStdString(); + configResult->bolunteConfig.postCoordinateAddress = ui->spinBox_bolunte_postaddr->value(); + configResult->bolunteConfig.postCoordinateSuccessValue = ui->spinBox_bolunte_postsuccess->value(); + configResult->bolunteConfig.postCoordinateFailValue = ui->spinBox_bolunte_postfail->value(); LOG_INFO("Saving Bolunte config: port=%d, zOffset=%.1f\n", configResult->bolunteConfig.port, diff --git a/App/GrabBag/GrabBagApp/dialogcamera.ui b/App/GrabBag/GrabBagApp/dialogcamera.ui index b587329..278f2ca 100644 --- a/App/GrabBag/GrabBagApp/dialogcamera.ui +++ b/App/GrabBag/GrabBagApp/dialogcamera.ui @@ -7,7 +7,7 @@ 0 0 660 - 620 + 650 @@ -226,7 +226,7 @@ QPushButton:disabled { 50 330 560 - 200 + 261 @@ -266,7 +266,7 @@ QPushButton:disabled { 110 35 - 120 + 100 30 @@ -293,8 +293,8 @@ background-color: rgb(47, 48, 52); 20 - 75 - 120 + 70 + 100 30 @@ -307,15 +307,15 @@ background-color: rgb(47, 48, 52); color: rgb(221, 225, 233); - 数据源标识: + 数据标识: - 140 - 75 - 380 + 110 + 70 + 411 30 @@ -336,8 +336,8 @@ background-color: rgb(47, 48, 52); 20 - 115 - 100 + 105 + 80 30 @@ -356,9 +356,9 @@ background-color: rgb(47, 48, 52); - 120 - 115 - 100 + 110 + 105 + 91 30 @@ -384,8 +384,8 @@ background-color: rgb(47, 48, 52); - 240 - 115 + 200 + 105 60 30 @@ -405,9 +405,9 @@ background-color: rgb(47, 48, 52); - 300 - 115 - 100 + 260 + 105 + 101 30 @@ -433,8 +433,8 @@ background-color: rgb(47, 48, 52); - 420 - 115 + 360 + 105 60 30 @@ -454,8 +454,8 @@ background-color: rgb(47, 48, 52); - 480 - 115 + 420 + 105 100 30 @@ -483,8 +483,8 @@ background-color: rgb(47, 48, 52); 20 - 155 - 100 + 140 + 80 30 @@ -503,9 +503,9 @@ background-color: rgb(47, 48, 52); - 120 - 155 - 100 + 110 + 140 + 80 30 @@ -531,9 +531,9 @@ background-color: rgb(47, 48, 52); - 240 - 155 - 100 + 20 + 180 + 80 30 @@ -546,15 +546,15 @@ background-color: rgb(47, 48, 52); color: rgb(221, 225, 233); - 附加命令: + 附加标识: - 340 - 155 - 180 + 110 + 180 + 411 30 @@ -571,12 +571,159 @@ background-color: rgb(47, 48, 52); 为空则不发送 + + + + 20 + 220 + 81 + 30 + + + + + 14 + + + + color: rgb(221, 225, 233); + + + 附加地址: + + + + + + 110 + 220 + 80 + 30 + + + + + 14 + + + + color: rgb(221, 225, 233); +background-color: rgb(47, 48, 52); + + + 0 + + + 65535 + + + 800 + + + + + + 210 + 220 + 60 + 30 + + + + + 14 + + + + color: rgb(221, 225, 233); + + + 成功值: + + + + + + 270 + 220 + 70 + 30 + + + + + 14 + + + + color: rgb(221, 225, 233); +background-color: rgb(47, 48, 52); + + + 0 + + + 65535 + + + 10 + + + + + + 360 + 220 + 60 + 30 + + + + + 14 + + + + color: rgb(221, 225, 233); + + + 失败值: + + + + + + 420 + 220 + 70 + 30 + + + + + 14 + + + + color: rgb(221, 225, 233); +background-color: rgb(47, 48, 52); + + + 0 + + + 65535 + + + 12 + + 190 - 560 + 600 111 38 @@ -597,7 +744,7 @@ background-color: rgb(47, 48, 52); 340 - 560 + 600 111 38 diff --git a/App/GrabBag/GrabBagConfig/Inc/IVrConfig.h b/App/GrabBag/GrabBagConfig/Inc/IVrConfig.h index 4cd1bfc..63fd460 100644 --- a/App/GrabBag/GrabBagConfig/Inc/IVrConfig.h +++ b/App/GrabBag/GrabBagConfig/Inc/IVrConfig.h @@ -67,7 +67,10 @@ struct BolunteConfig double zMin = -1500.0; // Z轴最小值 double zMax = 2500.0; // Z轴最大值 double angleOffset = 0.0; // 旋转角度补偿 - std::string postCoordinateCommand = R"({ "dsID":"www.hc-system.com.RemoteMonitor", "reqType":"command", "cmdData":["rewriteData","800","10","0"] })"; // 坐标发送后的附加命令 + std::string postCoordinateDsID = "www.hc-system.com.RemoteMonitor"; // 坐标发送后附加命令的dsID + int postCoordinateAddress = 800; // 坐标发送后附加命令的地址 + int postCoordinateSuccessValue = 10; // 检测成功时的值 + int postCoordinateFailValue = 12; // 检测失败时的值 }; /** diff --git a/App/GrabBag/GrabBagConfig/Src/VrConfig.cpp b/App/GrabBag/GrabBagConfig/Src/VrConfig.cpp index a962875..216e28c 100644 --- a/App/GrabBag/GrabBagConfig/Src/VrConfig.cpp +++ b/App/GrabBag/GrabBagConfig/Src/VrConfig.cpp @@ -476,10 +476,28 @@ ConfigResult CVrConfig::LoadConfig(const std::string& filePath) result.bolunteConfig.angleOffset = angleOffsetElement->DoubleText(); } - XMLElement* postCmdElement = bolunteConfigElement->FirstChildElement("PostCoordinateCommand"); - if (postCmdElement && postCmdElement->GetText()) + XMLElement* postDsIDElement = bolunteConfigElement->FirstChildElement("PostCoordinateDsID"); + if (postDsIDElement && postDsIDElement->GetText()) { - result.bolunteConfig.postCoordinateCommand = postCmdElement->GetText(); + result.bolunteConfig.postCoordinateDsID = postDsIDElement->GetText(); + } + + XMLElement* postAddressElement = bolunteConfigElement->FirstChildElement("PostCoordinateAddress"); + if (postAddressElement) + { + result.bolunteConfig.postCoordinateAddress = postAddressElement->IntText(); + } + + XMLElement* postSuccessElement = bolunteConfigElement->FirstChildElement("PostCoordinateSuccessValue"); + if (postSuccessElement) + { + result.bolunteConfig.postCoordinateSuccessValue = postSuccessElement->IntText(); + } + + XMLElement* postFailElement = bolunteConfigElement->FirstChildElement("PostCoordinateFailValue"); + if (postFailElement) + { + result.bolunteConfig.postCoordinateFailValue = postFailElement->IntText(); } } @@ -758,9 +776,21 @@ bool CVrConfig::SaveConfig(const std::string& filePath, ConfigResult& configResu bolunteAngleOffsetElement->SetText(configResult.bolunteConfig.angleOffset); bolunteConfigElement->InsertEndChild(bolunteAngleOffsetElement); - XMLElement* boluntePostCmdElement = doc.NewElement("PostCoordinateCommand"); - boluntePostCmdElement->SetText(configResult.bolunteConfig.postCoordinateCommand.c_str()); - bolunteConfigElement->InsertEndChild(boluntePostCmdElement); + XMLElement* boluntePostDsIDElement = doc.NewElement("PostCoordinateDsID"); + boluntePostDsIDElement->SetText(configResult.bolunteConfig.postCoordinateDsID.c_str()); + bolunteConfigElement->InsertEndChild(boluntePostDsIDElement); + + XMLElement* boluntePostAddressElement = doc.NewElement("PostCoordinateAddress"); + boluntePostAddressElement->SetText(configResult.bolunteConfig.postCoordinateAddress); + bolunteConfigElement->InsertEndChild(boluntePostAddressElement); + + XMLElement* boluntePostSuccessElement = doc.NewElement("PostCoordinateSuccessValue"); + boluntePostSuccessElement->SetText(configResult.bolunteConfig.postCoordinateSuccessValue); + bolunteConfigElement->InsertEndChild(boluntePostSuccessElement); + + XMLElement* boluntePostFailElement = doc.NewElement("PostCoordinateFailValue"); + boluntePostFailElement->SetText(configResult.bolunteConfig.postCoordinateFailValue); + bolunteConfigElement->InsertEndChild(boluntePostFailElement); // 保存工作点配置(新增) SaveWorkPositions(doc, root, configResult.workPositions); diff --git a/App/GrabBag/GrabBagConfig/config/config.xml b/App/GrabBag/GrabBagConfig/config/config.xml index 41f60e2..e96fee6 100644 --- a/App/GrabBag/GrabBagConfig/config/config.xml +++ b/App/GrabBag/GrabBagConfig/config/config.xml @@ -276,6 +276,9 @@ -1500.0 2500.0 0.0 - { "dsID":"www.hc-system.com.RemoteMonitor", "reqType":"command", "cmdData":["rewriteData","800","10","0"] } + www.hc-system.com.RemoteMonitor + 800 + 10 + 12 \ No newline at end of file