Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
李娜
/
SO664-HCSingleStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 561a9965
由
张东亮
编写于
2020-11-05 17:22:27 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
添加自动跑位功能
1 个父辈
ebbe3f07
隐藏空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
1685 行增加
和
70 行删除
source/HCSingleStore/App.config
source/HCSingleStore/FrmBox.Designer.cs
source/HCSingleStore/FrmBox.cs
source/HCSingleStore/FrmInOutStore.Designer.cs
source/HCSingleStore/FrmInOutStore.cs
source/HCSingleStore/FrmInOutStore.resx
source/HCSingleStore/HCSingleStore.csproj
source/HuichuanLibrary/HuichuanLibrary.csproj
source/HCSingleStore/App.config
查看文件 @
561a996
...
...
@@ -57,6 +57,20 @@
<
conversionPattern
value
=
"[%date][%t]%-5p %m%n"
/>
</
layout
>
</
appender
>
<
appender
name
=
"InOutStore"
type
=
"log4net.Appender.RollingFileAppender"
>
<
file
type
=
"log4net.Util.PatternString"
value
=
"logs/InOutStore-%property{fname}.log"
/>
<
param
name
=
"Encoding"
value
=
"UTF-8"
/>
<
appendToFile
value
=
"true"
/>
<
rollingStyle
value
=
"Date"
/>
<
datePattern
value
=
"yyyy-MM-dd"
/>
<
layout
type
=
"log4net.Layout.PatternLayout"
>
<
conversionPattern
value
=
"[%date][%t]%-5p %m%n"
/>
</
layout
>
</
appender
>
<
logger
name
=
"InOutStore"
>
<
level
value
=
"Info"
/>
<
appender
-
ref
ref
=
"InOutStore"
/>
</
logger
>
<
root
>
<
level
value
=
"Info"
/>
<
appender
-
ref
ref
=
"RollingLogFileAppender"
/>
...
...
source/HCSingleStore/FrmBox.Designer.cs
查看文件 @
561a996
...
...
@@ -69,6 +69,7 @@
this
.
btnCloseD
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
axisMoveControl1
=
new
OnlineStore
.
AutoCountClient
.
AxisMoveControl
();
this
.
groupInout
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
btnInOutTest
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
lblAutoMsg
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
btnStartAuTo
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
label9
=
new
System
.
Windows
.
Forms
.
Label
();
...
...
@@ -153,7 +154,7 @@
this
.
chbDebug
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
12F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
chbDebug
.
Location
=
new
System
.
Drawing
.
Point
(
299
,
20
);
this
.
chbDebug
.
Name
=
"chbDebug"
;
this
.
chbDebug
.
Size
=
new
System
.
Drawing
.
Size
(
93
,
25
);
this
.
chbDebug
.
Size
=
new
System
.
Drawing
.
Size
(
114
,
31
);
this
.
chbDebug
.
TabIndex
=
271
;
this
.
chbDebug
.
Text
=
"调试状态"
;
this
.
chbDebug
.
UseVisualStyleBackColor
=
true
;
...
...
@@ -260,9 +261,9 @@
this
.
tabPage2
.
Controls
.
Add
(
this
.
btnStoreStop
);
this
.
tabPage2
.
Controls
.
Add
(
this
.
chbDebug
);
this
.
tabPage2
.
Controls
.
Add
(
this
.
lblWarnMsg
);
this
.
tabPage2
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage2
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
32
);
this
.
tabPage2
.
Name
=
"tabPage2"
;
this
.
tabPage2
.
Size
=
new
System
.
Drawing
.
Size
(
1091
,
60
7
);
this
.
tabPage2
.
Size
=
new
System
.
Drawing
.
Size
(
1091
,
60
4
);
this
.
tabPage2
.
TabIndex
=
3
;
this
.
tabPage2
.
Text
=
" 设备状态 "
;
this
.
tabPage2
.
UseVisualStyleBackColor
=
true
;
...
...
@@ -274,7 +275,7 @@
this
.
lblMoveStr
.
ForeColor
=
System
.
Drawing
.
Color
.
Black
;
this
.
lblMoveStr
.
Location
=
new
System
.
Drawing
.
Point
(
834
,
76
);
this
.
lblMoveStr
.
Name
=
"lblMoveStr"
;
this
.
lblMoveStr
.
Size
=
new
System
.
Drawing
.
Size
(
56
,
17
);
this
.
lblMoveStr
.
Size
=
new
System
.
Drawing
.
Size
(
69
,
20
);
this
.
lblMoveStr
.
TabIndex
=
277
;
this
.
lblMoveStr
.
Text
=
"等待启动"
;
this
.
lblMoveStr
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -302,7 +303,7 @@
this
.
groupBox1
.
Controls
.
Add
(
this
.
label43
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
label42
);
this
.
groupBox1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
11
,
4
40
);
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
11
,
4
31
);
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
476
,
136
);
this
.
groupBox1
.
TabIndex
=
217
;
...
...
@@ -314,7 +315,7 @@
this
.
txt4Target
.
Location
=
new
System
.
Drawing
.
Point
(
377
,
103
);
this
.
txt4Target
.
Name
=
"txt4Target"
;
this
.
txt4Target
.
ReadOnly
=
true
;
this
.
txt4Target
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
txt4Target
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
txt4Target
.
TabIndex
=
270
;
//
// lblTargetP4
...
...
@@ -322,7 +323,7 @@
this
.
lblTargetP4
.
Location
=
new
System
.
Drawing
.
Point
(
377
,
75
);
this
.
lblTargetP4
.
Name
=
"lblTargetP4"
;
this
.
lblTargetP4
.
ReadOnly
=
true
;
this
.
lblTargetP4
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
lblTargetP4
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
lblTargetP4
.
TabIndex
=
269
;
//
// lblActual4
...
...
@@ -330,7 +331,7 @@
this
.
lblActual4
.
Location
=
new
System
.
Drawing
.
Point
(
377
,
47
);
this
.
lblActual4
.
Name
=
"lblActual4"
;
this
.
lblActual4
.
ReadOnly
=
true
;
this
.
lblActual4
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
lblActual4
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
lblActual4
.
TabIndex
=
268
;
//
// label7
...
...
@@ -339,7 +340,7 @@
this
.
label7
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label7
.
Location
=
new
System
.
Drawing
.
Point
(
384
,
20
);
this
.
label7
.
Name
=
"label7"
;
this
.
label7
.
Size
=
new
System
.
Drawing
.
Size
(
71
,
17
);
this
.
label7
.
Size
=
new
System
.
Drawing
.
Size
(
88
,
20
);
this
.
label7
.
TabIndex
=
267
;
this
.
label7
.
Text
=
"轴四:压紧轴"
;
//
...
...
@@ -348,7 +349,7 @@
this
.
txtMiddleTarget
.
Location
=
new
System
.
Drawing
.
Point
(
105
,
104
);
this
.
txtMiddleTarget
.
Name
=
"txtMiddleTarget"
;
this
.
txtMiddleTarget
.
ReadOnly
=
true
;
this
.
txtMiddleTarget
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
txtMiddleTarget
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
txtMiddleTarget
.
TabIndex
=
262
;
//
// txtInoutTarget
...
...
@@ -356,7 +357,7 @@
this
.
txtInoutTarget
.
Location
=
new
System
.
Drawing
.
Point
(
287
,
104
);
this
.
txtInoutTarget
.
Name
=
"txtInoutTarget"
;
this
.
txtInoutTarget
.
ReadOnly
=
true
;
this
.
txtInoutTarget
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
txtInoutTarget
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
txtInoutTarget
.
TabIndex
=
260
;
//
// txtUpdownTarget
...
...
@@ -364,7 +365,7 @@
this
.
txtUpdownTarget
.
Location
=
new
System
.
Drawing
.
Point
(
195
,
104
);
this
.
txtUpdownTarget
.
Name
=
"txtUpdownTarget"
;
this
.
txtUpdownTarget
.
ReadOnly
=
true
;
this
.
txtUpdownTarget
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
txtUpdownTarget
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
txtUpdownTarget
.
TabIndex
=
259
;
//
// label12
...
...
@@ -373,7 +374,7 @@
this
.
label12
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label12
.
Location
=
new
System
.
Drawing
.
Point
(
17
,
106
);
this
.
label12
.
Name
=
"label12"
;
this
.
label12
.
Size
=
new
System
.
Drawing
.
Size
(
83
,
17
);
this
.
label12
.
Size
=
new
System
.
Drawing
.
Size
(
103
,
20
);
this
.
label12
.
TabIndex
=
258
;
this
.
label12
.
Text
=
"出入库目标值:"
;
//
...
...
@@ -382,7 +383,7 @@
this
.
lblTargetP1
.
Location
=
new
System
.
Drawing
.
Point
(
105
,
76
);
this
.
lblTargetP1
.
Name
=
"lblTargetP1"
;
this
.
lblTargetP1
.
ReadOnly
=
true
;
this
.
lblTargetP1
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
lblTargetP1
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
lblTargetP1
.
TabIndex
=
257
;
//
// lblActual1
...
...
@@ -390,7 +391,7 @@
this
.
lblActual1
.
Location
=
new
System
.
Drawing
.
Point
(
105
,
48
);
this
.
lblActual1
.
Name
=
"lblActual1"
;
this
.
lblActual1
.
ReadOnly
=
true
;
this
.
lblActual1
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
lblActual1
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
lblActual1
.
TabIndex
=
256
;
//
// lblTargetP3
...
...
@@ -398,7 +399,7 @@
this
.
lblTargetP3
.
Location
=
new
System
.
Drawing
.
Point
(
287
,
76
);
this
.
lblTargetP3
.
Name
=
"lblTargetP3"
;
this
.
lblTargetP3
.
ReadOnly
=
true
;
this
.
lblTargetP3
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
lblTargetP3
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
lblTargetP3
.
TabIndex
=
178
;
//
// lblActual3
...
...
@@ -406,7 +407,7 @@
this
.
lblActual3
.
Location
=
new
System
.
Drawing
.
Point
(
287
,
48
);
this
.
lblActual3
.
Name
=
"lblActual3"
;
this
.
lblActual3
.
ReadOnly
=
true
;
this
.
lblActual3
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
lblActual3
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
lblActual3
.
TabIndex
=
177
;
//
// lblTargetP2
...
...
@@ -414,7 +415,7 @@
this
.
lblTargetP2
.
Location
=
new
System
.
Drawing
.
Point
(
195
,
76
);
this
.
lblTargetP2
.
Name
=
"lblTargetP2"
;
this
.
lblTargetP2
.
ReadOnly
=
true
;
this
.
lblTargetP2
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
lblTargetP2
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
lblTargetP2
.
TabIndex
=
176
;
//
// lblActual2
...
...
@@ -422,7 +423,7 @@
this
.
lblActual2
.
Location
=
new
System
.
Drawing
.
Point
(
195
,
48
);
this
.
lblActual2
.
Name
=
"lblActual2"
;
this
.
lblActual2
.
ReadOnly
=
true
;
this
.
lblActual2
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
3
);
this
.
lblActual2
.
Size
=
new
System
.
Drawing
.
Size
(
84
,
2
7
);
this
.
lblActual2
.
TabIndex
=
175
;
//
// label4
...
...
@@ -431,7 +432,7 @@
this
.
label4
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label4
.
Location
=
new
System
.
Drawing
.
Point
(
294
,
20
);
this
.
label4
.
Name
=
"label4"
;
this
.
label4
.
Size
=
new
System
.
Drawing
.
Size
(
71
,
17
);
this
.
label4
.
Size
=
new
System
.
Drawing
.
Size
(
88
,
20
);
this
.
label4
.
TabIndex
=
100
;
this
.
label4
.
Text
=
"轴三:进出轴"
;
//
...
...
@@ -441,7 +442,7 @@
this
.
label3
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label3
.
Location
=
new
System
.
Drawing
.
Point
(
202
,
20
);
this
.
label3
.
Name
=
"label3"
;
this
.
label3
.
Size
=
new
System
.
Drawing
.
Size
(
71
,
17
);
this
.
label3
.
Size
=
new
System
.
Drawing
.
Size
(
88
,
20
);
this
.
label3
.
TabIndex
=
99
;
this
.
label3
.
Text
=
"轴二:上下轴"
;
//
...
...
@@ -451,7 +452,7 @@
this
.
label1
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label1
.
Location
=
new
System
.
Drawing
.
Point
(
112
,
20
);
this
.
label1
.
Name
=
"label1"
;
this
.
label1
.
Size
=
new
System
.
Drawing
.
Size
(
71
,
17
);
this
.
label1
.
Size
=
new
System
.
Drawing
.
Size
(
88
,
20
);
this
.
label1
.
TabIndex
=
97
;
this
.
label1
.
Text
=
"轴一:旋转轴"
;
//
...
...
@@ -461,7 +462,7 @@
this
.
label43
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label43
.
Location
=
new
System
.
Drawing
.
Point
(
29
,
49
);
this
.
label43
.
Name
=
"label43"
;
this
.
label43
.
Size
=
new
System
.
Drawing
.
Size
(
59
,
17
);
this
.
label43
.
Size
=
new
System
.
Drawing
.
Size
(
73
,
20
);
this
.
label43
.
TabIndex
=
23
;
this
.
label43
.
Text
=
"实际位置:"
;
//
...
...
@@ -471,7 +472,7 @@
this
.
label42
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label42
.
Location
=
new
System
.
Drawing
.
Point
(
29
,
76
);
this
.
label42
.
Name
=
"label42"
;
this
.
label42
.
Size
=
new
System
.
Drawing
.
Size
(
59
,
17
);
this
.
label42
.
Size
=
new
System
.
Drawing
.
Size
(
73
,
20
);
this
.
label42
.
TabIndex
=
24
;
this
.
label42
.
Text
=
"规划位置:"
;
//
...
...
@@ -481,7 +482,7 @@
this
.
groupBox2
.
Controls
.
Add
(
this
.
button6
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
button3
);
this
.
groupBox2
.
Controls
.
Add
(
this
.
button5
);
this
.
groupBox2
.
Location
=
new
System
.
Drawing
.
Point
(
11
,
3
56
);
this
.
groupBox2
.
Location
=
new
System
.
Drawing
.
Point
(
11
,
3
47
);
this
.
groupBox2
.
Name
=
"groupBox2"
;
this
.
groupBox2
.
Size
=
new
System
.
Drawing
.
Size
(
476
,
78
);
this
.
groupBox2
.
TabIndex
=
276
;
...
...
@@ -529,7 +530,7 @@
this
.
lblTemp
.
ForeColor
=
System
.
Drawing
.
Color
.
Black
;
this
.
lblTemp
.
Location
=
new
System
.
Drawing
.
Point
(
420
,
22
);
this
.
lblTemp
.
Name
=
"lblTemp"
;
this
.
lblTemp
.
Size
=
new
System
.
Drawing
.
Size
(
159
,
20
);
this
.
lblTemp
.
Size
=
new
System
.
Drawing
.
Size
(
204
,
24
);
this
.
lblTemp
.
TabIndex
=
275
;
this
.
lblTemp
.
Text
=
"当前温度--,当前湿度--"
;
//
...
...
@@ -540,7 +541,7 @@
this
.
lblMoveEquipInfo
.
ForeColor
=
System
.
Drawing
.
Color
.
Green
;
this
.
lblMoveEquipInfo
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
109
);
this
.
lblMoveEquipInfo
.
Name
=
"lblMoveEquipInfo"
;
this
.
lblMoveEquipInfo
.
Size
=
new
System
.
Drawing
.
Size
(
1
07
,
17
);
this
.
lblMoveEquipInfo
.
Size
=
new
System
.
Drawing
.
Size
(
1
33
,
20
);
this
.
lblMoveEquipInfo
.
TabIndex
=
274
;
this
.
lblMoveEquipInfo
.
Text
=
"移栽状态:不可出库"
;
//
...
...
@@ -551,7 +552,7 @@
this
.
lblThisSta
.
ForeColor
=
System
.
Drawing
.
Color
.
Green
;
this
.
lblThisSta
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
76
);
this
.
lblThisSta
.
Name
=
"lblThisSta"
;
this
.
lblThisSta
.
Size
=
new
System
.
Drawing
.
Size
(
56
,
17
);
this
.
lblThisSta
.
Size
=
new
System
.
Drawing
.
Size
(
69
,
20
);
this
.
lblThisSta
.
TabIndex
=
216
;
this
.
lblThisSta
.
Text
=
"等待启动"
;
this
.
lblThisSta
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -589,9 +590,9 @@
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnAxisOn
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnAxisOff
);
this
.
tabPage3
.
Controls
.
Add
(
this
.
btnAxisP
);
this
.
tabPage3
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage3
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
32
);
this
.
tabPage3
.
Name
=
"tabPage3"
;
this
.
tabPage3
.
Size
=
new
System
.
Drawing
.
Size
(
1091
,
60
7
);
this
.
tabPage3
.
Size
=
new
System
.
Drawing
.
Size
(
1091
,
60
4
);
this
.
tabPage3
.
TabIndex
=
2
;
this
.
tabPage3
.
Text
=
" 库位操作/伺服调试 "
;
this
.
tabPage3
.
UseVisualStyleBackColor
=
true
;
...
...
@@ -634,6 +635,7 @@
this
.
groupInout
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)((((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
)
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
groupInout
.
Controls
.
Add
(
this
.
btnInOutTest
);
this
.
groupInout
.
Controls
.
Add
(
this
.
lblAutoMsg
);
this
.
groupInout
.
Controls
.
Add
(
this
.
btnStartAuTo
);
this
.
groupInout
.
Controls
.
Add
(
this
.
label9
);
...
...
@@ -679,11 +681,24 @@
this
.
groupInout
.
Enabled
=
false
;
this
.
groupInout
.
Location
=
new
System
.
Drawing
.
Point
(
5
,
6
);
this
.
groupInout
.
Name
=
"groupInout"
;
this
.
groupInout
.
Size
=
new
System
.
Drawing
.
Size
(
508
,
5
76
);
this
.
groupInout
.
Size
=
new
System
.
Drawing
.
Size
(
508
,
5
67
);
this
.
groupInout
.
TabIndex
=
100
;
this
.
groupInout
.
TabStop
=
false
;
this
.
groupInout
.
Text
=
"料仓操作"
;
//
// btnInOutTest
//
this
.
btnInOutTest
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnInOutTest
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnInOutTest
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnInOutTest
.
Location
=
new
System
.
Drawing
.
Point
(
154
,
461
);
this
.
btnInOutTest
.
Name
=
"btnInOutTest"
;
this
.
btnInOutTest
.
Size
=
new
System
.
Drawing
.
Size
(
132
,
39
);
this
.
btnInOutTest
.
TabIndex
=
275
;
this
.
btnInOutTest
.
Text
=
"自动跑位测试"
;
this
.
btnInOutTest
.
UseVisualStyleBackColor
=
false
;
this
.
btnInOutTest
.
Click
+=
new
System
.
EventHandler
(
this
.
btnInOutTest_Click
);
//
// lblAutoMsg
//
this
.
lblAutoMsg
.
AutoSize
=
true
;
...
...
@@ -691,7 +706,7 @@
this
.
lblAutoMsg
.
ForeColor
=
System
.
Drawing
.
Color
.
Green
;
this
.
lblAutoMsg
.
Location
=
new
System
.
Drawing
.
Point
(
120
,
76
);
this
.
lblAutoMsg
.
Name
=
"lblAutoMsg"
;
this
.
lblAutoMsg
.
Size
=
new
System
.
Drawing
.
Size
(
1
35
,
20
);
this
.
lblAutoMsg
.
Size
=
new
System
.
Drawing
.
Size
(
1
72
,
24
);
this
.
lblAutoMsg
.
TabIndex
=
223
;
this
.
lblAutoMsg
.
Text
=
"没有开启自动出入库"
;
//
...
...
@@ -714,7 +729,7 @@
this
.
label9
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label9
.
Location
=
new
System
.
Drawing
.
Point
(
11
,
78
);
this
.
label9
.
Name
=
"label9"
;
this
.
label9
.
Size
=
new
System
.
Drawing
.
Size
(
59
,
17
);
this
.
label9
.
Size
=
new
System
.
Drawing
.
Size
(
73
,
20
);
this
.
label9
.
TabIndex
=
220
;
this
.
label9
.
Text
=
"间隔仓位:"
;
//
...
...
@@ -748,7 +763,7 @@
//
this
.
txtJiange
.
Location
=
new
System
.
Drawing
.
Point
(
76
,
73
);
this
.
txtJiange
.
Name
=
"txtJiange"
;
this
.
txtJiange
.
Size
=
new
System
.
Drawing
.
Size
(
40
,
26
);
this
.
txtJiange
.
Size
=
new
System
.
Drawing
.
Size
(
40
,
31
);
this
.
txtJiange
.
TabIndex
=
221
;
this
.
txtJiange
.
Text
=
"0"
;
//
...
...
@@ -763,7 +778,7 @@
this
.
txtComP1
.
MaxLength
=
20
;
this
.
txtComP1
.
Name
=
"txtComP1"
;
this
.
txtComP1
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtComP1
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtComP1
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtComP1
.
TabIndex
=
214
;
this
.
txtComP1
.
Text
=
"-12388"
;
//
...
...
@@ -778,7 +793,7 @@
this
.
txtInOutP2
.
MaxLength
=
20
;
this
.
txtInOutP2
.
Name
=
"txtInOutP2"
;
this
.
txtInOutP2
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtInOutP2
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtInOutP2
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtInOutP2
.
TabIndex
=
212
;
this
.
txtInOutP2
.
Text
=
"-17000"
;
//
...
...
@@ -793,7 +808,7 @@
this
.
txtInOutP1
.
MaxLength
=
20
;
this
.
txtInOutP1
.
Name
=
"txtInOutP1"
;
this
.
txtInOutP1
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtInOutP1
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtInOutP1
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtInOutP1
.
TabIndex
=
210
;
this
.
txtInOutP1
.
Text
=
"3000"
;
//
...
...
@@ -808,7 +823,7 @@
this
.
txtMiddleP1
.
MaxLength
=
20
;
this
.
txtMiddleP1
.
Name
=
"txtMiddleP1"
;
this
.
txtMiddleP1
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtMiddleP1
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtMiddleP1
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtMiddleP1
.
TabIndex
=
208
;
this
.
txtMiddleP1
.
Text
=
"-52388"
;
//
...
...
@@ -836,7 +851,7 @@
this
.
txtUpDownP7
.
MaxLength
=
20
;
this
.
txtUpDownP7
.
Name
=
"txtUpDownP7"
;
this
.
txtUpDownP7
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtUpDownP7
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtUpDownP7
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtUpDownP7
.
TabIndex
=
204
;
this
.
txtUpDownP7
.
Text
=
"-836025"
;
//
...
...
@@ -851,7 +866,7 @@
this
.
txtUpDownP8
.
MaxLength
=
20
;
this
.
txtUpDownP8
.
Name
=
"txtUpDownP8"
;
this
.
txtUpDownP8
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtUpDownP8
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtUpDownP8
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtUpDownP8
.
TabIndex
=
206
;
this
.
txtUpDownP8
.
Text
=
"-816491"
;
//
...
...
@@ -866,7 +881,7 @@
this
.
txtUpDownP1
.
MaxLength
=
20
;
this
.
txtUpDownP1
.
Name
=
"txtUpDownP1"
;
this
.
txtUpDownP1
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtUpDownP1
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtUpDownP1
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtUpDownP1
.
TabIndex
=
200
;
this
.
txtUpDownP1
.
Text
=
"-816491"
;
//
...
...
@@ -881,7 +896,7 @@
this
.
txtUpDownP2
.
MaxLength
=
20
;
this
.
txtUpDownP2
.
Name
=
"txtUpDownP2"
;
this
.
txtUpDownP2
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtUpDownP2
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtUpDownP2
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtUpDownP2
.
TabIndex
=
202
;
this
.
txtUpDownP2
.
Text
=
"-836025"
;
//
...
...
@@ -896,7 +911,7 @@
this
.
txtComP3
.
MaxLength
=
20
;
this
.
txtComP3
.
Name
=
"txtComP3"
;
this
.
txtComP3
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtComP3
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtComP3
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtComP3
.
TabIndex
=
198
;
this
.
txtComP3
.
Text
=
"-12388"
;
//
...
...
@@ -911,7 +926,7 @@
this
.
txtComP2
.
MaxLength
=
20
;
this
.
txtComP2
.
Name
=
"txtComP2"
;
this
.
txtComP2
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtComP2
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtComP2
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtComP2
.
TabIndex
=
196
;
this
.
txtComP2
.
Text
=
"-12388"
;
//
...
...
@@ -926,7 +941,7 @@
this
.
txtInOutP3
.
MaxLength
=
20
;
this
.
txtInOutP3
.
Name
=
"txtInOutP3"
;
this
.
txtInOutP3
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtInOutP3
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtInOutP3
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtInOutP3
.
TabIndex
=
194
;
this
.
txtInOutP3
.
Text
=
"-12388"
;
//
...
...
@@ -941,7 +956,7 @@
this
.
txtMiddleP2
.
MaxLength
=
20
;
this
.
txtMiddleP2
.
Name
=
"txtMiddleP2"
;
this
.
txtMiddleP2
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtMiddleP2
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtMiddleP2
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtMiddleP2
.
TabIndex
=
192
;
this
.
txtMiddleP2
.
Text
=
"-12388"
;
//
...
...
@@ -956,7 +971,7 @@
this
.
txtUpDownP5
.
MaxLength
=
20
;
this
.
txtUpDownP5
.
Name
=
"txtUpDownP5"
;
this
.
txtUpDownP5
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtUpDownP5
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtUpDownP5
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtUpDownP5
.
TabIndex
=
188
;
this
.
txtUpDownP5
.
Text
=
"-16388"
;
//
...
...
@@ -971,7 +986,7 @@
this
.
txtUpDownP6
.
MaxLength
=
20
;
this
.
txtUpDownP6
.
Name
=
"txtUpDownP6"
;
this
.
txtUpDownP6
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtUpDownP6
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtUpDownP6
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtUpDownP6
.
TabIndex
=
190
;
this
.
txtUpDownP6
.
Text
=
"-12388"
;
//
...
...
@@ -982,7 +997,7 @@
this
.
cmbPosition
.
FormattingEnabled
=
true
;
this
.
cmbPosition
.
Location
=
new
System
.
Drawing
.
Point
(
7
,
23
);
this
.
cmbPosition
.
Name
=
"cmbPosition"
;
this
.
cmbPosition
.
Size
=
new
System
.
Drawing
.
Size
(
268
,
28
);
this
.
cmbPosition
.
Size
=
new
System
.
Drawing
.
Size
(
268
,
31
);
this
.
cmbPosition
.
TabIndex
=
174
;
this
.
cmbPosition
.
SelectedIndexChanged
+=
new
System
.
EventHandler
(
this
.
cmbPosition_SelectedIndexChanged
);
//
...
...
@@ -997,7 +1012,7 @@
this
.
txtUpDownP3
.
MaxLength
=
20
;
this
.
txtUpDownP3
.
Name
=
"txtUpDownP3"
;
this
.
txtUpDownP3
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtUpDownP3
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtUpDownP3
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtUpDownP3
.
TabIndex
=
162
;
this
.
txtUpDownP3
.
Text
=
"-16388"
;
//
...
...
@@ -1038,7 +1053,7 @@
this
.
txtUpDownP4
.
MaxLength
=
20
;
this
.
txtUpDownP4
.
Name
=
"txtUpDownP4"
;
this
.
txtUpDownP4
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
txtUpDownP4
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
3
);
this
.
txtUpDownP4
.
Size
=
new
System
.
Drawing
.
Size
(
89
,
2
7
);
this
.
txtUpDownP4
.
TabIndex
=
166
;
this
.
txtUpDownP4
.
Text
=
"-12388"
;
//
...
...
@@ -1130,7 +1145,7 @@
this
.
btnUpDownP7
.
Location
=
new
System
.
Drawing
.
Point
(
10
,
206
);
this
.
btnUpDownP7
.
Name
=
"btnUpDownP7"
;
this
.
btnUpDownP7
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnUpDownP7
.
Size
=
new
System
.
Drawing
.
Size
(
1
40
,
33
);
this
.
btnUpDownP7
.
Size
=
new
System
.
Drawing
.
Size
(
1
63
,
33
);
this
.
btnUpDownP7
.
TabIndex
=
203
;
this
.
btnUpDownP7
.
Text
=
"升降轴入料缓冲点P7:"
;
this
.
btnUpDownP7
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -1149,7 +1164,7 @@
this
.
btnUpDownP8
.
Location
=
new
System
.
Drawing
.
Point
(
10
,
246
);
this
.
btnUpDownP8
.
Name
=
"btnUpDownP8"
;
this
.
btnUpDownP8
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnUpDownP8
.
Size
=
new
System
.
Drawing
.
Size
(
1
40
,
33
);
this
.
btnUpDownP8
.
Size
=
new
System
.
Drawing
.
Size
(
1
63
,
33
);
this
.
btnUpDownP8
.
TabIndex
=
205
;
this
.
btnUpDownP8
.
Text
=
"升降轴出料缓冲点P8:"
;
this
.
btnUpDownP8
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -1187,7 +1202,7 @@
this
.
btnUpDownP2
.
Location
=
new
System
.
Drawing
.
Point
(
10
,
166
);
this
.
btnUpDownP2
.
Name
=
"btnUpDownP2"
;
this
.
btnUpDownP2
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnUpDownP2
.
Size
=
new
System
.
Drawing
.
Size
(
14
0
,
33
);
this
.
btnUpDownP2
.
Size
=
new
System
.
Drawing
.
Size
(
14
8
,
33
);
this
.
btnUpDownP2
.
TabIndex
=
201
;
this
.
btnUpDownP2
.
Text
=
"升降轴出料前点P2:"
;
this
.
btnUpDownP2
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -1205,7 +1220,7 @@
this
.
btnComP3
.
Location
=
new
System
.
Drawing
.
Point
(
259
,
365
);
this
.
btnComP3
.
Name
=
"btnComP3"
;
this
.
btnComP3
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnComP3
.
Size
=
new
System
.
Drawing
.
Size
(
14
0
,
33
);
this
.
btnComP3
.
Size
=
new
System
.
Drawing
.
Size
(
14
8
,
33
);
this
.
btnComP3
.
TabIndex
=
197
;
this
.
btnComP3
.
Text
=
"压紧轴压紧前点P3:"
;
this
.
btnComP3
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -1277,7 +1292,7 @@
this
.
btnUpDownP5
.
Location
=
new
System
.
Drawing
.
Point
(
259
,
206
);
this
.
btnUpDownP5
.
Name
=
"btnUpDownP5"
;
this
.
btnUpDownP5
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnUpDownP5
.
Size
=
new
System
.
Drawing
.
Size
(
14
0
,
33
);
this
.
btnUpDownP5
.
Size
=
new
System
.
Drawing
.
Size
(
14
8
,
33
);
this
.
btnUpDownP5
.
TabIndex
=
187
;
this
.
btnUpDownP5
.
Text
=
"升降轴出料前点P5:"
;
this
.
btnUpDownP5
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -1295,7 +1310,7 @@
this
.
btnUpDownP6
.
Location
=
new
System
.
Drawing
.
Point
(
259
,
246
);
this
.
btnUpDownP6
.
Name
=
"btnUpDownP6"
;
this
.
btnUpDownP6
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnUpDownP6
.
Size
=
new
System
.
Drawing
.
Size
(
1
40
,
33
);
this
.
btnUpDownP6
.
Size
=
new
System
.
Drawing
.
Size
(
1
63
,
33
);
this
.
btnUpDownP6
.
TabIndex
=
189
;
this
.
btnUpDownP6
.
Text
=
"升降轴出料缓冲点P6:"
;
this
.
btnUpDownP6
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -1313,7 +1328,7 @@
this
.
btnUpDownP3
.
Location
=
new
System
.
Drawing
.
Point
(
259
,
126
);
this
.
btnUpDownP3
.
Name
=
"btnUpDownP3"
;
this
.
btnUpDownP3
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnUpDownP3
.
Size
=
new
System
.
Drawing
.
Size
(
14
0
,
33
);
this
.
btnUpDownP3
.
Size
=
new
System
.
Drawing
.
Size
(
14
8
,
33
);
this
.
btnUpDownP3
.
TabIndex
=
161
;
this
.
btnUpDownP3
.
Text
=
"升降轴入料前点P3:"
;
this
.
btnUpDownP3
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -1331,7 +1346,7 @@
this
.
btnUpDownP4
.
Location
=
new
System
.
Drawing
.
Point
(
259
,
166
);
this
.
btnUpDownP4
.
Name
=
"btnUpDownP4"
;
this
.
btnUpDownP4
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnUpDownP4
.
Size
=
new
System
.
Drawing
.
Size
(
1
40
,
33
);
this
.
btnUpDownP4
.
Size
=
new
System
.
Drawing
.
Size
(
1
63
,
33
);
this
.
btnUpDownP4
.
TabIndex
=
165
;
this
.
btnUpDownP4
.
Text
=
"升降轴入料缓冲点P4:"
;
this
.
btnUpDownP4
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleLeft
;
...
...
@@ -1341,10 +1356,10 @@
// tabPage1
//
this
.
tabPage1
.
Controls
.
Add
(
this
.
panel1
);
this
.
tabPage1
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
2
6
);
this
.
tabPage1
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
2
9
);
this
.
tabPage1
.
Name
=
"tabPage1"
;
this
.
tabPage1
.
Padding
=
new
System
.
Windows
.
Forms
.
Padding
(
3
);
this
.
tabPage1
.
Size
=
new
System
.
Drawing
.
Size
(
1091
,
6
10
);
this
.
tabPage1
.
Size
=
new
System
.
Drawing
.
Size
(
1091
,
6
07
);
this
.
tabPage1
.
TabIndex
=
0
;
this
.
tabPage1
.
Text
=
" IO调试 "
;
this
.
tabPage1
.
UseVisualStyleBackColor
=
true
;
...
...
@@ -1412,7 +1427,7 @@
this
.
txtDOIndex
.
Location
=
new
System
.
Drawing
.
Point
(
266
,
55
);
this
.
txtDOIndex
.
MaxLength
=
10
;
this
.
txtDOIndex
.
Name
=
"txtDOIndex"
;
this
.
txtDOIndex
.
Size
=
new
System
.
Drawing
.
Size
(
46
,
26
);
this
.
txtDOIndex
.
Size
=
new
System
.
Drawing
.
Size
(
46
,
31
);
this
.
txtDOIndex
.
TabIndex
=
242
;
this
.
txtDOIndex
.
Text
=
"0"
;
//
...
...
@@ -1422,7 +1437,7 @@
this
.
txtDoName
.
Location
=
new
System
.
Drawing
.
Point
(
66
,
56
);
this
.
txtDoName
.
MaxLength
=
10
;
this
.
txtDoName
.
Name
=
"txtDoName"
;
this
.
txtDoName
.
Size
=
new
System
.
Drawing
.
Size
(
141
,
26
);
this
.
txtDoName
.
Size
=
new
System
.
Drawing
.
Size
(
141
,
31
);
this
.
txtDoName
.
TabIndex
=
241
;
this
.
txtDoName
.
Text
=
"0"
;
//
...
...
@@ -1445,7 +1460,7 @@
this
.
label17
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label17
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
61
);
this
.
label17
.
Name
=
"label17"
;
this
.
label17
.
Size
=
new
System
.
Drawing
.
Size
(
35
,
17
);
this
.
label17
.
Size
=
new
System
.
Drawing
.
Size
(
43
,
20
);
this
.
label17
.
TabIndex
=
240
;
this
.
label17
.
Text
=
"设备:"
;
this
.
label17
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
...
...
@@ -1469,7 +1484,7 @@
this
.
label14
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label14
.
Location
=
new
System
.
Drawing
.
Point
(
219
,
61
);
this
.
label14
.
Name
=
"label14"
;
this
.
label14
.
Size
=
new
System
.
Drawing
.
Size
(
35
,
17
);
this
.
label14
.
Size
=
new
System
.
Drawing
.
Size
(
43
,
20
);
this
.
label14
.
TabIndex
=
239
;
this
.
label14
.
Text
=
"地址:"
;
this
.
label14
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
...
...
@@ -1480,7 +1495,7 @@
this
.
txtWriteTime
.
Location
=
new
System
.
Drawing
.
Point
(
70
,
92
);
this
.
txtWriteTime
.
MaxLength
=
10
;
this
.
txtWriteTime
.
Name
=
"txtWriteTime"
;
this
.
txtWriteTime
.
Size
=
new
System
.
Drawing
.
Size
(
50
,
26
);
this
.
txtWriteTime
.
Size
=
new
System
.
Drawing
.
Size
(
50
,
31
);
this
.
txtWriteTime
.
TabIndex
=
238
;
this
.
txtWriteTime
.
Text
=
"0"
;
//
...
...
@@ -1491,7 +1506,7 @@
this
.
label5
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
label5
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
97
);
this
.
label5
.
Name
=
"label5"
;
this
.
label5
.
Size
=
new
System
.
Drawing
.
Size
(
60
,
17
);
this
.
label5
.
Size
=
new
System
.
Drawing
.
Size
(
74
,
20
);
this
.
label5
.
TabIndex
=
237
;
this
.
label5
.
Text
=
"定时(ms):"
;
this
.
label5
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
...
...
@@ -1504,7 +1519,7 @@
this
.
cmbWriteIO
.
FormattingEnabled
=
true
;
this
.
cmbWriteIO
.
Location
=
new
System
.
Drawing
.
Point
(
14
,
22
);
this
.
cmbWriteIO
.
Name
=
"cmbWriteIO"
;
this
.
cmbWriteIO
.
Size
=
new
System
.
Drawing
.
Size
(
298
,
28
);
this
.
cmbWriteIO
.
Size
=
new
System
.
Drawing
.
Size
(
298
,
31
);
this
.
cmbWriteIO
.
TabIndex
=
234
;
this
.
cmbWriteIO
.
ValueMember
=
"ProName"
;
this
.
cmbWriteIO
.
SelectedIndexChanged
+=
new
System
.
EventHandler
(
this
.
cmbWriteIO_SelectedIndexChanged
);
...
...
@@ -1568,7 +1583,6 @@
this
.
Controls
.
Add
(
this
.
tabControl1
);
this
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
Icon
=
((
System
.
Drawing
.
Icon
)(
resources
.
GetObject
(
"$this.Icon"
)));
this
.
Margin
=
new
System
.
Windows
.
Forms
.
Padding
(
4
);
this
.
Name
=
"FrmBox"
;
this
.
Opacity
=
0D
;
this
.
Text
=
"AC_SA_料仓"
;
...
...
@@ -1702,6 +1716,7 @@
private
System
.
Windows
.
Forms
.
Button
btnOpenD
;
private
System
.
Windows
.
Forms
.
Button
btnCloseD
;
private
System
.
Windows
.
Forms
.
Label
lblMoveStr
;
private
System
.
Windows
.
Forms
.
Button
btnInOutTest
;
}
}
source/HCSingleStore/FrmBox.cs
查看文件 @
561a996
...
...
@@ -1082,5 +1082,11 @@ namespace OnlineStore.ACSingleStore
{
}
private
void
btnInOutTest_Click
(
object
sender
,
EventArgs
e
)
{
FrmInOutStore
frmInOutStore
=
new
FrmInOutStore
(
boxBean
);
frmInOutStore
.
ShowDialog
();
}
}
}
source/HCSingleStore/FrmInOutStore.Designer.cs
0 → 100644
查看文件 @
561a996
namespace
OnlineStore.ACSingleStore
{
partial
class
FrmInOutStore
{
/// <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
.
components
=
new
System
.
ComponentModel
.
Container
();
this
.
lstBoxInOK
=
new
System
.
Windows
.
Forms
.
ListBox
();
this
.
grpBoxOKList
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
richTextBox1
=
new
System
.
Windows
.
Forms
.
RichTextBox
();
this
.
tableLayoutPanel1
=
new
System
.
Windows
.
Forms
.
TableLayoutPanel
();
this
.
grpBoxLog
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
grpBoxOperation
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
groupBox1
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
btnOut4
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnOut3
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnOut2
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnOut1
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnOutStore
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
cmbPosition
=
new
System
.
Windows
.
Forms
.
ComboBox
();
this
.
btnStartAuto
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnStoreStart
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
mainTimer
=
new
System
.
Windows
.
Forms
.
Timer
(
this
.
components
);
this
.
grpBoxOKList
.
SuspendLayout
();
this
.
tableLayoutPanel1
.
SuspendLayout
();
this
.
grpBoxLog
.
SuspendLayout
();
this
.
grpBoxOperation
.
SuspendLayout
();
this
.
groupBox1
.
SuspendLayout
();
this
.
SuspendLayout
();
//
// lstBoxInOK
//
this
.
lstBoxInOK
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
lstBoxInOK
.
FormattingEnabled
=
true
;
this
.
lstBoxInOK
.
ItemHeight
=
20
;
this
.
lstBoxInOK
.
Location
=
new
System
.
Drawing
.
Point
(
3
,
23
);
this
.
lstBoxInOK
.
Name
=
"lstBoxInOK"
;
this
.
lstBoxInOK
.
Size
=
new
System
.
Drawing
.
Size
(
253
,
589
);
this
.
lstBoxInOK
.
TabIndex
=
0
;
//
// grpBoxOKList
//
this
.
grpBoxOKList
.
Controls
.
Add
(
this
.
lstBoxInOK
);
this
.
grpBoxOKList
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
grpBoxOKList
.
Location
=
new
System
.
Drawing
.
Point
(
741
,
3
);
this
.
grpBoxOKList
.
Name
=
"grpBoxOKList"
;
this
.
grpBoxOKList
.
Size
=
new
System
.
Drawing
.
Size
(
259
,
615
);
this
.
grpBoxOKList
.
TabIndex
=
1
;
this
.
grpBoxOKList
.
TabStop
=
false
;
this
.
grpBoxOKList
.
Text
=
"入仓成功列表"
;
//
// richTextBox1
//
this
.
richTextBox1
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
richTextBox1
.
Location
=
new
System
.
Drawing
.
Point
(
3
,
23
);
this
.
richTextBox1
.
Name
=
"richTextBox1"
;
this
.
richTextBox1
.
Size
=
new
System
.
Drawing
.
Size
(
510
,
589
);
this
.
richTextBox1
.
TabIndex
=
2
;
this
.
richTextBox1
.
Text
=
""
;
//
// tableLayoutPanel1
//
this
.
tableLayoutPanel1
.
ColumnCount
=
3
;
this
.
tableLayoutPanel1
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
21.53539F
));
this
.
tableLayoutPanel1
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
52.04387F
));
this
.
tableLayoutPanel1
.
ColumnStyles
.
Add
(
new
System
.
Windows
.
Forms
.
ColumnStyle
(
System
.
Windows
.
Forms
.
SizeType
.
Percent
,
26.32104F
));
this
.
tableLayoutPanel1
.
Controls
.
Add
(
this
.
grpBoxOKList
,
2
,
0
);
this
.
tableLayoutPanel1
.
Controls
.
Add
(
this
.
grpBoxLog
,
1
,
0
);
this
.
tableLayoutPanel1
.
Controls
.
Add
(
this
.
grpBoxOperation
,
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
.
Size
=
new
System
.
Drawing
.
Size
(
1003
,
621
);
this
.
tableLayoutPanel1
.
TabIndex
=
3
;
//
// grpBoxLog
//
this
.
grpBoxLog
.
Controls
.
Add
(
this
.
richTextBox1
);
this
.
grpBoxLog
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
grpBoxLog
.
Location
=
new
System
.
Drawing
.
Point
(
219
,
3
);
this
.
grpBoxLog
.
Name
=
"grpBoxLog"
;
this
.
grpBoxLog
.
Size
=
new
System
.
Drawing
.
Size
(
516
,
615
);
this
.
grpBoxLog
.
TabIndex
=
2
;
this
.
grpBoxLog
.
TabStop
=
false
;
this
.
grpBoxLog
.
Text
=
"操作日志"
;
//
// grpBoxOperation
//
this
.
grpBoxOperation
.
Controls
.
Add
(
this
.
groupBox1
);
this
.
grpBoxOperation
.
Controls
.
Add
(
this
.
btnOutStore
);
this
.
grpBoxOperation
.
Controls
.
Add
(
this
.
cmbPosition
);
this
.
grpBoxOperation
.
Controls
.
Add
(
this
.
btnStartAuto
);
this
.
grpBoxOperation
.
Controls
.
Add
(
this
.
btnStoreStart
);
this
.
grpBoxOperation
.
Dock
=
System
.
Windows
.
Forms
.
DockStyle
.
Fill
;
this
.
grpBoxOperation
.
Location
=
new
System
.
Drawing
.
Point
(
3
,
3
);
this
.
grpBoxOperation
.
Name
=
"grpBoxOperation"
;
this
.
grpBoxOperation
.
Size
=
new
System
.
Drawing
.
Size
(
210
,
615
);
this
.
grpBoxOperation
.
TabIndex
=
3
;
this
.
grpBoxOperation
.
TabStop
=
false
;
this
.
grpBoxOperation
.
Text
=
"料仓操作"
;
//
// groupBox1
//
this
.
groupBox1
.
Controls
.
Add
(
this
.
btnOut4
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
btnOut3
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
btnOut2
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
btnOut1
);
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
9
,
343
);
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
172
,
239
);
this
.
groupBox1
.
TabIndex
=
4
;
this
.
groupBox1
.
TabStop
=
false
;
this
.
groupBox1
.
Text
=
"待出库信息"
;
//
// btnOut4
//
this
.
btnOut4
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
183
);
this
.
btnOut4
.
Name
=
"btnOut4"
;
this
.
btnOut4
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
47
);
this
.
btnOut4
.
TabIndex
=
7
;
this
.
btnOut4
.
Text
=
"出库"
;
this
.
btnOut4
.
UseVisualStyleBackColor
=
true
;
this
.
btnOut4
.
Click
+=
new
System
.
EventHandler
(
this
.
ManualOutStore
);
//
// btnOut3
//
this
.
btnOut3
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
130
);
this
.
btnOut3
.
Name
=
"btnOut3"
;
this
.
btnOut3
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
47
);
this
.
btnOut3
.
TabIndex
=
6
;
this
.
btnOut3
.
Text
=
"出库"
;
this
.
btnOut3
.
UseVisualStyleBackColor
=
true
;
this
.
btnOut3
.
Click
+=
new
System
.
EventHandler
(
this
.
ManualOutStore
);
//
// btnOut2
//
this
.
btnOut2
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
79
);
this
.
btnOut2
.
Name
=
"btnOut2"
;
this
.
btnOut2
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
47
);
this
.
btnOut2
.
TabIndex
=
5
;
this
.
btnOut2
.
Text
=
"出库"
;
this
.
btnOut2
.
UseVisualStyleBackColor
=
true
;
this
.
btnOut2
.
Click
+=
new
System
.
EventHandler
(
this
.
ManualOutStore
);
//
// btnOut1
//
this
.
btnOut1
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
26
);
this
.
btnOut1
.
Name
=
"btnOut1"
;
this
.
btnOut1
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
47
);
this
.
btnOut1
.
TabIndex
=
4
;
this
.
btnOut1
.
Text
=
"出库"
;
this
.
btnOut1
.
UseVisualStyleBackColor
=
true
;
this
.
btnOut1
.
Click
+=
new
System
.
EventHandler
(
this
.
ManualOutStore
);
//
// btnOutStore
//
this
.
btnOutStore
.
Location
=
new
System
.
Drawing
.
Point
(
15
,
267
);
this
.
btnOutStore
.
Name
=
"btnOutStore"
;
this
.
btnOutStore
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
47
);
this
.
btnOutStore
.
TabIndex
=
3
;
this
.
btnOutStore
.
Text
=
"出库"
;
this
.
btnOutStore
.
UseVisualStyleBackColor
=
true
;
this
.
btnOutStore
.
Click
+=
new
System
.
EventHandler
(
this
.
btnOutStore_Click
);
//
// cmbPosition
//
this
.
cmbPosition
.
FormattingEnabled
=
true
;
this
.
cmbPosition
.
Location
=
new
System
.
Drawing
.
Point
(
15
,
114
);
this
.
cmbPosition
.
Name
=
"cmbPosition"
;
this
.
cmbPosition
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
28
);
this
.
cmbPosition
.
TabIndex
=
2
;
//
// btnStartAuto
//
this
.
btnStartAuto
.
Location
=
new
System
.
Drawing
.
Point
(
15
,
170
);
this
.
btnStartAuto
.
Name
=
"btnStartAuto"
;
this
.
btnStartAuto
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
47
);
this
.
btnStartAuto
.
TabIndex
=
1
;
this
.
btnStartAuto
.
Text
=
"开始自动跑位"
;
this
.
btnStartAuto
.
UseVisualStyleBackColor
=
true
;
this
.
btnStartAuto
.
Click
+=
new
System
.
EventHandler
(
this
.
btnStartAuto_Click
);
//
// btnStoreStart
//
this
.
btnStoreStart
.
Location
=
new
System
.
Drawing
.
Point
(
15
,
46
);
this
.
btnStoreStart
.
Name
=
"btnStoreStart"
;
this
.
btnStoreStart
.
Size
=
new
System
.
Drawing
.
Size
(
150
,
47
);
this
.
btnStoreStart
.
TabIndex
=
0
;
this
.
btnStoreStart
.
Text
=
"启动料仓"
;
this
.
btnStoreStart
.
UseVisualStyleBackColor
=
true
;
this
.
btnStoreStart
.
Click
+=
new
System
.
EventHandler
(
this
.
btnStoreStart_Click
);
//
// FrmInOutStore
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
9F
,
20F
);
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
ClientSize
=
new
System
.
Drawing
.
Size
(
1003
,
621
);
this
.
Controls
.
Add
(
this
.
tableLayoutPanel1
);
this
.
Name
=
"FrmInOutStore"
;
this
.
Text
=
"自动跑位"
;
this
.
FormClosing
+=
new
System
.
Windows
.
Forms
.
FormClosingEventHandler
(
this
.
FrmInOutStore_FormClosing
);
this
.
Load
+=
new
System
.
EventHandler
(
this
.
FrmInOutStore_Load
);
this
.
grpBoxOKList
.
ResumeLayout
(
false
);
this
.
tableLayoutPanel1
.
ResumeLayout
(
false
);
this
.
grpBoxLog
.
ResumeLayout
(
false
);
this
.
grpBoxOperation
.
ResumeLayout
(
false
);
this
.
groupBox1
.
ResumeLayout
(
false
);
this
.
ResumeLayout
(
false
);
}
#
endregion
private
System
.
Windows
.
Forms
.
ListBox
lstBoxInOK
;
private
System
.
Windows
.
Forms
.
GroupBox
grpBoxOKList
;
private
System
.
Windows
.
Forms
.
RichTextBox
richTextBox1
;
private
System
.
Windows
.
Forms
.
TableLayoutPanel
tableLayoutPanel1
;
private
System
.
Windows
.
Forms
.
GroupBox
grpBoxLog
;
private
System
.
Windows
.
Forms
.
GroupBox
grpBoxOperation
;
private
System
.
Windows
.
Forms
.
Button
btnStoreStart
;
private
System
.
Windows
.
Forms
.
Button
btnStartAuto
;
private
System
.
Windows
.
Forms
.
Timer
mainTimer
;
private
System
.
Windows
.
Forms
.
ComboBox
cmbPosition
;
private
System
.
Windows
.
Forms
.
Button
btnOutStore
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox1
;
private
System
.
Windows
.
Forms
.
Button
btnOut4
;
private
System
.
Windows
.
Forms
.
Button
btnOut3
;
private
System
.
Windows
.
Forms
.
Button
btnOut2
;
private
System
.
Windows
.
Forms
.
Button
btnOut1
;
}
}
\ No newline at end of file
source/HCSingleStore/FrmInOutStore.cs
0 → 100644
查看文件 @
561a996
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
;
using
OnlineStore.Common
;
using
OnlineStore.DeviceLibrary
;
using
log4net
;
using
System.Reflection
;
using
OnlineStore.LoadCSVLibrary
;
namespace
OnlineStore.ACSingleStore
{
public
partial
class
FrmInOutStore
:
FrmBase
{
/// <summary>
/// 放入4个料盘步骤
/// </summary>
enum
IniPositionStep
{
None
,
Pos1
,
Pos3
,
Pos0
,
Pos2
,
Success
}
/// <summary>
/// 将料盘放到初始位置步骤
/// </summary>
enum
MoveToStartPosStep
{
None
,
S1_Out
,
S1_In
,
S2_Out
,
S2_In
,
S3_In
,
S3_Out
,
Sucess
}
/// <summary>
/// 循环体退出后的执行步骤
/// </summary>
enum
LastStageInOutStep
{
None
,
S1_Out
,
S1_In
,
S2_Out
,
S2_In
,
S3_Out
,
S3_In
,
S4_Out
,
S4_In
,
S5_Out
,
S5_In
,
S6_In
,
S6_Out
,
S7_Out
,
S7_In
,
Success
}
/// <summary>
/// 循环体的执行步骤
/// </summary>
enum
GeneralInOutStep
{
None
,
S1_Out
,
S1_In
,
S2_Out
,
S2_In
,
S3_Out
,
S3_In
,
S4_Out
,
S4_In
,
S5_Out
,
S5_In
,
S6_In
,
S6_Out
,
S7_Out
,
S7_In
,
S8_Out
,
S8_In
}
Button
[]
btnOuts
;
public
List
<
string
>
needToInStoreNumList
;
private
string
StartAuto
=
ResourceCulture
.
GetString
(
"开始自动跑位"
);
private
string
StopAuto
=
ResourceCulture
.
GetString
(
"停止自动跑位"
);
private
bool
IsRun
=
false
;
//是否自动运行
private
bool
IsInit
=
false
;
private
BoxBean
store
=
null
;
public
static
readonly
ILog
LOGGER
=
LogManager
.
GetLogger
(
MethodBase
.
GetCurrentMethod
().
DeclaringType
);
MoveToStartPosStep
moveToStartPosStep
;
IniPositionStep
iniPositionStep
;
LastStageInOutStep
lastStageInOutStep
;
GeneralInOutStep
generalInOutStep
;
public
List
<
int
>
curState
;
//料盘所在位置
private
List
<
string
>
PositionNumList
;
//需要跑位的所有信息
public
FrmInOutStore
(
BoxBean
store
)
{
InitializeComponent
();
this
.
store
=
store
;
lastStageInOutStep
=
new
LastStageInOutStep
();
generalInOutStep
=
new
GeneralInOutStep
();
moveToStartPosStep
=
new
MoveToStartPosStep
();
needToInStoreNumList
=
new
List
<
string
>();
PositionNumList
=
new
List
<
string
>();
curState
=
new
List
<
int
>();
iniPositionStep
=
new
IniPositionStep
();
btnOuts
=
new
Button
[]
{
btnOut1
,
btnOut2
,
btnOut3
,
btnOut4
};
}
#
region
"初始化界面数据"
#
endregion
private
void
FrmInOutStore_Load
(
object
sender
,
EventArgs
e
)
{
LogUtil
.
logBox
=
this
.
richTextBox1
;
btnStartAuto
.
Text
=
StartAuto
;
mainTimer
.
Tick
+=
MainTimer_Tick
;
if
(
store
.
PositionNumList
.
Count
>
0
)
{
cmbPosition
.
DataSource
=
store
.
PositionNumList
;
cmbPosition
.
SelectedIndex
=
0
;
}
}
/// <summary>
/// 启动测试
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private
void
btnStoreStart_Click
(
object
sender
,
EventArgs
e
)
{
store
.
StartRun
();
if
(
store
.
storeRunStatus
>=
StoreRunStatus
.
HomeMoving
)
{
StoreOpenStatus
(
true
);
}
}
private
bool
preOpen
=
false
;
public
void
StoreOpenStatus
(
bool
isOpen
)
{
if
(
preOpen
.
Equals
(
isOpen
))
{
return
;
}
preOpen
=
isOpen
;
btnOutStore
.
Enabled
=
!
isOpen
;
cmbPosition
.
Enabled
=
!
isOpen
;
btnStoreStart
.
Enabled
=
!
isOpen
;
}
private
void
btnStartAuto_Click
(
object
sender
,
EventArgs
e
)
{
if
(
store
.
storeRunStatus
>=
StoreRunStatus
.
HomeMoving
)
{
if
(
btnStartAuto
.
Text
==
StartAuto
)
{
if
(
needToInStoreNumList
.
Count
>
0
)
{
needToInStoreNumList
.
Clear
();
}
if
(
PositionNumList
.
Count
>
0
)
{
PositionNumList
.
Clear
();
}
for
(
int
i
=
cmbPosition
.
SelectedIndex
;
i
<
store
.
PositionNumList
.
Count
;
i
++)
{
needToInStoreNumList
.
Add
(
store
.
PositionNumList
[
i
]);
PositionNumList
.
Add
(
store
.
PositionNumList
[
i
]);
}
IsRun
=
true
;
StoreOpenStatus
(
true
);
btnStartAuto
.
Text
=
StopAuto
;
mainTimer
.
Enabled
=
true
;
// store.storeRunStatus = StoreRunStatus.Runing;
//store.storeStatus = StoreStatus.StoreOnline;
}
else
{
IsRun
=
false
;
StoreOpenStatus
(
false
);
btnStartAuto
.
Text
=
StartAuto
;
mainTimer
.
Enabled
=
false
;
}
}
else
{
MessageBox
.
Show
(
"请先启动料仓!"
);
}
}
string
selectPositionNum
;
/// <summary>
/// 检查仓内料盘是否为4个,不足则向料仓放料
/// </summary>
private
void
IniPositionProcess
()
{
if
(
iniPositionStep
==
IniPositionStep
.
None
)
{
//放置到初始位置1
//PlacePlateFromEntrance(1);
selectPositionNum
=
PositionNumList
[
1
];
iniPositionStep
=
IniPositionStep
.
Pos1
;
store
.
StartInStoreMove
(
new
InOutParam
(
new
InOutPosInfo
(
"AUTOINOUT"
,
selectPositionNum
)));
}
else
if
(
iniPositionStep
==
IniPositionStep
.
Pos1
)
{
if
(
IsMoveFinished
())
{
curState
.
Add
(
1
);
LogUtil
.
info
(
LOGGER
,
selectPositionNum
+
"入库"
);
//放置到初始位置3
// PlacePlateFromEntrance(3);
selectPositionNum
=
PositionNumList
[
3
];
iniPositionStep
=
IniPositionStep
.
Pos3
;
store
.
StartInStoreMove
(
new
InOutParam
(
new
InOutPosInfo
(
"AUTOINOUT"
,
selectPositionNum
)));
}
}
else
if
(
iniPositionStep
==
IniPositionStep
.
Pos3
)
{
if
(
IsMoveFinished
())
{
curState
.
Add
(
3
);
LogUtil
.
info
(
LOGGER
,
selectPositionNum
+
"入库"
);
selectPositionNum
=
PositionNumList
[
0
];
iniPositionStep
=
IniPositionStep
.
Pos0
;
store
.
StartInStoreMove
(
new
InOutParam
(
new
InOutPosInfo
(
"AUTOINOUT"
,
selectPositionNum
)));
}
}
else
if
(
iniPositionStep
==
IniPositionStep
.
Pos0
)
{
if
(
IsMoveFinished
())
{
curState
.
Add
(
0
);
OnInStore
(
selectPositionNum
);
needToInStoreNumList
.
Remove
(
selectPositionNum
);
selectPositionNum
=
PositionNumList
[
2
];
iniPositionStep
=
IniPositionStep
.
Pos2
;
store
.
StartInStoreMove
(
new
InOutParam
(
new
InOutPosInfo
(
"AUTOINOUT"
,
selectPositionNum
)));
}
}
else
if
(
iniPositionStep
==
IniPositionStep
.
Pos2
)
{
if
(
IsMoveFinished
())
{
curState
.
Add
(
2
);
OnInStore
(
selectPositionNum
);
needToInStoreNumList
.
Remove
(
selectPositionNum
);
curState
.
Sort
();
iniPositionStep
=
IniPositionStep
.
Success
;
}
}
else
if
(
iniPositionStep
==
IniPositionStep
.
Success
)
{
MoveToStartPositionProcess
();
}
}
/// <summary>
/// 将料盘放置到循环运行的开始位置
/// </summary>
private
void
MoveToStartPositionProcess
()
{
if
(
needToInStoreNumList
.
Count
==
3
)
//数量为5个的情况
{
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
None
)
{
moveToStartPosStep
=
MoveToStartPosStep
.
S1_Out
;
OutStoreExecution
(
curState
[
1
]);
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S1_Out
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S1_In
;
InStore
(
curState
[
1
],
curState
[
3
]
+
1
);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S1_In
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S2_Out
;
OutStoreExecution
(
curState
[
2
]);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S2_Out
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S2_In
;
InStore
(
curState
[
2
],
curState
[
0
]
+
1
);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S2_In
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S3_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S3_Out
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S3_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S3_In
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
Sucess
;
ClearToDeleteList
();
IsInit
=
true
;
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
Sucess
)
{
}
}
else
//大于5个的情况
{
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
None
)
{
moveToStartPosStep
=
MoveToStartPosStep
.
S1_Out
;
OutStoreExecution
(
curState
[
1
]);
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S1_Out
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S1_In
;
InStoreExecution
(
curState
[
1
],
curState
[
3
]
+
1
);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S1_In
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S2_Out
;
OutStoreExecution
(
curState
[
2
]);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S2_Out
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S2_In
;
InStore
(
curState
[
2
],
curState
[
0
]
+
1
);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S2_In
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S3_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S3_Out
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
S3_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
S3_In
)
{
if
(
IsMoveFinished
())
{
moveToStartPosStep
=
MoveToStartPosStep
.
Sucess
;
ClearToDeleteList
();
IsInit
=
true
;
}
}
else
if
(
moveToStartPosStep
==
MoveToStartPosStep
.
Sucess
)
{
}
}
///移动到初始位置
//store.MoveToPos(store.curState[1], store.curState[3] + 1);
//store.InStore(store.curState[2], store.curState[0] + 1);
// store.InStore(store.curState[0], store.curState[3] - 1);
}
/// <summary>
/// 出入库流程
/// </summary>
public
void
InOutProcess
()
{
try
{
if
(
needToInStoreNumList
.
Count
>=
0
)
{
if
(
needToInStoreNumList
.
Count
==
0
)
//针对数量只有5个的情况
{
if
(
lastStageInOutStep
==
LastStageInOutStep
.
None
)
{
lastStageInOutStep
=
LastStageInOutStep
.
Success
;
LogUtil
.
info
(
LOGGER
,
"所有仓位跑位测试完成"
);
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
Success
)
{
}
}
if
(
needToInStoreNumList
.
Count
==
1
)
{
// MoveToPos(curState[3], curState[3] + 1);
if
(
lastStageInOutStep
==
LastStageInOutStep
.
None
)
{
lastStageInOutStep
=
LastStageInOutStep
.
S1_Out
;
OutStoreExecution
(
curState
[
3
]);
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S1_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S1_In
;
InStoreExecution
(
curState
[
3
],
curState
[
3
]
+
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S1_In
)
// InStore(curState[0], curState[3] - 1);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S2_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S2_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S2_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S2_In
)
// MoveToPos(curState[0], curState[3] + 2);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S3_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S3_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S3_In
;
InStoreExecution
(
curState
[
0
],
curState
[
3
]
+
2
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S3_In
)
// InStore(curState[0], curState[3] - 1);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S4_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S4_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S4_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S4_In
)
//InStore(curState[1], curState[1]);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S5_Out
;
OutStoreExecution
(
curState
[
1
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S5_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S5_In
;
InStore
(
curState
[
1
],
curState
[
1
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S5_In
)
// InStore(curState[3], curState[3]);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S6_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S6_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S6_In
;
InStore
(
curState
[
0
],
curState
[
3
]
+
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S6_In
)
// InStore(curState[3], curState[3]);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S7_Out
;
OutStoreExecution
(
curState
[
3
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S7_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S7_In
;
InStore
(
curState
[
3
],
curState
[
3
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S7_In
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
Success
;
ClearToDeleteList
();
LogUtil
.
info
(
LOGGER
,
"所有仓位跑位测试完成"
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
Success
)
{
}
}
else
if
(
needToInStoreNumList
.
Count
==
2
)
{
if
(
lastStageInOutStep
==
LastStageInOutStep
.
None
)
{
lastStageInOutStep
=
LastStageInOutStep
.
S1_Out
;
OutStoreExecution
(
curState
[
0
]);
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S1_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S1_In
;
InStore
(
curState
[
0
],
curState
[
3
]
+
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S1_In
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S2_Out
;
OutStoreExecution
(
curState
[
2
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S2_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S2_In
;
InStore
(
curState
[
2
],
curState
[
2
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S2_In
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
Success
;
ClearToDeleteList
();
LogUtil
.
info
(
LOGGER
,
"所有仓位跑位测试完成"
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
Success
)
{
}
}
else
if
(
needToInStoreNumList
.
Count
==
3
)
{
if
(
lastStageInOutStep
==
LastStageInOutStep
.
None
)
{
lastStageInOutStep
=
LastStageInOutStep
.
S1_Out
;
OutStoreExecution
(
curState
[
3
]);
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S1_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S1_In
;
InStoreExecution
(
curState
[
3
],
curState
[
3
]
+
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S1_In
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S2_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S2_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S2_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S2_In
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S3_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S3_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S3_In
;
InStore
(
curState
[
0
],
curState
[
3
]
+
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S3_In
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S4_Out
;
OutStoreExecution
(
curState
[
2
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S4_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S4_In
;
InStore
(
curState
[
2
],
curState
[
2
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S4_In
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
Success
;
ClearToDeleteList
();
LogUtil
.
info
(
LOGGER
,
"所有仓位跑位测试完成"
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
Success
)
{
}
}
else
if
(
needToInStoreNumList
.
Count
==
4
)
{
// MoveToPos(curState[3], curState[3] + 1);
if
(
lastStageInOutStep
==
LastStageInOutStep
.
None
)
{
lastStageInOutStep
=
LastStageInOutStep
.
S1_Out
;
OutStoreExecution
(
curState
[
3
]);
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S1_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S1_In
;
InStoreExecution
(
curState
[
3
],
curState
[
3
]
+
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S1_In
)
// InStore(curState[0], curState[3] - 1);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S2_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S2_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S2_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S2_In
)
// MoveToPos(curState[0], curState[3] + 2);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S3_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S3_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S3_In
;
InStoreExecution
(
curState
[
0
],
curState
[
3
]
+
2
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S3_In
)
// InStore(curState[0], curState[3] - 1);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S4_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S4_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S4_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S4_In
)
//InStore(curState[1], curState[1]);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S5_Out
;
OutStoreExecution
(
curState
[
1
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S5_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S5_In
;
InStore
(
curState
[
1
],
curState
[
1
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S5_In
)
// InStore(curState[3], curState[3]);
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S6_Out
;
OutStoreExecution
(
curState
[
3
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S6_Out
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
S6_In
;
InStore
(
curState
[
3
],
curState
[
3
]);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
S6_In
)
{
if
(
IsMoveFinished
())
{
lastStageInOutStep
=
LastStageInOutStep
.
Success
;
ClearToDeleteList
();
LogUtil
.
info
(
LOGGER
,
"所有仓位跑位测试完成"
);
}
}
else
if
(
lastStageInOutStep
==
LastStageInOutStep
.
Success
)
{
}
}
else
if
(
needToInStoreNumList
.
Count
>
4
)
{
InOutMainProcess
();
}
}
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
ex
.
ToString
());
}
}
/// <summary>
/// 循环体执行流程
/// </summary>
void
InOutMainProcess
()
{
if
(
generalInOutStep
==
GeneralInOutStep
.
None
)
// MoveToPos(curState[3], curState[3] + 1);
{
generalInOutStep
=
GeneralInOutStep
.
S1_Out
;
OutStoreExecution
(
curState
[
3
]);
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S1_Out
)
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S1_In
;
InStoreExecution
(
curState
[
3
],
curState
[
3
]
+
1
);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S1_In
)
// InStore(curState[0], curState[3] - 1);
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S2_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S2_Out
)
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S2_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S2_In
)
// MoveToPos(curState[0], curState[3] + 2);
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S3_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S3_Out
)
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S3_In
;
InStoreExecution
(
curState
[
0
],
curState
[
3
]
+
2
);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S3_In
)
// InStore(curState[0], curState[3] - 1);
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S4_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S4_Out
)
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S4_In
;
InStore
(
curState
[
0
],
curState
[
3
]
-
1
);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S4_In
)
//MoveToPos(curState[1], curState[3] + 1);
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S5_Out
;
OutStoreExecution
(
curState
[
1
]);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S5_Out
)
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S5_In
;
InStoreExecution
(
curState
[
1
],
curState
[
3
]
+
1
);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S5_In
)
// InStore(curState[2], curState[0] + 1);
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S6_Out
;
OutStoreExecution
(
curState
[
2
]);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S6_Out
)
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S6_In
;
InStore
(
curState
[
2
],
curState
[
0
]
+
1
);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S6_In
)
//InStore(curState[1], curState[3] - 1);
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S7_Out
;
OutStoreExecution
(
curState
[
1
]);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S7_Out
)
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S7_In
;
InStore
(
curState
[
1
],
curState
[
3
]
-
1
);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S7_In
)
// MoveToPos(curState[0], curState[0] + 1);
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S8_Out
;
OutStoreExecution
(
curState
[
0
]);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S8_Out
)
{
if
(
IsMoveFinished
())
{
generalInOutStep
=
GeneralInOutStep
.
S8_In
;
InStoreExecution
(
curState
[
0
],
curState
[
0
]
+
1
);
}
}
else
if
(
generalInOutStep
==
GeneralInOutStep
.
S8_In
)
{
if
(
IsMoveFinished
())
{
ClearToDeleteList
();
generalInOutStep
=
GeneralInOutStep
.
None
;
}
}
}
private
void
MainTimer_Tick
(
object
sender
,
EventArgs
e
)
{
if
(!
IsRun
)
return
;
if
(
IsInit
)
//料盘到达初始位置
{
InOutProcess
();
}
else
{
IniPositionProcess
();
}
if
(
curState
.
Count
!=
0
)
//将目前料盘的位置信息更新到按钮中,方便后续出库
{
for
(
int
i
=
0
;
i
<
curState
.
Count
;
i
++)
{
btnOuts
[
i
].
Text
=
PositionNumList
[
curState
[
i
]];
btnOuts
[
i
].
Tag
=
curState
[
i
];
}
}
}
private
void
FrmInOutStore_FormClosing
(
object
sender
,
FormClosingEventArgs
e
)
{
DialogResult
result
=
MessageBox
.
Show
(
"是否确定退出?"
,
"提示"
,
MessageBoxButtons
.
YesNo
,
MessageBoxIcon
.
Question
);
if
(
result
.
Equals
(
DialogResult
.
Yes
))
{
ExitApp
();
}
}
/// <summary>
/// 退出程序
/// </summary>
private
void
ExitApp
()
{
try
{
IsRun
=
false
;
mainTimer
.
Enabled
=
false
;
curState
=
null
;
needToInStoreNumList
.
Clear
();
needToInStoreNumList
=
null
;
IsInit
=
false
;
if
(
lstBoxInOK
.
Items
.
Count
!=
0
)
lstBoxInOK
.
Items
.
Clear
();
}
catch
{
}
}
/// <summary>
/// 出库操作
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private
void
btnOutStore_Click
(
object
sender
,
EventArgs
e
)
{
if
(
store
.
storeRunStatus
>=
StoreRunStatus
.
HomeMoving
)
{
string
selectPositionNum
=
cmbPosition
.
Text
;
store
.
StartOutStoreMove
(
new
InOutParam
(
new
InOutPosInfo
(
"AUTOINOUT"
,
selectPositionNum
)));
}
else
{
MessageBox
.
Show
(
"请先启动料仓!"
);
}
}
/// <summary>
/// 将4个料盘出库操作
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private
void
ManualOutStore
(
object
sender
,
EventArgs
e
)
{
if
(
store
.
storeRunStatus
>=
StoreRunStatus
.
HomeMoving
)
{
if
(
IsMoveFinished
())
{
Button
btn
=
sender
as
Button
;
int
idx
=
(
int
)
btn
.
Tag
;
string
selectPositionNum
=
(
string
)
btn
.
Text
;
//btn.Enabled = false;
store
.
StartOutStoreMove
(
new
InOutParam
(
new
InOutPosInfo
(
"AUTOINOUT"
,
selectPositionNum
)));
}
else
{
MessageBox
.
Show
(
"请先等待当前出/入库操作完成后再进行操作!"
);
}
}
else
{
MessageBox
.
Show
(
"请先启动料仓!"
);
}
}
/// <summary>
/// 检查出库/入库是否完成
/// </summary>
/// <returns></returns>
bool
IsMoveFinished
()
{
if
(
store
.
storeRunStatus
==
StoreRunStatus
.
Runing
&&
store
.
storeStatus
==
StoreStatus
.
StoreOnline
)
return
true
;
return
false
;
}
List
<
string
>
toDeleteList
=
new
List
<
string
>();
public
void
ClearToDeleteList
()
{
foreach
(
string
item
in
toDeleteList
)
{
needToInStoreNumList
.
Remove
(
item
);
}
toDeleteList
.
Clear
();
}
/// <summary>
/// 入库测试成功(上下有料情况)
/// </summary>
/// <param name="fromPositionIdx"></param>
/// <param name="toPositionIdx"></param>
public
void
InStore
(
int
fromPositionIdx
,
int
toPositionIdx
)
{
InStoreExecution
(
fromPositionIdx
,
toPositionIdx
);
toDeleteList
.
Add
(
PositionNumList
[
toPositionIdx
]);
OnInStore
(
PositionNumList
[
toPositionIdx
]);
}
/// <summary>
/// 入库操作
/// </summary>
/// <param name="fromPositionIdx"></param>
/// <param name="toPositionIdx"></param>
public
void
InStoreExecution
(
int
fromPositionIdx
,
int
toPositionIdx
)
{
string
selectPositionNum
=
PositionNumList
[
toPositionIdx
];
curState
.
Remove
(
fromPositionIdx
);
curState
.
Add
(
toPositionIdx
);
curState
.
Sort
();
store
.
StartInStoreMove
(
new
InOutParam
(
new
InOutPosInfo
(
"AUTOINOUT"
,
selectPositionNum
)));
}
/// <summary>
/// 出库操作
/// </summary>
/// <param name="fromPositionIdx"></param>
public
void
OutStoreExecution
(
int
fromPositionIdx
)
{
string
selectPositionNum
=
PositionNumList
[
fromPositionIdx
];
store
.
StartOutStoreMove
(
new
InOutParam
(
new
InOutPosInfo
(
"AUTOINOUT"
,
selectPositionNum
)));
//LogUtil.info(LOGGER, selectPositionNum + "出库");
}
/// <summary>
/// 仓位测试完成
/// </summary>
/// <param name="selectPositionNum"></param>
public
void
OnInStore
(
string
selectPositionNum
)
{
lstBoxInOK
.
Items
.
Add
(
selectPositionNum
);
lstBoxInOK
.
SelectedIndex
=
lstBoxInOK
.
Items
.
Count
-
1
;
grpBoxOKList
.
Text
=
"仓位跑位成功列表_"
+
lstBoxInOK
.
Items
.
Count
+
"/"
+
PositionNumList
.
Count
;
LogUtil
.
info
(
LOGGER
,
selectPositionNum
+
"仓位跑位测试完成"
);
}
}
}
source/HCSingleStore/FrmInOutStore.resx
0 → 100644
查看文件 @
561a996
<?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>
<metadata name="mainTimer.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>
\ No newline at end of file
source/HCSingleStore/HCSingleStore.csproj
查看文件 @
561a996
...
...
@@ -99,6 +99,12 @@
<Compile Include="FrmIdConfig.Designer.cs">
<DependentUpon>FrmIdConfig.cs</DependentUpon>
</Compile>
<Compile Include="FrmInOutStore.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmInOutStore.designer.cs">
<DependentUpon>FrmInOutStore.cs</DependentUpon>
</Compile>
<Compile Include="FrmPwd.cs">
<SubType>Form</SubType>
</Compile>
...
...
@@ -144,6 +150,9 @@
<EmbeddedResource Include="FrmIdConfig.resx">
<DependentUpon>FrmIdConfig.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmInOutStore.resx">
<DependentUpon>FrmInOutStore.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="FrmPwd.resx">
<DependentUpon>FrmPwd.cs</DependentUpon>
</EmbeddedResource>
...
...
source/HuichuanLibrary/HuichuanLibrary.csproj
查看文件 @
561a996
...
...
@@ -32,7 +32,7 @@
</PropertyGroup>
<ItemGroup>
<Reference Include="log4net">
<HintPath>..\dll\log4net.dll</HintPath>
<HintPath>..\
..\
dll\log4net.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论