|
@@ -1,7 +1,6 @@
|
|
|
using ServiceCenter;
|
|
|
using ServiceCenter.SqlSugars;
|
|
|
using WCS.Core;
|
|
|
-using WCS.Entity;
|
|
|
using WCS.Entity.Protocol.BCR;
|
|
|
using WCS.Entity.Protocol.RGV;
|
|
|
using WCS.Entity.Protocol.Robot;
|
|
@@ -34,6 +33,17 @@ namespace WCS.WorkEngineering
|
|
|
conv.AddProtocol<IStation520>(0, 520, "1");
|
|
|
}
|
|
|
|
|
|
+ //var devs1 = new DevDbConfig<string>()
|
|
|
+ //{
|
|
|
+ // IP = "1",
|
|
|
+ // DevCodeList = new List<string>() { nameof(分线计算09), nameof(桁架码垛区补空托盘任务生成), "出库AGV", "入库AGV", nameof(NoInteractionSystems), nameof(UpLoadSystems), nameof(创建二次码垛出库任务) }
|
|
|
+ //};
|
|
|
+ //Parallel.ForEach(devs1.DevCodeList, convCode =>
|
|
|
+ //{
|
|
|
+ // var conv = new Device(convCode);
|
|
|
+ // conv.AddProtocol<IStation520>(0, 520, devs1.IP);
|
|
|
+ //});
|
|
|
+
|
|
|
#endregion 无交互触发设备
|
|
|
|
|
|
#region 设置设备IP集合
|
|
@@ -63,6 +73,23 @@ namespace WCS.WorkEngineering
|
|
|
//conv.AddProtocol<IStation523>(, 523, item.IP);
|
|
|
}
|
|
|
|
|
|
+ //var rgvInfo = new List<DevDbConfig<int>>()
|
|
|
+ //{
|
|
|
+ // new("10.30.37.113",1),
|
|
|
+ // new("10.30.37.118",2),
|
|
|
+ // new("10.30.37.123",3),
|
|
|
+ // new("10.30.37.128",4),
|
|
|
+ // new("10.30.37.133",5),
|
|
|
+ // new("10.30.37.138",6),
|
|
|
+ //};
|
|
|
+ //Parallel.ForEach(rgvInfo, dev =>
|
|
|
+ //{
|
|
|
+ // var conv = new Device($"RGV{dev.Code}");
|
|
|
+ // conv.AddFlag(DeviceFlags.RGV);
|
|
|
+ // conv.AddProtocol<IRGV520>(0, 520, dev.IP);
|
|
|
+ // conv.AddProtocol<IRGV521>(0, 521, dev.IP);
|
|
|
+ //});
|
|
|
+
|
|
|
#endregion 初始化RGV相关信息
|
|
|
|
|
|
#region 初始化输送机相关信息
|
|
@@ -81,22 +108,22 @@ namespace WCS.WorkEngineering
|
|
|
new(2701, 2740),
|
|
|
new(1661, 1690),
|
|
|
}),
|
|
|
- ////分拣库二
|
|
|
- //new("10.30.37.97",new List<Tuple<int, int>>()
|
|
|
- //{
|
|
|
- // new(1621, 1640),
|
|
|
- // new(2901, 2940),
|
|
|
- // new(3101, 3140),
|
|
|
- // new(1691, 1720),
|
|
|
- //}),
|
|
|
- ////分拣库三
|
|
|
- //new("10.30.37.105",new List<Tuple<int, int>>()
|
|
|
- //{
|
|
|
- // new(1641, 1660),
|
|
|
- // new(3301, 3340),
|
|
|
- // new(3501, 3540),
|
|
|
- // new(1721, 1750)
|
|
|
- //})
|
|
|
+ //分拣库二
|
|
|
+ new("10.30.37.97",new List<Tuple<int, int>>()
|
|
|
+ {
|
|
|
+ new(1621, 1640),
|
|
|
+ new(2901, 2940),
|
|
|
+ new(3101, 3140),
|
|
|
+ new(1691, 1720),
|
|
|
+ }),
|
|
|
+ //分拣库三
|
|
|
+ new("10.30.37.105",new List<Tuple<int, int>>()
|
|
|
+ {
|
|
|
+ new(1641, 1660),
|
|
|
+ new(3301, 3340),
|
|
|
+ new(3501, 3540),
|
|
|
+ new(1721, 1750)
|
|
|
+ })
|
|
|
};
|
|
|
|
|
|
foreach (var item in tuples)
|
|
@@ -122,6 +149,35 @@ namespace WCS.WorkEngineering
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //var devs2 = new List<DevDbConfig<int>>()
|
|
|
+ //{
|
|
|
+ // new("10.30.37.89",new List<DevInterval<int>>(){new (1601,1620),new (2501, 2540),new (2701, 2740),new (1661, 1690) }),
|
|
|
+ // new("10.30.37.97",new List<DevInterval<int>>(){new (1621, 1640),new (2901, 2940),new (3101, 3140),new (1691, 1720) }),
|
|
|
+ // new("10.30.37.105",new List<DevInterval<int>>(){new (1641, 1660),new (3301, 3340),new (3501, 3540),new (1721, 1750) })
|
|
|
+ //};
|
|
|
+ //Parallel.ForEach(devs2, dev =>
|
|
|
+ //{
|
|
|
+ // var db520 = 0;
|
|
|
+ // var db521 = 0;
|
|
|
+ // var db523 = 0;
|
|
|
+ // foreach (var devInterval in dev.DevIntervalList)
|
|
|
+ // {
|
|
|
+ // for (var i = devInterval.StartCode; i <= devInterval.EndCode; i++)
|
|
|
+ // {
|
|
|
+ // var conv = new Device(i.ToString());
|
|
|
+ // conv.AddFlag(DeviceFlags.输送机);
|
|
|
+
|
|
|
+ // conv.AddProtocol<IStation520>(db520, 520, dev.IP);
|
|
|
+ // conv.AddProtocol<IStation521>(db521, 521, dev.IP);
|
|
|
+ // conv.AddProtocol<IStation523>(db523, 523, dev.IP);
|
|
|
+
|
|
|
+ // db520 += 14;
|
|
|
+ // db521 += 16;
|
|
|
+ // db523 += 12;
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ //});
|
|
|
+
|
|
|
#endregion 托盘线输送线
|
|
|
|
|
|
#region 满轮输送线
|
|
@@ -138,14 +194,14 @@ namespace WCS.WorkEngineering
|
|
|
new(801,999),
|
|
|
new(1201,1399),
|
|
|
}),
|
|
|
- //new("10.30.37.198",new List<Tuple<int, int>>() //南侧满轮主线
|
|
|
- //{
|
|
|
- // new(101, 210),
|
|
|
- // new(601, 799),
|
|
|
- // new(1001, 1199),
|
|
|
- // new(1401,1599),
|
|
|
- // new(341,379),
|
|
|
- //})
|
|
|
+ new("10.30.37.198",new List<Tuple<int, int>>() //南侧满轮主线
|
|
|
+ {
|
|
|
+ new(101, 210),
|
|
|
+ new(601, 799),
|
|
|
+ new(1001, 1199),
|
|
|
+ new(1401,1599),
|
|
|
+ new(341,379),
|
|
|
+ })
|
|
|
};
|
|
|
|
|
|
foreach (var item in mLtuples523)
|
|
@@ -167,6 +223,31 @@ namespace WCS.WorkEngineering
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //var devs3 = new List<DevDbConfig<int>>()
|
|
|
+ //{
|
|
|
+ // new("10.30.37.166",new List<DevInterval<int>>(){new (1, 100),new (9001, 9010),new (401, 599),new (801, 999),new (1201, 1399) }),
|
|
|
+ // new("10.30.37.198",new List<DevInterval<int>>(){new (101, 210),new (601, 799),new (1001, 1199),new (1401, 1599),new (341, 379) })
|
|
|
+ //};
|
|
|
+
|
|
|
+ //Parallel.ForEach(devs3, dev =>
|
|
|
+ //{
|
|
|
+ // var db523 = 0;
|
|
|
+ // var db524 = 0;
|
|
|
+ // foreach (var devInterval in dev.DevIntervalList)
|
|
|
+ // {
|
|
|
+ // for (var i = devInterval.StartCode; i <= devInterval.EndCode; i++)
|
|
|
+ // {
|
|
|
+ // var conv = new Device(i.ToString());
|
|
|
+ // conv.AddFlag(DeviceFlags.输送机);
|
|
|
+ // conv.AddProtocol<IStation523>(db523, 523, dev.IP);
|
|
|
+ // conv.AddProtocol<IStation524>(db524, 524, dev.IP);
|
|
|
+
|
|
|
+ // db523 += 12;
|
|
|
+ // db524 += 16;
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ //});
|
|
|
+
|
|
|
#endregion DB523,所有线体都会有DB523
|
|
|
|
|
|
#region 520、521 交互线体会有520、521
|
|
@@ -176,8 +257,8 @@ namespace WCS.WorkEngineering
|
|
|
{
|
|
|
//北侧
|
|
|
new("10.30.37.166",new List<int>() {1,22,41,61,418,426,435,444,455,466,480,494,508,522,536,550,564,578,591,818,826,835,844,855,866,880,894,908,922,936,950,964,978,991,1218,1226,1235,1244,1255,1266,1280,1294,1308,1322,1336,1350,1364,1378,1391}),
|
|
|
- ////南侧
|
|
|
- //new("10.30.37.198",new List<int>(){101,122,141,161,618,626,635,644,655,666,680,694,708,722,736,750,764,778,791,1018,1026,1035,1044,1055,1066,1080,1094,1108,1122,1136,1150,1164,1178,1191,1418,1426,1435,1444,1455,1466,1480,1494,1508,1522,1536,1550,1564,1578,1591})
|
|
|
+ //南侧
|
|
|
+ new("10.30.37.198",new List<int>(){101,122,141,161,618,626,635,644,655,666,680,694,708,722,736,750,764,778,791,1018,1026,1035,1044,1055,1066,1080,1094,1108,1122,1136,1150,1164,1178,1191,1418,1426,1435,1444,1455,1466,1480,1494,1508,1522,1536,1550,1564,1578,1591})
|
|
|
};
|
|
|
|
|
|
foreach (var item in mLTuples520)
|
|
@@ -198,6 +279,27 @@ namespace WCS.WorkEngineering
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //var devs4 = new List<DevDbConfig<int>>()
|
|
|
+ //{
|
|
|
+ // new ("10.30.37.166",new List<int>(){1,22,41,61,418,426,435,444,455,466,480,494,508,522,536,550,564,578,591,818,826,835,844,855,866,880,894,908,922,936,950,964,978,991,1218,1226,1235,1244,1255,1266,1280,1294,1308,1322,1336,1350,1364,1378,1391}),
|
|
|
+ // new ("10.30.37.198",new List<int>(){101,122,141,161,618,626,635,644,655,666,680,694,708,722,736,750,764,778,791,1018,1026,1035,1044,1055,1066,1080,1094,1108,1122,1136,1150,1164,1178,1191,1418,1426,1435,1444,1455,1466,1480,1494,1508,1522,1536,1550,1564,1578,1591})
|
|
|
+ //};
|
|
|
+
|
|
|
+ //Parallel.ForEach(devs4, dev =>
|
|
|
+ //{
|
|
|
+ // var db520 = 0;
|
|
|
+ // var db521 = 0;
|
|
|
+ // foreach (var devCode in dev.DevCodeList)
|
|
|
+ // {
|
|
|
+ // var device = Device.All.FirstOrDefault(v => v.Code == devCode.ToString());
|
|
|
+ // device.AddProtocol<IStation520>(db520, 520, dev.IP);
|
|
|
+ // device.AddProtocol<IStation521>(db521, 521, dev.IP);
|
|
|
+
|
|
|
+ // db520 += 14;
|
|
|
+ // db521 += 16;
|
|
|
+ // }
|
|
|
+ //});
|
|
|
+
|
|
|
#endregion 520、521 交互线体会有520、521
|
|
|
|
|
|
#region 满轮扫码器
|
|
@@ -206,7 +308,7 @@ namespace WCS.WorkEngineering
|
|
|
var mLTuples83 = new List<Tuple<string, List<int>>>()
|
|
|
{
|
|
|
new("10.30.37.166",new List<int>(){3,14,18,22,38,323,41,58,61}) ,
|
|
|
- //new("10.30.37.198",new List<int>(){101,114,118,122,138,363,141,158,161})
|
|
|
+ new("10.30.37.198",new List<int>(){101,114,118,122,138,363,141,158,161})
|
|
|
};
|
|
|
|
|
|
foreach (var item in mLTuples83)
|
|
@@ -220,6 +322,23 @@ namespace WCS.WorkEngineering
|
|
|
db83 += 604;
|
|
|
}
|
|
|
}
|
|
|
+ //var devs5 = new List<DevDbConfig<int>>()
|
|
|
+ //{
|
|
|
+ // new("10.30.37.166",new List<int>(){3,14,18,22,38,323,41,58,61}) ,
|
|
|
+ // new("10.30.37.198",new List<int>(){101,114,118,122,138,363,141,158,161})
|
|
|
+ //};
|
|
|
+
|
|
|
+ //Parallel.ForEach(devs5, dev =>
|
|
|
+ //{
|
|
|
+ // var db83 = 0;
|
|
|
+ // foreach (var devCode in dev.DevCodeList)
|
|
|
+ // {
|
|
|
+ // var device = Device.All.FirstOrDefault(v => v.Code == devCode.ToString());
|
|
|
+ // device.AddProtocol<IBCR83>(db83, 83, dev.IP);
|
|
|
+
|
|
|
+ // db83 += 604;
|
|
|
+ // }
|
|
|
+ //});
|
|
|
|
|
|
#endregion 满轮扫码器
|
|
|
|
|
@@ -229,7 +348,7 @@ namespace WCS.WorkEngineering
|
|
|
var mLTuples525 = new List<Tuple<string, List<int>>>()
|
|
|
{
|
|
|
new("10.30.37.166",new List<int>(){18,38,58}),
|
|
|
- //new("10.30.37.198",new List<int>(){118,138,158}),
|
|
|
+ new("10.30.37.198",new List<int>(){118,138,158}),
|
|
|
};
|
|
|
|
|
|
foreach (var item in mLTuples525)
|
|
@@ -243,6 +362,23 @@ namespace WCS.WorkEngineering
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //var devs6 = new List<DevDbConfig<int>>()
|
|
|
+ //{
|
|
|
+ // new("10.30.37.166",new List<int>(){18,38,58}),
|
|
|
+ // new("10.30.37.198",new List<int>(){118,138,158}),
|
|
|
+ //};
|
|
|
+
|
|
|
+ //Parallel.ForEach(devs6, dev =>
|
|
|
+ //{
|
|
|
+ // var db525 = 0;
|
|
|
+ // foreach (var devCode in dev.DevCodeList)
|
|
|
+ // {
|
|
|
+ // var device = Device.All.FirstOrDefault(v => v.Code == devCode.ToString());
|
|
|
+ // device?.AddProtocol<IStation525>(db525, 525, dev.IP);
|
|
|
+ // db525 += 3266;
|
|
|
+ // }
|
|
|
+ //});
|
|
|
+
|
|
|
#endregion 满轮线告诉分拣预分配
|
|
|
|
|
|
#region 外检信息
|
|
@@ -251,7 +387,7 @@ namespace WCS.WorkEngineering
|
|
|
var mLTuples91 = new List<Tuple<string, List<int>>>()
|
|
|
{
|
|
|
new("10.30.37.166",new List<int>(){418,818,1218}),
|
|
|
- //new("10.30.37.198",new List<int>(){618,1018,1418})
|
|
|
+ new("10.30.37.198",new List<int>(){618,1018,1418})
|
|
|
};
|
|
|
|
|
|
foreach (var item in mLTuples91)
|
|
@@ -265,6 +401,23 @@ namespace WCS.WorkEngineering
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //var devs7 = new List<DevDbConfig<int>>()
|
|
|
+ //{
|
|
|
+ // new("10.30.37.166",new List<int>(){418,818,1218}),
|
|
|
+ // new("10.30.37.198",new List<int>(){618,1018,1418})
|
|
|
+ //};
|
|
|
+
|
|
|
+ //Parallel.ForEach(devs7, dev =>
|
|
|
+ //{
|
|
|
+ // var db91 = 0;
|
|
|
+ // foreach (var devCode in dev.DevCodeList)
|
|
|
+ // {
|
|
|
+ // var device = Device.All.FirstOrDefault(v => v.Code == devCode.ToString());
|
|
|
+ // device.AddProtocol<IStation91>(db91, 91, dev.IP);
|
|
|
+ // db91 += 14;
|
|
|
+ // }
|
|
|
+ //});
|
|
|
+
|
|
|
#endregion 外检信息
|
|
|
|
|
|
#endregion 满轮输送线
|
|
@@ -276,14 +429,14 @@ namespace WCS.WorkEngineering
|
|
|
var bcrInfo = new List<BcrInfo>
|
|
|
{
|
|
|
new(new [] { "2532", "2732" }, "10.30.37.89"),
|
|
|
- //new(new [] { "2932", "3132" }, "10.30.37.97"),
|
|
|
+ new(new [] { "2932", "3132" }, "10.30.37.97"),
|
|
|
//new(new [] { "2532", "2732" }, "10.30.37.105"),
|
|
|
new(new [] {"RGV1"},"10.30.37.113"),
|
|
|
- //new(new [] {"RGV2"},"10.30.37.118"),
|
|
|
- //new(new [] {"RGV3"},"10.30.37.123"),
|
|
|
- //new(new [] {"RGV4"},"10.30.37.128"),
|
|
|
- //new(new [] {"RGV5"},"10.30.37.133"),
|
|
|
- //new(new [] {"RGV6"},"10.30.37.138")
|
|
|
+ new(new [] {"RGV2"},"10.30.37.118"),
|
|
|
+ new(new [] {"RGV3"},"10.30.37.123"),
|
|
|
+ new(new [] {"RGV4"},"10.30.37.128"),
|
|
|
+ new(new [] {"RGV5"},"10.30.37.133"),
|
|
|
+ new(new [] {"RGV6"},"10.30.37.138")
|
|
|
};
|
|
|
|
|
|
foreach (var item in bcrInfo)
|
|
@@ -304,7 +457,7 @@ namespace WCS.WorkEngineering
|
|
|
List<ShapeInfo> shapeInfo = new List<ShapeInfo>
|
|
|
{
|
|
|
new ShapeInfo(new int[] { 2732,2532 }, "10.30.37.89"),
|
|
|
- //new ShapeInfo(new int[] { 2932, 3132 }, "10.30.37.97"),
|
|
|
+ new ShapeInfo(new int[] { 2932, 3132 }, "10.30.37.97"),
|
|
|
//new ShapeInfo(new int[] { 2732,2532 }, "10.30.37.105")
|
|
|
};
|
|
|
|
|
@@ -371,7 +524,7 @@ namespace WCS.WorkEngineering
|
|
|
{
|
|
|
//机械臂
|
|
|
new("10.30.37.230",new List<int>(){ 1666, 1661}), //库一北
|
|
|
- //new("10.30.37.232",new List<int>(){ 1681, 1676}), //库一南
|
|
|
+ new("10.30.37.232",new List<int>(){ 1681, 1676}), //库一南
|
|
|
//new("10.30.37.234",new List<int>(){ 1696, 1691}), //库二北
|
|
|
//new("10.30.37.236",new List<int>(){ 1711, 1706}), //库二南
|
|
|
//new("10.30.37.238",new List<int>(){ 1726, 1721}), //库三北
|
|
@@ -398,7 +551,7 @@ namespace WCS.WorkEngineering
|
|
|
List<TrussSegmentInfo> TrussInfo1 = new List<TrussSegmentInfo>
|
|
|
{
|
|
|
new( 1, "10.30.37.230"),
|
|
|
- //new( 2, "10.30.37.232"),
|
|
|
+ new( 2, "10.30.37.232"),
|
|
|
//new( 3, "10.30.37.234"),
|
|
|
//new( 4, "10.30.37.236"),
|
|
|
//new( 5, "10.30.37.238"),
|
|
@@ -543,8 +696,8 @@ namespace WCS.WorkEngineering
|
|
|
//库一
|
|
|
new RouteInfo("Robot1", new string[] { "1666" }),
|
|
|
new RouteInfo("Robot1", new string[] { "1661" }),
|
|
|
- //new RouteInfo("Robot2", new string[] { "1676" }),
|
|
|
- //new RouteInfo("Robot2", new string[] { "1681" }),
|
|
|
+ new RouteInfo("Robot2", new string[] { "1676" }),
|
|
|
+ new RouteInfo("Robot2", new string[] { "1681" }),
|
|
|
////库二
|
|
|
//new RouteInfo("Robot3", new string[] { "1691" }),
|
|
|
//new RouteInfo("Robot3", new string[] { "1696" }),
|
|
@@ -602,20 +755,20 @@ namespace WCS.WorkEngineering
|
|
|
new RouteInfo("41", new string[] { "58" }),
|
|
|
new RouteInfo("58", new string[] { "61" }),
|
|
|
////南侧
|
|
|
- //new RouteInfo("101", new string[] { "114" }),
|
|
|
- //new RouteInfo("114", new string[] { "118" }),
|
|
|
- //new RouteInfo("118", new string[] { "122" }),
|
|
|
- //new RouteInfo("122", new string[] { "138" }),
|
|
|
- //new RouteInfo("138", new string[] { "141" }),
|
|
|
- //new RouteInfo("141", new string[] { "158" }),
|
|
|
- //new RouteInfo("158", new string[] { "161" }),
|
|
|
+ new RouteInfo("101", new string[] { "114" }),
|
|
|
+ new RouteInfo("114", new string[] { "118" }),
|
|
|
+ new RouteInfo("118", new string[] { "122" }),
|
|
|
+ new RouteInfo("122", new string[] { "138" }),
|
|
|
+ new RouteInfo("138", new string[] { "141" }),
|
|
|
+ new RouteInfo("141", new string[] { "158" }),
|
|
|
+ new RouteInfo("158", new string[] { "161" }),
|
|
|
|
|
|
#endregion 主线
|
|
|
|
|
|
#region 主线分流点--环形库分流点
|
|
|
|
|
|
new RouteInfo("22", new string[] { "418" }), //分拣库一北
|
|
|
- //new RouteInfo("122", new string[] { "618" }), //分拣库一南
|
|
|
+ new RouteInfo("122", new string[] { "618" }), //分拣库一南
|
|
|
//new RouteInfo("41", new string[] { "818" }), //分拣库一北
|
|
|
//new RouteInfo("141", new string[] { "1018" }), //分拣库一南
|
|
|
//new RouteInfo("61", new string[] { "1218" }), //分拣库一北
|
|
@@ -626,7 +779,7 @@ namespace WCS.WorkEngineering
|
|
|
#region 环形库分流点--环形库取货点
|
|
|
|
|
|
new RouteInfo("418", new string[] { "424","433","442" }),
|
|
|
- //new RouteInfo("618", new string[] { "624", "633", "642" }),
|
|
|
+ new RouteInfo("618", new string[] { "624", "633", "642" }),
|
|
|
//new RouteInfo("818", new string[] { "824","833","842" }),
|
|
|
//new RouteInfo("1018", new string[] { "1024","1033","1042" }),
|
|
|
//new RouteInfo("1218", new string[] { "1224","1233","1242" }),
|
|
@@ -637,7 +790,7 @@ namespace WCS.WorkEngineering
|
|
|
#region 环形库分流点--桁架分流点
|
|
|
|
|
|
new RouteInfo("418", new string[] { "455" }), //分拣库一北
|
|
|
- //new RouteInfo("618", new string[] { "655" }), //分拣库一南
|
|
|
+ new RouteInfo("618", new string[] { "655" }), //分拣库一南
|
|
|
//new RouteInfo("818", new string[] { "855" }), //分拣库二北
|
|
|
//new RouteInfo("1018", new string[] { "1055" }), //分拣库二南
|
|
|
//new RouteInfo("1218", new string[] { "1255" }), //分拣库三北
|
|
@@ -648,7 +801,7 @@ namespace WCS.WorkEngineering
|
|
|
#region 桁架分流点--桁架缓存放行点
|
|
|
|
|
|
new RouteInfo("455", new string[] { "466","480","494","508", "522","536","550","564","578","591"}), //分拣库一北
|
|
|
- //new RouteInfo("655", new string[] { "666","680","694","708", "722","736","750","764","778","791"}), //分拣库一南
|
|
|
+ new RouteInfo("655", new string[] { "666","680","694","708", "722","736","750","764","778","791"}), //分拣库一南
|
|
|
//new RouteInfo("855", new string[] { "866","880","894","908", "922","936","950","964","978","991"}), //分拣库二北
|
|
|
//new RouteInfo("1055", new string[] { "1066","1080","1094","1108", "1122","1136","1150","1164","1178","1191"}), //分拣库二南
|
|
|
//new RouteInfo("1255", new string[] { "1266","1280","1294","1308", "1322","1336","1350","1364","1378", "1391"}), //分拣库三北
|
|
@@ -668,16 +821,16 @@ namespace WCS.WorkEngineering
|
|
|
new("564", new[] { "559" }),
|
|
|
new("578", new[] { "573" }),
|
|
|
new("591", new[] { "586" }),
|
|
|
- //new("666", new[] { "661" }),//分拣一南侧
|
|
|
- //new("680", new[] { "675" }),
|
|
|
- //new("694", new[] { "689" }),
|
|
|
- //new("708", new[] { "703" }),
|
|
|
- //new("722", new[] { "717" }),
|
|
|
- //new("736", new[] { "731" }),
|
|
|
- //new("750", new[] { "745" }),
|
|
|
- //new("764", new[] { "759" }),
|
|
|
- //new("778", new[] { "773" }),
|
|
|
- //new("791", new[] { "786" }),
|
|
|
+ new("666", new[] { "661" }),//分拣一南侧
|
|
|
+ new("680", new[] { "675" }),
|
|
|
+ new("694", new[] { "689" }),
|
|
|
+ new("708", new[] { "703" }),
|
|
|
+ new("722", new[] { "717" }),
|
|
|
+ new("736", new[] { "731" }),
|
|
|
+ new("750", new[] { "745" }),
|
|
|
+ new("764", new[] { "759" }),
|
|
|
+ new("778", new[] { "773" }),
|
|
|
+ new("791", new[] { "786" }),
|
|
|
//new("866", new[] { "861" }), //分拣二北侧
|
|
|
//new("880", new[] { "875" }),
|
|
|
//new("894", new[] { "889" }),
|
|
@@ -732,17 +885,17 @@ namespace WCS.WorkEngineering
|
|
|
new("545", new[] { "Truss1" }),
|
|
|
new("559", new[] { "Truss1" }),
|
|
|
new("573", new[] { "Truss1" }),
|
|
|
- //new("586", new[] { "Truss1" }),//分拣一南侧
|
|
|
- //new("661", new[] { "Truss1" }),
|
|
|
- //new("675", new[] { "Truss1" }),
|
|
|
- //new("689", new[] { "Truss1" }),
|
|
|
- //new("703", new[] { "Truss1" }),
|
|
|
- //new("717", new[] { "Truss1" }),
|
|
|
- //new("731", new[] { "Truss1" }),
|
|
|
- //new("745", new[] { "Truss1" }),
|
|
|
- //new("759", new[] { "Truss1" }),
|
|
|
- //new("773", new[] { "Truss1" }),
|
|
|
- //new("786", new[] { "Truss1" }),
|
|
|
+ new("586", new[] { "Truss1" }),//分拣一南侧
|
|
|
+ new("661", new[] { "Truss1" }),
|
|
|
+ new("675", new[] { "Truss1" }),
|
|
|
+ new("689", new[] { "Truss1" }),
|
|
|
+ new("703", new[] { "Truss1" }),
|
|
|
+ new("717", new[] { "Truss1" }),
|
|
|
+ new("731", new[] { "Truss1" }),
|
|
|
+ new("745", new[] { "Truss1" }),
|
|
|
+ new("759", new[] { "Truss1" }),
|
|
|
+ new("773", new[] { "Truss1" }),
|
|
|
+ new("786", new[] { "Truss1" }),
|
|
|
//new("861", new[] { "Truss2" }), //分拣二北侧
|
|
|
//new("875", new[] { "Truss2" }),
|
|
|
//new("889", new[] { "Truss2" }),
|
|
@@ -798,16 +951,16 @@ namespace WCS.WorkEngineering
|
|
|
new("559", new[] { "1662","1663","1664","1665","1670","1671","1672","1673", "1674","1675"}),
|
|
|
new("573", new[] { "1662","1663","1664","1665","1670","1671","1672","1673", "1674","1675"}),
|
|
|
new("586", new[] { "1662","1663","1664","1665","1670","1671","1672","1673", "1674","1675" }),
|
|
|
- //new("661", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),//分拣一南侧
|
|
|
- //new("675", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
- //new("689", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
- //new("703", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
- //new("717", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
- //new("731", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
- //new("745", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
- //new("759", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
- //new("773", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
- //new("786", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("661", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),//分拣一南侧
|
|
|
+ new("675", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("689", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("703", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("717", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("731", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("745", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("759", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("773", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
+ new("786", new[] { "1677","1678","1679","1680", "1685","1686","1687","1688","1689","1690" }),
|
|
|
//new("861", new[] { "1692","1693","1694","1695", "1700","1701","1702","1703","1704","1705" }), //分拣二北侧
|
|
|
//new("875", new[] { "1692","1693","1694","1695", "1700","1701","1702","1703","1704","1705" }),
|
|
|
//new("889", new[] { "1692","1693","1694","1695", "1700","1701","1702","1703","1704","1705" }),
|
|
@@ -875,18 +1028,18 @@ namespace WCS.WorkEngineering
|
|
|
new RouteInfo("1674", new string[] { "RGV1" }),
|
|
|
new RouteInfo("1675", new string[] { "RGV1" }),
|
|
|
////分拣库一南
|
|
|
- //new RouteInfo("1676", new string[] { "RGV2" }),//机械手码垛工位
|
|
|
- //new RouteInfo("1681", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1677", new string[] { "RGV2" }),//绗架码垛工位
|
|
|
- //new RouteInfo("1678", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1679", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1680", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1685", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1686", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1687", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1688", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1689", new string[] { "RGV2" }),
|
|
|
- //new RouteInfo("1690", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1676", new string[] { "RGV2" }),//机械手码垛工位
|
|
|
+ new RouteInfo("1681", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1677", new string[] { "RGV2" }),//绗架码垛工位
|
|
|
+ new RouteInfo("1678", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1679", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1680", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1685", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1686", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1687", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1688", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1689", new string[] { "RGV2" }),
|
|
|
+ new RouteInfo("1690", new string[] { "RGV2" }),
|
|
|
|
|
|
////分拣库二北
|
|
|
//new RouteInfo("1691", new string[] { "RGV3" }),//机械手码垛工位
|
|
@@ -992,9 +1145,9 @@ namespace WCS.WorkEngineering
|
|
|
new RouteInfo("442", new string[] { "Robot1" }),
|
|
|
new RouteInfo("433", new string[] { "Robot1" }),
|
|
|
new RouteInfo("424", new string[] { "Robot1" }),
|
|
|
- //new RouteInfo("624", new string[] { "Robot2" }),
|
|
|
- //new RouteInfo("633", new string[] { "Robot2" }),
|
|
|
- //new RouteInfo("642", new string[] { "Robot2" }),
|
|
|
+ new RouteInfo("624", new string[] { "Robot2" }),
|
|
|
+ new RouteInfo("633", new string[] { "Robot2" }),
|
|
|
+ new RouteInfo("642", new string[] { "Robot2" }),
|
|
|
//new RouteInfo("824", new string[] { "Robot3" }),
|
|
|
//new RouteInfo("833", new string[] { "Robot3" }),
|
|
|
//new RouteInfo("842", new string[] { "Robot3" }),
|
|
@@ -1029,7 +1182,6 @@ namespace WCS.WorkEngineering
|
|
|
}
|
|
|
//Parallel.ForEach(routeInfos, routeInfo =>
|
|
|
//{
|
|
|
-
|
|
|
//});
|
|
|
|
|
|
#endregion 配置路径信息
|
|
@@ -1042,10 +1194,10 @@ namespace WCS.WorkEngineering
|
|
|
new("424",new List<string> {"424","425"}),
|
|
|
new("433",new List<string> {"433","434"}),
|
|
|
new("442",new List<string> {"442","443"}),
|
|
|
- ////环形库一南侧侧机械手取货位
|
|
|
- //new("642",new List<string> {"642","643"}),
|
|
|
- //new("633",new List<string> {"633","634"}),
|
|
|
- //new("624",new List<string> {"624","625"}),
|
|
|
+ //环形库一南侧侧机械手取货位
|
|
|
+ new("642",new List<string> {"642","643"}),
|
|
|
+ new("633",new List<string> {"633","634"}),
|
|
|
+ new("624",new List<string> {"624","625"}),
|
|
|
////环形库二北侧机械手取货位
|
|
|
//new("824",new List<string> {"824","825"}),
|
|
|
//new("833",new List<string> {"833","834"}),
|
|
@@ -1082,20 +1234,20 @@ namespace WCS.WorkEngineering
|
|
|
{ DeviceFlags.一楼叠盘机,new List<string>() { "2527", "2528", "2727", "2728"/*, "2927", "2928", "3127", "3128" , "3327", "3328", "3527", "3528"*/ } },
|
|
|
{ DeviceFlags.主线分流点,new List<string>() { "22","41","61"} },
|
|
|
{ DeviceFlags.满轮主线第一次扫码,new List<string>() { "1"} },
|
|
|
- { DeviceFlags.环形库分流点,new List<string>(){ "418"/*, "618", "818","1018","1218","1418"*/ } },
|
|
|
- { DeviceFlags.桁架分流点,new List<string>() { "455"/*, "655", "855","1055","1255","1455"*/ } },
|
|
|
- { DeviceFlags.桁架缓存放行点, new List<string>(){ "466", "480", "494", "508", "522", "536", "550", "564", "578", "591"/*, "666", "680", "694", "708", "722", "736", "750", "764", "778", "791", "866", "880", "894", "908", "922", "936", "950", "964", "978", "991" , "1066", "1080", "1094", "1108", "1122", "1136", "1150", "1164", "1178", "1191" , "1266", "1280", "1294", "1308", "1322", "1336", "1350", "1364", "1378", "1391" , "1466", "1480", "1494", "1408", "1422", "1436", "1450", "1464", "1478", "1591"*/ } },
|
|
|
- { DeviceFlags.桁架09缓存放行点, new List<string>(){ "466", "480", "494", "508", "522", "536"/*, "666", "680", "694", "708", "722", "736", "866", "880", "894", "908", "922", "936", "1066", "1080", "1094", "1108", "1122", "1136", "1266", "1280", "1294", "1308", "1322", "1336", "1466", "1480", "1494", "1408", "1422", "1436"*/ } },
|
|
|
- { DeviceFlags.桁架09异常缓存放行点, new List<string>(){ "591"/*, "791", "991" , "1191" , "1391" , "1591"*/ } },
|
|
|
+ { DeviceFlags.环形库分流点,new List<string>(){ "418", "618"/*, "818","1018","1218","1418"*/ } },
|
|
|
+ { DeviceFlags.桁架分流点,new List<string>() { "455", "655"/*, "855","1055","1255","1455"*/ } },
|
|
|
+ { DeviceFlags.桁架缓存放行点, new List<string>(){ "466", "480", "494", "508", "522", "536", "550", "564", "578", "591", "666", "680", "694", "708", "722", "736", "750", "764", "778", "791"/*, "866", "880", "894", "908", "922", "936", "950", "964", "978", "991" , "1066", "1080", "1094", "1108", "1122", "1136", "1150", "1164", "1178", "1191" , "1266", "1280", "1294", "1308", "1322", "1336", "1350", "1364", "1378", "1391" , "1466", "1480", "1494", "1408", "1422", "1436", "1450", "1464", "1478", "1591"*/ } },
|
|
|
+ { DeviceFlags.桁架09缓存放行点, new List<string>(){ "466", "480", "494", "508", "522", "536", "666", "680", "694", "708", "722", "736"/*, "866", "880", "894", "908", "922", "936", "1066", "1080", "1094", "1108", "1122", "1136", "1266", "1280", "1294", "1308", "1322", "1336", "1466", "1480", "1494", "1408", "1422", "1436"*/ } },
|
|
|
+ { DeviceFlags.桁架09异常缓存放行点, new List<string>(){ "591", "791"/*, "991" , "1191" , "1391" , "1591"*/ } },
|
|
|
{ DeviceFlags.桁架18缓存放行点, new List<string>(){ "550", "564", "578", "750", "764", "778"/*, "950", "964", "978" , "1150", "1164", "1178" , "1350", "1364", "1378" , "1450", "1464", "1478"*/ } },
|
|
|
- { DeviceFlags.桁架取货点, new List<string>(){ "461", "475", "489", "503", "517", "531", "545", "559", "573", "586"/*, "661", "675", "689", "703", "717", "731", "745", "759", "773", "786", "861", "875", "889", "903", "917", "931", "945", "959", "973", "986", "1061", "1075", "1089", "1103", "1117", "1131", "1145", "1159", "1173", "1186", "1261", "1275", "1289", "1303", "1317", "1331", "1345", "1359", "1373", "1386" , "1461", "1475", "1489", "1503", "1517", "1531", "1545", "1559", "1573", "1586"*/ } },
|
|
|
+ { DeviceFlags.桁架取货点, new List<string>(){ "461", "475", "489", "503", "517", "531", "545", "559", "573", "586", "661", "675", "689", "703", "717", "731", "745", "759", "773", "786"/*, "861", "875", "889", "903", "917", "931", "945", "959", "973", "986", "1061", "1075", "1089", "1103", "1117", "1131", "1145", "1159", "1173", "1186", "1261", "1275", "1289", "1303", "1317", "1331", "1345", "1359", "1373", "1386" , "1461", "1475", "1489", "1503", "1517", "1531", "1545", "1559", "1573", "1586"*/ } },
|
|
|
//{ DeviceFlags.拆盘机09, new List<string>(){ /*"1606", "1616",*/"1626","1636","1646","1656" } },
|
|
|
{ DeviceFlags.拆盘机, new List<string>(){ "1602", "1612"/*, "1622","1632","1642","1652"*/ } },
|
|
|
{ DeviceFlags.桁架码垛位, new List<string>(){ "1670", "1671", "1672", "1673"/*, "1674", "1675"*/,"1664","1662","1663","1665","1677","1678","1679","1680","1685","1686","1687","1688","1689"/*,"1690", "1692", "1693", "1694", "1695", "1700", "1701", "1702", "1703", "1704", "1705", "1707", "1708", "1709", "1710", "1715", "1716", "1717", "1718", "1719", "1720", "1722", "1723", "1724", "1725", "1730", "1731", "1732", "1733", "1734", "1735", "1737", "1738", "1739", "1740", "1745", "1746", "1747", "1748", "1749", "1750"*/ } },
|
|
|
- { DeviceFlags.环形库码垛工位, new List<string>(){ "1666", "1661"/*, "1676", "1681", "1691", "1696", "1706", "1711", "1721", "1726", "1736", "1741"*/ } },
|
|
|
- { DeviceFlags.AGV取货站台口, new List<string>(){ "2533", "2534"/*, "2734","2733","2934","2933","3133","3134","3333","3334","3533","3534" */} },
|
|
|
- { DeviceFlags.Robot, new List<string>(){ "Robot1"/*, "Robot2", "Robot3","Robot4" , "Robot5", "Robot6"*/ } },
|
|
|
- {DeviceFlags.二次码垛RGV取货口, new List<string>(){ "1606"/*, "1616", "1626","1636","1646","1656"*/}}
|
|
|
+ { DeviceFlags.环形库码垛工位, new List<string>(){ "1666", "1661", "1676", "1681"/*, "1691", "1696", "1706", "1711", "1721", "1726", "1736", "1741"*/ } },
|
|
|
+ { DeviceFlags.AGV取货站台口, new List<string>(){ "2533", "2534", "2734", "2733"/*,"2934","2933","3133","3134","3333","3334","3533","3534" */} },
|
|
|
+ { DeviceFlags.Robot, new List<string>(){ "Robot1", "Robot2"/*, "Robot3","Robot4" , "Robot5", "Robot6"*/ } },
|
|
|
+ {DeviceFlags.二次码垛RGV取货口, new List<string>(){ "1606", "1616"/*, "1626","1636","1646","1656"*/}}
|
|
|
};
|
|
|
|
|
|
Parallel.ForEach(devices, device =>
|
|
@@ -1129,17 +1281,17 @@ namespace WCS.WorkEngineering
|
|
|
{
|
|
|
case "WCSDB"://WCS基本数据库
|
|
|
SqlSugarHelper.SetDefault(connectionString.Key);
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_PlcData));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_TaskInfo));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_TaskDtl));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_TaskOld));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_AgvTaskInfo));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_Palletizing));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_PalletizingLayer));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_PalletizingRow));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_PalletizingLoc));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_CacheLine));
|
|
|
- _db.CodeFirst.InitTables(typeof(WCS_CacheLineLoc));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_PlcData));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_TaskInfo));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_TaskDtl));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_TaskOld));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_AgvTaskInfo));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_Palletizing));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_PalletizingLayer));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_PalletizingRow));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_PalletizingLoc));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_CacheLine));
|
|
|
+ //_db.CodeFirst.InitTables(typeof(WCS_CacheLineLoc));
|
|
|
|
|
|
break;
|
|
|
|
|
@@ -1188,4 +1340,54 @@ namespace WCS.WorkEngineering
|
|
|
});
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ public class DevDbConfig<T>
|
|
|
+ {
|
|
|
+ public DevDbConfig()
|
|
|
+ {
|
|
|
+ }
|
|
|
+
|
|
|
+ public DevDbConfig(string ip, T code)
|
|
|
+ {
|
|
|
+ IP = ip;
|
|
|
+ Code = code;
|
|
|
+ }
|
|
|
+
|
|
|
+ public DevDbConfig(string ip, List<DevInterval<T>> devIntervalList)
|
|
|
+ {
|
|
|
+ IP = ip;
|
|
|
+ DevIntervalList = devIntervalList;
|
|
|
+ }
|
|
|
+
|
|
|
+ public DevDbConfig(string ip, List<T> devCodeList)
|
|
|
+ {
|
|
|
+ IP = ip;
|
|
|
+ DevCodeList = devCodeList;
|
|
|
+ }
|
|
|
+
|
|
|
+ public string IP { get; set; }
|
|
|
+
|
|
|
+ public T Code { get; set; }
|
|
|
+
|
|
|
+ public T StartCode { get; set; }
|
|
|
+
|
|
|
+ public T EndCode { get; set; }
|
|
|
+
|
|
|
+ public List<T> DevCodeList { get; set; }
|
|
|
+
|
|
|
+ public List<DevInterval<T>> DevIntervalList { get; set; }
|
|
|
+ }
|
|
|
+
|
|
|
+ public class DevInterval<T>
|
|
|
+ {
|
|
|
+ public DevInterval(T s, T e)
|
|
|
+ {
|
|
|
+ StartCode = s;
|
|
|
+ EndCode = e;
|
|
|
+ }
|
|
|
+
|
|
|
+ public T StartCode { get; set; }
|
|
|
+
|
|
|
+ public T EndCode { get; set; }
|
|
|
+ }
|
|
|
}
|