Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
李娜
/
SO908-XLRStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 67d37572
由
LN
编写于
2021-09-10 09:47:50 +0800
浏览文件
选项
浏览文件
标签
下载
差异文件
Merge branch 'master' of
http://106.15.194.121:8083/lina/SO908-XLRStore
2 个父辈
9008624d
67573a11
显示空白字符变更
内嵌
并排
正在显示
20 个修改的文件
包含
1460 行增加
和
166 行删除
source/DeviceLibrary/Config/Config_BoxEquip.csv
source/DeviceLibrary/manager/model/DeviceStep.cs
source/DeviceLibrary/storeBean/boxBean/BoxEqiup_Tongs.cs
source/DeviceLibrary/storeBean/boxBean/BoxEquip.cs
source/DeviceLibrary/storeBean/boxBean/BoxEquip_InExecute.cs
source/DeviceLibrary/storeBean/boxBean/BoxEquip_OutExecute.cs
source/DeviceLibrary/storeBean/boxBean/BoxEquip_Partial.cs
source/DeviceLibrary/storeBean/boxBean/BoxEquip_PosDebug.cs
source/DeviceLibrary/storeBean/boxBean/positionDebug/PositionDebugManager.cs
source/LoadCVSLibrary/storeConfig/config/BoxEquip_Config.cs
source/XLRStoreClient/XLRStore.csproj
source/XLRStoreClient/boxForm/FrmBoxEquip.cs
source/XLRStoreClient/boxForm/FrmPosDebug.Designer.cs
source/XLRStoreClient/boxForm/FrmPosDebug.cs
source/XLRStoreClient/boxForm/FrmPosDebug.resx
source/XLRStoreClient/boxForm/FrmPosResult.Designer.cs
source/XLRStoreClient/boxForm/FrmPosResult.cs
source/XLRStoreClient/boxForm/FrmPosResult.resx
source/XLRStoreClient/boxForm/userControl/UCStatusPanel.Designer.cs
source/XLRStoreClient/boxForm/userControl/UCStatusPanel.cs
source/DeviceLibrary/Config/Config_BoxEquip.csv
查看文件 @
67d3757
...
@@ -22,6 +22,10 @@ PRO,0,B面抽屉对位Mark_X坐标,FindPos_Drawer_B_X,991.98,,,,,,,,,,,,
...
@@ -22,6 +22,10 @@ PRO,0,B面抽屉对位Mark_X坐标,FindPos_Drawer_B_X,991.98,,,,,,,,,,,,
PRO,0,B面抽屉对位Mark_Y坐标,FindPos_Drawer_B_Y,902.12,,,,,,,,,,,,
PRO,0,B面抽屉对位Mark_Y坐标,FindPos_Drawer_B_Y,902.12,,,,,,,,,,,,
PRO,0,B面抽屉验证Mark_X坐标,Validate_Drawer_B_X,1003.86,,,,,,,,,,,,
PRO,0,B面抽屉验证Mark_X坐标,Validate_Drawer_B_X,1003.86,,,,,,,,,,,,
PRO,0,B面抽屉验证Mark_Y坐标,Validate_Drawer_B_Y,980.23,,,,,,,,,,,,
PRO,0,B面抽屉验证Mark_Y坐标,Validate_Drawer_B_Y,980.23,,,,,,,,,,,,
PRO,0,A面抽屉对位Mark面积,FindPos_Drawer_A_Area,897.49,,,,,,,,,,,,
PRO,0,A面抽屉验证Mark面积,Validate_Drawer_A_Area,897.49,,,,,,,,,,,,
PRO,0,B面抽屉对位Mark面积,FindPos_Drawer_B_Area,897.49,,,,,,,,,,,,
PRO,0,B面抽屉验证Mark面积,Validate_Drawer_B_Area,897.49,,,,,,,,,,,,
PRO,0,B面X方向像素到脉冲的系数,PixelToPulse_B_X,100,,,,,,,,,,,,
PRO,0,B面X方向像素到脉冲的系数,PixelToPulse_B_X,100,,,,,,,,,,,,
PRO,0,B面Y方向像素到脉冲的系数,PixelToPulse_B_Y,100,,,,,,,,,,,,
PRO,0,B面Y方向像素到脉冲的系数,PixelToPulse_B_Y,100,,,,,,,,,,,,
PRO,0,视觉对位Mark_X方向误差范围,FindPos_Drawer_X_Error,2,,,,,,,,,,,,
PRO,0,视觉对位Mark_X方向误差范围,FindPos_Drawer_X_Error,2,,,,,,,,,,,,
...
@@ -35,9 +39,13 @@ PRO,0,抽屉列数,Drawer_Columns,6,,,,,,,,,,,,
...
@@ -35,9 +39,13 @@ PRO,0,抽屉列数,Drawer_Columns,6,,,,,,,,,,,,
PRO,0,抽屉内行数,Rows_In_Drawer,4,,,,,,,,,,,,
PRO,0,抽屉内行数,Rows_In_Drawer,4,,,,,,,,,,,,
PRO,0,抽屉内列数,Cols_In_Drawer,20,,,,,,,,,,,,
PRO,0,抽屉内列数,Cols_In_Drawer,20,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,行走机构视觉对位速度,MoveAxis_FindPosSpeed,20,,,,,,,,,,,,
PRO,0,行走机构调试速度,MoveAxis_FindPosSpeed,20,,,,,,,,,,,,
PRO,0,升降轴视觉对位速度,UpdownAxis_FindPosSpeed,20,,,,,,,,,,,,
PRO,0,升降轴调试速度,UpdownAxis_FindPosSpeed,20,,,,,,,,,,,,
PRO,0,拉取升降轴视觉对位速度,PullAxis_Updown_FindPosSpeed,20,,,,,,,,,,,,
PRO,0,拉取升降轴调试速度,PullAxis_Updown_FindPosSpeed,20,,,,,,,,,,,,
PRO,0,拉取进出轴调试速度,PullAxis_InOut_FindPosSpeed,20,,,,,,,,,,,,
PRO,0,移栽X轴调试速度,XAxis_FindPosSpeed,20,,,,,,,,,,,,
PRO,0,压紧轴调试速度,ComAxis_FindPosSpeed,20,,,,,,,,,,,,
,,,,,,,,,,,,,,,,
PRO,0,行走机构正极限位置,MoveAxis_PosLimit,20,,,,,,,,,,,,
PRO,0,行走机构正极限位置,MoveAxis_PosLimit,20,,,,,,,,,,,,
PRO,0,行走机构负极限位置,MoveAxis_NegLimit,20,,,,,,,,,,,,
PRO,0,行走机构负极限位置,MoveAxis_NegLimit,20,,,,,,,,,,,,
PRO,0,升降轴正极限位置,UpdownAxis_PosLimit,20,,,,,,,,,,,,
PRO,0,升降轴正极限位置,UpdownAxis_PosLimit,20,,,,,,,,,,,,
...
...
source/DeviceLibrary/manager/model/DeviceStep.cs
查看文件 @
67d3757
...
@@ -605,19 +605,19 @@ namespace OnlineStore.DeviceLibrary
...
@@ -605,19 +605,19 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 库位调试:料屉返回,提升抽屉,料斗拉取升降轴到P3(料屉提取高点)
/// 库位调试:料屉返回,提升抽屉,料斗拉取升降轴到P3(料屉提取高点)
/// </summary>
/// </summary>
SP_20_Lift
Tray
,
SP_20_Lift
Drawer
,
/// <summary>
/// <summary>
/// 库位调试:推到抽屉提取点,料斗拉取进出轴到P2(A/B面料屉提取点)
/// 库位调试:推到抽屉提取点,料斗拉取进出轴到P2(A/B面料屉提取点)
/// </summary>
/// </summary>
SP_21_Push
Tray
,
SP_21_Push
Drawer
,
/// <summary>
/// <summary>
/// 库位调试:料屉水平,料斗拉取升降轴到料屉提取水平点,同时检测X04-X09=1
/// 库位调试:料屉水平,料斗拉取升降轴到料屉提取水平点,同时检测X04-X09=1
/// </summary>
/// </summary>
SP_22_Put
Tray
Middle
,
SP_22_Put
Drawer
Middle
,
/// <summary>
/// <summary>
/// 库位调试:放下料屉,料斗拉取升降轴到P4(料屉提取低点)
/// 库位调试:放下料屉,料斗拉取升降轴到P4(料屉提取低点)
/// </summary>
/// </summary>
SP_23_Put
Tray
Down
,
SP_23_Put
Drawer
Down
,
/// <summary>
/// <summary>
/// 库位调试:料斗拉取进出轴到P1(待机点),检查是否结束
/// 库位调试:料斗拉取进出轴到P1(待机点),检查是否结束
/// </summary>
/// </summary>
...
@@ -626,6 +626,26 @@ namespace OnlineStore.DeviceLibrary
...
@@ -626,6 +626,26 @@ namespace OnlineStore.DeviceLibrary
/// 库位调试:到下一个库位,移栽X轴到位,进出轴到位
/// 库位调试:到下一个库位,移栽X轴到位,进出轴到位
/// </summary>
/// </summary>
SP_25_ToNextGrid
,
SP_25_ToNextGrid
,
/// <summary>
/// 库位调试:到下一个抽屉
/// </summary>
SP_25_ToNextDrawer
,
/// <summary>
/// 库位调试:到暂存区
/// </summary>
SP_26_ToBufferArea
,
/// <summary>
/// 库位调试:移栽X轴到暂存区
/// </summary>
SP_27_XAxisToBuffer
,
/// <summary>
/// 库位调试: 放下料盘
/// </summary>
SP_28_PutReel
,
/// <summary>
/// 库位调试:移栽X轴返回待机点
/// </summary>
SP_29_XAxisBack
,
#
endregion
#
endregion
#
region
入料模块复位
1000
开始
#
region
入料模块复位
1000
开始
...
...
source/DeviceLibrary/storeBean/boxBean/BoxEqiup_Tongs.cs
查看文件 @
67d3757
...
@@ -100,7 +100,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -100,7 +100,7 @@ namespace OnlineStore.DeviceLibrary
public
bool
MatchAndSaveImg
(
Bitmap
bitmap
,
string
imgname
)
public
bool
MatchAndSaveImg
(
Bitmap
bitmap
,
string
imgname
)
{
{
var
score
=
match
(
bitmap
,
out
string
pn
,
out
Bitmap
bitmap1
);
var
score
=
match
(
bitmap
,
out
string
pn
,
out
Bitmap
bitmap1
);
var
pnpath
=
Path
.
Combine
(
temp_path
,
score
>
Config
.
TongsDetectThreshold
?
"OK"
:
"NG"
);
var
pnpath
=
Path
.
Combine
(
$
"{temp_path}/{DateTime.Now.ToString("
yyyyMMdd
")}/"
,
score
>
Config
.
TongsDetectThreshold
?
"OK"
:
"NG"
);
Directory
.
CreateDirectory
(
pnpath
);
Directory
.
CreateDirectory
(
pnpath
);
var
simpletemp
=
Path
.
Combine
(
pnpath
,
$
"{imgname}-{score.ToString("
##
.
##
")}-{pn}.png"
);
var
simpletemp
=
Path
.
Combine
(
pnpath
,
$
"{imgname}-{score.ToString("
##
.
##
")}-{pn}.png"
);
bitmap
.
Save
(
simpletemp
,
ImageFormat
.
Png
);
bitmap
.
Save
(
simpletemp
,
ImageFormat
.
Png
);
...
...
source/DeviceLibrary/storeBean/boxBean/BoxEquip.cs
查看文件 @
67d3757
...
@@ -128,9 +128,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -128,9 +128,8 @@ namespace OnlineStore.DeviceLibrary
InitPosititionNumList
();
InitPosititionNumList
();
InitDrawInfos
();
InitDrawInfos
();
LoadCameraConfig
();
LoadCameraConfig
();
//库位测试
//库位调试
//InitPosDebugInfo();
InitPosDebugInfo
();
//Test();
}
}
void
InitRowColumnSig
()
void
InitRowColumnSig
()
...
@@ -374,8 +373,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -374,8 +373,8 @@ namespace OnlineStore.DeviceLibrary
LogInfo
(
$
"复位 {MoveInfo.SLog}:在进出轴待机点取像"
);
LogInfo
(
$
"复位 {MoveInfo.SLog}:在进出轴待机点取像"
);
Bitmap
resetBitMapA
=
AcqImage
(
"box_A"
);
Bitmap
resetBitMapA
=
AcqImage
(
"box_A"
);
Bitmap
resetBitMapB
=
AcqImage
(
"box_B"
);
Bitmap
resetBitMapB
=
AcqImage
(
"box_B"
);
resetRtnA
=
MatchAndSaveImg
(
resetBitMapA
,
$
"resetA_{DateTime.Now.ToString("
yyyyMMdd
HHmmss
")}"
);
resetRtnA
=
MatchAndSaveImg
(
resetBitMapA
,
$
"resetA_{DateTime.Now.ToString("
HHmmss
")}"
);
resetRtnB
=
MatchAndSaveImg
(
resetBitMapB
,
$
"resetB_{DateTime.Now.ToString("
yyyyMMdd
HHmmss
")}"
);
resetRtnB
=
MatchAndSaveImg
(
resetBitMapB
,
$
"resetB_{DateTime.Now.ToString("
HHmmss
")}"
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
3000
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
3000
));
break
;
break
;
case
StepEnum
.
BOX_H003_2_CheckDrawerIsInAxis
:
case
StepEnum
.
BOX_H003_2_CheckDrawerIsInAxis
:
...
...
source/DeviceLibrary/storeBean/boxBean/BoxEquip_InExecute.cs
查看文件 @
67d3757
...
@@ -267,7 +267,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -267,7 +267,7 @@ namespace OnlineStore.DeviceLibrary
{
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_09_ToTray
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_09_ToTray
);
LogInfo
(
$
"入库 {MoveInfo.SLog}:到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"入库 {MoveInfo.SLog}:到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
ToTray
();
PullAxis_Inout_To_P2_P4
();
CamDetectError
=
false
;
CamDetectError
=
false
;
IgnoreCamDect
=
false
;
IgnoreCamDect
=
false
;
}
}
...
@@ -292,7 +292,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -292,7 +292,6 @@ namespace OnlineStore.DeviceLibrary
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_13_GetReel
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_13_GetReel
);
LogInfo
(
$
"入库 {MoveInfo.SLog}:进入库位中,移栽升降轴到料屉取放点P7/P13[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"入库 {MoveInfo.SLog}:进入库位中,移栽升降轴到料屉取放点P7/P13[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
UpdownAxisToP7_P13
();
UpdownAxisToP7_P13
();
SaveSpecifiedImage
();
break
;
break
;
case
StepEnum
.
SI_13_GetReel
:
case
StepEnum
.
SI_13_GetReel
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_14_ReleaseCompress
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_14_ReleaseCompress
);
...
@@ -313,27 +312,38 @@ namespace OnlineStore.DeviceLibrary
...
@@ -313,27 +312,38 @@ namespace OnlineStore.DeviceLibrary
PullAxis_UpdownToHighP3
();
PullAxis_UpdownToHighP3
();
break
;
break
;
case
StepEnum
.
SI_16_LiftTray
:
case
StepEnum
.
SI_16_LiftTray
:
//MoveInfo.NextMoveStep(StepEnum.SI_17_PushTray);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_17_PushTray
);
LogInfo
(
$
"入库 {MoveInfo.SLog}:推到抽屉待机点采集图片,料斗拉取进出轴到P1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_Inout_To_P1
();
//MoveInfo.NextMoveStep(StepEnum.SI_18_PutTrayMiddle);
//LogInfo($"入库 {MoveInfo.SLog}:推到抽屉提取点,料斗拉取进出轴到料屉提取点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
//PullAxis_Inout_To_P2_P4();
break
;
case
StepEnum
.
SI_17_PushTray
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_18_PutTrayMiddle
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_18_PutTrayMiddle
);
LogInfo
(
$
"入库 {MoveInfo.SLog}:推到抽屉提取点,料斗拉取进出轴到料屉提取点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"入库 {MoveInfo.SLog}:推到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
SaveSpecifiedImage
();
Bitmap
bitmap
=
AcqImage
(
CamPosSide
(
MoveInfo
.
MoveParam
.
PosInfo
.
PosId
));
bool
rtn
=
MatchAndSaveImg
(
bitmap
,
$
"{CamPosSide(MoveInfo.MoveParam.PosInfo.PosId)}_{DateTime.Now.ToString("
HHmmss
")}"
);
string
res
=
rtn
?
"OK"
:
"NG"
;
LogInfo
(
$
"入库 {MoveInfo.SLog}:抓手检测结果:{res}[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_Inout_To_P2_P4
();
PullAxis_Inout_To_P2_P4
();
break
;
//case StepEnum.SI_17_PushTray:
//PullAxis_UpdownToMiddleP2();
// MoveInfo.NextMoveStep(StepEnum.SI_18_PutTrayMiddle);
//if (CheckASide())
// PullAxis_UpdownToMiddleP2();
//{
// if (CheckASide())
// {
// LogInfo($"入库 {MoveInfo.SLog}:料斗拉取升降轴到料屉水平点P2,同时检测{trayAColumns[GetPosColumn()]}=1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
// LogInfo($"入库 {MoveInfo.SLog}:料斗拉取升降轴到料屉水平点P2,同时检测{trayAColumns[GetPosColumn()]}=1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
// if (!GetShieldState(sheidAColmns[GetPosColumn()]))
// if (!GetShieldState(sheidAColmns[GetPosColumn()]))
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(trayAColumns[GetPosColumn()], IO_VALUE.HIGH));
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(trayAColumns[GetPosColumn()], IO_VALUE.HIGH));
//
}
//
}
//
else
//
else
//
{
//
{
// LogInfo($"入库 {MoveInfo.SLog}:料斗拉取升降轴到料屉水平点P2,同时检测{trayBColumns[GetPosColumn()]} = 1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
// LogInfo($"入库 {MoveInfo.SLog}:料斗拉取升降轴到料屉水平点P2,同时检测{trayBColumns[GetPosColumn()]} = 1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
// if (!GetShieldState(sheidBColmns[GetPosColumn()]))
// if (!GetShieldState(sheidBColmns[GetPosColumn()]))
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(trayBColumns[GetPosColumn()], IO_VALUE.HIGH));
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(trayBColumns[GetPosColumn()], IO_VALUE.HIGH));
//
}
//
}
//
break;
break
;
case
StepEnum
.
SI_18_PutTrayMiddle
:
case
StepEnum
.
SI_18_PutTrayMiddle
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_18_PutTrayDown
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SI_18_PutTrayDown
);
//LogInfo($"入库 {MoveInfo.SLog}:放下料屉,料斗拉取升降轴到料屉提取低点P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
//LogInfo($"入库 {MoveInfo.SLog}:放下料屉,料斗拉取升降轴到料屉提取低点P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
...
...
source/DeviceLibrary/storeBean/boxBean/BoxEquip_OutExecute.cs
查看文件 @
67d3757
...
@@ -66,7 +66,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -66,7 +66,7 @@ namespace OnlineStore.DeviceLibrary
{
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_03_ToTray
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_03_ToTray
);
LogInfo
(
$
"出库 {MoveInfo.SLog}:到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"出库 {MoveInfo.SLog}:到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
ToTray
();
PullAxis_Inout_To_P2_P4
();
CamDetectError
=
false
;
CamDetectError
=
false
;
IgnoreCamDect
=
false
;
IgnoreCamDect
=
false
;
}
}
...
@@ -91,7 +91,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -91,7 +91,6 @@ namespace OnlineStore.DeviceLibrary
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_07_GetReel
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_07_GetReel
);
LogInfo
(
$
"出库 {MoveInfo.SLog}:进入库位中,移栽升降轴到料屉取放点P7/P13[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"出库 {MoveInfo.SLog}:进入库位中,移栽升降轴到料屉取放点P7/P13[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
UpdownAxisToP7_P13
();
UpdownAxisToP7_P13
();
SaveSpecifiedImage
();
break
;
break
;
case
StepEnum
.
SO_07_GetReel
:
case
StepEnum
.
SO_07_GetReel
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_08_StartCompress
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_08_StartCompress
);
...
@@ -109,29 +108,42 @@ namespace OnlineStore.DeviceLibrary
...
@@ -109,29 +108,42 @@ namespace OnlineStore.DeviceLibrary
PullAxis_UpdownToHighP3
();
PullAxis_UpdownToHighP3
();
break
;
break
;
case
StepEnum
.
SO_10_LiftTray
:
case
StepEnum
.
SO_10_LiftTray
:
//MoveInfo.NextMoveStep(StepEnum.SO_11_PushTray);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_11_PushTray
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_12_PutTrayMiddle
);
LogInfo
(
$
"出库 {MoveInfo.SLog}:到进出轴待机点拍照,料斗拉取进出轴到料屉待机点P1,移栽旋转轴到取放料水平点P2,移栽X到P1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"出库 {MoveInfo.SLog}:推到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4,移栽旋转轴到取放料水平点P2,移栽X到P1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_Inout_To_P1
();
PullAxis_Inout_To_P2_P4
();
MiddleAxis_To_P2
();
MiddleAxis_To_P2
();
XAxis_To_P1
();
XAxis_To_P1
();
//MoveInfo.NextMoveStep(StepEnum.SO_12_PutTrayMiddle);
//LogInfo($"出库 {MoveInfo.SLog}:推到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4,移栽旋转轴到取放料水平点P2,移栽X到P1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
//PullAxis_Inout_To_P2_P4();
//MiddleAxis_To_P2();
//XAxis_To_P1();
break
;
break
;
//case StepEnum.SO_11_PushTray:
case
StepEnum
.
SO_11_PushTray
:
// MoveInfo.NextMoveStep(StepEnum.SO_12_PutTrayMiddle);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_12_PutTrayMiddle
);
// PullAxis_UpdownToMiddleP2();
LogInfo
(
$
"出库 {MoveInfo.SLog}:推到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
// if (CheckASide())
SaveSpecifiedImage
();
// {
Bitmap
bitmap
=
AcqImage
(
CamPosSide
(
MoveInfo
.
MoveParam
.
PosInfo
.
PosId
));
bool
rtn
=
MatchAndSaveImg
(
bitmap
,
$
"{CamPosSide(MoveInfo.MoveParam.PosInfo.PosId)}_{DateTime.Now.ToString("
HHmmss
")}"
);
string
res
=
rtn
?
"OK"
:
"NG"
;
LogInfo
(
$
"出库 {MoveInfo.SLog}:抓手检测结果:{res}[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_Inout_To_P2_P4
();
//PullAxis_UpdownToMiddleP2();
//if (CheckASide())
//{
// LogInfo($"出库 {MoveInfo.SLog}:料斗拉取升降轴到料屉水平点P2,同时检测{trayAColumns[GetPosColumn()]}=1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
// LogInfo($"出库 {MoveInfo.SLog}:料斗拉取升降轴到料屉水平点P2,同时检测{trayAColumns[GetPosColumn()]}=1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
// if (!GetShieldState(sheidAColmns[GetPosColumn()]))
// if (!GetShieldState(sheidAColmns[GetPosColumn()]))
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(trayAColumns[GetPosColumn()], IO_VALUE.HIGH));
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(trayAColumns[GetPosColumn()], IO_VALUE.HIGH));
//
}
//
}
//
else
//
else
//
{
//
{
// LogInfo($"出库 {MoveInfo.SLog}:料斗拉取升降轴到料屉水平点P2,同时检测{trayBColumns[GetPosColumn()]} = 1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
// LogInfo($"出库 {MoveInfo.SLog}:料斗拉取升降轴到料屉水平点P2,同时检测{trayBColumns[GetPosColumn()]} = 1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
// if (!GetShieldState(sheidBColmns[GetPosColumn()]))
// if (!GetShieldState(sheidBColmns[GetPosColumn()]))
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(trayBColumns[GetPosColumn()], IO_VALUE.HIGH));
// MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(trayBColumns[GetPosColumn()], IO_VALUE.HIGH));
//
}
//
}
//
break;
break
;
case
StepEnum
.
SO_12_PutTrayMiddle
:
case
StepEnum
.
SO_12_PutTrayMiddle
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_12_PutTrayDown
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_12_PutTrayDown
);
//LogInfo($"出库 {MoveInfo.SLog}:放下料屉,料斗拉取升降轴到料屉提取低点P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
//LogInfo($"出库 {MoveInfo.SLog}:放下料屉,料斗拉取升降轴到料屉提取低点P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]");
...
...
source/DeviceLibrary/storeBean/boxBean/BoxEquip_Partial.cs
查看文件 @
67d3757
...
@@ -157,23 +157,35 @@ namespace OnlineStore.DeviceLibrary
...
@@ -157,23 +157,35 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 行走机构到待机点P1
/// 行走机构到待机点P1
/// </summary>
/// </summary>
private
void
MoveAxisToP1
()
private
void
MoveAxisToP1
(
bool
isdebugSpeed
=
false
)
{
{
if
(!
MoveAxis
.
IsInPosition
(
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P1
))
if
(!
MoveAxis
.
IsInPosition
(
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P1
))
{
if
(
isdebugSpeed
)
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P1
,
Config
.
MoveAxis_FindPosSpeed
);
else
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P1
,
Config
.
MoveAxis_P1_Speed
);
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P1
,
Config
.
MoveAxis_P1_Speed
);
}
}
}
/// <summary>
/// <summary>
/// 行走机构到进出料机构取放点P2
/// 行走机构到进出料机构取放点P2
/// </summary>
/// </summary>
private
void
MoveAxisToP2
()
private
void
MoveAxisToP2
(
bool
isdebugSpeed
=
false
)
{
{
if
(
isdebugSpeed
)
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P2
,
Config
.
MoveAxis_FindPosSpeed
);
else
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P2
,
Config
.
MoveAxis_P2_Speed
);
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P2
,
Config
.
MoveAxis_P2_Speed
);
}
}
/// <summary>
/// <summary>
/// 行走机构到存储库位取放点位P3
/// 行走机构到存储库位取放点位P3
/// </summary>
/// </summary>
private
void
MoveAxisToP3
()
private
void
MoveAxisToP3
(
bool
isdebugSpeed
=
false
)
{
{
if
(
isdebugSpeed
)
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P3
,
Config
.
MoveAxis_FindPosSpeed
);
else
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P3
,
Config
.
MoveAxis_P3_Speed
);
MoveAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
MoveAxis_P3
,
Config
.
MoveAxis_P3_Speed
);
}
}
#
endregion
#
endregion
...
@@ -181,46 +193,67 @@ namespace OnlineStore.DeviceLibrary
...
@@ -181,46 +193,67 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 料斗拉取进出轴到料屉库位点P3/P5
/// 料斗拉取进出轴到料屉库位点P3/P5
/// </summary>
/// </summary>
private
void
PullAxis_Inout_To_P3_P5
()
private
void
PullAxis_Inout_To_P3_P5
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P3_P5
,
Config
.
PullAxis_InOut_FindPosSpeed
);
else
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P3_P5
,
Config
.
PullAxis_Inout_P3_Speed
);
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P3_P5
,
Config
.
PullAxis_Inout_P3_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P3_P5
,
Config
.
PullAxis_InOut_FindPosSpeed
);
else
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P3_P5
,
Config
.
PullAxis_Inout_P5_Speed
);
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P3_P5
,
Config
.
PullAxis_Inout_P5_Speed
);
}
}
}
}
/// <summary>
/// <summary>
/// 料斗拉取进出轴到料屉提取点P2/P4
/// 料斗拉取进出轴到料屉提取点P2/P4
/// </summary>
/// </summary>
private
void
PullAxis_Inout_To_P2_P4
()
private
void
PullAxis_Inout_To_P2_P4
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P2_P4
,
Config
.
PullAxis_InOut_FindPosSpeed
);
else
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P2_P4
,
Config
.
PullAxis_Inout_P2_Speed
);
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P2_P4
,
Config
.
PullAxis_Inout_P2_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P2_P4
,
Config
.
PullAxis_InOut_FindPosSpeed
);
else
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P2_P4
,
Config
.
PullAxis_Inout_P4_Speed
);
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P2_P4
,
Config
.
PullAxis_Inout_P4_Speed
);
}
}
}
}
private
void
PullAxis_Inout_To_P1
()
private
void
PullAxis_Inout_To_P1
(
bool
isdebugSpeed
=
false
)
{
{
if
(
isdebugSpeed
)
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P1
,
Config
.
PullAxis_InOut_FindPosSpeed
);
else
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P1
,
Config
.
PullAxis_Inout_P1_Speed
);
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P1
,
Config
.
PullAxis_Inout_P1_Speed
);
}
}
/// <summary>
/// <summary>
/// 料斗拉取进出轴到取像点
/// 料斗拉取进出轴到取像点
/// </summary>
/// </summary>
private
void
PullAxis_Inout_To_Cam
()
private
void
PullAxis_Inout_To_Cam
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Inout_CamA
,
Config
.
PullAxis_InOut_FindPosSpeed
);
else
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Inout_CamA
,
Config
.
PullAxis_Inout_P1_Speed
);
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Inout_CamA
,
Config
.
PullAxis_Inout_P1_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Inout_CamB
,
Config
.
PullAxis_InOut_FindPosSpeed
);
else
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Inout_CamB
,
Config
.
PullAxis_Inout_P1_Speed
);
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Inout_CamB
,
Config
.
PullAxis_Inout_P1_Speed
);
}
}
}
}
...
@@ -228,14 +261,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -228,14 +261,20 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 移栽升降轴到料屉取放点P7/P13
/// 移栽升降轴到料屉取放点P7/P13
/// </summary>
/// </summary>
private
void
UpdownAxisToP7_P13
()
private
void
UpdownAxisToP7_P13
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P7_P13
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P7_P13
,
Config
.
Updown_P7_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P7_P13
,
Config
.
Updown_P7_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P7_P13
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P7_P13
,
Config
.
Updown_P13_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P7_P13
,
Config
.
Updown_P13_Speed
);
}
}
}
}
...
@@ -243,70 +282,100 @@ namespace OnlineStore.DeviceLibrary
...
@@ -243,70 +282,100 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 移栽升降轴到料屉上方过渡点P6/P12
/// 移栽升降轴到料屉上方过渡点P6/P12
/// </summary>
/// </summary>
private
void
UpdownAxisTo_P6_P12
()
private
void
UpdownAxisTo_P6_P12
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P6_P12
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P6_P12
,
Config
.
Updown_P6_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P6_P12
,
Config
.
Updown_P6_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P6_P12
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P6_P12
,
Config
.
Updown_P12_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
Updown_P6_P12
,
Config
.
Updown_P12_Speed
);
}
}
}
}
/// <summary>
/// <summary>
/// 移栽升降轴到下暂存区放料高点P4/P10
/// 移栽升降轴到下暂存区放料高点P4/P10
/// </summary>
/// </summary>
private
void
UpdownAxisTo_P4_P10
()
private
void
UpdownAxisTo_P4_P10
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P4
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P4
,
Config
.
Updown_P4_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P4
,
Config
.
Updown_P4_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P10
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P10
,
Config
.
Updown_P10_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P10
,
Config
.
Updown_P10_Speed
);
}
}
}
}
/// <summary>
/// <summary>
/// 移栽升降轴到上暂存区取料高点P2/P8
/// 移栽升降轴到上暂存区取料高点P2/P8
/// </summary>
/// </summary>
private
void
UpdownAxisTo_P2_P8
()
private
void
UpdownAxisTo_P2_P8
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P2
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P2
,
Config
.
Updown_P2_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P2
,
Config
.
Updown_P2_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P8
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P8
,
Config
.
Updown_P8_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P8
,
Config
.
Updown_P8_Speed
);
}
}
}
}
/// <summary>
/// <summary>
/// 移栽升降轴到上暂存区取料低点P3/P9
/// 移栽升降轴到上暂存区取料低点P3/P9
/// </summary>
/// </summary>
private
void
UpdownAxisTo_P3_P9
()
private
void
UpdownAxisTo_P3_P9
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P3
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P3
,
Config
.
Updown_P3_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P3
,
Config
.
Updown_P3_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P9
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P9
,
Config
.
Updown_P9_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P9
,
Config
.
Updown_P9_Speed
);
}
}
}
}
/// <summary>
/// <summary>
/// 移栽升降轴到下暂存区放料低点P5/P11
/// 移栽升降轴到下暂存区放料低点P5/P11
/// </summary>
/// </summary>
private
void
UpdownAxisTo_P5_P11
()
private
void
UpdownAxisTo_P5_P11
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P5
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P5
,
Config
.
Updown_P5_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P5
,
Config
.
Updown_P5_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P11
,
Config
.
UpdownAxis_FindPosSpeed
);
else
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P11
,
Config
.
Updown_P11_Speed
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
Updown_P11
,
Config
.
Updown_P11_Speed
);
}
}
}
}
...
@@ -316,46 +385,70 @@ namespace OnlineStore.DeviceLibrary
...
@@ -316,46 +385,70 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// AB面移栽X轴到进出料暂存区取放点P2
/// AB面移栽X轴到进出料暂存区取放点P2
/// </summary>
/// </summary>
private
void
XAxis_To_P2
()
private
void
XAxis_To_P2
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
XAxis_A
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_A_P2
,
Config
.
XAxis_FindPosSpeed
);
else
XAxis_A
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_A_P2
,
Config
.
XAxis_A_P2_Speed
);
XAxis_A
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_A_P2
,
Config
.
XAxis_A_P2_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
XAxis_B
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_B_P2
,
Config
.
XAxis_FindPosSpeed
);
else
XAxis_B
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_B_P2
,
Config
.
XAxis_B_P2_Speed
);
XAxis_B
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_B_P2
,
Config
.
XAxis_B_P2_Speed
);
}
}
}
}
/// <summary>
/// <summary>
/// AB面移栽X轴到料屉库位取放料点P3
/// AB面移栽X轴到料屉库位取放料点P3
/// </summary>
/// </summary>
private
void
XAxis_To_P3
()
private
void
XAxis_To_P3
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
XAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
XAxis_AB_P3
,
Config
.
XAxis_FindPosSpeed
);
else
XAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
XAxis_AB_P3
,
Config
.
XAxis_A_P3_Speed
);
XAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
XAxis_AB_P3
,
Config
.
XAxis_A_P3_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
XAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
XAxis_AB_P3
,
Config
.
XAxis_FindPosSpeed
);
else
XAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
XAxis_AB_P3
,
Config
.
XAxis_B_P3_Speed
);
XAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
XAxis_AB_P3
,
Config
.
XAxis_B_P3_Speed
);
}
}
}
}
/// <summary>
/// <summary>
/// AB面移栽X轴到待机点
/// AB面移栽X轴到待机点
/// </summary>
/// </summary>
private
void
XAxis_To_P1
()
private
void
XAxis_To_P1
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(!
XAxis_A
.
IsInPosition
(
Config
.
XAxis_A_P1
))
if
(!
XAxis_A
.
IsInPosition
(
Config
.
XAxis_A_P1
))
{
if
(
isdebugSpeed
)
XAxis_A
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_A_P1
,
Config
.
XAxis_FindPosSpeed
);
else
XAxis_A
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_A_P1
,
Config
.
XAxis_A_P1_Speed
);
XAxis_A
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_A_P1
,
Config
.
XAxis_A_P1_Speed
);
}
}
}
else
else
{
{
if
(!
XAxis_B
.
IsInPosition
(
Config
.
XAxis_B_P1
))
if
(!
XAxis_B
.
IsInPosition
(
Config
.
XAxis_B_P1
))
{
if
(
isdebugSpeed
)
XAxis_B
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_B_P1
,
Config
.
XAxis_FindPosSpeed
);
else
XAxis_B
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_B_P1
,
Config
.
XAxis_B_P1_Speed
);
XAxis_B
.
AbsMove
(
MoveInfo
,
Config
.
XAxis_B_P1
,
Config
.
XAxis_B_P1_Speed
);
}
}
}
}
}
#
endregion
#
endregion
...
@@ -363,28 +456,40 @@ namespace OnlineStore.DeviceLibrary
...
@@ -363,28 +456,40 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// AB移栽压紧轴到压紧前点P2
/// AB移栽压紧轴到压紧前点P2
/// </summary>
/// </summary>
private
void
ComAxis_To_P2
()
private
void
ComAxis_To_P2
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
ComAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P2
,
Config
.
ComAxis_FindPosSpeed
);
else
ComAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P2
,
Config
.
ComAxis_A_P2_Speed
);
ComAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P2
,
Config
.
ComAxis_A_P2_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
ComAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P2
,
Config
.
ComAxis_FindPosSpeed
);
else
ComAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P2
,
Config
.
ComAxis_B_P2_Speed
);
ComAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P2
,
Config
.
ComAxis_B_P2_Speed
);
}
}
}
}
/// <summary>
/// <summary>
/// AB移栽压紧轴到压紧点P3
/// AB移栽压紧轴到压紧点P3
/// </summary>
/// </summary>
private
void
ComAxis_To_P3
()
private
void
ComAxis_To_P3
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
if
(
isdebugSpeed
)
ComAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P3
,
Config
.
ComAxis_FindPosSpeed
);
else
ComAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P3
,
Config
.
ComAxis_A_P3_Speed
);
ComAxis_A
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P3
,
Config
.
ComAxis_A_P3_Speed
);
}
}
else
else
{
{
if
(
isdebugSpeed
)
ComAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P3
,
Config
.
ComAxis_FindPosSpeed
);
else
ComAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P3
,
Config
.
ComAxis_B_P3_Speed
);
ComAxis_B
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
ComAxis_AB_P3
,
Config
.
ComAxis_B_P3_Speed
);
}
}
}
}
...
@@ -393,29 +498,41 @@ namespace OnlineStore.DeviceLibrary
...
@@ -393,29 +498,41 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// 抽屉待机点
/// 抽屉待机点
/// </summary>
/// </summary>
private
void
PullAxis_UpdownToP1
()
private
void
PullAxis_UpdownToP1
(
bool
isdebugSpeed
=
false
)
{
{
if
(
isdebugSpeed
)
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P1
,
Config
.
PullAxis_Updown_FindPosSpeed
);
else
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P1
,
Config
.
PullAxis_Updown_P1_Speed
);
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P1
,
Config
.
PullAxis_Updown_P1_Speed
);
}
}
/// <summary>
/// <summary>
/// 抽屉高点,料斗拉取升降轴到料屉提取高点P3
/// 抽屉高点,料斗拉取升降轴到料屉提取高点P3
/// </summary>
/// </summary>
private
void
PullAxis_UpdownToHighP3
()
private
void
PullAxis_UpdownToHighP3
(
bool
isdebugSpeed
=
false
)
{
{
if
(
isdebugSpeed
)
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P3
,
Config
.
PullAxis_Updown_FindPosSpeed
);
else
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P3
,
Config
.
PullAxis_Updown_P3_Speed
);
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P3
,
Config
.
PullAxis_Updown_P3_Speed
);
}
}
/// <summary>
/// <summary>
/// 抽屉水平点,料斗拉取升降轴到料屉水平点P2
/// 抽屉水平点,料斗拉取升降轴到料屉水平点P2
/// </summary>
/// </summary>
private
void
PullAxis_UpdownToMiddleP2
()
private
void
PullAxis_UpdownToMiddleP2
(
bool
isdebugSpeed
=
false
)
{
{
if
(
isdebugSpeed
)
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P2
,
Config
.
PullAxis_Updown_FindPosSpeed
);
else
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P2
,
Config
.
PullAxis_Updown_P2_Speed
);
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P2
,
Config
.
PullAxis_Updown_P2_Speed
);
}
}
/// <summary>
/// <summary>
/// 抽屉低点,料斗拉取升降轴到料屉提取低点P4
/// 抽屉低点,料斗拉取升降轴到料屉提取低点P4
/// </summary>
/// </summary>
private
void
PullAxis_UpdownToLowP4
()
private
void
PullAxis_UpdownToLowP4
(
bool
isdebugSpeed
=
false
)
{
{
if
(
isdebugSpeed
)
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P4
,
Config
.
PullAxis_Updown_FindPosSpeed
);
else
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P4
,
Config
.
PullAxis_Updown_P4_Speed
);
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Updown_P4
,
Config
.
PullAxis_Updown_P4_Speed
);
}
}
#
endregion
#
endregion
...
@@ -424,7 +541,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -424,7 +541,7 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// AB面移栽旋转轴到料屉库位垂直取放料点P3
/// AB面移栽旋转轴到料屉库位垂直取放料点P3
/// </summary>
/// </summary>
private
void
MiddleAxis_To_P3
()
private
void
MiddleAxis_To_P3
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
...
@@ -440,7 +557,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -440,7 +557,7 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// <summary>
/// AB面移栽旋转轴到水平点P2
/// AB面移栽旋转轴到水平点P2
/// </summary>
/// </summary>
private
void
MiddleAxis_To_P2
()
private
void
MiddleAxis_To_P2
(
bool
isdebugSpeed
=
false
)
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
...
@@ -470,21 +587,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -470,21 +587,6 @@ namespace OnlineStore.DeviceLibrary
#
endregion
#
endregion
/// <summary>
/// <summary>
/// 到抽屉提取点,料斗拉取进出轴到P2(A/B面料屉提取点)
/// </summary>
private
void
ToTray
()
{
if
(
CheckASide
())
{
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P2_P4
,
Config
.
PullAxis_Inout_P2_Speed
);
}
else
{
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
MoveInfo
.
MoveParam
.
MoveP
.
PullAxis_Inout_P2_P4
,
Config
.
PullAxis_Inout_P4_Speed
);
}
}
/// <summary>
/// 获取当前位置
/// 获取当前位置
/// </summary>
/// </summary>
/// <param name="PosId"></param>
/// <param name="PosId"></param>
...
@@ -619,7 +721,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -619,7 +721,7 @@ namespace OnlineStore.DeviceLibrary
{
{
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Updown_P1
,
Config
.
PullAxis_Updown_P1_Speed
);
PullAxis_Updown
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Updown_P1
,
Config
.
PullAxis_Updown_P1_Speed
);
}
}
if
(
PullAxis_Inout
.
IsInPosition
(
Config
.
PullAxis_Inout_CamA
)
||
PullAxis_Inout
.
IsInPosition
(
Config
.
PullAxis_Inout_CamB
)
if
(
PullAxis_Inout
.
IsInPosition
(
Config
.
PullAxis_Inout_CamA
)
||
PullAxis_Inout
.
IsInPosition
(
Config
.
PullAxis_Inout_CamB
)
||
PullAxis_Inout
.
IsInPosition
(
Config
.
PullAxis_Inout_P1
))
||
PullAxis_Inout
.
IsInPosition
(
Config
.
PullAxis_Inout_P1
))
{
{
...
@@ -634,10 +736,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -634,10 +736,6 @@ namespace OnlineStore.DeviceLibrary
{
{
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Inout_CamB
,
Config
.
PullAxis_Inout_P1_Speed
);
PullAxis_Inout
.
AbsMove
(
MoveInfo
,
Config
.
PullAxis_Inout_CamB
,
Config
.
PullAxis_Inout_P1_Speed
);
}
}
//else
//{
// PullAxis_Inout.AbsMove(MoveInfo, Config.PullAxis_Inout_P1, Config.PullAxis_Inout_P1_Speed);
//}
}
}
if
(
MoveInfo
.
MoveStep
.
Equals
(
StepEnum
.
SI_00_StartInstore
))
if
(
MoveInfo
.
MoveStep
.
Equals
(
StepEnum
.
SI_00_StartInstore
))
...
@@ -648,7 +746,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -648,7 +746,7 @@ namespace OnlineStore.DeviceLibrary
{
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_01_PullAxis_Ready
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SO_01_PullAxis_Ready
);
}
}
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
StepEnum
.
SP_00_1_StartPosDebug
))
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
StepEnum
.
SP_00_1_StartPosDebug
))
{
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_00_2_PullAxisReady
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_00_2_PullAxisReady
);
}
}
...
@@ -698,7 +796,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -698,7 +796,7 @@ namespace OnlineStore.DeviceLibrary
CamDetectError
=
true
;
CamDetectError
=
true
;
return
false
;
return
false
;
}
}
else
if
(
res
==
-
1
)
else
if
(
res
==
-
1
)
{
{
SetWarnMsg
(
$
"相机检查库位异常[code={res}],取像失败。库位号:{MoveInfo.MoveParam.PosInfo.PosId}"
);
SetWarnMsg
(
$
"相机检查库位异常[code={res}],取像失败。库位号:{MoveInfo.MoveParam.PosInfo.PosId}"
);
CamDetectError
=
true
;
CamDetectError
=
true
;
...
@@ -725,9 +823,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -725,9 +823,20 @@ namespace OnlineStore.DeviceLibrary
return
false
;
return
false
;
}
}
private
float
GetValidateDrawerArea
()
{
if
(
CheckASide
())
{
return
Config
.
Validate_Drawer_A_Area
;
}
else
{
return
Config
.
Validate_Drawer_B_Area
;
}
}
private
float
GetValidateDrawerX
()
private
float
GetValidateDrawerX
()
{
{
if
(
CheckASide
())
if
(
CheckASide
())
{
{
return
Config
.
Validate_Drawer_A_X
;
return
Config
.
Validate_Drawer_A_X
;
}
}
...
@@ -809,7 +918,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -809,7 +918,7 @@ namespace OnlineStore.DeviceLibrary
/// <returns>true:有料</returns>
/// <returns>true:有料</returns>
private
bool
InDoorSigCheck
()
private
bool
InDoorSigCheck
()
{
{
if
(
IOValue
(
IO_Type
.
UpperArea_Check_A
).
Equals
(
IO_VALUE
.
HIGH
)
||
IOValue
(
IO_Type
.
UpperArea_Check_B
).
Equals
(
IO_VALUE
.
HIGH
))
if
(
IOValue
(
IO_Type
.
UpperArea_Check_A
).
Equals
(
IO_VALUE
.
HIGH
)
||
IOValue
(
IO_Type
.
UpperArea_Check_B
).
Equals
(
IO_VALUE
.
HIGH
))
{
{
return
true
;
return
true
;
}
}
...
@@ -917,7 +1026,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -917,7 +1026,7 @@ namespace OnlineStore.DeviceLibrary
private
DateTime
startOutStoreTime
=
DateTime
.
Now
;
private
DateTime
startOutStoreTime
=
DateTime
.
Now
;
public
override
bool
StartOutstore
(
InOutParam
param
)
public
override
bool
StartOutstore
(
InOutParam
param
)
{
{
if
(
InDoorSigCheck
())
if
(
InDoorSigCheck
())
{
{
return
false
;
return
false
;
}
}
...
...
source/DeviceLibrary/storeBean/boxBean/BoxEquip_PosDebug.cs
查看文件 @
67d3757
using
OnlineStore.LoadCSVLibrary
;
using
OnlineStore.Common
;
using
OnlineStore.LoadCSVLibrary
;
using
System
;
using
System
;
using
System.Collections.Generic
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Linq
;
...
@@ -10,25 +11,50 @@ namespace OnlineStore.DeviceLibrary
...
@@ -10,25 +11,50 @@ namespace OnlineStore.DeviceLibrary
public
partial
class
BoxEquip
public
partial
class
BoxEquip
{
{
public
bool
isInitPosDebugInfo
=
false
;
public
bool
isInitPosDebugInfo
=
false
;
PosDebugInfo
posDebugInfo
=
null
;
public
PosDebugInfo
posDebugInfo
=
null
;
public
void
InitPosDebugInfo
()
public
void
InitPosDebugInfo
()
{
{
PosDebugResultManager
.
Init
(
PositionNumList
);
PosDebugResultManager
.
Init
(
PositionNumList
);
isInitPosDebugInfo
=
PosDebugResultManager
.
isInit
;
isInitPosDebugInfo
=
PosDebugResultManager
.
isInit
;
posDebugInfo
=
new
PosDebugInfo
(
this
.
CID
,
this
.
Config
);
posDebugInfo
=
new
PosDebugInfo
(
this
.
CID
,
this
.
Config
);
posDebugInfo
.
SetDrawerParam
(
1
,
1
,
15
,
6
);
posDebugInfo
.
SetGridParam
(
1
,
1
,
4
,
20
);
}
}
public
void
Test
()
public
void
StartPosDebug
(
InOutParam
param
)
{
while
(!
posDebugInfo
.
IsLastDrawer
())
{
{
while
(!
posDebugInfo
.
IsLastGrid
())
if
(
isInSuddenDown
||
isNoAirpressure_Check
||
(!
runStatus
.
Equals
(
RunStatus
.
Runing
))
||
(!
MoveInfo
.
MoveType
.
Equals
(
MoveType
.
None
)))
{
{
posDebugInfo
.
NextGrid
();
LogUtil
.
error
(
Name
+
" 启动库位调试出错,忙碌或报警中 ,storeStatus="
+
runStatus
+
",MoveType="
+
MoveInfo
.
MoveType
+
",isInSuddenDown="
+
isInSuddenDown
+
",isNoAirpressure_Check="
+
isNoAirpressure_Check
);
return
;
}
}
posDebugInfo
.
NextDrawer
();
LogInfo
(
" 启动库位调试【"
+
param
.
PosInfo
.
ToStr
()
+
"】 "
);
param
.
MoveP
=
new
LineMoveP
(
Config
,
param
.
PosInfo
.
PosId
);
MoveInfo
.
NewMove
(
MoveType
.
Working
,
param
);
SetBoxStatus
(
DeviceStatus
.
Debugging
,
RunStatus
.
Busy
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_00_1_StartPosDebug
);
PullAxis_Inout_To_P1
();
}
}
//public void Test()
//{
// while(!posDebugInfo.IsLastDrawer())
// {
// while(!posDebugInfo.IsLastGrid())
// {
// posDebugInfo.NextGrid();
// }
// posDebugInfo.NextDrawer();
// }
//}
/// <summary>
/// 更新移动信息
/// </summary>
private
void
UpdateMoveInfo
(
string
posId
)
{
InOutPosInfo
inOutPosInfo
=
new
InOutPosInfo
(
"PosDebug"
,
posId
);
MoveInfo
.
MoveParam
.
PosInfo
=
inOutPosInfo
;
MoveInfo
.
MoveParam
.
MoveP
=
new
LineMoveP
(
Config
,
inOutPosInfo
.
PosId
);
}
}
/// <summary>
/// <summary>
/// 设置抽屉的结果代码
/// 设置抽屉的结果代码
...
@@ -58,20 +84,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -58,20 +84,20 @@ namespace OnlineStore.DeviceLibrary
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_00_3_CheckMoveAxisSafe
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_00_3_CheckMoveAxisSafe
);
if
(!
IsMoveAxisInSafePos
())
if
(!
IsMoveAxisInSafePos
())
{
{
MoveAxisToP1
();
MoveAxisToP1
(
true
);
LogInfo
(
$
"库位调试 行走机构不在安全位置,先到安全位置={Config.MoveAxis_SafePos}。当前位置{MoveAxis.GetAclPosition()}"
);
LogInfo
(
$
"库位调试 行走机构不在安全位置,先到安全位置={Config.MoveAxis_SafePos}。当前位置{MoveAxis.GetAclPosition()}"
);
}
}
break
;
break
;
case
StepEnum
.
SP_00_3_CheckMoveAxisSafe
:
case
StepEnum
.
SP_00_3_CheckMoveAxisSafe
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_01_ToBufferArea
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_01_ToBufferArea
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:到暂存区入料口,"
+
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:到暂存区入料口,"
+
$
"行走机构到待机点P1,料
屉升降轴到P1点,移栽升降轴到上暂存区取料低点P3/P9,移栽压紧轴到压紧前点P2,移栽旋转轴到取放料水平点P2,移栽X轴到P1,料屉升降轴到P1点
[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
$
"行走机构到待机点P1,料
斗升降轴到P1点,移栽升降轴到上暂存区取料低点P3/P9,移栽压紧轴到压紧前点P2,移栽旋转轴到取放料水平点P2,移栽X轴到P1
[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
MoveAxisToP1
();
MoveAxisToP1
(
true
);
PullAxis_UpdownToP1
();
PullAxis_UpdownToP1
(
true
);
UpdownAxisTo_P3_P9
();
UpdownAxisTo_P3_P9
(
true
);
ComAxis_To_P2
();
ComAxis_To_P2
(
true
);
MiddleAxis_To_P2
();
MiddleAxis_To_P2
(
true
);
XAxis_To_P1
();
XAxis_To_P1
(
true
);
break
;
break
;
case
StepEnum
.
SP_01_ToBufferArea
:
case
StepEnum
.
SP_01_ToBufferArea
:
if
(!
InDoorCheck
(
MoveInfo
.
MoveParam
))
if
(!
InDoorCheck
(
MoveInfo
.
MoveParam
))
...
@@ -92,8 +118,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -92,8 +118,8 @@ namespace OnlineStore.DeviceLibrary
{
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_03_XAxisToBuff
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_03_XAxisToBuff
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:移栽X轴到暂存区取放点P2,行走机构到取放点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:移栽X轴到暂存区取放点P2,行走机构到取放点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
XAxis_To_P2
();
XAxis_To_P2
(
true
);
MoveAxisToP2
();
MoveAxisToP2
(
true
);
}
}
else
if
(
MoveInfo
.
IsTimeOut
())
else
if
(
MoveInfo
.
IsTimeOut
())
{
{
...
@@ -104,19 +130,19 @@ namespace OnlineStore.DeviceLibrary
...
@@ -104,19 +130,19 @@ namespace OnlineStore.DeviceLibrary
case
StepEnum
.
SP_03_XAxisToBuff
:
case
StepEnum
.
SP_03_XAxisToBuff
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_04_GetReel
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_04_GetReel
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:取料盘,移栽升降轴到上暂存区取料高点P2/P8,移栽压紧轴到压紧点P3[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:取料盘,移栽升降轴到上暂存区取料高点P2/P8,移栽压紧轴到压紧点P3[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
UpdownAxisTo_P2_P8
();
UpdownAxisTo_P2_P8
(
true
);
ComAxis_To_P3
();
ComAxis_To_P3
(
true
);
break
;
break
;
case
StepEnum
.
SP_04_GetReel
:
case
StepEnum
.
SP_04_GetReel
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_05_XAxisBackToP1
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_05_XAxisBackToP1
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:移栽X轴到待机点P1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:移栽X轴到待机点P1[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
XAxis_To_P1
();
XAxis_To_P1
(
true
);
break
;
break
;
case
StepEnum
.
SP_05_XAxisBackToP1
:
case
StepEnum
.
SP_05_XAxisBackToP1
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_06_ClearBuffInfo
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_06_ClearBuffInfo
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:
清空暂存区料盘信息
[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
//清空暂存区料盘信息
//清空暂存区料盘信息
ClearInDoorBuffer
();
ClearInDoorBuffer
();
break
;
break
;
...
@@ -128,13 +154,13 @@ namespace OnlineStore.DeviceLibrary
...
@@ -128,13 +154,13 @@ namespace OnlineStore.DeviceLibrary
case
StepEnum
.
SP_07_MiddleToP3
:
case
StepEnum
.
SP_07_MiddleToP3
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_08_ToPosition
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_08_ToPosition
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:运行到库位,移栽升降轴到料屉上方过渡点P6/P12,行走机构到存储库位取放点位P3,"
+
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:运行到库位,移栽升降轴到料屉上方过渡点P6/P12,行走机构到存储库位取放点位P3,"
+
$
"料斗拉取升降轴到料屉提取低点P4,料
屉拉取进出轴到拍照点,移栽旋转轴到料屉库位垂直取放料点P3,移栽X轴到料屉
库位取放料点P3[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
$
"料斗拉取升降轴到料屉提取低点P4,料
斗拉取进出轴到拍照点,移栽旋转轴到料屉库位垂直取放料点P3,移栽X轴到料斗
库位取放料点P3[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
XAxis_To_P3
();
XAxis_To_P3
(
true
);
PullAxis_Inout_To_Cam
();
PullAxis_Inout_To_Cam
(
true
);
MiddleAxis_To_P3
();
MiddleAxis_To_P3
(
true
);
MoveAxisToP3
();
MoveAxisToP3
(
true
);
PullAxis_UpdownToLowP4
();
PullAxis_UpdownToLowP4
(
true
);
UpdownAxisTo_P6_P12
();
UpdownAxisTo_P6_P12
(
true
);
break
;
break
;
case
StepEnum
.
SP_08_ToPosition
:
case
StepEnum
.
SP_08_ToPosition
:
...
@@ -142,7 +168,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -142,7 +168,7 @@ namespace OnlineStore.DeviceLibrary
{
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_09_ToDrawer
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_09_ToDrawer
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:到抽屉提取点,料斗拉取进出轴到料屉提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
ToTray
(
);
PullAxis_Inout_To_P2_P4
(
true
);
CamDetectError
=
false
;
CamDetectError
=
false
;
IgnoreCamDect
=
false
;
IgnoreCamDect
=
false
;
}
}
...
@@ -157,95 +183,166 @@ namespace OnlineStore.DeviceLibrary
...
@@ -157,95 +183,166 @@ namespace OnlineStore.DeviceLibrary
case
StepEnum
.
SP_09_ToDrawer
:
case
StepEnum
.
SP_09_ToDrawer
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_10_LiftDrawer
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_10_LiftDrawer
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:提升抽屉,料斗拉取升降轴到料屉提取高点P3 [{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:提升抽屉,料斗拉取升降轴到料屉提取高点P3 [{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_UpdownToHighP3
();
PullAxis_UpdownToHighP3
(
true
);
break
;
break
;
case
StepEnum
.
SP_10_LiftDrawer
:
case
StepEnum
.
SP_10_LiftDrawer
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_11_PullDrawer
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_11_PullDrawer
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:拉抽屉到库位点,料斗拉取进出轴到料屉库位点P3/P5[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:拉抽屉到库位点,料斗拉取进出轴到料屉库位点P3/P5[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_Inout_To_P3_P5
();
PullAxis_Inout_To_P3_P5
(
true
);
break
;
break
;
case
StepEnum
.
SP_11_PullDrawer
:
case
StepEnum
.
SP_11_PullDrawer
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_12_DropDrawerToPos
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_12_DropDrawerToPos
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:将抽屉降到库位提取点,料斗拉取升降轴到P2料屉提取水平点P2,到位后检测{trayRows[GetPosRow()]}=1 [{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:将抽屉降到库位提取点,料斗拉取升降轴到P2料屉提取水平点P2,到位后检测{trayRows[GetPosRow()]}=1 [{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_UpdownToMiddleP2
();
PullAxis_UpdownToMiddleP2
(
true
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
trayRows
[
GetPosRow
()],
IO_VALUE
.
HIGH
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
trayRows
[
GetPosRow
()],
IO_VALUE
.
HIGH
));
break
;
break
;
case
StepEnum
.
SP_12_DropDrawerToPos
:
case
StepEnum
.
SP_12_DropDrawerToPos
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_13_PutReel
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_13_PutReel
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:进入库位中,移栽升降轴到料屉取放点P7/P13[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:进入库位中,移栽升降轴到料屉取放点P7/P13[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
UpdownAxisToP7_P13
();
UpdownAxisToP7_P13
(
true
);
SaveSpecifiedImage
();
SaveSpecifiedImage
();
break
;
break
;
case
StepEnum
.
SP_13_PutReel
:
case
StepEnum
.
SP_13_PutReel
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_14_ReleaseCompress
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_14_ReleaseCompress
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:压紧轴开始缓慢释放,移栽压紧轴到压紧前点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:
放下料盘,
压紧轴开始缓慢释放,移栽压紧轴到压紧前点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
ComAxis_To_P2
();
ComAxis_To_P2
(
true
);
break
;
break
;
case
StepEnum
.
SP_14_ReleaseCompress
:
case
StepEnum
.
SP_14_ReleaseCompress
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_15_UpDownBack
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_15_UpDownBack
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:叉子从库位返回[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:叉子从库位返回[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
UpdownAxisTo_P6_P12
();
UpdownAxisTo_P6_P12
(
true
);
break
;
break
;
case
StepEnum
.
SP_15_UpDownBack
:
case
StepEnum
.
SP_15_UpDownBack
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_16_GetReel
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_16_GetReel
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:进入库位中,移栽升降轴到料
屉
取放点P7/P13[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:进入库位中,移栽升降轴到料
斗
取放点P7/P13[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
UpdownAxisToP7_P13
();
UpdownAxisToP7_P13
(
true
);
break
;
break
;
case
StepEnum
.
SP_16_GetReel
:
case
StepEnum
.
SP_16_GetReel
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_17_StartCompress
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_17_StartCompress
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:压紧轴开始缓慢夹取,移栽压紧轴到压紧点P3[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:压紧轴开始缓慢夹取,移栽压紧轴到压紧点P3[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
ComAxis_To_P3
();
ComAxis_To_P3
(
true
);
break
;
break
;
case
StepEnum
.
SP_17_StartCompress
:
case
StepEnum
.
SP_17_StartCompress
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_18_UpDownBack
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_18_UpDownBack
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:叉子从库位返回,移栽升降轴到料
屉
上方过度点P6/P12 [{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:叉子从库位返回,移栽升降轴到料
斗
上方过度点P6/P12 [{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
UpdownAxisTo_P6_P12
();
UpdownAxisTo_P6_P12
(
true
);
break
;
break
;
case
StepEnum
.
SP_18_UpDownBack
:
case
StepEnum
.
SP_18_UpDownBack
:
if
(
posDebugInfo
.
IsLastGrid
())
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_19_CheckDrawerFinish
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_19_CheckDrawerFinish
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
int
drawerRescode
=
PosDebugResultManager
.
SetDrawerResultWithGrid
(
posDebugInfo
.
CurDrawer
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:{posDebugInfo.CurDrawer}{posDebugInfo.CurGrid}是抽屉的最后一个库位,统计抽屉结果:{drawerRescode}[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
}
else
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_25_ToNextGrid
);
PosDebugResultManager
.
SetGridResult
(
posDebugInfo
.
CurGrid
,
1
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:{posDebugInfo.CurDrawer}{posDebugInfo.CurGrid}库位调试OK,切换到下一个库位[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
posDebugInfo
.
NextGrid
();
UpdateMoveInfo
(
posDebugInfo
.
CurDrawer
+
posDebugInfo
.
CurGrid
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
}
break
;
break
;
case
StepEnum
.
SP_19_CheckDrawerFinish
:
case
StepEnum
.
SP_19_CheckDrawerFinish
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_20_LiftTray
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_20_LiftDrawer
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:提升抽屉,料斗拉取升降轴到料斗提取高点P3[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_UpdownToHighP3
(
true
);
break
;
break
;
case
StepEnum
.
SP_20_LiftTray
:
case
StepEnum
.
SP_20_LiftDrawer
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_21_PushTray
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_21_PushDrawer
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:将抽屉推入,料斗拉取进出轴到料斗提取点P2/P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_Inout_To_P2_P4
(
true
);
break
;
break
;
case
StepEnum
.
SP_21_Push
Tray
:
case
StepEnum
.
SP_21_Push
Drawer
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_22_Put
Tray
Middle
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_22_Put
Drawer
Middle
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:
抽屉降到水平点
[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
break
;
break
;
case
StepEnum
.
SP_22_PutTrayMiddle
:
case
StepEnum
.
SP_22_PutDrawerMiddle
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_23_PutTrayDown
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_23_PutDrawerDown
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:抽屉降到低点,料斗拉取升降轴到料斗提取低点P4[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_UpdownToLowP4
(
true
);
break
;
break
;
case
StepEnum
.
SP_23_Put
Tray
Down
:
case
StepEnum
.
SP_23_Put
Drawer
Down
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_24_InoutBack
);
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_24_InoutBack
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:进出轴返回拍照点[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
PullAxis_Inout_To_Cam
(
true
);
break
;
break
;
case
StepEnum
.
SP_24_InoutBack
:
case
StepEnum
.
SP_24_InoutBack
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_25_ToNextGrid
);
if
(
posDebugInfo
.
IsLastDrawer
())
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_26_ToBufferArea
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:{posDebugInfo.CurDrawer}是最后一个抽屉,将料盘送回暂存区。旋转轴到水平点P2,行走机构到待机点P1,抽屉升降轴到待机点P1、移栽升降轴到下暂存区高点P4/P10[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
MiddleAxis_To_P2
(
true
);
MoveAxisToP1
(
true
);
PullAxis_UpdownToP1
(
true
);
UpdownAxisTo_P4_P10
(
true
);
}
else
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_25_ToNextDrawer
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:{posDebugInfo.CurDrawer}调试结束,切换到下一个抽屉[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
posDebugInfo
.
NextDrawer
();
UpdateMoveInfo
(
posDebugInfo
.
CurDrawer
+
posDebugInfo
.
CurGrid
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
}
break
;
break
;
case
StepEnum
.
SP_25_ToNextDrawer
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_07_MiddleToP3
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:抽屉{posDebugInfo.CurDrawer}调试开始[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
break
;
case
StepEnum
.
SP_25_ToNextGrid
:
case
StepEnum
.
SP_25_ToNextGrid
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_12_DropDrawerToPos
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:到下一料格位置,移栽X轴到料斗库位取放料点P3、料斗拉取进出轴到料斗库位点P3/P5[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
XAxis_To_P3
(
true
);
PullAxis_Inout_To_P3_P5
(
true
);
break
;
case
StepEnum
.
SP_26_ToBufferArea
:
if
(!
CheckInputMiddleAxisInBuff
())
{
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_27_XAxisToBuffer
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:到下暂存区碗里,移栽X轴到进出料暂存区取放点P2,行走机构到进出料机构取放点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
XAxis_To_P2
(
true
);
MoveAxisToP2
(
true
);
}
else
if
(
MoveInfo
.
IsTimeOut
())
{
SetWarnMsg
(
$
"等待上料机构旋转轴离开{MoveInfo.MoveParam.PosInfo.GetPosSide()}面暂存区超时"
);
}
break
;
case
StepEnum
.
SP_27_XAxisToBuffer
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_28_PutReel
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:放料盘,移栽升降轴到下暂存区放料低点P5/P11,移栽压紧轴到压紧前点P2[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
UpdownAxisTo_P5_P11
(
true
);
ComAxis_To_P2
(
true
);
break
;
case
StepEnum
.
SP_28_PutReel
:
MoveInfo
.
NextMoveStep
(
StepEnum
.
SP_29_XAxisBack
);
LogInfo
(
$
"库位调试 {MoveInfo.SLog}:移栽X轴回待机点,库位调试结束[{MoveInfo.MoveParam.PosInfo.GetPosSide()}面]"
);
XAxis_To_P1
(
true
);
break
;
case
StepEnum
.
SP_29_XAxisBack
:
SetBoxStatus
(
DeviceStatus
.
Debugging
,
RunStatus
.
Runing
);
SetBoxStatus
(
DeviceStatus
.
Debugging
,
RunStatus
.
Runing
);
MoveInfo
.
EndMove
();
MoveInfo
.
EndMove
();
break
;
break
;
...
@@ -306,12 +403,22 @@ namespace OnlineStore.DeviceLibrary
...
@@ -306,12 +403,22 @@ namespace OnlineStore.DeviceLibrary
EndRowInDrawer
=
endrow
;
EndRowInDrawer
=
endrow
;
EndColInDrawer
=
endcol
;
EndColInDrawer
=
endcol
;
}
}
public
void
ResetGridParam
()
{
SetGridParam
(
1
,
1
,
4
,
1
);
}
/// <summary>
/// 停止调试
/// </summary>
public
bool
IsBreak
{
get
;
set
;
}
=
false
;
/// <summary>
/// <summary>
/// 是否是最后一个抽屉
/// 是否是最后一个抽屉
/// </summary>
/// </summary>
/// <returns></returns>
/// <returns></returns>
public
bool
IsLastDrawer
()
public
bool
IsLastDrawer
()
{
{
if
(
IsBreak
)
return
true
;
if
(
CurDrawerRow
>=
EndDrawerRow
&&
CurDrawerCol
==
EndDrawerCol
)
if
(
CurDrawerRow
>=
EndDrawerRow
&&
CurDrawerCol
==
EndDrawerCol
)
return
true
;
return
true
;
return
false
;
return
false
;
...
@@ -322,6 +429,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -322,6 +429,8 @@ namespace OnlineStore.DeviceLibrary
/// <returns></returns>
/// <returns></returns>
public
bool
IsLastGrid
()
public
bool
IsLastGrid
()
{
{
if
(
IsBreak
)
return
true
;
if
(
CurColInDrawer
==
EndColInDrawer
&&
CurRowInDrawer
>=
EndRowInDrawer
)
if
(
CurColInDrawer
==
EndColInDrawer
&&
CurRowInDrawer
>=
EndRowInDrawer
)
return
true
;
return
true
;
return
false
;
return
false
;
...
@@ -360,7 +469,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -360,7 +469,7 @@ namespace OnlineStore.DeviceLibrary
else
if
(
CurColInDrawer
==
PreColInDrawer
&&
CurRowInDrawer
>
PreRowInDrawer
)
//不同层,同一列
else
if
(
CurColInDrawer
==
PreColInDrawer
&&
CurRowInDrawer
>
PreRowInDrawer
)
//不同层,同一列
{
{
PreRowInDrawer
=
CurRowInDrawer
;
PreRowInDrawer
=
CurRowInDrawer
;
if
(
CurColInDrawer
==
config
.
Drawer_Columns
)
if
(
CurColInDrawer
==
config
.
Cols_In_Drawer
)
{
{
PreColInDrawer
=
CurColInDrawer
;
PreColInDrawer
=
CurColInDrawer
;
CurColInDrawer
--;
CurColInDrawer
--;
...
@@ -396,7 +505,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -396,7 +505,7 @@ namespace OnlineStore.DeviceLibrary
}
}
}
}
}
}
Common
.
LogUtil
.
info
(
$
"上一料格:{PreRowInDrawer},{PreColInDrawer}
。
当前料格:{CurRowInDrawer},{CurColInDrawer}"
);
Common
.
LogUtil
.
info
(
$
"上一料格:{PreRowInDrawer},{PreColInDrawer}
;
当前料格:{CurRowInDrawer},{CurColInDrawer}"
);
}
}
/// <summary>
/// <summary>
/// 下一个抽屉
/// 下一个抽屉
...
@@ -417,6 +526,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -417,6 +526,7 @@ namespace OnlineStore.DeviceLibrary
else
else
{
{
PreDrawerRow
=
CurDrawerRow
;
PreDrawerRow
=
CurDrawerRow
;
PreDrawerCol
=
CurDrawerCol
;
CurDrawerRow
++;
CurDrawerRow
++;
}
}
}
}
...
@@ -455,6 +565,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -455,6 +565,7 @@ namespace OnlineStore.DeviceLibrary
else
else
{
{
PreDrawerRow
=
CurDrawerRow
;
PreDrawerRow
=
CurDrawerRow
;
PreDrawerCol
=
CurDrawerCol
;
CurDrawerRow
++;
CurDrawerRow
++;
}
}
}
}
...
@@ -467,7 +578,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -467,7 +578,8 @@ namespace OnlineStore.DeviceLibrary
}
}
}
}
}
}
Common
.
LogUtil
.
info
(
$
"上一抽屉:{PreDrawerRow},{PreDrawerCol}。当前抽屉:{CurDrawerRow},{CurDrawerCol}"
);
ResetGridParam
();
Common
.
LogUtil
.
info
(
$
"上一抽屉:{PreDrawerRow},{PreDrawerCol}; 当前抽屉:{CurDrawerRow},{CurDrawerCol}"
);
}
}
}
}
}
}
source/DeviceLibrary/storeBean/boxBean/positionDebug/PositionDebugManager.cs
查看文件 @
67d3757
...
@@ -77,6 +77,27 @@ namespace OnlineStore.DeviceLibrary
...
@@ -77,6 +77,27 @@ namespace OnlineStore.DeviceLibrary
drawerResult
.
ResultCode
=
code
;
drawerResult
.
ResultCode
=
code
;
}
}
/// <summary>
/// <summary>
/// 通过料格结果得出抽屉结果
/// </summary>
public
static
int
SetDrawerResultWithGrid
(
string
drawername
)
{
if
(!
isInit
)
return
-
1
;
DrawerResult
drawerResult
=
DrawerResults
.
Find
(
s
=>
s
.
DrawerName
.
Equals
(
drawername
));
PosDebugResult
posDebugResult
=
drawerResult
.
PosResultList
.
Find
(
s
=>
s
.
ResCode
.
Equals
(
0
)
||
s
.
ResCode
.
Equals
(-
1
));
if
(
posDebugResult
==
null
)
{
drawerResult
.
ResultCode
=
1
;
return
1
;
}
else
{
drawerResult
.
ResultCode
=
0
;
return
0
;
}
}
/// <summary>
/// 设置料格的状态
/// 设置料格的状态
/// </summary>
/// </summary>
/// <param name="drawername">抽屉名</param>
/// <param name="drawername">抽屉名</param>
...
...
source/LoadCVSLibrary/storeConfig/config/BoxEquip_Config.cs
查看文件 @
67d3757
...
@@ -158,7 +158,26 @@ namespace OnlineStore.LoadCSVLibrary
...
@@ -158,7 +158,26 @@ namespace OnlineStore.LoadCSVLibrary
/// </summary>
/// </summary>
[
ConfigProAttribute
(
"Validate_Drawer_Y_Error"
)]
[
ConfigProAttribute
(
"Validate_Drawer_Y_Error"
)]
public
float
Validate_Drawer_Y_Error
{
get
;
set
;
}
public
float
Validate_Drawer_Y_Error
{
get
;
set
;
}
/// <summary>
/// A面抽屉对位Mark面积
/// </summary>
[
ConfigProAttribute
(
"FindPos_Drawer_A_Area"
)]
public
float
FindPos_Drawer_A_Area
{
get
;
set
;
}
/// <summary>
/// A面抽屉验证Mark面积
/// </summary>
[
ConfigProAttribute
(
"Validate_Drawer_A_Area"
)]
public
float
Validate_Drawer_A_Area
{
get
;
set
;
}
/// <summary>
/// B面抽屉对位Mark面积
/// </summary>
[
ConfigProAttribute
(
"FindPos_Drawer_B_Area"
)]
public
float
FindPos_Drawer_B_Area
{
get
;
set
;
}
/// <summary>
/// B面抽屉验证Mark面积
/// </summary>
[
ConfigProAttribute
(
"Validate_Drawer_B_Area"
)]
public
float
Validate_Drawer_B_Area
{
get
;
set
;
}
/// <summary>
/// <summary>
/// 抽屉行间距
/// 抽屉行间距
...
@@ -192,7 +211,7 @@ namespace OnlineStore.LoadCSVLibrary
...
@@ -192,7 +211,7 @@ namespace OnlineStore.LoadCSVLibrary
public
int
Cols_In_Drawer
{
get
;
set
;
}
public
int
Cols_In_Drawer
{
get
;
set
;
}
/// <summary>
/// <summary>
/// 行走机构
视觉对位
速度
/// 行走机构
调试
速度
/// </summary>
/// </summary>
[
ConfigProAttribute
(
"MoveAxis_FindPosSpeed"
)]
[
ConfigProAttribute
(
"MoveAxis_FindPosSpeed"
)]
public
int
MoveAxis_FindPosSpeed
{
get
;
set
;
}
public
int
MoveAxis_FindPosSpeed
{
get
;
set
;
}
...
@@ -208,7 +227,7 @@ namespace OnlineStore.LoadCSVLibrary
...
@@ -208,7 +227,7 @@ namespace OnlineStore.LoadCSVLibrary
public
int
MoveAxis_NegLimit
{
get
;
set
;
}
public
int
MoveAxis_NegLimit
{
get
;
set
;
}
/// <summary>
/// <summary>
/// 升降轴
视觉对位
速度
/// 升降轴
调试
速度
/// </summary>
/// </summary>
[
ConfigProAttribute
(
"UpdownAxis_FindPosSpeed"
)]
[
ConfigProAttribute
(
"UpdownAxis_FindPosSpeed"
)]
public
int
UpdownAxis_FindPosSpeed
{
get
;
set
;
}
public
int
UpdownAxis_FindPosSpeed
{
get
;
set
;
}
...
@@ -223,10 +242,28 @@ namespace OnlineStore.LoadCSVLibrary
...
@@ -223,10 +242,28 @@ namespace OnlineStore.LoadCSVLibrary
[
ConfigProAttribute
(
"UpdownAxis_NegLimit"
)]
[
ConfigProAttribute
(
"UpdownAxis_NegLimit"
)]
public
int
UpdownAxis_NegLimit
{
get
;
set
;
}
public
int
UpdownAxis_NegLimit
{
get
;
set
;
}
/// <summary>
/// <summary>
/// 拉取升降轴
视觉对位
速度
/// 拉取升降轴
调试
速度
/// </summary>
/// </summary>
[
ConfigProAttribute
(
"PullAxis_Updown_FindPosSpeed"
)]
[
ConfigProAttribute
(
"PullAxis_Updown_FindPosSpeed"
)]
public
int
PullAxis_Updown_FindPosSpeed
{
get
;
set
;
}
public
int
PullAxis_Updown_FindPosSpeed
{
get
;
set
;
}
/// <summary>
/// 拉取进出轴调试速度
/// </summary>
[
ConfigProAttribute
(
"PullAxis_InOut_FindPosSpeed"
)]
public
int
PullAxis_InOut_FindPosSpeed
{
get
;
set
;
}
/// <summary>
/// 轴调试速度
/// </summary>
[
ConfigProAttribute
(
"XAxis_FindPosSpeed"
)]
public
int
XAxis_FindPosSpeed
{
get
;
set
;
}
/// <summary>
/// 压紧轴调试速度
/// </summary>
[
ConfigProAttribute
(
"ComAxis_FindPosSpeed"
)]
public
int
ComAxis_FindPosSpeed
{
get
;
set
;
}
/// <summary>
/// <summary>
/// 拉取升降轴正极限位置
/// 拉取升降轴正极限位置
/// </summary>
/// </summary>
...
...
source/XLRStoreClient/XLRStore.csproj
查看文件 @
67d3757
...
@@ -103,6 +103,18 @@
...
@@ -103,6 +103,18 @@
<Compile Include="boxForm\FrmAxisMove.Designer.cs">
<Compile Include="boxForm\FrmAxisMove.Designer.cs">
<DependentUpon>FrmAxisMove.cs</DependentUpon>
<DependentUpon>FrmAxisMove.cs</DependentUpon>
</Compile>
</Compile>
<Compile Include="boxForm\FrmPosDebug.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="boxForm\FrmPosDebug.Designer.cs">
<DependentUpon>FrmPosDebug.cs</DependentUpon>
</Compile>
<Compile Include="boxForm\FrmPosResult.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="boxForm\FrmPosResult.Designer.cs">
<DependentUpon>FrmPosResult.cs</DependentUpon>
</Compile>
<Compile Include="boxForm\FrmTongsLearn.cs">
<Compile Include="boxForm\FrmTongsLearn.cs">
<SubType>Form</SubType>
<SubType>Form</SubType>
</Compile>
</Compile>
...
@@ -208,6 +220,12 @@
...
@@ -208,6 +220,12 @@
<EmbeddedResource Include="boxForm\FrmAxisMove.resx">
<EmbeddedResource Include="boxForm\FrmAxisMove.resx">
<DependentUpon>FrmAxisMove.cs</DependentUpon>
<DependentUpon>FrmAxisMove.cs</DependentUpon>
</EmbeddedResource>
</EmbeddedResource>
<EmbeddedResource Include="boxForm\FrmPosDebug.resx">
<DependentUpon>FrmPosDebug.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="boxForm\FrmPosResult.resx">
<DependentUpon>FrmPosResult.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="boxForm\FrmTongsLearn.resx">
<EmbeddedResource Include="boxForm\FrmTongsLearn.resx">
<DependentUpon>FrmTongsLearn.cs</DependentUpon>
<DependentUpon>FrmTongsLearn.cs</DependentUpon>
</EmbeddedResource>
</EmbeddedResource>
...
...
source/XLRStoreClient/boxForm/FrmBoxEquip.cs
查看文件 @
67d3757
...
@@ -44,7 +44,9 @@ namespace OnlineStore.XLRStore
...
@@ -44,7 +44,9 @@ namespace OnlineStore.XLRStore
FrmAutoFindPos
frmAutoFindPos
=
new
FrmAutoFindPos
();
FrmAutoFindPos
frmAutoFindPos
=
new
FrmAutoFindPos
();
AddForm
(
tabControl1
,
" 视觉对位 "
,
frmAutoFindPos
);
AddForm
(
tabControl1
,
" 视觉对位 "
,
frmAutoFindPos
);
FrmTongsLearn
learn
=
new
FrmTongsLearn
();
FrmTongsLearn
learn
=
new
FrmTongsLearn
();
AddForm
(
tabControl1
,
" 抓手图片训练 "
,
learn
);
AddForm
(
tabControl1
,
" 抓手训练 "
,
learn
);
FrmPosDebug
frmPosDebug
=
new
FrmPosDebug
();
AddForm
(
tabControl1
,
" 库位调试 "
,
frmPosDebug
);
boxBean
.
camera_event
+=
BoxBean_camera_event
;
boxBean
.
camera_event
+=
BoxBean_camera_event
;
IsLoad
=
true
;
IsLoad
=
true
;
}
}
...
...
source/XLRStoreClient/boxForm/FrmPosDebug.Designer.cs
0 → 100644
查看文件 @
67d3757
namespace
OnlineStore.XLRStore
{
partial
class
FrmPosDebug
{
/// <summary>
/// Required designer variable.
/// </summary>
private
System
.
ComponentModel
.
IContainer
components
=
null
;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected
override
void
Dispose
(
bool
disposing
)
{
if
(
disposing
&&
(
components
!=
null
))
{
components
.
Dispose
();
}
base
.
Dispose
(
disposing
);
}
#
region
Windows
Form
Designer
generated
code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private
void
InitializeComponent
()
{
this
.
label1
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
txtStartDrawerRow
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
groupBox1
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
txtEndColInDrawer
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
label5
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
txtEndRowInDrawer
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
label6
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
txtStartColInDrawer
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
label7
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
txtStartRowInDrawer
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
label8
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
txtEndDrawerCol
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
label4
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
txtEndDrawerRow
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
label3
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
txtStartDrawerCol
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
label2
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
groupBox2
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
radioButton2
=
new
System
.
Windows
.
Forms
.
RadioButton
();
this
.
radioButton1
=
new
System
.
Windows
.
Forms
.
RadioButton
();
this
.
btnStart
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnStop
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnPosResult
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
groupBox1
.
SuspendLayout
();
this
.
groupBox2
.
SuspendLayout
();
this
.
SuspendLayout
();
//
// label1
//
this
.
label1
.
AutoSize
=
true
;
this
.
label1
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
36
);
this
.
label1
.
Name
=
"label1"
;
this
.
label1
.
Size
=
new
System
.
Drawing
.
Size
(
77
,
12
);
this
.
label1
.
TabIndex
=
0
;
this
.
label1
.
Text
=
"抽屉开始层:"
;
//
// txtStartDrawerRow
//
this
.
txtStartDrawerRow
.
Location
=
new
System
.
Drawing
.
Point
(
102
,
33
);
this
.
txtStartDrawerRow
.
Name
=
"txtStartDrawerRow"
;
this
.
txtStartDrawerRow
.
Size
=
new
System
.
Drawing
.
Size
(
100
,
21
);
this
.
txtStartDrawerRow
.
TabIndex
=
1
;
this
.
txtStartDrawerRow
.
Text
=
"1"
;
//
// groupBox1
//
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtEndColInDrawer
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label5
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtEndRowInDrawer
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label6
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtStartColInDrawer
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label7
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtStartRowInDrawer
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label8
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtEndDrawerCol
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label4
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtEndDrawerRow
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label3
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtStartDrawerCol
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label2
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
txtStartDrawerRow
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label1
);
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
12
,
12
);
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
228
,
304
);
this
.
groupBox1
.
TabIndex
=
2
;
this
.
groupBox1
.
TabStop
=
false
;
this
.
groupBox1
.
Text
=
"参数设置"
;
//
// txtEndColInDrawer
//
this
.
txtEndColInDrawer
.
Location
=
new
System
.
Drawing
.
Point
(
102
,
268
);
this
.
txtEndColInDrawer
.
Name
=
"txtEndColInDrawer"
;
this
.
txtEndColInDrawer
.
Size
=
new
System
.
Drawing
.
Size
(
100
,
21
);
this
.
txtEndColInDrawer
.
TabIndex
=
15
;
this
.
txtEndColInDrawer
.
Text
=
"1"
;
//
// label5
//
this
.
label5
.
AutoSize
=
true
;
this
.
label5
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
271
);
this
.
label5
.
Name
=
"label5"
;
this
.
label5
.
Size
=
new
System
.
Drawing
.
Size
(
77
,
12
);
this
.
label5
.
TabIndex
=
14
;
this
.
label5
.
Text
=
"库位结束列:"
;
//
// txtEndRowInDrawer
//
this
.
txtEndRowInDrawer
.
Location
=
new
System
.
Drawing
.
Point
(
102
,
235
);
this
.
txtEndRowInDrawer
.
Name
=
"txtEndRowInDrawer"
;
this
.
txtEndRowInDrawer
.
Size
=
new
System
.
Drawing
.
Size
(
100
,
21
);
this
.
txtEndRowInDrawer
.
TabIndex
=
13
;
this
.
txtEndRowInDrawer
.
Text
=
"4"
;
//
// label6
//
this
.
label6
.
AutoSize
=
true
;
this
.
label6
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
238
);
this
.
label6
.
Name
=
"label6"
;
this
.
label6
.
Size
=
new
System
.
Drawing
.
Size
(
77
,
12
);
this
.
label6
.
TabIndex
=
12
;
this
.
label6
.
Text
=
"库位结束行:"
;
//
// txtStartColInDrawer
//
this
.
txtStartColInDrawer
.
Location
=
new
System
.
Drawing
.
Point
(
102
,
199
);
this
.
txtStartColInDrawer
.
Name
=
"txtStartColInDrawer"
;
this
.
txtStartColInDrawer
.
Size
=
new
System
.
Drawing
.
Size
(
100
,
21
);
this
.
txtStartColInDrawer
.
TabIndex
=
11
;
this
.
txtStartColInDrawer
.
Text
=
"1"
;
//
// label7
//
this
.
label7
.
AutoSize
=
true
;
this
.
label7
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
202
);
this
.
label7
.
Name
=
"label7"
;
this
.
label7
.
Size
=
new
System
.
Drawing
.
Size
(
77
,
12
);
this
.
label7
.
TabIndex
=
10
;
this
.
label7
.
Text
=
"库位开始列:"
;
//
// txtStartRowInDrawer
//
this
.
txtStartRowInDrawer
.
Location
=
new
System
.
Drawing
.
Point
(
102
,
167
);
this
.
txtStartRowInDrawer
.
Name
=
"txtStartRowInDrawer"
;
this
.
txtStartRowInDrawer
.
Size
=
new
System
.
Drawing
.
Size
(
100
,
21
);
this
.
txtStartRowInDrawer
.
TabIndex
=
9
;
this
.
txtStartRowInDrawer
.
Text
=
"1"
;
//
// label8
//
this
.
label8
.
AutoSize
=
true
;
this
.
label8
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
170
);
this
.
label8
.
Name
=
"label8"
;
this
.
label8
.
Size
=
new
System
.
Drawing
.
Size
(
77
,
12
);
this
.
label8
.
TabIndex
=
8
;
this
.
label8
.
Text
=
"库位开始行:"
;
//
// txtEndDrawerCol
//
this
.
txtEndDrawerCol
.
Location
=
new
System
.
Drawing
.
Point
(
102
,
134
);
this
.
txtEndDrawerCol
.
Name
=
"txtEndDrawerCol"
;
this
.
txtEndDrawerCol
.
Size
=
new
System
.
Drawing
.
Size
(
100
,
21
);
this
.
txtEndDrawerCol
.
TabIndex
=
7
;
this
.
txtEndDrawerCol
.
Text
=
"6"
;
//
// label4
//
this
.
label4
.
AutoSize
=
true
;
this
.
label4
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
137
);
this
.
label4
.
Name
=
"label4"
;
this
.
label4
.
Size
=
new
System
.
Drawing
.
Size
(
77
,
12
);
this
.
label4
.
TabIndex
=
6
;
this
.
label4
.
Text
=
"抽屉结束列:"
;
//
// txtEndDrawerRow
//
this
.
txtEndDrawerRow
.
Location
=
new
System
.
Drawing
.
Point
(
102
,
101
);
this
.
txtEndDrawerRow
.
Name
=
"txtEndDrawerRow"
;
this
.
txtEndDrawerRow
.
Size
=
new
System
.
Drawing
.
Size
(
100
,
21
);
this
.
txtEndDrawerRow
.
TabIndex
=
5
;
this
.
txtEndDrawerRow
.
Text
=
"15"
;
//
// label3
//
this
.
label3
.
AutoSize
=
true
;
this
.
label3
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
104
);
this
.
label3
.
Name
=
"label3"
;
this
.
label3
.
Size
=
new
System
.
Drawing
.
Size
(
77
,
12
);
this
.
label3
.
TabIndex
=
4
;
this
.
label3
.
Text
=
"抽屉结束层:"
;
//
// txtStartDrawerCol
//
this
.
txtStartDrawerCol
.
Location
=
new
System
.
Drawing
.
Point
(
102
,
65
);
this
.
txtStartDrawerCol
.
Name
=
"txtStartDrawerCol"
;
this
.
txtStartDrawerCol
.
Size
=
new
System
.
Drawing
.
Size
(
100
,
21
);
this
.
txtStartDrawerCol
.
TabIndex
=
3
;
this
.
txtStartDrawerCol
.
Text
=
"1"
;
//
// label2
//
this
.
label2
.
AutoSize
=
true
;
this
.
label2
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
68
);
this
.
label2
.
Name
=
"label2"
;
this
.
label2
.
Size
=
new
System
.
Drawing
.
Size
(
77
,
12
);
this
.
label2
.
TabIndex
=
2
;
this
.
label2
.
Text
=
"抽屉开始列:"
;
//
// groupBox2
//
this
.
groupBox2
.
Controls
.
Add
(
this
.
radioButton2
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
radioButton1
);
this
.
groupBox2
.
Location
=
new
System
.
Drawing
.
Point
(
271
,
12
);
this
.
groupBox2
.
Name
=
"groupBox2"
;
this
.
groupBox2
.
Size
=
new
System
.
Drawing
.
Size
(
128
,
100
);
this
.
groupBox2
.
TabIndex
=
3
;
this
.
groupBox2
.
TabStop
=
false
;
this
.
groupBox2
.
Text
=
"AB面选择"
;
//
// radioButton2
//
this
.
radioButton2
.
AutoSize
=
true
;
this
.
radioButton2
.
Location
=
new
System
.
Drawing
.
Point
(
24
,
64
);
this
.
radioButton2
.
Name
=
"radioButton2"
;
this
.
radioButton2
.
Size
=
new
System
.
Drawing
.
Size
(
41
,
16
);
this
.
radioButton2
.
TabIndex
=
1
;
this
.
radioButton2
.
Text
=
"B面"
;
this
.
radioButton2
.
UseVisualStyleBackColor
=
true
;
this
.
radioButton2
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
radioButton1_CheckedChanged
);
//
// radioButton1
//
this
.
radioButton1
.
AutoSize
=
true
;
this
.
radioButton1
.
Checked
=
true
;
this
.
radioButton1
.
Location
=
new
System
.
Drawing
.
Point
(
24
,
32
);
this
.
radioButton1
.
Name
=
"radioButton1"
;
this
.
radioButton1
.
Size
=
new
System
.
Drawing
.
Size
(
41
,
16
);
this
.
radioButton1
.
TabIndex
=
0
;
this
.
radioButton1
.
TabStop
=
true
;
this
.
radioButton1
.
Text
=
"A面"
;
this
.
radioButton1
.
UseVisualStyleBackColor
=
true
;
this
.
radioButton1
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
radioButton1_CheckedChanged
);
//
// btnStart
//
this
.
btnStart
.
Location
=
new
System
.
Drawing
.
Point
(
417
,
24
);
this
.
btnStart
.
Name
=
"btnStart"
;
this
.
btnStart
.
Size
=
new
System
.
Drawing
.
Size
(
137
,
60
);
this
.
btnStart
.
TabIndex
=
4
;
this
.
btnStart
.
Text
=
"开始"
;
this
.
btnStart
.
UseVisualStyleBackColor
=
true
;
this
.
btnStart
.
Click
+=
new
System
.
EventHandler
(
this
.
btnStart_Click
);
//
// btnStop
//
this
.
btnStop
.
Location
=
new
System
.
Drawing
.
Point
(
597
,
24
);
this
.
btnStop
.
Name
=
"btnStop"
;
this
.
btnStop
.
Size
=
new
System
.
Drawing
.
Size
(
137
,
60
);
this
.
btnStop
.
TabIndex
=
5
;
this
.
btnStop
.
Text
=
"结束"
;
this
.
btnStop
.
UseVisualStyleBackColor
=
true
;
this
.
btnStop
.
Click
+=
new
System
.
EventHandler
(
this
.
btnStop_Click
);
//
// btnPosResult
//
this
.
btnPosResult
.
Location
=
new
System
.
Drawing
.
Point
(
417
,
140
);
this
.
btnPosResult
.
Name
=
"btnPosResult"
;
this
.
btnPosResult
.
Size
=
new
System
.
Drawing
.
Size
(
137
,
60
);
this
.
btnPosResult
.
TabIndex
=
6
;
this
.
btnPosResult
.
Text
=
"库位状态"
;
this
.
btnPosResult
.
UseVisualStyleBackColor
=
true
;
this
.
btnPosResult
.
Click
+=
new
System
.
EventHandler
(
this
.
btnPosResult_Click
);
//
// FrmPosDebug
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
6F
,
12F
);
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
ClientSize
=
new
System
.
Drawing
.
Size
(
800
,
354
);
this
.
Controls
.
Add
(
this
.
btnPosResult
);
this
.
Controls
.
Add
(
this
.
btnStop
);
this
.
Controls
.
Add
(
this
.
btnStart
);
this
.
Controls
.
Add
(
this
.
groupBox2
);
this
.
Controls
.
Add
(
this
.
groupBox1
);
this
.
Name
=
"FrmPosDebug"
;
this
.
Text
=
"FrmPosDebug"
;
this
.
groupBox1
.
ResumeLayout
(
false
);
this
.
groupBox1
.
PerformLayout
();
this
.
groupBox2
.
ResumeLayout
(
false
);
this
.
groupBox2
.
PerformLayout
();
this
.
ResumeLayout
(
false
);
}
#
endregion
private
System
.
Windows
.
Forms
.
Label
label1
;
private
System
.
Windows
.
Forms
.
TextBox
txtStartDrawerRow
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox1
;
private
System
.
Windows
.
Forms
.
TextBox
txtEndColInDrawer
;
private
System
.
Windows
.
Forms
.
Label
label5
;
private
System
.
Windows
.
Forms
.
TextBox
txtEndRowInDrawer
;
private
System
.
Windows
.
Forms
.
Label
label6
;
private
System
.
Windows
.
Forms
.
TextBox
txtStartColInDrawer
;
private
System
.
Windows
.
Forms
.
Label
label7
;
private
System
.
Windows
.
Forms
.
TextBox
txtStartRowInDrawer
;
private
System
.
Windows
.
Forms
.
Label
label8
;
private
System
.
Windows
.
Forms
.
TextBox
txtEndDrawerCol
;
private
System
.
Windows
.
Forms
.
Label
label4
;
private
System
.
Windows
.
Forms
.
TextBox
txtEndDrawerRow
;
private
System
.
Windows
.
Forms
.
Label
label3
;
private
System
.
Windows
.
Forms
.
TextBox
txtStartDrawerCol
;
private
System
.
Windows
.
Forms
.
Label
label2
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox2
;
private
System
.
Windows
.
Forms
.
RadioButton
radioButton2
;
private
System
.
Windows
.
Forms
.
RadioButton
radioButton1
;
private
System
.
Windows
.
Forms
.
Button
btnStart
;
private
System
.
Windows
.
Forms
.
Button
btnStop
;
private
System
.
Windows
.
Forms
.
Button
btnPosResult
;
}
}
\ No newline at end of file
\ No newline at end of file
source/XLRStoreClient/boxForm/FrmPosDebug.cs
0 → 100644
查看文件 @
67d3757
using
OnlineStore.DeviceLibrary
;
using
System
;
using
System.Collections.Generic
;
using
System.ComponentModel
;
using
System.Data
;
using
System.Drawing
;
using
System.Linq
;
using
System.Text
;
using
System.Threading.Tasks
;
using
System.Windows.Forms
;
namespace
OnlineStore.XLRStore
{
public
partial
class
FrmPosDebug
:
Form
{
public
FrmPosDebug
()
{
CheckForIllegalCrossThreadCalls
=
false
;
InitializeComponent
();
boxEquip
=
StoreManager
.
XLRStore
.
boxEquip
;
}
BoxEquip
boxEquip
;
private
void
btnStart_Click
(
object
sender
,
EventArgs
e
)
{
if
(
MessageBox
.
Show
(
"是否开始库位调试?"
,
"提示"
,
MessageBoxButtons
.
OKCancel
).
Equals
(
MessageBoxButtons
.
OK
))
{
boxEquip
.
posDebugInfo
.
IsBreak
=
false
;
int
startDrawerRow
=
int
.
Parse
(
txtStartDrawerRow
.
Text
);
int
startDrawerCol
=
int
.
Parse
(
txtStartDrawerCol
.
Text
);
int
endDrawerRow
=
int
.
Parse
(
txtEndDrawerRow
.
Text
);
int
endDrawerCol
=
int
.
Parse
(
txtEndDrawerCol
.
Text
);
int
startRowInDrawer
=
int
.
Parse
(
txtStartRowInDrawer
.
Text
);
int
startColInDrawer
=
int
.
Parse
(
txtStartColInDrawer
.
Text
);
int
endRowInDrawer
=
int
.
Parse
(
txtEndRowInDrawer
.
Text
);
int
endColInDrawer
=
int
.
Parse
(
txtEndColInDrawer
.
Text
);
boxEquip
.
posDebugInfo
.
SetDrawerParam
(
startDrawerRow
,
startDrawerCol
,
endDrawerRow
,
endDrawerCol
);
boxEquip
.
posDebugInfo
.
SetGridParam
(
startRowInDrawer
,
startColInDrawer
,
endRowInDrawer
,
endColInDrawer
);
}
}
private
void
radioButton1_CheckedChanged
(
object
sender
,
EventArgs
e
)
{
if
(
radioButton1
.
Checked
)
{
boxEquip
.
posDebugInfo
.
PosSide
=
"AA"
;
}
if
(
radioButton2
.
Checked
)
boxEquip
.
posDebugInfo
.
PosSide
=
"BB"
;
}
private
void
btnStop_Click
(
object
sender
,
EventArgs
e
)
{
if
(
MessageBox
.
Show
(
"确认停止库位调试?"
,
"提示"
,
MessageBoxButtons
.
OKCancel
).
Equals
(
MessageBoxButtons
.
OK
))
boxEquip
.
posDebugInfo
.
IsBreak
=
true
;
}
FrmPosResult
frmPosResult
=
null
;
private
void
btnPosResult_Click
(
object
sender
,
EventArgs
e
)
{
if
(
frmPosResult
==
null
)
{
frmPosResult
=
new
FrmPosResult
();
frmPosResult
.
Show
();
}
else
{
if
(
frmPosResult
.
IsDisposed
)
{
frmPosResult
=
new
FrmPosResult
();
frmPosResult
.
Show
();
}
else
{
frmPosResult
.
Activate
();
}
}
}
}
}
source/XLRStoreClient/boxForm/FrmPosDebug.resx
0 → 100644
查看文件 @
67d3757
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
\ No newline at end of file
\ No newline at end of file
source/XLRStoreClient/boxForm/FrmPosResult.Designer.cs
0 → 100644
查看文件 @
67d3757
namespace
OnlineStore.XLRStore
{
partial
class
FrmPosResult
{
/// <summary>
/// Required designer variable.
/// </summary>
private
System
.
ComponentModel
.
IContainer
components
=
null
;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected
override
void
Dispose
(
bool
disposing
)
{
if
(
disposing
&&
(
components
!=
null
))
{
components
.
Dispose
();
}
base
.
Dispose
(
disposing
);
}
#
region
Windows
Form
Designer
generated
code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private
void
InitializeComponent
()
{
this
.
tableLayoutPanel1
=
new
System
.
Windows
.
Forms
.
TableLayoutPanel
();
this
.
groupBox2
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
tlpPos
=
new
System
.
Windows
.
Forms
.
TableLayoutPanel
();
this
.
groupBox1
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
tabControl1
=
new
System
.
Windows
.
Forms
.
TabControl
();
this
.
tabPage1
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
tlpDrawerA
=
new
System
.
Windows
.
Forms
.
TableLayoutPanel
();
this
.
tabPage2
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
tlpDrawerB
=
new
System
.
Windows
.
Forms
.
TableLayoutPanel
();
this
.
tableLayoutPanel1
.
SuspendLayout
();
this
.
groupBox2
.
SuspendLayout
();
this
.
groupBox1
.
SuspendLayout
();
this
.
tabControl1
.
SuspendLayout
();
this
.
tabPage1
.
SuspendLayout
();
this
.
tabPage2
.
SuspendLayout
();
this
.
SuspendLayout
();
//
// tableLayoutPanel1
//
this
.
tableLayoutPanel1
.
ColumnCount
=
2
;
this
.
tableLayoutPanel1
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
57.86853F
));
this
.
tableLayoutPanel1
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
42.13147F
));
this
.
tableLayoutPanel1
.
Controls
.
Add
(
this
.
groupBox2
,
1
,
0
);
this
.
tableLayoutPanel1
.
Controls
.
Add
(
this
.
groupBox1
,
0
,
0
);
this
.
tableLayoutPanel1
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
tableLayoutPanel1
.
Location
=
new
System
.
Drawing
.
Point
(
0
,
0
);
this
.
tableLayoutPanel1
.
Name
=
"tableLayoutPanel1"
;
this
.
tableLayoutPanel1
.
RowCount
=
1
;
this
.
tableLayoutPanel1
.
RowStyles
.
Add
(
new
System
.
Windows
.
Forms
.
RowStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
100F
));
this
.
tableLayoutPanel1
.
RowStyles
.
Add
(
new
System
.
Windows
.
Forms
.
RowStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Absolute
,
20F
));
this
.
tableLayoutPanel1
.
Size
=
new
System
.
Drawing
.
Size
(
1004
,
721
);
this
.
tableLayoutPanel1
.
TabIndex
=
0
;
//
// groupBox2
//
this
.
groupBox2
.
Controls
.
Add
(
this
.
tlpPos
);
this
.
groupBox2
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
groupBox2
.
Location
=
new
System
.
Drawing
.
Point
(
584
,
3
);
this
.
groupBox2
.
Name
=
"groupBox2"
;
this
.
groupBox2
.
Size
=
new
System
.
Drawing
.
Size
(
417
,
715
);
this
.
groupBox2
.
TabIndex
=
1
;
this
.
groupBox2
.
TabStop
=
false
;
this
.
groupBox2
.
Text
=
"库位结果"
;
//
// tlpPos
//
this
.
tlpPos
.
ColumnCount
=
1
;
this
.
tlpPos
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
50F
));
this
.
tlpPos
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
tlpPos
.
Location
=
new
System
.
Drawing
.
Point
(
3
,
17
);
this
.
tlpPos
.
Name
=
"tlpPos"
;
this
.
tlpPos
.
RowCount
=
1
;
this
.
tlpPos
.
RowStyles
.
Add
(
new
System
.
Windows
.
Forms
.
RowStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
50F
));
this
.
tlpPos
.
Size
=
new
System
.
Drawing
.
Size
(
411
,
695
);
this
.
tlpPos
.
TabIndex
=
1
;
//
// groupBox1
//
this
.
groupBox1
.
Controls
.
Add
(
this
.
tabControl1
);
this
.
groupBox1
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
3
,
3
);
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
575
,
715
);
this
.
groupBox1
.
TabIndex
=
0
;
this
.
groupBox1
.
TabStop
=
false
;
this
.
groupBox1
.
Text
=
"抽屉结果"
;
//
// tabControl1
//
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage1
);
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage2
);
this
.
tabControl1
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
tabControl1
.
Location
=
new
System
.
Drawing
.
Point
(
3
,
17
);
this
.
tabControl1
.
Name
=
"tabControl1"
;
this
.
tabControl1
.
SelectedIndex
=
0
;
this
.
tabControl1
.
Size
=
new
System
.
Drawing
.
Size
(
569
,
695
);
this
.
tabControl1
.
TabIndex
=
1
;
//
// tabPage1
//
this
.
tabPage1
.
Controls
.
Add
(
this
.
tlpDrawerA
);
this
.
tabPage1
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
22
);
this
.
tabPage1
.
Name
=
"tabPage1"
;
this
.
tabPage1
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage1
.
Size
=
new
System
.
Drawing
.
Size
(
561
,
669
);
this
.
tabPage1
.
TabIndex
=
0
;
this
.
tabPage1
.
Text
=
"A面"
;
this
.
tabPage1
.
UseVisualStyleBackColor
=
true
;
//
// tlpDrawerA
//
this
.
tlpDrawerA
.
ColumnCount
=
1
;
this
.
tlpDrawerA
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
50F
));
this
.
tlpDrawerA
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
tlpDrawerA
.
Location
=
new
System
.
Drawing
.
Point
(
3
,
3
);
this
.
tlpDrawerA
.
Name
=
"tlpDrawerA"
;
this
.
tlpDrawerA
.
RowCount
=
1
;
this
.
tlpDrawerA
.
RowStyles
.
Add
(
new
System
.
Windows
.
Forms
.
RowStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
50F
));
this
.
tlpDrawerA
.
Size
=
new
System
.
Drawing
.
Size
(
555
,
663
);
this
.
tlpDrawerA
.
TabIndex
=
0
;
//
// tabPage2
//
this
.
tabPage2
.
Controls
.
Add
(
this
.
tlpDrawerB
);
this
.
tabPage2
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
22
);
this
.
tabPage2
.
Name
=
"tabPage2"
;
this
.
tabPage2
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage2
.
Size
=
new
System
.
Drawing
.
Size
(
561
,
669
);
this
.
tabPage2
.
TabIndex
=
1
;
this
.
tabPage2
.
Text
=
"B面"
;
this
.
tabPage2
.
UseVisualStyleBackColor
=
true
;
//
// tlpDrawerB
//
this
.
tlpDrawerB
.
ColumnCount
=
1
;
this
.
tlpDrawerB
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
50F
));
this
.
tlpDrawerB
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
tlpDrawerB
.
Location
=
new
System
.
Drawing
.
Point
(
3
,
3
);
this
.
tlpDrawerB
.
Name
=
"tlpDrawerB"
;
this
.
tlpDrawerB
.
RowCount
=
1
;
this
.
tlpDrawerB
.
RowStyles
.
Add
(
new
System
.
Windows
.
Forms
.
RowStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
50F
));
this
.
tlpDrawerB
.
Size
=
new
System
.
Drawing
.
Size
(
555
,
663
);
this
.
tlpDrawerB
.
TabIndex
=
1
;
//
// FrmPosResult
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
6F
,
12F
);
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
ClientSize
=
new
System
.
Drawing
.
Size
(
1004
,
721
);
this
.
Controls
.
Add
(
this
.
tableLayoutPanel1
);
this
.
MaximizeBox
=
false
;
this
.
Name
=
"FrmPosResult"
;
this
.
Text
=
"库位结果"
;
this
.
tableLayoutPanel1
.
ResumeLayout
(
false
);
this
.
groupBox2
.
ResumeLayout
(
false
);
this
.
groupBox1
.
ResumeLayout
(
false
);
this
.
tabControl1
.
ResumeLayout
(
false
);
this
.
tabPage1
.
ResumeLayout
(
false
);
this
.
tabPage2
.
ResumeLayout
(
false
);
this
.
ResumeLayout
(
false
);
}
#
endregion
private
System
.
Windows
.
Forms
.
TableLayoutPanel
tableLayoutPanel1
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox2
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox1
;
private
System
.
Windows
.
Forms
.
TableLayoutPanel
tlpPos
;
private
System
.
Windows
.
Forms
.
TableLayoutPanel
tlpDrawerA
;
private
System
.
Windows
.
Forms
.
TabControl
tabControl1
;
private
System
.
Windows
.
Forms
.
TabPage
tabPage1
;
private
System
.
Windows
.
Forms
.
TabPage
tabPage2
;
private
System
.
Windows
.
Forms
.
TableLayoutPanel
tlpDrawerB
;
}
}
\ No newline at end of file
\ No newline at end of file
source/XLRStoreClient/boxForm/FrmPosResult.cs
0 → 100644
查看文件 @
67d3757
using
OnlineStore.DeviceLibrary
;
using
System
;
using
System.Collections.Generic
;
using
System.ComponentModel
;
using
System.Data
;
using
System.Drawing
;
using
System.Linq
;
using
System.Text
;
using
System.Threading.Tasks
;
using
System.Windows.Forms
;
namespace
OnlineStore.XLRStore
{
public
partial
class
FrmPosResult
:
Form
{
public
FrmPosResult
()
{
boxEquip
=
StoreManager
.
XLRStore
.
boxEquip
;
DrawerResults
=
PosDebugResultManager
.
DrawerResults
;
InitializeComponent
();
LoadDrawerList
();
}
List
<
DrawerResult
>
DrawerResults
;
BoxEquip
boxEquip
;
protected
Dictionary
<
string
,
UCStatusPanel
>
DrawerControlList
=
new
Dictionary
<
string
,
UCStatusPanel
>();
private
void
LoadDrawerList
()
{
this
.
tlpDrawerA
.
RowStyles
.
Clear
();
this
.
tlpDrawerA
.
ColumnStyles
.
Clear
();
this
.
tlpDrawerA
.
RowCount
=
boxEquip
.
Config
.
Drawer_Rows
;
this
.
tlpDrawerA
.
ColumnCount
=
boxEquip
.
Config
.
Drawer_Columns
;
string
cid
=
boxEquip
.
Config
.
CID
;
for
(
int
rowindex
=
0
;
rowindex
<
boxEquip
.
Config
.
Drawer_Rows
;
rowindex
++)
{
tlpDrawerA
.
RowStyles
.
Add
(
new
RowStyle
(
SizeType
.
Absolute
,
38
));
for
(
int
colindex
=
0
;
colindex
<
boxEquip
.
Config
.
Drawer_Columns
;
colindex
++)
{
tlpDrawerA
.
ColumnStyles
.
Add
(
new
ColumnStyle
(
SizeType
.
Absolute
,
87
));
UCStatusPanel
control
=
new
UCStatusPanel
();
control
.
ControlName
=
$
"{cid}AA{(rowindex+1).ToString("
00
")}{(colindex+1).ToString("
00
")}"
;
control
.
Click
+=
Control_Click
;
this
.
tlpDrawerA
.
Controls
.
Add
(
control
,
colindex
,
rowindex
);
DrawerControlList
.
Add
(
control
.
ControlName
,
control
);
}
}
this
.
tlpDrawerB
.
RowStyles
.
Clear
();
this
.
tlpDrawerB
.
ColumnStyles
.
Clear
();
this
.
tlpDrawerB
.
RowCount
=
boxEquip
.
Config
.
Drawer_Rows
;
this
.
tlpDrawerB
.
ColumnCount
=
boxEquip
.
Config
.
Drawer_Columns
;
for
(
int
rowindex
=
0
;
rowindex
<
boxEquip
.
Config
.
Drawer_Rows
;
rowindex
++)
{
tlpDrawerB
.
RowStyles
.
Add
(
new
RowStyle
(
SizeType
.
Absolute
,
38
));
for
(
int
colindex
=
0
;
colindex
<
boxEquip
.
Config
.
Drawer_Columns
;
colindex
++)
{
tlpDrawerB
.
ColumnStyles
.
Add
(
new
ColumnStyle
(
SizeType
.
Absolute
,
87
));
UCStatusPanel
control
=
new
UCStatusPanel
();
control
.
ControlName
=
$
"{cid}BB{(rowindex+1).ToString("
00
")}{(colindex+1).ToString("
00
")}"
;
control
.
Click
+=
Control_Click
;
this
.
tlpDrawerB
.
Controls
.
Add
(
control
,
colindex
,
rowindex
);
DrawerControlList
.
Add
(
control
.
ControlName
,
control
);
}
}
this
.
tlpPos
.
RowStyles
.
Clear
();
this
.
tlpPos
.
ColumnStyles
.
Clear
();
this
.
tlpPos
.
AutoScroll
=
true
;
this
.
tlpPos
.
RowCount
=
boxEquip
.
Config
.
Cols_In_Drawer
;
this
.
tlpPos
.
ColumnCount
=
boxEquip
.
Config
.
Rows_In_Drawer
;
for
(
int
rowindex
=
0
;
rowindex
<
boxEquip
.
Config
.
Cols_In_Drawer
;
rowindex
++)
{
tlpPos
.
RowStyles
.
Add
(
new
RowStyle
(
SizeType
.
Absolute
,
38
));
for
(
int
colindex
=
0
;
colindex
<
boxEquip
.
Config
.
Rows_In_Drawer
;
colindex
++)
{
tlpPos
.
ColumnStyles
.
Add
(
new
ColumnStyle
(
SizeType
.
Absolute
,
87
));
UCStatusPanel
control
=
new
UCStatusPanel
();
control
.
ControlName
=
$
"{(colindex+1).ToString("
00
")}{(rowindex+1).ToString("
00
")}"
;
this
.
tlpPos
.
Controls
.
Add
(
control
,
colindex
,
rowindex
);
}
}
this
.
SuspendLayout
();
}
private
void
Control_Click
(
object
sender
,
EventArgs
e
)
{
throw
new
NotImplementedException
();
}
}
}
source/XLRStoreClient/boxForm/FrmPosResult.resx
0 → 100644
查看文件 @
67d3757
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
\ No newline at end of file
\ No newline at end of file
source/XLRStoreClient/boxForm/userControl/UCStatusPanel.Designer.cs
查看文件 @
67d3757
namespace
OnlineStore.XLRStore
.boxForm.userControl
namespace
OnlineStore.XLRStore
{
{
partial
class
UCStatusPanel
partial
class
UCStatusPanel
{
{
...
@@ -38,18 +38,19 @@ namespace OnlineStore.XLRStore.boxForm.userControl
...
@@ -38,18 +38,19 @@ namespace OnlineStore.XLRStore.boxForm.userControl
this
.
lblStatus
.
Font
=
new
System
.
Drawing
.
Font
(
"宋体"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Bold
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblStatus
.
Font
=
new
System
.
Drawing
.
Font
(
"宋体"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Bold
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblStatus
.
Location
=
new
System
.
Drawing
.
Point
(
0
,
0
);
this
.
lblStatus
.
Location
=
new
System
.
Drawing
.
Point
(
0
,
0
);
this
.
lblStatus
.
Name
=
"lblStatus"
;
this
.
lblStatus
.
Name
=
"lblStatus"
;
this
.
lblStatus
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
38
);
this
.
lblStatus
.
Size
=
new
System
.
Drawing
.
Size
(
87
,
38
);
this
.
lblStatus
.
TabIndex
=
0
;
this
.
lblStatus
.
TabIndex
=
0
;
this
.
lblStatus
.
Text
=
"05BB0101
0101
"
;
this
.
lblStatus
.
Text
=
"05BB0101"
;
this
.
lblStatus
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
this
.
lblStatus
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
//
//
// UCStatusPanel
// UCStatusPanel
//
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
6F
,
12F
);
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
6F
,
12F
);
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
BackColor
=
System
.
Drawing
.
Color
.
FromArgb
(((
int
)(((
byte
)(
255
)))),
((
int
)(((
byte
)(
255
)))),
((
int
)(((
byte
)(
192
)))));
this
.
Controls
.
Add
(
this
.
lblStatus
);
this
.
Controls
.
Add
(
this
.
lblStatus
);
this
.
Name
=
"UCStatusPanel"
;
this
.
Name
=
"UCStatusPanel"
;
this
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
38
);
this
.
Size
=
new
System
.
Drawing
.
Size
(
87
,
38
);
this
.
ResumeLayout
(
false
);
this
.
ResumeLayout
(
false
);
}
}
...
...
source/XLRStoreClient/boxForm/userControl/UCStatusPanel.cs
查看文件 @
67d3757
...
@@ -8,7 +8,7 @@ using System.Text;
...
@@ -8,7 +8,7 @@ using System.Text;
using
System.Threading.Tasks
;
using
System.Threading.Tasks
;
using
System.Windows.Forms
;
using
System.Windows.Forms
;
namespace
OnlineStore.XLRStore
.boxForm.userControl
namespace
OnlineStore.XLRStore
{
{
public
partial
class
UCStatusPanel
:
UserControl
public
partial
class
UCStatusPanel
:
UserControl
{
{
...
@@ -16,5 +16,24 @@ namespace OnlineStore.XLRStore.boxForm.userControl
...
@@ -16,5 +16,24 @@ namespace OnlineStore.XLRStore.boxForm.userControl
{
{
InitializeComponent
();
InitializeComponent
();
}
}
private
string
ctlName
=
""
;
public
string
ControlName
{
get
{
return
ctlName
;
}
set
{
ctlName
=
value
;
lblStatus
.
Text
=
value
;
}
}
public
int
ResultCode
{
get
;
set
;
}
public
void
ShowResult
()
{
switch
(
ResultCode
)
{
case
-
1
:
this
.
BackColor
=
Color
.
FromArgb
(
255
,
255
,
192
);
break
;
case
0
:
this
.
BackColor
=
Color
.
Red
;
break
;
case
1
:
this
.
BackColor
=
Color
.
GreenYellow
;
break
;
}
}
}
}
}
}
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论