Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC1250-AssemblyLine
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit b933db27
由
LN
编写于
2019-09-16 10:35:22 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
1
1 个父辈
5744dc8a
显示空白字符变更
内嵌
并排
正在显示
12 个修改的文件
包含
293 行增加
和
182 行删除
source/AssemblyLineClient/FrmLineStore.Designer.cs
source/AssemblyLineClient/FrmLineStore.cs
source/DeviceLibrary/LineConfig/Config_FeedingEquip_1.csv
source/DeviceLibrary/assemblyLine/FeedingEquip.cs
source/DeviceLibrary/assemblyLine/LineBean_Partial.cs
source/DeviceLibrary/assemblyLine/MoveEquip.cs
source/DeviceLibrary/assemblyLine/MoveEquip_Partial.cs
source/DeviceLibrary/assemblyLine/TrayManager.cs
source/DeviceLibrary/deviceLibrary/IO/AIOBOX/AIOBOXManager.cs
source/DeviceLibrary/model/StoreMoveInfo.cs
source/DeviceLibrary/server/BoxInfo.cs
source/DeviceLibrary/server/LineServer.cs
source/AssemblyLineClient/FrmLineStore.Designer.cs
查看文件 @
b933db2
...
@@ -32,7 +32,6 @@
...
@@ -32,7 +32,6 @@
System
.
ComponentModel
.
ComponentResourceManager
resources
=
new
System
.
ComponentModel
.
ComponentResourceManager
(
typeof
(
FrmLineStore
));
System
.
ComponentModel
.
ComponentResourceManager
resources
=
new
System
.
ComponentModel
.
ComponentResourceManager
(
typeof
(
FrmLineStore
));
this
.
tabControl1
=
new
System
.
Windows
.
Forms
.
TabControl
();
this
.
tabControl1
=
new
System
.
Windows
.
Forms
.
TabControl
();
this
.
tabPage1
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
tabPage1
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
btnUpdateStatus
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
groupBox1
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
groupBox1
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
lblPosId
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblPosId
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
txtPosId
=
new
System
.
Windows
.
Forms
.
TextBox
();
this
.
txtPosId
=
new
System
.
Windows
.
Forms
.
TextBox
();
...
@@ -41,14 +40,16 @@
...
@@ -41,14 +40,16 @@
this
.
button2
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button2
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button1
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button1
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
chkDebug
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
chkDebug
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
btnCopyLog
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
chbAutoRun
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
chbAutoRun
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
btnCopyLog
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnClearLog
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
btnClearLog
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
logBox
=
new
System
.
Windows
.
Forms
.
RichTextBox
();
this
.
logBox
=
new
System
.
Windows
.
Forms
.
RichTextBox
();
this
.
btnUpdateStatus
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
groupBox3
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
groupBox3
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
lblWarnMsg
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
chbLineDebug
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
lblStatus
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblStatus
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblCID
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblCID
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
lblWarnMsg
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
menuStrip1
=
new
System
.
Windows
.
Forms
.
MenuStrip
();
this
.
menuStrip1
=
new
System
.
Windows
.
Forms
.
MenuStrip
();
this
.
操作
ToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
操作
ToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
toolStripSeparator1
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
this
.
toolStripSeparator1
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
...
@@ -73,7 +74,6 @@
...
@@ -73,7 +74,6 @@
this
.
toolStripMenuItem1
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
toolStripMenuItem1
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
timer1
=
new
System
.
Windows
.
Forms
.
Timer
(
this
.
components
);
this
.
timer1
=
new
System
.
Windows
.
Forms
.
Timer
(
this
.
components
);
this
.
listView1
=
new
System
.
Windows
.
Forms
.
ListView
();
this
.
listView1
=
new
System
.
Windows
.
Forms
.
ListView
();
this
.
chbLineDebug
=
new
System
.
Windows
.
Forms
.
CheckBox
();
this
.
tabControl1
.
SuspendLayout
();
this
.
tabControl1
.
SuspendLayout
();
this
.
tabPage1
.
SuspendLayout
();
this
.
tabPage1
.
SuspendLayout
();
this
.
groupBox1
.
SuspendLayout
();
this
.
groupBox1
.
SuspendLayout
();
...
@@ -90,11 +90,11 @@
...
@@ -90,11 +90,11 @@
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage1
);
this
.
tabControl1
.
Controls
.
Add
(
this
.
tabPage1
);
this
.
tabControl1
.
DrawMode
=
System
.
Windows
.
Forms
.
TabDrawMode
.
OwnerDrawFixed
;
this
.
tabControl1
.
DrawMode
=
System
.
Windows
.
Forms
.
TabDrawMode
.
OwnerDrawFixed
;
this
.
tabControl1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
tabControl1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
tabControl1
.
Location
=
new
System
.
Drawing
.
Point
(
12
,
230
);
this
.
tabControl1
.
Location
=
new
System
.
Drawing
.
Point
(
495
,
76
);
this
.
tabControl1
.
Multiline
=
true
;
this
.
tabControl1
.
Multiline
=
true
;
this
.
tabControl1
.
Name
=
"tabControl1"
;
this
.
tabControl1
.
Name
=
"tabControl1"
;
this
.
tabControl1
.
SelectedIndex
=
0
;
this
.
tabControl1
.
SelectedIndex
=
0
;
this
.
tabControl1
.
Size
=
new
System
.
Drawing
.
Size
(
1
740
,
498
);
this
.
tabControl1
.
Size
=
new
System
.
Drawing
.
Size
(
1
257
,
652
);
this
.
tabControl1
.
TabIndex
=
0
;
this
.
tabControl1
.
TabIndex
=
0
;
this
.
tabControl1
.
DrawItem
+=
new
System
.
Windows
.
Forms
.
DrawItemEventHandler
(
this
.
tabControl1_DrawItem
);
this
.
tabControl1
.
DrawItem
+=
new
System
.
Windows
.
Forms
.
DrawItemEventHandler
(
this
.
tabControl1_DrawItem
);
//
//
...
@@ -108,23 +108,11 @@
...
@@ -108,23 +108,11 @@
this
.
tabPage1
.
Controls
.
Add
(
this
.
logBox
);
this
.
tabPage1
.
Controls
.
Add
(
this
.
logBox
);
this
.
tabPage1
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage1
.
Location
=
new
System
.
Drawing
.
Point
(
4
,
29
);
this
.
tabPage1
.
Name
=
"tabPage1"
;
this
.
tabPage1
.
Name
=
"tabPage1"
;
this
.
tabPage1
.
Size
=
new
System
.
Drawing
.
Size
(
1
732
,
465
);
this
.
tabPage1
.
Size
=
new
System
.
Drawing
.
Size
(
1
249
,
619
);
this
.
tabPage1
.
TabIndex
=
0
;
this
.
tabPage1
.
TabIndex
=
0
;
this
.
tabPage1
.
Text
=
" 日志信息 "
;
this
.
tabPage1
.
Text
=
" 日志信息 "
;
this
.
tabPage1
.
UseVisualStyleBackColor
=
true
;
this
.
tabPage1
.
UseVisualStyleBackColor
=
true
;
//
//
// btnUpdateStatus
//
this
.
btnUpdateStatus
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnUpdateStatus
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnUpdateStatus
.
Location
=
new
System
.
Drawing
.
Point
(
241
,
82
);
this
.
btnUpdateStatus
.
Name
=
"btnUpdateStatus"
;
this
.
btnUpdateStatus
.
Size
=
new
System
.
Drawing
.
Size
(
213
,
35
);
this
.
btnUpdateStatus
.
TabIndex
=
195
;
this
.
btnUpdateStatus
.
Text
=
"更改为调试状态"
;
this
.
btnUpdateStatus
.
UseVisualStyleBackColor
=
false
;
this
.
btnUpdateStatus
.
Click
+=
new
System
.
EventHandler
(
this
.
btnUpdateStatus_Click
);
//
// groupBox1
// groupBox1
//
//
this
.
groupBox1
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
this
.
groupBox1
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
...
@@ -137,7 +125,7 @@
...
@@ -137,7 +125,7 @@
this
.
groupBox1
.
Controls
.
Add
(
this
.
button1
);
this
.
groupBox1
.
Controls
.
Add
(
this
.
button1
);
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
609
,
5
);
this
.
groupBox1
.
Location
=
new
System
.
Drawing
.
Point
(
609
,
5
);
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Name
=
"groupBox1"
;
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
1115
,
78
);
this
.
groupBox1
.
Size
=
new
System
.
Drawing
.
Size
(
632
,
78
);
this
.
groupBox1
.
TabIndex
=
195
;
this
.
groupBox1
.
TabIndex
=
195
;
this
.
groupBox1
.
TabStop
=
false
;
this
.
groupBox1
.
TabStop
=
false
;
this
.
groupBox1
.
Text
=
"料仓通信测试"
;
this
.
groupBox1
.
Text
=
"料仓通信测试"
;
...
@@ -214,18 +202,6 @@
...
@@ -214,18 +202,6 @@
this
.
chkDebug
.
Text
=
"开启DEBUG日志"
;
this
.
chkDebug
.
Text
=
"开启DEBUG日志"
;
this
.
chkDebug
.
UseVisualStyleBackColor
=
true
;
this
.
chkDebug
.
UseVisualStyleBackColor
=
true
;
//
//
// btnCopyLog
//
this
.
btnCopyLog
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnCopyLog
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnCopyLog
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
25
);
this
.
btnCopyLog
.
Name
=
"btnCopyLog"
;
this
.
btnCopyLog
.
Size
=
new
System
.
Drawing
.
Size
(
105
,
35
);
this
.
btnCopyLog
.
TabIndex
=
191
;
this
.
btnCopyLog
.
Text
=
"复制"
;
this
.
btnCopyLog
.
UseVisualStyleBackColor
=
false
;
this
.
btnCopyLog
.
Click
+=
new
System
.
EventHandler
(
this
.
btnCopyLog_Click
);
//
// chbAutoRun
// chbAutoRun
//
//
this
.
chbAutoRun
.
AutoSize
=
true
;
this
.
chbAutoRun
.
AutoSize
=
true
;
...
@@ -238,6 +214,18 @@
...
@@ -238,6 +214,18 @@
this
.
chbAutoRun
.
UseVisualStyleBackColor
=
true
;
this
.
chbAutoRun
.
UseVisualStyleBackColor
=
true
;
this
.
chbAutoRun
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
chbAutoRun_CheckedChanged
);
this
.
chbAutoRun
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
chbAutoRun_CheckedChanged
);
//
//
// btnCopyLog
//
this
.
btnCopyLog
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnCopyLog
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnCopyLog
.
Location
=
new
System
.
Drawing
.
Point
(
19
,
25
);
this
.
btnCopyLog
.
Name
=
"btnCopyLog"
;
this
.
btnCopyLog
.
Size
=
new
System
.
Drawing
.
Size
(
105
,
35
);
this
.
btnCopyLog
.
TabIndex
=
191
;
this
.
btnCopyLog
.
Text
=
"复制"
;
this
.
btnCopyLog
.
UseVisualStyleBackColor
=
false
;
this
.
btnCopyLog
.
Click
+=
new
System
.
EventHandler
(
this
.
btnCopyLog_Click
);
//
// btnClearLog
// btnClearLog
//
//
this
.
btnClearLog
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnClearLog
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
...
@@ -258,10 +246,22 @@
...
@@ -258,10 +246,22 @@
this
.
logBox
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
logBox
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
logBox
.
Location
=
new
System
.
Drawing
.
Point
(
10
,
89
);
this
.
logBox
.
Location
=
new
System
.
Drawing
.
Point
(
10
,
89
);
this
.
logBox
.
Name
=
"logBox"
;
this
.
logBox
.
Name
=
"logBox"
;
this
.
logBox
.
Size
=
new
System
.
Drawing
.
Size
(
1
714
,
370
);
this
.
logBox
.
Size
=
new
System
.
Drawing
.
Size
(
1
231
,
524
);
this
.
logBox
.
TabIndex
=
106
;
this
.
logBox
.
TabIndex
=
106
;
this
.
logBox
.
Text
=
""
;
this
.
logBox
.
Text
=
""
;
//
//
// btnUpdateStatus
//
this
.
btnUpdateStatus
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
btnUpdateStatus
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnUpdateStatus
.
Location
=
new
System
.
Drawing
.
Point
(
241
,
82
);
this
.
btnUpdateStatus
.
Name
=
"btnUpdateStatus"
;
this
.
btnUpdateStatus
.
Size
=
new
System
.
Drawing
.
Size
(
213
,
35
);
this
.
btnUpdateStatus
.
TabIndex
=
195
;
this
.
btnUpdateStatus
.
Text
=
"更改为调试状态"
;
this
.
btnUpdateStatus
.
UseVisualStyleBackColor
=
false
;
this
.
btnUpdateStatus
.
Click
+=
new
System
.
EventHandler
(
this
.
btnUpdateStatus_Click
);
//
// groupBox3
// groupBox3
//
//
this
.
groupBox3
.
Controls
.
Add
(
this
.
btnUpdateStatus
);
this
.
groupBox3
.
Controls
.
Add
(
this
.
btnUpdateStatus
);
...
@@ -276,17 +276,17 @@
...
@@ -276,17 +276,17 @@
this
.
groupBox3
.
TabStop
=
false
;
this
.
groupBox3
.
TabStop
=
false
;
this
.
groupBox3
.
Text
=
"流水线信息"
;
this
.
groupBox3
.
Text
=
"流水线信息"
;
//
//
//
lblWarnMs
g
//
chbLineDebu
g
//
//
this
.
lblWarnMsg
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
this
.
chbLineDebug
.
AutoSize
=
true
;
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
chbLineDebug
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblWarnMsg
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
))
);
this
.
chbLineDebug
.
Location
=
new
System
.
Drawing
.
Point
(
14
,
82
);
this
.
lblWarnMsg
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
chbLineDebug
.
Name
=
"chbLineDebug"
;
this
.
lblWarnMsg
.
Location
=
new
System
.
Drawing
.
Point
(
261
,
4
);
this
.
chbLineDebug
.
Size
=
new
System
.
Drawing
.
Size
(
126
,
2
4
);
this
.
lblWarnMsg
.
Name
=
"lblWarnMsg"
;
this
.
chbLineDebug
.
TabIndex
=
196
;
this
.
lblWarnMsg
.
Size
=
new
System
.
Drawing
.
Size
(
1491
,
69
)
;
this
.
chbLineDebug
.
Text
=
"流水线运转测试"
;
this
.
lblWarnMsg
.
TabIndex
=
96
;
this
.
chbLineDebug
.
UseVisualStyleBackColor
=
true
;
this
.
lblWarnMsg
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
this
.
chbLineDebug
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
chbLineDebug_CheckedChanged
)
;
//
//
// lblStatus
// lblStatus
//
//
...
@@ -310,6 +310,18 @@
...
@@ -310,6 +310,18 @@
this
.
lblCID
.
TabIndex
=
95
;
this
.
lblCID
.
TabIndex
=
95
;
this
.
lblCID
.
Text
=
"CID"
;
this
.
lblCID
.
Text
=
"CID"
;
//
//
// lblWarnMsg
//
this
.
lblWarnMsg
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Right
)));
this
.
lblWarnMsg
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblWarnMsg
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
lblWarnMsg
.
Location
=
new
System
.
Drawing
.
Point
(
261
,
4
);
this
.
lblWarnMsg
.
Name
=
"lblWarnMsg"
;
this
.
lblWarnMsg
.
Size
=
new
System
.
Drawing
.
Size
(
1491
,
69
);
this
.
lblWarnMsg
.
TabIndex
=
96
;
this
.
lblWarnMsg
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
//
// menuStrip1
// menuStrip1
//
//
this
.
menuStrip1
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
this
.
menuStrip1
.
BackColor
=
System
.
Drawing
.
Color
.
White
;
...
@@ -346,9 +358,9 @@
...
@@ -346,9 +358,9 @@
this
.
toolStripSeparator1
.
Name
=
"toolStripSeparator1"
;
this
.
toolStripSeparator1
.
Name
=
"toolStripSeparator1"
;
this
.
toolStripSeparator1
.
Size
=
new
System
.
Drawing
.
Size
(
141
,
6
);
this
.
toolStripSeparator1
.
Size
=
new
System
.
Drawing
.
Size
(
141
,
6
);
//
//
// 启动
所有料仓
AToolStripMenuItem
// 启动AToolStripMenuItem
//
//
this
.
启动
AToolStripMenuItem
.
Name
=
"启动
所有料仓
AToolStripMenuItem"
;
this
.
启动
AToolStripMenuItem
.
Name
=
"启动AToolStripMenuItem"
;
this
.
启动
AToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
144
,
26
);
this
.
启动
AToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
144
,
26
);
this
.
启动
AToolStripMenuItem
.
Text
=
"启动 "
;
this
.
启动
AToolStripMenuItem
.
Text
=
"启动 "
;
this
.
启动
AToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
启动所有料仓
AToolStripMenuItem_Click
);
this
.
启动
AToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
启动所有料仓
AToolStripMenuItem_Click
);
...
@@ -370,9 +382,9 @@
...
@@ -370,9 +382,9 @@
this
.
toolStripSeparator3
.
Name
=
"toolStripSeparator3"
;
this
.
toolStripSeparator3
.
Name
=
"toolStripSeparator3"
;
this
.
toolStripSeparator3
.
Size
=
new
System
.
Drawing
.
Size
(
141
,
6
);
this
.
toolStripSeparator3
.
Size
=
new
System
.
Drawing
.
Size
(
141
,
6
);
//
//
// 停止
所有料仓
TToolStripMenuItem
// 停止TToolStripMenuItem
//
//
this
.
停止
TToolStripMenuItem
.
Name
=
"停止
所有料仓
TToolStripMenuItem"
;
this
.
停止
TToolStripMenuItem
.
Name
=
"停止TToolStripMenuItem"
;
this
.
停止
TToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
144
,
26
);
this
.
停止
TToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
144
,
26
);
this
.
停止
TToolStripMenuItem
.
Text
=
"停止"
;
this
.
停止
TToolStripMenuItem
.
Text
=
"停止"
;
this
.
停止
TToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
停止所有料仓
TToolStripMenuItem_Click
);
this
.
停止
TToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
停止所有料仓
TToolStripMenuItem_Click
);
...
@@ -484,33 +496,21 @@
...
@@ -484,33 +496,21 @@
//
//
// listView1
// listView1
//
//
this
.
listView1
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Left
)
this
.
listView1
.
Anchor
=
((
System
.
Windows
.
Forms
.
AnchorStyles
)(((
System
.
Windows
.
Forms
.
AnchorStyles
.
Top
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Bottom
)
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Righ
t
)));
|
System
.
Windows
.
Forms
.
AnchorStyles
.
Lef
t
)));
this
.
listView1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
listView1
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
listView1
.
FullRowSelect
=
true
;
this
.
listView1
.
FullRowSelect
=
true
;
this
.
listView1
.
GridLines
=
true
;
this
.
listView1
.
GridLines
=
true
;
this
.
listView1
.
HideSelection
=
false
;
this
.
listView1
.
HideSelection
=
false
;
this
.
listView1
.
Location
=
new
System
.
Drawing
.
Point
(
495
,
80
);
this
.
listView1
.
Location
=
new
System
.
Drawing
.
Point
(
12
,
224
);
this
.
listView1
.
MultiSelect
=
false
;
this
.
listView1
.
MultiSelect
=
false
;
this
.
listView1
.
Name
=
"listView1"
;
this
.
listView1
.
Name
=
"listView1"
;
this
.
listView1
.
Size
=
new
System
.
Drawing
.
Size
(
1257
,
136
);
this
.
listView1
.
Size
=
new
System
.
Drawing
.
Size
(
477
,
504
);
this
.
listView1
.
TabIndex
=
191
;
this
.
listView1
.
TabIndex
=
191
;
this
.
listView1
.
UseCompatibleStateImageBehavior
=
false
;
this
.
listView1
.
UseCompatibleStateImageBehavior
=
false
;
this
.
listView1
.
View
=
System
.
Windows
.
Forms
.
View
.
Details
;
this
.
listView1
.
View
=
System
.
Windows
.
Forms
.
View
.
Details
;
this
.
listView1
.
SelectedIndexChanged
+=
new
System
.
EventHandler
(
this
.
listView1_SelectedIndexChanged
);
this
.
listView1
.
SelectedIndexChanged
+=
new
System
.
EventHandler
(
this
.
listView1_SelectedIndexChanged
);
//
//
// chbLineDebug
//
this
.
chbLineDebug
.
AutoSize
=
true
;
this
.
chbLineDebug
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
10.5F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
chbLineDebug
.
Location
=
new
System
.
Drawing
.
Point
(
14
,
82
);
this
.
chbLineDebug
.
Name
=
"chbLineDebug"
;
this
.
chbLineDebug
.
Size
=
new
System
.
Drawing
.
Size
(
126
,
24
);
this
.
chbLineDebug
.
TabIndex
=
196
;
this
.
chbLineDebug
.
Text
=
"流水线运转测试"
;
this
.
chbLineDebug
.
UseVisualStyleBackColor
=
true
;
this
.
chbLineDebug
.
CheckedChanged
+=
new
System
.
EventHandler
(
this
.
chbLineDebug_CheckedChanged
);
//
// FrmLineStore
// FrmLineStore
//
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
6F
,
12F
);
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
6F
,
12F
);
...
...
source/AssemblyLineClient/FrmLineStore.cs
查看文件 @
b933db2
...
@@ -44,29 +44,27 @@ namespace OnlineStore.AssemblyLine
...
@@ -44,29 +44,27 @@ namespace OnlineStore.AssemblyLine
FrmIOStatus
ioStatus
=
new
FrmIOStatus
();
FrmIOStatus
ioStatus
=
new
FrmIOStatus
();
AddForm
(
" 流水线IO状态 "
,
ioStatus
);
AddForm
(
" 流水线IO状态 "
,
ioStatus
);
List
<
MoveEquip
>
moveEquipList
=
new
List
<
MoveEquip
>(
lineBean
.
MoveEquipMap
.
Values
);
for
(
int
i
=
0
;
i
<
moveEquipList
.
Count
;
i
++)
{
MoveEquip
store
=
moveEquipList
[
i
];
FrmMoveEquip
test
=
new
FrmMoveEquip
(
store
);
AddForm
(
" "
+
store
.
Name
,
test
);
}
List
<
FeedingEquip
>
feeds
=
new
List
<
FeedingEquip
>(
lineBean
.
FeedingEquipMap
.
Values
);
List
<
FeedingEquip
>
feeds
=
new
List
<
FeedingEquip
>(
lineBean
.
FeedingEquipMap
.
Values
);
for
(
int
i
=
0
;
i
<
feeds
.
Count
;
i
++)
for
(
int
i
=
0
;
i
<
feeds
.
Count
;
i
++)
{
{
FeedingEquip
feed
=
feeds
[
i
];
FeedingEquip
feed
=
feeds
[
i
];
FrmFeedingEquip
test
=
new
FrmFeedingEquip
(
feed
);
FrmFeedingEquip
test
=
new
FrmFeedingEquip
(
feed
);
AddForm
(
" "
+
feed
.
Name
,
test
);
AddForm
(
" "
+
feed
.
Name
+
" "
,
test
);
}
}
List
<
ProvidingEquip
>
provids
=
new
List
<
ProvidingEquip
>(
lineBean
.
ProvidingEquipMap
.
Values
);
List
<
ProvidingEquip
>
provids
=
new
List
<
ProvidingEquip
>(
lineBean
.
ProvidingEquipMap
.
Values
);
for
(
int
i
=
0
;
i
<
provids
.
Count
;
i
++)
for
(
int
i
=
0
;
i
<
provids
.
Count
;
i
++)
{
{
ProvidingEquip
provid
=
provids
[
i
];
ProvidingEquip
provid
=
provids
[
i
];
FrmProvidingEquip
test
=
new
FrmProvidingEquip
(
provid
);
FrmProvidingEquip
test
=
new
FrmProvidingEquip
(
provid
);
AddForm
(
" "
+
provid
.
Name
,
test
);
AddForm
(
" "
+
provid
.
Name
+
" "
,
test
);
}
List
<
MoveEquip
>
moveEquipList
=
new
List
<
MoveEquip
>(
lineBean
.
MoveEquipMap
.
Values
);
for
(
int
i
=
0
;
i
<
moveEquipList
.
Count
;
i
++)
{
MoveEquip
store
=
moveEquipList
[
i
];
FrmMoveEquip
test
=
new
FrmMoveEquip
(
store
);
AddForm
(
" "
+
store
.
Name
,
test
);
}
}
lblCID
.
Text
=
ConfigAppSettings
.
GetValue
(
Setting_Init
.
Line_CID
);
lblCID
.
Text
=
ConfigAppSettings
.
GetValue
(
Setting_Init
.
Line_CID
);
chbLineDebug
.
Checked
=
TrayManager
.
LineRunTest
;
chbLineDebug
.
Checked
=
TrayManager
.
LineRunTest
;
...
@@ -109,14 +107,14 @@ namespace OnlineStore.AssemblyLine
...
@@ -109,14 +107,14 @@ namespace OnlineStore.AssemblyLine
private
void
LoadListView
()
private
void
LoadListView
()
{
{
this
.
listView1
.
Columns
.
Clear
();
this
.
listView1
.
Columns
.
Clear
();
AddHealder
(
"设备名称"
,
1
4
0
);
AddHealder
(
"设备名称"
,
1
0
0
);
AddHealder
(
"
移栽报警"
,
8
0
);
AddHealder
(
"
报警"
,
10
0
);
// AddHealder("设备状态", 100);
// AddHealder("设备状态", 100);
AddHealder
(
"
移栽状态"
,
15
0
);
AddHealder
(
"
状态"
,
10
0
);
AddHealder
(
"BOX_CID"
,
80
);
AddHealder
(
"BOX_CID"
,
80
);
AddHealder
(
"BOX报警"
,
100
);
AddHealder
(
"BOX报警"
,
100
);
AddHealder
(
"更新时间"
,
80
);
AddHealder
(
"更新时间"
,
80
);
AddHealder
(
"BOX状态"
,
listView1
.
Size
.
Width
-
100
-
80
-
80
-
1
50
-
80
-
14
0
-
8
);
AddHealder
(
"BOX状态"
,
listView1
.
Size
.
Width
-
100
-
80
-
80
-
1
00
-
100
-
10
0
-
8
);
foreach
(
MoveEquip
move
in
lineBean
.
MoveEquipMap
.
Values
)
foreach
(
MoveEquip
move
in
lineBean
.
MoveEquipMap
.
Values
)
{
{
ListViewItem
lvi
=
new
ListViewItem
();
ListViewItem
lvi
=
new
ListViewItem
();
...
@@ -141,7 +139,28 @@ namespace OnlineStore.AssemblyLine
...
@@ -141,7 +139,28 @@ namespace OnlineStore.AssemblyLine
}
}
this
.
listView1
.
Items
.
Add
(
lvi
);
this
.
listView1
.
Items
.
Add
(
lvi
);
}
}
ListViewItem
emptyView
=
new
ListViewItem
();
this
.
listView1
.
Items
.
Add
(
emptyView
);
foreach
(
FeedingEquip
equip
in
lineBean
.
FeedingEquipMap
.
Values
)
{
ListViewItem
lvi
=
new
ListViewItem
();
lvi
.
Text
=
equip
.
Name
;
lvi
.
SubItems
.
Add
(
equip
.
alarmType
.
ToString
());
// lvi.SubItems.Add(move.lineStatus.ToString());
lvi
.
SubItems
.
Add
(
KTK_Store
.
GetRunStr
(
equip
.
lineStatus
,
equip
.
runStatus
));
this
.
listView1
.
Items
.
Add
(
lvi
);
}
this
.
listView1
.
Items
.
Add
((
ListViewItem
)
emptyView
.
Clone
());
foreach
(
ProvidingEquip
equip
in
lineBean
.
ProvidingEquipMap
.
Values
)
{
ListViewItem
lvi
=
new
ListViewItem
();
lvi
.
Text
=
equip
.
Name
;
lvi
.
SubItems
.
Add
(
equip
.
alarmType
.
ToString
());
// lvi.SubItems.Add(move.lineStatus.ToString());
lvi
.
SubItems
.
Add
(
KTK_Store
.
GetRunStr
(
equip
.
lineStatus
,
equip
.
runStatus
));
this
.
listView1
.
Items
.
Add
(
lvi
);
}
cmbBoxIndex
.
Items
.
Clear
();
cmbBoxIndex
.
Items
.
Clear
();
foreach
(
int
key
in
lineBean
.
MoveEquipMap
.
Keys
)
foreach
(
int
key
in
lineBean
.
MoveEquipMap
.
Keys
)
{
{
...
@@ -381,8 +400,6 @@ namespace OnlineStore.AssemblyLine
...
@@ -381,8 +400,6 @@ namespace OnlineStore.AssemblyLine
ListViewItem
lvi
=
new
ListViewItem
();
ListViewItem
lvi
=
new
ListViewItem
();
lvi
.
Text
=
move
.
Name
;
lvi
.
Text
=
move
.
Name
;
SetItemText
(
i
,
1
,
move
.
alarmType
.
ToString
());
SetItemText
(
i
,
1
,
move
.
alarmType
.
ToString
());
// this.listView1.Items[i].SubItems[2].Text = move.lineStatus.ToString();
SetItemText
(
i
,
2
,
KTK_Store
.
GetRunStr
(
move
.
lineStatus
,
move
.
runStatus
));
SetItemText
(
i
,
2
,
KTK_Store
.
GetRunStr
(
move
.
lineStatus
,
move
.
runStatus
));
BoxInfo
box
=
LineServer
.
GetBoxInfo
(
move
.
DeviceID
);
BoxInfo
box
=
LineServer
.
GetBoxInfo
(
move
.
DeviceID
);
if
(
box
!=
null
)
if
(
box
!=
null
)
...
@@ -391,28 +408,26 @@ namespace OnlineStore.AssemblyLine
...
@@ -391,28 +408,26 @@ namespace OnlineStore.AssemblyLine
SetItemText
(
i
,
4
,
box
.
SAlarmType
.
ToString
());
SetItemText
(
i
,
4
,
box
.
SAlarmType
.
ToString
());
SetItemText
(
i
,
5
,
box
.
LastMsgTime
.
ToLongTimeString
());
SetItemText
(
i
,
5
,
box
.
LastMsgTime
.
ToLongTimeString
());
SetItemText
(
i
,
6
,
box
.
ToShowStr
());
SetItemText
(
i
,
6
,
box
.
ToShowStr
());
}
}
if
(
move
.
runStatus
.
Equals
(
LineRunStatus
.
Wait
))
SetItemColor
(
i
,
move
.
runStatus
);
{
i
++;
SetItemColor
(
i
,
Color
.
White
);
//listView1.Items[i].BackColor = Color.White;
}
else
if
(
move
.
runStatus
.
Equals
(
LineRunStatus
.
HomeMoving
)
||
move
.
runStatus
.
Equals
(
LineRunStatus
.
Reset
))
{
SetItemColor
(
i
,
Color
.
Orange
);
}
}
else
if
(
move
.
runStatus
.
Equals
(
LineRunStatus
.
Busy
))
i
++;
foreach
(
FeedingEquip
equip
in
lineBean
.
FeedingEquipMap
.
Values
)
{
{
SetItemColor
(
i
,
Color
.
Green
);
SetItemText
(
i
,
1
,
equip
.
alarmType
.
ToString
());
SetItemText
(
i
,
2
,
KTK_Store
.
GetRunStr
(
equip
.
lineStatus
,
equip
.
runStatus
));
SetItemColor
(
i
,
equip
.
runStatus
);
i
++;
}
}
if
(
move
.
runStatus
.
Equals
(
LineRunStatus
.
Runing
))
i
++;
foreach
(
ProvidingEquip
equip
in
lineBean
.
ProvidingEquipMap
.
Values
)
{
{
SetItemColor
(
i
,
Color
.
LightBlue
);
SetItemText
(
i
,
1
,
equip
.
alarmType
.
ToString
());
}
SetItemText
(
i
,
2
,
KTK_Store
.
GetRunStr
(
equip
.
lineStatus
,
equip
.
runStatus
));
SetItemColor
(
i
,
equip
.
runStatus
);
i
++;
i
++;
}
}
if
(
lineBean
.
runStatus
>
LineRunStatus
.
Wait
)
if
(
lineBean
.
runStatus
>
LineRunStatus
.
Wait
)
{
{
if
(
启动
AToolStripMenuItem
.
Enabled
.
Equals
(
true
))
if
(
启动
AToolStripMenuItem
.
Enabled
.
Equals
(
true
))
...
@@ -436,6 +451,28 @@ namespace OnlineStore.AssemblyLine
...
@@ -436,6 +451,28 @@ namespace OnlineStore.AssemblyLine
SetMenuS
(
停止
TToolStripMenuItem
,
false
);
SetMenuS
(
停止
TToolStripMenuItem
,
false
);
}
}
}
}
private
void
SetItemColor
(
int
i
,
LineRunStatus
runStatus
)
{
if
(
runStatus
.
Equals
(
LineRunStatus
.
Wait
))
{
SetItemColor
(
i
,
Color
.
White
);
//listView1.Items[i].BackColor = Color.White;
}
else
if
(
runStatus
.
Equals
(
LineRunStatus
.
HomeMoving
)
||
runStatus
.
Equals
(
LineRunStatus
.
Reset
))
{
SetItemColor
(
i
,
Color
.
Orange
);
}
else
if
(
runStatus
.
Equals
(
LineRunStatus
.
Busy
))
{
SetItemColor
(
i
,
Color
.
Green
);
}
if
(
runStatus
.
Equals
(
LineRunStatus
.
Runing
))
{
SetItemColor
(
i
,
Color
.
LightBlue
);
}
}
private
void
SetMenuS
(
ToolStripMenuItem
toolMenu
,
bool
isEn
)
private
void
SetMenuS
(
ToolStripMenuItem
toolMenu
,
bool
isEn
)
{
{
if
(!
toolMenu
.
Enabled
.
Equals
(
isEn
))
if
(!
toolMenu
.
Enabled
.
Equals
(
isEn
))
...
...
source/DeviceLibrary/LineConfig/Config_FeedingEquip_1.csv
查看文件 @
b933db2
类型,分类编号,说明,名称,属性值,设备名称,默认值,描述,电器定义,代码定义
类型,分类编号,说明,名称,属性值,设备名称,默认值,描述,电器定义,代码定义
PRO,0,设备是否处于调试状态(1=调试,0=正常),IsDebug,1,,,,,
PRO,0,设备是否处于调试状态(1=调试,0=正常),IsDebug,1,,,,,
PRO,0,阻挡气缸控制信号(1-4分别对应夹具检测1-4),StopCylinderIOType,1
,,,,,
,,,,
,,,,,
PRO,0,移栽上下运动是否使用伺服,UpDownUseAxis,0,,,,,
PRO,0,移栽上下运动是否使用伺服,UpDownUseAxis,0,,,,,
PRO,0,移栽上下移动料盘高度对应的上升位置,UpDownPositions,12=1000;16=1300;20=2000;24=2000;36=3000;,,,,,
,
PRO,0,移栽上下移动料盘高度对应的上升位置,UpDownPositions,12=1000;16=1300;20=2000;24=2000;36=3000;,,,,,
AXIS,0,移栽上下轴,UpDown_Axis,2,COM1,0,,,
AXIS,0,移栽上下轴,UpDown_Axis,2,COM1,0,,,
PRO,0,移栽上下轴待机点 P1,UpDownAxisP1,2000,,,,,
PRO,0,移栽上下轴待机点 P1,UpDownAxisP1,2000,,,,,
PRO,0,移栽上下轴目标速度,UpdownAxis_TargetSpeed,150,,,,,
PRO,0,移栽上下轴目标速度,UpdownAxis_TargetSpeed,150,,,,,
...
@@ -11,3 +11,5 @@ PRO,0,移栽上下轴减速度,UpdownAxis_DelSpeed,400,,,,,
...
@@ -11,3 +11,5 @@ PRO,0,移栽上下轴减速度,UpdownAxis_DelSpeed,400,,,,,
PRO,0,移栽上下轴原点低速度,UpdownAxis_HomeLowSpeed,100,,,,,
PRO,0,移栽上下轴原点低速度,UpdownAxis_HomeLowSpeed,100,,,,,
PRO,0,移栽上下轴原点高速,UpdownAxis_HomeHighSpeed,200,,,,,
PRO,0,移栽上下轴原点高速,UpdownAxis_HomeHighSpeed,200,,,,,
PRO,0,移栽上下轴原点加速度,UpdownAxis_HomeAddSpeed,200,,,,,
PRO,0,移栽上下轴原点加速度,UpdownAxis_HomeAddSpeed,200,,,,,
,,,,,,,,,
PRO,0,扫码的相机名称(多个用#分隔),CameraNameList,Name1#Name1,,,,,
source/DeviceLibrary/assemblyLine/FeedingEquip.cs
查看文件 @
b933db2
...
@@ -21,10 +21,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -21,10 +21,6 @@ namespace OnlineStore.DeviceLibrary
public
AxisAlarmInfo
AxisAlarm
=
new
AxisAlarmInfo
();
public
AxisAlarmInfo
AxisAlarm
=
new
AxisAlarmInfo
();
public
FeedingEquip_Config
Config
;
public
FeedingEquip_Config
Config
;
/// <summary>
///入料装置后面分为两条移动线
/// </summary>
public
LineMoveInfo
SecondMoveInfo
=
null
;
// public List<InOutParam> waitOutStoreList = new List<InOutParam>();
// public List<InOutParam> waitOutStoreList = new List<InOutParam>();
public
List
<
InOutParam
>
waitInStoreList
=
new
List
<
InOutParam
>();
public
List
<
InOutParam
>
waitInStoreList
=
new
List
<
InOutParam
>();
...
@@ -47,7 +43,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -47,7 +43,6 @@ namespace OnlineStore.DeviceLibrary
//this.Box = box;
//this.Box = box;
MoveInfo
=
new
LineMoveInfo
(
DeviceID
,
"入料-"
+
DeviceID
+
"-MoveInfo"
);
MoveInfo
=
new
LineMoveInfo
(
DeviceID
,
"入料-"
+
DeviceID
+
"-MoveInfo"
);
SecondMoveInfo
=
new
LineMoveInfo
(
DeviceID
,
"入料-"
+
DeviceID
+
"-SecondMoveInfo"
);
IsDebug
=
config
.
IsDebug
.
Equals
(
1
);
IsDebug
=
config
.
IsDebug
.
Equals
(
1
);
UpdownUseAxis
=
config
.
UpDownUseAxis
.
Equals
(
1
);
UpdownUseAxis
=
config
.
UpDownUseAxis
.
Equals
(
1
);
if
(
UpdownUseAxis
)
if
(
UpdownUseAxis
)
...
@@ -71,7 +66,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -71,7 +66,6 @@ namespace OnlineStore.DeviceLibrary
{
{
mainTimer
.
Enabled
=
false
;
mainTimer
.
Enabled
=
false
;
MoveInfo
.
EndMove
();
MoveInfo
.
EndMove
();
SecondMoveInfo
.
EndMove
();
lineStatus
=
LineStatus
.
StoreOnline
;
lineStatus
=
LineStatus
.
StoreOnline
;
//TODO 调试时暂时注释
//TODO 调试时暂时注释
runStatus
=
LineRunStatus
.
HomeMoving
;
runStatus
=
LineRunStatus
.
HomeMoving
;
...
@@ -82,7 +76,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -82,7 +76,6 @@ namespace OnlineStore.DeviceLibrary
{
{
mainTimer
.
Enabled
=
false
;
mainTimer
.
Enabled
=
false
;
MoveInfo
.
EndMove
();
MoveInfo
.
EndMove
();
SecondMoveInfo
.
EndMove
();
lineStatus
=
LineStatus
.
StoreOnline
;
lineStatus
=
LineStatus
.
StoreOnline
;
//TODO 调试时暂时注释
//TODO 调试时暂时注释
runStatus
=
LineRunStatus
.
HomeMoving
;
runStatus
=
LineRunStatus
.
HomeMoving
;
...
@@ -141,11 +134,11 @@ namespace OnlineStore.DeviceLibrary
...
@@ -141,11 +134,11 @@ namespace OnlineStore.DeviceLibrary
// break;
// break;
default
:
break
;
default
:
break
;
}
}
if
(
MoveInfo
.
MoveType
==
LineMoveType
.
InStore
||
this
.
SecondMoveInfo
.
MoveType
==
LineMoveType
.
InStore
)
if
(
MoveInfo
.
MoveType
==
LineMoveType
.
InStore
)
{
{
InStoreProcess
();
InStoreProcess
();
}
}
else
if
(
MoveInfo
.
MoveType
==
LineMoveType
.
OutStore
||
SecondMoveInfo
.
MoveType
==
LineMoveType
.
OutStore
)
else
if
(
MoveInfo
.
MoveType
==
LineMoveType
.
OutStore
)
{
{
OutStoreProcess
();
OutStoreProcess
();
}
}
...
@@ -161,11 +154,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -161,11 +154,6 @@ namespace OnlineStore.DeviceLibrary
{
{
StopMoveProcess
();
StopMoveProcess
();
}
}
if
(
SecondMoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
CheckFixture
))
{
//CheckFixtureProcess();
}
}
}
...
@@ -191,7 +179,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -191,7 +179,7 @@ namespace OnlineStore.DeviceLibrary
BusyMoveProcess
();
BusyMoveProcess
();
//判断流水线打开了才可以运行
//判断流水线打开了才可以运行
if
(
Second
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
None
))
if
(
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
None
))
{
{
LineBean
lineBean
=
LineManager
.
Line
;
LineBean
lineBean
=
LineManager
.
Line
;
if
(
lineBean
.
isCanProcessLine
()
&&
IOManager
.
IOValue
(
IO_Type
.
DriveMotor_Run
,
0
).
Equals
(
IO_VALUE
.
HIGH
)
&&
lineBean
.
runStatus
>=
LineRunStatus
.
Runing
&&
lineBean
.
IsSleep
.
Equals
(
false
))
if
(
lineBean
.
isCanProcessLine
()
&&
IOManager
.
IOValue
(
IO_Type
.
DriveMotor_Run
,
0
).
Equals
(
IO_VALUE
.
HIGH
)
&&
lineBean
.
runStatus
>=
LineRunStatus
.
Runing
&&
lineBean
.
IsSleep
.
Equals
(
false
))
...
@@ -226,7 +214,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -226,7 +214,7 @@ namespace OnlineStore.DeviceLibrary
}
}
//若BOX和入料都没有在等待Io的过程中则此Io超时异常可能已经处理过
//若BOX和入料都没有在等待Io的过程中则此Io超时异常可能已经处理过
if
(
MoveInfo
.
IsInWait
.
Equals
(
false
)
&&
SecondMoveInfo
.
IsInWait
.
Equals
(
false
)
)
if
(
MoveInfo
.
IsInWait
.
Equals
(
false
))
{
{
LogUtil
.
info
(
Name
+
"清理信号超时报警【"
+
WarnMsg
+
"】 "
);
LogUtil
.
info
(
Name
+
"清理信号超时报警【"
+
WarnMsg
+
"】 "
);
alarmType
=
LineAlarmType
.
None
;
alarmType
=
LineAlarmType
.
None
;
...
@@ -295,7 +283,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -295,7 +283,6 @@ namespace OnlineStore.DeviceLibrary
// currMoveTrayNum = 0;
// currMoveTrayNum = 0;
LogInfo
(
"开始重置:清零上一个托盘号,(上下气缸回原点,阻挡气缸输入=0 )开始;"
);
LogInfo
(
"开始重置:清零上一个托盘号,(上下气缸回原点,阻挡气缸输入=0 )开始;"
);
runStatus
=
LineRunStatus
.
Reset
;
runStatus
=
LineRunStatus
.
Reset
;
SecondMoveInfo
.
EndMove
();
MoveInfo
.
NewMove
(
LineMoveType
.
Reset
);
MoveInfo
.
NewMove
(
LineMoveType
.
Reset
);
UpdownHomeMove
();
UpdownHomeMove
();
...
@@ -323,11 +310,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -323,11 +310,8 @@ namespace OnlineStore.DeviceLibrary
{
{
CheckWait
(
MoveInfo
);
CheckWait
(
MoveInfo
);
}
}
else
if
(
SecondMoveInfo
.
IsInWait
)
{
if
(!
MoveInfo
.
IsInWait
)
CheckWait
(
SecondMoveInfo
);
}
if
(!
MoveInfo
.
IsInWait
&&
!
SecondMoveInfo
.
IsInWait
)
{
{
//流水线各装置复原位,夹料气缸状态不变
//流水线各装置复原位,夹料气缸状态不变
//阻挡气缸全部=0
//阻挡气缸全部=0
...
@@ -351,11 +335,9 @@ namespace OnlineStore.DeviceLibrary
...
@@ -351,11 +335,9 @@ namespace OnlineStore.DeviceLibrary
break
;
break
;
case
LineMoveStep
.
MH_OtherCylinder_Back
:
case
LineMoveStep
.
MH_OtherCylinder_Back
:
LogInfo
(
"重置完成!"
);
LogInfo
(
"重置完成!"
);
runStatus
=
LineRunStatus
.
Runing
;
runStatus
=
LineRunStatus
.
Runing
;
MoveInfo
.
EndMove
();
MoveInfo
.
EndMove
();
SecondMoveInfo
.
EndMove
();
break
;
break
;
//TODO 需要继续之前的的出入库处理
//TODO 需要继续之前的的出入库处理
//ContinueInOutStore();
//ContinueInOutStore();
...
@@ -373,11 +355,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -373,11 +355,7 @@ namespace OnlineStore.DeviceLibrary
{
{
CheckWait
(
MoveInfo
);
CheckWait
(
MoveInfo
);
}
}
if
(
SecondMoveInfo
.
IsInWait
)
if
(!
MoveInfo
.
IsInWait
)
{
CheckWait
(
SecondMoveInfo
);
}
if
(!
MoveInfo
.
IsInWait
&&
!
SecondMoveInfo
.
IsInWait
)
{
{
switch
(
MoveInfo
.
MoveStep
)
switch
(
MoveInfo
.
MoveStep
)
{
{
...
@@ -398,7 +376,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -398,7 +376,6 @@ namespace OnlineStore.DeviceLibrary
case
LineMoveStep
.
MH_OtherCylinder_Back
:
case
LineMoveStep
.
MH_OtherCylinder_Back
:
MoveInfo
.
EndMove
();
MoveInfo
.
EndMove
();
SecondMoveInfo
.
EndMove
();
LogInfo
(
"原点返回完成!"
);
LogInfo
(
"原点返回完成!"
);
runStatus
=
LineRunStatus
.
Runing
;
runStatus
=
LineRunStatus
.
Runing
;
//如果是调试模式,入料装置两个阻挡气缸落下,并且不再移动
//如果是调试模式,入料装置两个阻挡气缸落下,并且不再移动
...
@@ -423,11 +400,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -423,11 +400,8 @@ namespace OnlineStore.DeviceLibrary
{
{
CheckWait
(
MoveInfo
);
CheckWait
(
MoveInfo
);
}
}
if
(
SecondMoveInfo
.
IsInWait
)
{
if
(!
MoveInfo
.
IsInWait
)
CheckWait
(
SecondMoveInfo
);
}
if
(!
MoveInfo
.
IsInWait
&&
!
SecondMoveInfo
.
IsInWait
)
{
{
switch
(
MoveInfo
.
MoveStep
)
switch
(
MoveInfo
.
MoveStep
)
{
{
...
@@ -474,7 +448,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -474,7 +448,6 @@ namespace OnlineStore.DeviceLibrary
MoveInfo
.
EndMove
();
MoveInfo
.
EndMove
();
}
}
runStatus
=
LineRunStatus
.
Busy
;
runStatus
=
LineRunStatus
.
Busy
;
SecondMoveInfo
.
EndMove
();
LogInfo
(
"停止运动:(上下气缸上升端,阻挡气缸输入=0 )开始 "
);
LogInfo
(
"停止运动:(上下气缸上升端,阻挡气缸输入=0 )开始 "
);
...
...
source/DeviceLibrary/assemblyLine/LineBean_Partial.cs
查看文件 @
b933db2
...
@@ -120,7 +120,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -120,7 +120,7 @@ namespace OnlineStore.DeviceLibrary
}
}
else
else
{
{
string
msg
=
Name
+
"
出现托盘顺序错乱,上个托盘号【"
+
preTrayNum
+
"】当前托盘号【"
+
trayNum
+
"(有料盘)
】"
;
string
msg
=
Name
+
"
托盘顺序错乱,上个托盘号【"
+
preTrayNum
+
"】当前有料托盘【"
+
trayNum
+
"】最大盘号【"
+
TrayManager
.
MaxTrayNum
+
"
】"
;
TrayManager
.
UpdateTrayNumError
(
0
,
msg
);
TrayManager
.
UpdateTrayNumError
(
0
,
msg
);
LogUtil
.
error
(
msg
);
LogUtil
.
error
(
msg
);
}
}
...
@@ -169,7 +169,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -169,7 +169,7 @@ namespace OnlineStore.DeviceLibrary
}
}
else
else
{
{
string
msg
=
Name
+
"
出现托盘顺序错乱,上个托盘号【"
+
preTrayNum
+
"】当前托盘号【"
+
trayNum
+
"(空盘)
】"
;
string
msg
=
Name
+
"
托盘顺序错乱,上个托盘号【"
+
preTrayNum
+
"】当前空托盘【"
+
trayNum
+
"】最大盘号【"
+
TrayManager
.
MaxTrayNum
+
"
】"
;
TrayManager
.
UpdateTrayNumError
(
0
,
msg
);
TrayManager
.
UpdateTrayNumError
(
0
,
msg
);
LogUtil
.
error
(
msg
);
LogUtil
.
error
(
msg
);
}
}
...
@@ -181,7 +181,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -181,7 +181,7 @@ namespace OnlineStore.DeviceLibrary
{
{
IsWaitToScan
=
false
;
IsWaitToScan
=
false
;
IsWaitEmptyGo
=
false
;
IsWaitEmptyGo
=
false
;
LogUtil
.
error
(
Name
+
Config
.
StopCylinderIOType
+
"检测到Fixture_Check_4亮,但是托盘号为0,不处理托盘~"
);
LogUtil
.
debug
(
Name
+
Config
.
StopCylinderIOType
+
"检测到Fixture_Check_4亮,但是托盘号为0,不处理托盘~"
);
}
}
}
}
...
@@ -305,6 +305,16 @@ namespace OnlineStore.DeviceLibrary
...
@@ -305,6 +305,16 @@ namespace OnlineStore.DeviceLibrary
else
if
(
wait
.
WaitType
==
3
)
else
if
(
wait
.
WaitType
==
3
)
{
{
wait
.
IsEnd
=
(
span
.
TotalMilliseconds
>=
wait
.
TimeMSeconds
);
wait
.
IsEnd
=
(
span
.
TotalMilliseconds
>=
wait
.
TimeMSeconds
);
}
else
if
(
wait
.
WaitType
==
8
)
{
string
posId
=
checkWaitInfo
.
MoveParam
.
PosId
;
int
id
=
checkWaitInfo
.
MoveParam
.
GetStoreId
();
wait
.
IsEnd
=
LineServer
.
RightInPosId
(
id
,
posId
);
}
else
if
(
wait
.
WaitType
.
Equals
(
9
))
{
int
storeId
=
checkWaitInfo
.
MoveParam
.
GetStoreId
();
wait
.
IsEnd
=
LineServer
.
BoxCanReviceTray
(
storeId
);
}
}
if
(
wait
.
IsEnd
&&
checkWaitInfo
.
OneWaitCanEndStep
)
if
(
wait
.
IsEnd
&&
checkWaitInfo
.
OneWaitCanEndStep
)
{
{
...
@@ -404,9 +414,14 @@ namespace OnlineStore.DeviceLibrary
...
@@ -404,9 +414,14 @@ namespace OnlineStore.DeviceLibrary
InOutLog
(
"开始入库忙碌中[BUSY]"
);
InOutLog
(
"开始入库忙碌中[BUSY]"
);
MoveInfo
.
NewMove
(
LineMoveType
.
InStore
);
MoveInfo
.
NewMove
(
LineMoveType
.
InStore
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
LI_00_Wait100
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
LI_00_Wait100
);
MoveInfo
.
MoveParam
=
param
;
preTrayNum
=
param
.
TrayNumber
;
preTrayNum
=
param
.
TrayNumber
;
//InOutLog("入库处理:(LI_00_Wait100 ,等待300毫秒后再放行 ) 开始");
//StoreMove.WaitList.Add(WaitResultInfo.WaitTime(300));
//等待料仓验证成功,最多等待10秒,若验证不成功,直接失败
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
10000
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitCanInstore
());
MoveInfo
.
OneWaitCanEndStep
=
true
;
}
}
protected
override
void
InStoreProcess
()
protected
override
void
InStoreProcess
()
{
{
...
@@ -425,10 +440,33 @@ namespace OnlineStore.DeviceLibrary
...
@@ -425,10 +440,33 @@ namespace OnlineStore.DeviceLibrary
switch
(
MoveInfo
.
MoveStep
)
switch
(
MoveInfo
.
MoveStep
)
{
{
case
LineMoveStep
.
LI_00_Wait100
:
case
LineMoveStep
.
LI_00_Wait100
:
//判断是否可以入库
string
posId
=
MoveInfo
.
MoveParam
.
PosId
;
int
id
=
MoveInfo
.
MoveParam
.
GetStoreId
();
bool
result
=
LineServer
.
RightInPosId
(
id
,
posId
);
MoveEquip
moveEquip
=
null
;
MoveEquipMap
.
TryGetValue
(
id
,
out
moveEquip
);
if
(!
result
||
moveEquip
==
null
)
{
LogUtil
.
error
(
"入库处理:入库验证失败【"
+
id
+
"】【"
+
posId
+
"】,结束入库"
);
IsScanCode
=
false
;
MoveInfo
.
EndMove
();
runStatus
=
LineRunStatus
.
Runing
;
lineStatus
=
LineStatus
.
StoreOnline
;
}
else
{
lock
(
moveEquip
.
waitInListLock
)
{
//如果当前正在出入库中,需要记录下来,等待空闲时执行
LogUtil
.
info
(
moveEquip
.
Name
+
" 入库命令: "
+
MoveInfo
.
MoveParam
.
ToStr
()
+
"已验证完成 ,写入排队列表中等待!"
);
moveEquip
.
waitInStoreList
.
Add
(
MoveInfo
.
MoveParam
);
}
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
LI_01_StopCylinder2Down
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
LI_01_StopCylinder2Down
);
InOutLog
(
"入库处理:(LI_01_StopCylinder2Down ,阻挡气缸0-1上升,阻挡气缸0-2下降 ) 开始"
);
InOutLog
(
"入库处理:(LI_01_StopCylinder2Down ,阻挡气缸0-1上升,阻挡气缸0-2下降 ) 开始"
);
IOMove
(
IO_Type
.
StopCylinder_Down1
,
IO_VALUE
.
LOW
);
IOMove
(
IO_Type
.
StopCylinder_Down1
,
IO_VALUE
.
LOW
);
IOMove
(
IO_Type
.
StopCylinder_Down2
,
IO_VALUE
.
HIGH
);
IOMove
(
IO_Type
.
StopCylinder_Down2
,
IO_VALUE
.
HIGH
);
}
break
;
break
;
case
LineMoveStep
.
LI_01_StopCylinder2Down
:
case
LineMoveStep
.
LI_01_StopCylinder2Down
:
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
LI_02_FixtureCheck
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
LI_02_FixtureCheck
);
...
...
source/DeviceLibrary/assemblyLine/MoveEquip.cs
查看文件 @
b933db2
...
@@ -33,7 +33,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -33,7 +33,6 @@ namespace OnlineStore.DeviceLibrary
public
MoveEquip
(
string
cid
,
MoveEquip_Config
config
)
public
MoveEquip
(
string
cid
,
MoveEquip_Config
config
)
{
{
baseConfig
=
config
;
this
.
DeviceID
=
config
.
Id
;
this
.
DeviceID
=
config
.
Id
;
this
.
Config
=
config
;
this
.
Config
=
config
;
Name
=
(
" "
+
"_移栽_"
+
DeviceID
+
" "
).
ToUpper
();
Name
=
(
" "
+
"_移栽_"
+
DeviceID
+
" "
).
ToUpper
();
...
...
source/DeviceLibrary/assemblyLine/MoveEquip_Partial.cs
查看文件 @
b933db2
...
@@ -131,6 +131,17 @@ namespace OnlineStore.DeviceLibrary
...
@@ -131,6 +131,17 @@ namespace OnlineStore.DeviceLibrary
{
{
wait
.
IsEnd
=
(
span
.
TotalMilliseconds
>=
wait
.
TimeMSeconds
);
wait
.
IsEnd
=
(
span
.
TotalMilliseconds
>=
wait
.
TimeMSeconds
);
}
}
else
if
(
wait
.
WaitType
==
8
)
{
string
posId
=
moveInfo
.
MoveParam
.
PosId
;
int
id
=
moveInfo
.
MoveParam
.
GetStoreId
();
wait
.
IsEnd
=
LineServer
.
RightInPosId
(
id
,
posId
);
}
else
if
(
wait
.
WaitType
.
Equals
(
9
))
{
int
storeId
=
moveInfo
.
MoveParam
.
GetStoreId
();
wait
.
IsEnd
=
LineServer
.
BoxCanReviceTray
(
storeId
);
}
if
(
wait
.
IsEnd
&&
moveInfo
.
OneWaitCanEndStep
)
if
(
wait
.
IsEnd
&&
moveInfo
.
OneWaitCanEndStep
)
{
{
isOk
=
true
;
isOk
=
true
;
...
@@ -408,11 +419,12 @@ namespace OnlineStore.DeviceLibrary
...
@@ -408,11 +419,12 @@ namespace OnlineStore.DeviceLibrary
}
}
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
MI_09_UpDownCylinderUp
))
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
MI_09_UpDownCylinderUp
))
{
{
InStoreLog
(
"入库:(MI_10_BeforeAfterCylinderBefore,前后气缸1前进)"
);
int
num
=
MoveInfo
.
MoveParam
.
TrayNumber
;
InStoreLog
(
"入库:(MI_10_BeforeAfterCylinderBefore,前后气缸1前进),更新盘号【"
+
num
+
"】为空盘"
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MI_10_BeforeAfterCylinderBefore
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MI_10_BeforeAfterCylinderBefore
);
CylinderMove
(
MoveInfo
,
IO_Type
.
BeforeAfterCylinder_After
,
IO_Type
.
BeforeAfterCylinder_Before
);
CylinderMove
(
MoveInfo
,
IO_Type
.
BeforeAfterCylinder_After
,
IO_Type
.
BeforeAfterCylinder_Before
);
int
num
=
TrayManager
.
GetNum
(
DeviceID
);
//
int num = TrayManager.GetNum(DeviceID);
LogInfo
(
"入库【"
+
posId
+
"】处理: 物品已移走,重新读取并更新盘号【"
+
num
+
"】为空盘"
);
//
LogInfo("入库【" + posId + "】处理: 物品已移走,重新读取并更新盘号【" + num + "】为空盘");
TrayManager
.
UpdateFixtureValue
(
num
,
false
,
0
);
TrayManager
.
UpdateFixtureValue
(
num
,
false
,
0
);
//阻挡气缸移动
//阻挡气缸移动
...
@@ -423,9 +435,9 @@ namespace OnlineStore.DeviceLibrary
...
@@ -423,9 +435,9 @@ namespace OnlineStore.DeviceLibrary
}
}
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
MI_10_BeforeAfterCylinderBefore
))
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
MI_10_BeforeAfterCylinderBefore
))
{
{
LogInfo
(
"入库【"
+
posId
+
"】处理(等待移栽):(判断box门口没有盘
之后,才能把料盘放下
"
);
LogInfo
(
"入库【"
+
posId
+
"】处理(等待移栽):(判断box门口没有盘
, 且可以入库,才能把料盘放下)
"
);
//此处需要等待box门口没有盘
//此处需要等待box门口没有盘
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
Wait
IO
(
IO_Type
.
TrayCheck
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
Wait
BoxCanReviceTray
(
));
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MI_10_WaitBox
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MI_10_WaitBox
);
}
}
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
MI_10_WaitBox
))
else
if
(
MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
MI_10_WaitBox
))
...
@@ -669,7 +681,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -669,7 +681,7 @@ namespace OnlineStore.DeviceLibrary
}
}
else
else
{
{
string
msg
=
Name
+
"
出现托盘顺序错乱,上一个托盘号【"
+
preTrayNum
+
"】当前托盘号 【"
+
currMoveTrayNum
+
"】"
;
string
msg
=
Name
+
"
托盘顺序错乱,上个托盘号【"
+
preTrayNum
+
"】当前托盘号 【"
+
currMoveTrayNum
+
"】最大盘号【"
+
TrayManager
.
MaxTrayNum
+
"】"
;
TrayManager
.
UpdateTrayNumError
(
DeviceID
,
msg
);
TrayManager
.
UpdateTrayNumError
(
DeviceID
,
msg
);
LogUtil
.
error
(
msg
);
LogUtil
.
error
(
msg
);
return
;
return
;
...
@@ -682,7 +694,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -682,7 +694,7 @@ namespace OnlineStore.DeviceLibrary
}
}
else
else
{
{
LogInfo
(
SecondMoveInfo
.
MoveNum
+
"***************上
一个托盘号【"
+
preTrayNum
+
"】,当前托盘号【(isFull="
+
isFull
+
"):"
+
currMoveTrayNum
+
"】没有匹配的
出入库任务,放盘通过~"
);
LogInfo
(
SecondMoveInfo
.
MoveNum
+
"***************上
个托盘号【"
+
preTrayNum
+
"】,当前"
+
(
isFull
?
"有料托盘"
:
"空托盘"
)
+
"【"
+
currMoveTrayNum
+
"】没有
出入库任务,放盘通过~"
);
// preTrayNum = currMoveTrayNum;
// preTrayNum = currMoveTrayNum;
if
(
TrayManager
.
ErrorStoreId
.
Equals
(
DeviceID
))
if
(
TrayManager
.
ErrorStoreId
.
Equals
(
DeviceID
))
{
{
...
@@ -817,6 +829,28 @@ namespace OnlineStore.DeviceLibrary
...
@@ -817,6 +829,28 @@ namespace OnlineStore.DeviceLibrary
}
}
public
void
CylinderMove
(
LineMoveInfo
moveInfo
,
string
IoLowType
,
string
IoHighType
)
{
IOMove
(
IoLowType
,
IO_VALUE
.
LOW
);
IOMove
(
IoHighType
,
IO_VALUE
.
HIGH
);
if
(
moveInfo
!=
null
)
{
moveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IoLowType
,
IO_VALUE
.
LOW
));
moveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IoHighType
,
IO_VALUE
.
HIGH
));
}
}
public
void
IOMove
(
string
IoType
,
IO_VALUE
value
)
{
IOManager
.
IOMove
(
IoType
,
value
,
Config
.
Id
);
}
public
IO_VALUE
IOValue
(
string
IoType
)
{
return
IOManager
.
IOValue
(
IoType
,
Config
.
Id
);
}
public
void
LogInfo
(
string
logInfo
)
{
LogUtil
.
info
(
Name
+
logInfo
);
}
}
}
}
}
source/DeviceLibrary/assemblyLine/TrayManager.cs
查看文件 @
b933db2
...
@@ -159,31 +159,19 @@ namespace OnlineStore.DeviceLibrary
...
@@ -159,31 +159,19 @@ namespace OnlineStore.DeviceLibrary
return
false
;
return
false
;
}
}
/// <summary>
/// 验证托盘号是否正确
/// </summary>
public
static
bool
RightTrayCode
(
int
trayNum
,
int
preTrayNum
,
bool
isCanUpdateMax
)
public
static
bool
RightTrayCode
(
int
trayNum
,
int
preTrayNum
,
bool
isCanUpdateMax
)
{
{
if
(
preTrayNum
==
0
)
int
defNext
=
preTrayNum
+
1
;
{
if
(
preTrayNum
.
Equals
(
0
)
||
MaxTrayNum
.
Equals
(
0
)
||
trayNum
.
Equals
(
defNext
))
return
true
;
}
else
if
(
trayNum
==
preTrayNum
+
1
)
{
return
true
;
}
else
if
(
MaxTrayNum
>
0
&&
trayNum
==
1
&&
preTrayNum
==
MaxTrayNum
)
{
{
return
true
;
if
(
isCanUpdateMax
&&
trayNum
>
MaxTrayNum
)
}
if
(
trayNum
==
1
&&
MaxTrayNum
==
0
&&
isCanUpdateMax
)
{
{
MaxTrayNum
=
preT
rayNum
;
MaxTrayNum
=
t
rayNum
;
LogUtil
.
info
(
"更新MaxTrayNum="
+
preTrayNum
);
LogUtil
.
info
(
"更新MaxTrayNum="
+
preTrayNum
);
}
return
true
;
return
true
;
}
}
else
if
(
isCanUpdateMax
==
false
&&
MaxTrayNum
==
0
)
else
if
(
trayNum
.
Equals
(
1
)
&&
preTrayNum
>=
MaxTrayNum
)
{
{
return
true
;
return
true
;
}
}
...
...
source/DeviceLibrary/deviceLibrary/IO/AIOBOX/AIOBOXManager.cs
查看文件 @
b933db2
...
@@ -520,10 +520,10 @@ namespace OnlineStore.DeviceLibrary
...
@@ -520,10 +520,10 @@ namespace OnlineStore.DeviceLibrary
return
value
;
return
value
;
}
}
private
Box_Addr
GetAddr
(
ushort
StartAddress
)
//
private Box_Addr GetAddr(ushort StartAddress)
{
//
{
return
(
Box_Addr
)(
StartAddress
);
//
return (Box_Addr)(StartAddress);
}
//
}
private
Box_Sta
GetBox_Sta
(
IO_VALUE
onOff
)
private
Box_Sta
GetBox_Sta
(
IO_VALUE
onOff
)
{
{
if
(
onOff
.
Equals
(
IO_VALUE
.
HIGH
))
if
(
onOff
.
Equals
(
IO_VALUE
.
HIGH
))
...
...
source/DeviceLibrary/model/StoreMoveInfo.cs
查看文件 @
b933db2
...
@@ -244,6 +244,18 @@ namespace OnlineStore.DeviceLibrary
...
@@ -244,6 +244,18 @@ namespace OnlineStore.DeviceLibrary
wait
.
IsEnd
=
false
;
wait
.
IsEnd
=
false
;
return
wait
;
return
wait
;
}
}
public
static
WaitResultInfo
WaitCanInstore
()
{
WaitResultInfo
wait
=
new
WaitResultInfo
();
wait
.
WaitType
=
8
;
return
wait
;
}
public
static
WaitResultInfo
WaitBoxCanReviceTray
(
)
{
WaitResultInfo
wait
=
new
WaitResultInfo
();
wait
.
WaitType
=
9
;
return
wait
;
}
public
string
ToStr
()
public
string
ToStr
()
{
{
if
(
WaitType
==
1
)
if
(
WaitType
==
1
)
...
@@ -279,6 +291,13 @@ namespace OnlineStore.DeviceLibrary
...
@@ -279,6 +291,13 @@ namespace OnlineStore.DeviceLibrary
}
else
if
(
WaitType
==
7
)
}
else
if
(
WaitType
==
7
)
{
{
return
"料盘高度【"
+
HeightValue
+
"】 "
;
return
"料盘高度【"
+
HeightValue
+
"】 "
;
}
else
if
(
WaitType
==
8
)
{
return
"入库库位验证完成"
;
}
else
if
(
WaitType
==
9
)
{
return
"入库BOX可以开始入库"
;
}
}
else
else
{
{
...
@@ -334,6 +353,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -334,6 +353,8 @@ namespace OnlineStore.DeviceLibrary
/// 高度
/// 高度
/// </summary>
/// </summary>
public
int
HeightValue
{
get
;
set
;
}
public
int
HeightValue
{
get
;
set
;
}
}
}
public
enum
LineMoveType
public
enum
LineMoveType
{
{
...
...
source/DeviceLibrary/server/BoxInfo.cs
查看文件 @
b933db2
using
System
;
using
System
;
using
System.Collections.Generic
;
namespace
OnlineStore.DeviceLibrary
namespace
OnlineStore.DeviceLibrary
{
{
...
@@ -13,10 +14,10 @@ namespace OnlineStore.DeviceLibrary
...
@@ -13,10 +14,10 @@ namespace OnlineStore.DeviceLibrary
SRunStatus
=
(
int
)
LineRunStatus
.
Wait
;
SRunStatus
=
(
int
)
LineRunStatus
.
Wait
;
SAlarmType
=
LineAlarmType
.
None
;
SAlarmType
=
LineAlarmType
.
None
;
HasTray
=
0
;
HasTray
=
0
;
WaitInStoreList
=
new
List
<
string
>();
}
}
public
BoxInfo
(
int
id
,
string
cid
,
int
seq
,
int
ss
,
int
runs
,
int
hasTray
,
int
alarmType
)
public
BoxInfo
(
int
id
,
string
cid
,
int
seq
,
int
ss
,
int
runs
,
int
hasTray
,
int
alarmType
,
List
<
string
>
inList
)
{
{
this
.
ID
=
id
;
this
.
ID
=
id
;
CId
=
cid
;
CId
=
cid
;
...
@@ -26,6 +27,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -26,6 +27,7 @@ namespace OnlineStore.DeviceLibrary
SAlarmType
=
(
LineAlarmType
)
alarmType
;
SAlarmType
=
(
LineAlarmType
)
alarmType
;
LastMsgTime
=
DateTime
.
Now
;
LastMsgTime
=
DateTime
.
Now
;
this
.
HasTray
=
hasTray
;
this
.
HasTray
=
hasTray
;
this
.
WaitInStoreList
=
inList
;
}
}
public
string
ToShowStr
()
public
string
ToShowStr
()
...
@@ -69,5 +71,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -69,5 +71,6 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
/// </summary>
public
int
HasTray
{
get
;
set
;
}
public
int
HasTray
{
get
;
set
;
}
public
List
<
string
>
WaitInStoreList
=
new
List
<
string
>();
}
}
}
}
source/DeviceLibrary/server/LineServer.cs
查看文件 @
b933db2
...
@@ -71,7 +71,25 @@ namespace OnlineStore.DeviceLibrary
...
@@ -71,7 +71,25 @@ namespace OnlineStore.DeviceLibrary
}
}
return
false
;
return
false
;
}
}
/// <summary>
/// 判断库位是否验证成功
/// </summary>
public
static
bool
RightInPosId
(
int
id
,
string
posId
)
{
BoxInfo
box
=
GetBoxInfo
(
id
);
if
(
box
!=
null
)
{
TimeSpan
span
=
DateTime
.
Now
-
box
.
LastMsgTime
;
if
(
span
.
TotalSeconds
<
ClientKeepSecond
)
{
if
(
box
.
WaitInStoreList
!=
null
&&
box
.
WaitInStoreList
.
Contains
(
posId
))
{
return
true
;
}
}
}
return
false
;
}
/// <summary>
/// <summary>
/// 移栽装置送盘到料仓门口时,需要判断是否可以将盘送入
/// 移栽装置送盘到料仓门口时,需要判断是否可以将盘送入
/// </summary>
/// </summary>
...
@@ -83,7 +101,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -83,7 +101,7 @@ namespace OnlineStore.DeviceLibrary
if
(
box
!=
null
)
if
(
box
!=
null
)
{
{
TimeSpan
span
=
DateTime
.
Now
-
box
.
LastMsgTime
;
TimeSpan
span
=
DateTime
.
Now
-
box
.
LastMsgTime
;
if
(
span
.
TotalSeconds
<
ClientKeepSecond
&&
box
.
HasTray
.
Equals
(
0
)&&
box
.
SAlarmType
.
Equals
(
LineAlarmType
.
None
))
if
(
span
.
TotalSeconds
<
ClientKeepSecond
&&
box
.
HasTray
.
Equals
(
0
)&&
box
.
SAlarmType
.
Equals
(
LineAlarmType
.
None
)
)
{
{
LineRunStatus
runs
=
(
LineRunStatus
)
box
.
SRunStatus
;
LineRunStatus
runs
=
(
LineRunStatus
)
box
.
SRunStatus
;
...
@@ -91,14 +109,6 @@ namespace OnlineStore.DeviceLibrary
...
@@ -91,14 +109,6 @@ namespace OnlineStore.DeviceLibrary
{
{
return
true
;
return
true
;
}
}
else
if
(
runs
.
Equals
(
LineRunStatus
.
Busy
))
{
LineStatus
status
=
(
LineStatus
)
box
.
SStatus
;
if
(
status
.
Equals
(
LineStatus
.
StoreOnline
)
||
status
.
Equals
(
LineStatus
.
InStoreEnd
)
||
status
.
Equals
(
LineStatus
.
InStoreExecute
))
{
return
true
;
}
}
}
}
}
}
return
false
;
return
false
;
...
@@ -240,6 +250,10 @@ namespace OnlineStore.DeviceLibrary
...
@@ -240,6 +250,10 @@ namespace OnlineStore.DeviceLibrary
{
{
LogUtil
.
error
(
"CheckInStorePos【"
+
id
+
"】【"
+
msg
+
"】失败"
);
LogUtil
.
error
(
"CheckInStorePos【"
+
id
+
"】【"
+
msg
+
"】失败"
);
}
}
else
{
// LogUtil.info("CheckInStorePos【" + id + "】【" + msg + "】发送成功");
}
}
}
}
catch
(
Exception
ex
)
}
catch
(
Exception
ex
)
{
{
...
@@ -321,7 +335,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -321,7 +335,7 @@ namespace OnlineStore.DeviceLibrary
else
else
{
{
int
id
=
storeSMsg
.
StoreId
;
int
id
=
storeSMsg
.
StoreId
;
BoxInfo
box
=
new
BoxInfo
(
storeSMsg
.
StoreId
,
storeSMsg
.
Cid
,
storeSMsg
.
Seq
,
storeSMsg
.
SStatus
,
storeSMsg
.
SRunStatus
,
storeSMsg
.
DoorHasTray
,
storeSMsg
.
AlarmType
);
BoxInfo
box
=
new
BoxInfo
(
storeSMsg
.
StoreId
,
storeSMsg
.
Cid
,
storeSMsg
.
Seq
,
storeSMsg
.
SStatus
,
storeSMsg
.
SRunStatus
,
storeSMsg
.
DoorHasTray
,
storeSMsg
.
AlarmType
,
storeSMsg
.
WaitInStoreList
);
SaveBoxClient
(
id
,
box
,
client
);
SaveBoxClient
(
id
,
box
,
client
);
string
cmd
=
storeSMsg
.
Cmd
;
string
cmd
=
storeSMsg
.
Cmd
;
...
@@ -405,6 +419,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -405,6 +419,8 @@ namespace OnlineStore.DeviceLibrary
public
string
PosId
=
""
;
public
string
PosId
=
""
;
public
string
PlateH
=
"0"
;
public
string
PlateH
=
"0"
;
public
string
PlateW
=
"0"
;
public
string
PlateW
=
"0"
;
public
List
<
string
>
WaitInStoreList
=
new
List
<
string
>();
}
}
}
}
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论