From ef57389fd66aca85d6fb4a73c0f7c1c1f7d607b2 Mon Sep 17 00:00:00 2001
From: wanshenmean <cathay_xy@163.com>
Date: 星期日, 26 四月 2026 17:46:51 +0800
Subject: [PATCH] Merge branch 'dev' into xiaoyang
---
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Workflow/RobotWorkflowOrchestrator.cs | 28 ++++++++++++++++------------
1 files changed, 16 insertions(+), 12 deletions(-)
diff --git a/Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Workflow/RobotWorkflowOrchestrator.cs b/Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Workflow/RobotWorkflowOrchestrator.cs
index ec3d757..3d5241e 100644
--- a/Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Workflow/RobotWorkflowOrchestrator.cs
+++ b/Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Workflow/RobotWorkflowOrchestrator.cs
@@ -169,6 +169,9 @@
bool isFlowA = task.RobotSourceAddressLineCode is "11001" or "11010";
+ await _taskProcessor.SendSocketRobotNumAsync(task, state, false);
+ Thread.Sleep(500);
+
// ==================== Phase 2: 鏀炬甯哥數鑺埌鐩爣鎵樼洏锛堜袱娴佸悜鐩稿悓锛�====================
// PickFinished 鍒拌揪锛歅hase 1 鐨� Pick 鍛戒护瀹屾垚锛岀幇鍦ㄤ笅鍙� Put 鍛戒护鏀炬甯哥數鑺�
if (state?.ChangePalletPhase == 2)
@@ -239,8 +242,6 @@
return;
}
- // 闈炴壒娆℃ā寮忔垨鍏朵粬闃舵涓嶄笅鍙戞寚浠�
- return;
}
// 闈炴崲鐩樹换鍔★細浣跨敤鍘熸湁鏍煎紡
@@ -273,7 +274,7 @@
if (_stateManager.TryUpdateStateSafely(ipAddress, stateToUpdate))
{
- await _robotTaskService.UpdateRobotTaskAsync(task);
+ //await _robotTaskService.UpdateRobotTaskAsync(task);
}
}
}
@@ -337,15 +338,15 @@
// 濡傛灉鏉$爜鐢熸垚鎴愬姛
if (!string.IsNullOrEmpty(trayBarcode1) && !string.IsNullOrEmpty(trayBarcode2))
{
- if (stateForUpdate.CellBarcode.Contains(trayBarcode1) || stateForUpdate.CellBarcode.Contains(trayBarcode2))
- {
- QuartzLogHelper.LogInfo(_logger, $"HandlePutFinishedStateAsync锛氳鍙栫殑鐢佃姱鏉$爜宸插瓨鍦紝鍙兘瀛樺湪閲嶅锛屼换鍔″彿: {task.RobotTaskNum}", stateForUpdate?.RobotCrane?.DeviceName ?? ipAddress);
+ //if (stateForUpdate.CellBarcode.Contains(trayBarcode1) || stateForUpdate.CellBarcode.Contains(trayBarcode2))
+ //{
+ // QuartzLogHelper.LogInfo(_logger, $"HandlePutFinishedStateAsync锛氳鍙栫殑鐢佃姱鏉$爜宸插瓨鍦紝鍙兘瀛樺湪閲嶅锛屼换鍔″彿: {task.RobotTaskNum}", stateForUpdate?.RobotCrane?.DeviceName ?? ipAddress);
- // 鍙戦�佸彇璐ф寚浠� 鏍囪鎵爜NG锛屾斁璐ф椂涓嶄娇鐢ㄨ繖浜涙潯鐮侊紝骞舵斁鍏G鍙�
- //await _taskProcessor.SendSocketRobotPickAsync(task, stateForUpdate, true);
- return;
- }
- else
+ // // 鍙戦�佸彇璐ф寚浠� 鏍囪鎵爜NG锛屾斁璐ф椂涓嶄娇鐢ㄨ繖浜涙潯鐮侊紝骞舵斁鍏G鍙�
+ // //await _taskProcessor.SendSocketRobotPickAsync(task, stateForUpdate, true);
+ // return;
+ //}
+ //else
{
if (trayBarcode1.Length < 13 || trayBarcode2.Length < 13)
{
@@ -389,8 +390,11 @@
// 鍒ゆ柇娴佸悜锛坣ull-safe锛�
bool isFlowA = task.RobotSourceAddressLineCode is "11001" or "11010";
+ await _taskProcessor.SendSocketRobotNumAsync(task, stateForUpdate);
+ Thread.Sleep(500);
+
// 鐩爣鏁伴噺涓�48锛氱洿鎺ヨ蛋鍘熸湁閫昏緫锛屼笉杩涘叆鎵规妯″紡
- if (targetNormalCount == targetTotal)
+ if (targetNormalCount + currentCompletedCount == targetTotal)
{
await _taskProcessor.SendSocketRobotPickAsync(task, stateForUpdate);
return;
--
Gitblit v1.9.3