change-提升机节拍优化

master
liuwf 1 year ago
parent 6388ded0d1
commit 791c89883f

@ -739,14 +739,22 @@ namespace Khd.Core.Wcs.Wcs
StaticData.PlcDic[2].WriteToPoint(Ylc.Address, cardStatus.PosY.ToString(), Ylc.type); StaticData.PlcDic[2].WriteToPoint(Ylc.Address, cardStatus.PosY.ToString(), Ylc.type);
#region 经过走廊区域报警 #region 经过走廊区域报警
if (int.Parse(cardStatus.PosX) >= 53040 && int.Parse(cardStatus.PosX) <= 58090 && (int.Parse(cardStatus.PosY) >= 53520 && int.Parse(cardStatus.PosY) <= 64590)) var Agv3FLED = StaticData.BasePlcpointList.First(t => t.id == 76);
if(Agv3FLED != null)
{ {
Console.WriteLine("=======>3F走廊区域预警"); if (int.Parse(cardStatus.PosX) >= 53040 && int.Parse(cardStatus.PosX) <= 58090 && (int.Parse(cardStatus.PosY) >= 53520 && int.Parse(cardStatus.PosY) <= 64590))
} {
else // Console.WriteLine("=======>3F走廊区域预警");
{
// Console.WriteLine("3F走廊区域正常"); StaticData.PlcDic[0].WriteToPoint(Agv3FLED.plcpointAddress, true, Agv3FLED.plcpointLength.ToString());
}
else
{
// Console.WriteLine("3F走廊区域正常");
StaticData.PlcDic[0].WriteToPoint(Agv3FLED.plcpointAddress, false, Agv3FLED.plcpointLength.ToString());
}
} }
#endregion #endregion
} }
} }
@ -789,14 +797,22 @@ namespace Khd.Core.Wcs.Wcs
StaticData.PlcDic[2].WriteToPoint(Ylc.Address, cardStatus.PosY.ToString(), Ylc.type); StaticData.PlcDic[2].WriteToPoint(Ylc.Address, cardStatus.PosY.ToString(), Ylc.type);
#region 经过走廊区域报警 #region 经过走廊区域报警
if (int.Parse(cardStatus.PosX) >= 119000 && int.Parse(cardStatus.PosX) <= 122800 && (int.Parse(cardStatus.PosY) >= 124100 && int.Parse(cardStatus.PosY) <= 134435)) var Agv2FLED = StaticData.BasePlcpointList.First(t => t.id == 75);
if (Agv2FLED != null)
{ {
Console.WriteLine("=======>2F走廊区域预警"); if (int.Parse(cardStatus.PosX) >= 119000 && int.Parse(cardStatus.PosX) <= 122800 && (int.Parse(cardStatus.PosY) >= 124100 && int.Parse(cardStatus.PosY) <= 134435))
} {
else // Console.WriteLine("=======>2F走廊区域预警");
{
// Console.WriteLine("2F走廊区域正常"); StaticData.PlcDic[0].WriteToPoint(Agv2FLED.plcpointAddress, true, Agv2FLED.plcpointLength.ToString());
}
else
{
// Console.WriteLine("2F走廊区域正常");
StaticData.PlcDic[0].WriteToPoint(Agv2FLED.plcpointAddress, false, Agv2FLED.plcpointLength.ToString());
}
} }
#endregion #endregion
} }

@ -124,6 +124,7 @@ namespace Khd.Core.Wpf.Form
private void FormBoard_Loaded(object sender, RoutedEventArgs e) private void FormBoard_Loaded(object sender, RoutedEventArgs e)
{ {
InitializeData(1); InitializeData(1);
QueryPositionCombox.SelectedIndex = 0; // 设置默认选择为 "南侧" QueryPositionCombox.SelectedIndex = 0; // 设置默认选择为 "南侧"
try try
{ {
@ -253,6 +254,16 @@ namespace Khd.Core.Wpf.Form
Thread.Sleep(3000); Thread.Sleep(3000);
} }
}); });
try
{
GetPersonCallMaterialData();
}catch(Exception ex)
{
Console.WriteLine(ex.Message);
}
//加载dategrid信息 //加载dategrid信息
//LoadMaterial_GetMessage(""); //LoadMaterial_GetMessage("");
//连接PLC判断 //连接PLC判断
@ -1554,7 +1565,7 @@ namespace Khd.Core.Wpf.Form
if (selectedTabItem != null && selectedTabItem.Name == "CallPersonManager") if (selectedTabItem != null && selectedTabItem.Name == "CallPersonManager")
{ //人工叫料界面 { //人工叫料界面
CallSelectedItem.Clear(); CallSelectedItem.Clear();
await GetPersonCallMaterialData(); //await GetPersonCallMaterialData();
} }
else if (selectedTabItem != null && selectedTabItem.Name == "InventoryManager") else if (selectedTabItem != null && selectedTabItem.Name == "InventoryManager")
{ //盘库界面 { //盘库界面

Loading…
Cancel
Save