diff --git a/Rs.DeweyTester/Commom/TrayPointManager.cs b/Rs.DeweyTester/Commom/TrayPointManager.cs
index bc57297..b4debac 100644
--- a/Rs.DeweyTester/Commom/TrayPointManager.cs
+++ b/Rs.DeweyTester/Commom/TrayPointManager.cs
@@ -62,6 +62,33 @@ namespace Rs.MotionPlat.Commom
}
return null;
}
-
+
+ ///
+ /// 获取料盘的点位
+ ///
+ ///
+ ///
+ ///
+ ///
+ ///
+ public static List GetAllSlotPoint(ETrayType trayType)
+ {
+ List list = new List();
+ for(int i = 0;i<256;i++)
+ {
+ string key = $"{GlobalVar.CurRecipe}-{trayType}-{i+1}";
+ if (trayPoints.ContainsKey(key))
+ {
+ list.Add(trayPoints[key]);
+ }
+ //if (trayPoints)
+ //if(item.Key.IndexOf($"{GlobalVar.CurRecipe}-{trayType}") >=0)
+ //{
+ // list.Add(item.Value);
+ //}
+
+ }
+ return list;
+ }
}
}
diff --git a/Rs.DeweyTester/Flow/NormalFlow/ThreePointLocationFlow.cs b/Rs.DeweyTester/Flow/NormalFlow/ThreePointLocationFlow.cs
index e363e57..cae6f50 100644
--- a/Rs.DeweyTester/Flow/NormalFlow/ThreePointLocationFlow.cs
+++ b/Rs.DeweyTester/Flow/NormalFlow/ThreePointLocationFlow.cs
@@ -1,4 +1,5 @@
-using Newtonsoft.Json;
+using HalconDotNet;
+using Newtonsoft.Json;
using Rs.DataAccess;
using Rs.Framework;
using Rs.Motion;
@@ -249,5 +250,78 @@ namespace Rs.MotionPlat.Flow.NormalFlow
//}
}
}
+
+
+ public void CalcTrayRunPoint2(ETrayType trayType)
+ {
+ double sx1 = TrayPointManager.GetSlotPoint(trayType, 1).X;
+ double sy1 = TrayPointManager.GetSlotPoint(trayType, 1).Y ;
+
+ double sx2 = TrayPointManager.GetSlotPoint(trayType, 16).X ;
+ double sy2 = TrayPointManager.GetSlotPoint(trayType, 16).Y ;
+
+ double sx3 = TrayPointManager.GetSlotPoint(trayType, 241).X ;
+ double sy3 = TrayPointManager.GetSlotPoint(trayType, 241).Y ;
+
+
+ double x1 = TrayPointManager.GetSlotPoint(trayType, 1).X + 0.1;// vResult[0].OffsetX;
+ double y1 = TrayPointManager.GetSlotPoint(trayType, 1).Y + 0.07;// vResult[0].OffsetY;
+
+ double x2 = TrayPointManager.GetSlotPoint(trayType, 16).X + 0.1;// vResult[1].OffsetX;
+ double y2 = TrayPointManager.GetSlotPoint(trayType, 16).Y + 0.07;// vResult[1].OffsetY;
+
+ double x3 = TrayPointManager.GetSlotPoint(trayType, 241).X + 0.1;// vResult[2].OffsetX;
+ double y3 = TrayPointManager.GetSlotPoint(trayType, 241).Y + 0.07;// vResult[2].OffsetY;
+
+ HOperatorSet.VectorToHomMat2d(new HTuple(sx1).TupleConcat(sx2).TupleConcat(sx3), new HTuple(sy1).TupleConcat(sy2).TupleConcat(sy3), new HTuple(x1).TupleConcat(x2).TupleConcat(x3), new HTuple(y1).TupleConcat(y2).TupleConcat(y3), out HTuple homMat2D);
+ //HOperatorSet.AffineTransPoint2d(homMat2D,)
+ List points = TrayPointManager.GetAllSlotPoint(trayType);
+ HTuple xx = new HTuple();
+ HTuple yy = new HTuple();
+ //for(int i=0;i4
+
+ False
+ bin\Debug\halcondotnet.dll
+
False
bin\Debug\ICSharpCode.SharpZipLib.dll
diff --git a/Rs.DeweyTester/TestFrm.cs b/Rs.DeweyTester/TestFrm.cs
index 1446b3e..973fcdb 100644
--- a/Rs.DeweyTester/TestFrm.cs
+++ b/Rs.DeweyTester/TestFrm.cs
@@ -346,7 +346,11 @@ namespace Rs.MotionPlat
private void button10_Click(object sender, EventArgs e)
{
- StockLocationFlow.Instance.Grab(ETrayType.Grr, 1);
+ ThreePointLocationFlow.Instance.CalcTrayRunPoint2(ETrayType.Ng);
+
+
+ //TrayPointManager.GetAllSlotPoint(ETrayType.Ng);
+ //StockLocationFlow.Instance.Grab(ETrayType.Grr, 1);
}
}
}