Commit 1f1b7d9d 顾剑亮

upload

1 个父辈 208ae8ed
正在显示 51 个修改的文件 包含 576 行增加79 行删除
...@@ -24,7 +24,8 @@ ...@@ -24,7 +24,8 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit> <Prefer32Bit>false</Prefer32Bit>
<DocumentationFile>bin\Debug\AGVControl_Steel.xml</DocumentationFile> <DocumentationFile>
</DocumentationFile>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget> <PlatformTarget>AnyCPU</PlatformTarget>
...@@ -36,7 +37,7 @@ ...@@ -36,7 +37,7 @@
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
</PropertyGroup> </PropertyGroup>
<PropertyGroup> <PropertyGroup>
<ApplicationIcon>Icon.ico</ApplicationIcon> <ApplicationIcon>图标.ico</ApplicationIcon>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="ClassFormParent"> <Reference Include="ClassFormParent">
...@@ -45,6 +46,7 @@ ...@@ -45,6 +46,7 @@
<Reference Include="log4net"> <Reference Include="log4net">
<HintPath>..\..\..\..\DLL\log4net.dll</HintPath> <HintPath>..\..\..\..\DLL\log4net.dll</HintPath>
</Reference> </Reference>
<Reference Include="Microsoft.VisualBasic" />
<Reference Include="RestSharp, Version=106.11.4.0, Culture=neutral, PublicKeyToken=598062e77f915f75, processorArchitecture=MSIL"> <Reference Include="RestSharp, Version=106.11.4.0, Culture=neutral, PublicKeyToken=598062e77f915f75, processorArchitecture=MSIL">
<HintPath>..\packages\RestSharp.106.11.4\lib\net452\RestSharp.dll</HintPath> <HintPath>..\packages\RestSharp.106.11.4\lib\net452\RestSharp.dll</HintPath>
</Reference> </Reference>
...@@ -69,6 +71,7 @@ ...@@ -69,6 +71,7 @@
<ItemGroup> <ItemGroup>
<Compile Include="BLL\Control.cs" /> <Compile Include="BLL\Control.cs" />
<Compile Include="BLL\Common.cs" /> <Compile Include="BLL\Common.cs" />
<Compile Include="Job\MissionMoveJob.cs" />
<Compile Include="Model\MissionState.cs" /> <Compile Include="Model\MissionState.cs" />
<Compile Include="Model\MiR_API.cs" /> <Compile Include="Model\MiR_API.cs" />
<Compile Include="Job\TakeOldJob.cs" /> <Compile Include="Job\TakeOldJob.cs" />
...@@ -128,7 +131,7 @@ ...@@ -128,7 +131,7 @@
<Content Include="bin\Debug\log4net.dll" /> <Content Include="bin\Debug\log4net.dll" />
<Content Include="bin\Debug\RestSharp.dll" /> <Content Include="bin\Debug\RestSharp.dll" />
<Content Include="bin\Debug\RestSharp.xml" /> <Content Include="bin\Debug\RestSharp.xml" />
<Content Include="Icon.ico" /> <Content Include="图标.ico" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Folder Include="bin\Debug\Logs\" /> <Folder Include="bin\Debug\Logs\" />
......
...@@ -37,15 +37,13 @@ ...@@ -37,15 +37,13 @@
</logger> </logger>
</log4net> </log4net>
<appSettings> <appSettings>
<add key="FLEET_IP" value="10.85.199.3" /> <add key="FLEET_IP" value="10.85.199.3"/>
<add key="FLEET_Send" value="true"/>
<add key="WebService" value="http://10.85.196.40:8089/"/> <add key="WebService" value="http://10.85.196.40:8089/"/>
<add key="AGV_BATTERY_MAX" value="100"/> <add key="AGV_BATTERY_MAX" value="100"/>
<add key="AGV_BATTERY_MIN" value="60"/> <add key="AGV_BATTERY_MIN" value="40"/>
<!--<add key="4D_Line" value="D1,D2,D3,D4,D5,D6,D8,D9,D10,D11,D12,D14,D15,D16"/>
<add key="4C_Line" value="C1,C2,C3,C4,C5,C6,C7,C8,C9,C10"/>
<add key="Store" value="4cwash,4dwash,storage"/>-->
<add key="PlaceName" value="D1,D2,D3,D4,D5,D6,D8,D9,D10,D11,D12,D14,D15,D16,C1,C2,C3,C4,C5,C6,C7,C8,C9,C10,4cwash,4dwash,storage"/>
<add key="4D_AGV" value="3"/>
<add key="4C_AGV" value="32"/> <add key="4C_AGV" value="32"/>
<add key="4D_AGV" value="25"/>
<add key="PlaceName" value="D1,D2,D3,D4,D5,D6,D7,D8,D9,D10,D11,D12,D13,D14,D15,D16,C1,C2,C3,C4,C5,C6,C7,C8,C9,C10,C11,C12,C13,C14,C15,C16,4cwash,4dwash,storage"/>
</appSettings> </appSettings>
</configuration> </configuration>
\ No newline at end of file \ No newline at end of file
...@@ -11,8 +11,10 @@ namespace AGVControl_Steel ...@@ -11,8 +11,10 @@ namespace AGVControl_Steel
public static class Common public static class Common
{ {
public static System.Windows.Forms.TextBox txtLog; public static System.Windows.Forms.TextBox txtLog;
public static System.Windows.Forms.TextBox txtOldSteel; public static System.Windows.Forms.ListBox lstOldSteel;
public static System.Windows.Forms.TextBox txtNewSteel; public static System.Windows.Forms.ListBox lstNewSteel;
public static System.Windows.Forms.ListBox lstStorage;
public static System.Windows.Forms.Label lblStorageIO;
public static List<AgvInfo> agvInfos; public static List<AgvInfo> agvInfos;
public static Dictionary<string, string> agvMissions; public static Dictionary<string, string> agvMissions;
...@@ -21,15 +23,24 @@ namespace AGVControl_Steel ...@@ -21,15 +23,24 @@ namespace AGVControl_Steel
public static BLL.SteelManage steelManage; public static BLL.SteelManage steelManage;
public static System.Configuration.Configuration appConfig; public static System.Configuration.Configuration appConfig;
public static log4net.ILog log; public static log4net.ILog log;
public static string[] PLACE_NAME; public static string[] PLACE_NAME;
//public static string[] LINE_NAME_4D; /// <summary>
//public static string[] LINE_NAME_4C; /// 仓库对接完成
//public static string[] STORE_NAME; /// </summary>
public const string WORKSHOP_4D = "4D"; public static bool StorageDockFinish;
public const string WORKSHOP_4C = "4C";
//public const string WASH_4D = "4Dwash";
//public const string WASH_4C = "4Cwash"; public const int AGV_CALL_SLEEP = 2000;
public const string STORAGE_ENTER_4C = "4c_enter";
public const string STORAGE_ENTER_4D = "4d_enter";
public const string STORAGE_LEAVE = "leave";
public const string STORAGE_IO_ON = "di_on";
public const string STORAGE_IO_OFF = "di_off";
public const string WORKSHOP_4D = "4d";
public const string WORKSHOP_4C = "4c";
public const string MISSION_TAKE_OFF_SHELF = "Placeqisdashelf"; public const string MISSION_TAKE_OFF_SHELF = "Placeqisdashelf";
public const string MISSION_TAKE_ON_SHELF = "Pickupqisdashelf"; public const string MISSION_TAKE_ON_SHELF = "Pickupqisdashelf";
public const string MISSION_MOVE_4C_4D = "MoveDoor-4C-4D"; public const string MISSION_MOVE_4C_4D = "MoveDoor-4C-4D";
...@@ -40,7 +51,7 @@ namespace AGVControl_Steel ...@@ -40,7 +51,7 @@ namespace AGVControl_Steel
public const string MISSION_STANDBY_4C = "Move4CStandby"; public const string MISSION_STANDBY_4C = "Move4CStandby";
public const string MISSION_MOVE_WASH_4D = "Move4DWash"; public const string MISSION_MOVE_WASH_4D = "Move4DWash";
public const string MISSION_MOVE_WASH_4C = "Move4CWash"; public const string MISSION_MOVE_WASH_4C = "Move4CWash";
public const string MISSION_MOVE_STORAGE = "MoveStorage"; public const string MISSION_MOVE_STORAGE = "MoveSteelstorage";
public const string MISSION_MOVE_D1 = "MoveSteelD1"; public const string MISSION_MOVE_D1 = "MoveSteelD1";
public const string MISSION_MOVE_D2 = "MoveSteelD2"; public const string MISSION_MOVE_D2 = "MoveSteelD2";
public const string MISSION_MOVE_D3 = "MoveSteelD3"; public const string MISSION_MOVE_D3 = "MoveSteelD3";
...@@ -70,6 +81,7 @@ namespace AGVControl_Steel ...@@ -70,6 +81,7 @@ namespace AGVControl_Steel
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_NEW_STEEL_WORK = Environment.CurrentDirectory + "\\Config\\NewSteelWork.txt"; public static readonly string PATH_NEW_STEEL_WORK = Environment.CurrentDirectory + "\\Config\\NewSteelWork.txt";
public static readonly string PATH_OLD_STEEL_WORK = Environment.CurrentDirectory + "\\Config\\OldSteelWork.txt"; public static readonly string PATH_OLD_STEEL_WORK = Environment.CurrentDirectory + "\\Config\\OldSteelWork.txt";
public static readonly string PATH_STORAGE_WORK = Environment.CurrentDirectory + "\\Config\\StorageWork.txt";
} }
......
...@@ -32,7 +32,7 @@ namespace BLL ...@@ -32,7 +32,7 @@ namespace BLL
/// </summary> /// </summary>
public void Start() public void Start()
{ {
timerCall = new Timer(CallProcess, null, 0, 2000); timerCall = new Timer(CallProcess, null, 0, Common.AGV_CALL_SLEEP);
} }
/// <summary> /// <summary>
......
...@@ -10,6 +10,7 @@ namespace Model ...@@ -10,6 +10,7 @@ namespace Model
{ {
private string id; private string id;
private JobStep<ChargeStep> chargeStep; private JobStep<ChargeStep> chargeStep;
private const int CHARGE_PLACE_PLC = 20;
/// <summary> /// <summary>
/// 充电工作 /// 充电工作
...@@ -17,6 +18,7 @@ namespace Model ...@@ -17,6 +18,7 @@ namespace Model
public ChargeJob() public ChargeJob()
{ {
chargeStep = new JobStep<ChargeStep>(ChargeStep.None); chargeStep = new JobStep<ChargeStep>(ChargeStep.None);
Common.log.Debug("进入ChargeJob任务");
} }
/// <summary> /// <summary>
...@@ -49,7 +51,7 @@ namespace Model ...@@ -49,7 +51,7 @@ namespace Model
} }
else if (chargeStep.IsEqual(ChargeStep.WaitChargeStation)) else if (chargeStep.IsEqual(ChargeStep.WaitChargeStation))
{ {
rtn = Common.mir.Get_Register(info.IP, info.Authorization, 20, out int value); rtn = Common.mir.Get_Register(info.IP, info.Authorization, CHARGE_PLACE_PLC, out int value);
if (rtn) if (rtn)
{ {
if (value == 1) if (value == 1)
...@@ -60,7 +62,7 @@ namespace Model ...@@ -60,7 +62,7 @@ namespace Model
} }
else else
{ {
chargeStep.Msg = info.FullName + "获取PLC20失败"; chargeStep.Msg = info.FullName + "获取PLC" + CHARGE_PLACE_PLC + "失败";
} }
} }
else if (chargeStep.IsEqual(ChargeStep.Charging)) else if (chargeStep.IsEqual(ChargeStep.Charging))
...@@ -99,7 +101,7 @@ namespace Model ...@@ -99,7 +101,7 @@ namespace Model
rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id); rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id);
if (rtn) if (rtn)
{ {
chargeStep.Msg = info.FullName + "在" + info.Workshop + "车间,先过车间门"; chargeStep.Msg = info.FullName + "在" + info.Workshop.ToUpper() + "车间,先过车间门";
chargeStep.NextStep(ChargeStep.WaitWorkshopDoor); chargeStep.NextStep(ChargeStep.WaitWorkshopDoor);
} }
else else
...@@ -118,6 +120,7 @@ namespace Model ...@@ -118,6 +120,7 @@ namespace Model
rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id); rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id);
if (rtn) if (rtn)
{ {
info.Place = "充电位";
chargeStep.Msg = info.FullName + "在" + info.Workshop + "车间,去充电位"; chargeStep.Msg = info.FullName + "在" + info.Workshop + "车间,去充电位";
chargeStep.NextStep(ChargeStep.WaitChargeStation); chargeStep.NextStep(ChargeStep.WaitChargeStation);
} }
......
using AGVControl_Steel;
namespace Model
{
public class MissionMoveJob : Job
{
private string id;
private int getStateTime = 0;
private JobStep<MissionMoveStep> missionMoveStep;
public MissionMoveJob(string missionName)
{
IsEnd = false;
mission = missionName;
missionMoveStep = new JobStep<MissionMoveStep>(MissionMoveStep.None);
Common.log.Debug("进入MissionMoveJob任务");
}
public override Job Execute(AgvInfo info)
{
if (missionMoveStep.IsEqual(MissionMoveStep.None))
{
rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id);
if (rtn)
{
getStateTime = 0;
missionMoveStep.NextStep(MissionMoveStep.Moving);
}
else
{
missionMoveStep.Msg = info.FullName + "发送 " + mission + " 失败";
Common.mir.Del_Mission(info.IP, info.Authorization);
}
}
else if (missionMoveStep.IsEqual(MissionMoveStep.Moving))
{
getStateTime += Common.AGV_CALL_SLEEP;
if (getStateTime >= 2000) //每2s获取一次状态
{
getStateTime = 0;
rtn = Common.mir.Get_MissionState_Fleet(info.Authorization, id, out string state);
if (rtn)
{
if (state == MissionState.Done.ToString())
{
missionMoveStep.NextStep(MissionMoveStep.End);
}
else if (state == MissionState.Aborted.ToString())
{
missionMoveStep.Msg = info.FullName + "任务状态" + MissionState.Aborted.ToString() + ",重新发送";
missionMoveStep.NextStep(MissionMoveStep.None);
}
}
else
{
missionMoveStep.Msg = info.FullName + "获取任务状态id[" + id + "]失败";
}
}
}
else if (missionMoveStep.IsEqual(MissionMoveStep.End))
{
IsEnd = true;
}
return this;
}
private enum MissionMoveStep
{
None,
Moving,
End
}
}
}
\ No newline at end of file \ No newline at end of file
...@@ -5,18 +5,21 @@ namespace Model ...@@ -5,18 +5,21 @@ namespace Model
public class SendNewJob : Job public class SendNewJob : Job
{ {
private string id; private string id;
private string name = null; private int dockTime;
private int delayGetSignal;
private JobStep<SendNewStep> sendNewStep; private JobStep<SendNewStep> sendNewStep;
public SendNewJob() public SendNewJob()
{ {
sendNewStep = new JobStep<SendNewStep>(SendNewStep.None); sendNewStep = new JobStep<SendNewStep>(SendNewStep.None);
Common.log.Debug("进入SendNewJob任务");
} }
public override Job Execute(AgvInfo info) public override Job Execute(AgvInfo info)
{ {
if (sendNewStep.IsEqual(SendNewStep.None)) if (sendNewStep.IsEqual(SendNewStep.None))
{ {
dockTime = 0;
info.FillSteelCount(); info.FillSteelCount();
sendNewStep.Msg = info.FullName + "等待任务"; sendNewStep.Msg = info.FullName + "等待任务";
sendNewStep.NextStep(SendNewStep.FindMission); sendNewStep.NextStep(SendNewStep.FindMission);
...@@ -36,6 +39,11 @@ namespace Model ...@@ -36,6 +39,11 @@ namespace Model
MoveDoor(info); MoveDoor(info);
} }
} }
//else
//{
// sendNewStep.Msg = info.FullName + "没有找到任务";
// sendNewStep.NextStep(SendNewStep.End);
//}
} }
else if (sendNewStep.IsEqual(SendNewStep.WaitWorkshopDoor)) else if (sendNewStep.IsEqual(SendNewStep.WaitWorkshopDoor))
{ {
...@@ -69,9 +77,8 @@ namespace Model ...@@ -69,9 +77,8 @@ namespace Model
rtn = Common.steelManage.FindNewSteelWork(info, out string place); rtn = Common.steelManage.FindNewSteelWork(info, out string place);
if (rtn) if (rtn)
{ {
name = place; info.Place = place;
info.Place = name; mission = "MoveSteel" + info.Place;
mission = "MoveSteel" + name;
Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id); Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id);
sendNewStep.Msg = info.FullName + "发送任务" + mission; sendNewStep.Msg = info.FullName + "发送任务" + mission;
sendNewStep.NextStep(SendNewStep.MoveLine); sendNewStep.NextStep(SendNewStep.MoveLine);
...@@ -91,9 +98,19 @@ namespace Model ...@@ -91,9 +98,19 @@ namespace Model
{ {
if (state == MissionState.Done.ToString()) if (state == MissionState.Done.ToString())
{ {
Common.steelManage.NewSteelWorkDel(info.SteelFrom, name);
sendNewStep.Msg = info.FullName + "完成" + mission; sendNewStep.Msg = info.FullName + "完成" + mission;
sendNewStep.NextStep(SendNewStep.FindLine); if (info.Place == "storage")
{
delayGetSignal = 0;
sendNewStep.Msg = info.FullName + "等待到位信号";
sendNewStep.NextStep(SendNewStep.GetSingle);
}
else
{
Common.steelManage.NewSteelWorkDel(info.SteelFrom, info.Place);
sendNewStep.NextStep(SendNewStep.FindLine);
}
} }
else if (state == MissionState.Aborted.ToString()) else if (state == MissionState.Aborted.ToString())
{ {
...@@ -105,12 +122,55 @@ namespace Model ...@@ -105,12 +122,55 @@ namespace Model
sendNewStep.Msg = info.FullName + "获取任务状态id[" + id + "]失败"; sendNewStep.Msg = info.FullName + "获取任务状态id[" + id + "]失败";
} }
} }
else if (sendNewStep.IsEqual(SendNewStep.GetSingle))
{
if (Common.StorageDockFinish)
{
Common.steelManage.NewSteelWorkDel(info.SteelFrom, info.Place);
sendNewStep.Msg = info.FullName + "已到位,等待离开信号";
sendNewStep.NextStep(SendNewStep.WaitStorageLeave);
}
else
{
if (delayGetSignal >= 2)
{
if (dockTime >= 3)
{
sendNewStep.Msg = info.FullName + "对接仓库连续3次信号没有到位";
sendNewStep.NextStep(SendNewStep.Error);
dockTime = 0;
//小车报警任务
}
else
{
dockTime++;
mission = "MoveSteel" + info.Place;
Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id);
sendNewStep.Msg = info.FullName + "信号没有到位,第" + dockTime + "次重发任务" + mission;
sendNewStep.NextStep(SendNewStep.MoveLine);
}
}
delayGetSignal++;
}
}
else if (sendNewStep.IsEqual(SendNewStep.WaitStorageLeave))
{
if (Common.steelManage.FindStorageWorkLeave())
{
Common.steelManage.StorageWorkDelLeave();
sendNewStep.Msg = info.FullName + "收到离开信号";
sendNewStep.NextStep(SendNewStep.FindLine);
}
}
else if (sendNewStep.IsEqual(SendNewStep.End)) else if (sendNewStep.IsEqual(SendNewStep.End))
{ {
info.SteelFrom = ""; info.SteelFrom = "";
info.ClearSteelCount(); info.ClearSteelCount();
return new StandbyJob(); return new StandbyJob();
} }
else if (sendNewStep.IsEqual(SendNewStep.Error))
{
}
return this; return this;
} }
...@@ -140,7 +200,10 @@ namespace Model ...@@ -140,7 +200,10 @@ namespace Model
WaitWorkshopDoor, WaitWorkshopDoor,
FindLine, FindLine,
MoveLine, MoveLine,
End GetSingle,
WaitStorageLeave,
End,
Error
} }
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -5,17 +5,21 @@ namespace Model ...@@ -5,17 +5,21 @@ namespace Model
public class StandbyJob : Job public class StandbyJob : Job
{ {
private string id; private string id;
private int standingTime; //在待机位停留时间
private JobStep<StandbyStep> standbyStep; private JobStep<StandbyStep> standbyStep;
private const int STANDBY_TIMEOUT = 2 * 60; //待机位停留超时时间,秒
public StandbyJob() public StandbyJob()
{ {
standbyStep = new JobStep<StandbyStep>(StandbyStep.None); standbyStep = new JobStep<StandbyStep>(StandbyStep.None);
Common.log.Debug("进入StandbyJob任务");
} }
public override Job Execute(AgvInfo info) public override Job Execute(AgvInfo info)
{ {
if (standbyStep.IsEqual(StandbyStep.None)) if (standbyStep.IsEqual(StandbyStep.None))
{ {
info.ClearSteelCount();
if (info.IsSelfWorkshop()) if (info.IsSelfWorkshop())
MoveStandby(info); MoveStandby(info);
else else
...@@ -43,6 +47,7 @@ namespace Model ...@@ -43,6 +47,7 @@ namespace Model
{ {
if (state == MissionState.Done.ToString()) if (state == MissionState.Done.ToString())
{ {
standingTime = 0;
standbyStep.Msg = info.FullName + "已在待机位"; standbyStep.Msg = info.FullName + "已在待机位";
standbyStep.NextStep(StandbyStep.End); standbyStep.NextStep(StandbyStep.End);
} }
...@@ -58,9 +63,19 @@ namespace Model ...@@ -58,9 +63,19 @@ namespace Model
} }
else if (standbyStep.IsEqual(StandbyStep.End)) else if (standbyStep.IsEqual(StandbyStep.End))
{ {
if (info.Battery <= info.BatteryMin) standingTime += Common.AGV_CALL_SLEEP;
if (standingTime > STANDBY_TIMEOUT * 1000)
{
if (info.Battery < info.BatteryMax)
{
standbyStep.Msg = info.FullName + "在待机位停留超过2分钟,执行充电任务";
return new ChargeJob();
}
}
else if (info.Battery <= info.BatteryMin)
{ {
Common.log.Info(info.FullName + "电量小于" + info.BatteryMin + ",执行充电任务"); standbyStep.Msg = info.FullName + "电量小于" + info.BatteryMin + ",执行充电任务";
return new ChargeJob(); return new ChargeJob();
} }
else else
...@@ -102,7 +117,7 @@ namespace Model ...@@ -102,7 +117,7 @@ namespace Model
if (rtn) if (rtn)
{ {
info.Place = "待机位"; info.Place = "待机位";
standbyStep.Msg = info.FullName + "回待机位" + mission; standbyStep.Msg = info.FullName + "回待机位" + mission;
standbyStep.NextStep(StandbyStep.WaitStandby); standbyStep.NextStep(StandbyStep.WaitStandby);
} }
else else
......
...@@ -5,17 +5,21 @@ namespace Model ...@@ -5,17 +5,21 @@ namespace Model
public class StorageJob : Job public class StorageJob : Job
{ {
private string id; private string id;
private int delayGetSignal; //延迟获取信号
private int dockTime; //停靠次数
private JobStep<StorageStep> storageStep; private JobStep<StorageStep> storageStep;
public StorageJob() public StorageJob()
{ {
storageStep = new JobStep<StorageStep>(StorageStep.None); storageStep = new JobStep<StorageStep>(StorageStep.None);
Common.log.Debug("进入StorageJob任务");
} }
public override Job Execute(AgvInfo info) public override Job Execute(AgvInfo info)
{ {
if (storageStep.IsEqual(StorageStep.None)) if (storageStep.IsEqual(StorageStep.None))
{ {
dockTime = 0;
if (info.Is4DWorkshop()) if (info.Is4DWorkshop())
storageStep.NextStep(StorageStep.GoStorage); storageStep.NextStep(StorageStep.GoStorage);
else else
...@@ -43,6 +47,10 @@ namespace Model ...@@ -43,6 +47,10 @@ namespace Model
} }
else if (storageStep.IsEqual(StorageStep.GoStorage)) else if (storageStep.IsEqual(StorageStep.GoStorage))
{ {
Common.steelManage.FindStorageWork(info, out string place);
info.Place = place;
rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, Common.MISSION_MOVE_STORAGE, out id); rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, Common.MISSION_MOVE_STORAGE, out id);
if (rtn) if (rtn)
{ {
...@@ -61,9 +69,9 @@ namespace Model ...@@ -61,9 +69,9 @@ namespace Model
{ {
if (state == MissionState.Done.ToString()) if (state == MissionState.Done.ToString())
{ {
Common.steelManage.NewSteelWorkDel(info.SteelFrom, info.SteelFrom);
storageStep.Msg = info.FullName + "已在仓库"; storageStep.Msg = info.FullName + "已在仓库";
storageStep.NextStep(StorageStep.End); delayGetSignal = 0;
storageStep.NextStep(StorageStep.GetSingle);
} }
else if (state == MissionState.Aborted.ToString()) else if (state == MissionState.Aborted.ToString())
{ {
...@@ -75,10 +83,43 @@ namespace Model ...@@ -75,10 +83,43 @@ namespace Model
storageStep.Msg = info.FullName + "获取任务状态id[" + id + "]失败"; storageStep.Msg = info.FullName + "获取任务状态id[" + id + "]失败";
} }
} }
else if (storageStep.IsEqual(StorageStep.GetSingle))
{
if (Common.StorageDockFinish)
{
Common.steelManage.StorageWorkDel(info.Place);
storageStep.NextStep(StorageStep.End);
}
else
{
if (delayGetSignal >= 3)
{
if (dockTime >= 3)
{
storageStep.Msg = info.FullName + "对接仓库连续3次信号没有到位";
storageStep.NextStep(StorageStep.Error);
dockTime = 0;
//小车报警任务
}
else
{
dockTime++;
mission = "MoveSteel" + info.Place;
Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id);
storageStep.Msg = info.FullName + "信号没有到位,第" + dockTime + "次重发任务" + mission;
storageStep.NextStep(StorageStep.GoStorage);
}
}
delayGetSignal++;
}
}
else if (storageStep.IsEqual(StorageStep.End)) else if (storageStep.IsEqual(StorageStep.End))
{ {
return new SendNewJob(); return new SendNewJob();
} }
else if (storageStep.IsEqual(StorageStep.Error))
{
}
return this; return this;
} }
...@@ -102,6 +143,8 @@ namespace Model ...@@ -102,6 +143,8 @@ namespace Model
WaitWorkshopDoor, WaitWorkshopDoor,
GoStorage, GoStorage,
WaitStorage, WaitStorage,
GetSingle,
Error,
End End
} }
} }
......
...@@ -11,12 +11,14 @@ namespace Model ...@@ -11,12 +11,14 @@ namespace Model
public TakeOldJob() public TakeOldJob()
{ {
takeOldStep = new JobStep<TakeOldStep>(TakeOldStep.None); takeOldStep = new JobStep<TakeOldStep>(TakeOldStep.None);
Common.log.Debug("进入TakeOldJob任务");
} }
public override Job Execute(AgvInfo info) public override Job Execute(AgvInfo info)
{ {
if (takeOldStep.IsEqual(TakeOldStep.None)) if (takeOldStep.IsEqual(TakeOldStep.None))
{ {
info.ClearSteelCount();
takeOldStep.NextStep(TakeOldStep.FindLine); takeOldStep.NextStep(TakeOldStep.FindLine);
} }
else if (takeOldStep.IsEqual(TakeOldStep.FindLine)) else if (takeOldStep.IsEqual(TakeOldStep.FindLine))
...@@ -68,7 +70,7 @@ namespace Model ...@@ -68,7 +70,7 @@ namespace Model
if (rtn) if (rtn)
{ {
info.Place = "4D清洗点"; info.Place = "4D清洗点";
takeOldStep.Msg = info.FullName + "去" + info.Workshop + "清洗点"; takeOldStep.Msg = info.FullName + "去" + info.Workshop.ToUpper() + "清洗点";
takeOldStep.NextStep(TakeOldStep.WaitWashPoint); takeOldStep.NextStep(TakeOldStep.WaitWashPoint);
} }
else else
...@@ -114,7 +116,7 @@ namespace Model ...@@ -114,7 +116,7 @@ namespace Model
info.Place = name; info.Place = name;
mission = "MoveSteel" + name; mission = "MoveSteel" + name;
Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id); Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id);
takeOldStep.Msg = info.FullName + "发送任务" + mission; takeOldStep.Msg = info.FullName + "发送任务" + mission;
takeOldStep.NextStep(TakeOldStep.MoveLine); takeOldStep.NextStep(TakeOldStep.MoveLine);
info.SteelCountAdd(); info.SteelCountAdd();
} }
......
...@@ -10,6 +10,7 @@ namespace Model ...@@ -10,6 +10,7 @@ namespace Model
public WashPointJob() public WashPointJob()
{ {
washPointStep = new JobStep<WashPointStep>(WashPointStep.None); washPointStep = new JobStep<WashPointStep>(WashPointStep.None);
Common.log.Debug("进入WashPointJob任务");
} }
public override Job Execute(AgvInfo info) public override Job Execute(AgvInfo info)
...@@ -28,7 +29,7 @@ namespace Model ...@@ -28,7 +29,7 @@ namespace Model
rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id); rtn = Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, mission, out id);
if (rtn) if (rtn)
{ {
washPointStep.Msg = info.FullName + "去" + info.Workshop + "清洗点"; washPointStep.Msg = info.FullName + "去" + info.Workshop.ToUpper() + "清洗点";
washPointStep.NextStep(WashPointStep.WaitWashPoint); washPointStep.NextStep(WashPointStep.WaitWashPoint);
} }
else else
......
...@@ -30,7 +30,7 @@ namespace Model ...@@ -30,7 +30,7 @@ namespace Model
{ {
get get
{ {
return string.Format("{0}[{1}]", Name, IP); return string.Format("{0}[{1}] ", Name, IP);
} }
} }
/// <summary> /// <summary>
...@@ -106,10 +106,16 @@ namespace Model ...@@ -106,10 +106,16 @@ namespace Model
/// <returns></returns> /// <returns></returns>
public string[] ToRow() public string[] ToRow()
{ {
string[] arr = new string[] { Name, Place, StateText, MissionText, Battery.ToString(), IsOnline.ToString(), IsAuto.ToString(), "清除" }; string[] arr = new string[] { Name, Place, StateText, Battery.ToString(), IsOnline.ToString(), IsAuto.ToString(), "清除" };
return arr; return arr;
} }
public string ToMissionState()
{
string s = FullName + "\r\n\r\n" + MissionText;
return s;
}
/// <summary> /// <summary>
/// 是否在自己的车间里面 /// 是否在自己的车间里面
/// </summary> /// </summary>
......
...@@ -78,6 +78,7 @@ namespace Model ...@@ -78,6 +78,7 @@ namespace Model
{ {
string time = string.Format("[{0:HH:mm:ss}] ", DateTime.Now); string time = string.Format("[{0:HH:mm:ss}] ", DateTime.Now);
Common.txtLog.AppendText(time + value + "\r\n"); Common.txtLog.AppendText(time + value + "\r\n");
Common.txtLog.SelectionStart = Common.txtLog.Text.Length;
Common.txtLog.ScrollToCaret(); Common.txtLog.ScrollToCaret();
} }
} }
......
...@@ -32,8 +32,6 @@ namespace AGVControl_Steel ...@@ -32,8 +32,6 @@ namespace AGVControl_Steel
Common.log.Info("=====程序开始====="); Common.log.Info("=====程序开始=====");
ReadConfig(); ReadConfig();
Common.steelManage = new BLL.SteelManage(); Common.steelManage = new BLL.SteelManage();
//Common.steelManage.OldSteelWorkLoad();
//Common.steelManage.NewSteelWorkLoad();
Common.control = new BLL.Control(); Common.control = new BLL.Control();
Common.mir = new Model.MiR_API { FleetIP = Common.appConfig.AppSettings.Settings["FLEET_IP"].Value, MissionList = Common.agvMissions }; Common.mir = new Model.MiR_API { FleetIP = Common.appConfig.AppSettings.Settings["FLEET_IP"].Value, MissionList = Common.agvMissions };
......
...@@ -32,5 +32,5 @@ using System.Runtime.InteropServices; ...@@ -32,5 +32,5 @@ using System.Runtime.InteropServices;
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值 //可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
//通过使用 "*",如下所示: //通过使用 "*",如下所示:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.1.0.0")] [assembly: AssemblyVersion("1.1.1.0")]
[assembly: AssemblyFileVersion("1.1.0.0")] [assembly: AssemblyFileVersion("1.1.1.0")]
...@@ -23,33 +23,47 @@ namespace AGVControl_Steel ...@@ -23,33 +23,47 @@ namespace AGVControl_Steel
private void Control_AgvChanged(int agvIndex) private void Control_AgvChanged(int agvIndex)
{ {
DgvName.Rows[agvIndex].SetValues(Common.agvInfos[agvIndex].ToRow()); DgvName.Rows[agvIndex].SetValues(Common.agvInfos[agvIndex].ToRow());
tableLayoutPanel5.Controls["TxtAgvMission" + agvIndex].Text = Common.agvInfos[agvIndex].ToMissionState();
} }
private void Control_AgvOnline(int agvIndex) private void Control_AgvOnline(int agvIndex)
{ {
DgvName.Rows[agvIndex].DefaultCellStyle.ForeColor = Common.agvInfos[agvIndex].IsOnline ? Color.Black : Color.Red; DgvName.Rows[agvIndex].DefaultCellStyle.ForeColor = Common.agvInfos[agvIndex].IsOnline ? Color.Black : Color.Red;
DgvName.Rows[agvIndex].SetValues(Common.agvInfos[agvIndex].ToRow()); DgvName.Rows[agvIndex].SetValues(Common.agvInfos[agvIndex].ToRow());
tableLayoutPanel5.Controls["TxtAgvMission" + agvIndex].Text = Common.agvInfos[agvIndex].ToMissionState();
} }
private void FrmMain_Load(object sender, EventArgs e) private void FrmMain_Load(object sender, EventArgs e)
{ {
Common.txtLog = TxtLog; Common.txtLog = TxtLog;
Common.txtOldSteel = TxtOldSteel; Common.lstOldSteel = LstOldSteel;
Common.txtNewSteel = TxtNewSteel; Common.lstNewSteel = LstNewSteel;
Common.lstStorage = LstStorage;
Common.lblStorageIO = LblStorageIO;
Common.steelManage.OldSteelWorkLoad(); Common.steelManage.OldSteelWorkLoad();
Common.steelManage.NewSteelWorkLoad(); Common.steelManage.NewSteelWorkLoad();
Common.steelManage.StorageWorkLoad();
Asa.WindowsForm.Load(this); Asa.WindowsForm.Load(this);
webService = new Webs.WebService(); webService = new Webs.WebService();
webService.Open(Common.appConfig.AppSettings.Settings["WebService"].Value); webService.Open(Common.appConfig.AppSettings.Settings["WebService"].Value);
LblWeb.BackColor = webService.IsOpen ? Color.Lime : Color.Red; LblWeb.BackColor = webService.IsOpen ? Color.Lime : Color.Red;
LblWeb.Text = webService.IsOpen ? "WebService Open" : "WebService Close"; LblWeb.Text = webService.IsOpen ? "WebService Open" : "WebService Close";
LstMission.Items.AddRange(Common.agvMissions.Keys.ToArray());
List<string> missionHint = new List<string>();
missionHint.AddRange(Common.PLACE_NAME);
missionHint.Add(Common.STORAGE_ENTER_4C);
missionHint.Add(Common.STORAGE_ENTER_4D);
missionHint.Add(Common.STORAGE_LEAVE);
LblMissionHint.Text = "提示:" + string.Join(",", missionHint);
for (int i = 0; i < Common.agvInfos.Count; i++) for (int i = 0; i < Common.agvInfos.Count; i++)
{ {
DgvName.Rows.Add(Common.agvInfos[i].ToRow()); DgvName.Rows.Add(Common.agvInfos[i].ToRow());
DgvName.Rows[i].DefaultCellStyle.ForeColor = Color.Red; DgvName.Rows[i].DefaultCellStyle.ForeColor = Color.Red;
DgvName.Rows[i].HeaderCell.Value = (i + 1).ToString(); DgvName.Rows[i].HeaderCell.Value = (i + 1).ToString();
DgvName.Rows[i].Height = 30;
} }
Common.control.AgvChanged += Control_AgvChanged; Common.control.AgvChanged += Control_AgvChanged;
...@@ -86,6 +100,7 @@ namespace AGVControl_Steel ...@@ -86,6 +100,7 @@ namespace AGVControl_Steel
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;
info.Place = "";
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.FleetID].Value = info.IsAuto.ToString(); Common.appConfig.AppSettings.Settings[info.FleetID].Value = info.IsAuto.ToString();
Common.appConfig.Save(); Common.appConfig.Save();
...@@ -94,6 +109,155 @@ namespace AGVControl_Steel ...@@ -94,6 +109,155 @@ namespace AGVControl_Steel
} }
} }
#region 手动添加小车任务
private void BtnMissionAdd_Click(object sender, EventArgs e)
{
if (DgvName.SelectedCells.Count == 0) return;
int idx = DgvName.SelectedCells[0].RowIndex;
if (idx < 0) return;
if (LstMission.SelectedIndex == -1) return;
AgvInfo info = Common.agvInfos[idx];
Common.mir.Add_Mission_Fleet(info.FleetID, info.Authorization, LstMission.Text, out string id);
}
private void BtnMissionClear_Click(object sender, EventArgs e)
{
if (DgvName.SelectedCells.Count == 0) return;
int idx = DgvName.SelectedCells[0].RowIndex;
if (idx < 0) return;
AgvInfo info = Common.agvInfos[DgvName.SelectedRows[0].Index];
Common.mir.Del_Mission(info.IP, info.Authorization);
}
private void BtnMissionRun_Click(object sender, EventArgs e)
{
if (DgvName.SelectedCells.Count == 0) return;
int idx = DgvName.SelectedCells[0].RowIndex;
if (idx < 0) return;
AgvInfo info = Common.agvInfos[DgvName.SelectedRows[0].Index];
Common.mir.State_Ready(info.IP, info.Authorization);
}
private void BtnMissionPause_Click(object sender, EventArgs e)
{
if (DgvName.SelectedCells.Count == 0) return;
int idx = DgvName.SelectedCells[0].RowIndex;
if (idx < 0) return;
AgvInfo info = Common.agvInfos[DgvName.SelectedRows[0].Index];
Common.mir.State_Pause(info.IP, info.Authorization);
}
#endregion
#region 手动修改钢网任务
private void BtnOldSteelWorkAdd_Click(object sender, EventArgs e)
{
string text = "手动添加回收钢板任务";
string msg = Microsoft.VisualBasic.Interaction.InputBox(text, "添加", "");
if (string.IsNullOrWhiteSpace(msg)) return;
Common.log.Info(text + " " + msg);
Common.steelManage.OldSteelWorkAdd(msg);
}
private void BtnOldSteelWorkDel_Click(object sender, EventArgs e)
{
if (LstOldSteel.SelectedIndex == -1) return;
string[] arr = LstOldSteel.Text.Split(',');
string text = "手动删除【" + arr[0] + "】回收钢板任务";
DialogResult dr = MessageBox.Show(text, "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
if (dr == DialogResult.Yes)
{
Common.log.Info(text);
Common.steelManage.OldSteelWorkDel(arr[0]);
}
}
private void BtnOldSteelWorkDelAll_Click(object sender, EventArgs e)
{
string text = "手动删除全部回收钢板任务";
DialogResult dr = MessageBox.Show(text, "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
if (dr == DialogResult.Yes)
{
Common.log.Info(text);
Common.steelManage.OldSteelWorkDelAll();
}
}
private void BtnNewSteelWorkAdd_Click(object sender, EventArgs e)
{
string text = "手动添加送新钢板任务,from&place逗号分割";
string msg = Microsoft.VisualBasic.Interaction.InputBox(text, "添加", "");
if (string.IsNullOrWhiteSpace(msg)) return;
string[] arr = msg.Split(',');
Common.log.Info(text + " " + msg);
Common.steelManage.NewSteelWorkAdd(arr[0], arr[1]);
}
private void BtnNewSteelWorkDel_Click(object sender, EventArgs e)
{
if (LstNewSteel.SelectedIndex == -1) return;
string[] arr = LstNewSteel.Text.Split(',');
string text = "手动删除【" + arr[0] + "," + arr[1] + "】送新钢板任务";
DialogResult dr = MessageBox.Show(text, "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
if (dr == DialogResult.Yes)
{
Common.log.Info(text);
Common.steelManage.NewSteelWorkDel(arr[0], arr[1]);
}
}
private void BtnNewSteelWorkDelAll_Click(object sender, EventArgs e)
{
string text = "手动删除全部送新钢板任务";
DialogResult dr = MessageBox.Show(text, "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
if (dr == DialogResult.Yes)
{
Common.log.Info(text);
Common.steelManage.NewSteelWorkDelAll();
}
}
private void BtnStorageWorkAdd_Click(object sender, EventArgs e)
{
string text = "手动添加仓库钢板任务";
string msg = Microsoft.VisualBasic.Interaction.InputBox(text, "添加", "");
if (string.IsNullOrWhiteSpace(msg)) return;
Common.log.Info(text + " " + msg);
Common.steelManage.StorageWorkAdd(msg);
}
private void BtnStorageWorkDel_Click(object sender, EventArgs e)
{
if (LstStorage.SelectedIndex == -1) return;
string[] arr = LstStorage.Text.Split(',');
string text = "手动删除【" + arr[0] + "】仓库钢板任务";
DialogResult dr = MessageBox.Show(text, "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
if (dr == DialogResult.Yes)
{
Common.log.Info(text);
Common.steelManage.StorageWorkDel(arr[0]);
}
}
private void BtnStorageWorkDelAll_Click(object sender, EventArgs e)
{
string text = "手动删除全部仓库钢板任务";
DialogResult dr = MessageBox.Show(text, "删除", MessageBoxButtons.YesNo, MessageBoxIcon.Information);
if (dr == DialogResult.Yes)
{
Common.log.Info(text);
Common.steelManage.StorageWorkDelAll();
}
}
#endregion
} }
......
...@@ -117,6 +117,9 @@ ...@@ -117,6 +117,9 @@
<resheader name="writer"> <resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader> </resheader>
<metadata name="DgvName.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
...@@ -126,9 +129,6 @@ ...@@ -126,9 +129,6 @@
<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">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="Column6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column3.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>
...@@ -141,6 +141,114 @@ ...@@ -141,6 +141,114 @@
<metadata name="Column8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="Column8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="tabControl1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="tabPage2.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="tableLayoutPanel5.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="TxtAgvMission0.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="TxtLog.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="TxtAgvMission1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="LblStorageIO.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="LblWeb.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="tabPage3.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="LblMissionHint.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="tableLayoutPanel1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="LstStorage.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="LstOldSteel.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="LstNewSteel.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="tableLayoutPanel2.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnOldSteelWorkDelAll.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnOldSteelWorkDel.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnOldSteelWorkAdd.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="tableLayoutPanel3.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnNewSteelWorkDelAll.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnNewSteelWorkDel.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnNewSteelWorkAdd.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="tableLayoutPanel4.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnStorageWorkDelAll.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnStorageWorkDel.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnStorageWorkAdd.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label2.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label3.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="tabPage1.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnMissionPause.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnMissionRun.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnMissionClear.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="BtnMissionAdd.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="LstMission.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="$this.Locked" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /> <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
......
<?xml version="1.0" encoding="utf-8" ?> <?xml version="1.0" encoding="utf-8" ?>
<configuration> <configuration>
<configSections> <configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net"/> <section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler,log4net"/>
...@@ -37,15 +37,16 @@ ...@@ -37,15 +37,16 @@
</logger> </logger>
</log4net> </log4net>
<appSettings> <appSettings>
<add key="FLEET_IP" value="10.85.199.3" /> <add key="FLEET_IP" value="10.85.199.3" />
<add key="WebService" value="http://10.85.196.40:8089/"/> <add key="FLEET_Send" value="true" />
<add key="AGV_BATTERY_MAX" value="100"/> <add key="WebService" value="http://10.85.196.40:8089/" />
<add key="AGV_BATTERY_MIN" value="60"/> <add key="AGV_BATTERY_MAX" value="100" />
<!--<add key="4D_Line" value="D1,D2,D3,D4,D5,D6,D8,D9,D10,D11,D12,D14,D15,D16"/> <add key="AGV_BATTERY_MIN" value="40" />
<add key="4C_Line" value="C1,C2,C3,C4,C5,C6,C7,C8,C9,C10"/> <add key="4C_AGV" value="32" />
<add key="Store" value="4cwash,4dwash,storage"/>--> <add key="4D_AGV" value="25" />
<add key="PlaceName" value="D1,D2,D3,D4,D5,D6,D8,D9,D10,D11,D12,D14,D15,D16,C1,C2,C3,C4,C5,C6,C7,C8,C9,C10,4cwash,4dwash,storage"/> <add key="PlaceName" value="D1,D2,D3,D4,D5,D6,D7,D8,D9,D10,D11,D12,D13,D14,D15,D16,C1,C2,C3,C4,C5,C6,C7,C8,C9,C10,C11,C12,C13,C14,C15,C16,4cwash,4dwash,storage" />
<add key="4D_AGV" value="3"/> <add key="32" value="false" />
<add key="4C_AGV" value="32"/> <add key="25" value="false" />
</appSettings> <add key="26" value="false" />
</appSettings>
</configuration> </configuration>
\ No newline at end of file \ No newline at end of file
32,11号_1762,10.85.199.82,Basic ZGlzdHJpYnV0b3I6NjJmMmYwZjFlZmYxMGQzMTUyYzk1ZjZmMDU5NjU3NmU0ODJiYjhlNDQ4MDY0MzNmNGNmOTI5NzkyODM0YjAxNA==
25,13号_1766,10.85.199.84,Basic ZGlzdHJpYnV0b3I6NjJmMmYwZjFlZmYxMGQzMTUyYzk1ZjZmMDU5NjU3NmU0ODJiYjhlNDQ4MDY0MzNmNGNmOTI5NzkyODM0YjAxNA==
3,1号_1467,10.85.199.67,Basic ZGlzdHJpYnV0b3I6NjJmMmYwZjFlZmYxMGQzMTUyYzk1ZjZmMDU5NjU3NmU0ODJiYjhlNDQ4MDY0MzNmNGNmOTI5NzkyODM0YjAxNA==
\ No newline at end of file \ No newline at end of file
32,11号_4C,10.85.199.82,Basic ZGlzdHJpYnV0b3I6NjJmMmYwZjFlZmYxMGQzMTUyYzk1ZjZmMDU5NjU3NmU0ODJiYjhlNDQ4MDY0MzNmNGNmOTI5NzkyODM0YjAxNA==
25,13号_4D,10.85.199.84,Basic ZGlzdHJpYnV0b3I6NjJmMmYwZjFlZmYxMGQzMTUyYzk1ZjZmMDU5NjU3NmU0ODJiYjhlNDQ4MDY0MzNmNGNmOTI5NzkyODM0YjAxNA==
\ 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

\ No newline at end of file \ No newline at end of file
[2020-09-10 14:29:58,242][1][AGVControl_Steel:32]INFO =====程序开始=====
[2020-09-10 14:29:58,379][1][AGVControl_Steel:80]INFO 读取配置文件 D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\Config\AgvName.csv
[2020-09-10 14:29:58,380][1][AGVControl_Steel:91]INFO 读取配置文件 D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\Config\AgvMission.csv
[2020-09-10 14:29:59,366][1][AGVControl_Steel:172]INFO Web服务已开启
[2020-09-10 14:30:05,682][1][AGVControl_Steel:73]INFO 手动修改 4号_1470 IsUse=True
[2020-09-10 14:30:11,916][8][AGVControl_Steel:76]INFO None:4号_1470[10.85.199.70]回待机位Move4DStandby
[2020-09-10 14:30:14,539][8][AGVControl_Steel:76]INFO WaitStandby:4号_1470[10.85.199.70]已在待机位
[2020-09-10 14:31:43,325][1][AGVControl_Steel:189]INFO Web服务已关闭
[2020-09-10 14:31:43,388][1][AGVControl_Steel:43]INFO =====程序结束=====
1010f035bba49815b3022e46603e0845961d0731 b7ce55f3eb8a41195dbd285ef65f42aa74fe3fdd
...@@ -12,3 +12,16 @@ D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Ste ...@@ -12,3 +12,16 @@ D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Ste
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\ClassFormParent.dll D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\ClassFormParent.dll
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\ClassFormParent.pdb D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\ClassFormParent.pdb
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.csprojAssemblyReference.cache D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.csprojAssemblyReference.cache
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\AGVControl_Steel.exe.config
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\AGVControl_Steel.exe
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\AGVControl_Steel.pdb
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\ClassFormParent.dll
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\bin\Debug\ClassFormParent.pdb
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.FrmMain.resources
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.Properties.Resources.resources
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.csproj.GenerateResource.cache
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.csproj.CoreCompileInputs.cache
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.csproj.CopyComplete
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.exe
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.pdb
D:\OneDrive\SMD\AGVControl_Steel\AGVControl_Steel\obj\Debug\AGVControl_Steel.csprojAssemblyReference.cache
...@@ -84,7 +84,7 @@ namespace Test ...@@ -84,7 +84,7 @@ namespace Test
private void button4_Click(object sender, EventArgs e) private void button4_Click(object sender, EventArgs e)
{ {
RestClient client = new RestClient("http://10.85.196.40:8089/StealAgv/sendNew?from=storage&place=storage"); RestClient client = new RestClient("http://10.85.196.40:8089/StealAgv/storage?place=4D_Enter");
client.Timeout = -1; client.Timeout = -1;
RestRequest request = new RestRequest(Method.GET); RestRequest request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request); IRestResponse response = client.Execute(request);
......
...@@ -3,7 +3,6 @@ D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\bin\Debug ...@@ -3,7 +3,6 @@ D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\bin\Debug
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\bin\Debug\Test.pdb D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\bin\Debug\Test.pdb
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\bin\Debug\RestSharp.dll D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\bin\Debug\RestSharp.dll
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\bin\Debug\RestSharp.xml D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\bin\Debug\RestSharp.xml
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\obj\Debug\Test.csprojAssemblyReference.cache
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\obj\Debug\Test.Form1.resources D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\obj\Debug\Test.Form1.resources
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\obj\Debug\Test.Properties.Resources.resources D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\obj\Debug\Test.Properties.Resources.resources
D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\obj\Debug\Test.csproj.GenerateResource.cache D:\OneDrive - 上海挚锦科技有限公司\SMD\AGVControl_Steel\Test\obj\Debug\Test.csproj.GenerateResource.cache
......
此文件类型无法预览
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!