Commit 2ec35899 张东亮
2 个父辈 d97b9663 c0849f9f
......@@ -113,5 +113,6 @@ namespace OnlineStore.Common
public static string AShelfInfo = "AShelfInfo";
public static string BShelfInfo = "BShelfInfo";
public static string UseSecurityAccess = "UseSecurityAccess";
}
}
类型,分类编号,说明,名称,属性值,设备名称,电器定义,目标速度,加速度,减速度,回零低速,回零高速,回零加速度,脉冲最小误差,脉冲最大误差,脉冲最小限位,脉冲最大限位
类型,分类编号,说明,名称,属性值,设备名称,电器定义,目标速度,加速度,减速度,回零低速,回零高速,回零加速度,脉冲最小误差,脉冲最大误差,脉冲最小限位,脉冲最大限位
AXIS,0,行走机构,MoveAxis,0,HC,,15000,300000,200000,5000,30000,60000,10,100,0,0
AXIS,0,料斗拉取进出轴,PullAxis_Inout,1,HC,,50000,130000,130000,5000,50000,100000,10,100,0,0
AXIS,0,移栽升降轴,UpdownAxis,2,HC,,150000,1000000,800000,2000,20000,50000,10,100,0,0
......@@ -12,10 +12,10 @@ AXIS,0,B面移栽压紧轴,ComAxis_B,9,HC,,20000,50000,50000,2000,10000,20000,10
,,,,,,,,,,,,,,,,
PRO,0,设备是否处于调试状态(1=调试,0=正常),IsDebug,0,,,,,,,,,,,,
PRO,0,温湿度端口号,Humiture_Port,0,,,,,,,,,,,,
PRO,0,抽屉Mark_X坐标,Drawer_X,962.07,,,,,,,,,,,,
PRO,0,抽屉Mark_Y坐标,Drawer_Y,862.94,,,,,,,,,,,,
PRO,0,抽屉Mark_X方向误差范围,Drawer_X_Error,3,,,,,,,,,,,,
PRO,0,抽屉Mark_Y方向误差范围,Drawer_Y_Error,3,,,,,,,,,,,,
PRO,0,抽屉Mark_X坐标,Drawer_X,999.91,,,,,,,,,,,,
PRO,0,抽屉Mark_Y坐标,Drawer_Y,876.22,,,,,,,,,,,,
PRO,0,抽屉Mark_X方向误差范围,Drawer_X_Error,20000,,,,,,,,,,,,
PRO,0,抽屉Mark_Y方向误差范围,Drawer_Y_Error,20000,,,,,,,,,,,,
PRO,0,抽屉行间距,Row_Spacing,850000,,,,,,,,,,,,
PRO,0,抽屉列间距,Column_Spacing,333300,,,,,,,,,,,,
PRO,0,抽屉层数,Drawer_Rows,15,,,,,,,,,,,,
......@@ -35,7 +35,7 @@ PRO,0,移栽升降轴_A下暂存区放料低点P5,Updown_P5,670000,,,,,,,,,,,,
PRO,0,移栽升降轴_B上暂存区取料高点P8,Updown_P8,1506534,,,,,,,,,,,,
PRO,0,移栽升降轴_B上暂存区取料低点P9,Updown_P9,1338069,,,,,,,,,,,,
PRO,0,移栽升降轴_B下暂存区取料高点P10,Updown_P10,827531,,,,,,,,,,,,
PRO,0,移栽升降轴_B下暂存区取料低点P11,Updown_P11,660000,,,,,,,,,,,,
PRO,0,移栽升降轴_B下暂存区取料低点P11,Updown_P11,651000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,料斗拉取升降轴_待机点P1,PullAxis_Updown_P1,0,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
......@@ -46,7 +46,7 @@ PRO,0,A面移栽旋转轴_待机点P1,MiddleAxis_A_P1,-918,,,,,,,,,,,,
PRO,0,A面移栽旋转轴_A进出料暂存区取放料水平点P2,MiddleAxis_A_P2,95000,,,,,,,,,,,,
PRO,0,A面移栽旋转轴_A面料屉库位垂直取放料点P3,MiddleAxis_A_P3,-918,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,A面移栽压紧轴_待机点P1,ComAxis_A_P1,10000,,,,,,,,,,,,
PRO,0,A面移栽压紧轴_待机点P1,ComAxis_A_P1,9000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,B面移栽X轴_待机点P1,XAxis_B_P1,661000,,,,,,,,,,,,
......@@ -56,7 +56,7 @@ PRO,0,B面移栽旋转轴_待机点P1,MiddleAxis_B_P1,-2000,,,,,,,,,,,,
PRO,0,B面移栽旋转轴_B进出料暂存区取放料水平点P2,MiddleAxis_B_P2,95000,,,,,,,,,,,,
PRO,0,B面移栽旋转轴_B面料屉库位垂直取放料点P3,MiddleAxis_B_P3,-2000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,B面移栽压紧轴_待机点P1,ComAxis_B_P1,10000,,,,,,,,,,,,
PRO,0,B面移栽压紧轴_待机点P1,ComAxis_B_P1,8000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,行走机构_P1速度,MoveAxis_P1_Speed,100000,,,,,,,,,,,,
PRO,0,行走机构_P2速度,MoveAxis_P2_Speed,100000,,,,,,,,,,,,
......@@ -64,9 +64,9 @@ PRO,0,行走机构_P3速度,MoveAxis_P3_Speed,100000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,料斗拉取进出轴_P1速度,PullAxis_Inout_P1_Speed,100000,,,,,,,,,,,,
PRO,0,料斗拉取进出轴_P2速度,PullAxis_Inout_P2_Speed,100000,,,,,,,,,,,,
PRO,0,料斗拉取进出轴_P3速度,PullAxis_Inout_P3_Speed,80000,,,,,,,,,,,,
PRO,0,料斗拉取进出轴_P3速度,PullAxis_Inout_P3_Speed,120000,,,,,,,,,,,,
PRO,0,料斗拉取进出轴_P4速度,PullAxis_Inout_P4_Speed,100000,,,,,,,,,,,,
PRO,0,料斗拉取进出轴_P5速度,PullAxis_Inout_P5_Speed,80000,,,,,,,,,,,,
PRO,0,料斗拉取进出轴_P5速度,PullAxis_Inout_P5_Speed,100000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,移栽升降轴_P1速度,Updown_P1_Speed,200000,,,,,,,,,,,,
PRO,0,移栽升降轴_P2速度,Updown_P2_Speed,100000,,,,,,,,,,,,
......@@ -79,7 +79,7 @@ PRO,0,移栽升降轴_P8速度,Updown_P8_Speed,100000,,,,,,,,,,,,
PRO,0,移栽升降轴_P9速度,Updown_P9_Speed,150000,,,,,,,,,,,,
PRO,0,移栽升降轴_P10速度,Updown_P10_Speed,100000,,,,,,,,,,,,
PRO,0,移栽升降轴_P11速度,Updown_P11_Speed,150000,,,,,,,,,,,,
PRO,0,移栽升降轴_P12速度,Updown_P12_Speed,200000,,,,,,,,,,,,
PRO,0,移栽升降轴_P12速度,Updown_P12_Speed,300000,,,,,,,,,,,,
PRO,0,移栽升降轴_P13速度,Updown_P13_Speed,150000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,料斗拉取升降轴_P1速度,PullAxis_Updown_P1_Speed,200000,,,,,,,,,,,,
......@@ -87,9 +87,9 @@ PRO,0,料斗拉取升降轴_P2速度,PullAxis_Updown_P2_Speed,400000,,,,,,,,,,,,
PRO,0,料斗拉取升降轴_P3速度,PullAxis_Updown_P3_Speed,400000,,,,,,,,,,,,
PRO,0,料斗拉取升降轴_P4速度,PullAxis_Updown_P4_Speed,400000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,A面移栽X轴_P1速度,XAxis_A_P1_Speed,100000,,,,,,,,,,,,
PRO,0,A面移栽X轴_P2速度,XAxis_A_P2_Speed,100000,,,,,,,,,,,,
PRO,0,A面移栽X轴_P3速度,XAxis_A_P3_Speed,100000,,,,,,,,,,,,
PRO,0,A面移栽X轴_P1速度,XAxis_A_P1_Speed,400000,,,,,,,,,,,,
PRO,0,A面移栽X轴_P2速度,XAxis_A_P2_Speed,400000,,,,,,,,,,,,
PRO,0,A面移栽X轴_P3速度,XAxis_A_P3_Speed,400000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,A面移栽旋转轴_P1速度,MiddleAxis_A_P1_Speed,20000,,,,,,,,,,,,
PRO,0,A面移栽旋转轴_P2速度,MiddleAxis_A_P2_Speed,60000,,,,,,,,,,,,
......@@ -99,17 +99,17 @@ PRO,0,A面移栽压紧轴_P1速度,ComAxis_A_P1_Speed,20000,,,,,,,,,,,,
PRO,0,A面移栽压紧轴_P2速度,ComAxis_A_P2_Speed,20000,,,,,,,,,,,,
PRO,0,A面移栽压紧轴_P3速度,ComAxis_A_P3_Speed,20000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,B面移栽X轴_P1速度,XAxis_B_P1_Speed,400000,,,,,,,,,,,,
PRO,0,B面移栽X轴_P2速度,XAxis_B_P2_Speed,400000,,,,,,,,,,,,
PRO,0,B面移栽X轴_P3速度,XAxis_B_P3_Speed,400000,,,,,,,,,,,,
PRO,0,B面移栽X轴_P1速度,XAxis_B_P1_Speed,800000,,,,,,,,,,,,
PRO,0,B面移栽X轴_P2速度,XAxis_B_P2_Speed,800000,,,,,,,,,,,,
PRO,0,B面移栽X轴_P3速度,XAxis_B_P3_Speed,800000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,B面移栽旋转轴_P1速度,MiddleAxis_B_P1_Speed,80000,,,,,,,,,,,,
PRO,0,B面移栽旋转轴_P2速度,MiddleAxis_B_P2_Speed,80000,,,,,,,,,,,,
PRO,0,B面移栽旋转轴_P3速度,MiddleAxis_B_P3_Speed,80000,,,,,,,,,,,,
PRO,0,B面移栽旋转轴_P1速度,MiddleAxis_B_P1_Speed,120000,,,,,,,,,,,,
PRO,0,B面移栽旋转轴_P2速度,MiddleAxis_B_P2_Speed,120000,,,,,,,,,,,,
PRO,0,B面移栽旋转轴_P3速度,MiddleAxis_B_P3_Speed,120000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,B面移栽压紧轴_P1速度,ComAxis_B_P1_Speed,40000,,,,,,,,,,,,
PRO,0,B面移栽压紧轴_P2速度,ComAxis_B_P2_Speed,40000,,,,,,,,,,,,
PRO,0,B面移栽压紧轴_P3速度,ComAxis_B_P3_Speed,40000,,,,,,,,,,,,
PRO,0,B面移栽压紧轴_P1速度,ComAxis_B_P1_Speed,60000,,,,,,,,,,,,
PRO,0,B面移栽压紧轴_P2速度,ComAxis_B_P2_Speed,60000,,,,,,,,,,,,
PRO,0,B面移栽压紧轴_P3速度,ComAxis_B_P3_Speed,60000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,A面料屉拉取进出轴_拍照点,PullAxis_Inout_CamA,10000,,,,,,,,,,,,
PRO,0,B面料屉拉取进出轴_拍照点,PullAxis_Inout_CamB,10000,,,,,,,,,,,,
......
......@@ -2,7 +2,7 @@
AXIS,0,A料口提升轴,BatchAxis_A,10,HC,,30000,80000,80000,2000,10000,30000,10,100,0,0
AXIS,0,B料口提升轴,BatchAxis_B,11,HC,,30000,80000,80000,2000,10000,30000,10,100,0,0
AXIS,0,取料升降轴,TakeAxis_Updown,12,HC,,30000,80000,80000,800,10000,30000,10,200,0,0
AXIS,0,取料旋转轴,TakeAxis_Middle,13,HC,,10000,30000,30000,2000,8000,20000,10,200,0,0
AXIS,0,取料旋转轴,TakeAxis_Middle,13,HC,,20000,80000,80000,2000,8000,20000,10,200,0,0
,,,,,,,,,,,,,,,,
PRO,0,设备是否处于调试状态(1=调试,0=正常),IsDebug,0,,,,,,,,,,,,
PRO,0,是否使用夹爪(1=使用夹爪,0=用吸盘),UseClampJaw,1,,,,,,,,,,,,
......@@ -28,7 +28,7 @@ PRO,0,提升上料轴P3速度/料盘拿走后提升轴下降速度,BatchAxis_P3S
PRO,0,提升上料轴高度转换系数(1mm对应的脉冲),Height_ChangeValue,1250,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,取料升降轴_待机点,Updown_P1,310000,,,,,,,,,,,,
PRO,0,取料升降轴_A料口取料点,Updown_P2_ATake,395000,,,,,,,,,,,,
PRO,0,取料升降轴_A料口取料点,Updown_P2_ATake,394000,,,,,,,,,,,,
PRO,0,取料升降轴_B料口取料点,Updown_P3_BTake,386317,,,,,,,,,,,,
PRO,0,取料升降轴_A上暂存区放料高点,Updown_P4_AUpperH,18000,,,,,,,,,,,,
PRO,0,取料升降轴_A上暂存区放料低点,Updown_P5_AUpperL,65798,,,,,,,,,,,,
......@@ -38,8 +38,8 @@ PRO,0,取料升降轴_NG料区放料高点,Updown_P8_NGH,310000,,,,,,,,,,,,
PRO,0,取料升降轴_NG料区放料低点,Updown_P9_NGL,310000,,,,,,,,,,,,
PRO,0,取料升降轴_B上暂存区放料高点,Updown_P10_BUpperH,18000,,,,,,,,,,,,
PRO,0,取料升降轴_B上暂存区放料低点,Updown_P11_BUpperL,65798,,,,,,,,,,,,
PRO,0,取料升降轴_B下暂存区取料高点,Updown_P12_BUnderH,368000,,,,,,,,,,,,
PRO,0,取料升降轴_B下暂存区取料低点,Updown_P13_BUnderL,112,,,,,,,,,,,,
PRO,0,取料升降轴_B下暂存区取料高点,Updown_P12_BUnderH,310000,,,,,,,,,,,,
PRO,0,取料升降轴_B下暂存区取料低点,Updown_P13_BUnderL,370000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,取料升降轴_P1速度,Updown_P1_Speed,30000,,,,,,,,,,,,
PRO,1,取料升降轴_P2速度,Updown_P2_Speed,30000,,,,,,,,,,,,
......@@ -56,18 +56,18 @@ PRO,11,取料升降轴_P12速度,Updown_P12_Speed,30000,,,,,,,,,,,,
PRO,12,取料升降轴_P13速度,Updown_P13_Speed,30000,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,取料旋转轴_待机点,Middle_P1,126912,,,,,,,,,,,,
PRO,0,取料旋转轴_A料口取料点,Middle_P2_ATake,161570,,,,,,,,,,,,
PRO,0,取料旋转轴_A料口取料点,Middle_P2_ATake,161988,,,,,,,,,,,,
PRO,0,取料旋转轴_B料口取料点,Middle_P3_BTake,93462,,,,,,,,,,,,
PRO,0,取料旋转轴_A上暂存区放料点,Middle_P4_AUpper,250000,,,,,,,,,,,,
PRO,0,取料旋转轴_B上暂存区放料点,Middle_P5_BUpper,104,,,,,,,,,,,,
PRO,0,取料旋转轴_B上暂存区放料点,Middle_P5_BUpper,107,,,,,,,,,,,,
PRO,0,取料旋转轴_NG料区放料点,Middle_P6_NG,214355,,,,,,,,,,,,
PRO,0,取料旋转轴_A下暂存区取料点,Middle_P7_AUnder,250000,,,,,,,,,,,,
PRO,0,取料旋转轴_A下暂存区取料点,Middle_P7_AUnder,250100,,,,,,,,,,,,
PRO,0,取料旋转轴_B下暂存区取料点,Middle_P8_BUnder,107,,,,,,,,,,,,
PRO,0,取料旋转轴_P1速度,Middle_P1_Speed,20000,,,,,,,,,,,,
PRO,1,取料旋转轴_P2速度,Middle_P2_Speed,20000,,,,,,,,,,,,
PRO,2,取料旋转轴_P3速度,Middle_P3_Speed,20000,,,,,,,,,,,,
PRO,3,取料旋转轴_P4速度,Middle_P4_Speed,20000,,,,,,,,,,,,
PRO,4,取料旋转轴_P5速度,Middle_P5_Speed,20000,,,,,,,,,,,,
PRO,5,取料旋转轴_P6速度,Middle_P6_Speed,20000,,,,,,,,,,,,
PRO,6,取料旋转轴_P7速度,Middle_P7_Speed,20000,,,,,,,,,,,,
PRO,7,取料旋转轴_P8速度,Middle_P8_Speed,20000,,,,,,,,,,,,
PRO,0,取料旋转轴_P1速度,Middle_P1_Speed,80000,,,,,,,,,,,,
PRO,1,取料旋转轴_P2速度,Middle_P2_Speed,80000,,,,,,,,,,,,
PRO,2,取料旋转轴_P3速度,Middle_P3_Speed,80000,,,,,,,,,,,,
PRO,3,取料旋转轴_P4速度,Middle_P4_Speed,80000,,,,,,,,,,,,
PRO,4,取料旋转轴_P5速度,Middle_P5_Speed,80000,,,,,,,,,,,,
PRO,5,取料旋转轴_P6速度,Middle_P6_Speed,80000,,,,,,,,,,,,
PRO,6,取料旋转轴_P7速度,Middle_P7_Speed,80000,,,,,,,,,,,,
PRO,7,取料旋转轴_P8速度,Middle_P8_Speed,80000,,,,,,,,,,,,
此文件的差异太大,无法显示。
......@@ -18,6 +18,7 @@ namespace OnlineStore.DeviceLibrary
public static int OutMoveId = 7;
public static bool TrayToOutLineTest = false;
public static bool UseSecurityAccess = ConfigAppSettings.GetIntValue(Setting_Init.UseSecurityAccess).Equals(1);
public static bool DisGetWare = false;
public static bool UseBuzzer = ConfigAppSettings.GetIntValue(Setting_Init.UseBuzzer).Equals(1);
......
......@@ -43,8 +43,8 @@ namespace OnlineStore.DeviceLibrary
MiddleAxis = new AxisBean(config.TakeAxis_Middle, Name, false);
UpdownAxis = new AxisBean(config.TakeAxis_Updown, Name, false);
BatchAxis_A = new AxisBean(config.BatchAxis_A, Name,true);
BatchAxis_B = new AxisBean(config.BatchAxis_B, Name,true);
BatchAxis_A = new AxisBean(config.BatchAxis_A, Name, true);
BatchAxis_B = new AxisBean(config.BatchAxis_B, Name, true);
moveAxisArray = new AxisBean[] { MiddleAxis, UpdownAxis };
if (config.UseClampJaw.Equals(1))
{
......@@ -84,7 +84,7 @@ namespace OnlineStore.DeviceLibrary
LogInfo("StartRun : 开始启动 ");
runStatus = RunStatus.HomeMoving;
MoveInfo.NewMove(MoveType.RHome,new InOutParam());
MoveInfo.NewMove(MoveType.RHome, new InOutParam());
if (!BatchMove_A.Reset())
{
......@@ -121,7 +121,7 @@ namespace OnlineStore.DeviceLibrary
}
LogInfo("Reset 开始重置 ");
runStatus = RunStatus.Reset;
MoveInfo.NewMove(MoveType.Reset,new InOutParam());
MoveInfo.NewMove(MoveType.Reset, new InOutParam());
if (!BatchMove_A.Reset())
{
SetWarnMsg("复位失败:A料口复位失败");
......@@ -185,14 +185,14 @@ namespace OnlineStore.DeviceLibrary
if (MiddleAxis.IsInPosition(Config.Middle_P4_AUpper, middleWucha) || MiddleAxis.IsInPosition(Config.Middle_P7_AUnder, middleWucha))
{
//如果升降轴低于下方高点
if(updownP> Config.Updown_P6_AUnderH- updownWucha)
if (updownP > Config.Updown_P6_AUnderH - updownWucha)
{
MoveInfo.NextMoveStep(StepEnum.IR02_UpdownUpMove);
LogInfo($"复位 {MoveInfo.SLog}:当前旋转轴在 A侧暂存区{middleP},升降轴当前位置{updownP},低于下方高点,升降轴先到P6:{Config.Updown_P6_AUnderH}");
UpdownAxis.AbsMove(MoveInfo, Config.Updown_P6_AUnderH, Config.Updown_P6_Speed);
}
//升降轴高于上方低点
else if(updownP<Config.Updown_P5_AUpperL+ updownWucha)
else if (updownP < Config.Updown_P5_AUpperL + updownWucha)
{
MoveInfo.NextMoveStep(StepEnum.IR02_UpdownUpMove);
LogInfo($"复位 {MoveInfo.SLog}:当前旋转轴在 A侧暂存区{middleP},升降轴当前位置{updownP},高于上方低点,升降轴到上方高点P4:{Config.Updown_P4_AUpperH}");
......@@ -214,7 +214,7 @@ namespace OnlineStore.DeviceLibrary
UpdownAxis.AbsMove(MoveInfo, Config.Updown_P12_BUnderH, Config.Updown_P12_BUnderH);
}
//升降轴高于上方低点
else if (updownP<Config.Updown_P11_BUpperL+ updownWucha)
else if (updownP < Config.Updown_P11_BUpperL + updownWucha)
{
MoveInfo.NextMoveStep(StepEnum.IR02_UpdownUpMove);
LogInfo($"复位 {MoveInfo.SLog}:当前旋转轴在 B侧暂存区{middleP},升降轴当前位置{updownP},高于上方低点,升降轴到上方高点P10:{Config.Updown_P10_BUpperH}");
......@@ -366,6 +366,7 @@ namespace OnlineStore.DeviceLibrary
{
return;
}
SecurityAccessProcess();
BusyMoveProcess();
IOTimeOutProcess();
//判断流水线打开了才可以运行
......@@ -377,7 +378,7 @@ namespace OnlineStore.DeviceLibrary
{
if (moveBean.MoveInfo.MoveType.Equals(MoveType.InStore) && moveBean.MoveInfo.IsStep(StepEnum.IB10_ScanOK))
{
LogInfo(moveBean.Name + "开始取料:"+moveBean.GetInstoreParam().PosInfo.ToStr());
LogInfo(moveBean.Name + "开始取料:" + moveBean.GetInstoreParam().PosInfo.ToStr());
StartInstore(moveBean.GetInstoreParam());
break;
}
......@@ -385,11 +386,11 @@ namespace OnlineStore.DeviceLibrary
}
if (MoveInfo.MoveType.Equals(MoveType.None) && NoErrorAlarm())
{
if (CheckStartOutPos("A下暂存区", BufferDataManager.AOutStoreInfo, BatchMoveList))
if (CheckStartOutPos("A下暂存区", BufferDataManager.AOutStoreInfo, IO_Type.UnderArea_Check_A, BatchMoveList))
{
}
else if (CheckStartOutPos("B下暂存区", BufferDataManager.BOutStoreInfo, BatchMoveList))
else if (CheckStartOutPos("B下暂存区", BufferDataManager.BOutStoreInfo,IO_Type.UnderArea_Check_B, BatchMoveList))
{
}
......@@ -398,11 +399,11 @@ namespace OnlineStore.DeviceLibrary
//如果有物料且不能放料,需要送一个料串离开
if (BufferDataManager.AOutStoreInfo != null)
{
CheckStartOutPos("A下暂存区", BufferDataManager.AOutStoreInfo, BatchMoveList, true);
CheckStartOutPos("A下暂存区", BufferDataManager.AOutStoreInfo, IO_Type.UnderArea_Check_A,BatchMoveList, true);
}
else if (BufferDataManager.BOutStoreInfo != null)
{
CheckStartOutPos("B下暂存区", BufferDataManager.BOutStoreInfo, BatchMoveList, true);
CheckStartOutPos("B下暂存区", BufferDataManager.BOutStoreInfo, IO_Type.UnderArea_Check_B, BatchMoveList, true);
}
}
......@@ -418,9 +419,9 @@ namespace OnlineStore.DeviceLibrary
CheckAxisAlarm();
}
}
private bool CheckStartOutPos(string posType, InOutPosInfo posInfo, List<BatchMoveBean> BatchMoveList, bool shelfAutoLeave = false)
private bool CheckStartOutPos(string posType, InOutPosInfo posInfo,String ioType, List<BatchMoveBean> BatchMoveList, bool shelfAutoLeave = false)
{
if (posInfo != null)
if (posInfo != null && IOValue(ioType).Equals(IO_VALUE.HIGH))
{
foreach (BatchMoveBean moveBean in BatchMoveList)
{
......@@ -594,7 +595,7 @@ namespace OnlineStore.DeviceLibrary
//在A下暂存区
if (areaNum == 2)
{
return true ;
return true;
}
}
//升降轴高于上方低点
......@@ -652,14 +653,14 @@ namespace OnlineStore.DeviceLibrary
int middleP = MiddleAxis.GetAclPosition();
int middleWucha = 20000;
//旋转轴在A暂存区
if (MiddleAxis.IsInPosition(Config.Middle_P2_ATake, middleWucha) )
if (MiddleAxis.IsInPosition(Config.Middle_P2_ATake, middleWucha))
{
if (shelfType.Equals(1))
{
return true;
}
}
else if (MiddleAxis.IsInPosition(Config.Middle_P3_BTake, middleWucha) )
else if (MiddleAxis.IsInPosition(Config.Middle_P3_BTake, middleWucha))
{
if (shelfType.Equals(2))
{
......@@ -668,6 +669,84 @@ namespace OnlineStore.DeviceLibrary
}
return false;
}
//光栅状态:0正常。1=安全门禁打开,已停止运动
private int CurrSecurityAccess = 0;
protected void SecurityAccessProcess()
{
try
{
if (!baseConfig.DIList.ContainsKey(IO_Type.SafetyRasterSignal))
{
return;
}
if (CurrSecurityAccess.Equals(0) && StoreManager.UseSecurityAccess)
{
if (BatchMove_A.ProcessShelfEnter || BatchMove_A.ProcessShelfOut)
{
return;
}
if (BatchMove_B.ProcessShelfEnter || BatchMove_B.ProcessShelfOut)
{
return;
}
if (IOValue(IO_Type.SafetyRasterSignal).Equals(IO_VALUE.LOW))
{
SecurityAccessStop();
}
}
else if (CurrSecurityAccess.Equals(1))
{
if (IOValue(IO_Type.SafetyRasterSignal).Equals(IO_VALUE.HIGH))
{
SecurityAccessReset();
}
}
}
catch (Exception ex)
{
LogUtil.error(Name + " 出错 :" + ex.ToString());
}
}
private void SecurityAccessStop()
{
if (!baseConfig.DIList.ContainsKey(IO_Type.SafetyRasterSignal))
{
return;
}
CurrSecurityAccess = 1;
if (alarmType > (AlarmType.IoSingleTimeOut))
{
return;
}
ConfigIO di = baseConfig.DIList[IO_Type.SafetyRasterSignal];
LogUtil.info($"{Name }光栅被遮挡,停止当前运动{MoveInfo.MoveType},MoveStop={MoveStop},报警急停");
SetWarnMsg("光栅被遮挡,报警急停");
Alarm(AlarmType.SuddenStop);
}
private void SecurityAccessReset()
{
if (!baseConfig.DIList.ContainsKey(IO_Type.SafetyRasterSignal))
{
return;
}
CurrSecurityAccess = 0;
MoveStop = false;
ConfigIO di = baseConfig.DIList[IO_Type.SafetyRasterSignal];
if (alarmType > (AlarmType.IoSingleTimeOut))
{
return;
}
//光栅恢复处理
}
}
}
......@@ -56,6 +56,7 @@ namespace OnlineStore.DeviceLibrary
}
#region 入库
private DateTime startInTime = DateTime.Now;
public override bool StartInstore(InOutParam param)
{
if (!NoAlarm())
......@@ -68,6 +69,7 @@ namespace OnlineStore.DeviceLibrary
{
runStatus = RunStatus.Busy;
MoveInfo.NewMove(MoveType.InStore, param);
startInTime = DateTime.Now;
//if (MiddleAxis.IsInPosition(Config.Middle_P1))
//{
if (UpdownAxis.IsInPosition(Config.Updown_P1))
......@@ -315,7 +317,8 @@ namespace OnlineStore.DeviceLibrary
else if (MoveInfo.IsStep(StepEnum.II47_MiddleToP1))
{
ClearTimeoutAlarm("扫码结束");
MoveLog($" 入料->A侧放料结束,更新A上暂存区物料{MoveInfo.MoveParam.PosInfo.ToStr()}");
TimeSpan span = DateTime.Now - startInTime;
MoveLog($" 入料->A侧放料结束,更新A上暂存区物料{MoveInfo.MoveParam.PosInfo.ToStr()},耗时【{FormUtil.GetSpanStr(span)}】");
BufferDataManager.AInStoreInfo = MoveInfo.MoveParam.PosInfo;
MoveInfo.EndMove();
runStatus = RunStatus.Runing;
......@@ -401,7 +404,8 @@ namespace OnlineStore.DeviceLibrary
else if (MoveInfo.IsStep(StepEnum.II67_MiddleToP1))
{
ClearTimeoutAlarm("扫码结束");
MoveLog($" 入料->B侧放料结束,更新B上暂存区物料{MoveInfo.MoveParam.PosInfo.ToStr()}");
TimeSpan span = DateTime.Now - startInTime;
MoveLog($" 入料->B侧放料结束,更新B上暂存区物料{MoveInfo.MoveParam.PosInfo.ToStr()},耗时【{FormUtil.GetSpanStr(span)}】");
BufferDataManager.BInStoreInfo = MoveInfo.MoveParam.PosInfo;
MoveInfo.EndMove();
runStatus = RunStatus.Runing;
......@@ -452,7 +456,8 @@ namespace OnlineStore.DeviceLibrary
}
else if (MoveInfo.IsStep(StepEnum.II86_MiddleToP1))
{
MoveLog($" 入料->NG箱放料结束");
TimeSpan span = DateTime.Now - startInTime;
MoveLog($" 入料->NG箱放料结束,耗时【{FormUtil.GetSpanStr(span)}】");
MoveInfo.EndMove();
runStatus = RunStatus.Runing;
}
......@@ -655,6 +660,7 @@ namespace OnlineStore.DeviceLibrary
#endregion
#region 出库
private DateTime startOutTime = DateTime.Now;
public override bool StartOutstore(InOutParam param)
{
if (!NoAlarm())
......@@ -671,6 +677,7 @@ namespace OnlineStore.DeviceLibrary
{
runStatus = RunStatus.Busy;
MoveInfo.NewMove(MoveType.OutStore, param);
startOutTime = DateTime.Now;
MoveInfo.NextMoveStep(StepEnum.IO01_ReelCheck);
if (!MiddleAxis.IsInPosition(Config.Middle_P1))
{
......@@ -688,6 +695,7 @@ namespace OnlineStore.DeviceLibrary
{
runStatus = RunStatus.Busy;
MoveInfo.NewMove(MoveType.OutStore, param);
startOutTime = DateTime.Now;
MoveInfo.NextMoveStep(StepEnum.IO11_ReelCheck);
if (!MiddleAxis.IsInPosition(Config.Middle_P1))
{
......@@ -900,7 +908,8 @@ namespace OnlineStore.DeviceLibrary
{
MoveInfo.EndMove();
runStatus = RunStatus.Runing;
MoveLog($"出库->料串 {MoveInfo.SLog}: 放料完成");
TimeSpan span = DateTime.Now - startOutTime;
MoveLog($"出库->料串 {MoveInfo.SLog}: 放料完成,耗时【{FormUtil.GetSpanStr(span)}】");
}
#endregion
......
......@@ -83,6 +83,7 @@
this.toolStripSeparator25 = new System.Windows.Forms.ToolStripSeparator();
this.aGVCancelStateToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripSeparator17 = new System.Windows.Forms.ToolStripSeparator();
this.启用安全光栅ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.tabControl1.SuspendLayout();
this.tabPage1.SuspendLayout();
this.tabPage2.SuspendLayout();
......@@ -137,7 +138,7 @@
this.tabPage2.Controls.Add(this.panel1);
this.tabPage2.Location = new System.Drawing.Point(4, 29);
this.tabPage2.Name = "tabPage2";
this.tabPage2.Size = new System.Drawing.Size(988, 605);
this.tabPage2.Size = new System.Drawing.Size(192, 67);
this.tabPage2.TabIndex = 1;
this.tabPage2.Text = " 设备状态 ";
this.tabPage2.UseVisualStyleBackColor = true;
......@@ -148,7 +149,7 @@
this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(988, 605);
this.panel1.Size = new System.Drawing.Size(192, 67);
this.panel1.TabIndex = 1;
//
// tableLayoutPanel1
......@@ -173,7 +174,7 @@
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 14.28571F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 19.04762F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 19.04762F));
this.tableLayoutPanel1.Size = new System.Drawing.Size(988, 605);
this.tableLayoutPanel1.Size = new System.Drawing.Size(192, 67);
this.tableLayoutPanel1.TabIndex = 0;
//
// InputControl
......@@ -184,10 +185,10 @@
this.tableLayoutPanel1.SetColumnSpan(this.InputControl, 2);
this.InputControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.InputControl.EquipText = "上料机构";
this.InputControl.Location = new System.Drawing.Point(3, 376);
this.InputControl.Location = new System.Drawing.Point(3, 43);
this.InputControl.MoveInfo = "暂无出入库";
this.InputControl.Name = "InputControl";
this.InputControl.Size = new System.Drawing.Size(982, 109);
this.InputControl.Size = new System.Drawing.Size(186, 6);
this.InputControl.TabIndex = 5;
this.InputControl.WorkStatus = "暂未启动";
//
......@@ -197,10 +198,10 @@
this.ReelControlA1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.ReelControlA1.ColorStatus = System.Drawing.Color.White;
this.ReelControlA1.Dock = System.Windows.Forms.DockStyle.Fill;
this.ReelControlA1.Location = new System.Drawing.Point(3, 204);
this.ReelControlA1.Location = new System.Drawing.Point(3, 25);
this.ReelControlA1.Name = "ReelControlA1";
this.ReelControlA1.ReelText = "暂存区物料";
this.ReelControlA1.Size = new System.Drawing.Size(488, 80);
this.ReelControlA1.Size = new System.Drawing.Size(90, 3);
this.ReelControlA1.TabIndex = 0;
//
// ReelControlA2
......@@ -209,10 +210,10 @@
this.ReelControlA2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.ReelControlA2.ColorStatus = System.Drawing.Color.White;
this.ReelControlA2.Dock = System.Windows.Forms.DockStyle.Fill;
this.ReelControlA2.Location = new System.Drawing.Point(3, 290);
this.ReelControlA2.Location = new System.Drawing.Point(3, 34);
this.ReelControlA2.Name = "ReelControlA2";
this.ReelControlA2.ReelText = "暂存区物料";
this.ReelControlA2.Size = new System.Drawing.Size(488, 80);
this.ReelControlA2.Size = new System.Drawing.Size(90, 3);
this.ReelControlA2.TabIndex = 1;
//
// ReelControlB1
......@@ -221,10 +222,10 @@
this.ReelControlB1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.ReelControlB1.ColorStatus = System.Drawing.Color.White;
this.ReelControlB1.Dock = System.Windows.Forms.DockStyle.Fill;
this.ReelControlB1.Location = new System.Drawing.Point(497, 204);
this.ReelControlB1.Location = new System.Drawing.Point(99, 25);
this.ReelControlB1.Name = "ReelControlB1";
this.ReelControlB1.ReelText = "暂存区物料";
this.ReelControlB1.Size = new System.Drawing.Size(488, 80);
this.ReelControlB1.Size = new System.Drawing.Size(90, 3);
this.ReelControlB1.TabIndex = 2;
//
// ReelControlB2
......@@ -233,10 +234,10 @@
this.ReelControlB2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.ReelControlB2.ColorStatus = System.Drawing.Color.White;
this.ReelControlB2.Dock = System.Windows.Forms.DockStyle.Fill;
this.ReelControlB2.Location = new System.Drawing.Point(497, 290);
this.ReelControlB2.Location = new System.Drawing.Point(99, 34);
this.ReelControlB2.Name = "ReelControlB2";
this.ReelControlB2.ReelText = "暂存区物料";
this.ReelControlB2.Size = new System.Drawing.Size(488, 80);
this.ReelControlB2.Size = new System.Drawing.Size(90, 3);
this.ReelControlB2.TabIndex = 3;
//
// BoxControl
......@@ -250,7 +251,7 @@
this.BoxControl.Location = new System.Drawing.Point(3, 3);
this.BoxControl.MoveInfo = "暂无出入库";
this.BoxControl.Name = "BoxControl";
this.BoxControl.Size = new System.Drawing.Size(982, 195);
this.BoxControl.Size = new System.Drawing.Size(186, 16);
this.BoxControl.TabIndex = 4;
this.BoxControl.WorkStatus = "暂未启动";
//
......@@ -261,10 +262,10 @@
this.ShelfAControl.ColorStatus = System.Drawing.Color.White;
this.ShelfAControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.ShelfAControl.EquipText = "A料口";
this.ShelfAControl.Location = new System.Drawing.Point(3, 491);
this.ShelfAControl.Location = new System.Drawing.Point(3, 55);
this.ShelfAControl.MoveInfo = "暂无出入库";
this.ShelfAControl.Name = "ShelfAControl";
this.ShelfAControl.Size = new System.Drawing.Size(488, 111);
this.ShelfAControl.Size = new System.Drawing.Size(90, 9);
this.ShelfAControl.TabIndex = 6;
this.ShelfAControl.WorkStatus = "暂未启动";
//
......@@ -275,10 +276,10 @@
this.ShelfBControl.ColorStatus = System.Drawing.Color.White;
this.ShelfBControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.ShelfBControl.EquipText = "B料口";
this.ShelfBControl.Location = new System.Drawing.Point(497, 491);
this.ShelfBControl.Location = new System.Drawing.Point(99, 55);
this.ShelfBControl.MoveInfo = "暂无出入库";
this.ShelfBControl.Name = "ShelfBControl";
this.ShelfBControl.Size = new System.Drawing.Size(488, 111);
this.ShelfBControl.Size = new System.Drawing.Size(90, 9);
this.ShelfBControl.TabIndex = 7;
this.ShelfBControl.WorkStatus = "暂未启动";
//
......@@ -533,7 +534,8 @@
this.启用蜂鸣器ToolStripMenuItem,
this.toolStripSeparator25,
this.aGVCancelStateToolStripMenuItem,
this.toolStripSeparator17});
this.toolStripSeparator17,
this.启用安全光栅ToolStripMenuItem});
this.运行参数ToolStripMenuItem.Name = "运行参数ToolStripMenuItem";
this.运行参数ToolStripMenuItem.Size = new System.Drawing.Size(86, 25);
this.运行参数ToolStripMenuItem.Text = "运行参数";
......@@ -576,6 +578,13 @@
this.toolStripSeparator17.Size = new System.Drawing.Size(203, 6);
this.toolStripSeparator17.Visible = false;
//
// 启用安全光栅ToolStripMenuItem
//
this.启用安全光栅ToolStripMenuItem.Name = "启用安全光栅ToolStripMenuItem";
this.启用安全光栅ToolStripMenuItem.Size = new System.Drawing.Size(206, 26);
this.启用安全光栅ToolStripMenuItem.Text = "启用安全光栅";
this.启用安全光栅ToolStripMenuItem.Click += new System.EventHandler(this.启用安全光栅ToolStripMenuItem_Click);
//
// FrmXLRStore
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
......@@ -664,6 +673,7 @@
private EquipControl BoxControl;
private EquipControl ShelfAControl;
private EquipControl ShelfBControl;
private System.Windows.Forms.ToolStripMenuItem 启用安全光栅ToolStripMenuItem;
}
}
......@@ -53,6 +53,14 @@ namespace OnlineStore.XLRStore
this.notifyIcon1.Visible = false;
this.ShowInTaskbar = true;
this.Cursor = Cursors.Default;
if (StoreManager.UseSecurityAccess)
{
启用安全光栅ToolStripMenuItem.Text = gouStr + "启用安全光栅";
}
else
{
启用安全光栅ToolStripMenuItem.Text = "启用安全光栅";
}
//tabControl1.TabPages.Remove(tabPage5);
timer1.Start();
}
......@@ -695,5 +703,30 @@ namespace OnlineStore.XLRStore
inputEquip.FrmInputEquip_VisibleChanged(null, null);
}
}
private void 启用安全光栅ToolStripMenuItem_Click(object sender, EventArgs e)
{
if (!LoadOk)
{
return;
}
bool result = !启用安全光栅ToolStripMenuItem.Text.Contains(gouStr);
if (result.Equals(StoreManager.UseSecurityAccess))
{
return;
}
StoreManager.UseSecurityAccess = result;
ConfigAppSettings.SaveValue(Setting_Init.UseSecurityAccess, (StoreManager.UseSecurityAccess ? 1 : 0));
if (result)
{
启用安全光栅ToolStripMenuItem.Text = gouStr + " 启用安全光栅";
}
else
{
启用安全光栅ToolStripMenuItem.Text = "启用安全光栅";
}
LogUtil.info(Name + " 点击:" + 启用安全光栅ToolStripMenuItem.Text);
}
}
}
......@@ -705,6 +705,7 @@ namespace OnlineStore.XLRStore
{
positions = (from m in StoreManager.XLRStore.boxEquip.PositionNumList where m.Contains("BB") select m).ToList<string>();
}
cmb.DataSource = null;
cmb.Items.Clear();
cmb.DataSource = positions;
if (positions.Count > 0)
......
......@@ -97,13 +97,12 @@
//
this.lblMoveInfo.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.lblMoveInfo.AutoSize = true;
this.lblMoveInfo.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblMoveInfo.ForeColor = System.Drawing.Color.Black;
this.lblMoveInfo.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft;
this.lblMoveInfo.Location = new System.Drawing.Point(3, 53);
this.lblMoveInfo.Location = new System.Drawing.Point(3, 51);
this.lblMoveInfo.Name = "lblMoveInfo";
this.lblMoveInfo.Size = new System.Drawing.Size(68, 17);
this.lblMoveInfo.Size = new System.Drawing.Size(245, 35);
this.lblMoveInfo.TabIndex = 3;
this.lblMoveInfo.Text = "暂无出入库";
this.lblMoveInfo.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
......@@ -150,9 +149,9 @@
this.lblWarn.Font = new System.Drawing.Font("微软雅黑", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.lblWarn.ForeColor = System.Drawing.Color.White;
this.lblWarn.ImageAlign = System.Drawing.ContentAlignment.TopLeft;
this.lblWarn.Location = new System.Drawing.Point(3, 77);
this.lblWarn.Location = new System.Drawing.Point(3, 90);
this.lblWarn.Name = "lblWarn";
this.lblWarn.Size = new System.Drawing.Size(242, 42);
this.lblWarn.Size = new System.Drawing.Size(242, 28);
this.lblWarn.TabIndex = 8;
this.lblWarn.Text = "暂无报警";
this.lblWarn.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!