Commit 0e02f2f0 张东亮

1

1 个父辈 6f57bfb2
正在显示 52 个修改的文件 包含 2474 行增加1683 行删除
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
<HintPath>..\AgvClient\bin\Debug\AsaPL.AgvClient.dll</HintPath> <HintPath>..\AgvClient\bin\Debug\AsaPL.AgvClient.dll</HintPath>
</Reference> </Reference>
<Reference Include="log4net"> <Reference Include="log4net">
<HintPath>..\..\..\..\DLL\log4net.dll</HintPath> <HintPath>dll\log4net.dll</HintPath>
</Reference> </Reference>
<Reference Include="Newtonsoft.Json, Version=3.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL"> <Reference Include="Newtonsoft.Json, Version=3.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion> <SpecificVersion>False</SpecificVersion>
......
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
</layout> </layout>
</appender> </appender>
<logger> <logger>
<level value="Debug"/> <level value="ALL"/>
<appender-ref ref="LineWebService"/> <appender-ref ref="LineWebService"/>
</logger> </logger>
<root> <root>
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
<host> <host>
<baseAddresses> <baseAddresses>
<!--添加调用服务地址--> <!--添加调用服务地址-->
<add baseAddress="http://10.85.199.1/BenQMIR/Webservice/AGVService.asmx/"/> <add baseAddress="http://127.0.0.1/BenQMIR/Webservice/AGVService.asmx/"/>
</baseAddresses> </baseAddresses>
</host> </host>
......
...@@ -11,7 +11,88 @@ namespace BLL ...@@ -11,7 +11,88 @@ namespace BLL
{ {
public class AGVManager public class AGVManager
{ {
private static string Addr_CurSO = "/rest/api/qisda/device/currentOutLine";
/// <summary>
/// 查询当前出料工单信息
/// </summary>
/// <returns></returns>
public static bool FindCurSO(out WOData woData)
{
woData = null;
try
{
Dictionary<string, string> paramMap = new Dictionary<string, string>();
//paramMap.Add("deviceAlarmList", msgListStr);
string server = GetAddr(Addr_CurSO, paramMap);
DateTime startTime = DateTime.Now;
string resultStr = HttpHelper.Get(server);
Common.log.Debug("当前正在出工单料信息【" + server + "】【" + resultStr + "】");
WorkOrder workOrder = JsonHelper.DeserializeJsonToObject<WorkOrder>(resultStr);
if (workOrder == null)
{
return false;
}
else
{
if (workOrder.data == null)
{
return false;
}
else
{
if(workOrder.data.line !=null)
{
string tempLocation = workOrder.data.line;
if (workOrder.data.line.Equals("Feeder"))
{
tempLocation = "FeederIn";
}
else if (workOrder.data.line.Equals("4CFeeder"))
{
tempLocation = "4CFeederIn";
}
workOrder.data.line = tempLocation;
woData = workOrder.data;
return true;
}
}
}
}
catch (Exception ex)
{
Common.log.Error(ex);
return false;
}
return false;
}
/// <summary>
/// 当前正在出的工单信息
/// </summary>
public class WorkOrder
{
//{"code":0,"msg":"ok","data":{"hSerial":"32622","line":null,"so":"2506287"}}
//{"code":0,"msg":"ok","data":{"hSerial":"32651","line":"D2","so":"2508551"}}
public int code { get; set; }
public string msg { get; set; }
public WOData data { get; set; }
}
public class WOData
{
public string hSerial { get; set; }
public string line { get; set; }
public string so { get; set; }
public string ToTxt(string nodeName)
{
return string.Format("[hSerial={0},line={1}[{3}],so={2}]", hSerial,line,so,nodeName);
}
}
public static string A6_Target = ""; public static string A6_Target = "";
/// <summary> /// <summary>
/// 查找满料架目的地 /// 查找满料架目的地
...@@ -42,7 +123,7 @@ namespace BLL ...@@ -42,7 +123,7 @@ namespace BLL
//JavaScriptSerializer serializer = new JavaScriptSerializer(); //JavaScriptSerializer serializer = new JavaScriptSerializer();
if (res == null || res.Count == 0) if (res == null || res.Count == 0)
return false; return false;
string tempLocation = ""; string tempLocation = res[0].location;
if (res[0].id == rfid) if (res[0].id == rfid)
{ {
if (res[0].location.Equals("Feeder")) if (res[0].location.Equals("Feeder"))
...@@ -53,7 +134,8 @@ namespace BLL ...@@ -53,7 +134,8 @@ namespace BLL
{ {
tempLocation = "4CFeederIn"; tempLocation = "4CFeederIn";
} }
if (Common.GetNodeNameByLineName(tempLocation,out string loc))
if (Common.GetNodeNameByLineName(tempLocation, out string loc))
{ {
int i = Common.FindNode(loc); int i = Common.FindNode(loc);
if (i > -1) if (i > -1)
...@@ -84,8 +166,8 @@ namespace BLL ...@@ -84,8 +166,8 @@ namespace BLL
#endregion #endregion
res[0].location = loc; res[0].location = loc;
dest = res[0]; dest = res[0];
A6_Target = "获取周转箱目的地信息: " + url + " Return: " + json+"["+loc+"]"; A6_Target = res[0].ShowInfo() + "[" + loc + "]";
Common.LogInfo("收到满料架任务[RFID=" + rfid + "]:目的地为 " + loc + " [产线名 " + res[0].location + "]"); Common.log.Debug("查找满料架任务[RFID=" + rfid + "]:目的地为 " + loc + " [产线名 " + tempLocation + "]");
return true; return true;
} }
else else
...@@ -118,7 +200,7 @@ namespace BLL ...@@ -118,7 +200,7 @@ namespace BLL
public string ShowInfo() public string ShowInfo()
{ {
return string.Format("RFID={0},SO={1},location={2}",id,SO,location); return string.Format("RFID={0},SO={1},location={2}", id, SO, location);
} }
} }
...@@ -129,10 +211,12 @@ namespace BLL ...@@ -129,10 +211,12 @@ namespace BLL
/// <param name="rfid"></param> /// <param name="rfid"></param>
/// <param name="lineName"></param> /// <param name="lineName"></param>
/// <returns></returns> /// <returns></returns>
public static bool UpdateStatus(string rfid, string lineName) public static bool UpdateStatus(string rfid, string nodeName)
{ {
//GET /ESMTCommonInterface/CommonService.asmx/UpdateStatusBy?id=string&location=string HTTP/1.1 //GET /ESMTCommonInterface/CommonService.asmx/UpdateStatusBy?id=string&location=string HTTP/1.1
//Host: 10.85.17.233 //Host: 10.85.17.233
Common.GetLineNameByNodeName(nodeName, out string lineName);
if (lineName.Equals("FeederIn")) if (lineName.Equals("FeederIn"))
{ {
lineName = "Feeder"; lineName = "Feeder";
...@@ -226,7 +310,7 @@ namespace BLL ...@@ -226,7 +310,7 @@ namespace BLL
List<Msg> msgs = JsonHelper.DeserializeJsonToList<Msg>(result); List<Msg> msgs = JsonHelper.DeserializeJsonToList<Msg>(result);
if (msgs == null || msgs.Count == 0) if (msgs == null || msgs.Count == 0)
return ""; return "";
return string.Format("[{0}] [{1}]", addr, result); return result;
} }
} }
...@@ -328,7 +412,7 @@ namespace BLL ...@@ -328,7 +412,7 @@ namespace BLL
return data.Succeed.ToString(); return data.Succeed.ToString();
} }
} }
catch(Exception e) catch (Exception e)
{ {
return e.ToString(); return e.ToString();
} }
......
...@@ -479,11 +479,12 @@ namespace BLL ...@@ -479,11 +479,12 @@ namespace BLL
eNodeStatus action = (eNodeStatus)buff[idx++]; eNodeStatus action = (eNodeStatus)buff[idx++];
idx += 1; ClientLevel level = (ClientLevel)buff[idx++];
idx += 4; //预留 idx += 4; //预留
if (buff[idx] != 0xDA) return null; if (buff[idx] != 0xDA) return null;
ClientNode node = new ClientNode(name, rfid, action); ClientNode node = new ClientNode(name, rfid, action);
node.ClientLevel = level;
return node; return node;
} }
...@@ -503,12 +504,13 @@ namespace BLL ...@@ -503,12 +504,13 @@ namespace BLL
} }
if (!Common.nodeInfo[idx].StateEquals(node.GetState()) || if (!Common.nodeInfo[idx].StateEquals(node.GetState()) ||
Common.nodeInfo[idx].RFID != node.RFID) Common.nodeInfo[idx].RFID != node.RFID || Common.nodeInfo[idx].ClientLevel != node.ClientLevel)
{ {
Common.nodeInfo[idx].UpdateNodeStatus(node.GetState()); Common.nodeInfo[idx].UpdateNodeStatus(node.GetState());
Common.nodeInfo[idx].ClientLevel = node.ClientLevel;
Common.nodeInfo[idx].RFID = node.RFID; Common.nodeInfo[idx].RFID = node.RFID;
Common.LogInfo("节点更新 " + node.StatetText()); Common.LogInfo("节点更新 " + node.StatetText()+" "+ node.ClientLevel.ToString());
NodeChanged?.Invoke(idx); NodeChanged?.Invoke(idx);
} }
} }
......
...@@ -7,6 +7,7 @@ using System.Net; ...@@ -7,6 +7,7 @@ using System.Net;
using System.Net.Sockets; using System.Net.Sockets;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using System.Threading; using System.Threading;
using System.Web.UI.WebControls;
using System.Windows.Forms; using System.Windows.Forms;
namespace AGVControl namespace AGVControl
...@@ -18,17 +19,25 @@ namespace AGVControl ...@@ -18,17 +19,25 @@ namespace AGVControl
{ {
public const int AGVCNT = 6; public const int AGVCNT = 6;
public const string Move = "Move"; public const string Move = "Move";
public const string MoveStandby = "MoveStandby"; //任务名称
public const string Standby = "Standby";
public const string CheckShelf = "CheckShelf"; public const string CheckShelf = "CheckShelf";
public const string MoveDoorDToC = "MoveDoorDToC"; public const string DoorDToC = "DoorDToC";
public const string MoveDoorCToD = "MoveDoorCToD"; public const string DoorCToD = "DoorCToD";
public const string DoubleLine_Name_Prefix = "A";
public const string Wait = "Wait";
public const string Done = "Done";
public const string AutoCharge = "AutoCharge";
public const string Executing = "Executing";
public const string C4_DOOR_Name = "F1"; public const string C4_DOOR_Name = "F1";
public const string D4_DOOR_Name = "F2"; public const string D4_DOOR_Name = "F2";
public const string Standby_Name_Prefix = ""; public const string Standby_Name_Prefix = "H";
public const string Charge_Name_Prefix = "I"; public const string Charge_Name_Prefix = "I";
public const string RandomCharge_IP1 = "10.85.199.80"; public const string RandomCharge_IP1 = "10.85.199.80";
public const string RandomCharge_IP2 = "10.85.199.81"; public const string RandomCharge_IP2 = "10.85.199.81";
public const string FileName_AGV= "AgvName.csv"; public const string RandomCharge_IP3 = "10.85.199.71";
public const string RandomCharge_IP4 = "10.85.199.72";
public const string FileName_AGV = "AgvName.csv";
public const string FileName_AgvMission = "AgvMission.csv"; public const string FileName_AgvMission = "AgvMission.csv";
public const string FileName_AgvProductionLine = "AgvProductionLine.csv"; public const string FileName_AgvProductionLine = "AgvProductionLine.csv";
public const string FileName_tempData = "tempData.ini"; public const string FileName_tempData = "tempData.ini";
...@@ -38,7 +47,8 @@ namespace AGVControl ...@@ -38,7 +47,8 @@ namespace AGVControl
/// <summary> /// <summary>
/// 去4C的3辆车IP /// 去4C的3辆车IP
/// </summary> /// </summary>
public const string C4_AGV_IPs = "10.85.199.80,10.85.199.81,10.85.199.71"; public const string C4_AGV_IPs = "10.85.199.71,10.85.199.72,10.85.199.73";
/// <summary> /// <summary>
/// 上料区 /// 上料区
/// </summary> /// </summary>
...@@ -208,22 +218,37 @@ namespace AGVControl ...@@ -208,22 +218,37 @@ namespace AGVControl
public static readonly string CONFIG_PATH = AppDomain.CurrentDomain.BaseDirectory + "Config\\"; public static readonly string CONFIG_PATH = AppDomain.CurrentDomain.BaseDirectory + "Config\\";
public static string ReadIni(string section,string key) public static string ReadIni(string section, string key)
{ {
return IniHelper.ReadValue(section,key,CONFIG_PATH+SettingString.FileName_tempData); return IniHelper.ReadValue(section, key, CONFIG_PATH + SettingString.FileName_tempData);
} }
public static void WriteIni(string section, string key,string value) public static void WriteIni(string section, string key, string value)
{ {
IniHelper.WriteValue(section, key,value, CONFIG_PATH + SettingString.FileName_tempData); IniHelper.WriteValue(section, key, value, CONFIG_PATH + SettingString.FileName_tempData);
} }
public static bool GetNodeNameByLineName(string lineName,out string nodeName) public static bool GetNodeNameByLineName(string lineName, out string nodeName)
{ {
nodeName = ""; nodeName = "";
int id = nodeInfo.FindIndex(s=>s.LineName.Equals(lineName)); int id = nodeInfo.FindIndex(s => s.LineName.Equals(lineName));
if(id>-1) if (id > -1)
{
nodeName = nodeInfo[id].Name;
return true;
}
else
{
return false;
}
}
public static bool GetLineNameByNodeName(string nodeName, out string lineName)
{
lineName = "";
int id = nodeInfo.FindIndex(s => s.Name.Equals(nodeName));
if (id > -1)
{ {
nodeName=nodeInfo[id].Name; lineName = nodeInfo[id].LineName;
return true; return true;
} }
else else
...@@ -251,8 +276,8 @@ namespace AGVControl ...@@ -251,8 +276,8 @@ namespace AGVControl
public static bool MoveToNode(Agv_Info agv, string nodeName) public static bool MoveToNode(Agv_Info agv, string nodeName)
{ {
string log; string log;
if (!agv.TaskSend.Equals("")) //if (!agv.TaskSend.Equals(""))
return false; // return false;
//清除当前任务点 //清除当前任务点
int idx = Common.nodeInfo.FindIndex(s => s.AgvName == agv.Name); int idx = Common.nodeInfo.FindIndex(s => s.AgvName == agv.Name);
...@@ -287,123 +312,224 @@ namespace AGVControl ...@@ -287,123 +312,224 @@ namespace AGVControl
} }
/// <summary> /// <summary>
/// 查看A5、A6需要料架的状况 /// 查看A5、A6需要料架的状况
/// </summary> /// </summary>
/// <param name="agv"></param> /// <param name="agv"></param>
/// <param name="node"></param> /// <param name="node"></param>
public static bool CheckA5A6State(Agv_Info agv, eShelfType shelfType, out string tarNodeName) public static bool CheckA5A6State(Agv_Info agv, eShelfType shelfType, out string nodeName)
{ {
bool rtn = false; bool rtn = false;
string place = agv.Place; string place = agv.Place;
tarNodeName = ""; nodeName = "";
if (shelfType.Equals(eShelfType.SmallShelf)) if (shelfType.Equals(eShelfType.SmallShelf))
{ {
int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A5 int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A5
&& (s.StateEquals(eNodeStatus.NeedD) || s.StateEquals(eNodeStatus.NeedEnter)) && s.AgvName == "" && s.IsUse); && (s.StateEquals(eNodeStatus.NeedD) || s.StateEquals(eNodeStatus.NeedEnter)) && s.IsUse);
if (tarIdx == -1) if (tarIdx == -1)
{ {
Common.LogInfo(string.Format("{0} 已装载小料架,{1}不需要料架", agv.Name, SettingString.A5), false); Common.log.Debug(string.Format("{0} {1}不需要小料架", agv.Name, SettingString.A5));
} }
else else
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + SettingString.A5]); nodeName = SettingString.A5;
if (rtn) Common.log.Debug(string.Format("{0} {1}需要小料架", agv.Name, SettingString.A5));
{
agv.NextPlace = "";
tarNodeName = SettingString.A5;
Common.nodeInfo[tarIdx].AgvName = agv.Name;
agv.TaskSend = rtn ? SettingString.Move + SettingString.A5 : "";
agv.Msg = string.Format("{0} 在{1}已装小载料架,送往{2}", agv.Name, place, SettingString.A5);
Common.LogInfo(string.Format("{0} 在{1}已装小载料架,送往{2}", agv.Name, place, SettingString.A5));
}
return true; return true;
} }
tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A6 && tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A6 &&
(s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.AgvName == "" && s.IsUse); (s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.IsUse);
if (tarIdx == -1) if (tarIdx == -1)
{ {
//StatusCharge(agv); Common.log.Debug(string.Format("{0} {1}不需要小料架", agv.Name, SettingString.A6));
//Common.LogInfo(string.Format("{0} 已装载小料架,A6不需要料架,到待机位等待", agv.Name), false);//小 //rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.MoveStandby]);
//if (rtn)
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.MoveStandby]); //{
if (rtn) // agv.NextPlace = "";
{ // agv.TaskSend = rtn ? SettingString.MoveStandby : "";
agv.NextPlace = ""; // agv.Msg = string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.MoveStandby);
agv.TaskSend = rtn ? SettingString.MoveStandby : ""; // Common.LogInfo(string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.MoveStandby));
agv.Msg = string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.MoveStandby); //}
Common.LogInfo(string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.MoveStandby));
}
} }
else else
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + SettingString.A6]); nodeName = SettingString.A6;
if (rtn) Common.log.Debug(string.Format("{0} {1}需要小料架", agv.Name, SettingString.A6));
{
agv.NextPlace = "";
tarNodeName = SettingString.A6;
Common.nodeInfo[tarIdx].AgvName = agv.Name;
agv.TaskSend = rtn ? SettingString.Move + SettingString.A6 : "";
agv.Msg = string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.A6);
Common.LogInfo(string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.A6));
return true; return true;
} //rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + SettingString.A6]);
//if (rtn)
//{
// agv.NextPlace = "";
// tarNodeName = SettingString.A6;
// Common.nodeInfo[tarIdx].AgvName = agv.Name;
// agv.TaskSend = rtn ? SettingString.Move + SettingString.A6 : "";
// agv.Msg = string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.A6);
// Common.LogInfo(string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.A6));
// return true;
//}
} }
} }
else if (shelfType.Equals(eShelfType.BigShelf)) else if (shelfType.Equals(eShelfType.BigShelf))
{ {
int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A5 int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A5
&& (s.StateEquals(eNodeStatus.NeedC) || s.StateEquals(eNodeStatus.NeedEnter)) && s.AgvName == "" && s.IsUse); && (s.StateEquals(eNodeStatus.NeedC) || s.StateEquals(eNodeStatus.NeedEnter)) && s.IsUse);
if (tarIdx == -1) if (tarIdx == -1)
{ {
Common.LogInfo(string.Format("{0} 已装载大料架,{1}不需要料架", agv.Name, SettingString.A5), false); Common.log.Debug(string.Format("{0} {1}不需要大料架", agv.Name, SettingString.A5));
} }
else else
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + SettingString.A5]); nodeName = SettingString.A5;
if (rtn) Common.log.Debug(string.Format("{0} {1}需要大料架", agv.Name, SettingString.A5));
{
agv.NextPlace = "";
tarNodeName = SettingString.A5;
Common.nodeInfo[tarIdx].AgvName = agv.Name;
agv.TaskSend = rtn ? SettingString.Move + SettingString.A5 : "";
agv.Msg = string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.A5);
Common.LogInfo(string.Format("{0} 在{1}已装载料架,送往{2}", agv.Name, place, SettingString.A5));
}
return true; return true;
} }
tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A6 && tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A6 &&
(s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.AgvName == "" && s.IsUse); (s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.IsUse);
if (tarIdx == -1) if (tarIdx == -1)
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.MoveStandby]); Common.log.Debug(string.Format("{0} {1}不需要大料架", agv.Name, SettingString.A6));
if (rtn) //rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.MoveStandby]);
//if (rtn)
//{
// agv.NextPlace = "";
// agv.TaskSend = rtn ? SettingString.MoveStandby : "";
// agv.Msg = string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.MoveStandby);
// Common.LogInfo(string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.MoveStandby));
//}
}
else
{ {
agv.NextPlace = ""; nodeName = SettingString.A6;
agv.TaskSend = rtn ? SettingString.MoveStandby : ""; Common.log.Debug(string.Format("{0} {1}需要大料架", agv.Name, SettingString.A6));
agv.Msg = string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.MoveStandby); return true;
Common.LogInfo(string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.MoveStandby)); //rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + SettingString.A6]);
//if (rtn)
//{
// agv.NextPlace = "";
// tarNodeName = SettingString.A6;
// Common.nodeInfo[tarIdx].AgvName = agv.Name;
// agv.TaskSend = rtn ? SettingString.Move + SettingString.A6 : "";
// agv.Msg = string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.A6);
// Common.LogInfo(string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.A6));
// return true;
//}
} }
} }
else
return false;
}
/// <summary>
/// 查看A5料架的状况(A5当前料架小于2个)
/// </summary>
/// <param name="agv"></param>
/// <param name="node"></param>
public static bool CheckA5State(Agv_Info agv, eShelfType shelfType, out string nodeName)
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + SettingString.A6]); bool rtn = false;
if (rtn) string place = agv.Place;
nodeName = "";
if (shelfType.Equals(eShelfType.SmallShelf))
{
int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A5 && s.ClientLevel.Equals(ClientLevel.High)
&& (s.StateEquals(eNodeStatus.NeedD) || s.StateEquals(eNodeStatus.NeedEnter)) && s.IsUse);
if (tarIdx == -1)
{ {
agv.NextPlace = ""; Common.log.Debug(string.Format("{0} {1}不需要小料架", agv.Name, SettingString.A5));
tarNodeName = SettingString.A6; }
Common.nodeInfo[tarIdx].AgvName = agv.Name; else
agv.TaskSend = rtn ? SettingString.Move + SettingString.A6 : ""; {
agv.Msg = string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.A6); nodeName = SettingString.A5;
Common.LogInfo(string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.A6)); Common.log.Debug(string.Format("{0} {1}需要小料架", agv.Name, SettingString.A5));
return true; return true;
} }
//tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A6 &&
//(s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.IsUse);
//if (tarIdx == -1)
//{
// Common.LogInfo(string.Format("{0} {1}不需要小料架", agv.Name, SettingString.A6));
// //rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.MoveStandby]);
// //if (rtn)
// //{
// // agv.NextPlace = "";
// // agv.TaskSend = rtn ? SettingString.MoveStandby : "";
// // agv.Msg = string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.MoveStandby);
// // Common.LogInfo(string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.MoveStandby));
// //}
//}
//else
//{
// nodeName = SettingString.A6;
// Common.LogInfo(string.Format("{0} {1}需要小料架", agv.Name, SettingString.A6));
// return true;
// //rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + SettingString.A6]);
// //if (rtn)
// //{
// // agv.NextPlace = "";
// // tarNodeName = SettingString.A6;
// // Common.nodeInfo[tarIdx].AgvName = agv.Name;
// // agv.TaskSend = rtn ? SettingString.Move + SettingString.A6 : "";
// // agv.Msg = string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.A6);
// // Common.LogInfo(string.Format("{0} 在{1}已装载小料架,送往{2}", agv.Name, place, SettingString.A6));
// // return true;
// //}
//}
}
else if (shelfType.Equals(eShelfType.BigShelf))
{
int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A5
&& (s.StateEquals(eNodeStatus.NeedC) || s.StateEquals(eNodeStatus.NeedEnter)) && s.IsUse);
if (tarIdx == -1)
{
Common.log.Debug(string.Format("{0} {1}不需要大料架", agv.Name, SettingString.A5));
} }
else
{
nodeName = SettingString.A5;
Common.log.Debug(string.Format("{0} {1}需要大料架", agv.Name, SettingString.A5));
return true;
}
//tarIdx = Common.nodeInfo.FindIndex(s => s.Name == SettingString.A6 &&
//(s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.IsUse);
//if (tarIdx == -1)
//{
// Common.LogInfo(string.Format("{0} {1}不需要大料架", agv.Name, SettingString.A6));
// //rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.MoveStandby]);
// //if (rtn)
// //{
// // agv.NextPlace = "";
// // agv.TaskSend = rtn ? SettingString.MoveStandby : "";
// // agv.Msg = string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.MoveStandby);
// // Common.LogInfo(string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.MoveStandby));
// //}
//}
//else
//{
// nodeName = SettingString.A6;
// Common.LogInfo(string.Format("{0} {1}需要大料架", agv.Name, SettingString.A6));
// return true;
// //rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + SettingString.A6]);
// //if (rtn)
// //{
// // agv.NextPlace = "";
// // tarNodeName = SettingString.A6;
// // Common.nodeInfo[tarIdx].AgvName = agv.Name;
// // agv.TaskSend = rtn ? SettingString.Move + SettingString.A6 : "";
// // agv.Msg = string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.A6);
// // Common.LogInfo(string.Format("{0} 在{1}已装载大料架,送往{2}", agv.Name, place, SettingString.A6));
// // return true;
// //}
//}
} }
return false; return false;
...@@ -418,18 +544,41 @@ namespace AGVControl ...@@ -418,18 +544,41 @@ namespace AGVControl
return Common.mir.Add_Mission_Fleet(agv, Common.agvMission["CheckShelf"]); return Common.mir.Add_Mission_Fleet(agv, Common.agvMission["CheckShelf"]);
} }
public static bool DoorMission(Agv_Info agv, string missionName) public static bool DoorMission(Agv_Info agv, string doorName)
{ {
return Common.mir.Add_Mission_Fleet(agv, Common.agvMission[missionName]); return Common.mir.Add_Mission_Fleet(agv, Common.agvMission[SettingString.Move + doorName]);
} }
/// <summary> /// <summary>
/// 检查当前任务是否结束
/// </summary>
/// <param name="taskName">任务名称</param>
/// <param name="taskGUID">任务GUID</param>
/// <returns></returns>
public static bool CheckTaskFinished(Agv_Info agv, string nodeName, string taskGUID)
{
log.Debug(agv.Name + " 检查当前任务是否结束: " + SettingString.Move + nodeName + " " + agv.CurTaskState + " " + taskGUID);
return Common.agvMission[SettingString.Move + nodeName].Equals(taskGUID) && agv.CurTaskState.Equals(SettingString.Done);
}
/// <summary>
/// 检查充电任务是否完成
/// </summary>
/// <param name="taskName"></param>
/// <returns></returns>
public static bool CheckTaskFinished(Agv_Info agv, string taskName)
{
return taskName.Contains(SettingString.AutoCharge) && agv.CurTaskState.Equals(SettingString.Executing);
}
//双层线工单信息
public static string doubleLine_WO = "[hSerial={0},line={1}[{3}],so={2}]";
/// <summary>
/// 查找空架任务 /// 查找空架任务
/// </summary> /// </summary>
/// <param name="curPlace">为空表示待机位</param> /// <param name="curPlace">为空表示待机位</param>
/// <param name="nodeName">出空料架的节点名</param> /// <param name="nodeName">出空料架的节点名</param>
/// <param name="emptyAGVbACK">agv空车返回,带一个料架</param>
/// <returns></returns> /// <returns></returns>
public static bool FindEmptyShelfNode(Agv_Info agv, out string nodeName) public static bool FindEmptyShelfNode(Agv_Info agv, out string nodeName, bool emptyAGVbACK = false)
{ {
nodeName = ""; nodeName = "";
...@@ -469,38 +618,107 @@ namespace AGVControl ...@@ -469,38 +618,107 @@ namespace AGVControl
} }
} }
//查询双层线正在出的工单料
if (AGVManager.FindCurSO(out AGVManager.WOData woData))
{
if (Common.GetNodeNameByLineName(woData.line, out string loc))
{
nodeName = loc;
doubleLine_WO = "工单料信息:" + woData.ToTxt(loc);
Common.log.Debug(doubleLine_WO);
idx = nodeInfo.FindIndex(s => s.Name.Equals(loc) && s.EmptyShelfCnt > 0);
if (idx > -1)
{
if (loc.StartsWith("G") && SettingString.C4_AGV_IPs.Contains(agv.IP))
{
nodeName = loc;
Common.LogInfo("双层线正在出的工单目标产线有空料架,优先处理 " + loc);
return true;
}
else if (loc.StartsWith("E") && !SettingString.C4_AGV_IPs.Contains(agv.IP))
{
nodeName = loc;
Common.LogInfo("双层线正在出的工单目标产线有空料架,优先处理 " + loc);
return true;
}
}
}
}
///AGV出满料带回一个料架
if (emptyAGVbACK)
{
//双层线是否需要小料架 //双层线是否需要小料架
if (CheckA5A6State(agv, eShelfType.SmallShelf, out string lineName)) if (CheckA5A6State(agv, eShelfType.SmallShelf, out string lineNodeName))
{ {
//if (curPlace.Equals(""))//待机位 //if (curPlace.Equals(""))//待机位
// { // {
//4C车间寻找 //4C车间寻找
if (SettingString.C4_AGV_IPs.Contains(agv.IP)) if (SettingString.C4_AGV_IPs.Contains(agv.IP))
{ {
string nearNodeName = CalculateNearNode(agv,"G"); string nearNodeName = CalculateNearNode(agv, "G");
if (nearNodeName.Equals("")) if (nearNodeName.Equals(""))
{ {
return false; return false;
} }
nodeName = lineName; nodeName = nearNodeName;
Common.LogInfo(agv.Name+ " 双层线需要小料架,小车在待机位,去" + nodeName); Common.LogInfo(agv.Name + " 双层线需要小料架,去4C-" + nearNodeName);
return true; return true;
} }
//4D车间寻找 //4D车间寻找
if ( !SettingString.C4_AGV_IPs.Contains(agv.IP)) if (!SettingString.C4_AGV_IPs.Contains(agv.IP))
{ {
string nearNodeName = CalculateNearNode(agv,"E"); string nearNodeName = CalculateNearNode(agv, "E");
if (nearNodeName.Equals("")) if (nearNodeName.Equals(""))
{ {
return false; return false;
} }
nodeName = lineName; nodeName = nearNodeName;
Common.LogInfo(agv.Name + " 双层线需要小料架,小车在待机位,去" + nodeName); Common.LogInfo(agv.Name + " 双层线需要小料架,去4D-" + nearNodeName);
return true; return true;
} }
} }
}
else//主动拉料架
{
//双层线是否需要小料架
if (CheckA5State(agv, eShelfType.SmallShelf, out string lineNodeName))
{
//if (curPlace.Equals(""))//待机位
// {
//4C车间寻找
if (SettingString.C4_AGV_IPs.Contains(agv.IP))
{
string nearNodeName = CalculateNearNode(agv, "G");
if (nearNodeName.Equals(""))
{
return false;
}
nodeName = nearNodeName;
Common.LogInfo(agv.Name + " 双层线需要小料架,去4C-" + nearNodeName);
return true;
}
//4D车间寻找
if (!SettingString.C4_AGV_IPs.Contains(agv.IP))
{
string nearNodeName = CalculateNearNode(agv, "E");
if (nearNodeName.Equals(""))
{
return false;
}
nodeName = nearNodeName;
Common.LogInfo(agv.Name + " 双层线需要小料架,去4D-" + nearNodeName);
return true;
}
}
}
return false; return false;
} }
...@@ -521,10 +739,15 @@ namespace AGVControl ...@@ -521,10 +739,15 @@ namespace AGVControl
{ {
if (FullShelfDestInfo.location.StartsWith("G") && SettingString.C4_AGV_IPs.Contains(agv.IP)) if (FullShelfDestInfo.location.StartsWith("G") && SettingString.C4_AGV_IPs.Contains(agv.IP))
{ {
int i = Common.agvInfo.FindIndex(s => s.CurJob is GoFullShelfStationJob && !s.IP.Equals(agv.IP));
if (i == -1)
return true; return true;
} }
else if (FullShelfDestInfo.location.StartsWith("E") && !SettingString.C4_AGV_IPs.Contains(agv.IP)) else if (FullShelfDestInfo.location.StartsWith("E") && !SettingString.C4_AGV_IPs.Contains(agv.IP))
{ {
int i = Common.agvInfo.FindIndex(s => s.CurJob is GoFullShelfStationJob && !s.IP.Equals(agv.IP));
if (i ==-1)
return true; return true;
} }
} }
...@@ -548,13 +771,13 @@ namespace AGVControl ...@@ -548,13 +771,13 @@ namespace AGVControl
{ {
nodeName = ""; nodeName = "";
int idx = nodeInfo.FindIndex(s => s.Name.Equals(SettingString.A6) int idx = nodeInfo.FindIndex(s => s.Name.Equals(SettingString.A6)
&& (s.StateEquals(eNodeStatus.NeedEnterLeave) || (s.StateEquals(eNodeStatus.NeedLeave))) && !s.RFID.Equals("")); && (s.StateEquals(eNodeStatus.NeedEnterLeave) || (s.StateEquals(eNodeStatus.NeedLeave))) && !s.RFID.Equals("") && s.IsUse);
if (idx > -1) if (idx > -1)
{ {
if (AGVManager.FindFullShelfTarget(Common.nodeInfo[idx].RFID, out AGVManager.BoxDestInfo FullShelfDestInfo)) if (AGVManager.FindFullShelfTarget(Common.nodeInfo[idx].RFID, out AGVManager.BoxDestInfo FullShelfDestInfo))
{ {
idx = nodeInfo.FindIndex(s=>s.Name.Equals(FullShelfDestInfo.location) && s.EmptyShelfCnt>0); idx = nodeInfo.FindIndex(s => s.Name.Equals(FullShelfDestInfo.location) && s.EmptyShelfCnt > 0 && s.IsUse);
if(idx>-1) if (idx > -1)
{ {
nodeName = FullShelfDestInfo.location; nodeName = FullShelfDestInfo.location;
Common.LogInfo("A6出满料架的产线有空料架,优先处理 " + FullShelfDestInfo.ShowInfo()); Common.LogInfo("A6出满料架的产线有空料架,优先处理 " + FullShelfDestInfo.ShowInfo());
...@@ -577,11 +800,11 @@ namespace AGVControl ...@@ -577,11 +800,11 @@ namespace AGVControl
/// </summary> /// </summary>
/// <param name="agv"></param> /// <param name="agv"></param>
/// <returns>节点名称</returns> /// <returns>节点名称</returns>
private static string CalculateNearNode(Agv_Info agv,string RoomProfix) public static string CalculateNearNode(Agv_Info agv, string RoomProfix)
{ {
double minDis = Double.MaxValue; double minDis = Double.MaxValue;
string nodeName = ""; string nodeName = "";
List<ClientNode> clientNodes = nodeInfo.FindAll(s => s.EmptyShelfCnt > 0 && s.Name.Substring(0,1).Equals(RoomProfix) && s.AgvName == "" && s.IsUse); List<ClientNode> clientNodes = nodeInfo.FindAll(s => s.EmptyShelfCnt > 0 && s.Name.Substring(0, 1).Equals(RoomProfix) && s.IsUse);
try try
{ {
if (clientNodes.Count.Equals(0)) if (clientNodes.Count.Equals(0))
...@@ -597,7 +820,7 @@ namespace AGVControl ...@@ -597,7 +820,7 @@ namespace AGVControl
} }
} }
Common.log.Debug(string.Format("{0} 运动到产线 {1}", agv.Name, nodeName)); Common.log.Debug(string.Format("{0} 准备运动到产线 {1} 回收空料架", agv.Name, nodeName));
return nodeName; return nodeName;
} }
catch (Exception e) catch (Exception e)
...@@ -720,16 +943,16 @@ namespace AGVControl ...@@ -720,16 +943,16 @@ namespace AGVControl
#endregion #endregion
#region 指定充电位置 #region 指定充电位置
if (agv.IP == "10.85.199.71")//1763 if (agv.IP == "10.85.199.73")//1767,
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge3"], isRemovePreMission); rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge5"], isRemovePreMission);
if (rtn) if (rtn)
{ {
//agv.TaskSend = "AutoCharge3"; //agv.TaskSend = "AutoCharge5";
agv.TaskSend = "AutoCharge"; agv.TaskSend = "AutoCharge";
Common.chargeStatus.charge3 = agv.Name; Common.chargeStatus.charge5 = agv.Name;
Common.chargeStatus.chargeInterval = DateTime.Now.Ticks; Common.chargeStatus.chargeInterval = DateTime.Now.Ticks;
log = string.Format("{0} AutoCharge3", agv.Name); log = string.Format("{0} AutoCharge5", agv.Name);
agv.Msg = log; agv.Msg = log;
Common.LogInfo(log); Common.LogInfo(log);
Common.mir.State_Ready(agv); Common.mir.State_Ready(agv);
...@@ -737,23 +960,23 @@ namespace AGVControl ...@@ -737,23 +960,23 @@ namespace AGVControl
else else
{ {
agv.TaskSend = ""; agv.TaskSend = "";
log = string.Format("{0} AutoCharge3 失败", agv.Name); log = string.Format("{0} AutoCharge5 失败", agv.Name);
//防止上一个任务已执行但返回失败时,删除任务 //防止上一个任务已执行但返回失败时,删除任务
//Common.mir.Del_Mission(agv); //Common.mir.Del_Mission(agv);
Common.LogInfo(log); Common.LogInfo(log);
} }
return rtn; return rtn;
} }
else if (agv.IP == "10.85.199.72")//1764 else if (agv.IP == "10.85.199.74")//1768
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge4"], isRemovePreMission); rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge6"], isRemovePreMission);
if (rtn) if (rtn)
{ {
//agv.TaskSend = "AutoCharge4"; //agv.TaskSend = "AutoCharge6";
agv.TaskSend = "AutoCharge"; agv.TaskSend = "AutoCharge";
Common.chargeStatus.charge4 = agv.Name; Common.chargeStatus.charge4 = agv.Name;
Common.chargeStatus.chargeInterval = DateTime.Now.Ticks; Common.chargeStatus.chargeInterval = DateTime.Now.Ticks;
log = string.Format("{0} AutoCharge4", agv.Name); log = string.Format("{0} AutoCharge6", agv.Name);
agv.Msg = log; agv.Msg = log;
Common.LogInfo(log); Common.LogInfo(log);
Common.mir.State_Ready(agv); Common.mir.State_Ready(agv);
...@@ -761,23 +984,23 @@ namespace AGVControl ...@@ -761,23 +984,23 @@ namespace AGVControl
else else
{ {
agv.TaskSend = ""; agv.TaskSend = "";
log = string.Format("{0} AutoCharge4 失败", agv.Name); log = string.Format("{0} AutoCharge6 失败", agv.Name);
//防止上一个任务已执行但返回失败时,删除任务 //防止上一个任务已执行但返回失败时,删除任务
//Common.mir.Del_Mission(agv); //Common.mir.Del_Mission(agv);
Common.LogInfo(log); Common.LogInfo(log);
} }
return rtn; return rtn;
} }
else if (agv.IP == "10.85.199.73")//1767, if (Common.chargeStatus.charge3 == "")//1763 agv.IP == "10.85.199.71"
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge5"], isRemovePreMission); rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge3"], isRemovePreMission);
if (rtn) if (rtn)
{ {
//agv.TaskSend = "AutoCharge5"; //agv.TaskSend = "AutoCharge3";
agv.TaskSend = "AutoCharge"; agv.TaskSend = "AutoCharge";
Common.chargeStatus.charge5 = agv.Name; Common.chargeStatus.charge3 = agv.Name;
Common.chargeStatus.chargeInterval = DateTime.Now.Ticks; Common.chargeStatus.chargeInterval = DateTime.Now.Ticks;
log = string.Format("{0} AutoCharge5", agv.Name); log = string.Format("{0} AutoCharge3", agv.Name);
agv.Msg = log; agv.Msg = log;
Common.LogInfo(log); Common.LogInfo(log);
Common.mir.State_Ready(agv); Common.mir.State_Ready(agv);
...@@ -785,23 +1008,23 @@ namespace AGVControl ...@@ -785,23 +1008,23 @@ namespace AGVControl
else else
{ {
agv.TaskSend = ""; agv.TaskSend = "";
log = string.Format("{0} AutoCharge5 失败", agv.Name); log = string.Format("{0} AutoCharge3 失败", agv.Name);
//防止上一个任务已执行但返回失败时,删除任务 //防止上一个任务已执行但返回失败时,删除任务
//Common.mir.Del_Mission(agv); //Common.mir.Del_Mission(agv);
Common.LogInfo(log); Common.LogInfo(log);
} }
return rtn; return rtn;
} }
else if (agv.IP == "10.85.199.74")//1768 else if (Common.chargeStatus.charge4 == "")//1764 agv.IP == "10.85.199.72"
{ {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge6"], isRemovePreMission); rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge4"], isRemovePreMission);
if (rtn) if (rtn)
{ {
//agv.TaskSend = "AutoCharge6"; //agv.TaskSend = "AutoCharge4";
agv.TaskSend = "AutoCharge"; agv.TaskSend = "AutoCharge";
Common.chargeStatus.charge4 = agv.Name; Common.chargeStatus.charge4 = agv.Name;
Common.chargeStatus.chargeInterval = DateTime.Now.Ticks; Common.chargeStatus.chargeInterval = DateTime.Now.Ticks;
log = string.Format("{0} AutoCharge6", agv.Name); log = string.Format("{0} AutoCharge4", agv.Name);
agv.Msg = log; agv.Msg = log;
Common.LogInfo(log); Common.LogInfo(log);
Common.mir.State_Ready(agv); Common.mir.State_Ready(agv);
...@@ -809,41 +1032,41 @@ namespace AGVControl ...@@ -809,41 +1032,41 @@ namespace AGVControl
else else
{ {
agv.TaskSend = ""; agv.TaskSend = "";
log = string.Format("{0} AutoCharge6 失败", agv.Name); log = string.Format("{0} AutoCharge4 失败", agv.Name);
//防止上一个任务已执行但返回失败时,删除任务 //防止上一个任务已执行但返回失败时,删除任务
//Common.mir.Del_Mission(agv); //Common.mir.Del_Mission(agv);
Common.LogInfo(log); Common.LogInfo(log);
} }
return rtn; return rtn;
} }
else //if (Common.chargeStatus.charge7 == "") //else //if (Common.chargeStatus.charge7 == "")
{ //{
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge7"]); // rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["AutoCharge7"]);
if (rtn) // if (rtn)
{ // {
agv.TaskSend = "AutoCharge7"; // agv.TaskSend = "AutoCharge7";
Common.chargeStatus.charge3 = agv.Name; // Common.chargeStatus.charge3 = agv.Name;
Common.chargeStatus.chargeInterval = DateTime.Now.Ticks; // Common.chargeStatus.chargeInterval = DateTime.Now.Ticks;
log = string.Format("{0} AutoCharge7", agv.Name); // log = string.Format("{0} AutoCharge7", agv.Name);
Common.LogInfo(log); // Common.LogInfo(log);
Common.mir.State_Ready(agv); // Common.mir.State_Ready(agv);
} // }
// else
// {
// agv.TaskSend = "";
// log = string.Format("{0} AutoCharge7 失败", agv.Name);
// //防止上一个任务已执行但返回失败时,删除任务
// //Common.mir.Del_Mission(agv);
// Common.LogInfo(log);
// }
// return rtn;
//}
else else
{ {
agv.TaskSend = "";
log = string.Format("{0} AutoCharge7 失败", agv.Name);
//防止上一个任务已执行但返回失败时,删除任务
//Common.mir.Del_Mission(agv);
Common.LogInfo(log);
}
return rtn;
}
//else
//{
// return false; return false;
//} }
#endregion #endregion
} }
...@@ -871,7 +1094,7 @@ namespace AGVControl ...@@ -871,7 +1094,7 @@ namespace AGVControl
/// <returns></returns> /// <returns></returns>
public static bool CheckAGVStatusNone(Agv_Info agv) public static bool CheckAGVStatusNone(Agv_Info agv)
{ {
if (agv.CurJob is ChargeJob && !agv.IsExistShelf) if ((agv.CurJob is ChargeJob || agv.CurJob == null) && !agv.IsExistShelf)
return true; return true;
else else
return false; return false;
...@@ -968,6 +1191,7 @@ namespace AGVControl ...@@ -968,6 +1191,7 @@ namespace AGVControl
idx = Common.missionManager.missionList.FindIndex(s => s.NodeName == nodeName); idx = Common.missionManager.missionList.FindIndex(s => s.NodeName == nodeName);
if (idx > -1) if (idx > -1)
{ {
LogInfo("删除一个空料架任务:"+nodeName);
Common.missionManager.missionList.RemoveAt(idx); Common.missionManager.missionList.RemoveAt(idx);
using (System.IO.StreamWriter file = new System.IO.StreamWriter(CONFIG_PATH + "LinePlace.txt")) using (System.IO.StreamWriter file = new System.IO.StreamWriter(CONFIG_PATH + "LinePlace.txt"))
{ {
...@@ -1083,8 +1307,6 @@ namespace AGVControl ...@@ -1083,8 +1307,6 @@ namespace AGVControl
} }
/// <summary> /// <summary>
/// 地点状态 /// 地点状态
/// </summary> /// </summary>
......
...@@ -31,15 +31,15 @@ namespace BLL ...@@ -31,15 +31,15 @@ namespace BLL
AgvCallTimer = new System.Timers.Timer AgvCallTimer = new System.Timers.Timer
{ {
Interval = 300, Interval = 300,
AutoReset = false, AutoReset = true,
Enabled = false Enabled = false
}; };
AgvCallTimer.Elapsed += AgvCallTimer_Elapsed; AgvCallTimer.Elapsed += AgvCallTimer_Elapsed;
AgvStateTimer = new System.Timers.Timer AgvStateTimer = new System.Timers.Timer
{ {
Interval = 300, Interval = 500,
AutoReset = false, AutoReset = true,
Enabled = false Enabled = false
}; };
AgvStateTimer.Elapsed += AgvStateTimer_Elapsed; AgvStateTimer.Elapsed += AgvStateTimer_Elapsed;
...@@ -48,28 +48,28 @@ namespace BLL ...@@ -48,28 +48,28 @@ namespace BLL
public void Start() public void Start()
{ {
//AgvCallTimer.Enabled = true; AgvCallTimer.Enabled = true;
//AgvStateTimer.Enabled = true; AgvStateTimer.Enabled = true;
AgvCallTimer.Start(); AgvCallTimer.Start();
AgvStateTimer.Start(); AgvStateTimer.Start();
} }
public void Stop() public void Stop()
{ {
//AgvCallTimer.Enabled = false; AgvCallTimer.Enabled = false;
//AgvStateTimer.Enabled = false; AgvStateTimer.Enabled = false;
AgvCallTimer.Stop(); AgvCallTimer.Stop();
AgvStateTimer.Stop(); AgvStateTimer.Stop();
} }
//private bool AgvStateInProcess = false; private bool AgvStateInProcess = false;
private eAGVState preAGVState = eAGVState.None; private eAGVState preAGVState = eAGVState.None;
private void AgvStateTimer_Elapsed(object sender, System.Timers.ElapsedEventArgs e) private void AgvStateTimer_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
{ {
bool rtn; bool rtn;
//if (AgvStateInProcess) return; if (AgvStateInProcess) return;
//AgvStateInProcess = true; AgvStateInProcess = true;
//上报异常 //上报异常
bool isAlarm = false; bool isAlarm = false;
List<AlarmMsg> msglist = new List<AlarmMsg>(); List<AlarmMsg> msglist = new List<AlarmMsg>();
...@@ -81,7 +81,6 @@ namespace BLL ...@@ -81,7 +81,6 @@ namespace BLL
msglist.Add(new AlarmMsg(Common.nodeInfo[j].AliceName, "agv." + Common.nodeInfo[j].Name + ".OnLine", "接驳台状态:离线")); msglist.Add(new AlarmMsg(Common.nodeInfo[j].AliceName, "agv." + Common.nodeInfo[j].Name + ".OnLine", "接驳台状态:离线"));
} }
} }
Common.log.Debug("上报异常");
for (int i = 0; i < Common.agvInfo.Count; i++) for (int i = 0; i < Common.agvInfo.Count; i++)
{ {
...@@ -89,13 +88,18 @@ namespace BLL ...@@ -89,13 +88,18 @@ namespace BLL
//获取AGV状态 //获取AGV状态
rtn = Common.mir.Get_State(Common.agvInfo[i], out eAGVState stateID, out string stateText, out int battery, out string mission_text, out Agv_Info.clsPosition position); rtn = Common.mir.Get_State(Common.agvInfo[i], out eAGVState stateID, out string stateText, out int battery, out string mission_text, out Agv_Info.clsPosition position);
if (!rtn)
continue;
Common.log.Debug("获取AGV状态"); Common.log.Debug("获取AGV状态");
Thread.Sleep(50); Thread.Sleep(50);
rtn = Common.mir.Get_Task_State(Common.agvInfo[i], out string stateStr);
Common.mir.Get_IO_Status(Common.agvInfo[i], out bool[] input, out bool[] output); Thread.Sleep(50);
rtn = Common.mir.Get_IO_Status(Common.agvInfo[i], out bool[] input, out bool[] output);
if (!rtn)
continue;
Common.log.Debug("获取IO状态"); Common.log.Debug("获取IO状态");
bool change = false; bool change = false;
if (rtn) change = Common.agvInfo[i].SetState(stateID, stateText, battery, mission_text, position); if (rtn) change = Common.agvInfo[i].SetState(stateID, stateStr, battery, mission_text, position);
if (Common.agvInfo[i].StateID.Equals(eAGVState.Docking)) if (Common.agvInfo[i].StateID.Equals(eAGVState.Docking))
{ {
...@@ -150,7 +154,7 @@ namespace BLL ...@@ -150,7 +154,7 @@ namespace BLL
//执行任务更新状态 //执行任务更新状态
if (stateID.Equals(eAGVState.Executing) || change) if (stateID.Equals(eAGVState.Executing) || change)
{ {
Common.log.Debug(string.Format("{0} Get_Register PLC{1}={2}", Common.agvInfo[i].Name, REG_STATUS, regValue)); //Common.log.Debug(string.Format("{0} Get_Register PLC{1}={2}", Common.agvInfo[i].Name, REG_STATUS, regValue));
AgvChanged?.Invoke(i); AgvChanged?.Invoke(i);
} }
...@@ -172,7 +176,7 @@ namespace BLL ...@@ -172,7 +176,7 @@ namespace BLL
} }
if (isAlarm) if (isAlarm)
BLL.AGVManager.updateDeviceAlarmMsg(msglist); BLL.AGVManager.updateDeviceAlarmMsg(msglist);
//AgvStateInProcess = false; AgvStateInProcess = false;
} }
/// <summary> /// <summary>
...@@ -180,13 +184,32 @@ namespace BLL ...@@ -180,13 +184,32 @@ namespace BLL
/// </summary> /// </summary>
/// <param name="agv_Info"></param> /// <param name="agv_Info"></param>
/// <returns></returns> /// <returns></returns>
private Job GetJob(Agv_Info agv_Info) public Job GetJob(Agv_Info agv_Info)
{ {
foreach(Node node in Common.nodeInfo) foreach (Node node in Common.nodeInfo)
{ {
Job job = node.GetNewJob(agv_Info); Job job = null;
if(job != null)
if (node.Name.Equals("A5"))
{ {
if (!SettingString.C4_AGV_IPs.Contains(agv_Info.IP))
continue;
job = ((DoubleLineNodeFor4C)node).GetNewJob(agv_Info);
}
else if (node.Name.Equals("A6"))
{
if (SettingString.C4_AGV_IPs.Contains(agv_Info.IP))
continue;
job = ((DoubleLineNodeFor4D)node).GetNewJob(agv_Info);
}
else
{
job = node.GetNewJob(agv_Info);
}
if (job != null)
{
Common.log.Info(node.Name + " GetJob OK " + job.ToString());
return job; return job;
} }
} }
...@@ -210,24 +233,26 @@ namespace BLL ...@@ -210,24 +233,26 @@ namespace BLL
if (!Common.agvInfo[i].StateID.Equals(eAGVState.Ready) && !Common.agvInfo[i].StateID.Equals(eAGVState.Pause) if (!Common.agvInfo[i].StateID.Equals(eAGVState.Ready) && !Common.agvInfo[i].StateID.Equals(eAGVState.Pause)
&& !Common.agvInfo[i].StateID.Equals(eAGVState.Executing) && !Common.agvInfo[i].StateID.Equals(eAGVState.Error)) && !Common.agvInfo[i].StateID.Equals(eAGVState.Executing) && !Common.agvInfo[i].StateID.Equals(eAGVState.Error))
{ {
Common.LogInfo(string.Format("{0}不能调用 StateID={1}, StateText={2}", Common.agvInfo[i].Name, Common.agvInfo[i].StateID, Common.agvInfo[i].StateText)); Common.LogInfo(string.Format("{0}不能调用 StateID={1}", Common.agvInfo[i].Name, Common.agvInfo[i].StateID.ToString()));
continue; continue;
} }
if(agv.CurJob == null) if (agv.CurJob == null)
{ {
Job job = GetJob(agv); Job job = GetJob(agv);
if(job != null) if (job != null)
{ {
agv.CurJob = job; agv.CurJob = job;
} }
else else
{ {
//if (agv.Battery < Common.chargeStatus.chargeMax)
agv.CurJob = new ChargeJob(agv.Place); agv.CurJob = new ChargeJob(agv.Place);
} }
} }
if(agv.CurJob != null) if (agv.CurJob != null)
{ {
agv.CurJob = agv.CurJob.Execute(agv); agv.CurJob = agv.CurJob.Execute(agv);
} }
...@@ -277,6 +302,8 @@ namespace BLL ...@@ -277,6 +302,8 @@ namespace BLL
} }
return rtn; return rtn;
} }
#region 老程序
/// <summary> /// <summary>
/// agv空闲 /// agv空闲
/// </summary> /// </summary>
...@@ -894,39 +921,39 @@ namespace BLL ...@@ -894,39 +921,39 @@ namespace BLL
// AgvChanged?.Invoke(idx); // AgvChanged?.Invoke(idx);
//} //}
private void ProcessStandyTemp(Agv_Info agv) //private void ProcessStandyTemp(Agv_Info agv)
{ //{
switch (agv.Place) // switch (agv.Place)
{ // {
case "J1": // case "J1":
case "J2": // case "J2":
case "J3": // case "J3":
case "J4": // case "J4":
case "J5": // case "J5":
case "J6": // case "J6":
case "J7": // case "J7":
case "J8": // case "J8":
CheckA5A6State_SmallShelf(agv); // CheckA5A6State_SmallShelf(agv);
break; // break;
} // }
} //}
private void ProcessDoor(Agv_Info agv) //private void ProcessDoor(Agv_Info agv)
{ //{
switch (agv.Place) // switch (agv.Place)
{ // {
case "F1": // case "F1":
case "F2": // case "F2":
case "F3": // case "F3":
case "F4": // case "F4":
case "F5": // case "F5":
case "F6": // case "F6":
case "F7": // case "F7":
case "F8": // case "F8":
//ResetNodeState(node, agv); // //ResetNodeState(node, agv);
Common.log.Debug(string.Format("{0} MoveDoor {1}[RFID={2}] Finish.", agv.Name, agv.Place, agv.RFID)); // Common.log.Debug(string.Format("{0} MoveDoor {1}[RFID={2}] Finish.", agv.Name, agv.Place, agv.RFID));
break; // break;
} // }
} //}
...@@ -1073,181 +1100,116 @@ namespace BLL ...@@ -1073,181 +1100,116 @@ namespace BLL
// } // }
// AgvChanged?.Invoke(idx); // AgvChanged?.Invoke(idx);
//} //}
/// <summary>
/// 查看A5、A6需要小料架的状况
/// </summary>
/// <param name="agv"></param>
/// <param name="node"></param>
private void CheckA5A6State_SmallShelf(Agv_Info agv, ClientNode node, bool isRemovePreMission = true)
{
bool rtn = false;
int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A5"
&& (s.StateEquals(eNodeStatus.NeedD) || s.StateEquals(eNodeStatus.NeedEnter)) && s.AgvName == "" && s.IsUse);
if (tarIdx == -1)
{
Common.LogInfo(string.Format("{0} 已装载小料架,A5不需要料架", agv.Name), false);//小
}
else
{
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA5"], isRemovePreMission);
if (rtn)
{
agv.NextPlace = "";
node.AgvName = "";
Common.nodeInfo[tarIdx].AgvName = agv.Name;
agv.TaskSend = rtn ? "MoveA5" : "";
agv.Msg = string.Format("{0} 已装载小料架,送往A5", agv.Name);
Common.LogInfo(string.Format("{0} 已装载小料架,送往A5", agv.Name));//小
}
return;
}
tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A6" &&
(s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.AgvName == "" && s.IsUse);
if (tarIdx == -1)
{
//StatusCharge(agv);
//Common.LogInfo(string.Format("{0} 已装载小料架,A6不需要料架,到待机位等待", agv.Name), false);//小
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveStandbyTemp"]);
if (rtn)
{
agv.NextPlace = "";
node.AgvName = "";
agv.TaskSend = rtn ? "MoveStandbyTemp" : "";
agv.Msg = string.Format("{0} 已装载小料架,送往MoveStandbyTemp", agv.Name);
Common.LogInfo(string.Format("{0} 已装载小料架,送往MoveStandbyTemp", agv.Name));
}
}
else
{
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA6"], isRemovePreMission);
if (rtn)
{
agv.NextPlace = "";
node.AgvName = "";
Common.nodeInfo[tarIdx].AgvName = agv.Name;
agv.TaskSend = rtn ? "MoveA6" : "";
agv.Msg = string.Format("{0} 已装载小料架,送往A6", agv.Name);
Common.LogInfo(string.Format("{0} 已装载小料架,送往A6", agv.Name));//小
}
}
}
/// <summary> /// <summary>
/// 空闲状态查看A5、A6需要小料架的状况 /// 空闲状态查看A5、A6需要小料架的状况
/// </summary> /// </summary>
/// <param name="agv"></param> /// <param name="agv"></param>
private void CheckA5A6State_SmallShelf(Agv_Info agv) //private void CheckA5A6State_SmallShelf(Agv_Info agv)
{ //{
if (!agv.TaskSend.Equals("")) // if (!agv.TaskSend.Equals(""))
return; // return;
bool rtn = false; // bool rtn = false;
int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A5" // int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A5"
&& (s.StateEquals(eNodeStatus.NeedD) || s.StateEquals(eNodeStatus.NeedEnter)) && s.AgvName == "" && s.IsUse); // && (s.StateEquals(eNodeStatus.NeedD) || s.StateEquals(eNodeStatus.NeedEnter)) && s.AgvName == "" && s.IsUse);
if (tarIdx == -1) // if (tarIdx == -1)
{ // {
Common.log.Debug(string.Format("{0} 已装载料架 {1},A5不需要料架", agv.Name, agv.RFID));//小 // Common.log.Debug(string.Format("{0} 已装载料架 {1},A5不需要料架", agv.Name, agv.RFID));//小
} // }
else // else
{ // {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA5"]); // rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA5"]);
if (rtn) // if (rtn)
{ // {
agv.NextPlace = ""; // agv.TaskSend = "MoveA5";
agv.TaskSend = "MoveA5"; // Common.nodeInfo[tarIdx].AgvName = agv.Name;
Common.nodeInfo[tarIdx].AgvName = agv.Name; // agv.Msg = string.Format("{0} 已装载料架 {1},送往A5", agv.Name, agv.RFID);
agv.Msg = string.Format("{0} 已装载料架 {1},送往A5", agv.Name, agv.RFID); // Common.LogInfo(string.Format("{0} 已装载料架 {1},送往A5", agv.Name, agv.RFID));//小
Common.LogInfo(string.Format("{0} 已装载料架 {1},送往A5", agv.Name, agv.RFID));//小 // }
} // return;
return; // }
}
tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A6" && // tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A6" &&
(s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.AgvName == "" && s.IsUse); // (s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.AgvName == "" && s.IsUse);
if (tarIdx == -1) // if (tarIdx == -1)
{ // {
Common.log.Debug(string.Format("{0} 已装载料架 {1},A6不需要料架", agv.Name, agv.RFID));//小 // Common.log.Debug(string.Format("{0} 已装载料架 {1},A6不需要料架", agv.Name, agv.RFID));//小
} // }
else // else
{ // {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA6"]); // rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA6"]);
if (rtn) // if (rtn)
{ // {
agv.NextPlace = ""; // agv.TaskSend = "MoveA6";
agv.TaskSend = "MoveA6"; // Common.nodeInfo[tarIdx].AgvName = agv.Name;
Common.nodeInfo[tarIdx].AgvName = agv.Name; // agv.Msg = string.Format("{0} 已装载料架 {1},送往A6", agv.Name, agv.RFID);
agv.Msg = string.Format("{0} 已装载料架 {1},送往A6", agv.Name, agv.RFID); // Common.LogInfo(string.Format("{0} 已装载料架 {1},送往A6", agv.Name, agv.RFID));//小
Common.LogInfo(string.Format("{0} 已装载料架 {1},送往A6", agv.Name, agv.RFID));//小 // }
}
} // }
} //}
/// <summary> /// <summary>
/// 空闲 查看A5、A6需要大料架的状况 /// 空闲 查看A5、A6需要大料架的状况
/// </summary> /// </summary>
/// <param name="agv"></param> /// <param name="agv"></param>
private void CheckA5A6State_BigShelf(Agv_Info agv) //private void CheckA5A6State_BigShelf(Agv_Info agv)
{ //{
if (!agv.TaskSend.Equals("")) // if (!agv.TaskSend.Equals(""))
return; // return;
bool rtn = false; // bool rtn = false;
int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A5" // int tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A5"
&& (s.StateEquals(eNodeStatus.NeedC) || s.StateEquals(eNodeStatus.NeedEnter)) && s.IsUse); // && (s.StateEquals(eNodeStatus.NeedC) || s.StateEquals(eNodeStatus.NeedEnter)) && s.IsUse);
if (tarIdx == -1) // if (tarIdx == -1)
{ // {
Common.log.Debug(string.Format("{0} 已装载料架 {1},A5不需要料架", agv.Name, agv.RFID));//小 // Common.log.Debug(string.Format("{0} 已装载料架 {1},A5不需要料架", agv.Name, agv.RFID));//小
} // }
else // else
{ // {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA5"]); // rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA5"]);
if (rtn) // if (rtn)
{ // {
agv.NextPlace = ""; // agv.TaskSend = "MoveA5";
agv.TaskSend = "MoveA5"; // Common.nodeInfo[tarIdx].AgvName = agv.Name;
Common.nodeInfo[tarIdx].AgvName = agv.Name; // agv.Msg = string.Format("{0} 已装载料架 {1},送往A5", agv.Name, agv.RFID);
agv.Msg = string.Format("{0} 已装载料架 {1},送往A5", agv.Name, agv.RFID); // Common.LogInfo(string.Format("{0} 已装载料架 {1},送往A5", agv.Name, agv.RFID));//小
Common.LogInfo(string.Format("{0} 已装载料架 {1},送往A5", agv.Name, agv.RFID));//小 // }
} // return;
return; // }
}
tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A6" && // tarIdx = Common.nodeInfo.FindIndex(s => s.Name == "A6" &&
(s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.IsUse); // (s.StateEquals(eNodeStatus.NeedEnter) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && s.IsUse);
if (tarIdx == -1) // if (tarIdx == -1)
{ // {
Common.log.Debug(string.Format("{0} 已装载料架 {1},A6不需要料架", agv.Name, agv.RFID));//小 // Common.log.Debug(string.Format("{0} 已装载料架 {1},A6不需要料架", agv.Name, agv.RFID));//小
} // }
else // else
{ // {
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA6"]); // rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveA6"]);
if (rtn) // if (rtn)
{ // {
agv.NextPlace = ""; // Common.nodeInfo[tarIdx].AgvName = agv.Name;
Common.nodeInfo[tarIdx].AgvName = agv.Name; // agv.TaskSend = "MoveA6";
agv.TaskSend = "MoveA6"; // agv.Msg = string.Format("{0} 已装载料架 {1},送往A6", agv.Name, agv.RFID);
agv.Msg = string.Format("{0} 已装载料架 {1},送往A6", agv.Name, agv.RFID); // Common.LogInfo(string.Format("{0} 已装载料架 {1},送往A6", agv.Name, agv.RFID));//小
Common.LogInfo(string.Format("{0} 已装载料架 {1},送往A6", agv.Name, agv.RFID));//小 // }
}
} // }
} //}
/// <summary> ///// <summary>
/// 料架离开小车 ///// 料架离开小车
/// </summary> ///// </summary>
/// <param name="idx">agv索引</param> ///// <param name="idx">agv索引</param>
private void StateLeave(int idx) //private void StateLeave(int idx)
{ //{
Agv_Info agv = Common.agvInfo[idx]; // Agv_Info agv = Common.agvInfo[idx];
} //}
/// <summary> /// <summary>
/// 料架离开小车完成 /// 料架离开小车完成
/// </summary> /// </summary>
...@@ -1442,125 +1404,114 @@ namespace BLL ...@@ -1442,125 +1404,114 @@ namespace BLL
/// 重置节点状态 /// 重置节点状态
/// </summary> /// </summary>
/// <param name="clientNode"></param> /// <param name="clientNode"></param>
private void ResetNodeState(ClientNode clientNode, Agv_Info agv) //private void ResetNodeState(ClientNode clientNode, Agv_Info agv)
{ //{
clientNode.StateEquals(eNodeStatus.None); // clientNode.StateEquals(eNodeStatus.None);
if (agv.Name == clientNode.AgvName) // if (agv.Name == clientNode.AgvName)
clientNode.AgvName = ""; // clientNode.AgvName = "";
clientNode.RFID = ""; // clientNode.RFID = "";
} //}
/// <summary> //private bool MoveStandby(Agv_Info agv)
/// 重置agv变量信息(RFID) //{
/// </summary> // string log;
/// <param name="agv"></param> // if (!agv.TaskSend.Equals(""))
/// <param name="IsNextPlace">是否清除下一目的地</param> // return false;
private void ResetAGVState(Agv_Info agv, bool IsNextPlace = false) // //清除当前任务点
{ // if (!agv.Place.Equals(""))
agv.RFID = ""; // {
if (IsNextPlace) // int idx = Common.nodeInfo.FindIndex(s => s.Name == agv.Place);
agv.NextPlace = ""; // if (idx > -1)
} // {
private bool MoveStandby(Agv_Info agv) // Common.nodeInfo[idx].AgvName = "";
{ // }
string log; // else
if (!agv.TaskSend.Equals("")) // {
return false; // log = "清理AgvName,没有找到 " + agv.Name;
//清除当前任务点 // Common.LogInfo(log);
if (!agv.Place.Equals("")) // }
{ // }
int idx = Common.nodeInfo.FindIndex(s => s.Name == agv.Place);
if (idx > -1)
{
Common.nodeInfo[idx].AgvName = "";
}
else
{
log = "清理AgvName,没有找到 " + agv.Name;
Common.LogInfo(log);
}
}
//执行下一个任务 // //执行下一个任务
//agv.Place = ""; // //agv.Place = "";
bool rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveStandby"]); //返回待机区 // bool rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["MoveStandby"]); //返回待机区
if (rtn) // if (rtn)
{ // {
agv.TaskSend = ""; // agv.TaskSend = "";
agv.Place = ""; // agv.Place = "";
log = string.Format("{0} MoveStandby", agv.Name); // log = string.Format("{0} MoveStandby", agv.Name);
Common.LogInfo(log); // Common.LogInfo(log);
Common.mir.State_Ready(agv); // Common.mir.State_Ready(agv);
} // }
else // else
{ // {
agv.TaskSend = ""; // agv.TaskSend = "";
log = string.Format("{0} MoveStandby 失败", agv.Name); // log = string.Format("{0} MoveStandby 失败", agv.Name);
//防止上一个任务已执行但返回失败时,删除任务 // //防止上一个任务已执行但返回失败时,删除任务
//Common.mir.Del_Mission(agv); // //Common.mir.Del_Mission(agv);
Common.LogInfo(log); // Common.LogInfo(log);
} // }
return rtn; // return rtn;
} //}
Task<bool> continueTask; // Task<bool> continueTask;
/// <summary> /// <summary>
/// 清空错误并继续任务 /// 清空错误并继续任务
/// </summary> /// </summary>
/// <param name="idx"></param> /// <param name="idx"></param>
private bool ClearErrorAndContinueTask(int idx) //private bool ClearErrorAndContinueTask(int idx)
{ //{
continueTask = Task.Run<bool>(() => // continueTask = Task.Run<bool>(() =>
{ // {
Agv_Info agv = Common.agvInfo[idx]; // Agv_Info agv = Common.agvInfo[idx];
Common.LogInfo(string.Format("{0}在执行任务[{1}]出现错误:{2}", agv.Name, agv.TaskSend, agv.MissionText)); // Common.LogInfo(string.Format("{0}在执行任务[{1}]出现错误:{2}", agv.Name, agv.TaskSend, agv.MissionText));
if (Common.agvInfo[idx].IsCon) // if (Common.agvInfo[idx].IsCon)
{ // {
Common.mir.Clear_Error(Common.agvInfo[idx]); // Common.mir.Clear_Error(Common.agvInfo[idx]);
Thread.Sleep(1000); // Thread.Sleep(1000);
Common.mir.State_Ready(Common.agvInfo[idx]); // Common.mir.State_Ready(Common.agvInfo[idx]);
Thread.Sleep(1000); // Thread.Sleep(1000);
//bool rtn = Common.mir.Add_Mission(Common.agvInfo[idx], Common.agvMission[agv.TaskSend]); // //bool rtn = Common.mir.Add_Mission(Common.agvInfo[idx], Common.agvMission[agv.TaskSend]);
//if (!rtn) // //if (!rtn)
// // return false;
// Common.LogInfo(string.Format("{0}清除错误,继续任务", agv.Name, agv.TaskSend, agv.MissionText));
// return true;
// }
// return false; // return false;
Common.LogInfo(string.Format("{0}清除错误,继续任务", agv.Name, agv.TaskSend, agv.MissionText)); // });
return true; // continueTask.Start();
} // return continueTask.Result;
return false; //}
});
continueTask.Start();
return continueTask.Result;
}
/// <summary> /// <summary>
/// 小车重试次数 /// 小车重试次数
/// </summary> /// </summary>
static int[] reTryTimes = new int[Common.agvInfo.Count]; //static int[] reTryTimes = new int[Common.agvInfo.Count];
/// <summary> ///// <summary>
/// 错误状态 ///// 错误状态
/// </summary> ///// </summary>
/// <param name="idx"></param> ///// <param name="idx"></param>
private void StateError(int idx) //private void StateError(int idx)
{ //{
if (continueTask != null && !continueTask.IsCompleted) // if (continueTask != null && !continueTask.IsCompleted)
return; // return;
if (reTryTimes[idx] > 5)//重试5次 // if (reTryTimes[idx] > 5)//重试5次
{ // {
Common.LogInfo(string.Format("{0} 发生错误,重试5次失败,需要手动清除错误!", Common.agvInfo[idx])); // Common.LogInfo(string.Format("{0} 发生错误,重试5次失败,需要手动清除错误!", Common.agvInfo[idx]));
reTryTimes[idx] = 0; // reTryTimes[idx] = 0;
return; // return;
} // }
if (!ClearErrorAndContinueTask(idx)) // if (!ClearErrorAndContinueTask(idx))
reTryTimes[idx]++; // reTryTimes[idx]++;
else // else
reTryTimes[idx] = 0; // reTryTimes[idx] = 0;
} //}
//private bool FindA6Leave(out string nextNode) //private bool FindA6Leave(out string nextNode)
...@@ -1586,7 +1537,7 @@ namespace BLL ...@@ -1586,7 +1537,7 @@ namespace BLL
//} //}
#endregion
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -10,6 +10,7 @@ using System.Text; ...@@ -10,6 +10,7 @@ using System.Text;
namespace BLL namespace BLL
{ {
[ServiceContract(Name = "Services")] [ServiceContract(Name = "Services")]
internal interface IWebService internal interface IWebService
{ {
...@@ -43,6 +44,7 @@ namespace BLL ...@@ -43,6 +44,7 @@ namespace BLL
{ {
internal ClsWebService() internal ClsWebService()
{ {
} }
public string CreateEmptyRecycleTask(Stream stream) public string CreateEmptyRecycleTask(Stream stream)
......
...@@ -92,7 +92,7 @@ namespace BLL ...@@ -92,7 +92,7 @@ namespace BLL
{ {
input = null; input = null;
output = null; output = null;
Common.log.Error("", ex); //Common.log.Error("", ex);
return false; return false;
} }
} }
...@@ -174,6 +174,10 @@ namespace BLL ...@@ -174,6 +174,10 @@ namespace BLL
{ {
try try
{ {
//var key = Common.agvMission.Where(qq => qq.Value == mission_id).Select(qq => qq.Key);
//Common.log.Info(string.Format("{0} Add_Mission [{1}]", info.Name, key.ToList()[0]));
Common.LogInfo(string.Format("{0} Add_Mission [{1}]", info.Name, mission_id));
//防止上一个任务已执行但返回失败时,删除任务 //防止上一个任务已执行但返回失败时,删除任务
// if (isRemovePreMission) // if (isRemovePreMission)
Del_Mission(info); Del_Mission(info);
...@@ -188,15 +192,22 @@ namespace BLL ...@@ -188,15 +192,22 @@ namespace BLL
if (dic == null) return false; if (dic == null) return false;
string s = dic["mission_id"].ToString(); string s = dic["mission_id"].ToString();
string id = dic["id"].ToString();
if (s == mission_id) if (s == mission_id)
{ {
try try
{ {
info.CurTaskID = Convert.ToInt32(id);
info.CurTaskGUID = mission_id;
var key = Common.agvMission.Where(qq => qq.Value == mission_id).Select(qq => qq.Key); var key = Common.agvMission.Where(qq => qq.Value == mission_id).Select(qq => qq.Key);
info.CurTaskName = key.ToList()[0];
Common.LogInfo(string.Format("{0} Add_Mission [{1}]", info.Name, key.ToList()[0])); Common.LogInfo(string.Format("{0} Add_Mission [{1}]", info.Name, key.ToList()[0]));
} }
catch { Common.LogInfo(string.Format("{0} Add_Mission [{1}]", info.Name, mission_id)); } catch
{
Common.LogInfo(string.Format("{0} Add_Mission [{1}]", info.Name, mission_id));
info.CurTaskName = "";
}
return true; return true;
} }
...@@ -220,10 +231,13 @@ namespace BLL ...@@ -220,10 +231,13 @@ namespace BLL
{ {
try try
{ {
var key = Common.agvMission.Where(qq => qq.Value == mission_id).Select(qq => qq.Key); //var key = Common.agvMission.Where(qq => qq.Value == mission_id).Select(qq => qq.Key);
Common.log.Info(string.Format("{0} Add_Mission_Fleet [{1}]", info.Name, key.ToList()[0])); //Common.log.Info(string.Format("{0} Add_Mission_Fleet [{1}]", info.Name, key.ToList()[0]));
Common.LogInfo(string.Format("{0} Add_Mission_Fleet [{1}]", info.Name, mission_id));
info.CurTaskID = -1;
info.CurTaskGUID = "";
info.CurTaskName = "";
info.CurTaskState = SettingString.Wait;
//防止上一个任务已执行但返回失败时,删除任务 //防止上一个任务已执行但返回失败时,删除任务
//if (isRemovePreMission) //if (isRemovePreMission)
Del_Mission(info); Del_Mission(info);
...@@ -239,15 +253,22 @@ namespace BLL ...@@ -239,15 +253,22 @@ namespace BLL
if (dic == null) return false; if (dic == null) return false;
string s = dic["mission_id"].ToString(); string s = dic["mission_id"].ToString();
string id = dic["id"].ToString();
if (s == mission_id) if (s == mission_id)
{ {
//try try
//{ {
info.CurTaskID = Convert.ToInt32(id);
// var key = Common.agvMission.Where(qq => qq.Value == mission_id).Select(qq => qq.Key); info.CurTaskGUID = mission_id;
// Common.LogInfo(string.Format("{0} Add_Mission_Fleet [{1}]", info.Name, key.ToList()[0])); var key = Common.agvMission.Where(qq => qq.Value == mission_id).Select(qq => qq.Key);
//} info.CurTaskName = key.ToList()[0];
//catch { Common.LogInfo(string.Format("{0} Add_Mission_Fleet [{1}]", info.Name, mission_id)); } Common.LogInfo(string.Format("{0} Add_Mission_Fleet [{1}]", info.Name, key.ToList()[0]));
}
catch
{
Common.LogInfo(string.Format("{0} Add_Mission_Fleet [{1}]", info.Name, mission_id));
info.CurTaskName = "";
}
return true; return true;
} }
else else
...@@ -369,7 +390,7 @@ namespace BLL ...@@ -369,7 +390,7 @@ namespace BLL
/// <returns></returns> /// <returns></returns>
public bool Get_State(Agv_Info info, out eAGVState stateID, out string stateText, out int battery, out string mission_text, out Agv_Info.clsPosition position) public bool Get_State(Agv_Info info, out eAGVState stateID, out string stateText, out int battery, out string mission_text, out Agv_Info.clsPosition position)
{ {
stateID = eAGVState.NULL; stateID = eAGVState.UNKNOWN;
stateText = ""; stateText = "";
battery = 0; battery = 0;
mission_text = ""; mission_text = "";
...@@ -379,12 +400,21 @@ namespace BLL ...@@ -379,12 +400,21 @@ namespace BLL
string url = "http://" + info.IP + "/api/v2.0.0/status?whitelist=state_id,state_text,battery_percentage,mission_text,position"; string url = "http://" + info.IP + "/api/v2.0.0/status?whitelist=state_id,state_text,battery_percentage,mission_text,position";
string json = HttpGet(url, info.IP, info.Authorization); string json = HttpGet(url, info.IP, info.Authorization);
if (string.IsNullOrWhiteSpace(json)) return false; if (string.IsNullOrWhiteSpace(json)) return false;
JavaScriptSerializer serializer = new JavaScriptSerializer(); JavaScriptSerializer serializer = new JavaScriptSerializer();
Dictionary<string, object> dic = (Dictionary<string, object>)serializer.DeserializeObject(json); Dictionary<string, object> dic = (Dictionary<string, object>)serializer.DeserializeObject(json);
if (dic == null) return false; if (dic == null) return false;
stateID = (eAGVState)Convert.ToInt32(dic["state_id"].ToString()); //state_id不存在:{"args":{},"error_code":"service_unavailable","error_human":"\u670d\u52a1\u4e0d\u53ef\u7528\uff0c\u8bf7\u7a0d\u540e\u91cd\u8bd5"}
try
{
stateText = dic["state_text"].ToString();
}
catch
{
Common.log.Error("获取状态失败:" + json);
return false;
}
stateID = (eAGVState)(Convert.ToInt32(dic["state_id"].ToString()));
stateText = dic["state_text"].ToString(); stateText = dic["state_text"].ToString();
mission_text = dic["mission_text"].ToString(); mission_text = dic["mission_text"].ToString();
string s = dic["battery_percentage"].ToString(); string s = dic["battery_percentage"].ToString();
...@@ -399,11 +429,48 @@ namespace BLL ...@@ -399,11 +429,48 @@ namespace BLL
} }
catch (Exception ex) catch (Exception ex)
{ {
Common.log.Error("Get_State", ex); Common.log.Error("Get_State: ", ex);
return false; return false;
} }
} }
public bool Get_Task_State(Agv_Info info,out string stateStr)
{
stateStr = "None";
try
{
if (info.CurTaskID == -1)
return true;
string ip = Common.appConfig.AppSettings.Settings["FLEET"].Value;
//http://10.85.199.3/api/v2.0.0/mission_scheduler
string url = "http://" + ip + "/api/v2.0.0/mission_scheduler/" + info.CurTaskID;
string json = HttpGet(url, info.IP, info.Authorization);
Common.log.Debug("URL: " + url + "\n" + "Return: " + json);
if (string.IsNullOrWhiteSpace(json)) return false;
JavaScriptSerializer serializer = new JavaScriptSerializer();
Dictionary<string, object> dic = (Dictionary<string, object>)serializer.DeserializeObject(json);
if (dic == null) return false;
// "mission_id": "2e433130-c045-11ea-9a66-94c691a7387d",
// "id": 7178,
// "state": "Done"
string s = dic["id"].ToString();
if (s.Equals(info.CurTaskID.ToString()))
{
stateStr = dic["state"].ToString();
return true;
}
return false;
}
catch(Exception ex)
{
Common.log.Error("Get_Task_State", ex);
return false;
}
}
/// <summary> /// <summary>
/// 获取节点位置 /// 获取节点位置
/// </summary> /// </summary>
......
...@@ -32,18 +32,15 @@ ...@@ -32,18 +32,15 @@
this.DgvAgv = new System.Windows.Forms.DataGridView(); this.DgvAgv = new System.Windows.Forms.DataGridView();
this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column3 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column21 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column21 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column25 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column14 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column18 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column18 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column20 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column20 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column23 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column23 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column13 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column13 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column19 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column19 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column11 = new System.Windows.Forms.DataGridViewButtonColumn(); this.Column11 = new System.Windows.Forms.DataGridViewButtonColumn();
this.Column17 = new System.Windows.Forms.DataGridViewButtonColumn();
this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel(); this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel();
this.tabControl1 = new System.Windows.Forms.TabControl(); this.tabControl1 = new System.Windows.Forms.TabControl();
this.tabPage1 = new System.Windows.Forms.TabPage(); this.tabPage1 = new System.Windows.Forms.TabPage();
...@@ -53,59 +50,50 @@ ...@@ -53,59 +50,50 @@
this.Column12 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column12 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column22 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column22 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column7 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column10 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column5 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.Column5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column16 = new System.Windows.Forms.DataGridViewButtonColumn(); this.Column16 = new System.Windows.Forms.DataGridViewButtonColumn();
this.Column15 = new System.Windows.Forms.DataGridViewButtonColumn();
this.groupBox1 = new System.Windows.Forms.GroupBox(); this.groupBox1 = new System.Windows.Forms.GroupBox();
this.btnAddMission = new System.Windows.Forms.Button(); this.tableLayoutPanel5 = new System.Windows.Forms.TableLayoutPanel();
this.cmbBoxLineName = new System.Windows.Forms.ComboBox(); this.groupBox5 = new System.Windows.Forms.GroupBox();
this.btnDeleteMission = new System.Windows.Forms.Button(); this.lblDestInfo = new System.Windows.Forms.Label();
this.groupBox3 = new System.Windows.Forms.GroupBox();
this.lblWO = new System.Windows.Forms.Label();
this.groupBox4 = new System.Windows.Forms.GroupBox();
this.button5 = new System.Windows.Forms.Button();
this.btnWO = new System.Windows.Forms.Button();
this.dgvLineMission = new System.Windows.Forms.DataGridView(); this.dgvLineMission = new System.Windows.Forms.DataGridView();
this.Column24 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.tabPage2 = new System.Windows.Forms.TabPage(); this.tabPage2 = new System.Windows.Forms.TabPage();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.TxtLog = new System.Windows.Forms.TextBox(); this.TxtLog = new System.Windows.Forms.TextBox();
this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel();
this.lblVMIGetBoxDestInfo = new System.Windows.Forms.Label();
this.lblGetRack = new System.Windows.Forms.Label();
this.tabPage3 = new System.Windows.Forms.TabPage(); this.tabPage3 = new System.Windows.Forms.TabPage();
this.button1 = new System.Windows.Forms.Button(); this.groupBox6 = new System.Windows.Forms.GroupBox();
this.btnDeleteMission = new System.Windows.Forms.Button();
this.btnAddMission = new System.Windows.Forms.Button();
this.cmbBoxLineName = new System.Windows.Forms.ComboBox();
this.btnSetRFID = new System.Windows.Forms.Button(); this.btnSetRFID = new System.Windows.Forms.Button();
this.txtAgvRFID = new System.Windows.Forms.TextBox(); this.txtAgvRFID = new System.Windows.Forms.TextBox();
this.groupBox2 = new System.Windows.Forms.GroupBox(); this.groupBox2 = new System.Windows.Forms.GroupBox();
this.label5 = new System.Windows.Forms.Label();
this.TxtCharge7 = new System.Windows.Forms.TextBox();
this.BtnWriteCharge7 = new System.Windows.Forms.Button();
this.BtnReadCharge7 = new System.Windows.Forms.Button();
this.cmbBoxAGVName = new System.Windows.Forms.ComboBox();
this.label3 = new System.Windows.Forms.Label();
this.TxtCharge5 = new System.Windows.Forms.TextBox();
this.BtnReadCharge5 = new System.Windows.Forms.Button();
this.ChkAutoCharge = new System.Windows.Forms.CheckBox(); this.ChkAutoCharge = new System.Windows.Forms.CheckBox();
this.label4 = new System.Windows.Forms.Label();
this.BtnWriteCharge5 = new System.Windows.Forms.Button();
this.TxtCharge6 = new System.Windows.Forms.TextBox();
this.BtnWriteCharge6 = new System.Windows.Forms.Button();
this.BtnReadCharge6 = new System.Windows.Forms.Button();
this.label1 = new System.Windows.Forms.Label();
this.TxtCharge3 = new System.Windows.Forms.TextBox();
this.BtnReadCharge3 = new System.Windows.Forms.Button();
this.label2 = new System.Windows.Forms.Label();
this.BtnWriteCharge3 = new System.Windows.Forms.Button();
this.TxtCharge4 = new System.Windows.Forms.TextBox();
this.BtnWriteCharge4 = new System.Windows.Forms.Button();
this.BtnReadCharge4 = new System.Windows.Forms.Button();
this.BtnClearError = new System.Windows.Forms.Button(); this.BtnClearError = new System.Windows.Forms.Button();
this.BtnMissionAdd = new System.Windows.Forms.Button(); this.BtnMissionAdd = new System.Windows.Forms.Button();
this.BtnMissionPause = new System.Windows.Forms.Button(); this.BtnMissionPause = new System.Windows.Forms.Button();
this.BtnMissionReady = new System.Windows.Forms.Button(); this.BtnMissionReady = new System.Windows.Forms.Button();
this.LstAgvPlace = new System.Windows.Forms.ListBox(); this.LstAgvPlace = new System.Windows.Forms.ListBox();
this.tableLayoutPanel4 = new System.Windows.Forms.TableLayoutPanel(); this.tableLayoutPanel4 = new System.Windows.Forms.TableLayoutPanel();
this.lblWarnMsg = new System.Windows.Forms.Label(); this.tableLayoutPanel6 = new System.Windows.Forms.TableLayoutPanel();
this.lblMsg = new System.Windows.Forms.Label(); this.label6 = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.label4 = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.label1 = new System.Windows.Forms.Label();
this.groupBox7 = new System.Windows.Forms.GroupBox();
this.txtBoxRFID = new System.Windows.Forms.TextBox();
this.btnUpdateStatus = new System.Windows.Forms.Button();
this.Column24 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
((System.ComponentModel.ISupportInitialize)(this.DgvAgv)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.DgvAgv)).BeginInit();
this.tableLayoutPanel3.SuspendLayout(); this.tableLayoutPanel3.SuspendLayout();
this.tabControl1.SuspendLayout(); this.tabControl1.SuspendLayout();
...@@ -113,13 +101,19 @@ ...@@ -113,13 +101,19 @@
this.tableLayoutPanel2.SuspendLayout(); this.tableLayoutPanel2.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.DgvNode)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.DgvNode)).BeginInit();
this.groupBox1.SuspendLayout(); this.groupBox1.SuspendLayout();
this.tableLayoutPanel5.SuspendLayout();
this.groupBox5.SuspendLayout();
this.groupBox3.SuspendLayout();
this.groupBox4.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dgvLineMission)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.dgvLineMission)).BeginInit();
this.tabPage2.SuspendLayout(); this.tabPage2.SuspendLayout();
this.tableLayoutPanel1.SuspendLayout(); this.tableLayoutPanel1.SuspendLayout();
this.flowLayoutPanel1.SuspendLayout();
this.tabPage3.SuspendLayout(); this.tabPage3.SuspendLayout();
this.groupBox6.SuspendLayout();
this.groupBox2.SuspendLayout(); this.groupBox2.SuspendLayout();
this.tableLayoutPanel4.SuspendLayout(); this.tableLayoutPanel4.SuspendLayout();
this.tableLayoutPanel6.SuspendLayout();
this.groupBox7.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
// DgvAgv // DgvAgv
...@@ -128,30 +122,33 @@ ...@@ -128,30 +122,33 @@
this.DgvAgv.AllowUserToDeleteRows = false; this.DgvAgv.AllowUserToDeleteRows = false;
this.DgvAgv.AllowUserToResizeColumns = false; this.DgvAgv.AllowUserToResizeColumns = false;
this.DgvAgv.AllowUserToResizeRows = false; this.DgvAgv.AllowUserToResizeRows = false;
this.DgvAgv.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.DgvAgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.DgvAgv.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.DgvAgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.DgvAgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.DgvAgv.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.DgvAgv.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.Column1, this.Column1,
this.Column2, this.Column2,
this.Column4,
this.Column3, this.Column3,
this.Column21, this.Column21,
this.Column25,
this.Column14,
this.Column18, this.Column18,
this.Column20, this.Column20,
this.Column4,
this.Column23, this.Column23,
this.Column13, this.Column13,
this.Column19, this.Column19,
this.Column11, this.Column11});
this.Column17}); this.DgvAgv.Location = new System.Drawing.Point(4, 4);
this.DgvAgv.Dock = System.Windows.Forms.DockStyle.Fill; this.DgvAgv.Margin = new System.Windows.Forms.Padding(4);
this.DgvAgv.Location = new System.Drawing.Point(3, 3); this.DgvAgv.MultiSelect = false;
this.DgvAgv.Name = "DgvAgv"; this.DgvAgv.Name = "DgvAgv";
this.DgvAgv.ReadOnly = true; this.DgvAgv.ReadOnly = true;
this.DgvAgv.RowHeadersVisible = false; this.DgvAgv.RowHeadersVisible = false;
this.DgvAgv.RowHeadersWidth = 51; this.DgvAgv.RowHeadersWidth = 51;
this.DgvAgv.RowTemplate.Height = 23; this.DgvAgv.RowTemplate.Height = 23;
this.DgvAgv.Size = new System.Drawing.Size(1307, 143); this.DgvAgv.Size = new System.Drawing.Size(1415, 164);
this.DgvAgv.TabIndex = 3; this.DgvAgv.TabIndex = 3;
this.DgvAgv.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.DgvAgv_CellClick); this.DgvAgv.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.DgvAgv_CellClick);
// //
...@@ -162,7 +159,6 @@ ...@@ -162,7 +159,6 @@
this.Column1.Name = "Column1"; this.Column1.Name = "Column1";
this.Column1.ReadOnly = true; this.Column1.ReadOnly = true;
this.Column1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column1.Width = 80;
// //
// Column2 // Column2
// //
...@@ -171,7 +167,14 @@ ...@@ -171,7 +167,14 @@
this.Column2.Name = "Column2"; this.Column2.Name = "Column2";
this.Column2.ReadOnly = true; this.Column2.ReadOnly = true;
this.Column2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column2.Width = 110; //
// Column4
//
this.Column4.HeaderText = "小车状态";
this.Column4.MinimumWidth = 6;
this.Column4.Name = "Column4";
this.Column4.ReadOnly = true;
this.Column4.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
// //
// Column3 // Column3
// //
...@@ -180,7 +183,6 @@ ...@@ -180,7 +183,6 @@
this.Column3.Name = "Column3"; this.Column3.Name = "Column3";
this.Column3.ReadOnly = true; this.Column3.ReadOnly = true;
this.Column3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column3.Width = 60;
// //
// Column21 // Column21
// //
...@@ -188,24 +190,6 @@ ...@@ -188,24 +190,6 @@
this.Column21.MinimumWidth = 6; this.Column21.MinimumWidth = 6;
this.Column21.Name = "Column21"; this.Column21.Name = "Column21";
this.Column21.ReadOnly = true; this.Column21.ReadOnly = true;
this.Column21.Width = 50;
//
// Column25
//
this.Column25.HeaderText = "任务内容";
this.Column25.MinimumWidth = 6;
this.Column25.Name = "Column25";
this.Column25.ReadOnly = true;
this.Column25.Width = 300;
//
// Column14
//
this.Column14.HeaderText = "执行信息";
this.Column14.MinimumWidth = 6;
this.Column14.Name = "Column14";
this.Column14.ReadOnly = true;
this.Column14.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column14.Width = 300;
// //
// Column18 // Column18
// //
...@@ -214,7 +198,6 @@ ...@@ -214,7 +198,6 @@
this.Column18.Name = "Column18"; this.Column18.Name = "Column18";
this.Column18.ReadOnly = true; this.Column18.ReadOnly = true;
this.Column18.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column18.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column18.Width = 80;
// //
// Column20 // Column20
// //
...@@ -222,16 +205,6 @@ ...@@ -222,16 +205,6 @@
this.Column20.MinimumWidth = 6; this.Column20.MinimumWidth = 6;
this.Column20.Name = "Column20"; this.Column20.Name = "Column20";
this.Column20.ReadOnly = true; this.Column20.ReadOnly = true;
this.Column20.Width = 80;
//
// Column4
//
this.Column4.HeaderText = "后续任务";
this.Column4.MinimumWidth = 6;
this.Column4.Name = "Column4";
this.Column4.ReadOnly = true;
this.Column4.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column4.Width = 80;
// //
// Column23 // Column23
// //
...@@ -239,7 +212,6 @@ ...@@ -239,7 +212,6 @@
this.Column23.MinimumWidth = 6; this.Column23.MinimumWidth = 6;
this.Column23.Name = "Column23"; this.Column23.Name = "Column23";
this.Column23.ReadOnly = true; this.Column23.ReadOnly = true;
this.Column23.Width = 60;
// //
// Column13 // Column13
// //
...@@ -248,7 +220,6 @@ ...@@ -248,7 +220,6 @@
this.Column13.Name = "Column13"; this.Column13.Name = "Column13";
this.Column13.ReadOnly = true; this.Column13.ReadOnly = true;
this.Column13.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column13.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column13.Width = 60;
// //
// Column19 // Column19
// //
...@@ -256,23 +227,13 @@ ...@@ -256,23 +227,13 @@
this.Column19.MinimumWidth = 6; this.Column19.MinimumWidth = 6;
this.Column19.Name = "Column19"; this.Column19.Name = "Column19";
this.Column19.ReadOnly = true; this.Column19.ReadOnly = true;
this.Column19.Width = 60;
// //
// Column11 // Column11
// //
this.Column11.HeaderText = "调用"; this.Column11.HeaderText = "自动";
this.Column11.MinimumWidth = 6; this.Column11.MinimumWidth = 6;
this.Column11.Name = "Column11"; this.Column11.Name = "Column11";
this.Column11.ReadOnly = true; this.Column11.ReadOnly = true;
this.Column11.Width = 60;
//
// Column17
//
this.Column17.HeaderText = "清除任务";
this.Column17.MinimumWidth = 6;
this.Column17.Name = "Column17";
this.Column17.ReadOnly = true;
this.Column17.Width = 60;
// //
// tableLayoutPanel3 // tableLayoutPanel3
// //
...@@ -283,13 +244,13 @@ ...@@ -283,13 +244,13 @@
this.tableLayoutPanel3.Controls.Add(this.tableLayoutPanel4, 0, 1); this.tableLayoutPanel3.Controls.Add(this.tableLayoutPanel4, 0, 1);
this.tableLayoutPanel3.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel3.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel3.Location = new System.Drawing.Point(0, 0); this.tableLayoutPanel3.Location = new System.Drawing.Point(0, 0);
this.tableLayoutPanel3.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.tableLayoutPanel3.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.tableLayoutPanel3.Name = "tableLayoutPanel3"; this.tableLayoutPanel3.Name = "tableLayoutPanel3";
this.tableLayoutPanel3.RowCount = 3; this.tableLayoutPanel3.RowCount = 3;
this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 22.72727F)); this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 21.05263F));
this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 9.090909F)); this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 26.31579F));
this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 68.18182F)); this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 52.63158F));
this.tableLayoutPanel3.Size = new System.Drawing.Size(1313, 656); this.tableLayoutPanel3.Size = new System.Drawing.Size(1423, 820);
this.tableLayoutPanel3.TabIndex = 7; this.tableLayoutPanel3.TabIndex = 7;
// //
// tabControl1 // tabControl1
...@@ -298,19 +259,21 @@ ...@@ -298,19 +259,21 @@
this.tabControl1.Controls.Add(this.tabPage2); this.tabControl1.Controls.Add(this.tabPage2);
this.tabControl1.Controls.Add(this.tabPage3); this.tabControl1.Controls.Add(this.tabPage3);
this.tabControl1.Dock = System.Windows.Forms.DockStyle.Fill; this.tabControl1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tabControl1.Location = new System.Drawing.Point(3, 211); this.tabControl1.Location = new System.Drawing.Point(4, 391);
this.tabControl1.Margin = new System.Windows.Forms.Padding(4);
this.tabControl1.Name = "tabControl1"; this.tabControl1.Name = "tabControl1";
this.tabControl1.SelectedIndex = 0; this.tabControl1.SelectedIndex = 0;
this.tabControl1.Size = new System.Drawing.Size(1307, 442); this.tabControl1.Size = new System.Drawing.Size(1415, 425);
this.tabControl1.TabIndex = 7; this.tabControl1.TabIndex = 7;
// //
// tabPage1 // tabPage1
// //
this.tabPage1.Controls.Add(this.tableLayoutPanel2); this.tabPage1.Controls.Add(this.tableLayoutPanel2);
this.tabPage1.Location = new System.Drawing.Point(4, 22); this.tabPage1.Location = new System.Drawing.Point(4, 25);
this.tabPage1.Margin = new System.Windows.Forms.Padding(4);
this.tabPage1.Name = "tabPage1"; this.tabPage1.Name = "tabPage1";
this.tabPage1.Padding = new System.Windows.Forms.Padding(3, 3, 3, 3); this.tabPage1.Padding = new System.Windows.Forms.Padding(4);
this.tabPage1.Size = new System.Drawing.Size(1299, 416); this.tabPage1.Size = new System.Drawing.Size(1407, 396);
this.tabPage1.TabIndex = 0; this.tabPage1.TabIndex = 0;
this.tabPage1.Text = "节点状态&产线任务"; this.tabPage1.Text = "节点状态&产线任务";
this.tabPage1.UseVisualStyleBackColor = true; this.tabPage1.UseVisualStyleBackColor = true;
...@@ -318,17 +281,17 @@ ...@@ -318,17 +281,17 @@
// tableLayoutPanel2 // tableLayoutPanel2
// //
this.tableLayoutPanel2.ColumnCount = 2; this.tableLayoutPanel2.ColumnCount = 2;
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 69.9422F)); this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 56.39743F));
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 30.0578F)); this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 43.60257F));
this.tableLayoutPanel2.Controls.Add(this.DgvNode, 0, 0); this.tableLayoutPanel2.Controls.Add(this.DgvNode, 0, 0);
this.tableLayoutPanel2.Controls.Add(this.groupBox1, 1, 0); this.tableLayoutPanel2.Controls.Add(this.groupBox1, 1, 0);
this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel2.Location = new System.Drawing.Point(3, 3); this.tableLayoutPanel2.Location = new System.Drawing.Point(4, 4);
this.tableLayoutPanel2.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.tableLayoutPanel2.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.tableLayoutPanel2.Name = "tableLayoutPanel2"; this.tableLayoutPanel2.Name = "tableLayoutPanel2";
this.tableLayoutPanel2.RowCount = 1; this.tableLayoutPanel2.RowCount = 1;
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.Size = new System.Drawing.Size(1293, 410); this.tableLayoutPanel2.Size = new System.Drawing.Size(1399, 388);
this.tableLayoutPanel2.TabIndex = 34; this.tableLayoutPanel2.TabIndex = 34;
// //
// DgvNode // DgvNode
...@@ -337,152 +300,212 @@ ...@@ -337,152 +300,212 @@
this.DgvNode.AllowUserToDeleteRows = false; this.DgvNode.AllowUserToDeleteRows = false;
this.DgvNode.AllowUserToResizeColumns = false; this.DgvNode.AllowUserToResizeColumns = false;
this.DgvNode.AllowUserToResizeRows = false; this.DgvNode.AllowUserToResizeRows = false;
this.DgvNode.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.DgvNode.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
this.DgvNode.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells;
this.DgvNode.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; this.DgvNode.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.DgvNode.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.DgvNode.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.Column6, this.Column6,
this.Column12, this.Column12,
this.Column22, this.Column22,
this.Column7, this.Column7,
this.Column9,
this.Column10, this.Column10,
this.Column9,
this.Column5, this.Column5,
this.Column16, this.Column16});
this.Column15}); this.DgvNode.Location = new System.Drawing.Point(4, 4);
this.DgvNode.Dock = System.Windows.Forms.DockStyle.Fill; this.DgvNode.Margin = new System.Windows.Forms.Padding(4);
this.DgvNode.Location = new System.Drawing.Point(3, 3); this.DgvNode.MultiSelect = false;
this.DgvNode.Name = "DgvNode"; this.DgvNode.Name = "DgvNode";
this.DgvNode.ReadOnly = true; this.DgvNode.ReadOnly = true;
this.DgvNode.RowHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.Single;
this.DgvNode.RowHeadersVisible = false; this.DgvNode.RowHeadersVisible = false;
this.DgvNode.RowHeadersWidth = 50; this.DgvNode.RowHeadersWidth = 50;
this.DgvNode.RowTemplate.Height = 23; this.DgvNode.RowTemplate.Height = 23;
this.DgvNode.Size = new System.Drawing.Size(898, 404); this.DgvNode.Size = new System.Drawing.Size(781, 380);
this.DgvNode.TabIndex = 1; this.DgvNode.TabIndex = 1;
this.DgvNode.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.DgvNode_CellClick); this.DgvNode.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.DgvNode_CellClick);
// //
// Column6 // Column6
// //
this.Column6.FillWeight = 107.563F;
this.Column6.HeaderText = "地点"; this.Column6.HeaderText = "地点";
this.Column6.MinimumWidth = 6; this.Column6.MinimumWidth = 6;
this.Column6.Name = "Column6"; this.Column6.Name = "Column6";
this.Column6.ReadOnly = true; this.Column6.ReadOnly = true;
this.Column6.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column6.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column6.Width = 125;
// //
// Column12 // Column12
// //
this.Column12.FillWeight = 107.563F;
this.Column12.HeaderText = "IP"; this.Column12.HeaderText = "IP";
this.Column12.MinimumWidth = 6; this.Column12.MinimumWidth = 6;
this.Column12.Name = "Column12"; this.Column12.Name = "Column12";
this.Column12.ReadOnly = true; this.Column12.ReadOnly = true;
this.Column12.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column12.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column12.Width = 125;
// //
// Column22 // Column22
// //
this.Column22.HeaderText = "解绑数量"; this.Column22.FillWeight = 107.563F;
this.Column22.HeaderText = "解绑数";
this.Column22.MinimumWidth = 6; this.Column22.MinimumWidth = 6;
this.Column22.Name = "Column22"; this.Column22.Name = "Column22";
this.Column22.ReadOnly = true; this.Column22.ReadOnly = true;
this.Column22.Width = 80; this.Column22.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
// //
// Column7 // Column7
// //
this.Column7.FillWeight = 107.563F;
this.Column7.HeaderText = "动作"; this.Column7.HeaderText = "动作";
this.Column7.MinimumWidth = 6; this.Column7.MinimumWidth = 6;
this.Column7.Name = "Column7"; this.Column7.Name = "Column7";
this.Column7.ReadOnly = true; this.Column7.ReadOnly = true;
this.Column7.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column7.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column7.Width = 125; //
// Column10
//
this.Column10.FillWeight = 47.05883F;
this.Column10.HeaderText = "等级";
this.Column10.MinimumWidth = 6;
this.Column10.Name = "Column10";
this.Column10.ReadOnly = true;
// //
// Column9 // Column9
// //
this.Column9.FillWeight = 107.563F;
this.Column9.HeaderText = "RFID"; this.Column9.HeaderText = "RFID";
this.Column9.MinimumWidth = 6; this.Column9.MinimumWidth = 6;
this.Column9.Name = "Column9"; this.Column9.Name = "Column9";
this.Column9.ReadOnly = true; this.Column9.ReadOnly = true;
this.Column9.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column9.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column9.Width = 125;
//
// Column10
//
this.Column10.HeaderText = "AGV名称";
this.Column10.MinimumWidth = 6;
this.Column10.Name = "Column10";
this.Column10.ReadOnly = true;
this.Column10.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column10.Width = 125;
// //
// Column5 // Column5
// //
this.Column5.FillWeight = 107.563F;
this.Column5.HeaderText = "连接"; this.Column5.HeaderText = "连接";
this.Column5.MinimumWidth = 6; this.Column5.MinimumWidth = 6;
this.Column5.Name = "Column5"; this.Column5.Name = "Column5";
this.Column5.ReadOnly = true; this.Column5.ReadOnly = true;
this.Column5.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; this.Column5.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
this.Column5.Width = 60;
// //
// Column16 // Column16
// //
this.Column16.FillWeight = 107.563F;
this.Column16.HeaderText = "调用"; this.Column16.HeaderText = "调用";
this.Column16.MinimumWidth = 6; this.Column16.MinimumWidth = 6;
this.Column16.Name = "Column16"; this.Column16.Name = "Column16";
this.Column16.ReadOnly = true; this.Column16.ReadOnly = true;
this.Column16.Width = 60;
//
// Column15
//
this.Column15.HeaderText = "清除AGV";
this.Column15.MinimumWidth = 6;
this.Column15.Name = "Column15";
this.Column15.ReadOnly = true;
this.Column15.Width = 80;
// //
// groupBox1 // groupBox1
// //
this.groupBox1.Controls.Add(this.btnAddMission); this.groupBox1.Controls.Add(this.tableLayoutPanel5);
this.groupBox1.Controls.Add(this.cmbBoxLineName);
this.groupBox1.Controls.Add(this.btnDeleteMission);
this.groupBox1.Controls.Add(this.dgvLineMission);
this.groupBox1.Dock = System.Windows.Forms.DockStyle.Fill; this.groupBox1.Dock = System.Windows.Forms.DockStyle.Fill;
this.groupBox1.Location = new System.Drawing.Point(906, 2); this.groupBox1.Font = new System.Drawing.Font("宋体", 10.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.groupBox1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.groupBox1.Location = new System.Drawing.Point(792, 2);
this.groupBox1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupBox1.Name = "groupBox1"; this.groupBox1.Name = "groupBox1";
this.groupBox1.Padding = new System.Windows.Forms.Padding(2, 2, 2, 2); this.groupBox1.Padding = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupBox1.Size = new System.Drawing.Size(385, 406); this.groupBox1.Size = new System.Drawing.Size(604, 384);
this.groupBox1.TabIndex = 33; this.groupBox1.TabIndex = 33;
this.groupBox1.TabStop = false; this.groupBox1.TabStop = false;
this.groupBox1.Text = "产线任务"; this.groupBox1.Text = "任务信息";
// //
// btnAddMission // tableLayoutPanel5
// //
this.btnAddMission.Location = new System.Drawing.Point(296, 220); this.tableLayoutPanel5.ColumnCount = 1;
this.btnAddMission.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.tableLayoutPanel5.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.btnAddMission.Name = "btnAddMission"; this.tableLayoutPanel5.Controls.Add(this.groupBox5, 0, 1);
this.btnAddMission.Size = new System.Drawing.Size(75, 38); this.tableLayoutPanel5.Controls.Add(this.groupBox3, 0, 0);
this.btnAddMission.TabIndex = 39; this.tableLayoutPanel5.Controls.Add(this.groupBox4, 0, 2);
this.btnAddMission.Text = "添加任务"; this.tableLayoutPanel5.Dock = System.Windows.Forms.DockStyle.Fill;
this.btnAddMission.UseVisualStyleBackColor = true; this.tableLayoutPanel5.Location = new System.Drawing.Point(3, 23);
this.btnAddMission.Click += new System.EventHandler(this.btnAddMission_Click); this.tableLayoutPanel5.Name = "tableLayoutPanel5";
// this.tableLayoutPanel5.RowCount = 3;
// cmbBoxLineName this.tableLayoutPanel5.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 15F));
// this.tableLayoutPanel5.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 15F));
this.cmbBoxLineName.FormattingEnabled = true; this.tableLayoutPanel5.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 70F));
this.cmbBoxLineName.Location = new System.Drawing.Point(292, 81); this.tableLayoutPanel5.Size = new System.Drawing.Size(598, 359);
this.cmbBoxLineName.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.tableLayoutPanel5.TabIndex = 2;
this.cmbBoxLineName.Name = "cmbBoxLineName"; //
this.cmbBoxLineName.Size = new System.Drawing.Size(92, 20); // groupBox5
this.cmbBoxLineName.TabIndex = 38; //
// this.groupBox5.Controls.Add(this.lblDestInfo);
// btnDeleteMission this.groupBox5.Dock = System.Windows.Forms.DockStyle.Fill;
// this.groupBox5.Location = new System.Drawing.Point(3, 56);
this.btnDeleteMission.Location = new System.Drawing.Point(296, 140); this.groupBox5.Name = "groupBox5";
this.btnDeleteMission.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.groupBox5.Size = new System.Drawing.Size(592, 47);
this.btnDeleteMission.Name = "btnDeleteMission"; this.groupBox5.TabIndex = 2;
this.btnDeleteMission.Size = new System.Drawing.Size(75, 38); this.groupBox5.TabStop = false;
this.btnDeleteMission.TabIndex = 35; this.groupBox5.Text = "出料信息信息";
this.btnDeleteMission.Text = "删除任务"; //
this.btnDeleteMission.UseVisualStyleBackColor = true; // lblDestInfo
this.btnDeleteMission.Click += new System.EventHandler(this.btnDeleteMission_Click); //
this.lblDestInfo.Dock = System.Windows.Forms.DockStyle.Fill;
this.lblDestInfo.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblDestInfo.Location = new System.Drawing.Point(3, 24);
this.lblDestInfo.Name = "lblDestInfo";
this.lblDestInfo.Size = new System.Drawing.Size(586, 20);
this.lblDestInfo.TabIndex = 40;
this.lblDestInfo.Text = "lblDestInfo";
//
// groupBox3
//
this.groupBox3.Controls.Add(this.lblWO);
this.groupBox3.Dock = System.Windows.Forms.DockStyle.Fill;
this.groupBox3.Location = new System.Drawing.Point(3, 3);
this.groupBox3.Name = "groupBox3";
this.groupBox3.Size = new System.Drawing.Size(592, 47);
this.groupBox3.TabIndex = 0;
this.groupBox3.TabStop = false;
this.groupBox3.Text = "双层线工单信息";
//
// lblWO
//
this.lblWO.Dock = System.Windows.Forms.DockStyle.Fill;
this.lblWO.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblWO.Location = new System.Drawing.Point(3, 24);
this.lblWO.Name = "lblWO";
this.lblWO.Size = new System.Drawing.Size(586, 20);
this.lblWO.TabIndex = 40;
this.lblWO.Text = "lblWO";
//
// groupBox4
//
this.groupBox4.Controls.Add(this.button5);
this.groupBox4.Controls.Add(this.btnWO);
this.groupBox4.Controls.Add(this.dgvLineMission);
this.groupBox4.Dock = System.Windows.Forms.DockStyle.Fill;
this.groupBox4.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.groupBox4.Location = new System.Drawing.Point(3, 109);
this.groupBox4.Name = "groupBox4";
this.groupBox4.Size = new System.Drawing.Size(592, 247);
this.groupBox4.TabIndex = 1;
this.groupBox4.TabStop = false;
this.groupBox4.Text = "产线解绑信息";
//
// button5
//
this.button5.Location = new System.Drawing.Point(456, 105);
this.button5.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.button5.Name = "button5";
this.button5.Size = new System.Drawing.Size(100, 65);
this.button5.TabIndex = 41;
this.button5.Text = "出料查询";
this.button5.UseVisualStyleBackColor = true;
this.button5.Click += new System.EventHandler(this.button5_Click);
//
// btnWO
//
this.btnWO.Location = new System.Drawing.Point(456, 23);
this.btnWO.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.btnWO.Name = "btnWO";
this.btnWO.Size = new System.Drawing.Size(100, 65);
this.btnWO.TabIndex = 40;
this.btnWO.Text = "工单查询";
this.btnWO.UseVisualStyleBackColor = true;
this.btnWO.Click += new System.EventHandler(this.btnWO_Click);
// //
// dgvLineMission // dgvLineMission
// //
...@@ -492,101 +515,57 @@ ...@@ -492,101 +515,57 @@
this.Column24, this.Column24,
this.Column8}); this.Column8});
this.dgvLineMission.Dock = System.Windows.Forms.DockStyle.Left; this.dgvLineMission.Dock = System.Windows.Forms.DockStyle.Left;
this.dgvLineMission.Location = new System.Drawing.Point(2, 16); this.dgvLineMission.Location = new System.Drawing.Point(3, 21);
this.dgvLineMission.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.dgvLineMission.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.dgvLineMission.Name = "dgvLineMission"; this.dgvLineMission.Name = "dgvLineMission";
this.dgvLineMission.RowHeadersVisible = false; this.dgvLineMission.RowHeadersVisible = false;
this.dgvLineMission.RowHeadersWidth = 51; this.dgvLineMission.RowHeadersWidth = 51;
this.dgvLineMission.RowTemplate.Height = 27; this.dgvLineMission.RowTemplate.Height = 27;
this.dgvLineMission.Size = new System.Drawing.Size(290, 388); this.dgvLineMission.Size = new System.Drawing.Size(367, 223);
this.dgvLineMission.TabIndex = 28; this.dgvLineMission.TabIndex = 28;
// //
// Column24
//
this.Column24.HeaderText = "时间";
this.Column24.MinimumWidth = 6;
this.Column24.Name = "Column24";
this.Column24.Width = 180;
//
// Column8
//
this.Column8.HeaderText = "任务";
this.Column8.MinimumWidth = 6;
this.Column8.Name = "Column8";
this.Column8.Width = 80;
//
// tabPage2 // tabPage2
// //
this.tabPage2.Controls.Add(this.tableLayoutPanel1); this.tabPage2.Controls.Add(this.tableLayoutPanel1);
this.tabPage2.Location = new System.Drawing.Point(4, 22); this.tabPage2.Location = new System.Drawing.Point(4, 25);
this.tabPage2.Margin = new System.Windows.Forms.Padding(4);
this.tabPage2.Name = "tabPage2"; this.tabPage2.Name = "tabPage2";
this.tabPage2.Padding = new System.Windows.Forms.Padding(3, 3, 3, 3); this.tabPage2.Padding = new System.Windows.Forms.Padding(4);
this.tabPage2.Size = new System.Drawing.Size(1299, 416); this.tabPage2.Size = new System.Drawing.Size(1407, 396);
this.tabPage2.TabIndex = 3; this.tabPage2.TabIndex = 3;
this.tabPage2.Text = "日志"; this.tabPage2.Text = "日志";
this.tabPage2.UseVisualStyleBackColor = true; this.tabPage2.UseVisualStyleBackColor = true;
// //
// tableLayoutPanel1 // tableLayoutPanel1
// //
this.tableLayoutPanel1.ColumnCount = 2; this.tableLayoutPanel1.ColumnCount = 1;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 43.32172F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 56.67828F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20F));
this.tableLayoutPanel1.Controls.Add(this.TxtLog, 0, 0); this.tableLayoutPanel1.Controls.Add(this.TxtLog, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.flowLayoutPanel1, 1, 0);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(3, 3); this.tableLayoutPanel1.Location = new System.Drawing.Point(4, 4);
this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.tableLayoutPanel1.Name = "tableLayoutPanel1"; this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 1; this.tableLayoutPanel1.RowCount = 1;
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 388F)); this.tableLayoutPanel1.Size = new System.Drawing.Size(1399, 388);
this.tableLayoutPanel1.Size = new System.Drawing.Size(1293, 410);
this.tableLayoutPanel1.TabIndex = 6; this.tableLayoutPanel1.TabIndex = 6;
// //
// TxtLog // TxtLog
// //
this.TxtLog.Dock = System.Windows.Forms.DockStyle.Fill; this.TxtLog.Dock = System.Windows.Forms.DockStyle.Fill;
this.TxtLog.Location = new System.Drawing.Point(3, 3); this.TxtLog.Location = new System.Drawing.Point(4, 4);
this.TxtLog.Margin = new System.Windows.Forms.Padding(4);
this.TxtLog.Multiline = true; this.TxtLog.Multiline = true;
this.TxtLog.Name = "TxtLog"; this.TxtLog.Name = "TxtLog";
this.TxtLog.ScrollBars = System.Windows.Forms.ScrollBars.Both; this.TxtLog.ScrollBars = System.Windows.Forms.ScrollBars.Both;
this.TxtLog.Size = new System.Drawing.Size(554, 404); this.TxtLog.Size = new System.Drawing.Size(1391, 380);
this.TxtLog.TabIndex = 5; this.TxtLog.TabIndex = 5;
// //
// flowLayoutPanel1
//
this.flowLayoutPanel1.Controls.Add(this.lblVMIGetBoxDestInfo);
this.flowLayoutPanel1.Controls.Add(this.lblGetRack);
this.flowLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.flowLayoutPanel1.Location = new System.Drawing.Point(562, 2);
this.flowLayoutPanel1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.flowLayoutPanel1.Name = "flowLayoutPanel1";
this.flowLayoutPanel1.Size = new System.Drawing.Size(729, 406);
this.flowLayoutPanel1.TabIndex = 6;
//
// lblVMIGetBoxDestInfo
//
this.lblVMIGetBoxDestInfo.AutoSize = true;
this.lblVMIGetBoxDestInfo.Location = new System.Drawing.Point(2, 0);
this.lblVMIGetBoxDestInfo.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.lblVMIGetBoxDestInfo.Name = "lblVMIGetBoxDestInfo";
this.lblVMIGetBoxDestInfo.Size = new System.Drawing.Size(47, 12);
this.lblVMIGetBoxDestInfo.TabIndex = 0;
this.lblVMIGetBoxDestInfo.Text = "BoxDest";
//
// lblGetRack
//
this.lblGetRack.AutoSize = true;
this.lblGetRack.Location = new System.Drawing.Point(53, 0);
this.lblGetRack.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.lblGetRack.Name = "lblGetRack";
this.lblGetRack.Size = new System.Drawing.Size(47, 12);
this.lblGetRack.TabIndex = 1;
this.lblGetRack.Text = "GetRack";
//
// tabPage3 // tabPage3
// //
this.tabPage3.Controls.Add(this.button1); this.tabPage3.Controls.Add(this.groupBox7);
this.tabPage3.Controls.Add(this.groupBox6);
this.tabPage3.Controls.Add(this.btnSetRFID); this.tabPage3.Controls.Add(this.btnSetRFID);
this.tabPage3.Controls.Add(this.txtAgvRFID); this.tabPage3.Controls.Add(this.txtAgvRFID);
this.tabPage3.Controls.Add(this.groupBox2); this.tabPage3.Controls.Add(this.groupBox2);
...@@ -595,30 +574,64 @@ ...@@ -595,30 +574,64 @@
this.tabPage3.Controls.Add(this.BtnMissionPause); this.tabPage3.Controls.Add(this.BtnMissionPause);
this.tabPage3.Controls.Add(this.BtnMissionReady); this.tabPage3.Controls.Add(this.BtnMissionReady);
this.tabPage3.Controls.Add(this.LstAgvPlace); this.tabPage3.Controls.Add(this.LstAgvPlace);
this.tabPage3.Location = new System.Drawing.Point(4, 22); this.tabPage3.Location = new System.Drawing.Point(4, 25);
this.tabPage3.Margin = new System.Windows.Forms.Padding(4);
this.tabPage3.Name = "tabPage3"; this.tabPage3.Name = "tabPage3";
this.tabPage3.Padding = new System.Windows.Forms.Padding(3, 3, 3, 3); this.tabPage3.Padding = new System.Windows.Forms.Padding(4);
this.tabPage3.Size = new System.Drawing.Size(1299, 416); this.tabPage3.Size = new System.Drawing.Size(1407, 396);
this.tabPage3.TabIndex = 2; this.tabPage3.TabIndex = 2;
this.tabPage3.Text = "agv手动"; this.tabPage3.Text = "agv手动";
this.tabPage3.UseVisualStyleBackColor = true; this.tabPage3.UseVisualStyleBackColor = true;
// //
// button1 // groupBox6
//
this.groupBox6.Controls.Add(this.btnDeleteMission);
this.groupBox6.Controls.Add(this.btnAddMission);
this.groupBox6.Controls.Add(this.cmbBoxLineName);
this.groupBox6.Location = new System.Drawing.Point(396, 26);
this.groupBox6.Name = "groupBox6";
this.groupBox6.Size = new System.Drawing.Size(255, 155);
this.groupBox6.TabIndex = 35;
this.groupBox6.TabStop = false;
this.groupBox6.Text = "产线解绑";
//
// btnDeleteMission
//
this.btnDeleteMission.Location = new System.Drawing.Point(122, 62);
this.btnDeleteMission.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.btnDeleteMission.Name = "btnDeleteMission";
this.btnDeleteMission.Size = new System.Drawing.Size(100, 65);
this.btnDeleteMission.TabIndex = 41;
this.btnDeleteMission.Text = "删除任务";
this.btnDeleteMission.UseVisualStyleBackColor = true;
this.btnDeleteMission.Click += new System.EventHandler(this.btnDeleteMission_Click);
//
// btnAddMission
// //
this.button1.Location = new System.Drawing.Point(474, 68); this.btnAddMission.Location = new System.Drawing.Point(6, 62);
this.button1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.btnAddMission.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.button1.Name = "button1"; this.btnAddMission.Name = "btnAddMission";
this.button1.Size = new System.Drawing.Size(82, 35); this.btnAddMission.Size = new System.Drawing.Size(100, 65);
this.button1.TabIndex = 35; this.btnAddMission.TabIndex = 40;
this.button1.Text = "设置负载信号"; this.btnAddMission.Text = "添加任务";
this.button1.UseVisualStyleBackColor = true; this.btnAddMission.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click); this.btnAddMission.Click += new System.EventHandler(this.btnAddMission_Click);
//
// cmbBoxLineName
//
this.cmbBoxLineName.FormattingEnabled = true;
this.cmbBoxLineName.Location = new System.Drawing.Point(6, 23);
this.cmbBoxLineName.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.cmbBoxLineName.Name = "cmbBoxLineName";
this.cmbBoxLineName.Size = new System.Drawing.Size(181, 23);
this.cmbBoxLineName.TabIndex = 39;
// //
// btnSetRFID // btnSetRFID
// //
this.btnSetRFID.Location = new System.Drawing.Point(336, 68); this.btnSetRFID.Location = new System.Drawing.Point(227, 57);
this.btnSetRFID.Margin = new System.Windows.Forms.Padding(4);
this.btnSetRFID.Name = "btnSetRFID"; this.btnSetRFID.Name = "btnSetRFID";
this.btnSetRFID.Size = new System.Drawing.Size(75, 35); this.btnSetRFID.Size = new System.Drawing.Size(100, 44);
this.btnSetRFID.TabIndex = 34; this.btnSetRFID.TabIndex = 34;
this.btnSetRFID.Text = "设置RFID"; this.btnSetRFID.Text = "设置RFID";
this.btnSetRFID.UseVisualStyleBackColor = true; this.btnSetRFID.UseVisualStyleBackColor = true;
...@@ -626,240 +639,42 @@ ...@@ -626,240 +639,42 @@
// //
// txtAgvRFID // txtAgvRFID
// //
this.txtAgvRFID.Location = new System.Drawing.Point(336, 27); this.txtAgvRFID.Location = new System.Drawing.Point(227, 26);
this.txtAgvRFID.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.txtAgvRFID.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.txtAgvRFID.Name = "txtAgvRFID"; this.txtAgvRFID.Name = "txtAgvRFID";
this.txtAgvRFID.Size = new System.Drawing.Size(76, 21); this.txtAgvRFID.Size = new System.Drawing.Size(100, 25);
this.txtAgvRFID.TabIndex = 33; this.txtAgvRFID.TabIndex = 33;
// //
// groupBox2 // groupBox2
// //
this.groupBox2.Controls.Add(this.label5);
this.groupBox2.Controls.Add(this.TxtCharge7);
this.groupBox2.Controls.Add(this.BtnWriteCharge7);
this.groupBox2.Controls.Add(this.BtnReadCharge7);
this.groupBox2.Controls.Add(this.cmbBoxAGVName);
this.groupBox2.Controls.Add(this.label3);
this.groupBox2.Controls.Add(this.TxtCharge5);
this.groupBox2.Controls.Add(this.BtnReadCharge5);
this.groupBox2.Controls.Add(this.ChkAutoCharge); this.groupBox2.Controls.Add(this.ChkAutoCharge);
this.groupBox2.Controls.Add(this.label4); this.groupBox2.Location = new System.Drawing.Point(1088, 30);
this.groupBox2.Controls.Add(this.BtnWriteCharge5); this.groupBox2.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupBox2.Controls.Add(this.TxtCharge6);
this.groupBox2.Controls.Add(this.BtnWriteCharge6);
this.groupBox2.Controls.Add(this.BtnReadCharge6);
this.groupBox2.Controls.Add(this.label1);
this.groupBox2.Controls.Add(this.TxtCharge3);
this.groupBox2.Controls.Add(this.BtnReadCharge3);
this.groupBox2.Controls.Add(this.label2);
this.groupBox2.Controls.Add(this.BtnWriteCharge3);
this.groupBox2.Controls.Add(this.TxtCharge4);
this.groupBox2.Controls.Add(this.BtnWriteCharge4);
this.groupBox2.Controls.Add(this.BtnReadCharge4);
this.groupBox2.Location = new System.Drawing.Point(727, 27);
this.groupBox2.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.groupBox2.Name = "groupBox2"; this.groupBox2.Name = "groupBox2";
this.groupBox2.Padding = new System.Windows.Forms.Padding(2, 2, 2, 2); this.groupBox2.Padding = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.groupBox2.Size = new System.Drawing.Size(548, 247); this.groupBox2.Size = new System.Drawing.Size(157, 71);
this.groupBox2.TabIndex = 32; this.groupBox2.TabIndex = 32;
this.groupBox2.TabStop = false; this.groupBox2.TabStop = false;
this.groupBox2.Text = "充电"; this.groupBox2.Text = "充电";
// //
// label5
//
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(446, 102);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(47, 12);
this.label5.TabIndex = 31;
this.label5.Text = "充电桩7";
//
// TxtCharge7
//
this.TxtCharge7.Location = new System.Drawing.Point(443, 117);
this.TxtCharge7.Name = "TxtCharge7";
this.TxtCharge7.Size = new System.Drawing.Size(96, 21);
this.TxtCharge7.TabIndex = 28;
//
// BtnWriteCharge7
//
this.BtnWriteCharge7.Location = new System.Drawing.Point(443, 180);
this.BtnWriteCharge7.Name = "BtnWriteCharge7";
this.BtnWriteCharge7.Size = new System.Drawing.Size(96, 30);
this.BtnWriteCharge7.TabIndex = 30;
this.BtnWriteCharge7.Text = "写";
this.BtnWriteCharge7.UseVisualStyleBackColor = true;
//
// BtnReadCharge7
//
this.BtnReadCharge7.Location = new System.Drawing.Point(443, 143);
this.BtnReadCharge7.Name = "BtnReadCharge7";
this.BtnReadCharge7.Size = new System.Drawing.Size(96, 30);
this.BtnReadCharge7.TabIndex = 29;
this.BtnReadCharge7.Text = "读";
this.BtnReadCharge7.UseVisualStyleBackColor = true;
//
// cmbBoxAGVName
//
this.cmbBoxAGVName.FormattingEnabled = true;
this.cmbBoxAGVName.Location = new System.Drawing.Point(50, 51);
this.cmbBoxAGVName.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.cmbBoxAGVName.Name = "cmbBoxAGVName";
this.cmbBoxAGVName.Size = new System.Drawing.Size(92, 20);
this.cmbBoxAGVName.TabIndex = 27;
this.cmbBoxAGVName.SelectedIndexChanged += new System.EventHandler(this.cmbBoxAGVName_SelectedIndexChanged);
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(226, 102);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(47, 12);
this.label3.TabIndex = 25;
this.label3.Text = "充电桩5";
//
// TxtCharge5
//
this.TxtCharge5.Location = new System.Drawing.Point(223, 117);
this.TxtCharge5.Name = "TxtCharge5";
this.TxtCharge5.Size = new System.Drawing.Size(96, 21);
this.TxtCharge5.TabIndex = 19;
//
// BtnReadCharge5
//
this.BtnReadCharge5.Location = new System.Drawing.Point(223, 143);
this.BtnReadCharge5.Name = "BtnReadCharge5";
this.BtnReadCharge5.Size = new System.Drawing.Size(96, 30);
this.BtnReadCharge5.TabIndex = 20;
this.BtnReadCharge5.Text = "读";
this.BtnReadCharge5.UseVisualStyleBackColor = true;
//
// ChkAutoCharge // ChkAutoCharge
// //
this.ChkAutoCharge.AutoSize = true; this.ChkAutoCharge.AutoSize = true;
this.ChkAutoCharge.Location = new System.Drawing.Point(38, 20); this.ChkAutoCharge.Location = new System.Drawing.Point(18, 27);
this.ChkAutoCharge.Margin = new System.Windows.Forms.Padding(4);
this.ChkAutoCharge.Name = "ChkAutoCharge"; this.ChkAutoCharge.Name = "ChkAutoCharge";
this.ChkAutoCharge.Size = new System.Drawing.Size(72, 16); this.ChkAutoCharge.Size = new System.Drawing.Size(89, 19);
this.ChkAutoCharge.TabIndex = 10; this.ChkAutoCharge.TabIndex = 10;
this.ChkAutoCharge.Text = "自动充电"; this.ChkAutoCharge.Text = "自动充电";
this.ChkAutoCharge.UseVisualStyleBackColor = true; this.ChkAutoCharge.UseVisualStyleBackColor = true;
// this.ChkAutoCharge.CheckedChanged += new System.EventHandler(this.ChkAutoCharge_CheckedChanged);
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(328, 102);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(47, 12);
this.label4.TabIndex = 26;
this.label4.Text = "充电桩6";
//
// BtnWriteCharge5
//
this.BtnWriteCharge5.Location = new System.Drawing.Point(223, 180);
this.BtnWriteCharge5.Name = "BtnWriteCharge5";
this.BtnWriteCharge5.Size = new System.Drawing.Size(96, 30);
this.BtnWriteCharge5.TabIndex = 21;
this.BtnWriteCharge5.Text = "写";
this.BtnWriteCharge5.UseVisualStyleBackColor = true;
//
// TxtCharge6
//
this.TxtCharge6.Location = new System.Drawing.Point(325, 117);
this.TxtCharge6.Name = "TxtCharge6";
this.TxtCharge6.Size = new System.Drawing.Size(96, 21);
this.TxtCharge6.TabIndex = 22;
//
// BtnWriteCharge6
//
this.BtnWriteCharge6.Location = new System.Drawing.Point(325, 180);
this.BtnWriteCharge6.Name = "BtnWriteCharge6";
this.BtnWriteCharge6.Size = new System.Drawing.Size(96, 30);
this.BtnWriteCharge6.TabIndex = 24;
this.BtnWriteCharge6.Text = "写";
this.BtnWriteCharge6.UseVisualStyleBackColor = true;
//
// BtnReadCharge6
//
this.BtnReadCharge6.Location = new System.Drawing.Point(325, 143);
this.BtnReadCharge6.Name = "BtnReadCharge6";
this.BtnReadCharge6.Size = new System.Drawing.Size(96, 30);
this.BtnReadCharge6.TabIndex = 23;
this.BtnReadCharge6.Text = "读";
this.BtnReadCharge6.UseVisualStyleBackColor = true;
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(22, 102);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(47, 12);
this.label1.TabIndex = 17;
this.label1.Text = "充电桩3";
//
// TxtCharge3
//
this.TxtCharge3.Location = new System.Drawing.Point(19, 117);
this.TxtCharge3.Name = "TxtCharge3";
this.TxtCharge3.Size = new System.Drawing.Size(96, 21);
this.TxtCharge3.TabIndex = 11;
//
// BtnReadCharge3
//
this.BtnReadCharge3.Location = new System.Drawing.Point(19, 143);
this.BtnReadCharge3.Name = "BtnReadCharge3";
this.BtnReadCharge3.Size = new System.Drawing.Size(96, 30);
this.BtnReadCharge3.TabIndex = 12;
this.BtnReadCharge3.Text = "读";
this.BtnReadCharge3.UseVisualStyleBackColor = true;
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(124, 102);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(47, 12);
this.label2.TabIndex = 18;
this.label2.Text = "充电桩4";
//
// BtnWriteCharge3
//
this.BtnWriteCharge3.Location = new System.Drawing.Point(19, 180);
this.BtnWriteCharge3.Name = "BtnWriteCharge3";
this.BtnWriteCharge3.Size = new System.Drawing.Size(96, 30);
this.BtnWriteCharge3.TabIndex = 13;
this.BtnWriteCharge3.Text = "写";
this.BtnWriteCharge3.UseVisualStyleBackColor = true;
//
// TxtCharge4
//
this.TxtCharge4.Location = new System.Drawing.Point(121, 117);
this.TxtCharge4.Name = "TxtCharge4";
this.TxtCharge4.Size = new System.Drawing.Size(96, 21);
this.TxtCharge4.TabIndex = 14;
//
// BtnWriteCharge4
//
this.BtnWriteCharge4.Location = new System.Drawing.Point(121, 180);
this.BtnWriteCharge4.Name = "BtnWriteCharge4";
this.BtnWriteCharge4.Size = new System.Drawing.Size(96, 30);
this.BtnWriteCharge4.TabIndex = 16;
this.BtnWriteCharge4.Text = "写";
this.BtnWriteCharge4.UseVisualStyleBackColor = true;
//
// BtnReadCharge4
//
this.BtnReadCharge4.Location = new System.Drawing.Point(121, 143);
this.BtnReadCharge4.Name = "BtnReadCharge4";
this.BtnReadCharge4.Size = new System.Drawing.Size(96, 30);
this.BtnReadCharge4.TabIndex = 15;
this.BtnReadCharge4.Text = "读";
this.BtnReadCharge4.UseVisualStyleBackColor = true;
// //
// BtnClearError // BtnClearError
// //
this.BtnClearError.Location = new System.Drawing.Point(577, 206); this.BtnClearError.Location = new System.Drawing.Point(227, 301);
this.BtnClearError.Margin = new System.Windows.Forms.Padding(4);
this.BtnClearError.Name = "BtnClearError"; this.BtnClearError.Name = "BtnClearError";
this.BtnClearError.Size = new System.Drawing.Size(96, 68); this.BtnClearError.Size = new System.Drawing.Size(100, 44);
this.BtnClearError.TabIndex = 19; this.BtnClearError.TabIndex = 19;
this.BtnClearError.Text = "清除错误"; this.BtnClearError.Text = "清除错误";
this.BtnClearError.UseVisualStyleBackColor = true; this.BtnClearError.UseVisualStyleBackColor = true;
...@@ -867,9 +682,10 @@ ...@@ -867,9 +682,10 @@
// //
// BtnMissionAdd // BtnMissionAdd
// //
this.BtnMissionAdd.Location = new System.Drawing.Point(170, 58); this.BtnMissionAdd.Location = new System.Drawing.Point(227, 118);
this.BtnMissionAdd.Margin = new System.Windows.Forms.Padding(4);
this.BtnMissionAdd.Name = "BtnMissionAdd"; this.BtnMissionAdd.Name = "BtnMissionAdd";
this.BtnMissionAdd.Size = new System.Drawing.Size(96, 62); this.BtnMissionAdd.Size = new System.Drawing.Size(100, 44);
this.BtnMissionAdd.TabIndex = 3; this.BtnMissionAdd.TabIndex = 3;
this.BtnMissionAdd.Text = "添加任务"; this.BtnMissionAdd.Text = "添加任务";
this.BtnMissionAdd.UseVisualStyleBackColor = true; this.BtnMissionAdd.UseVisualStyleBackColor = true;
...@@ -877,9 +693,10 @@ ...@@ -877,9 +693,10 @@
// //
// BtnMissionPause // BtnMissionPause
// //
this.BtnMissionPause.Location = new System.Drawing.Point(460, 206); this.BtnMissionPause.Location = new System.Drawing.Point(227, 237);
this.BtnMissionPause.Margin = new System.Windows.Forms.Padding(4);
this.BtnMissionPause.Name = "BtnMissionPause"; this.BtnMissionPause.Name = "BtnMissionPause";
this.BtnMissionPause.Size = new System.Drawing.Size(96, 68); this.BtnMissionPause.Size = new System.Drawing.Size(100, 44);
this.BtnMissionPause.TabIndex = 2; this.BtnMissionPause.TabIndex = 2;
this.BtnMissionPause.Text = "暂停"; this.BtnMissionPause.Text = "暂停";
this.BtnMissionPause.UseVisualStyleBackColor = true; this.BtnMissionPause.UseVisualStyleBackColor = true;
...@@ -887,9 +704,10 @@ ...@@ -887,9 +704,10 @@
// //
// BtnMissionReady // BtnMissionReady
// //
this.BtnMissionReady.Location = new System.Drawing.Point(336, 206); this.BtnMissionReady.Location = new System.Drawing.Point(227, 174);
this.BtnMissionReady.Margin = new System.Windows.Forms.Padding(4);
this.BtnMissionReady.Name = "BtnMissionReady"; this.BtnMissionReady.Name = "BtnMissionReady";
this.BtnMissionReady.Size = new System.Drawing.Size(96, 68); this.BtnMissionReady.Size = new System.Drawing.Size(100, 44);
this.BtnMissionReady.TabIndex = 1; this.BtnMissionReady.TabIndex = 1;
this.BtnMissionReady.Text = "运行"; this.BtnMissionReady.Text = "运行";
this.BtnMissionReady.UseVisualStyleBackColor = true; this.BtnMissionReady.UseVisualStyleBackColor = true;
...@@ -897,58 +715,171 @@ ...@@ -897,58 +715,171 @@
// //
// LstAgvPlace // LstAgvPlace
// //
this.LstAgvPlace.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) this.LstAgvPlace.Dock = System.Windows.Forms.DockStyle.Left;
| System.Windows.Forms.AnchorStyles.Left)));
this.LstAgvPlace.FormattingEnabled = true; this.LstAgvPlace.FormattingEnabled = true;
this.LstAgvPlace.IntegralHeight = false; this.LstAgvPlace.IntegralHeight = false;
this.LstAgvPlace.ItemHeight = 12; this.LstAgvPlace.ItemHeight = 15;
this.LstAgvPlace.Location = new System.Drawing.Point(6, 6); this.LstAgvPlace.Location = new System.Drawing.Point(4, 4);
this.LstAgvPlace.Margin = new System.Windows.Forms.Padding(4);
this.LstAgvPlace.Name = "LstAgvPlace"; this.LstAgvPlace.Name = "LstAgvPlace";
this.LstAgvPlace.Size = new System.Drawing.Size(150, 275); this.LstAgvPlace.Size = new System.Drawing.Size(199, 388);
this.LstAgvPlace.TabIndex = 0; this.LstAgvPlace.TabIndex = 0;
// //
// tableLayoutPanel4 // tableLayoutPanel4
// //
this.tableLayoutPanel4.ColumnCount = 1; this.tableLayoutPanel4.ColumnCount = 1;
this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel4.Controls.Add(this.lblWarnMsg, 0, 1); this.tableLayoutPanel4.Controls.Add(this.tableLayoutPanel6, 0, 0);
this.tableLayoutPanel4.Controls.Add(this.lblMsg, 0, 0);
this.tableLayoutPanel4.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel4.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel4.Location = new System.Drawing.Point(2, 151); this.tableLayoutPanel4.Location = new System.Drawing.Point(3, 174);
this.tableLayoutPanel4.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2); this.tableLayoutPanel4.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.tableLayoutPanel4.Name = "tableLayoutPanel4"; this.tableLayoutPanel4.Name = "tableLayoutPanel4";
this.tableLayoutPanel4.RowCount = 2; this.tableLayoutPanel4.RowCount = 1;
this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 211F));
this.tableLayoutPanel4.Size = new System.Drawing.Size(1309, 55); this.tableLayoutPanel4.Size = new System.Drawing.Size(1417, 211);
this.tableLayoutPanel4.TabIndex = 8; this.tableLayoutPanel4.TabIndex = 8;
// //
// lblWarnMsg // tableLayoutPanel6
//
this.tableLayoutPanel6.CellBorderStyle = System.Windows.Forms.TableLayoutPanelCellBorderStyle.OutsetPartial;
this.tableLayoutPanel6.ColumnCount = 3;
this.tableLayoutPanel6.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.tableLayoutPanel6.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33334F));
this.tableLayoutPanel6.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33334F));
this.tableLayoutPanel6.Controls.Add(this.label6, 2, 1);
this.tableLayoutPanel6.Controls.Add(this.label5, 1, 1);
this.tableLayoutPanel6.Controls.Add(this.label4, 0, 1);
this.tableLayoutPanel6.Controls.Add(this.label3, 2, 0);
this.tableLayoutPanel6.Controls.Add(this.label2, 1, 0);
this.tableLayoutPanel6.Controls.Add(this.label1, 0, 0);
this.tableLayoutPanel6.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel6.Font = new System.Drawing.Font("宋体", 10.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.tableLayoutPanel6.Location = new System.Drawing.Point(3, 3);
this.tableLayoutPanel6.Name = "tableLayoutPanel6";
this.tableLayoutPanel6.RowCount = 2;
this.tableLayoutPanel6.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel6.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel6.Size = new System.Drawing.Size(1411, 205);
this.tableLayoutPanel6.TabIndex = 0;
//
// label6
//
this.label6.AutoSize = true;
this.label6.Dock = System.Windows.Forms.DockStyle.Fill;
this.label6.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label6.Location = new System.Drawing.Point(944, 104);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(461, 98);
this.label6.TabIndex = 5;
this.label6.Text = "label6";
//
// label5
//
this.label5.AutoSize = true;
this.label5.Dock = System.Windows.Forms.DockStyle.Fill;
this.label5.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label5.Location = new System.Drawing.Point(475, 104);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(460, 98);
this.label5.TabIndex = 4;
this.label5.Text = "label5";
//
// label4
//
this.label4.AutoSize = true;
this.label4.Dock = System.Windows.Forms.DockStyle.Fill;
this.label4.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label4.Location = new System.Drawing.Point(6, 104);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(460, 98);
this.label4.TabIndex = 3;
this.label4.Text = "label4";
//
// label3
//
this.label3.AutoSize = true;
this.label3.Dock = System.Windows.Forms.DockStyle.Fill;
this.label3.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label3.Location = new System.Drawing.Point(944, 3);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(461, 98);
this.label3.TabIndex = 2;
this.label3.Text = "label3";
//
// label2
//
this.label2.AutoSize = true;
this.label2.Dock = System.Windows.Forms.DockStyle.Fill;
this.label2.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label2.Location = new System.Drawing.Point(475, 3);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(460, 98);
this.label2.TabIndex = 1;
this.label2.Text = "label2";
//
// label1
//
this.label1.AutoSize = true;
this.label1.Dock = System.Windows.Forms.DockStyle.Fill;
this.label1.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label1.Location = new System.Drawing.Point(6, 3);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(460, 98);
this.label1.TabIndex = 0;
this.label1.Text = "label1";
//
// groupBox7
//
this.groupBox7.Controls.Add(this.btnUpdateStatus);
this.groupBox7.Controls.Add(this.txtBoxRFID);
this.groupBox7.Location = new System.Drawing.Point(691, 30);
this.groupBox7.Name = "groupBox7";
this.groupBox7.Size = new System.Drawing.Size(204, 151);
this.groupBox7.TabIndex = 36;
this.groupBox7.TabStop = false;
this.groupBox7.Text = "物料状态上报";
//
// txtBoxRFID
//
this.txtBoxRFID.Location = new System.Drawing.Point(24, 27);
this.txtBoxRFID.Name = "txtBoxRFID";
this.txtBoxRFID.Size = new System.Drawing.Size(139, 25);
this.txtBoxRFID.TabIndex = 0;
//
// btnUpdateStatus
//
this.btnUpdateStatus.Location = new System.Drawing.Point(45, 67);
this.btnUpdateStatus.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.btnUpdateStatus.Name = "btnUpdateStatus";
this.btnUpdateStatus.Size = new System.Drawing.Size(100, 65);
this.btnUpdateStatus.TabIndex = 41;
this.btnUpdateStatus.Text = "上报";
this.btnUpdateStatus.UseVisualStyleBackColor = true;
this.btnUpdateStatus.Click += new System.EventHandler(this.btnUpdateStatus_Click);
// //
this.lblWarnMsg.Dock = System.Windows.Forms.DockStyle.Fill; // Column24
this.lblWarnMsg.ForeColor = System.Drawing.Color.Red;
this.lblWarnMsg.Location = new System.Drawing.Point(2, 27);
this.lblWarnMsg.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
this.lblWarnMsg.Name = "lblWarnMsg";
this.lblWarnMsg.Size = new System.Drawing.Size(1305, 28);
this.lblWarnMsg.TabIndex = 1;
// //
// lblMsg this.Column24.HeaderText = "时间";
this.Column24.MinimumWidth = 6;
this.Column24.Name = "Column24";
this.Column24.Width = 150;
// //
this.lblMsg.Dock = System.Windows.Forms.DockStyle.Fill; // Column8
this.lblMsg.Location = new System.Drawing.Point(2, 0); //
this.lblMsg.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0); this.Column8.HeaderText = "任务";
this.lblMsg.Name = "lblMsg"; this.Column8.MinimumWidth = 6;
this.lblMsg.Size = new System.Drawing.Size(1305, 27); this.Column8.Name = "Column8";
this.lblMsg.TabIndex = 0; this.Column8.Width = 150;
// //
// FrmMain // FrmMain
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1313, 656); this.ClientSize = new System.Drawing.Size(1423, 820);
this.Controls.Add(this.tableLayoutPanel3); this.Controls.Add(this.tableLayoutPanel3);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Margin = new System.Windows.Forms.Padding(4);
this.Name = "FrmMain"; this.Name = "FrmMain";
this.Text = "AGV产线调度"; this.Text = "AGV产线调度";
this.WindowState = System.Windows.Forms.FormWindowState.Maximized; this.WindowState = System.Windows.Forms.FormWindowState.Maximized;
...@@ -961,99 +892,94 @@ ...@@ -961,99 +892,94 @@
this.tableLayoutPanel2.ResumeLayout(false); this.tableLayoutPanel2.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.DgvNode)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.DgvNode)).EndInit();
this.groupBox1.ResumeLayout(false); this.groupBox1.ResumeLayout(false);
this.tableLayoutPanel5.ResumeLayout(false);
this.groupBox5.ResumeLayout(false);
this.groupBox3.ResumeLayout(false);
this.groupBox4.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.dgvLineMission)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.dgvLineMission)).EndInit();
this.tabPage2.ResumeLayout(false); this.tabPage2.ResumeLayout(false);
this.tableLayoutPanel1.ResumeLayout(false); this.tableLayoutPanel1.ResumeLayout(false);
this.tableLayoutPanel1.PerformLayout(); this.tableLayoutPanel1.PerformLayout();
this.flowLayoutPanel1.ResumeLayout(false);
this.flowLayoutPanel1.PerformLayout();
this.tabPage3.ResumeLayout(false); this.tabPage3.ResumeLayout(false);
this.tabPage3.PerformLayout(); this.tabPage3.PerformLayout();
this.groupBox6.ResumeLayout(false);
this.groupBox2.ResumeLayout(false); this.groupBox2.ResumeLayout(false);
this.groupBox2.PerformLayout(); this.groupBox2.PerformLayout();
this.tableLayoutPanel4.ResumeLayout(false); this.tableLayoutPanel4.ResumeLayout(false);
this.tableLayoutPanel6.ResumeLayout(false);
this.tableLayoutPanel6.PerformLayout();
this.groupBox7.ResumeLayout(false);
this.groupBox7.PerformLayout();
this.ResumeLayout(false); this.ResumeLayout(false);
} }
#endregion #endregion
private System.Windows.Forms.DataGridView DgvAgv; private System.Windows.Forms.DataGridView DgvAgv;
private System.Windows.Forms.DataGridViewTextBoxColumn Column1;
private System.Windows.Forms.DataGridViewTextBoxColumn Column2;
private System.Windows.Forms.DataGridViewTextBoxColumn Column3;
private System.Windows.Forms.DataGridViewTextBoxColumn Column21;
private System.Windows.Forms.DataGridViewTextBoxColumn Column25;
private System.Windows.Forms.DataGridViewTextBoxColumn Column14;
private System.Windows.Forms.DataGridViewTextBoxColumn Column18;
private System.Windows.Forms.DataGridViewTextBoxColumn Column20;
private System.Windows.Forms.DataGridViewTextBoxColumn Column4;
private System.Windows.Forms.DataGridViewTextBoxColumn Column23;
private System.Windows.Forms.DataGridViewTextBoxColumn Column13;
private System.Windows.Forms.DataGridViewTextBoxColumn Column19;
private System.Windows.Forms.DataGridViewButtonColumn Column11;
private System.Windows.Forms.DataGridViewButtonColumn Column17;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel3; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel3;
private System.Windows.Forms.TabControl tabControl1; private System.Windows.Forms.TabControl tabControl1;
private System.Windows.Forms.TabPage tabPage1; private System.Windows.Forms.TabPage tabPage1;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
private System.Windows.Forms.DataGridView DgvNode; private System.Windows.Forms.DataGridView DgvNode;
private System.Windows.Forms.GroupBox groupBox1; private System.Windows.Forms.GroupBox groupBox1;
private System.Windows.Forms.Button btnAddMission;
private System.Windows.Forms.ComboBox cmbBoxLineName;
private System.Windows.Forms.Button btnDeleteMission;
private System.Windows.Forms.DataGridView dgvLineMission; private System.Windows.Forms.DataGridView dgvLineMission;
private System.Windows.Forms.DataGridViewTextBoxColumn Column24;
private System.Windows.Forms.DataGridViewTextBoxColumn Column8;
private System.Windows.Forms.TabPage tabPage2; private System.Windows.Forms.TabPage tabPage2;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.TextBox TxtLog; private System.Windows.Forms.TextBox TxtLog;
private System.Windows.Forms.TabPage tabPage3; private System.Windows.Forms.TabPage tabPage3;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button btnSetRFID; private System.Windows.Forms.Button btnSetRFID;
private System.Windows.Forms.TextBox txtAgvRFID; private System.Windows.Forms.TextBox txtAgvRFID;
private System.Windows.Forms.GroupBox groupBox2; private System.Windows.Forms.GroupBox groupBox2;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.TextBox TxtCharge7;
private System.Windows.Forms.Button BtnWriteCharge7;
private System.Windows.Forms.Button BtnReadCharge7;
private System.Windows.Forms.ComboBox cmbBoxAGVName;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox TxtCharge5;
private System.Windows.Forms.Button BtnReadCharge5;
private System.Windows.Forms.CheckBox ChkAutoCharge; private System.Windows.Forms.CheckBox ChkAutoCharge;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Button BtnWriteCharge5;
private System.Windows.Forms.TextBox TxtCharge6;
private System.Windows.Forms.Button BtnWriteCharge6;
private System.Windows.Forms.Button BtnReadCharge6;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox TxtCharge3;
private System.Windows.Forms.Button BtnReadCharge3;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Button BtnWriteCharge3;
private System.Windows.Forms.TextBox TxtCharge4;
private System.Windows.Forms.Button BtnWriteCharge4;
private System.Windows.Forms.Button BtnReadCharge4;
private System.Windows.Forms.Button BtnClearError; private System.Windows.Forms.Button BtnClearError;
private System.Windows.Forms.Button BtnMissionAdd; private System.Windows.Forms.Button BtnMissionAdd;
private System.Windows.Forms.Button BtnMissionPause; private System.Windows.Forms.Button BtnMissionPause;
private System.Windows.Forms.Button BtnMissionReady; private System.Windows.Forms.Button BtnMissionReady;
private System.Windows.Forms.ListBox LstAgvPlace; private System.Windows.Forms.ListBox LstAgvPlace;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel4; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel4;
private System.Windows.Forms.Label lblWarnMsg; private System.Windows.Forms.Label lblWO;
private System.Windows.Forms.Label lblMsg; private System.Windows.Forms.GroupBox groupBox3;
private System.Windows.Forms.GroupBox groupBox4;
private System.Windows.Forms.Button btnWO;
private System.Windows.Forms.Button button5;
private System.Windows.Forms.DataGridViewTextBoxColumn Column6; private System.Windows.Forms.DataGridViewTextBoxColumn Column6;
private System.Windows.Forms.DataGridViewTextBoxColumn Column12; private System.Windows.Forms.DataGridViewTextBoxColumn Column12;
private System.Windows.Forms.DataGridViewTextBoxColumn Column22; private System.Windows.Forms.DataGridViewTextBoxColumn Column22;
private System.Windows.Forms.DataGridViewTextBoxColumn Column7; private System.Windows.Forms.DataGridViewTextBoxColumn Column7;
private System.Windows.Forms.DataGridViewTextBoxColumn Column9;
private System.Windows.Forms.DataGridViewTextBoxColumn Column10; private System.Windows.Forms.DataGridViewTextBoxColumn Column10;
private System.Windows.Forms.DataGridViewTextBoxColumn Column9;
private System.Windows.Forms.DataGridViewTextBoxColumn Column5; private System.Windows.Forms.DataGridViewTextBoxColumn Column5;
private System.Windows.Forms.DataGridViewButtonColumn Column16; private System.Windows.Forms.DataGridViewButtonColumn Column16;
private System.Windows.Forms.DataGridViewButtonColumn Column15; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel6;
private System.Windows.Forms.FlowLayoutPanel flowLayoutPanel1; private System.Windows.Forms.Label label6;
private System.Windows.Forms.Label lblVMIGetBoxDestInfo; private System.Windows.Forms.Label label5;
private System.Windows.Forms.Label lblGetRack; private System.Windows.Forms.Label label4;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.DataGridViewTextBoxColumn Column1;
private System.Windows.Forms.DataGridViewTextBoxColumn Column2;
private System.Windows.Forms.DataGridViewTextBoxColumn Column4;
private System.Windows.Forms.DataGridViewTextBoxColumn Column3;
private System.Windows.Forms.DataGridViewTextBoxColumn Column21;
private System.Windows.Forms.DataGridViewTextBoxColumn Column18;
private System.Windows.Forms.DataGridViewTextBoxColumn Column20;
private System.Windows.Forms.DataGridViewTextBoxColumn Column23;
private System.Windows.Forms.DataGridViewTextBoxColumn Column13;
private System.Windows.Forms.DataGridViewTextBoxColumn Column19;
private System.Windows.Forms.DataGridViewButtonColumn Column11;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel5;
private System.Windows.Forms.GroupBox groupBox5;
private System.Windows.Forms.Label lblDestInfo;
private System.Windows.Forms.GroupBox groupBox6;
private System.Windows.Forms.Button btnDeleteMission;
private System.Windows.Forms.Button btnAddMission;
private System.Windows.Forms.ComboBox cmbBoxLineName;
private System.Windows.Forms.GroupBox groupBox7;
private System.Windows.Forms.Button btnUpdateStatus;
private System.Windows.Forms.TextBox txtBoxRFID;
private System.Windows.Forms.DataGridViewTextBoxColumn Column24;
private System.Windows.Forms.DataGridViewTextBoxColumn Column8;
} }
} }
...@@ -20,6 +20,7 @@ namespace AGVControl ...@@ -20,6 +20,7 @@ namespace AGVControl
private NotifyIcon notify; private NotifyIcon notify;
private ContextMenuStrip notifyMenu; private ContextMenuStrip notifyMenu;
private System.Timers.Timer showTimer; private System.Timers.Timer showTimer;
private Label[] agvRunInfo;
public FrmMain() public FrmMain()
{ {
InitializeComponent(); InitializeComponent();
...@@ -30,6 +31,7 @@ namespace AGVControl ...@@ -30,6 +31,7 @@ namespace AGVControl
showTimer.Elapsed += ShowTimer_Elapsed; showTimer.Elapsed += ShowTimer_Elapsed;
showTimer.Start(); showTimer.Start();
Common.logTextBox = TxtLog; Common.logTextBox = TxtLog;
agvRunInfo = new Label[] {label1,label2,label3,label4,label5,label6};
} }
private void ShowConfig() private void ShowConfig()
...@@ -47,6 +49,10 @@ namespace AGVControl ...@@ -47,6 +49,10 @@ namespace AGVControl
DgvAgv.Rows[n].DefaultCellStyle.BackColor = Color.LightBlue; DgvAgv.Rows[n].DefaultCellStyle.BackColor = Color.LightBlue;
if (!Common.agvInfo[i].IsCon) if (!Common.agvInfo[i].IsCon)
DgvAgv.Rows[n].DefaultCellStyle.ForeColor = Color.Red; DgvAgv.Rows[n].DefaultCellStyle.ForeColor = Color.Red;
//if (i % 2 == 0)
// agvRunInfo[i].BackColor = Color.LightBlue;
//else
// agvRunInfo[i].BackColor = Color.LightGray;
} }
cmbBoxLineName.Items.Add("产线名称"); cmbBoxLineName.Items.Add("产线名称");
...@@ -76,7 +82,7 @@ namespace AGVControl ...@@ -76,7 +82,7 @@ namespace AGVControl
{ {
Invoke(new Action(() => Invoke(new Action(() =>
{ {
DgvNode.Rows[nodeIndex].DefaultCellStyle.ForeColor = Common.nodeInfo[nodeIndex].Online ? Color.Black : Color.Red; DgvNode.Rows[nodeIndex].DefaultCellStyle.ForeColor = Common.nodeInfo[nodeIndex].Online && Common.nodeInfo[nodeIndex].IsUse ? Color.Black : Color.Red;
DgvNode.Rows[nodeIndex].SetValues(Common.nodeInfo[nodeIndex].ToRow()); DgvNode.Rows[nodeIndex].SetValues(Common.nodeInfo[nodeIndex].ToRow());
})); }));
ShowEmptyTask(); ShowEmptyTask();
...@@ -90,8 +96,6 @@ namespace AGVControl ...@@ -90,8 +96,6 @@ namespace AGVControl
DgvNode.Rows[nodeIndex].DefaultCellStyle.ForeColor = Common.nodeInfo[nodeIndex].Online ? Color.Black : Color.Red; DgvNode.Rows[nodeIndex].DefaultCellStyle.ForeColor = Common.nodeInfo[nodeIndex].Online ? Color.Black : Color.Red;
DgvNode.Rows[nodeIndex].SetValues(Common.nodeInfo[nodeIndex].ToRow()); DgvNode.Rows[nodeIndex].SetValues(Common.nodeInfo[nodeIndex].ToRow());
})); }));
ShowEmptyTask();
System.GC.Collect(); System.GC.Collect();
} }
...@@ -182,12 +186,12 @@ namespace AGVControl ...@@ -182,12 +186,12 @@ namespace AGVControl
Common.control.AgvMissionChanged += Control_AgvMissionChanged; Common.control.AgvMissionChanged += Control_AgvMissionChanged;
Common.server.NodeChanged += Server_NodeChanged; Common.server.NodeChanged += Server_NodeChanged;
Common.server.NodeOnline += Server_NodeOnline; Common.server.NodeOnline += Server_NodeOnline;
foreach (var item in Common.agvInfo) //foreach (var item in Common.agvInfo)
{ //{
cmbBoxAGVName.Items.Add(item.Name); // cmbBoxAGVName.Items.Add(item.Name);
} //}
cmbBoxAGVName.Items.Add("None"); //cmbBoxAGVName.Items.Add("None");
cmbBoxAGVName.SelectedIndex = Common.agvInfo.Count; //cmbBoxAGVName.SelectedIndex = Common.agvInfo.Count;
} }
private void FrmMain_FormClosing(object sender, FormClosingEventArgs e) private void FrmMain_FormClosing(object sender, FormClosingEventArgs e)
...@@ -214,9 +218,22 @@ namespace AGVControl ...@@ -214,9 +218,22 @@ namespace AGVControl
{ {
if (e.RowIndex == -1) return; if (e.RowIndex == -1) return;
if (e.ColumnIndex == 12) //调用 if (e.ColumnIndex == 10) //调用
{
if(Common.agvInfo[e.RowIndex].IsUse.Equals(true))
{
if (MessageBox.Show("是否关闭当前小车的自动模式?", Common.agvInfo[e.RowIndex].Name+"_警告", MessageBoxButtons.YesNo).Equals(DialogResult.Yes))
{
Common.agvInfo[e.RowIndex].IsUse = false;
Common.agvInfo[e.RowIndex].CurJob = null;
Common.agvInfo[e.RowIndex].RFID = "";
}
}
else
{ {
Common.agvInfo[e.RowIndex].IsUse = !Common.agvInfo[e.RowIndex].IsUse; Common.agvInfo[e.RowIndex].CurJob = null;
Common.agvInfo[e.RowIndex].IsUse = true;
}
DgvAgv.Rows[e.RowIndex].Cells[e.ColumnIndex].Value = Common.agvInfo[e.RowIndex].IsUse.ToString(); DgvAgv.Rows[e.RowIndex].Cells[e.ColumnIndex].Value = Common.agvInfo[e.RowIndex].IsUse.ToString();
Common.WriteIni(Common.agvInfo[e.RowIndex].Name, SettingString.IsUse, Common.agvInfo[e.RowIndex].IsUse.ToString()); Common.WriteIni(Common.agvInfo[e.RowIndex].Name, SettingString.IsUse, Common.agvInfo[e.RowIndex].IsUse.ToString());
Common.appConfig.Save(); Common.appConfig.Save();
...@@ -224,46 +241,48 @@ namespace AGVControl ...@@ -224,46 +241,48 @@ namespace AGVControl
} }
else if (e.ColumnIndex == 13) //清除缓存 else if (e.ColumnIndex == 13) //清除缓存
{ {
Common.agvInfo[e.RowIndex].IsUse = false;
//清除小车缓存 //清除小车缓存
Common.LogInfo(string.Format("手动清除agv缓存,{0} {1}", Common.agvInfo[e.RowIndex].Name, Common.agvInfo[e.RowIndex].Place)); Common.LogInfo(string.Format("手动清除agv缓存,{0} {1}", Common.agvInfo[e.RowIndex].Name, Common.agvInfo[e.RowIndex].Place));
string place = Common.agvInfo[e.RowIndex].Place; //string place = Common.agvInfo[e.RowIndex].Place;
//Common.agvInfo[e.RowIndex].Place = ""; //Common.agvInfo[e.RowIndex].Place = "";
Common.agvInfo[e.RowIndex].PlaceAliceName = ""; //Common.agvInfo[e.RowIndex].PlaceAliceName = "";
//Common.agvInfo[e.RowIndex].RFID = ""; //Common.agvInfo[e.RowIndex].RFID = "";
Common.agvInfo[e.RowIndex].NextPlace = ""; //Common.agvInfo[e.RowIndex].NextPlace = "";
Common.agvInfo[e.RowIndex].NextPlaceAliceName = ""; //Common.agvInfo[e.RowIndex].NextPlaceAliceName = "";
Common.agvInfo[e.RowIndex].TaskSend = ""; //Common.agvInfo[e.RowIndex].TaskSend = "";
Common.agvInfo[e.RowIndex].Msg = ""; //Common.agvInfo[e.RowIndex].Msg = "";
// Common.agvInfo[e.RowIndex].CurJob = null;
//清除执行空架任务的小车 //清除执行空架任务的小车
if (Common.missionManager.AGV_Name_EmptyTask == Common.agvInfo[e.RowIndex].Name) //if (Common.missionManager.AGV_Name_EmptyTask == Common.agvInfo[e.RowIndex].Name)
Common.missionManager.AGV_Name_EmptyTask = ""; // Common.missionManager.AGV_Name_EmptyTask = "";
DgvAgv.Rows[e.RowIndex].SetValues(Common.agvInfo[e.RowIndex].ToRow()); DgvAgv.Rows[e.RowIndex].SetValues(Common.agvInfo[e.RowIndex].ToRow());
//清除节点缓存 //清除节点缓存
int idx = Common.nodeInfo.FindIndex(s => s.Name == place); //int idx = Common.nodeInfo.FindIndex(s => s.Name == place);
if (idx > -1) //if (idx > -1)
{ //{
Common.nodeInfo[idx].AgvName = ""; // Common.nodeInfo[idx].AgvName = "";
DgvNode.Rows[idx].Cells[5].Value = ""; // DgvNode.Rows[idx].Cells[5].Value = "";
} //}
////添加Init任务 ////添加Init任务
//Common.mir.Add_Mission_Fleet(Common.agvInfo[e.RowIndex], Common.agvMission["Init"]); //Common.mir.Add_Mission_Fleet(Common.agvInfo[e.RowIndex], Common.agvMission["Init"]);
Common.mir.Add_Mission(Common.agvInfo[e.RowIndex], Common.agvMission["Init"]); //Common.mir.Add_Mission(Common.agvInfo[e.RowIndex], Common.agvMission["Init"]);
Common.mir.State_Ready(Common.agvInfo[e.RowIndex]); // Common.mir.State_Ready(Common.agvInfo[e.RowIndex]);
//判断小车负载与实际是否匹配 //判断小车负载与实际是否匹配
Common.mir.Get_IO_Status(Common.agvInfo[e.RowIndex], out bool[] input, out bool[] output); //Common.mir.Get_IO_Status(Common.agvInfo[e.RowIndex], out bool[] input, out bool[] output);
if (input != null && input.Length == 4) //if (input != null && input.Length == 4)
{ //{
if (!Common.agvInfo[e.RowIndex].IsExistShelf.Equals(input[3])) // if (!Common.agvInfo[e.RowIndex].IsExistShelf.Equals(input[3]))
{ // {
if (MessageBox.Show("满载IO信号与当前负载信号不一致,是否同步?", "警告", MessageBoxButtons.YesNo).Equals(DialogResult.Yes)) // if (MessageBox.Show("满载IO信号与当前负载信号不一致,是否同步?", "警告", MessageBoxButtons.YesNo).Equals(DialogResult.Yes))
Common.agvInfo[e.RowIndex].IsExistShelf = input[3]; // Common.agvInfo[e.RowIndex].IsExistShelf = input[3];
DgvAgv.Rows[e.RowIndex].SetValues(Common.agvInfo[e.RowIndex].ToRow()); // DgvAgv.Rows[e.RowIndex].SetValues(Common.agvInfo[e.RowIndex].ToRow());
} // }
} //}
} }
} }
...@@ -329,7 +348,13 @@ namespace AGVControl ...@@ -329,7 +348,13 @@ namespace AGVControl
if (idx < 0) return; if (idx < 0) return;
if (Common.agvInfo[idx].IsCon) if (Common.agvInfo[idx].IsCon)
{ {
bool rtn = Common.mir.Add_Mission(Common.agvInfo[idx], Common.agvMission[Common.showNameMissionName[LstAgvPlace.Text]]); if(Common.agvInfo[idx].IsUse)
{
if (MessageBox.Show("确定在自动模式下对小车手动分配任务?", Common.agvInfo[idx].Name, MessageBoxButtons.YesNo) == DialogResult.No)
return;
}
bool rtn = Common.mir.Add_Mission_Fleet(Common.agvInfo[idx], Common.agvMission[Common.showNameMissionName[LstAgvPlace.Text]]);
if (!rtn) if (!rtn)
return; return;
//Common.agvInfo[idx].TaskSend = LstAgvPlace.Text; //Common.agvInfo[idx].TaskSend = LstAgvPlace.Text;
...@@ -349,29 +374,23 @@ namespace AGVControl ...@@ -349,29 +374,23 @@ namespace AGVControl
} }
bool InShhow = false; bool InShhow = false;
private void ShowTimer_Elapsed(object sender, System.Timers.ElapsedEventArgs e) private void ShowTimer_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
{ {
//ShowEmptyTask(); //ShowEmptyTask();
if (InShhow)
return;
InShhow = true; InShhow = true;
string msg = "";
string racks = "";
foreach (Agv_Info agv in Common.agvInfo)
{
if (agv.CurJob != null)
msg += agv.Name + ":" + agv.Msg + ";" + agv.CurJob.RunInfo;
else
msg += agv.Name + ":" + agv.Msg + ";";
if(agv.RFID.StartsWith("C"))
{
racks+=AGVManager.GetRackBy(agv.RFID);
}
}
Invoke(new Action(() => Invoke(new Action(() =>
{ {
lblMsg.Text = msg; for (int i = 0; i < Common.agvInfo.Count; i++)
lblVMIGetBoxDestInfo.Text = AGVManager.A6_Target; {
lblGetRack.Text = racks; agvRunInfo[i].Text = Common.agvInfo[i].RunInfo();
}
lblWO.Text = Common.doubleLine_WO;
lblDestInfo.Text = AGVManager.A6_Target;
})); }));
...@@ -401,56 +420,55 @@ namespace AGVControl ...@@ -401,56 +420,55 @@ namespace AGVControl
} }
} }
private void BtnReadWriteCharge_Click(object sender, EventArgs e) //private void BtnReadWriteCharge_Click(object sender, EventArgs e)
{ //{
string name = (sender as System.Windows.Forms.Control).Name; // string name = (sender as System.Windows.Forms.Control).Name;
int num = Convert.ToInt32(name.Substring(name.Length - 1, 1));
//if (DgvAgv.SelectedCells.Count == 0) return; // //if (DgvAgv.SelectedCells.Count == 0) return;
int idx = cmbBoxAGVName.SelectedIndex; // int idx = cmbBoxAGVName.SelectedIndex;
if (idx >= Common.agvInfo.Count) return; // if (idx >= Common.agvInfo.Count) return;
// int num =
// if (name.IndexOf("Read") > 0)
// {
// if (num == 3)
// TxtCharge.Text = Common.chargeStatus.charge3;
// else if (num == 4)
// TxtCharge4.Text = Common.chargeStatus.charge4;
// else if (num == 5)
// TxtCharge5.Text = Common.chargeStatus.charge5;
// else if (num == 6)
// TxtCharge6.Text = Common.chargeStatus.charge6;
// else if (num == 7)
// TxtCharge7.Text = Common.chargeStatus.charge7;
// }
// else if (name.IndexOf("Write") > 0)
// {
// if (num == 3)
// {
// //if(!Common.chargeStatus.charge3.Equals(""))
// //{
// // MessageBox.Show("该充电桩已有小车");
// //}
// Common.chargeStatus.charge3 = TxtCharge.Text;
// }
if (name.IndexOf("Read") > 0) // else if (num == 4)
{ // Common.chargeStatus.charge4 = TxtCharge4.Text;
if (num == 3) // else if (num == 5)
TxtCharge3.Text = Common.chargeStatus.charge3; // Common.chargeStatus.charge5 = TxtCharge5.Text;
else if (num == 4) // else if (num == 6)
TxtCharge4.Text = Common.chargeStatus.charge4; // Common.chargeStatus.charge6 = TxtCharge6.Text;
else if (num == 5) // else if (num == 7)
TxtCharge5.Text = Common.chargeStatus.charge5; // Common.chargeStatus.charge7 = TxtCharge7.Text;
else if (num == 6) // if (Common.agvInfo[idx].IsCon)
TxtCharge6.Text = Common.chargeStatus.charge6; // {
else if (num == 7) // bool rtn = Common.mir.Add_Mission_Fleet(Common.agvInfo[idx], Common.agvMission["AutoCharge" + num.ToString()]);
TxtCharge7.Text = Common.chargeStatus.charge7; // if (!rtn)
} // return;
else if (name.IndexOf("Write") > 0) // Common.agvInfo[idx].TaskSend = "AutoCharge" + num.ToString();
{ // }
if (num == 3) // }
{
//if(!Common.chargeStatus.charge3.Equals(""))
//{
// MessageBox.Show("该充电桩已有小车");
//} //}
Common.chargeStatus.charge3 = TxtCharge3.Text;
}
else if (num == 4)
Common.chargeStatus.charge4 = TxtCharge4.Text;
else if (num == 5)
Common.chargeStatus.charge5 = TxtCharge5.Text;
else if (num == 6)
Common.chargeStatus.charge6 = TxtCharge6.Text;
else if (num == 7)
Common.chargeStatus.charge7 = TxtCharge7.Text;
if (Common.agvInfo[idx].IsCon)
{
bool rtn = Common.mir.Add_Mission(Common.agvInfo[idx], Common.agvMission["AutoCharge" + num.ToString()]);
if (!rtn)
return;
Common.agvInfo[idx].TaskSend = "AutoCharge" + num.ToString();
}
}
}
private void ChkAutoCharge_CheckedChanged(object sender, EventArgs e) private void ChkAutoCharge_CheckedChanged(object sender, EventArgs e)
{ {
...@@ -460,57 +478,6 @@ namespace AGVControl ...@@ -460,57 +478,6 @@ namespace AGVControl
} }
private void cmbBoxAGVName_SelectedIndexChanged(object sender, EventArgs e)
{
if (cmbBoxAGVName.SelectedItem != null)
{
switch (cmbBoxAGVName.SelectedIndex)
{
case 0:
TxtCharge3.Text = "MiR_R1763";
break;
case 1:
TxtCharge4.Text = "MiR_R1764";
break;
case 2:
TxtCharge5.Text = "MiR_R1767";
break;
case 3:
TxtCharge6.Text = "MiR_R1768";
break;
default:
TxtCharge3.Text = "";
TxtCharge4.Text = "";
TxtCharge5.Text = "";
TxtCharge6.Text = "";
break;
}
}
//if(cmbBoxAGVName.SelectedItem!=null)
//{
// if(cmbBoxAGVName.SelectedItem.ToString()=="None")
// {
// TxtCharge3.Text = "";
// TxtCharge4.Text = "";
// TxtCharge5.Text = "";
// TxtCharge6.Text = "";
// }
// else
// {
// TxtCharge3.Text = cmbBoxAGVName.SelectedItem.ToString();
// TxtCharge4.Text = cmbBoxAGVName.SelectedItem.ToString();
// TxtCharge5.Text = cmbBoxAGVName.SelectedItem.ToString();
// TxtCharge6.Text = cmbBoxAGVName.SelectedItem.ToString();
// }
//}
}
private void btnDeleteMission_Click(object sender, EventArgs e) private void btnDeleteMission_Click(object sender, EventArgs e)
{ {
try try
...@@ -520,7 +487,7 @@ namespace AGVControl ...@@ -520,7 +487,7 @@ namespace AGVControl
ShowEmptyTask(); ShowEmptyTask();
return; return;
} }
if (MessageBox.Show("确定删除产线任务[" + cmbBoxLineName.SelectedItem.ToString() + "]") == DialogResult.Cancel) if (MessageBox.Show("确定删除产线任务[" + cmbBoxLineName.SelectedItem.ToString() + "]","手动删除解绑任务",MessageBoxButtons.YesNo) == DialogResult.No)
return; return;
//int idx=Common.missionList.FindIndex(s => s.NodeName == Common.agvProductionLine[txtBoxMission.Text]); //int idx=Common.missionList.FindIndex(s => s.NodeName == Common.agvProductionLine[txtBoxMission.Text]);
...@@ -572,7 +539,7 @@ namespace AGVControl ...@@ -572,7 +539,7 @@ namespace AGVControl
} }
if (cmbBoxLineName.SelectedItem.ToString().StartsWith("A")) if (cmbBoxLineName.SelectedItem.ToString().StartsWith("A"))
return; return;
if (MessageBox.Show("确定添加产线任务[" + cmbBoxLineName.SelectedItem.ToString() + "]") == DialogResult.Cancel) if (MessageBox.Show("确定添加产线任务[" + cmbBoxLineName.SelectedItem.ToString() + "]","手动1添加解绑",MessageBoxButtons.YesNo) == DialogResult.No)
return; return;
int idx = Common.nodeInfo.FindIndex(s => s.AliceName.Equals(cmbBoxLineName.SelectedItem.ToString())); int idx = Common.nodeInfo.FindIndex(s => s.AliceName.Equals(cmbBoxLineName.SelectedItem.ToString()));
if (idx > -1) if (idx > -1)
...@@ -611,5 +578,120 @@ namespace AGVControl ...@@ -611,5 +578,120 @@ namespace AGVControl
} }
} }
private void button1_Click_1(object sender, EventArgs e)
{
if (DgvAgv.SelectedCells.Count == 0) return;
int idx = DgvAgv.SelectedCells[0].RowIndex;
if (idx < 0) return;
if (Common.agvInfo[idx].IsCon)
{
Common.agvInfo[idx].CurJob = new ChargeJob("");
return;
//Common.agvInfo[idx].TaskSend = LstAgvPlace.Text;
}
}
private void button2_Click(object sender, EventArgs e)
{
if (DgvAgv.SelectedCells.Count == 0) return;
int idx = DgvAgv.SelectedCells[0].RowIndex;
if (idx < 0) return;
if (Common.agvInfo[idx].IsCon)
{
Common.agvInfo[idx].CurJob = new EmptyAGVBackJob("");
return;
}
}
private void btnWO_Click(object sender, EventArgs e)
{
try
{
Task.Factory.StartNew(new Action(() =>
{
if (AGVManager.FindCurSO(out AGVManager.WOData woData))
{
if (Common.GetNodeNameByLineName(woData.line, out string loc))
{
Common.doubleLine_WO = "工单料信息:" + woData.ToTxt(loc);
Common.LogInfo(Common.doubleLine_WO);
}
}
}));
}
catch (Exception ex)
{
MessageBox.Show("查询失败:" + ex.Message + "\r\n" + ex.StackTrace);
}
}
/// <summary>
/// 出料查询
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void button5_Click(object sender, EventArgs e)
{
try
{
Task.Factory.StartNew(() =>
{
int idx = Common.nodeInfo.FindIndex(s => s.Name.Equals(SettingString.A6));
if (idx > -1)
{
AGVManager.FindFullShelfTarget(Common.nodeInfo[idx].RFID, out AGVManager.BoxDestInfo FullShelfDestInfo);
}
});
}
catch (Exception ex)
{
MessageBox.Show("查询失败:" + ex.Message + "\r\n" + ex.StackTrace);
}
}
private void button9_Click(object sender, EventArgs e)
{
if (DgvAgv.SelectedCells.Count == 0) return;
int idx = DgvAgv.SelectedCells[0].RowIndex;
if (idx < 0) return;
if (Common.agvInfo[idx].IsCon)
{
Common.agvInfo[idx].CurJob =null;
}
}
private void button1_Click_2(object sender, EventArgs e)
{
if (DgvAgv.SelectedCells.Count == 0) return;
int idx = DgvAgv.SelectedCells[0].RowIndex;
if (idx < 0) return;
Common.CalculateNearNode(Common.agvInfo[idx],"E");
}
private void btnUpdateStatus_Click(object sender, EventArgs e)
{
try
{
if (DgvAgv.SelectedCells.Count == 0) return;
int idx = DgvAgv.SelectedCells[0].RowIndex;
if (idx < 0) return;
Task.Factory.StartNew(() =>
{
idx = Common.nodeInfo.FindIndex(s => s.Name.Equals(SettingString.A6));
if (idx > -1)
{
AGVManager.UpdateStatus(txtBoxRFID.Text.ToUpper(), Common.agvInfo[idx].Place);
}
});
}
catch (Exception ex)
{
MessageBox.Show("手动上报状态失败:" + ex.Message + "\r\n" + ex.StackTrace);
}
}
} }
} }
...@@ -123,16 +123,13 @@ ...@@ -123,16 +123,13 @@
<metadata name="Column2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column21.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column25.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column14.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column21.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column18.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column18.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
...@@ -141,9 +138,6 @@ ...@@ -141,9 +138,6 @@
<metadata name="Column20.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column20.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column23.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column23.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
...@@ -156,9 +150,6 @@ ...@@ -156,9 +150,6 @@
<metadata name="Column11.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column11.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column17.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
...@@ -171,10 +162,10 @@ ...@@ -171,10 +162,10 @@
<metadata name="Column7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column9.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column10.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column10.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column9.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
...@@ -183,9 +174,6 @@ ...@@ -183,9 +174,6 @@
<metadata name="Column16.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column16.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column15.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column24.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column24.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
......
...@@ -51,7 +51,7 @@ namespace AGVControl ...@@ -51,7 +51,7 @@ namespace AGVControl
Common.mir = new MiR_API(); Common.mir = new MiR_API();
Common.control = new BLL.Control(); Common.control = new BLL.Control();
//软件开启时检查小车当前的任务状态,并获取各节点的坐标位置 //软件开启时检查小车当前的任务状态,并获取各节点的坐标位置
//Common.CheckAGVMissionState(); // Common.CheckAGVMissionState();
//获取节点位置 //获取节点位置
//Common.GetNodesPosition(); //Common.GetNodesPosition();
...@@ -88,7 +88,7 @@ namespace AGVControl ...@@ -88,7 +88,7 @@ namespace AGVControl
if (temp.Length != 5) continue; if (temp.Length != 5) continue;
//string val = Common.appConfig.AppSettings.Settings[temp[1]].Value; //string val = Common.appConfig.AppSettings.Settings[temp[1]].Value;
bool.TryParse(Common.ReadIni(temp[1], SettingString.IsUse), out isuse); //Convert.ToBoolean(val.Split(',')[0]); bool.TryParse(Common.ReadIni(temp[1], SettingString.IsUse), out isuse); //Convert.ToBoolean(val.Split(',')[0]);
rfid = Common.ReadIni(temp[1],SettingString.RFID); //val.Split(',')[1]; rfid = Common.ReadIni(temp[1], SettingString.RFID); //val.Split(',')[1];
Common.agvInfo.Add(new Agv_Info(temp[0], temp[1], temp[2], temp[3], temp[4], isuse, rfid)); Common.agvInfo.Add(new Agv_Info(temp[0], temp[1], temp[2], temp[3], temp[4], isuse, rfid));
} }
...@@ -112,9 +112,18 @@ namespace AGVControl ...@@ -112,9 +112,18 @@ namespace AGVControl
{ {
temp = line[i].Split(','); temp = line[i].Split(',');
if (temp.Length != 6) continue; if (temp.Length != 6) continue;
Boolean.TryParse(Common.ReadIni(temp[1], SettingString.IsUse),out bool isUse); Boolean.TryParse(Common.ReadIni(temp[1], SettingString.IsUse), out bool isUse);
Int32.TryParse(Common.ReadIni(temp[1], SettingString.EmptyShelfCnt), out int emptyShelfCnt); Int32.TryParse(Common.ReadIni(temp[1], SettingString.EmptyShelfCnt), out int emptyShelfCnt);
Common.nodeInfo.Add(new ClientNode(temp[1], temp[2], temp[3], temp[0], temp[4], temp[5], isUse,emptyShelfCnt)); if (temp[1].Equals("A5"))
{
Common.nodeInfo.Add(new DoubleLineNodeFor4C(temp[1], temp[2], temp[3], temp[0], temp[4], temp[5], isUse, emptyShelfCnt));
}
else if (temp[1].Equals("A6"))
{
Common.nodeInfo.Add(new DoubleLineNodeFor4D(temp[1], temp[2], temp[3], temp[0], temp[4], temp[5], isUse, emptyShelfCnt));
}
else
Common.nodeInfo.Add(new ClientNode(temp[1], temp[2], temp[3], temp[0], temp[4], temp[5], isUse, emptyShelfCnt));
} }
Common.chargeStatus = new ChargeStatus(); Common.chargeStatus = new ChargeStatus();
Common.itsHttp = Common.appConfig.AppSettings.Settings["ITS"].Value; Common.itsHttp = Common.appConfig.AppSettings.Settings["ITS"].Value;
......
...@@ -76,10 +76,7 @@ namespace AGVControl ...@@ -76,10 +76,7 @@ namespace AGVControl
/// 负载 /// 负载
/// </summary> /// </summary>
public bool IsExistShelf { set; get; } = false; public bool IsExistShelf { set; get; } = false;
/// <summary>
/// 小车的状态,(从小车获取)
/// </summary>
public string StateText { private set; get; }
/// <summary> /// <summary>
/// 电量百分比,(从小车获取) /// 电量百分比,(从小车获取)
/// </summary> /// </summary>
...@@ -88,14 +85,7 @@ namespace AGVControl ...@@ -88,14 +85,7 @@ namespace AGVControl
/// 当前任务文本,(从小车获取) /// 当前任务文本,(从小车获取)
/// </summary> /// </summary>
public string MissionText { set; get; } public string MissionText { set; get; }
/// <summary>
/// 下一个地点
/// </summary>
public string NextPlace { set; get; }
/// <summary>
/// 下一个地点
/// </summary>
public string NextPlaceAliceName { set; get; } = "";
/// <summary> /// <summary>
/// 关门,用于执行一次 /// 关门,用于执行一次
...@@ -129,8 +119,66 @@ namespace AGVControl ...@@ -129,8 +119,66 @@ namespace AGVControl
/// 任务内容 /// 任务内容
/// </summary> /// </summary>
public string Msg { get; set; } public string Msg { get; set; }
/// <summary>
/// 当前任务
/// </summary>
public Job CurJob { get; set; } public Job CurJob { get; set; }
/// <summary>
/// 当前任务的ID号
/// </summary>
public int CurTaskID { get; set; } = -1;
public string CurTaskState { get; set; } = "";
/// <summary>
/// 当前任务名称
/// </summary>
public string CurTaskName { get; set; }
/// <summary>
/// 当前任务的GUID
/// </summary>
public string CurTaskGUID { get; set; }
/// <summary>
/// 当前料架的工单信息
/// </summary>
public string BoxDestInfo { get; set; } = "";
public string RunInfo()
{
Job tmpJob = null;
if (CurJob != null)
{
if (CurJob is ChargeJob)
tmpJob = (ChargeJob)CurJob;
else if (CurJob is EmptyAGVBackJob)
tmpJob = (EmptyAGVBackJob)CurJob;
else if (CurJob is EmptyShelfBackJob)
tmpJob = (EmptyShelfBackJob)CurJob;
else if (CurJob is EnterLeaveShelfJob)
tmpJob = (EnterLeaveShelfJob)CurJob;
else if (CurJob is GoEmptyShelfLineJob)
tmpJob = (GoEmptyShelfLineJob)CurJob;
else if (CurJob is GoFullShelfStationJob)
tmpJob = (GoFullShelfStationJob)CurJob;
else if (CurJob is SendFullShelfToLineJob)
tmpJob = (SendFullShelfToLineJob)CurJob;
if (RFID.StartsWith("C"))
{
return string.Format("Name:{1}{0}RFID:{2}{0}CurJob:{3}{0}CurTaskName:{4}{0}RunStep:{5}{0}BoxDestInfo:{6}{0}GetRack:{7}{0}RunInfo:{8}", "\r\n", Name, RFID,CurJob.ToString(), CurTaskName,Msg, BoxDestInfo, BLL.AGVManager.GetRackBy(RFID),MissionText);
}
else if (!RFID.Equals(""))
{
return string.Format("Name:{1}{0}RFID:{2}{0}CurJob:{3}{0}CurTaskName:{4}{0}RunStep:{5}{0}BoxDestInfo:{6}{0}RunInfo:{7}", "\r\n", Name, RFID, CurJob.ToString(), CurTaskName, Msg, BoxDestInfo,MissionText);
}
else
return string.Format("Name:{1}{0}RFID:{2}{0}CurJob:{3}{0}CurTaskName:{4}{0}RunStep:{5}{0}RunInfo:{6}", "\r\n", Name, RFID, CurJob.ToString(), CurTaskName, Msg,MissionText);
}
else
return string.Format("Name:{1}{0}RFID:{2}{0}CurTaskName:{3}{0}RunInfo:{4}", "\r\n", Name, RFID, CurTaskName,MissionText);
}
public Agv_Info(string id, string name, string ip, string authorization, string ioID, bool isUse, string rfid) public Agv_Info(string id, string name, string ip, string authorization, string ioID, bool isUse, string rfid)
{ {
ID = id; ID = id;
...@@ -143,7 +191,6 @@ namespace AGVControl ...@@ -143,7 +191,6 @@ namespace AGVControl
_IsUse = isUse; _IsUse = isUse;
Place = ""; Place = "";
TaskSend = ""; TaskSend = "";
NextPlace = "";
Msg = ""; Msg = "";
Position = new Agv_Info.clsPosition(); Position = new Agv_Info.clsPosition();
} }
...@@ -154,41 +201,42 @@ namespace AGVControl ...@@ -154,41 +201,42 @@ namespace AGVControl
{ {
bool isChange = false; bool isChange = false;
bool preShelfState = IsExistShelf; bool preShelfState = IsExistShelf;
//if (input != null && input.Length == 4) Common.mir.Get_IO_Status(this, out bool[] input, out bool[] output);
//{ if (input != null && input.Length == 4)
// bool reachIoValue = input[3].Equals(true);//input[2] && {
// if (reachIoValue) bool reachIoValue = input[3].Equals(true);//input[2] &&
// { if (reachIoValue)
// //满足给定的IO值,计算持续时间 {
// if (IoStartTime == DateTime.MaxValue) //满足给定的IO值,计算持续时间
// { if (IoStartTime == DateTime.MaxValue)
// IoStartTime = DateTime.Now; {
// } IoStartTime = DateTime.Now;
}
// if (IoLastTime > 0) if (IoLastTime > 0)
// { {
// //持续时间 //持续时间
// TimeSpan lastTimeSpan = DateTime.Now - IoStartTime; TimeSpan lastTimeSpan = DateTime.Now - IoStartTime;
// IsExistShelf = (lastTimeSpan.TotalMilliseconds >= IoLastTime); IsExistShelf = (lastTimeSpan.TotalMilliseconds >= IoLastTime);
// } }
// else else
// { {
// IsExistShelf = true; IsExistShelf = true;
// } }
// } }
// else else
// { {
// //重新计时 //重新计时
// IoStartTime = DateTime.MinValue; IoStartTime = DateTime.MinValue;
// IsExistShelf = input[3]; IsExistShelf = input[3];
// } }
//} }
if (!StateID.Equals(stateID) || !StateText.Equals(stateText) if (!StateID.Equals(stateID) || !CurTaskState.Equals(stateText)
|| !MissionText.Equals(missionText) || !IsExistShelf.Equals(preShelfState)) //!Battery.Equals(battery) || !MissionText.Equals(missionText) || !IsExistShelf.Equals(preShelfState))
isChange = true; isChange = true;
StateID = stateID; StateID = stateID;
StateText = stateText; CurTaskState = stateText;
Battery = battery; Battery = battery;
MissionText = missionText; MissionText = missionText;
Position = position; Position = position;
...@@ -197,7 +245,7 @@ namespace AGVControl ...@@ -197,7 +245,7 @@ namespace AGVControl
public void GetPlace(int value) public void GetPlace(int value)
{ {
Common.log.Debug(Name + " PLC20=" + value); // Common.log.Debug(Name + " PLC20=" + value);
if (value == 0) if (value == 0)
{ {
Place = ""; Place = "";
...@@ -235,34 +283,35 @@ namespace AGVControl ...@@ -235,34 +283,35 @@ namespace AGVControl
List<string> s = new List<string>(); List<string> s = new List<string>();
s.Add(Name); s.Add(Name);
s.Add(IP); s.Add(IP);
if (IsCon) // if (IsCon)
{ //{
s.Add(StateText); s.Add(StateID.ToString());
s.Add(CurTaskState);
s.Add(RFID); s.Add(RFID);
s.Add(Msg); //s.Add(Msg);
s.Add(MissionText); // s.Add(MissionText);
s.Add(PlaceAliceName); s.Add(PlaceAliceName);
//s.Add(Place); //s.Add(Place);
s.Add(PlaceState.ToString()); s.Add(PlaceState.ToString());
if (Common.nodeInfo != null && Common.nodeInfo.Count != 0) //if (Common.nodeInfo != null && Common.nodeInfo.Count != 0)
{ //{
ClientNode node = Common.nodeInfo.Find(q => q.Name == NextPlace); // ClientNode node = Common.nodeInfo.Find(q => q.Name == NextPlace);
if (node != null) // if (node != null)
NextPlaceAliceName = node.AliceName; // NextPlaceAliceName = node.AliceName;
else // else
NextPlaceAliceName = NextPlace; // NextPlaceAliceName = NextPlace;
} //}
s.Add(NextPlaceAliceName); //s.Add(NextPlaceAliceName);
} //}
else //else
{ //{
s.AddRange(new List<string> { "", "", "", "", "", "", "" }); // s.AddRange(new List<string> { "", "", "", "", "", "", "" });
} //}
s.Add(IsExistShelf ? "满载" : "空载"); s.Add(IsExistShelf ? "满载" : "空载");
s.Add(IsCon ? "在线" : "离线"); s.Add(IsCon ? "在线" : "离线");
s.Add(Battery + "%"); s.Add(Battery + "%");
s.Add(IsUse ? "是" : "否"); s.Add(IsUse ? "是" : "否");
s.Add("清空"); // s.Add("清空");
return s.ToArray(); return s.ToArray();
} }
...@@ -274,7 +323,7 @@ namespace AGVControl ...@@ -274,7 +323,7 @@ namespace AGVControl
/// </summary> /// </summary>
public enum eAGVState public enum eAGVState
{ {
None=0, None = 0,
Starting, Starting,
ShuttingDown, ShuttingDown,
Ready, Ready,
...@@ -287,6 +336,6 @@ namespace AGVControl ...@@ -287,6 +336,6 @@ namespace AGVControl
EmergencyStop, EmergencyStop,
ManualControl, ManualControl,
Error, Error,
NULL UNKNOWN
} }
} }
...@@ -17,10 +17,7 @@ namespace AGVControl ...@@ -17,10 +17,7 @@ namespace AGVControl
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
public abstract bool IsEnd { get; } public abstract bool IsEnd { get; }
/// <summary>
/// 运行信息
/// </summary>
public string RunInfo { get; set; }
/// <summary> /// <summary>
/// 根据任务状态继续执行任务 /// 根据任务状态继续执行任务
/// </summary> /// </summary>
......
...@@ -18,10 +18,11 @@ namespace AGVControl ...@@ -18,10 +18,11 @@ namespace AGVControl
{ {
if (!string.IsNullOrEmpty(value)) if (!string.IsNullOrEmpty(value))
{ {
value = step.ToString() + ":" + value;
//不为空,且与上一个消息不一样才打印 //不为空,且与上一个消息不一样才打印
if (!value.Equals(msg)) if (!value.Equals(msg))
{ {
Common.LogInfo(step.ToString()+":"+value); Common.LogInfo(value);
} }
} }
msg = value; msg = value;
...@@ -58,7 +59,7 @@ namespace AGVControl ...@@ -58,7 +59,7 @@ namespace AGVControl
TimeSpan span = DateTime.Now - startTime; TimeSpan span = DateTime.Now - startTime;
if (span.TotalMilliseconds > timeOutMilliseconds) if (span.TotalMilliseconds > timeOutMilliseconds)
{ {
timeOutValue = span.TotalMilliseconds; timeOutValue = span.TotalSeconds;
return true; return true;
} }
return false; return false;
...@@ -74,7 +75,7 @@ namespace AGVControl ...@@ -74,7 +75,7 @@ namespace AGVControl
startTime = DateTime.Now; startTime = DateTime.Now;
} }
public string StatusStr() public string CurStep()
{ {
return step.ToString(); return step.ToString();
} }
......
...@@ -125,5 +125,23 @@ namespace AGVControl ...@@ -125,5 +125,23 @@ namespace AGVControl
} }
/// <summary>
/// 客户端的优先级
/// </summary>
public enum ClientLevel : byte
{
/// <summary>
/// 低
/// </summary>
Low = 0,
/// <summary>
/// 中等
/// </summary>
Middle = 1,
/// <summary>
/// 高
/// </summary>
High = 2
}
} }
...@@ -30,10 +30,6 @@ namespace AGVControl ...@@ -30,10 +30,6 @@ namespace AGVControl
/// </summary> /// </summary>
private string agvPlace { get; set; } private string agvPlace { get; set; }
/// <summary>
/// 运行信息
/// </summary>
public string RunInfo { get; set; }
public override bool IsEnd { get { return ChargeStep.IsStep(CHARGE_STEP.END); } } public override bool IsEnd { get { return ChargeStep.IsStep(CHARGE_STEP.END); } }
private JobStep<CHARGE_STEP> ChargeStep = new JobStep<CHARGE_STEP>(CHARGE_STEP.NONE); private JobStep<CHARGE_STEP> ChargeStep = new JobStep<CHARGE_STEP>(CHARGE_STEP.NONE);
...@@ -44,56 +40,150 @@ namespace AGVControl ...@@ -44,56 +40,150 @@ namespace AGVControl
/// <param name="agv"></param> /// <param name="agv"></param>
public override Job Execute(Agv_Info agv) public override Job Execute(Agv_Info agv)
{ {
string msg = ""; string msg = agv.Name + " ";
bool rtn = false; bool rtn = false;
agv.Msg = ChargeStep.Msg;
if (ChargeStep.IsStep(CHARGE_STEP.NONE)) if (ChargeStep.IsStep(CHARGE_STEP.NONE))
{ {
if (agv.Battery > Common.chargeStatus.chargeMax)
{
if (agv.Place.StartsWith(SettingString.Standby_Name_Prefix))//在待机位不操作
{
ChargeStep.ToNextStep(CHARGE_STEP.END);
msg += "在待机位,电量充足[" + agv.Battery + "%],等待任务";
ChargeStep.Msg = msg;
}
else if (agvPlace.StartsWith("G"))
{
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_AGV_REACH_4D_DOOR);
msg += "电量充足["+ agv.Battery + "%],从当前位置4C-" + agvPlace + "回到待机位,先到4D门";
ChargeStep.Msg = msg;
Common.DoorMission(agv, SettingString.DoorCToD);
}
else
{
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_STANDBY);
msg += "电量充足[" + agv.Battery + "%],从当前位置" + agvPlace + "回到待机位";
ChargeStep.Msg = msg;
//Common.StatusCharge(agv);
Common.MoveToNode(agv, SettingString.Standby);
}
}
else
{
if (agvPlace.StartsWith("G")) if (agvPlace.StartsWith("G"))
{ {
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_AGV_REACH_4D_DOOR); ChargeStep.ToNextStep(CHARGE_STEP.WAIT_AGV_REACH_4D_DOOR);
msg = "从当前位置" + agvPlace + "回到充电位,先到4D门"; msg += "电量[" + agv.Battery + "%]小于最大电量["+ Common.chargeStatus.chargeMax + "%],从当前位置" + agvPlace + "回到充电位,先到4D门";
ChargeStep.Msg = msg; ChargeStep.Msg = msg;
Common.DoorMission(agv, SettingString.MoveDoorCToD); Common.DoorMission(agv, SettingString.DoorCToD);
}
else
{
if(!Common.StatusCharge(agv))
{
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_STANDBY);
msg += "电量[" + agv.Battery + "%]小于最大电量[" + Common.chargeStatus.chargeMax + "%],充电桩有小车,从当前位置" + agvPlace + "回到待机位";
ChargeStep.Msg = msg;
Common.MoveToNode(agv, SettingString.Standby);
} }
else else
{ {
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_CHARGE_STATION); ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_CHARGE_STATION);
msg = "从当前位置" + agvPlace + "回到充电位"; msg += "电量[" + agv.Battery + "%]小于最大电量[" + Common.chargeStatus.chargeMax + "%],从当前位置" + agvPlace + "回到充电位";
ChargeStep.Msg = msg; ChargeStep.Msg = msg;
Common.StatusCharge(agv); }
} }
} }
}
else if (ChargeStep.IsStep(CHARGE_STEP.WAIT_AGV_REACH_4D_DOOR)) else if (ChargeStep.IsStep(CHARGE_STEP.WAIT_AGV_REACH_4D_DOOR))
{ {
if(agv.Place.Equals(SettingString.D4_DOOR_Name)&& agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, SettingString.DoorCToD, agv.CurTaskGUID))
{ {
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_AGV_REACH_4D_DOOR); if (agv.Battery > Common.chargeStatus.chargeMax)
msg = "从当前位置" + agvPlace + "到4D门"; {
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_STANDBY);
msg += "电量充足[" + agv.Battery + "%],从当前位置" + agvPlace + "回到待机位";
ChargeStep.Msg = msg; ChargeStep.Msg = msg;
Common.StatusCharge(agv); Common.MoveToNode(agv, SettingString.Standby);
}
else
{
if (!Common.StatusCharge(agv))
{
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_STANDBY);
msg += "电量[" + agv.Battery + "%]小于最大电量[" + Common.chargeStatus.chargeMax + "%],充电桩有小车,从当前位置" + agvPlace + "回到待机位";
ChargeStep.Msg = msg;
Common.MoveToNode(agv, SettingString.Standby);
}
else
{
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_CHARGE_STATION);
msg += "电量[" + agv.Battery + "%]小于最大电量[" + Common.chargeStatus.chargeMax + "%],从当前位置" + agvPlace + "回到充电位";
ChargeStep.Msg = msg;
}
}
} }
} }
else if (ChargeStep.IsStep(CHARGE_STEP.WAIT_REACH_CHARGE_STATION)) else if (ChargeStep.IsStep(CHARGE_STEP.WAIT_REACH_CHARGE_STATION))
{ {
if (agv.Place.StartsWith(SettingString.Charge_Name_Prefix) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, agv.CurTaskName))
{ {
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_CHARGE_OK); ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_CHARGE_OK);
msg = "到达充电位"; msg += "充电任务分配完成,去充电且等待任务";
ChargeStep.Msg = msg; ChargeStep.Msg = msg;
} }
} }
else if(ChargeStep.IsStep(CHARGE_STEP.WAIT_REACH_CHARGE_OK)) else if (ChargeStep.IsStep(CHARGE_STEP.WAIT_REACH_CHARGE_OK))
{ {
if(CheckRandomCharge(agv)) if (CheckRandomCharge(agv))
{ {
if (agv.Battery >= Common.chargeStatus.chargeMax) if (agv.Battery >= Common.chargeStatus.chargeMax)
{ {
ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_STANDBY); ChargeStep.ToNextStep(CHARGE_STEP.WAIT_REACH_STANDBY);
msg = "充电完成,回待机位"; msg += "电量充足,回待机位";
ChargeStep.Msg = msg; ChargeStep.Msg = msg;
Common.MoveToNode(agv, SettingString.MoveStandby); if (Common.chargeStatus.charge3.Equals(agv.Name))
{
Common.chargeStatus.charge3 = "";
}
if (Common.chargeStatus.charge4.Equals(agv.Name))
{
Common.chargeStatus.charge4 = "";
}
Common.MoveToNode(agv, SettingString.Standby);
}
else if (agv.Battery >= Common.chargeStatus.chargeMin)
{
Job job = Common.control.GetJob(agv);
if (job != null && !(job is ChargeJob))
{
if (Common.chargeStatus.charge3.Equals(agv.Name))
{
Common.chargeStatus.charge3 = "";
}
if (Common.chargeStatus.charge4.Equals(agv.Name))
{
Common.chargeStatus.charge4 = "";
}
msg += "充电过程检测到任务,电量["+agv.Battery+"]大于最小电量["+Common.chargeStatus.chargeMin+"],中断充电执行任务";
ChargeStep.Msg = msg;
if (Common.chargeStatus.charge3.Equals(agv.Name))
{
Common.chargeStatus.charge3 = "";
}
if (Common.chargeStatus.charge4.Equals(agv.Name))
{
Common.chargeStatus.charge4 = "";
}
return job;
}
} }
} }
else else
...@@ -101,8 +191,26 @@ namespace AGVControl ...@@ -101,8 +191,26 @@ namespace AGVControl
if (agv.Battery >= Common.chargeStatus.chargeMax) if (agv.Battery >= Common.chargeStatus.chargeMax)
{ {
ChargeStep.ToNextStep(CHARGE_STEP.END); ChargeStep.ToNextStep(CHARGE_STEP.END);
msg = "充电完成"; msg += "充电完成";
ChargeStep.Msg = msg;
}
else if (agv.Battery >= Common.chargeStatus.chargeMin)
{
Job job = Common.control.GetJob(agv);
if (job != null && !(job is ChargeJob))
{
msg += "充电过程检测到任务,电量[" + agv.Battery + "]大于最小电量[" + Common.chargeStatus.chargeMin + "],中断充电执行任务";
ChargeStep.Msg = msg; ChargeStep.Msg = msg;
if (Common.chargeStatus.charge3.Equals(agv.Name))
{
Common.chargeStatus.charge3 = "";
}
if (Common.chargeStatus.charge4.Equals(agv.Name))
{
Common.chargeStatus.charge4 = "";
}
return job;
}
} }
} }
...@@ -110,18 +218,31 @@ namespace AGVControl ...@@ -110,18 +218,31 @@ namespace AGVControl
} }
else if (ChargeStep.IsStep(CHARGE_STEP.WAIT_REACH_STANDBY)) else if (ChargeStep.IsStep(CHARGE_STEP.WAIT_REACH_STANDBY))
{ {
if (agv.Place.StartsWith(SettingString.Standby_Name_Prefix) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, SettingString.Standby, agv.CurTaskGUID))
{ {
ChargeStep.ToNextStep(CHARGE_STEP.END); ChargeStep.ToNextStep(CHARGE_STEP.END);
msg = "充电完成,回到达待机位"; msg += "充电完成,到达待机位";
ChargeStep.Msg = msg; ChargeStep.Msg = msg;
} }
} }
else if (ChargeStep.IsStep(CHARGE_STEP.END)) else if (ChargeStep.IsStep(CHARGE_STEP.END))
{ {
Job job = Common.control.GetJob(agv);
if (job != null && !(job is ChargeJob))
{
msg += "在待机位检测到任务,执行任务";
ChargeStep.Msg = msg;
if (Common.chargeStatus.charge3.Equals(agv.Name))
{
Common.chargeStatus.charge3 = "";
}
if (Common.chargeStatus.charge4.Equals(agv.Name))
{
Common.chargeStatus.charge4 = "";
}
return job;
}
} }
RunInfo = ChargeStep.Msg;
return this; return this;
} }
...@@ -131,7 +252,8 @@ namespace AGVControl ...@@ -131,7 +252,8 @@ namespace AGVControl
/// <returns></returns> /// <returns></returns>
private bool CheckRandomCharge(Agv_Info agv) private bool CheckRandomCharge(Agv_Info agv)
{ {
if(agv.IP.Equals(SettingString.RandomCharge_IP1) || agv.IP.Equals(SettingString.RandomCharge_IP2)) if (agv.IP.Equals(SettingString.RandomCharge_IP1) || agv.IP.Equals(SettingString.RandomCharge_IP2) ||
agv.IP.Equals(SettingString.RandomCharge_IP3) || agv.IP.Equals(SettingString.RandomCharge_IP4))
{ {
return true; return true;
} }
......
...@@ -30,10 +30,7 @@ namespace AGVControl ...@@ -30,10 +30,7 @@ namespace AGVControl
/// 接收任务时,agv的位置 /// 接收任务时,agv的位置
/// </summary> /// </summary>
private string agvPlace { get; set; } private string agvPlace { get; set; }
/// <summary>
/// 运行信息
/// </summary>
public string RunInfo { get; set; }
/// <summary> /// <summary>
/// 到达待机位 /// 到达待机位
/// </summary> /// </summary>
...@@ -47,42 +44,77 @@ namespace AGVControl ...@@ -47,42 +44,77 @@ namespace AGVControl
/// <param name="agv"></param> /// <param name="agv"></param>
public override Job Execute(Agv_Info agv) public override Job Execute(Agv_Info agv)
{ {
string msg = ""; string msg = agv.Name+" ";
bool rtn = false; bool rtn = false;
agv.Msg = EmptyAGVBackStep.Msg;
if (EmptyAGVBackStep.IsStep(EMPTY_AGV_BACK_STEP.NONE)) if (EmptyAGVBackStep.IsStep(EMPTY_AGV_BACK_STEP.NONE))
{ {
if(Common.FindEmptyShelfNode(agv,out string nodeName)) if (Common.FindEmptyShelfNode(agv, out string nodeName,true))
{ {
//EmptyAGVBackStep.ToNextStep(EMPTY_AGV_BACK_STEP.END); //EmptyAGVBackStep.ToNextStep(EMPTY_AGV_BACK_STEP.END);
msg = "小车在产线"+agvPlace+"准备返回时检测到"+nodeName+"有空料架"; msg = "小车在产线 " + agvPlace + " 准备返回时检测到 " + nodeName + " 有空料架";
EmptyAGVBackStep.Msg = msg; EmptyAGVBackStep.Msg = msg;
return new GoEmptyShelfLineJob(agvPlace,nodeName); return new GoEmptyShelfLineJob(agvPlace, nodeName);
} }
else else
{ {
if(agvPlace.StartsWith("G")) if (agvPlace.StartsWith("G"))
{ {
EmptyAGVBackStep.ToNextStep(EMPTY_AGV_BACK_STEP.WAIT_AGV_REACH_4D_DOOR); EmptyAGVBackStep.ToNextStep(EMPTY_AGV_BACK_STEP.WAIT_AGV_REACH_4D_DOOR);
msg = "从产线" + agvPlace + "回待机位,先到4D门"; msg = "从产线" + agvPlace + "回待机位,先到4D门";
EmptyAGVBackStep.Msg = msg; EmptyAGVBackStep.Msg = msg;
Common.DoorMission(agv, SettingString.MoveDoorCToD); Common.DoorMission(agv, SettingString.DoorCToD);
} }
else else
{ {
EmptyAGVBackStep.ToNextStep(EMPTY_AGV_BACK_STEP.WAIT_REACH_STANDBY); EmptyAGVBackStep.ToNextStep(EMPTY_AGV_BACK_STEP.WAIT_REACH_STANDBY);
msg = "从产线" + agvPlace + "回到待机位"; msg = "从产线" + agvPlace + "回待机位";
EmptyAGVBackStep.Msg = msg;
Common.MoveToNode(agv, SettingString.Standby);
}
}
}
else if (EmptyAGVBackStep.IsStep(EMPTY_AGV_BACK_STEP.WAIT_REACH_STANDBY))
{
if (Common.CheckTaskFinished(agv, SettingString.Standby, agv.CurTaskGUID))
{
Job job = Common.control.GetJob(agv);
if (job == null && agv.Battery < Common.chargeStatus.chargeMax)
{
msg = "到达待机位,电量[" + agv.Battery + "]小于最大电量[" + Common.chargeStatus.chargeMax + "],暂无任务,去充电";
EmptyAGVBackStep.Msg = msg; EmptyAGVBackStep.Msg = msg;
Common.MoveToNode(agv, SettingString.MoveStandby); return new ChargeJob("");
} }
else
{
msg = "到达待机位,检测到新任务,执行任务";
EmptyAGVBackStep.Msg = msg;
return job;
} }
}
else
{
if (Common.FindFullShelfTask(agv))
{
msg = "从产线" + agvPlace + "回待机位过程中,检测到A6出满料,去A6";
EmptyAGVBackStep.Msg = msg;
return new GoFullShelfStationJob(SettingString.Standby);
}
//else
//{
// msg = "从产线" + agvPlace + "到达4D门,暂无任务,去充电位";
// EmptyAGVBackStep.Msg = msg;
// return new ChargeJob(SettingString.D4_DOOR_Name);
//}
} }
}
else if (EmptyAGVBackStep.IsStep(EMPTY_AGV_BACK_STEP.WAIT_AGV_REACH_4D_DOOR)) else if (EmptyAGVBackStep.IsStep(EMPTY_AGV_BACK_STEP.WAIT_AGV_REACH_4D_DOOR))
{ {
if(agv.Place.Equals(SettingString.D4_DOOR_Name)&& agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, SettingString.DoorCToD, agv.CurTaskGUID))
{ {
if(Common.FindFullShelfTask(agv)) if (Common.FindFullShelfTask(agv))
{ {
msg = "从产线" + agvPlace + "到达4D门,检测到A6出满料,去A6"; msg = "从产线" + agvPlace + "到达4D门,检测到A6出满料,去A6";
EmptyAGVBackStep.Msg = msg; EmptyAGVBackStep.Msg = msg;
...@@ -96,7 +128,6 @@ namespace AGVControl ...@@ -96,7 +128,6 @@ namespace AGVControl
} }
} }
} }
RunInfo = EmptyAGVBackStep.Msg;
return this; return this;
} }
......
...@@ -25,7 +25,7 @@ namespace AGVControl ...@@ -25,7 +25,7 @@ namespace AGVControl
/// 载空料架返回任务 /// 载空料架返回任务
/// </summary> /// </summary>
/// <param name="lineName">产线的节点名称</param> /// <param name="lineName">产线的节点名称</param>
public EmptyShelfBackJob(string lineName,eShelfType shelfType) public EmptyShelfBackJob(string lineName, eShelfType shelfType)
{ {
EmptyShelfPlace = lineName; EmptyShelfPlace = lineName;
this.shelfType = shelfType; this.shelfType = shelfType;
...@@ -39,13 +39,10 @@ namespace AGVControl ...@@ -39,13 +39,10 @@ namespace AGVControl
/// 空料架目的地 /// 空料架目的地
/// </summary> /// </summary>
private string EmptyShelfTargetPlace { get; set; } private string EmptyShelfTargetPlace { get; set; }
/// <summary>
/// 运行信息
/// </summary>
public string RunInfo { get; set; }
private eShelfType shelfType; private eShelfType shelfType;
public override bool IsEnd { get {return EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.END); } } public override bool IsEnd { get { return EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.END); } }
private JobStep<EMPTY_SHELF_BACK_STEP> EmptyBackStep = new JobStep<EMPTY_SHELF_BACK_STEP>(EMPTY_SHELF_BACK_STEP.NONE); private JobStep<EMPTY_SHELF_BACK_STEP> EmptyBackStep = new JobStep<EMPTY_SHELF_BACK_STEP>(EMPTY_SHELF_BACK_STEP.NONE);
...@@ -57,52 +54,54 @@ namespace AGVControl ...@@ -57,52 +54,54 @@ namespace AGVControl
{ {
string msg = ""; string msg = "";
bool rtn = false; bool rtn = false;
agv.Msg = EmptyBackStep.Msg;
if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.NONE)) if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.NONE))
{ {
Common.DelEmptyShelfTask(EmptyShelfPlace);
if (EmptyShelfPlace.StartsWith("G"))//4车间 if (EmptyShelfPlace.StartsWith("G"))//4车间
{ {
EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_DOOR); EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_DOOR);
msg = "空料架从产线"+ EmptyShelfPlace + "前往4D门"; msg = "空料架从产线" + EmptyShelfPlace + "前往4D门";
EmptyBackStep.Msg = msg; EmptyBackStep.Msg = msg;
Common.DoorMission(agv, SettingString.MoveDoorCToD); Common.DoorMission(agv, SettingString.DoorCToD);
} }
else else
{ {
if (Common.CheckA5A6State(agv,shelfType, out string nodeName)) if (Common.CheckA5A6State(agv, shelfType, out string nodeName))
{ {
EmptyShelfTargetPlace = nodeName; EmptyShelfTargetPlace = nodeName;
EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6); EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6);
msg = "空料架从产线 [" + EmptyShelfTargetPlace + "] 送往双层线"; msg = "空料架从产线 [" + EmptyShelfPlace + "] 送往双层线" + EmptyShelfTargetPlace;
EmptyBackStep.Msg = msg; EmptyBackStep.Msg = msg;
if (!EmptyShelfTargetPlace.Equals(""))
Common.MoveToNode(agv, EmptyShelfTargetPlace);
} }
else else
{ {
EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_STANDBY); EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_STANDBY);
msg = "双层线暂不需要空料架,从产线[" + EmptyShelfTargetPlace + "]到待机位"; msg = "双层线暂不需要空料架,从产线[" + EmptyShelfPlace + "]到待机位";
EmptyBackStep.Msg = msg; EmptyBackStep.Msg = msg;
Common.MoveToNode(agv, SettingString.MoveStandby); Common.MoveToNode(agv, SettingString.Standby);
} }
} }
} }
else if(EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_DOOR)) else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_DOOR))
{ {
if(agv.Place.Equals(SettingString.D4_DOOR_Name) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, SettingString.DoorCToD, agv.CurTaskGUID))
{ {
if (Common.CheckA5A6State(agv, shelfType, out string nodeName)) if (Common.CheckA5A6State(agv, shelfType, out string nodeName))
{ {
EmptyShelfTargetPlace = nodeName; EmptyShelfTargetPlace = nodeName;
EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6); EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6);
msg = "空料架从产线 [" + EmptyShelfTargetPlace + "] 送往双层线"; msg = "空料架从产线 [" + EmptyShelfPlace + "] 送往双层线" + EmptyShelfTargetPlace;
EmptyBackStep.Msg = msg; EmptyBackStep.Msg = msg;
Common.MoveToNode(agv, EmptyShelfTargetPlace);
} }
else else
{ {
EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_STANDBY); EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_STANDBY);
msg = "双层线暂不需要空料架,从产线[" + EmptyShelfTargetPlace + "]到待机位"; msg = "双层线暂不需要空料架,从产线[" + EmptyShelfPlace + "]到待机位";
EmptyBackStep.Msg = msg; EmptyBackStep.Msg = msg;
Common.MoveToNode(agv, SettingString.MoveStandby); Common.MoveToNode(agv, SettingString.Standby);
} }
} }
} }
...@@ -112,63 +111,81 @@ namespace AGVControl ...@@ -112,63 +111,81 @@ namespace AGVControl
{ {
EmptyShelfTargetPlace = nodeName; EmptyShelfTargetPlace = nodeName;
EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6); EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6);
msg = "待机位检测到双层线需要料架,送往双层线 "+EmptyShelfTargetPlace; msg = "待机位检测到双层线需要料架,送往双层线 " + EmptyShelfTargetPlace;
EmptyBackStep.Msg = msg; EmptyBackStep.Msg = msg;
Common.MoveToNode(agv, EmptyShelfTargetPlace);
} }
} }
else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6)) else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6))
{ {
if(agv.Place.Equals(EmptyShelfTargetPlace) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, EmptyShelfTargetPlace, agv.CurTaskGUID) && EmptyShelfTargetPlace.StartsWith("A"))
{ {
msg = "AGV到达 " + EmptyShelfTargetPlace; //msg = "AGV到达 " + EmptyShelfTargetPlace;
EmptyBackStep.Msg = msg;
return new EnterLeaveShelfJob(EmptyShelfTargetPlace,eEnterLeaveType.Leave,shelfType);
//EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_DOUBLE_LINE_RESPONSE);
//msg = "AGV到达 " + EmptyShelfTargetPlace + ",并发送入料架请求[ReadyEnter]";
//EmptyBackStep.Msg = msg; //EmptyBackStep.Msg = msg;
//Common.server.ReadyEnter(EmptyShelfTargetPlace); //return new EnterLeaveShelfJob(EmptyShelfTargetPlace,eEnterLeaveType.Leave,shelfType);
} EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_DOUBLE_LINE_RESPONSE);
} msg = "AGV到达 " + EmptyShelfTargetPlace + ",并发送入料架请求[ReadyEnter]";
//else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.WAIT_DOUBLE_LINE_RESPONSE)) EmptyBackStep.Msg = msg;
//{ Common.server.ReadyEnter(EmptyShelfTargetPlace);
// int id = Common.FindNode(EmptyShelfTargetPlace); }
// ClientNode node = Common.nodeInfo[id]; }
// if (node.StateEquals(eNodeStatus.MayEnter)) else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.WAIT_DOUBLE_LINE_RESPONSE))
// { {
// EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT__EMPTY_SHELF_IN_DOUBLE_LINE); int id = Common.FindNode(EmptyShelfTargetPlace);
// msg = "收到双层线入料架请求[ReadyEnter]的响应 " + EmptyShelfTargetPlace + "入料架,小车链条运行"; ClientNode node = Common.nodeInfo[id];
// EmptyBackStep.Msg = msg; if (node.StateEquals(eNodeStatus.MayEnter))
// rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Leave"]); {
// agv.TaskSend = rtn ? "Leave" : ""; if(!agv.CurTaskName.Equals("Leave"))
// } {
// else if (EmptyBackStep.IsTimeOut(15000, out double timeOutValue)) EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT__EMPTY_SHELF_IN_DOUBLE_LINE);
// { msg = "收到双层线入料架请求[ReadyEnter]的响应 " + EmptyShelfTargetPlace + "入料架,小车链条运行";
// EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6); EmptyBackStep.Msg = msg;
// msg = "AGV到达 " + EmptyShelfTargetPlace + ",15秒后重新向双层线发送入料架请求[ReadyEnter]"; rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Leave"]);
// EmptyBackStep.Msg = msg; agv.TaskSend = rtn ? "Leave" : "";
// } }
//}
//else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.WAIT__EMPTY_SHELF_IN_DOUBLE_LINE))
//{
// if (agv.Place.Equals(EmptyShelfTargetPlace) && agv.PlaceState.Equals(ePlaceState.LeaveFinish))
// {
// EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.END); }
// msg = "空料架进入" + EmptyShelfTargetPlace + "完成"; else if (EmptyBackStep.IsTimeOut(15000, out double timeOutValue))
// EmptyBackStep.Msg = msg; {
// } EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.WAIT_AGV_REACH_A5A6);
// else if (EmptyBackStep.IsTimeOut(60000, out double timeOutValue)) msg = "AGV到达 " + EmptyShelfTargetPlace + ",15秒后重新向双层线发送入料架请求[ReadyEnter]";
// { EmptyBackStep.Msg = msg;
// //链条停止 }
// msg = "空料架在[" + EmptyShelfTargetPlace + "]离开小车超时[" + timeOutValue.ToString("f1") + "秒],请检查料架离开小车的情况"; }
// EmptyBackStep.Msg = msg; else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.WAIT__EMPTY_SHELF_IN_DOUBLE_LINE))
// } {
if (agv.Place.Equals(EmptyShelfTargetPlace) && agv.PlaceState.Equals(ePlaceState.LeaveFinish))
{
//EmptyBackStep.ToNextStep(EMPTY_SHELF_BACK_STEP.END);
agv.RFID = "";
Job job = Common.control.GetJob(agv);
if (job != null)
{
msg += "在双层线检测到任务,执行任务";
EmptyBackStep.Msg = msg;
return job;
}
else
{
msg = "空料架进入" + EmptyShelfTargetPlace + "完成,暂无任务,回充电位";
EmptyBackStep.Msg = msg;
return new ChargeJob(SettingString.DoubleLine_Name_Prefix);
}
}
else if (EmptyBackStep.IsTimeOut(60000, out double timeOutValue))
{
//链条停止
msg = "空料架在[" + EmptyShelfTargetPlace + "]离开小车超时[" + timeOutValue.ToString("f1") + "秒],请检查料架离开小车的情况";
EmptyBackStep.Msg = msg;
}
}
else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.END))
{
}
//}
//else if (EmptyBackStep.IsStep(EMPTY_SHELF_BACK_STEP.END))
//{
//}
RunInfo = EmptyBackStep.Msg;
return this; return this;
} }
......
...@@ -46,13 +46,10 @@ namespace AGVControl ...@@ -46,13 +46,10 @@ namespace AGVControl
/// <summary> /// <summary>
/// 位置名 /// 位置名
/// </summary> /// </summary>
public string LineName { get; set; } public new string LineName { get; set; }
public string RFID { get; set; } public string RFID { get; set; }
/// <summary>
/// 运行信息
/// </summary>
public string RunInfo { get; set; }
public eEnterLeaveType ActionType { get; set; } public eEnterLeaveType ActionType { get; set; }
private eShelfType shelfType; private eShelfType shelfType;
...@@ -64,22 +61,32 @@ namespace AGVControl ...@@ -64,22 +61,32 @@ namespace AGVControl
{ {
string msg = ""; string msg = "";
bool rtn = false; bool rtn = false;
agv.Msg = EnterLeaveShelfStep.Msg;
if (EnterLeaveShelfStep.IsStep(ENTER_LEAVE_SHELF_STEP.NONE)) if (EnterLeaveShelfStep.IsStep(ENTER_LEAVE_SHELF_STEP.NONE))
{ {
if (ActionType.Equals(eEnterLeaveType.Leave)) if (ActionType.Equals(eEnterLeaveType.Leave))
{ {
EnterLeaveShelfStep.ToNextStep(ENTER_LEAVE_SHELF_STEP.WAIT_LINE_ReadyEnter_RESPONSE); //EnterLeaveShelfStep.ToNextStep(ENTER_LEAVE_SHELF_STEP.WAIT_LINE_ReadyEnter_RESPONSE);
msg = "AGV到达 " + LineName + ",并发送入料架请求[ReadyEnter]"; //msg = "AGV到达 " + LineName + ",并发送入料架请求[ReadyEnter]";
//EnterLeaveShelfStep.Msg = msg;
//Common.server.ReadyEnter(LineName);
EnterLeaveShelfStep.ToNextStep(ENTER_LEAVE_SHELF_STEP.WAIT__SHELF_IN_LINE);
msg = LineName + "入料架,小车链条运行";
EnterLeaveShelfStep.Msg = msg; EnterLeaveShelfStep.Msg = msg;
Common.server.ReadyEnter(LineName); rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Leave"]);
agv.TaskSend = rtn ? "Leave" : "";
} }
else if(ActionType.Equals(eEnterLeaveType.Enter)) else if(ActionType.Equals(eEnterLeaveType.Enter))
{ {
EnterLeaveShelfStep.ToNextStep(ENTER_LEAVE_SHELF_STEP.WAIT_LINE_ReadyLeave_RESPONSE); //EnterLeaveShelfStep.ToNextStep(ENTER_LEAVE_SHELF_STEP.WAIT_LINE_ReadyLeave_RESPONSE);
msg = "AGV到达 " + LineName + ",并发送出料架请求[ReadyLeave]"; //msg = "AGV到达 " + LineName + ",并发送出料架请求[ReadyLeave]";
//EnterLeaveShelfStep.Msg = msg;
//Common.server.ReadyLeave(LineName);
EnterLeaveShelfStep.ToNextStep(ENTER_LEAVE_SHELF_STEP.WAIT__SHELF_OUT_LINE);
msg = LineName + "出料架,小车链条运行";
EnterLeaveShelfStep.Msg = msg; EnterLeaveShelfStep.Msg = msg;
Common.server.ReadyLeave(LineName); rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Enter"]);
agv.TaskSend = rtn ? "Enter" : "";
} }
} }
else if (EnterLeaveShelfStep.IsStep(ENTER_LEAVE_SHELF_STEP.WAIT_LINE_ReadyEnter_RESPONSE)) else if (EnterLeaveShelfStep.IsStep(ENTER_LEAVE_SHELF_STEP.WAIT_LINE_ReadyEnter_RESPONSE))
...@@ -128,6 +135,7 @@ namespace AGVControl ...@@ -128,6 +135,7 @@ namespace AGVControl
//EnterLeaveShelfStep.ToNextStep(ENTER_LEAVE_SHELF_STEP.END); //EnterLeaveShelfStep.ToNextStep(ENTER_LEAVE_SHELF_STEP.END);
msg = "料架进入" + LineName + "完成 ["+RFID+"]"; msg = "料架进入" + LineName + "完成 ["+RFID+"]";
EnterLeaveShelfStep.Msg = msg; EnterLeaveShelfStep.Msg = msg;
agv.RFID = "";
return new EmptyAGVBackJob(LineName); return new EmptyAGVBackJob(LineName);
} }
...@@ -160,7 +168,7 @@ namespace AGVControl ...@@ -160,7 +168,7 @@ namespace AGVControl
else if (EnterLeaveShelfStep.IsStep(ENTER_LEAVE_SHELF_STEP.END)) else if (EnterLeaveShelfStep.IsStep(ENTER_LEAVE_SHELF_STEP.END))
{ {
} }
RunInfo = EnterLeaveShelfStep.Msg;
return this; return this;
} }
......
...@@ -34,10 +34,7 @@ namespace AGVControl ...@@ -34,10 +34,7 @@ namespace AGVControl
/// 接收任务时,agv的位置 /// 接收任务时,agv的位置
/// </summary> /// </summary>
private string agvPlae { get; set; } private string agvPlae { get; set; }
/// <summary>
/// 运行信息
/// </summary>
public string RunInfo { get; set; }
public override bool IsEnd { get { return TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.END); } } public override bool IsEnd { get { return TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.END); } }
...@@ -49,8 +46,9 @@ namespace AGVControl ...@@ -49,8 +46,9 @@ namespace AGVControl
/// <param name="agv"></param> /// <param name="agv"></param>
public override Job Execute(Agv_Info agv) public override Job Execute(Agv_Info agv)
{ {
string msg = ""; string msg = agv.Name+" ";
bool rtn = false; bool rtn = false;
agv.Msg = TakeEmptyStep.Msg;
int nodeIdx = Common.FindNode(EmptyShelfPlace); int nodeIdx = Common.FindNode(EmptyShelfPlace);
if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.NONE)) if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.NONE))
...@@ -58,39 +56,40 @@ namespace AGVControl ...@@ -58,39 +56,40 @@ namespace AGVControl
if (agvPlae.StartsWith("G") && EmptyShelfPlace.StartsWith("E"))//4C->4D if (agvPlae.StartsWith("G") && EmptyShelfPlace.StartsWith("E"))//4C->4D
{ {
TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_AGV_REACH_4D_DOOR); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_AGV_REACH_4D_DOOR);
msg = "去空料架产线" + EmptyShelfPlace + ",先前往4D门["+ agvPlae +"->"+ EmptyShelfPlace + "]"; msg += "去空料架产线" + EmptyShelfPlace + ",先前往4D门[" + agvPlae + "->" + EmptyShelfPlace + "]";
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
Common.DoorMission(agv, SettingString.MoveDoorCToD); Common.DoorMission(agv, SettingString.DoorCToD);
} }
else if (agvPlae.StartsWith("E") && EmptyShelfPlace.StartsWith("G"))//4D->4C else if ((agvPlae.StartsWith("E") || agvPlae.StartsWith("A"))
&& EmptyShelfPlace.StartsWith("G"))//4D->4C
{ {
TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_AGV_REACH_4C_DOOR); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_AGV_REACH_4C_DOOR);
msg = "去空料架产线" + EmptyShelfPlace + ",先前往4C门[" + agvPlae + "->" + EmptyShelfPlace + "]"; msg += "去空料架产线" + EmptyShelfPlace + ",先前往4C门[" + agvPlae + "->" + EmptyShelfPlace + "]";
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
Common.DoorMission(agv, SettingString.MoveDoorDToC); Common.DoorMission(agv, SettingString.DoorDToC);
} }
else else
{ {
TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.ASSIGN_AGV_TASK); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.ASSIGN_AGV_TASK);
msg = "开始执行回收空料架任务[" + agvPlae + "->" + EmptyShelfPlace + "]"; msg += "开始执行回收空料架任务[" + agvPlae + "->" + EmptyShelfPlace + "]";
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
} }
} }
else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_AGV_REACH_4C_DOOR)) else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_AGV_REACH_4C_DOOR))
{ {
if(agv.Place.Equals(SettingString.C4_DOOR_Name) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, SettingString.DoorDToC, agv.CurTaskGUID))
{ {
TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.ASSIGN_AGV_TASK); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.ASSIGN_AGV_TASK);
msg = "开始执行回收空料架任务[" + agvPlae + "->" + EmptyShelfPlace + "]"; msg += "开始执行回收空料架任务[" + agvPlae + "->" + EmptyShelfPlace + "]";
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
} }
} }
else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_AGV_REACH_4D_DOOR)) else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_AGV_REACH_4D_DOOR))
{ {
if (agv.Place.Equals(SettingString.D4_DOOR_Name) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, SettingString.DoorCToD, agv.CurTaskGUID))
{ {
TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.ASSIGN_AGV_TASK); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.ASSIGN_AGV_TASK);
msg = "开始执行回收空料架任务[" + agvPlae + "->" + EmptyShelfPlace + "]"; msg += "开始执行回收空料架任务[" + agvPlae + "->" + EmptyShelfPlace + "]";
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
} }
} }
...@@ -100,82 +99,104 @@ namespace AGVControl ...@@ -100,82 +99,104 @@ namespace AGVControl
if (nodeIdx > -1) if (nodeIdx > -1)
{ {
TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_AGV_START_TASK); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_AGV_START_TASK);
msg = "AGV 添加任务:移动到" + EmptyShelfPlace; msg += "AGV 添加任务:移动到" + EmptyShelfPlace;
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
Common.MoveToNode(agv, EmptyShelfPlace); Common.MoveToNode(agv, EmptyShelfPlace);
} }
else else
{ {
TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.ASSIGN_AGV_TASK); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.ASSIGN_AGV_TASK);
msg = EmptyShelfPlace + " 不存在或未开启调用"; msg += EmptyShelfPlace + " 不存在或未开启调用";
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
} }
} }
else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_AGV_START_TASK)) else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_AGV_START_TASK))
{ {
if (agv.PlaceState.Equals(ePlaceState.Move)) if (agv.CurTaskState.Equals(SettingString.Executing))
{ {
TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_REACH_PLACE); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_REACH_PLACE);
msg = "AGV开始向目的地[" + EmptyShelfPlace + "]移动"; msg += "AGV开始向目的地[" + EmptyShelfPlace + "]移动";
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
} }
} }
else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_REACH_PLACE)) else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_REACH_PLACE))
{ {
if (agv.Place.Equals(EmptyShelfPlace) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, EmptyShelfPlace, agv.CurTaskGUID))
{ {
msg = "AGV到达 " + EmptyShelfPlace; if (EmptyShelfPlace.Equals("G22"))
{
msg += "AGV到达 " + EmptyShelfPlace;
TakeEmptyStep.Msg = msg; TakeEmptyStep.Msg = msg;
return new EnterLeaveShelfJob(EmptyShelfPlace, eEnterLeaveType.Enter); return new EnterLeaveShelfJob(EmptyShelfPlace, eEnterLeaveType.Enter);
//TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_LINE_RESPONSE); }
//msg = "AGV到达 " + EmptyShelfPlace + " 向产线发送出料架请求[ReadyLeave]"; else
//TakeEmptyStep.Msg = msg; {
//Common.server.ReadyLeave(EmptyShelfPlace); TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_LINE_RESPONSE);
} msg += "AGV到达 " + EmptyShelfPlace + " 向产线发送出料架请求[ReadyLeave]";
} TakeEmptyStep.Msg = msg;
//else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_LINE_RESPONSE)) Common.server.ReadyLeave(EmptyShelfPlace);
//{ }
// ClientNode node = Common.nodeInfo[nodeIdx];
// if (node.StateEquals(eNodeStatus.MayLeave)) }
// { }
// TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_TAKE_EMPTY_SHELF); else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_LINE_RESPONSE))
// msg = "收到产线出料请求[ReadyLeave]的响应 " + EmptyShelfPlace + "出料架,小车链条运行"; {
// TakeEmptyStep.Msg = msg; ClientNode node = Common.nodeInfo[nodeIdx];
// rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Enter"]); if (node.StateEquals(eNodeStatus.MayLeave))
// agv.TaskSend = rtn ? "Enter" : ""; {
// } if(!agv.CurTaskName.Equals("Enter"))
// else if (TakeEmptyStep.IsTimeOut(15000, out double timeOutValue)) {
// { TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_TAKE_EMPTY_SHELF);
// TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_REACH_PLACE); msg += "收到产线出料请求[ReadyLeave]的响应 " + EmptyShelfPlace + "出料架,小车链条运行";
// msg = "AGV到达 " + EmptyShelfPlace + ",15秒后重新向产线发送出料架请求[ReadyLeave]"; TakeEmptyStep.Msg = msg;
// TakeEmptyStep.Msg = msg; agv.RFID = node.RFID;
// } rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Enter"]);
//} agv.TaskSend = rtn ? "Enter" : "";
//else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_TAKE_EMPTY_SHELF)) }
//{
// if (agv.PlaceState.Equals(ePlaceState.EnterFinish)) }
// { else if (TakeEmptyStep.IsTimeOut(15000, out double timeOutValue))
// ClientNode node = Common.nodeInfo[nodeIdx]; {
// node.AgvName = ""; TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.WAIT_REACH_PLACE);
// //回收空料架数量减少1 msg += "AGV到达 " + EmptyShelfPlace + ",15秒后重新向产线发送出料架请求[ReadyLeave]";
TakeEmptyStep.Msg = msg;
}
}
else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.WAIT_TAKE_EMPTY_SHELF))
{
if (agv.PlaceState.Equals(ePlaceState.EnterFinish))
{
ClientNode node = Common.nodeInfo[nodeIdx];
node.AgvName = "";
//回收空料架数量减少1
// node.DecreEmptyShelfCnt(); // node.DecreEmptyShelfCnt();
// TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.END); //TakeEmptyStep.ToNextStep(TAKE_EMPTY_STEP.END);
// msg = "空料架在[" + EmptyShelfPlace + "]进入小车完成"; //if (shelfType.Equals(eShelfType.SmallShelf))
// TakeEmptyStep.Msg = msg; Common.DelEmptyShelfTask(EmptyShelfPlace);
// } msg += "空料架在[" + EmptyShelfPlace + "]进入小车完成";
// else if (TakeEmptyStep.IsTimeOut(60000, out double timeOutValue)) TakeEmptyStep.Msg = msg;
// { if(agv.RFID.StartsWith("D"))
// //链条停止 return new EmptyShelfBackJob(EmptyShelfPlace, eShelfType.SmallShelf);
// msg = "空料架在[" + EmptyShelfPlace + "]进入小车超时[" + timeOutValue.ToString("f1") + "秒],请检查料架进入小车的情况"; else if(agv.RFID.StartsWith("C"))
// TakeEmptyStep.Msg = msg; {
// } return new EmptyShelfBackJob(EmptyShelfPlace, eShelfType.BigShelf);
}
//} else
return new EmptyShelfBackJob(EmptyShelfPlace, eShelfType.SmallShelf);
}
else if (TakeEmptyStep.IsTimeOut(60000, out double timeOutValue))
{
//链条停止
msg += "空料架在[" + EmptyShelfPlace + "]进入小车超时[" + timeOutValue.ToString("f1") + "秒],请检查料架进入小车的情况";
TakeEmptyStep.Msg = msg;
}
}
else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.END)) else if (TakeEmptyStep.IsStep(TAKE_EMPTY_STEP.END))
{ {
} }
RunInfo= TakeEmptyStep.Msg;
return this; return this;
} }
......
...@@ -31,10 +31,6 @@ namespace AGVControl ...@@ -31,10 +31,6 @@ namespace AGVControl
public string FullShelfStationPlace { get; set; } public string FullShelfStationPlace { get; set; }
/// <summary> /// <summary>
/// 运行信息
/// </summary>
public string RunInfo { get; set; }
/// <summary>
/// 接到任务时,AGV的位置 /// 接到任务时,AGV的位置
/// </summary> /// </summary>
public string agvPlace { get; set; } public string agvPlace { get; set; }
...@@ -52,6 +48,7 @@ namespace AGVControl ...@@ -52,6 +48,7 @@ namespace AGVControl
{ {
string msg = ""; string msg = "";
bool rtn = false; bool rtn = false;
agv.Msg = GoFullShelfStationStep.Msg;
if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.NONE)) if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.NONE))
{ {
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_CHECK_RESULT); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_CHECK_RESULT);
...@@ -61,10 +58,14 @@ namespace AGVControl ...@@ -61,10 +58,14 @@ namespace AGVControl
} }
else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_CHECK_RESULT)) else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_CHECK_RESULT))
{ {
if (GoFullShelfStationStep.IsTimeOut(15000, out double timeOutValue)) //Common.log.Debug("WAIT_CHECK_RESULT " + Common.agvMission["CheckShelf"].Equals(agv.CurTaskGUID).ToString() + " " + agv.CurTaskGUID + " " + Common.agvMission["CheckShelf"]);
if (Common.agvMission["CheckShelf"].Equals(agv.CurTaskGUID) && agv.CurTaskState.Equals(SettingString.Done))
{
rtn = Common.mir.Get_IO_Status(agv, out bool[] input, out bool[] output);
if(rtn)
{ {
Common.mir.Get_IO_Status(agv, out bool[] input, out bool[] output); Common.log.Debug("WAIT_CHECK_RESULT: "+agv.Name+" 获取IO状态成功:满载信号="+input[3].ToString());
if (!input.Equals(null) && input[3]) if (input !=null && input[3])
{ {
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.END); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.END);
msg = agv.Name + " 车上有料架,无法去入料口出料"; msg = agv.Name + " 车上有料架,无法去入料口出料";
...@@ -72,12 +73,40 @@ namespace AGVControl ...@@ -72,12 +73,40 @@ namespace AGVControl
agv.IsExistShelf = true; agv.IsExistShelf = true;
IsLoadOnAGV = true; IsLoadOnAGV = true;
} }
else if (!input.Equals(null) && !input[3]) else if (input !=null && !input[3])
{
if (agvPlace.StartsWith(SettingString.Charge_Name_Prefix) || agvPlace.StartsWith(SettingString.Standby_Name_Prefix))//待机位/充电位接到任务
{
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6);
msg = agv.Name + " 无负载,准备运动到入料口"+ FullShelfStationPlace;
GoFullShelfStationStep.Msg = msg;
Common.MoveToNode(agv, FullShelfStationPlace);
}
else if (agvPlace.StartsWith("G"))//4C车间
{
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_DOOR);
msg = agv.Name + " 在4C车间,向4D门运行,再到双层线入料口";
GoFullShelfStationStep.Msg = msg;
Common.DoorMission(agv, SettingString.DoorCToD);
}
else
{
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6);
msg = agv.Name + " 无负载,准备运动到入料口" + FullShelfStationPlace;
GoFullShelfStationStep.Msg = msg;
Common.MoveToNode(agv, FullShelfStationPlace);
}
}
}
else
{
Common.LogInfo("WAIT_CHECK_RESULT: 获取IO状态失败,使用小车IO信号");
if (!agv.IsExistShelf)
{ {
if (agvPlace.Equals(""))//待机位接到任务 if (agvPlace.Equals(""))//待机位接到任务
{ {
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6);
msg = agv.Name + " 无负载,准备运动到入料口"; msg = agv.Name + " 无负载,准备运动到入料口" + FullShelfStationPlace;
GoFullShelfStationStep.Msg = msg; GoFullShelfStationStep.Msg = msg;
Common.MoveToNode(agv, FullShelfStationPlace); Common.MoveToNode(agv, FullShelfStationPlace);
} }
...@@ -86,18 +115,20 @@ namespace AGVControl ...@@ -86,18 +115,20 @@ namespace AGVControl
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_DOOR); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_DOOR);
msg = agv.Name + " 在4C车间,向4D门运行,再到双层线入料口"; msg = agv.Name + " 在4C车间,向4D门运行,再到双层线入料口";
GoFullShelfStationStep.Msg = msg; GoFullShelfStationStep.Msg = msg;
Common.DoorMission(agv, SettingString.MoveDoorCToD); Common.DoorMission(agv, SettingString.DoorCToD);
} }
} }
}
} }
} }
else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_DOOR)) else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_DOOR))
{ {
if (agv.Place.Equals(SettingString.D4_DOOR_Name) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, SettingString.DoorCToD, agv.CurTaskGUID))
{ {
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6);
msg = agv.Name + " 到达4D门,准备运动到双层线入料口"; msg = agv.Name + " 到达4D门,准备运动到双层线入料口" + FullShelfStationPlace;
GoFullShelfStationStep.Msg = msg; GoFullShelfStationStep.Msg = msg;
Common.MoveToNode(agv, FullShelfStationPlace); Common.MoveToNode(agv, FullShelfStationPlace);
} }
...@@ -105,15 +136,17 @@ namespace AGVControl ...@@ -105,15 +136,17 @@ namespace AGVControl
} }
else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6)) else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6))
{ {
if (agv.Place.Equals(FullShelfStationPlace) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, FullShelfStationPlace, agv.CurTaskGUID))
{ {
ClientNode node = Common.nodeInfo.Find(s => s.Name.Equals(SettingString.A6) ClientNode node = Common.nodeInfo.Find(s => s.Name.Equals(SettingString.A6)
&& (s.StateEquals(eNodeStatus.NeedEnterLeave) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && !s.RFID.Equals("00")); && (s.StateEquals(eNodeStatus.NeedLeave) || s.StateEquals(eNodeStatus.NeedEnterLeave)) && !s.RFID.Equals("00"));
if (node.Name.Equals(SettingString.A6)) if (node != null && node.Name.Equals(SettingString.A6))
{ {
if (AGVManager.FindFullShelfTarget(node.RFID, out FullShelfDestInfo)) if (AGVManager.FindFullShelfTarget(node.RFID, out FullShelfDestInfo))
{ {
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_DOUBLE_LINE_RESPONSE); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_DOUBLE_LINE_RESPONSE);
if (!FullShelfDestInfo.Equals(null))
agv.BoxDestInfo = FullShelfDestInfo.ShowInfo();
msg = "AGV到达 " + FullShelfStationPlace + ",并发送出料架请求[ReadyLeave]"; msg = "AGV到达 " + FullShelfStationPlace + ",并发送出料架请求[ReadyLeave]";
GoFullShelfStationStep.Msg = msg; GoFullShelfStationStep.Msg = msg;
Common.server.ReadyLeave(FullShelfStationPlace); Common.server.ReadyLeave(FullShelfStationPlace);
...@@ -131,17 +164,22 @@ namespace AGVControl ...@@ -131,17 +164,22 @@ namespace AGVControl
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_REACH_STANDBY); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_REACH_STANDBY);
msg = "从产线" + agvPlace + "回到待机位"; msg = "从产线" + agvPlace + "回到待机位";
GoFullShelfStationStep.Msg = msg; GoFullShelfStationStep.Msg = msg;
Common.MoveToNode(agv, SettingString.MoveStandby); Common.MoveToNode(agv, SettingString.Standby);
} }
} }
} }
} }
//else if (GoFullShelfStationStep.IsTimeOut(30000, out double timeOutValue) && !agv.TaskSend.Equals(SettingString.Move + SettingString.A6)
// && !agv.CurTaskName.Equals(SettingString.Move+SettingString.A6))
//{
// Common.MoveToNode(agv, FullShelfStationPlace);
//}
} }
else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_REACH_STANDBY)) else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_REACH_STANDBY))
{ {
if (agv.Place.StartsWith(SettingString.Standby_Name_Prefix) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv, SettingString.Standby, agv.CurTaskGUID))
{ {
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.END); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.END);
msg = "到达待机位"; msg = "到达待机位";
...@@ -151,15 +189,25 @@ namespace AGVControl ...@@ -151,15 +189,25 @@ namespace AGVControl
else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_DOUBLE_LINE_RESPONSE)) else if (GoFullShelfStationStep.IsStep(GO_FULL_SHELF_STATION_STEP.WAIT_DOUBLE_LINE_RESPONSE))
{ {
int id = Common.FindNode(FullShelfStationPlace); int id = Common.FindNode(FullShelfStationPlace);
if (id == -1)
{
msg = "未找到节点:" + FullShelfStationPlace;
GoFullShelfStationStep.Msg = msg;
return this;
}
ClientNode node = Common.nodeInfo[id]; ClientNode node = Common.nodeInfo[id];
if (node.StateEquals(eNodeStatus.MayLeave)) if (node.StateEquals(eNodeStatus.MayLeave))
{ {
if(!agv.CurTaskName.Equals("Enter"))
{
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT__FULL_SHELF_IN_AGV); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT__FULL_SHELF_IN_AGV);
msg = "收到双层线出料架请求[ReadyLeave]的响应 " + FullShelfStationPlace + "出料架,小车链条运行"; msg = "收到双层线出料架请求[ReadyLeave]的响应 " + FullShelfStationPlace + "出料架,小车链条运行";
GoFullShelfStationStep.Msg = msg; GoFullShelfStationStep.Msg = msg;
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Enter"]); rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Enter"]);
agv.TaskSend = rtn ? "Enter" : ""; agv.TaskSend = rtn ? "Enter" : "";
} }
}
else if (GoFullShelfStationStep.IsTimeOut(15000, out double timeOutValue)) else if (GoFullShelfStationStep.IsTimeOut(15000, out double timeOutValue))
{ {
GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6); GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.WAIT_AGV_REACH_A6);
...@@ -177,11 +225,11 @@ namespace AGVControl ...@@ -177,11 +225,11 @@ namespace AGVControl
//GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.END); //GoFullShelfStationStep.ToNextStep(GO_FULL_SHELF_STATION_STEP.END);
msg = FullShelfStationPlace + "满料架进入小车完成"; msg = FullShelfStationPlace + "满料架进入小车完成";
GoFullShelfStationStep.Msg = msg; GoFullShelfStationStep.Msg = msg;
if (FullShelfDestInfo.location.StartsWith("G")) //if (FullShelfDestInfo.location.StartsWith("G"))
{ //{
return new SendFullShelfToLineJob(FullShelfDestInfo, true); // return new SendFullShelfToLineJob(FullShelfDestInfo, true);
} //}
else //else
return new SendFullShelfToLineJob(FullShelfDestInfo); return new SendFullShelfToLineJob(FullShelfDestInfo);
} }
else if (GoFullShelfStationStep.IsTimeOut(60000, out double timeOutValue)) else if (GoFullShelfStationStep.IsTimeOut(60000, out double timeOutValue))
...@@ -192,7 +240,7 @@ namespace AGVControl ...@@ -192,7 +240,7 @@ namespace AGVControl
} }
} }
RunInfo = GoFullShelfStationStep.Msg;
return this; return this;
} }
......
...@@ -35,16 +35,14 @@ namespace AGVControl ...@@ -35,16 +35,14 @@ namespace AGVControl
public string FullShelfPlace { get; set; } public string FullShelfPlace { get; set; }
public string RFID { get; set; } public string RFID { get; set; }
/// <summary>
/// 运行信息
/// </summary>
public string RunInfo { get; set; }
public AGVManager.BoxDestInfo BoxDestInfo { get; private set; } public AGVManager.BoxDestInfo BoxDestInfo { get; private set; }
/// <summary> /// <summary>
/// 是否忽略大料架移库解绑 /// 是否忽略大料架移库解绑
/// </summary> /// </summary>
public bool IsIgnoreBigShelf { get; private set; } public bool IsIgnoreBigShelf { get; private set; }
public override bool IsEnd { get { return SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.END); } } public override bool IsEnd { get { return SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.END); } }
private JobStep<SEND_FULL_SHELF_STEP> SendFullShelfStep = new JobStep<SEND_FULL_SHELF_STEP>(SEND_FULL_SHELF_STEP.NONE); private JobStep<SEND_FULL_SHELF_STEP> SendFullShelfStep = new JobStep<SEND_FULL_SHELF_STEP>(SEND_FULL_SHELF_STEP.NONE);
...@@ -53,15 +51,17 @@ namespace AGVControl ...@@ -53,15 +51,17 @@ namespace AGVControl
{ {
string msg = ""; string msg = "";
bool rtn = false; bool rtn = false;
agv.RFID = RFID;
agv.Msg = SendFullShelfStep.Msg;
if (SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.NONE)) if (SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.NONE))
{ {
if(FullShelfPlace.StartsWith("G")) if(FullShelfPlace.StartsWith("G"))
{ {
SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_DOOR); SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_DOOR);
msg = "满料架前往4C门,从双层线A6送往[" + FullShelfPlace + "][" + RFID + "]"+ BoxDestInfo.ShowInfo(); msg = "满料架前往4C门,从双层线A6送往[" + FullShelfPlace + "][" + RFID + "]"+ BoxDestInfo.ShowInfo();
SendFullShelfStep.Msg = msg; SendFullShelfStep.Msg = msg;
Common.DoorMission(agv, SettingString.MoveDoorDToC); Common.DoorMission(agv, SettingString.DoorDToC);
} }
else else
{ {
...@@ -75,7 +75,7 @@ namespace AGVControl ...@@ -75,7 +75,7 @@ namespace AGVControl
else if (SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_DOOR)) else if (SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_DOOR))
{ {
if (agv.Place.Equals(SettingString.C4_DOOR_Name) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv,SettingString.DoorDToC,agv.CurTaskGUID))
{ {
SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_LINE); SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_LINE);
msg = "满料架从双层线A6送往[" + FullShelfPlace + "][" + RFID + "]" + BoxDestInfo.ShowInfo(); msg = "满料架从双层线A6送往[" + FullShelfPlace + "][" + RFID + "]" + BoxDestInfo.ShowInfo();
...@@ -85,10 +85,14 @@ namespace AGVControl ...@@ -85,10 +85,14 @@ namespace AGVControl
} }
else if (SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_LINE)) else if (SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_LINE))
{ {
if (agv.Place.Equals(FullShelfPlace) && agv.PlaceState.Equals(ePlaceState.MoveFinish)) if (Common.CheckTaskFinished(agv,FullShelfPlace,agv.CurTaskGUID))
{ {
// msg = "AGV到达 " + FullShelfPlace + ",并发送入料架请求[ReadyEnter]" + BoxDestInfo.ShowInfo(); if(FullShelfPlace.Equals("G21"))
//SendFullShelfStep.Msg = msg; {
msg = "AGV到达 " + FullShelfPlace + "完成" + BoxDestInfo.ShowInfo();
SendFullShelfStep.Msg = msg;
return new EnterLeaveShelfJob(FullShelfPlace, eEnterLeaveType.Leave);
}
if (IsIgnoreBigShelf) if (IsIgnoreBigShelf)
{ {
SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_LINE_RESPONSE); SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_LINE_RESPONSE);
...@@ -98,7 +102,7 @@ namespace AGVControl ...@@ -98,7 +102,7 @@ namespace AGVControl
} }
else else
{ {
if (RFID.StartsWith("C")) if (RFID.StartsWith("C") && !agv.Place.Equals("E21"))
{ {
SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_BIG_SHELF_UNLOCK); SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_BIG_SHELF_UNLOCK);
msg = "AGV到达 " + FullShelfPlace + ",并等待大料架[" + RFID + "]解绑" + BoxDestInfo.ShowInfo(); msg = "AGV到达 " + FullShelfPlace + ",并等待大料架[" + RFID + "]解绑" + BoxDestInfo.ShowInfo();
...@@ -131,12 +135,16 @@ namespace AGVControl ...@@ -131,12 +135,16 @@ namespace AGVControl
ClientNode node = Common.nodeInfo[id]; ClientNode node = Common.nodeInfo[id];
if (node.StateEquals(eNodeStatus.MayEnter)) if (node.StateEquals(eNodeStatus.MayEnter))
{ {
if(!agv.CurTaskName.Equals("Leave"))
{
SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT__SHELF_IN_LINE); SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT__SHELF_IN_LINE);
msg = "收到产线入料架请求[ReadyEnter]的响应 " + FullShelfPlace + "入料架,小车链条运行" + BoxDestInfo.ShowInfo(); msg = "收到产线入料架请求[ReadyEnter]的响应 " + FullShelfPlace + "入料架,小车链条运行" + BoxDestInfo.ShowInfo();
SendFullShelfStep.Msg = msg; SendFullShelfStep.Msg = msg;
rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Leave"]); rtn = Common.mir.Add_Mission_Fleet(agv, Common.agvMission["Leave"]);
agv.TaskSend = rtn ? "Leave" : ""; agv.TaskSend = rtn ? "Leave" : "";
} }
}
else if (SendFullShelfStep.IsTimeOut(15000, out double timeOutValue)) else if (SendFullShelfStep.IsTimeOut(15000, out double timeOutValue))
{ {
SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_LINE); SendFullShelfStep.ToNextStep(SEND_FULL_SHELF_STEP.WAIT_AGV_REACH_LINE);
...@@ -150,6 +158,7 @@ namespace AGVControl ...@@ -150,6 +158,7 @@ namespace AGVControl
{ {
msg = "满料架进入" + FullShelfPlace + "完成 [" + RFID + "]" + BoxDestInfo.ShowInfo(); msg = "满料架进入" + FullShelfPlace + "完成 [" + RFID + "]" + BoxDestInfo.ShowInfo();
SendFullShelfStep.Msg = msg; SendFullShelfStep.Msg = msg;
agv.RFID = "";
AGVManager.UpdateStatus(RFID, FullShelfPlace); AGVManager.UpdateStatus(RFID, FullShelfPlace);
return new EmptyAGVBackJob(FullShelfPlace); return new EmptyAGVBackJob(FullShelfPlace);
} }
...@@ -161,10 +170,11 @@ namespace AGVControl ...@@ -161,10 +170,11 @@ namespace AGVControl
} }
} }
else if (SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.END)) //else if (SendFullShelfStep.IsStep(SEND_FULL_SHELF_STEP.END))
{ //{
}
RunInfo = SendFullShelfStep.Msg; //}
return this; return this;
} }
......
...@@ -48,6 +48,8 @@ namespace AGVControl ...@@ -48,6 +48,8 @@ namespace AGVControl
/// 节点位置名称 /// 节点位置名称
/// </summary> /// </summary>
public string Pos_name { get; set; } public string Pos_name { get; set; }
public ClientLevel ClientLevel { get; set; } = ClientLevel.Low;
/// <summary> /// <summary>
/// 节点位置坐标 /// 节点位置坐标
/// </summary> /// </summary>
...@@ -145,26 +147,27 @@ namespace AGVControl ...@@ -145,26 +147,27 @@ namespace AGVControl
/// <returns></returns> /// <returns></returns>
public string StatetText() public string StatetText()
{ {
string s = string.Format("[Name={0}, NodeStatus={1}, RFID={2}, AGVName={3}]", Name, nodeStatus.ToString(), RFID, AgvName); string s = string.Format("[Name={0}, NodeStatus={1}, RFID={2},ClientLevel ={3}]", Name, nodeStatus.ToString(), RFID, ClientLevel.ToString());
return s; return s;
} }
public string[] ToRow() public string[] ToRow()
{ {
//节点,IP,动作,RFID,AGV名称,在线,调用,清除AGV //节点,IP,动作,RFID,AGV名称,在线,调用,清除AGV
string[] s = new string[9]; string[] s = new string[8];
s[0] = AliceName; s[0] = AliceName;
s[1] = IP; s[1] = IP;
// if (Online) // if (Online)
// { // {
s[2] = EmptyShelfCnt.ToString();//string.Format("({0},{1})", position.X.ToString("f2"), position.Y.ToString("f2")); s[2] = EmptyShelfCnt.ToString();//string.Format("({0},{1})", position.X.ToString("f2"), position.Y.ToString("f2"));
s[3] = nodeStatus.ToString(); s[3] = nodeStatus.ToString();
s[4] = RFID; s[4] = ClientLevel.ToString();
s[5] = AgvName; s[5] = RFID;
// s[5] = AgvName;
// } // }
s[6] = Online ? "在线" : "离线"; s[6] = Online ? "在线" : "离线";
s[7] = IsUse ? "是" : "否"; s[7] = IsUse ? "是" : "否";
s[8] = "清除"; // s[8] = "清除";
return s; return s;
} }
......
...@@ -22,7 +22,8 @@ namespace AGVControl ...@@ -22,7 +22,8 @@ namespace AGVControl
/// <returns></returns> /// <returns></returns>
public override Job GetNewJob(Agv_Info currentAgv) public override Job GetNewJob(Agv_Info currentAgv)
{ {
if (!SettingString.C4_AGV_IPs.Contains(currentAgv.IP))
return null;
if (!Common.CheckCanExecuteMission(currentAgv)) if (!Common.CheckCanExecuteMission(currentAgv))
return null; return null;
if (!Common.CheckAGVStatusNone(currentAgv)) if (!Common.CheckAGVStatusNone(currentAgv))
...@@ -67,12 +68,36 @@ namespace AGVControl ...@@ -67,12 +68,36 @@ namespace AGVControl
//出满料 //出满料
if (Common.FindFullShelfTask(currentAgv)) if (Common.FindFullShelfTask(currentAgv))
{ {
if (SettingString.C4_AGV_IPs.Contains(currentAgv.IP))
{
int i = Common.agvInfo.FindIndex(s => s.CurJob is GoFullShelfStationJob && !s.IP.Equals(currentAgv.IP));
if (i > -1)
return null;
}
//foreach (Agv_Info agv in Common.agvInfo)
//{
// if (agv.CurJob is GoFullShelfStationJob)
// {
// return null;
// }
//}
return new GoFullShelfStationJob(currentAgv.Place); return new GoFullShelfStationJob(currentAgv.Place);
} }
//回收空料架 //回收空料架
if (Common.FindEmptyShelfNode(currentAgv, out string emptyNodeName)) if (Common.FindEmptyShelfNode(currentAgv, out string emptyNodeName))
{ {
foreach (Agv_Info agv in Common.agvInfo)
{
if (!SettingString.C4_AGV_IPs.Contains(agv.IP))
continue;
if (agv.CurJob is GoEmptyShelfLineJob && ((GoEmptyShelfLineJob)agv.CurJob).EmptyShelfPlace.Equals(emptyNodeName))
{
return null;
}
}
return new GoEmptyShelfLineJob(currentAgv.Place, emptyNodeName); return new GoEmptyShelfLineJob(currentAgv.Place, emptyNodeName);
} }
return null; return null;
......
...@@ -24,7 +24,8 @@ namespace AGVControl ...@@ -24,7 +24,8 @@ namespace AGVControl
/// <returns></returns> /// <returns></returns>
public override Job GetNewJob(Agv_Info currentAgv) public override Job GetNewJob(Agv_Info currentAgv)
{ {
if (SettingString.C4_AGV_IPs.Contains(currentAgv.IP))
return null;
if (!Common.CheckCanExecuteMission(currentAgv)) if (!Common.CheckCanExecuteMission(currentAgv))
return null; return null;
if (!Common.CheckAGVStatusNone(currentAgv)) if (!Common.CheckAGVStatusNone(currentAgv))
...@@ -71,12 +72,28 @@ namespace AGVControl ...@@ -71,12 +72,28 @@ namespace AGVControl
//出满料 //出满料
if (Common.FindFullShelfTask(currentAgv)) if (Common.FindFullShelfTask(currentAgv))
{ {
if (!SettingString.C4_AGV_IPs.Contains(currentAgv.IP))
{
int i = Common.agvInfo.FindIndex(s=>s.CurJob is GoFullShelfStationJob && !s.IP.Equals(currentAgv.IP));
if(i>-1)
return null;
}
return new GoFullShelfStationJob(currentAgv.Place); return new GoFullShelfStationJob(currentAgv.Place);
} }
//回收空料架 //回收空料架
if (Common.FindEmptyShelfNode(currentAgv, out string emptyNodeName)) if (Common.FindEmptyShelfNode(currentAgv, out string emptyNodeName))
{ {
foreach (Agv_Info agv in Common.agvInfo)
{
if (SettingString.C4_AGV_IPs.Contains(agv.IP))
continue;
if (agv.CurJob is GoEmptyShelfLineJob && ((GoEmptyShelfLineJob)agv.CurJob).EmptyShelfPlace.Equals(emptyNodeName))
{
return null;
}
}
return new GoEmptyShelfLineJob(currentAgv.Place, emptyNodeName); return new GoEmptyShelfLineJob(currentAgv.Place, emptyNodeName);
} }
return null; return null;
......
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
</layout> </layout>
</appender> </appender>
<logger> <logger>
<level value="Debug"/> <level value="ALL"/>
<appender-ref ref="LineWebService"/> <appender-ref ref="LineWebService"/>
</logger> </logger>
<root> <root>
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
<host> <host>
<baseAddresses> <baseAddresses>
<!--添加调用服务地址--> <!--添加调用服务地址-->
<add baseAddress="http://10.85.199.1/BenQMIR/Webservice/AGVService.asmx/"/> <add baseAddress="http://127.0.0.1/BenQMIR/Webservice/AGVService.asmx/"/>
</baseAddresses> </baseAddresses>
</host> </host>
......
Fleet ID,agv,IP,Ȩ,IOID
1,MiR_R1580,10.85.199.81,Basic ZGlzdHJpYnV0b3I6NjJmMmYwZjFlZmYxMGQzMTUyYzk1ZjZmMDU5NjU3NmU0ODJiYjhlNDQ4MDY0MzNmNGNmOTI5NzkyODM0YjAxNA==,007615a5-2220-11ea-99f2-94c691a73b53
2020-08-29 21:42:35,E1
2020-08-29 21:42:49,E22
2020-08-29 21:42:55,G5
[A5]
EmptyShelfCnt=0
IsUse=False
[E14]
EmptyShelfCnt=0
[MiR_R1763] [MiR_R1763]
IsUse=False
RFID= RFID=
[MiR_R1764]
IsUse=False IsUse=False
[MiR_R1764]
RFID= RFID=
[MiR_R1767] [MiR_R1767]
IsUse=False
RFID= RFID=
[E10]
EmptyShelfCnt=0
[MiR_R1768] [MiR_R1768]
RFID= RFID=
[MiR_R1579] [MiR_R1579]
RFID= RFID=
[MiR_R1580] [MiR_R1580]
RFID= RFID=
[E4] IsUse=True
EmptyShelfCnt=0 [E1]
[E3] EmptyShelfCnt=1
IsUse=True
[A5]
IsUse=False
[E2]
EmptyShelfCnt=0 EmptyShelfCnt=0
IsUse=False
[E22]
EmptyShelfCnt=1
[G5]
EmptyShelfCnt=1
[G9]
IsUse=False

\ No newline at end of file \ No newline at end of file

\ No newline at end of file \ No newline at end of file

\ No newline at end of file \ No newline at end of file
3fb131896028187df2e3607393bdb409455980a9 ce147cdc7d5f84ac5eea7abfb5866dce563042b6
[2020-07-19 17:07:54,759][1]INFO SetStatus Name=E1, Action=None, Level=Low [2020-08-31 09:35:08,871][1]INFO SetStatus Name=E21, Action=None, Level=Low
[2020-07-19 17:07:54,783][1]INFO SetStatus Name=E2, Action=None, Level=Low [2020-08-31 09:35:08,877][1]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:07:54,783][1]INFO SetStatus Name=E3, Action=None, Level=Low [2020-08-31 09:35:08,877][1]INFO SetStatus Name=G21, Action=None, Level=Low
[2020-07-19 17:07:54,784][1]INFO SetStatus Name=E4, Action=None, Level=Low [2020-08-31 09:35:08,877][1]INFO SetStatus Name=G22, Action=None, Level=Low
[2020-07-19 17:07:54,784][1]INFO SetStatus Name=E5, Action=None, Level=Low [2020-08-31 09:35:08,878][1]INFO Connect
[2020-07-19 17:07:54,785][1]INFO SetStatus Name=E6, Action=None, Level=Low [2020-08-31 09:35:08,878][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:07:54,785][1]INFO SetStatus Name=E8, Action=None, Level=Low [2020-08-31 09:35:08,902][3]ERROR CheckIP()
[2020-07-19 17:07:54,785][1]INFO SetStatus Name=E9, Action=None, Level=Low System.Net.NetworkInformation.PingException: Ping 请求期间发生异常。 ---> System.ComponentModel.Win32Exception: Unknown error (0x2b2a)
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E10, Action=None, Level=Low 在 System.Net.NetworkInformation.Ping.InternalSend(IPAddress address, Byte[] buffer, Int32 timeout, PingOptions options, Boolean async)
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E11, Action=None, Level=Low 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E12, Action=None, Level=Low --- 内部异常堆栈跟踪的结尾 ---
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E14, Action=None, Level=Low 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E15, Action=None, Level=Low 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E16, Action=None, Level=Low 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout)
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E21, Action=None, Level=Low 在 AsaPL.AgvClient.CheckIP(String ip) 位置 C:\ZDL\Gitee\AGVControl-Qisda-ProductionLine\AgvClient\AgvClient.cs:行号 440
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E22, Action=None, Level=Low [2020-08-31 09:35:08,928][3]INFO Server connection failed 1 times
[2020-07-19 17:07:54,789][1]INFO Connect [2020-08-31 09:35:09,928][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:07:54,790][3]INFO Connect 10.85.199.1:9501 [2020-08-31 09:35:09,928][3]ERROR CheckIP()
[2020-07-19 17:07:56,385][3]INFO Ping 10.85.199.1 request timeout System.Net.NetworkInformation.PingException: Ping 请求期间发生异常。 ---> System.ComponentModel.Win32Exception: Unknown error (0x2b2a)
[2020-07-19 17:07:56,386][3]INFO Server connection failed 1 times 在 System.Net.NetworkInformation.Ping.InternalSend(IPAddress address, Byte[] buffer, Int32 timeout, PingOptions options, Boolean async)
[2020-07-19 17:07:57,387][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:07:59,385][3]INFO Ping 10.85.199.1 request timeout --- 内部异常堆栈跟踪的结尾 ---
[2020-07-19 17:07:59,385][3]INFO Server connection failed 2 times 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:00,386][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:02,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout)
[2020-07-19 17:08:02,385][3]INFO Server connection failed 3 times 在 AsaPL.AgvClient.CheckIP(String ip) 位置 C:\ZDL\Gitee\AGVControl-Qisda-ProductionLine\AgvClient\AgvClient.cs:行号 440
[2020-07-19 17:08:03,386][3]INFO Connect 10.85.199.1:9501 [2020-08-31 09:35:09,928][3]INFO Server connection failed 2 times
[2020-07-19 17:08:05,385][3]INFO Ping 10.85.199.1 request timeout [2020-08-31 09:35:10,930][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:05,385][3]INFO Server connection failed 4 times [2020-08-31 09:35:10,930][3]ERROR CheckIP()
[2020-07-19 17:08:06,386][3]INFO Connect 10.85.199.1:9501 System.Net.NetworkInformation.PingException: Ping 请求期间发生异常。 ---> System.ComponentModel.Win32Exception: Unknown error (0x2b2a)
[2020-07-19 17:08:08,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.InternalSend(IPAddress address, Byte[] buffer, Int32 timeout, PingOptions options, Boolean async)
[2020-07-19 17:08:08,385][3]INFO Server connection failed 5 times 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:09,386][3]INFO Connect 10.85.199.1:9501 --- 内部异常堆栈跟踪的结尾 ---
[2020-07-19 17:08:11,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:11,385][3]INFO Server connection failed 6 times 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:12,386][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout)
[2020-07-19 17:08:14,385][3]INFO Ping 10.85.199.1 request timeout 在 AsaPL.AgvClient.CheckIP(String ip) 位置 C:\ZDL\Gitee\AGVControl-Qisda-ProductionLine\AgvClient\AgvClient.cs:行号 440
[2020-07-19 17:08:14,386][3]INFO Server connection failed 7 times [2020-08-31 09:35:10,930][3]INFO Server connection failed 3 times
[2020-07-19 17:08:15,386][3]INFO Connect 10.85.199.1:9501 [2020-08-31 09:35:11,931][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:17,386][3]INFO Ping 10.85.199.1 request timeout [2020-08-31 09:35:11,931][3]ERROR CheckIP()
[2020-07-19 17:08:17,386][3]INFO Server connection failed 8 times System.Net.NetworkInformation.PingException: Ping 请求期间发生异常。 ---> System.ComponentModel.Win32Exception: Unknown error (0x2b2a)
[2020-07-19 17:08:18,386][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.InternalSend(IPAddress address, Byte[] buffer, Int32 timeout, PingOptions options, Boolean async)
[2020-07-19 17:08:20,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:20,385][3]INFO Server connection failed 9 times --- 内部异常堆栈跟踪的结尾 ---
[2020-07-19 17:08:21,386][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:23,386][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:23,386][3]INFO Server connection failed 10 times 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout)
[2020-07-19 17:08:24,386][3]INFO Connect 10.85.199.1:9501 在 AsaPL.AgvClient.CheckIP(String ip) 位置 C:\ZDL\Gitee\AGVControl-Qisda-ProductionLine\AgvClient\AgvClient.cs:行号 440
[2020-07-19 17:08:26,385][3]INFO Ping 10.85.199.1 request timeout [2020-08-31 09:35:11,931][3]INFO Server connection failed 4 times
[2020-07-19 17:08:26,385][3]INFO Server connection failed 11 times [2020-08-31 09:35:12,932][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:27,386][3]INFO Connect 10.85.199.1:9501 [2020-08-31 09:35:12,932][3]ERROR CheckIP()
[2020-07-19 17:08:27,622][6]INFO SetStatus Name=E2, Action=MayEnter, Level=Low System.Net.NetworkInformation.PingException: Ping 请求期间发生异常。 ---> System.ComponentModel.Win32Exception: Unknown error (0x2b2a)
[2020-07-19 17:08:29,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.InternalSend(IPAddress address, Byte[] buffer, Int32 timeout, PingOptions options, Boolean async)
[2020-07-19 17:08:29,385][3]INFO Server connection failed 12 times 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:30,386][3]INFO Connect 10.85.199.1:9501 --- 内部异常堆栈跟踪的结尾 ---
[2020-07-19 17:08:32,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:32,385][3]INFO Server connection failed 13 times 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:33,386][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout)
[2020-07-19 17:08:35,386][3]INFO Ping 10.85.199.1 request timeout 在 AsaPL.AgvClient.CheckIP(String ip) 位置 C:\ZDL\Gitee\AGVControl-Qisda-ProductionLine\AgvClient\AgvClient.cs:行号 440
[2020-07-19 17:08:35,386][3]INFO Server connection failed 14 times [2020-08-31 09:35:12,932][3]INFO Server connection failed 5 times
[2020-07-19 17:08:36,386][3]INFO Connect 10.85.199.1:9501 [2020-08-31 09:35:13,934][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:37,627][6]INFO SetStatus Name=E2, Action=None, Level=Low [2020-08-31 09:35:13,934][3]ERROR CheckIP()
[2020-07-19 17:08:38,385][3]INFO Ping 10.85.199.1 request timeout System.Net.NetworkInformation.PingException: Ping 请求期间发生异常。 ---> System.ComponentModel.Win32Exception: Unknown error (0x2b2a)
[2020-07-19 17:08:38,385][3]INFO Server connection failed 15 times 在 System.Net.NetworkInformation.Ping.InternalSend(IPAddress address, Byte[] buffer, Int32 timeout, PingOptions options, Boolean async)
[2020-07-19 17:08:39,386][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:41,386][3]INFO Ping 10.85.199.1 request timeout --- 内部异常堆栈跟踪的结尾 ---
[2020-07-19 17:08:41,386][3]INFO Server connection failed 16 times 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:42,387][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:44,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout)
[2020-07-19 17:08:44,385][3]INFO Server connection failed 17 times 在 AsaPL.AgvClient.CheckIP(String ip) 位置 C:\ZDL\Gitee\AGVControl-Qisda-ProductionLine\AgvClient\AgvClient.cs:行号 440
[2020-07-19 17:08:45,386][3]INFO Connect 10.85.199.1:9501 [2020-08-31 09:35:13,934][3]INFO Server connection failed 6 times
[2020-07-19 17:08:47,385][3]INFO Ping 10.85.199.1 request timeout [2020-08-31 09:35:14,935][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:47,385][3]INFO Server connection failed 18 times [2020-08-31 09:35:14,935][3]ERROR CheckIP()
[2020-07-19 17:08:48,386][3]INFO Connect 10.85.199.1:9501 System.Net.NetworkInformation.PingException: Ping 请求期间发生异常。 ---> System.ComponentModel.Win32Exception: Unknown error (0x2b2a)
[2020-07-19 17:08:50,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.InternalSend(IPAddress address, Byte[] buffer, Int32 timeout, PingOptions options, Boolean async)
[2020-07-19 17:08:50,385][3]INFO Server connection failed 19 times 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:51,386][3]INFO Connect 10.85.199.1:9501 --- 内部异常堆栈跟踪的结尾 ---
[2020-07-19 17:08:53,385][3]INFO Ping 10.85.199.1 request timeout 在 System.Net.NetworkInformation.Ping.Send(IPAddress address, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:53,385][3]INFO Server connection failed 20 times 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout, Byte[] buffer, PingOptions options)
[2020-07-19 17:08:54,386][3]INFO Connect 10.85.199.1:9501 在 System.Net.NetworkInformation.Ping.Send(String hostNameOrAddress, Int32 timeout)
[2020-07-19 17:08:56,385][3]INFO Ping 10.85.199.1 request timeout 在 AsaPL.AgvClient.CheckIP(String ip) 位置 C:\ZDL\Gitee\AGVControl-Qisda-ProductionLine\AgvClient\AgvClient.cs:行号 440
[2020-07-19 17:08:56,385][3]INFO Server connection failed 21 times [2020-08-31 09:35:14,935][3]INFO Server connection failed 7 times
[2020-07-19 17:08:57,386][3]INFO Connect 10.85.199.1:9501 [2020-08-31 09:35:14,965][1]INFO Close
[2020-07-19 17:08:59,128][7]INFO SetStatus Name=A5, Action=None, Level=Low
[2020-07-19 17:08:59,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:59,385][3]INFO Server connection failed 22 times
[2020-07-19 17:09:00,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:02,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:02,385][3]INFO Server connection failed 23 times
[2020-07-19 17:09:03,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:05,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:05,386][3]INFO Server connection failed 24 times
[2020-07-19 17:09:06,387][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:08,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:08,385][3]INFO Server connection failed 25 times
[2020-07-19 17:09:09,129][7]INFO SetStatus Name=A5, Action=None, Level=Low
[2020-07-19 17:09:09,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:11,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:11,385][3]INFO Server connection failed 26 times
[2020-07-19 17:09:12,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:14,002][8]INFO SetStatus Name=E2, Action=MayEnter, Level=Low
[2020-07-19 17:09:14,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:14,385][3]INFO Server connection failed 27 times
[2020-07-19 17:09:15,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:17,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:17,386][3]INFO Server connection failed 28 times
[2020-07-19 17:09:18,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:20,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:20,385][3]INFO Server connection failed 29 times
[2020-07-19 17:09:21,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:23,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:23,386][3]INFO Server connection failed 30 times
[2020-07-19 17:09:24,005][8]INFO SetStatus Name=E2, Action=None, Level=Low
[2020-07-19 17:09:24,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:26,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:26,385][3]INFO Server connection failed 31 times
[2020-07-19 17:09:27,273][7]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:27,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:29,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:29,386][3]INFO Server connection failed 32 times
[2020-07-19 17:09:29,744][8]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:29,994][9]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,190][10]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:30,433][11]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,634][12]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,830][13]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,993][14]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:31,744][15]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:32,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:32,386][3]INFO Server connection failed 33 times
[2020-07-19 17:09:33,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:35,258][1]INFO Close
[2020-07-19 17:09:35,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:35,386][3]INFO Server connection failed 34 times
[2020-07-19 17:07:54,759][1]INFO SetStatus Name=E1, Action=None, Level=Low
[2020-07-19 17:07:54,783][1]INFO SetStatus Name=E2, Action=None, Level=Low
[2020-07-19 17:07:54,783][1]INFO SetStatus Name=E3, Action=None, Level=Low
[2020-07-19 17:07:54,784][1]INFO SetStatus Name=E4, Action=None, Level=Low
[2020-07-19 17:07:54,784][1]INFO SetStatus Name=E5, Action=None, Level=Low
[2020-07-19 17:07:54,785][1]INFO SetStatus Name=E6, Action=None, Level=Low
[2020-07-19 17:07:54,785][1]INFO SetStatus Name=E8, Action=None, Level=Low
[2020-07-19 17:07:54,785][1]INFO SetStatus Name=E9, Action=None, Level=Low
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E10, Action=None, Level=Low
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E11, Action=None, Level=Low
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E12, Action=None, Level=Low
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E14, Action=None, Level=Low
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E15, Action=None, Level=Low
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E16, Action=None, Level=Low
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E21, Action=None, Level=Low
[2020-07-19 17:07:54,786][1]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:07:54,789][1]INFO Connect
[2020-07-19 17:07:54,790][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:07:56,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:07:56,386][3]INFO Server connection failed 1 times
[2020-07-19 17:07:57,387][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:07:59,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:07:59,385][3]INFO Server connection failed 2 times
[2020-07-19 17:08:00,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:02,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:02,385][3]INFO Server connection failed 3 times
[2020-07-19 17:08:03,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:05,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:05,385][3]INFO Server connection failed 4 times
[2020-07-19 17:08:06,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:08,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:08,385][3]INFO Server connection failed 5 times
[2020-07-19 17:08:09,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:11,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:11,385][3]INFO Server connection failed 6 times
[2020-07-19 17:08:12,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:14,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:14,386][3]INFO Server connection failed 7 times
[2020-07-19 17:08:15,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:17,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:17,386][3]INFO Server connection failed 8 times
[2020-07-19 17:08:18,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:20,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:20,385][3]INFO Server connection failed 9 times
[2020-07-19 17:08:21,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:23,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:23,386][3]INFO Server connection failed 10 times
[2020-07-19 17:08:24,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:26,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:26,385][3]INFO Server connection failed 11 times
[2020-07-19 17:08:27,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:27,622][6]INFO SetStatus Name=E2, Action=MayEnter, Level=Low
[2020-07-19 17:08:29,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:29,385][3]INFO Server connection failed 12 times
[2020-07-19 17:08:30,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:32,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:32,385][3]INFO Server connection failed 13 times
[2020-07-19 17:08:33,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:35,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:35,386][3]INFO Server connection failed 14 times
[2020-07-19 17:08:36,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:37,627][6]INFO SetStatus Name=E2, Action=None, Level=Low
[2020-07-19 17:08:38,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:38,385][3]INFO Server connection failed 15 times
[2020-07-19 17:08:39,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:41,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:41,386][3]INFO Server connection failed 16 times
[2020-07-19 17:08:42,387][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:44,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:44,385][3]INFO Server connection failed 17 times
[2020-07-19 17:08:45,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:47,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:47,385][3]INFO Server connection failed 18 times
[2020-07-19 17:08:48,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:50,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:50,385][3]INFO Server connection failed 19 times
[2020-07-19 17:08:51,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:53,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:53,385][3]INFO Server connection failed 20 times
[2020-07-19 17:08:54,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:56,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:56,385][3]INFO Server connection failed 21 times
[2020-07-19 17:08:57,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:08:59,128][7]INFO SetStatus Name=A5, Action=None, Level=Low
[2020-07-19 17:08:59,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:08:59,385][3]INFO Server connection failed 22 times
[2020-07-19 17:09:00,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:02,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:02,385][3]INFO Server connection failed 23 times
[2020-07-19 17:09:03,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:05,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:05,386][3]INFO Server connection failed 24 times
[2020-07-19 17:09:06,387][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:08,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:08,385][3]INFO Server connection failed 25 times
[2020-07-19 17:09:09,129][7]INFO SetStatus Name=A5, Action=None, Level=Low
[2020-07-19 17:09:09,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:11,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:11,385][3]INFO Server connection failed 26 times
[2020-07-19 17:09:12,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:14,002][8]INFO SetStatus Name=E2, Action=MayEnter, Level=Low
[2020-07-19 17:09:14,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:14,385][3]INFO Server connection failed 27 times
[2020-07-19 17:09:15,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:17,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:17,386][3]INFO Server connection failed 28 times
[2020-07-19 17:09:18,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:20,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:20,385][3]INFO Server connection failed 29 times
[2020-07-19 17:09:21,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:23,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:23,386][3]INFO Server connection failed 30 times
[2020-07-19 17:09:24,005][8]INFO SetStatus Name=E2, Action=None, Level=Low
[2020-07-19 17:09:24,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:26,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:26,385][3]INFO Server connection failed 31 times
[2020-07-19 17:09:27,273][7]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:27,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:29,385][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:29,386][3]INFO Server connection failed 32 times
[2020-07-19 17:09:29,744][8]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:29,994][9]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,190][10]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:30,433][11]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,634][12]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,830][13]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:30,993][14]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:31,744][15]INFO SetStatus Name=E22, Action=None, Level=Low
[2020-07-19 17:09:32,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:32,386][3]INFO Server connection failed 33 times
[2020-07-19 17:09:33,386][3]INFO Connect 10.85.199.1:9501
[2020-07-19 17:09:35,258][1]INFO Close
[2020-07-19 17:09:35,386][3]INFO Ping 10.85.199.1 request timeout
[2020-07-19 17:09:35,386][3]INFO Server connection failed 34 times
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!