| | |
| | | |
| | | if (_stateManager.TryUpdateStateSafely(ipAddress, stateToUpdate)) |
| | | { |
| | | await _robotTaskService.UpdateRobotTaskAsync(task); |
| | | //await _robotTaskService.UpdateRobotTaskAsync(task); |
| | | } |
| | | } |
| | | } |
| | |
| | | // 如果条码生成成功 |
| | | 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,放货时不使用这些条码,并放入NG口 |
| | | //await _taskProcessor.SendSocketRobotPickAsync(task, stateForUpdate, true); |
| | | return; |
| | | } |
| | | else |
| | | // // 发送取货指令 标记扫码NG,放货时不使用这些条码,并放入NG口 |
| | | // //await _taskProcessor.SendSocketRobotPickAsync(task, stateForUpdate, true); |
| | | // return; |
| | | //} |
| | | //else |
| | | { |
| | | if (trayBarcode1.Length < 13 || trayBarcode2.Length < 13) |
| | | { |