Commit 91b4f973 顾剑亮

debug

1 个父辈 7f22012e
正在显示 48 个修改的文件 包含 389 行增加111 行删除
...@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00 ...@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16 # Visual Studio Version 16
VisualStudioVersion = 16.0.30413.136 VisualStudioVersion = 16.0.30413.136
MinimumVisualStudioVersion = 10.0.40219.1 MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AGVControl_Steel", "AGVControl_Steel\AGVControl_Steel.csproj", "{BE830571-6737-4FA7-A75B-0242B07E011C}" Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AGVControl_Steel(old)", "AGVControl_Steel\AGVControl_Steel(old).csproj", "{BE830571-6737-4FA7-A75B-0242B07E011C}"
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Test", "Test\Test.csproj", "{752A054D-58EC-460A-A936-F5483B1BC8B2}" Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Test", "Test\Test.csproj", "{752A054D-58EC-460A-A936-F5483B1BC8B2}"
EndProject EndProject
......
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectView>ShowAllFiles</ProjectView>
</PropertyGroup>
</Project>
\ No newline at end of file \ No newline at end of file
...@@ -9,7 +9,6 @@ namespace BLL ...@@ -9,7 +9,6 @@ namespace BLL
private MoveJob move; private MoveJob move;
private string mission; private string mission;
private JobStep<ChargeStep> chargeStep; private JobStep<ChargeStep> chargeStep;
//private int currBattery;
private const int CHARGE_PLC = 20; private const int CHARGE_PLC = 20;
public ChargeJob() public ChargeJob()
...@@ -35,16 +34,21 @@ namespace BLL ...@@ -35,16 +34,21 @@ namespace BLL
{ {
_info.From = ""; _info.From = "";
_info.Place = ""; _info.Place = "";
//currBattery = _info.Battery;
if (_info.IsWorkspace()) if (_info.IsWorkspace())
MoveCharge(); MoveWash();
else else
PassDoor(); PassDoor();
} }
else if (chargeStep.Equals(ChargeStep.PassDoor)) else if (chargeStep.Equals(ChargeStep.PassDoor))
{ {
move.Execute(_info); move.Execute(_info);
if(move.IsEnd) if (move.IsEnd)
MoveWash();
}
else if (chargeStep.Equals(ChargeStep.WaitWashPoint))
{
move.Execute(_info);
if (move.IsEnd)
MoveCharge(); MoveCharge();
} }
else if (chargeStep.Equals(ChargeStep.MoveStation)) else if (chargeStep.Equals(ChargeStep.MoveStation))
...@@ -83,6 +87,20 @@ namespace BLL ...@@ -83,6 +87,20 @@ namespace BLL
return this; return this;
} }
private void MoveWash()
{
mission = Common.MISSION_MOVE_WASH + _info.Workshop;
_info.Place = string.Format("去{0}清洗点", _info.Workshop);
move = new MoveJob(mission);
move.Execute(_info);
chargeStep.NextStep(ChargeStep.WaitWashPoint);
chargeStep.Msg = _info.Name + " 发送回清洗点任务 " + mission;
}
private void MoveCharge() private void MoveCharge()
{ {
mission = Common.MISSION_CHARGE + _info.Workshop; mission = Common.MISSION_CHARGE + _info.Workshop;
...@@ -129,6 +147,8 @@ namespace BLL ...@@ -129,6 +147,8 @@ namespace BLL
End, End,
PassDoor, PassDoor,
MoveStation, MoveStation,
GoWashPoint,
WaitWashPoint,
Charging Charging
} }
} }
......
...@@ -8,9 +8,9 @@ namespace BLL ...@@ -8,9 +8,9 @@ namespace BLL
private AgvInfo _info; private AgvInfo _info;
private MoveJob move; private MoveJob move;
private string mission; private string mission;
//private DateTime _getTime; private string airPlace;
private JobStep<SendNewStep> sendNewStep; private JobStep<SendNewStep> sendNewStep;
public SendNewJob() public SendNewJob()
{ {
sendNewStep = new JobStep<SendNewStep>(SendNewStep.None); sendNewStep = new JobStep<SendNewStep>(SendNewStep.None);
...@@ -51,20 +51,88 @@ namespace BLL ...@@ -51,20 +51,88 @@ namespace BLL
bool rtn = SteelManage.FindNewSteelWork(_info, out string place); bool rtn = SteelManage.FindNewSteelWork(_info, out string place);
if (rtn) if (rtn)
{ {
if (place == "STORAGE") airPlace = place;
if (SteelManage.IsAirLines(place))
{ {
SteelManage.NewSteelWorkDel(_info.From, place); if (_info.In4CAirRoom())
return new StorageJob(); {
MoveLine(place);
}
else
{
sendNewStep.Msg = _info.Name + " 先暂停" + place;
EnterAirAccess();
}
} }
else else
{ {
FindLine(place); if (_info.In4CAirRoom())
{
sendNewStep.Msg = _info.Name + " 先暂停" + place;
LeaveAirAccess();
}
else
{
if (place == "STORAGE")
{
SteelManage.NewSteelWorkDel(_info.From, place);
return new StorageJob();
}
else
{
MoveLine(place);
}
}
} }
} }
else else
{ {
//sendNewStep.Msg = info.Name + " 没有后续新钢板任务";
//sendNewStep.NextStep(SendNewStep.GoWashPoint);
sendNewStep.Msg = info.Name + " 没有后续新钢板任务"; sendNewStep.Msg = info.Name + " 没有后续新钢板任务";
sendNewStep.NextStep(SendNewStep.GoWashPoint); if (_info.In4CAirRoom())
{
airPlace = "$WASH";
sendNewStep.Msg = _info.Name + " 先暂停去清洗点";
LeaveAirAccess();
}
else
{
sendNewStep.NextStep(SendNewStep.GoWashPoint);
}
}
}
else if (sendNewStep.Equals(SendNewStep.EnterAirRoom))
{
move.Execute(_info);
if (move.IsEnd)
{
sendNewStep.Msg = _info.Name + " 已进入4C无尘室";
MoveLine(airPlace);
}
}
else if (sendNewStep.Equals(SendNewStep.LeaveAirRoom))
{
move.Execute(_info);
if (move.IsEnd)
{
sendNewStep.Msg = _info.Name + " 已离开4C无尘室";
if (airPlace == "$WASH")
{
MoveWash();
}
else if (airPlace == "STORAGE")
{
SteelManage.NewSteelWorkDel(_info.From, airPlace);
return new StorageJob();
}
else
{
MoveLine(airPlace);
}
} }
} }
else if (sendNewStep.Equals(SendNewStep.MoveLine)) else if (sendNewStep.Equals(SendNewStep.MoveLine))
...@@ -79,12 +147,7 @@ namespace BLL ...@@ -79,12 +147,7 @@ namespace BLL
} }
else if (sendNewStep.Equals(SendNewStep.GoWashPoint)) else if (sendNewStep.Equals(SendNewStep.GoWashPoint))
{ {
mission = Common.MISSION_MOVE_WASH + _info.Workshop; MoveWash();
_info.Place = string.Format("去{0}清洗点", _info.Workshop);
move = new MoveJob(mission);
move.Execute(_info);
sendNewStep.NextStep(SendNewStep.WaitWashPoint);
sendNewStep.Msg = _info.Name + " 发送回清洗点任务 " + mission;
} }
else if (sendNewStep.Equals(SendNewStep.WaitWashPoint)) else if (sendNewStep.Equals(SendNewStep.WaitWashPoint))
{ {
...@@ -107,16 +170,55 @@ namespace BLL ...@@ -107,16 +170,55 @@ namespace BLL
return this; return this;
} }
private void FindLine(string place) private void MoveLine(string place)
{ {
mission = Common.MISSION_MOVE_STEEL + place; //if (place == "STORAGE")
//{
// SteelManage.NewSteelWorkDel(_info.From, place);
// return new StorageJob();
//}
//else
//{
//}
_info.Place = place; _info.Place = place;
mission = Common.MISSION_MOVE_STEEL + place;
move = new MoveJob(mission); move = new MoveJob(mission);
move.Execute(_info); move.Execute(_info);
sendNewStep.NextStep(SendNewStep.MoveLine); sendNewStep.NextStep(SendNewStep.MoveLine);
sendNewStep.Msg = _info.Name + " 发送新钢板任务 " + mission; sendNewStep.Msg = _info.Name + " 发送新钢板任务 " + mission;
} }
private void MoveWash()
{
mission = Common.MISSION_MOVE_WASH + _info.Workshop;
_info.Place = string.Format("去{0}清洗点", _info.Workshop);
move = new MoveJob(mission);
move.Execute(_info);
sendNewStep.NextStep(SendNewStep.WaitWashPoint);
sendNewStep.Msg = _info.Name + " 发送回清洗点任务 " + mission;
}
private void EnterAirAccess()
{
mission = Common.MISSION_ENTER_AIR;
_info.Place = "进入风淋门";
move = new MoveJob(mission);
move.Execute(_info);
sendNewStep.NextStep(SendNewStep.EnterAirRoom);
sendNewStep.Msg = _info.Name + " 发送进入风淋门任务 " + mission;
}
private void LeaveAirAccess()
{
mission = Common.MISSION_LEAVE_AIR;
_info.Place = "离开风淋门";
move = new MoveJob(mission);
move.Execute(_info);
sendNewStep.NextStep(SendNewStep.LeaveAirRoom);
sendNewStep.Msg = _info.Name + " 发送离开风淋门任务 " + mission;
}
private void PassDoor() private void PassDoor()
{ {
mission = Common.MISSION_PASS_DOOR_INTO + _info.Workshop; mission = Common.MISSION_PASS_DOOR_INTO + _info.Workshop;
...@@ -134,6 +236,8 @@ namespace BLL ...@@ -134,6 +236,8 @@ namespace BLL
PassDoor, PassDoor,
FindLine, FindLine,
MoveLine, MoveLine,
EnterAirRoom,
LeaveAirRoom,
GoWashPoint, GoWashPoint,
WaitWashPoint WaitWashPoint
} }
......
...@@ -96,54 +96,17 @@ namespace BLL ...@@ -96,54 +96,17 @@ namespace BLL
storageStep.Msg = info.Name + " 收到离开信号"; storageStep.Msg = info.Name + " 收到离开信号";
if (_info.IsWorkspace()) if (_info.IsWorkspace())
storageStep.NextStep(StorageStep.End); storageStep.NextStep(StorageStep.FindJob);
else else
PassDoor4C(); PassDoor4C();
//if (SteelManage.FindStorageWork(info))
//{
// if (_info.IsWorkspace())
// {
// storageStep.NextStep(StorageStep.FindLine);
// }
// else
// {
// PassDoor4C();
// }
//}
//else
// return new StandbyJob();
} }
} }
else if (storageStep.Equals(StorageStep.BackDoor)) else if (storageStep.Equals(StorageStep.BackDoor))
{ {
move.Execute(_info); move.Execute(_info);
if (move.IsEnd) if (move.IsEnd)
storageStep.NextStep(StorageStep.End); storageStep.NextStep(StorageStep.FindJob);
} }
//else if (storageStep.Equals(StorageStep.FindLine))
//{
// bool rtn = SteelManage.FindStorageWork(_info, out string place);
// if (rtn)
// {
// FindLine(place);
// }
// else
// {
// storageStep.Msg = info.Name + " 没有后续新钢板任务";
// return new StandbyJob();
// }
//}
//else if (storageStep.Equals(StorageStep.MoveLine))
//{
// move.Execute(_info);
// if (move.IsEnd)
// {
// SteelManage.NewSteelWorkDel(_info.From, _info.Place);
// storageStep.Msg = _info.Name + " 到达 " + _info.Place;
// storageStep.NextStep(StorageStep.FindLine);
// }
//}
else if (storageStep.Equals(StorageStep.Error)) else if (storageStep.Equals(StorageStep.Error))
{ {
if (SteelManage.FindStorageWorkLeave()) if (SteelManage.FindStorageWorkLeave())
...@@ -152,27 +115,50 @@ namespace BLL ...@@ -152,27 +115,50 @@ namespace BLL
storageStep.Msg = info.Name + " 收到离开信号"; storageStep.Msg = info.Name + " 收到离开信号";
if (_info.IsWorkspace()) if (_info.IsWorkspace())
storageStep.NextStep(StorageStep.End); storageStep.NextStep(StorageStep.FindJob);
else else
PassDoor4C(); PassDoor4C();
} }
} }
else if (storageStep.Equals(StorageStep.End)) else if (storageStep.Equals(StorageStep.FindJob))
{ {
//IsEnd = true;
//return new SendNewJob();
_info.Place = "";
IJob job = SteelManage.GetNewSteelJob(info); IJob job = SteelManage.GetNewSteelJob(info);
if (job == null) if (job == null)
{ {
return new StandbyJob(); storageStep.Msg = info.Name + " 没有找到仓库送新钢板任务,回清洗点";
storageStep.NextStep(StorageStep.GoWashPoint);
} }
else else
{ {
_info.Place = "";
IsEnd = true;
return job; return job;
} }
} }
else if(storageStep.Equals(StorageStep.GoWashPoint))
{
mission = Common.MISSION_MOVE_WASH + _info.Workshop;
_info.Place = string.Format("去{0}清洗点", _info.Workshop);
move = new MoveJob(mission);
move.Execute(_info);
storageStep.NextStep(StorageStep.WaitWashPoint);
storageStep.Msg = _info.Name + " 发送回清洗点任务 " + mission;
}
else if (storageStep.Equals(StorageStep.WaitWashPoint))
{
move.Execute(_info);
if (move.IsEnd)
{
_info.Place = "";
storageStep.NextStep(StorageStep.End);
storageStep.Msg = _info.Name + " 到达" + _info.Workshop + "清洗点";
}
}
else if (storageStep.Equals(StorageStep.End))
{
return new StandbyJob();
}
return this; return this;
} }
...@@ -230,6 +216,9 @@ namespace BLL ...@@ -230,6 +216,9 @@ namespace BLL
WaitStorageLeave, WaitStorageLeave,
FindLine, FindLine,
MoveLine, MoveLine,
FindJob,
GoWashPoint,
WaitWashPoint,
Error Error
} }
} }
......
...@@ -8,7 +8,7 @@ namespace BLL ...@@ -8,7 +8,7 @@ namespace BLL
private AgvInfo _info; private AgvInfo _info;
private MoveJob move; private MoveJob move;
private string mission; private string mission;
//private DateTime _getTime; private string airPlace;
private JobStep<TakeOldStep> takeOldStep; private JobStep<TakeOldStep> takeOldStep;
public TakeOldJob() public TakeOldJob()
...@@ -35,20 +35,49 @@ namespace BLL ...@@ -35,20 +35,49 @@ namespace BLL
{ {
_info.From = ""; _info.From = "";
_info.Place = ""; _info.Place = "";
info.OldSteel = 0; _info.OldSteel = 0;
takeOldStep.Msg = info.Name + " 查找回收钢板任务"; takeOldStep.Msg = _info.Name + " 查找回收钢板任务";
takeOldStep.NextStep(TakeOldStep.FindLine); takeOldStep.NextStep(TakeOldStep.FindLine);
} }
else if (takeOldStep.Equals(TakeOldStep.FindLine)) else if (takeOldStep.Equals(TakeOldStep.FindLine))
{ {
if (info.OldSteel == 5) if (_info.OldSteel == 5)
{ {
takeOldStep.Msg = info.Name + " 回收钢板已满"; takeOldStep.Msg = _info.Name + " 回收钢板已满";
takeOldStep.NextStep(TakeOldStep.GoWashPoint); if (_info.In4CAirRoom())
{
airPlace = "$WASH";
LeaveAirAccess();
}
else
{
takeOldStep.NextStep(TakeOldStep.GoWashPoint);
}
} }
else else
{ {
FindLine(info); FindLine();
}
}
else if (takeOldStep.Equals(TakeOldStep.EnterAirRoom))
{
move.Execute(_info);
if (move.IsEnd)
{
takeOldStep.Msg = _info.Name + " 已进入4C无尘室";
MoveLine(airPlace);
}
}
else if (takeOldStep.Equals(TakeOldStep.LeaveAirRoom))
{
move.Execute(_info);
if (move.IsEnd)
{
takeOldStep.Msg = _info.Name + " 已离开4C无尘室";
if (airPlace == "$WASH")
MoveWash();
else
MoveLine(airPlace);
} }
} }
else if (takeOldStep.Equals(TakeOldStep.MoveLine)) else if (takeOldStep.Equals(TakeOldStep.MoveLine))
...@@ -56,27 +85,30 @@ namespace BLL ...@@ -56,27 +85,30 @@ namespace BLL
move.Execute(_info); move.Execute(_info);
if (move.IsEnd) if (move.IsEnd)
{ {
info.OldSteel++; _info.OldSteel++;
SteelManage.OldSteelWorkDel(info.Place); SteelManage.OldSteelWorkDel(_info.Place);
takeOldStep.NextStep(TakeOldStep.FindLine); takeOldStep.NextStep(TakeOldStep.FindLine);
takeOldStep.Msg = _info.Name + " 到达" + _info.Place; takeOldStep.Msg = _info.Name + " 到达" + _info.Place;
} }
} }
else if (takeOldStep.Equals(TakeOldStep.GoWashPoint)) else if (takeOldStep.Equals(TakeOldStep.GoWashPoint))
{ {
if (info.OldSteel == 0) if (_info.OldSteel == 0)
{ {
takeOldStep.NextStep(TakeOldStep.End); takeOldStep.NextStep(TakeOldStep.End);
takeOldStep.Msg = _info.Name + " 回收钢板数量为0,结束任务"; takeOldStep.Msg = _info.Name + " 回收钢板数量为0,结束任务";
} }
else else
{ {
mission = Common.MISSION_MOVE_WASH + _info.Workshop; //if (_info.In4CAirRoom())
_info.Place = string.Format("去{0}清洗点", _info.Workshop); //{
move = new MoveJob(mission); // takeOldStep.Msg = _info.Name + " 先暂停" + place;
move.Execute(_info); // LeaveAirAccess();
takeOldStep.NextStep(TakeOldStep.WaitWashPoint); //}
takeOldStep.Msg = _info.Name + " 发送回清洗点任务 " + mission; //else
// MoveLine(place);
MoveWash();
} }
} }
else if (takeOldStep.Equals(TakeOldStep.WaitWashPoint)) else if (takeOldStep.Equals(TakeOldStep.WaitWashPoint))
...@@ -90,8 +122,8 @@ namespace BLL ...@@ -90,8 +122,8 @@ namespace BLL
} }
else if (takeOldStep.Equals(TakeOldStep.End)) else if (takeOldStep.Equals(TakeOldStep.End))
{ {
info.OldSteel = 0; _info.OldSteel = 0;
IJob job = SteelManage.GetSteelJob(info); IJob job = SteelManage.GetSteelJob(_info);
if (job == null) if (job == null)
return new StandbyJob(); return new StandbyJob();
else else
...@@ -101,26 +133,88 @@ namespace BLL ...@@ -101,26 +133,88 @@ namespace BLL
return this; return this;
} }
private void FindLine(AgvInfo info) private void FindLine()
{ {
bool rtn = SteelManage.FindOldSteelWork(info, out string place); bool rtn = SteelManage.FindOldSteelWork(_info, out string place);
if (rtn) if (rtn)
{ {
info.Place = place; airPlace = place;
mission = Common.MISSION_MOVE_STEEL + place; if (SteelManage.IsAirLines(place))
move = new MoveJob(mission); {
move.Execute(_info); if (_info.In4CAirRoom())
takeOldStep.NextStep(TakeOldStep.MoveLine); MoveLine(place);
takeOldStep.Msg = _info.Name + " 发送回收钢板任务 " + mission; else
{
takeOldStep.Msg = _info.Name + " 先暂停" + place;
EnterAirAccess();
}
}
else
{
if (_info.In4CAirRoom())
{
takeOldStep.Msg = _info.Name + " 先暂停" + place;
LeaveAirAccess();
}
else
MoveLine(place);
}
} }
else else
{ {
takeOldStep.NextStep(TakeOldStep.GoWashPoint); takeOldStep.Msg = _info.Name + " 没有后续旧钢板任务";
takeOldStep.Msg = info.Name + " 没有后续旧钢板任务"; if (_info.In4CAirRoom())
{
airPlace = "$WASH";
takeOldStep.Msg = _info.Name + " 先暂停去清洗点";
LeaveAirAccess();
}
else
{
takeOldStep.NextStep(TakeOldStep.GoWashPoint);
}
} }
} }
private void MoveLine(string place)
{
_info.Place = place;
mission = Common.MISSION_MOVE_STEEL + place;
move = new MoveJob(mission);
move.Execute(_info);
takeOldStep.NextStep(TakeOldStep.MoveLine);
takeOldStep.Msg = _info.Name + " 发送回收钢板任务 " + mission;
}
private void MoveWash()
{
mission = Common.MISSION_MOVE_WASH + _info.Workshop;
_info.Place = string.Format("去{0}清洗点", _info.Workshop);
move = new MoveJob(mission);
move.Execute(_info);
takeOldStep.NextStep(TakeOldStep.WaitWashPoint);
takeOldStep.Msg = _info.Name + " 发送回清洗点任务 " + mission;
}
private void EnterAirAccess()
{
mission = Common.MISSION_ENTER_AIR;
_info.Place = "进入风淋门";
move = new MoveJob(mission);
move.Execute(_info);
takeOldStep.NextStep(TakeOldStep.EnterAirRoom);
takeOldStep.Msg = _info.Name + " 发送进入风淋门任务 " + mission;
}
private void LeaveAirAccess()
{
mission = Common.MISSION_LEAVE_AIR;
_info.Place = "离开风淋门";
move = new MoveJob(mission);
move.Execute(_info);
takeOldStep.NextStep(TakeOldStep.LeaveAirRoom);
takeOldStep.Msg = _info.Name + " 发送离开风淋门任务 " + mission;
}
private enum TakeOldStep private enum TakeOldStep
...@@ -128,6 +222,8 @@ namespace BLL ...@@ -128,6 +222,8 @@ namespace BLL
None, None,
FindLine, FindLine,
MoveLine, MoveLine,
EnterAirRoom,
LeaveAirRoom,
GoWashPoint, GoWashPoint,
WaitWashPoint, WaitWashPoint,
End End
......
...@@ -101,7 +101,7 @@ namespace BLL ...@@ -101,7 +101,7 @@ namespace BLL
foreach (Process process in processes) foreach (Process process in processes)
{ {
if (process.Id == current.Id) continue; //自己 if (process.Id == current.Id) continue; //自己
if (process.MainModule.ModuleName == current.MainModule.ModuleName) if (process.MainModule.FileName == current.MainModule.FileName)
{ {
//显示已打开的程序 //显示已打开的程序
ShowWindow(process.MainWindowHandle, SW_RESTORE); ShowWindow(process.MainWindowHandle, SW_RESTORE);
......
...@@ -258,7 +258,7 @@ namespace BLL ...@@ -258,7 +258,7 @@ namespace BLL
bool find = false; bool find = false;
for (int i = 0; i < Common.agvLines[lineIdx].Lines.Length; i++) for (int i = 0; i < Common.agvLines[lineIdx].Lines.Length; i++)
{ {
int index = newSteelWork.FindIndex(s => s.From == info.From && s.Place == Common.agvLines[lineIdx].Lines[i]); int index = newSteelWork.FindIndex(s => s.From == info.From && s.Place != s.From && s.Place == Common.agvLines[lineIdx].Lines[i]);
if (index > -1) if (index > -1)
{ {
place = newSteelWork[index].Place; place = newSteelWork[index].Place;
...@@ -531,7 +531,13 @@ namespace BLL ...@@ -531,7 +531,13 @@ namespace BLL
} }
public static bool IsAirLines(string place)
{
if (place == "C8" || place == "C9" || place == "C10")
return true;
else
return false;
}
......
3b6cfc6b8015e6bae558763a064e06e7f6d7d448 a02b9d68e5a56016956d69a6eba993b3109164bb
...@@ -26,3 +26,17 @@ D:\Neotel\AGVControl_Steel\BLL\obj\Debug\BLL.csproj.CoreCompileInputs.cache ...@@ -26,3 +26,17 @@ D:\Neotel\AGVControl_Steel\BLL\obj\Debug\BLL.csproj.CoreCompileInputs.cache
D:\Neotel\AGVControl_Steel\BLL\obj\Debug\BLL.csproj.CopyComplete D:\Neotel\AGVControl_Steel\BLL\obj\Debug\BLL.csproj.CopyComplete
D:\Neotel\AGVControl_Steel\BLL\obj\Debug\BLL.dll D:\Neotel\AGVControl_Steel\BLL\obj\Debug\BLL.dll
D:\Neotel\AGVControl_Steel\BLL\obj\Debug\BLL.pdb D:\Neotel\AGVControl_Steel\BLL\obj\Debug\BLL.pdb
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\log4net.config
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\BLL.dll
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\BLL.pdb
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\Model.dll
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\log4net.dll
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\RestSharp.dll
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\Model.pdb
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\log4net.xml
C:\Neotel\Program\AGVControl_Steel\BLL\bin\Debug\RestSharp.xml
C:\Neotel\Program\AGVControl_Steel\BLL\obj\Debug\BLL.csprojAssemblyReference.cache
C:\Neotel\Program\AGVControl_Steel\BLL\obj\Debug\BLL.csproj.CoreCompileInputs.cache
C:\Neotel\Program\AGVControl_Steel\BLL\obj\Debug\BLL.csproj.CopyComplete
C:\Neotel\Program\AGVControl_Steel\BLL\obj\Debug\BLL.dll
C:\Neotel\Program\AGVControl_Steel\BLL\obj\Debug\BLL.pdb
...@@ -142,5 +142,17 @@ namespace Model ...@@ -142,5 +142,17 @@ namespace Model
else else
return false; return false;
} }
/// <summary>
/// 4C无尘室
/// </summary>
/// <returns></returns>
public bool In4CAirRoom()
{
if (Position.X < 51.5f && Position.Y > 65.7f)
return true;
else
return false;
}
} }
} }
...@@ -46,7 +46,9 @@ namespace Model ...@@ -46,7 +46,9 @@ namespace Model
public const string MISSION_MOVE_WASH = "MoveWash"; public const string MISSION_MOVE_WASH = "MoveWash";
public const string MISSION_MOVE_STORAGE = "MoveSteelstorage"; public const string MISSION_MOVE_STORAGE = "MoveSteelstorage";
public const string MISSION_MOVE_STEEL = "MoveSteel"; public const string MISSION_MOVE_STEEL = "MoveSteel";
public const string MISSION_ENTER_AIR = "4CflowIOin";
public const string MISSION_LEAVE_AIR = "4CflowIOout";
public static readonly string PATH_AGV_NAME = Environment.CurrentDirectory + "\\Config\\AgvName.csv"; public static readonly string PATH_AGV_NAME = Environment.CurrentDirectory + "\\Config\\AgvName.csv";
public static readonly string PATH_AGV_MISSION = Environment.CurrentDirectory + "\\Config\\AgvMission.csv"; public static readonly string PATH_AGV_MISSION = Environment.CurrentDirectory + "\\Config\\AgvMission.csv";
public static readonly string PATH_AGV_LINE = Environment.CurrentDirectory + "\\Config\\AgvLine.txt"; public static readonly string PATH_AGV_LINE = Environment.CurrentDirectory + "\\Config\\AgvLine.txt";
......
55762488e9ab378cb6871978329ebc986d9d5dd2 39cd401be94be237b207dee168b5365597548902
...@@ -22,3 +22,15 @@ D:\Neotel\AGVControl_Steel\Model\obj\Debug\Model.csproj.CopyComplete ...@@ -22,3 +22,15 @@ D:\Neotel\AGVControl_Steel\Model\obj\Debug\Model.csproj.CopyComplete
D:\Neotel\AGVControl_Steel\Model\obj\Debug\Model.dll D:\Neotel\AGVControl_Steel\Model\obj\Debug\Model.dll
D:\Neotel\AGVControl_Steel\Model\obj\Debug\Model.pdb D:\Neotel\AGVControl_Steel\Model\obj\Debug\Model.pdb
D:\Neotel\AGVControl_Steel\Model\obj\Debug\Model.csprojAssemblyReference.cache D:\Neotel\AGVControl_Steel\Model\obj\Debug\Model.csprojAssemblyReference.cache
C:\Neotel\Program\AGVControl_Steel\Model\bin\Debug\log4net.config
C:\Neotel\Program\AGVControl_Steel\Model\bin\Debug\Model.dll
C:\Neotel\Program\AGVControl_Steel\Model\bin\Debug\Model.pdb
C:\Neotel\Program\AGVControl_Steel\Model\bin\Debug\log4net.dll
C:\Neotel\Program\AGVControl_Steel\Model\bin\Debug\RestSharp.dll
C:\Neotel\Program\AGVControl_Steel\Model\bin\Debug\log4net.xml
C:\Neotel\Program\AGVControl_Steel\Model\bin\Debug\RestSharp.xml
C:\Neotel\Program\AGVControl_Steel\Model\obj\Debug\Model.csproj.CoreCompileInputs.cache
C:\Neotel\Program\AGVControl_Steel\Model\obj\Debug\Model.csproj.CopyComplete
C:\Neotel\Program\AGVControl_Steel\Model\obj\Debug\Model.dll
C:\Neotel\Program\AGVControl_Steel\Model\obj\Debug\Model.pdb
C:\Neotel\Program\AGVControl_Steel\Model\obj\Debug\Model.csprojAssemblyReference.cache
...@@ -775,7 +775,7 @@ ...@@ -775,7 +775,7 @@
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Name = "FrmMain"; this.Name = "FrmMain";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "钢网AGV调度"; this.Text = "钢网AGV(4楼)";
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FrmMain_FormClosing); this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FrmMain_FormClosing);
this.Load += new System.EventHandler(this.FrmMain_Load); this.Load += new System.EventHandler(this.FrmMain_Load);
((System.ComponentModel.ISupportInitialize)(this.DgvName)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.DgvName)).EndInit();
......
...@@ -102,11 +102,11 @@ namespace AGVControl_Steel ...@@ -102,11 +102,11 @@ namespace AGVControl_Steel
if (e.ColumnIndex == DgvName.Columns.Count - 2) //最后二列,自动/手动 if (e.ColumnIndex == DgvName.Columns.Count - 2) //最后二列,自动/手动
{ {
info.IsAuto = !info.IsAuto; info.IsAuto = !info.IsAuto;
Common.log.Info("手动修改 " + info.Name + " 自动状态" + info.IsAuto);
DgvName.Rows[e.RowIndex].Cells[e.ColumnIndex].Value = info.IsAuto.ToString(); DgvName.Rows[e.RowIndex].Cells[e.ColumnIndex].Value = info.IsAuto.ToString();
Common.appConfig.AppSettings.Settings[info.Name].Value = info.IsAuto.ToString(); Common.appConfig.AppSettings.Settings[info.Name].Value = info.IsAuto.ToString();
Common.appConfig.Save(); Common.appConfig.Save();
System.Configuration.ConfigurationManager.RefreshSection("appSettings"); System.Configuration.ConfigurationManager.RefreshSection("appSettings");
Common.log.Info("手动修改 " + info.Name + " IsUse=" + info.IsAuto);
if (info.IsAuto && Common.WorkAutoDel) if (info.IsAuto && Common.WorkAutoDel)
{ {
...@@ -121,6 +121,7 @@ namespace AGVControl_Steel ...@@ -121,6 +121,7 @@ namespace AGVControl_Steel
DialogResult dr = MessageBox.Show(text, "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Information); DialogResult dr = MessageBox.Show(text, "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
if (dr == DialogResult.Yes) if (dr == DialogResult.Yes)
{ {
Common.log.Info("手动清除 " + info.Name + " 任务");
info.CurrentJob = null; info.CurrentJob = null;
Common.mir.Del_Mission(info.IP, info.Authorization); Common.mir.Del_Mission(info.IP, info.Authorization);
info.IsAuto = false; info.IsAuto = false;
......
...@@ -19,9 +19,14 @@ namespace AGVControl_Steel ...@@ -19,9 +19,14 @@ namespace AGVControl_Steel
Application.EnableVisualStyles(); Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false); Application.SetCompatibleTextRenderingDefault(false);
if (BLL.RunMode.IsRun()) return;
Common.log = new Log("AGVControl_Steel"); Common.log = new Log("AGVControl_Steel");
Common.log.Info("=====程序开始====="); Common.log.Info("=====程序开始=====");
if (BLL.RunMode.IsRun())
{
Common.log.Info("=====打开相同的程序,程序结束=====\r\n");
return;
}
ReadConfig(); ReadConfig();
Application.Run(new FrmMain()); Application.Run(new FrmMain());
Common.log.Info("=====程序结束=====\r\n"); Common.log.Info("=====程序结束=====\r\n");
......
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
<DefineConstants>DEBUG;TRACE</DefineConstants> <DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>AnyCPU</PlatformTarget>
......
此文件类型无法预览
此文件类型无法预览
...@@ -32,4 +32,6 @@ PassDoorInto4D,d67f31c8-ca7e-11ea-9a66-94c691a7387d ...@@ -32,4 +32,6 @@ PassDoorInto4D,d67f31c8-ca7e-11ea-9a66-94c691a7387d
PassDoorInto4C,fd6e26ac-c1bf-11ea-9a66-94c691a7387d PassDoorInto4C,fd6e26ac-c1bf-11ea-9a66-94c691a7387d
MoveSteelstorage,418c9064-f2ac-11ea-8452-94c691a7387d MoveSteelstorage,418c9064-f2ac-11ea-8452-94c691a7387d
Pickupqisdashelf,f2acdcae-e524-11ea-b003-0001299a3f0e Pickupqisdashelf,f2acdcae-e524-11ea-b003-0001299a3f0e
Placeqisdashelf,4001120d-e525-11ea-b003-0001299a3f0e
\ No newline at end of file \ No newline at end of file
Placeqisdashelf,4001120d-e525-11ea-b003-0001299a3f0e
4CflowIOin,2f0086e6-362c-11eb-b091-94c691a7387d
4CflowIOout,46b3f3bf-3636-11eb-b048-0001299981d4
\ No newline at end of file \ No newline at end of file
2858df09001d9a0041d7edb18b50efb3e8fd2b88 27b344593bbf71d4e0ea6b3f49e7afaf11a1f7b6
...@@ -38,3 +38,23 @@ D:\Neotel\AGVControl_Steel\UI\obj\Debug\UI.csproj.CoreCompileInputs.cache ...@@ -38,3 +38,23 @@ D:\Neotel\AGVControl_Steel\UI\obj\Debug\UI.csproj.CoreCompileInputs.cache
D:\Neotel\AGVControl_Steel\UI\obj\Debug\UI.csproj.CopyComplete D:\Neotel\AGVControl_Steel\UI\obj\Debug\UI.csproj.CopyComplete
D:\Neotel\AGVControl_Steel\UI\obj\Debug\AGVControl_Steel.exe D:\Neotel\AGVControl_Steel\UI\obj\Debug\AGVControl_Steel.exe
D:\Neotel\AGVControl_Steel\UI\obj\Debug\AGVControl_Steel.pdb D:\Neotel\AGVControl_Steel\UI\obj\Debug\AGVControl_Steel.pdb
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\log4net.config
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\AGVControl_Steel.exe.config
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\AGVControl_Steel.exe
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\AGVControl_Steel.pdb
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\BLL.dll
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\Model.dll
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\log4net.dll
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\RestSharp.dll
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\BLL.pdb
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\Model.pdb
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\log4net.xml
C:\Neotel\Program\AGVControl_Steel\UI\bin\Debug\RestSharp.xml
C:\Neotel\Program\AGVControl_Steel\UI\obj\Debug\UI.csprojAssemblyReference.cache
C:\Neotel\Program\AGVControl_Steel\UI\obj\Debug\AGVControl_Steel.FrmMain.resources
C:\Neotel\Program\AGVControl_Steel\UI\obj\Debug\AGVControl_Steel.Properties.Resources.resources
C:\Neotel\Program\AGVControl_Steel\UI\obj\Debug\UI.csproj.GenerateResource.cache
C:\Neotel\Program\AGVControl_Steel\UI\obj\Debug\UI.csproj.CoreCompileInputs.cache
C:\Neotel\Program\AGVControl_Steel\UI\obj\Debug\UI.csproj.CopyComplete
C:\Neotel\Program\AGVControl_Steel\UI\obj\Debug\AGVControl_Steel.exe
C:\Neotel\Program\AGVControl_Steel\UI\obj\Debug\AGVControl_Steel.pdb
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!