|
|
|
@ -60,7 +60,7 @@ namespace Rs.MotionPlat.Flow.SubFlow
|
|
|
|
|
HObject[] grabImages= null;
|
|
|
|
|
Stopwatch timeout = new Stopwatch();
|
|
|
|
|
string logInfo = string.Empty;
|
|
|
|
|
|
|
|
|
|
Stopwatch scanBarCodeWait= new Stopwatch();
|
|
|
|
|
|
|
|
|
|
bool exit = true;
|
|
|
|
|
//ManualResetEvent grabFinishedEvent = new ManualResetEvent(true);
|
|
|
|
@ -325,16 +325,25 @@ namespace Rs.MotionPlat.Flow.SubFlow
|
|
|
|
|
AxisControl.LoadX.ComparePulse(2, false);
|
|
|
|
|
logInfo = GetClassName() + $"已运动到扫码起始位";
|
|
|
|
|
MessageQueue.Instance.Insert(logInfo);
|
|
|
|
|
scanBarCodeWait.Restart();
|
|
|
|
|
fixedStep = EUpCameraFixedScanBarCodeFlowStep.等待扫码结束;
|
|
|
|
|
}
|
|
|
|
|
break;
|
|
|
|
|
case EUpCameraFixedScanBarCodeFlowStep.等待扫码结束:
|
|
|
|
|
if(scanBarCodeWait.ElapsedMilliseconds<3000)
|
|
|
|
|
{
|
|
|
|
|
HObject image = ImageProcess.GetManualImage();
|
|
|
|
|
if(image!=null)
|
|
|
|
|
if (image != null)
|
|
|
|
|
{
|
|
|
|
|
imageSingle = ImageRotate.Rotate(image, "upCamera");
|
|
|
|
|
fixedStep = EUpCameraFixedScanBarCodeFlowStep.拍照结果处理;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
fixedStep = EUpCameraFixedScanBarCodeFlowStep.到扫码位上方;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
case EUpCameraFixedScanBarCodeFlowStep.拍照结果处理:
|
|
|
|
|
singleResult = VisionManager.TurnoverTrayDumpProductOK(imageSingle, bNeedLocate, bNeedScanBarcode, SlotIndex);
|
|
|
|
|