Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
李娜
/
SO664-AssemblyLine
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 301cb911
由
LN
编写于
2020-12-14 18:13:42 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
上料模块增加模拟测试功能。NG接驳台bug修改
1 个父辈
f0f32343
隐藏空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
273 行增加
和
60 行删除
source/AssemblyLineClient/FrmFeedingEquip.Designer.cs
source/AssemblyLineClient/FrmFeedingEquip.cs
source/AssemblyLineClient/FrmRFIPEdit.cs
source/DeviceLibrary/assemblyLine/FeedingEquip.cs
source/DeviceLibrary/assemblyLine/FeedingEquip_InStore.cs
source/DeviceLibrary/assemblyLine/HY/HY_C1Line.cs
source/DeviceLibrary/assemblyLine/HY/HY_Coveryor_Partial.cs
source/DeviceLibrary/assemblymanager/TrayManager.cs
source/AssemblyLineClient/FrmFeedingEquip.Designer.cs
查看文件 @
301cb91
...
...
@@ -73,6 +73,11 @@
this
.
groupBox8
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
tableLayoutPanel4
=
new
System
.
Windows
.
Forms
.
TableLayoutPanel
();
this
.
tabPage2
=
new
System
.
Windows
.
Forms
.
TabPage
();
this
.
groupBox5
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
lblTestMsg
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
btnTestStop
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
lblTargetP3
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
btnStartTest
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
groupDetial
=
new
System
.
Windows
.
Forms
.
GroupBox
();
this
.
btnDSave
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
label3
=
new
System
.
Windows
.
Forms
.
Label
();
...
...
@@ -115,6 +120,7 @@
this
.
groupBox7
.
SuspendLayout
();
this
.
groupBox8
.
SuspendLayout
();
this
.
tabPage2
.
SuspendLayout
();
this
.
groupBox5
.
SuspendLayout
();
this
.
groupDetial
.
SuspendLayout
();
this
.
groupBox9
.
SuspendLayout
();
this
.
groupBox2
.
SuspendLayout
();
...
...
@@ -906,6 +912,7 @@
//
// tabPage2
//
this
.
tabPage2
.
Controls
.
Add
(
this
.
groupBox5
);
this
.
tabPage2
.
Controls
.
Add
(
this
.
groupDetial
);
this
.
tabPage2
.
Controls
.
Add
(
this
.
groupBox9
);
this
.
tabPage2
.
Controls
.
Add
(
this
.
axisMoveControl1
);
...
...
@@ -918,6 +925,76 @@
this
.
tabPage2
.
Text
=
" 伺服信息 "
;
this
.
tabPage2
.
UseVisualStyleBackColor
=
true
;
//
// groupBox5
//
this
.
groupBox5
.
Controls
.
Add
(
this
.
lblTestMsg
);
this
.
groupBox5
.
Controls
.
Add
(
this
.
btnTestStop
);
this
.
groupBox5
.
Controls
.
Add
(
this
.
lblTargetP3
);
this
.
groupBox5
.
Controls
.
Add
(
this
.
btnStartTest
);
this
.
groupBox5
.
Location
=
new
System
.
Drawing
.
Point
(
16
,
405
);
this
.
groupBox5
.
Name
=
"groupBox5"
;
this
.
groupBox5
.
Size
=
new
System
.
Drawing
.
Size
(
557
,
114
);
this
.
groupBox5
.
TabIndex
=
320
;
this
.
groupBox5
.
TabStop
=
false
;
this
.
groupBox5
.
Text
=
"批量轴上料测试"
;
//
// lblTestMsg
//
this
.
lblTestMsg
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblTestMsg
.
ForeColor
=
System
.
Drawing
.
Color
.
Black
;
this
.
lblTestMsg
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
lblTestMsg
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
64
);
this
.
lblTestMsg
.
Name
=
"lblTestMsg"
;
this
.
lblTestMsg
.
Size
=
new
System
.
Drawing
.
Size
(
545
,
43
);
this
.
lblTestMsg
.
TabIndex
=
318
;
this
.
lblTestMsg
.
Text
=
"测试信息:"
;
this
.
lblTestMsg
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
//
// btnTestStop
//
this
.
btnTestStop
.
BackColor
=
System
.
Drawing
.
SystemColors
.
Control
;
this
.
btnTestStop
.
Cursor
=
System
.
Windows
.
Forms
.
Cursors
.
Default
;
this
.
btnTestStop
.
Enabled
=
false
;
this
.
btnTestStop
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnTestStop
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnTestStop
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
btnTestStop
.
Location
=
new
System
.
Drawing
.
Point
(
354
,
23
);
this
.
btnTestStop
.
Name
=
"btnTestStop"
;
this
.
btnTestStop
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnTestStop
.
Size
=
new
System
.
Drawing
.
Size
(
163
,
34
);
this
.
btnTestStop
.
TabIndex
=
317
;
this
.
btnTestStop
.
Text
=
"批量轴停止"
;
this
.
btnTestStop
.
UseVisualStyleBackColor
=
true
;
this
.
btnTestStop
.
Click
+=
new
System
.
EventHandler
(
this
.
btnTestStop_Click
);
//
// lblTargetP3
//
this
.
lblTargetP3
.
AutoSize
=
true
;
this
.
lblTargetP3
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
lblTargetP3
.
ImageAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
this
.
lblTargetP3
.
Location
=
new
System
.
Drawing
.
Point
(
39
,
32
);
this
.
lblTargetP3
.
Name
=
"lblTargetP3"
;
this
.
lblTargetP3
.
Size
=
new
System
.
Drawing
.
Size
(
70
,
17
);
this
.
lblTargetP3
.
TabIndex
=
316
;
this
.
lblTargetP3
.
Text
=
"目标点P3:"
;
this
.
lblTargetP3
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleRight
;
//
// btnStartTest
//
this
.
btnStartTest
.
BackColor
=
System
.
Drawing
.
SystemColors
.
Control
;
this
.
btnStartTest
.
Cursor
=
System
.
Windows
.
Forms
.
Cursors
.
Default
;
this
.
btnStartTest
.
FlatStyle
=
System
.
Windows
.
Forms
.
FlatStyle
.
Flat
;
this
.
btnStartTest
.
Font
=
new
System
.
Drawing
.
Font
(
"微软雅黑"
,
9F
,
System
.
Drawing
.
FontStyle
.
Regular
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
btnStartTest
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
btnStartTest
.
Location
=
new
System
.
Drawing
.
Point
(
167
,
23
);
this
.
btnStartTest
.
Name
=
"btnStartTest"
;
this
.
btnStartTest
.
RightToLeft
=
System
.
Windows
.
Forms
.
RightToLeft
.
No
;
this
.
btnStartTest
.
Size
=
new
System
.
Drawing
.
Size
(
163
,
34
);
this
.
btnStartTest
.
TabIndex
=
307
;
this
.
btnStartTest
.
Text
=
"批量轴入料运动开始"
;
this
.
btnStartTest
.
UseVisualStyleBackColor
=
true
;
this
.
btnStartTest
.
Click
+=
new
System
.
EventHandler
(
this
.
btnStartTest_Click
);
//
// groupDetial
//
this
.
groupDetial
.
Controls
.
Add
(
this
.
btnDSave
);
...
...
@@ -1153,7 +1230,7 @@
//
this
.
axisMoveControl1
.
Location
=
new
System
.
Drawing
.
Point
(
6
,
4
);
this
.
axisMoveControl1
.
Name
=
"axisMoveControl1"
;
this
.
axisMoveControl1
.
Size
=
new
System
.
Drawing
.
Size
(
575
,
440
);
this
.
axisMoveControl1
.
Size
=
new
System
.
Drawing
.
Size
(
575
,
398
);
this
.
axisMoveControl1
.
TabIndex
=
219
;
//
// groupBox2
...
...
@@ -1356,6 +1433,8 @@
this
.
groupBox7
.
ResumeLayout
(
false
);
this
.
groupBox8
.
ResumeLayout
(
false
);
this
.
tabPage2
.
ResumeLayout
(
false
);
this
.
groupBox5
.
ResumeLayout
(
false
);
this
.
groupBox5
.
PerformLayout
();
this
.
groupDetial
.
ResumeLayout
(
false
);
this
.
groupDetial
.
PerformLayout
();
this
.
groupBox9
.
ResumeLayout
(
false
);
...
...
@@ -1454,6 +1533,11 @@
private
System
.
Windows
.
Forms
.
Button
SL_ClampCylinder_Work
;
private
System
.
Windows
.
Forms
.
Button
SL_OutTopCylinder_Down
;
private
System
.
Windows
.
Forms
.
Button
SL_TrayLocation_After
;
private
System
.
Windows
.
Forms
.
GroupBox
groupBox5
;
internal
System
.
Windows
.
Forms
.
Button
btnTestStop
;
private
System
.
Windows
.
Forms
.
Label
lblTargetP3
;
internal
System
.
Windows
.
Forms
.
Button
btnStartTest
;
private
System
.
Windows
.
Forms
.
Label
lblTestMsg
;
}
}
source/AssemblyLineClient/FrmFeedingEquip.cs
查看文件 @
301cb91
...
...
@@ -113,6 +113,7 @@ namespace OnlineStore.AssemblyLine
}
ReadIOList
();
ReadBtnDO
();
BatchTimerPro
();
lblName
.
BackColor
=
equipBean
.
GetShowColor
();
if
(
equipBean
.
runStatus
>
LineRunStatus
.
Wait
)
{
...
...
@@ -273,6 +274,9 @@ namespace OnlineStore.AssemblyLine
btnScan
.
Visible
=
equipBean
.
Config
.
IsCanOut
.
Equals
(
0
);
chbBoxSendShelf
.
Checked
=
equipBean
.
OutEndSendShelfOut
;
btnOutStore
.
Visible
=
equipBean
.
Config
.
IsCanOut
.
Equals
(
1
);
lblTargetP3
.
Text
=
"目标P3:"
+
equipBean
.
Config
.
BatchAxisP3
;
lblTestMsg
.
Text
=
""
;
TargetP3
=
equipBean
.
Config
.
BatchAxisP3
;
IsLoad
=
true
;
}
...
...
@@ -534,6 +538,8 @@ namespace OnlineStore.AssemblyLine
equipBean
.
Config
.
BatchAxisP3
=
p3
;
LineManager
.
SaveFeedingEquipConfig
(
equipBean
.
Config
);
MessageBox
.
Show
(
"保存成功!"
);
lblTargetP3
.
Text
=
"目标P3:"
+
equipBean
.
Config
.
BatchAxisP3
;
TargetP3
=
equipBean
.
Config
.
BatchAxisP3
;
}
private
void
btnScan_Click
(
object
sender
,
EventArgs
e
)
...
...
@@ -817,6 +823,98 @@ namespace OnlineStore.AssemblyLine
MessageBox
.
Show
(
"未启动或不在空闲中,出库测试失败!"
,
"提示"
,
MessageBoxButtons
.
OK
,
MessageBoxIcon
.
Error
);
}
}
private
int
TargetP3
=
0
;
private
bool
StartTest
=
false
;
private
void
btnStartTest_Click
(
object
sender
,
EventArgs
e
)
{
ConfigMoveAxis
moveAxis
=
equipBean
.
Config
.
Batch_Axis
;
bool
isServoOn
=
AxisManager
.
instance
.
IsServeoOn
(
moveAxis
.
DeviceName
,
moveAxis
.
GetAxisValue
());
if
(!
isServoOn
)
{
MessageBox
.
Show
(
moveAxis
.
Explain
+
" 未打开,请先打开伺服 "
,
"提示"
,
MessageBoxButtons
.
OK
,
MessageBoxIcon
.
Warning
);
return
;
}
bool
isStop
=
AxisManager
.
instance
.
GetBusyStatus
(
moveAxis
.
DeviceName
,
moveAxis
.
GetAxisValue
()).
Equals
(
0
);
if
(
isServoOn
&&
isStop
)
{
//判断批量轴是否停止且到位
TargetP3
=
equipBean
.
Config
.
BatchAxisP3
;
LogUtil
.
info
(
equipBean
.
Name
+
"点击:"
+
btnStartTest
.
Text
+
",目标位置:"
+
equipBean
.
Config
.
BatchAxisP3
);
equipBean
.
BatchAxisToP3
(
true
,
false
,
true
);
lblTestMsg
.
Text
=
"开始入料运动,目标位置["
+
TargetP3
+
"] ,开始位置["
+
equipBean
.
StartMovePosition
+
"],"
;
StartTest
=
true
;
}
else
{
MessageBox
.
Show
(
moveAxis
.
Explain
+
" 忙碌中,无法开始运动 "
,
"提示"
,
MessageBoxButtons
.
OK
,
MessageBoxIcon
.
Warning
);
return
;
}
}
private
void
btnTestStop_Click
(
object
sender
,
EventArgs
e
)
{
LogUtil
.
info
(
equipBean
.
Name
+
"点击:"
+
btnTestStop
.
Text
);
equipBean
.
BatchAxisStopCheck
();
equipBean
.
BatchAxis
.
SuddenStop
();
}
private
void
BatchTimerPro
()
{
if
(
equipBean
.
IsBatchMove
())
{
btnStartTest
.
Enabled
=
false
;
if
(
equipBean
.
LastMoveIsTest
)
{
ConfigMoveAxis
moveAxis
=
equipBean
.
Config
.
Batch_Axis
;
bool
countError
=
false
;
bool
isStop
=
false
;
bool
result
=
AxisManager
.
instance
.
AbsMoveIsEnd
(
moveAxis
.
DeviceName
,
moveAxis
.
GetAxisValue
(),
TargetP3
,
moveAxis
.
CanErrorCountMax
,
out
countError
);
if
(
result
)
{
isStop
=
true
;
LogUtil
.
info
(
equipBean
.
Name
+
"批量轴上料功能测试,发现批量轴已到达目标位置【"
+
TargetP3
+
"】,停止上料测试 "
);
}
else
{
bool
axisMoveIsEnd
=
HuichuanLibrary
.
HCBoardManager
.
MoveIsEnd
(
equipBean
.
Config
.
Batch_Axis
.
GetAxisValue
());
if
(
axisMoveIsEnd
)
{
isStop
=
true
;
LogUtil
.
info
(
equipBean
.
Name
+
"批量轴上料功能测试,发现批量轴已停止运动,停止上料测试"
);
}
}
if
(
isStop
)
{
StartTest
=
false
;
equipBean
.
BatchAxisStopCheck
();
btnStartTest
.
Enabled
=
true
;
btnTestStop
.
Enabled
=
false
;
int
height
=
equipBean
.
GetHeight
();
lblTestMsg
.
Text
=
"目标位置["
+
TargetP3
+
"] ,开始位置["
+
equipBean
.
StartMovePosition
+
"],停止位置["
+
equipBean
.
EndMovePosition
+
"],高度["
+
height
+
"]mm"
;
}
else
{
btnTestStop
.
Enabled
=
true
;
}
}
else
{
btnTestStop
.
Enabled
=
false
;
}
}
else
{
if
(
StartTest
)
{
StartTest
=
false
;
int
height
=
equipBean
.
GetHeight
();
lblTestMsg
.
Text
=
"目标位置["
+
TargetP3
+
"] ,开始位置["
+
equipBean
.
StartMovePosition
+
"],停止位置["
+
equipBean
.
EndMovePosition
+
"],高度["
+
height
+
"]mm"
;
}
btnStartTest
.
Enabled
=
true
;
btnTestStop
.
Enabled
=
false
;
}
}
}
}
...
...
source/AssemblyLineClient/FrmRFIPEdit.cs
查看文件 @
301cb91
...
...
@@ -81,9 +81,9 @@ namespace OnlineStore.AssemblyLine
resul
=
data
.
NumStr
();
numNum
.
Value
=
data
.
Num
;
int
selIndex
=
data
.
RFType
-
64
;
if
(
selIndex
>=
0
&&
selIndex
<=
com
box
Type
.
Items
.
Count
)
if
(
selIndex
>=
0
&&
selIndex
<=
comType
.
Items
.
Count
)
{
com
box
Type
.
SelectedIndex
=
selIndex
;
comType
.
SelectedIndex
=
selIndex
;
}
}
...
...
source/DeviceLibrary/assemblyLine/FeedingEquip.cs
查看文件 @
301cb91
...
...
@@ -618,6 +618,40 @@ namespace OnlineStore.DeviceLibrary
#
endregion
#
region
提升轴匀速上升处理
public
bool
LastMoveIsTest
=
true
;
public
void
BatchAxisToP3
(
bool
isFirstMove
=
true
,
bool
isWait
=
true
,
bool
IsTest
=
false
)
{
int
targetP3
=
Config
.
BatchAxisP3
;
int
targetSpeed
=
Config
.
BatchAxis_P3Speed
;
if
(!
isFirstMove
)
{
int
currPosition
=
BatchAxis
.
GetAclPosition
();
if
(
currPosition
!=
-
1
)
{
targetP3
=
currPosition
+
Config
.
Height_ChangeValue
*
80
;
if
(
targetP3
>
Config
.
BatchAxisP3
)
{
targetP3
=
Config
.
BatchAxisP3
;
}
LogUtil
.
info
(
Name
+
" BatchAxisToP3 目标P3: "
+
targetP3
+
"("
+
currPosition
+
")"
);
}
//targetSpeed = Config.BatchAxis_P3Speed / 2;
}
// 需要增加定时器,获取验证信号并停止伺服
StartMovePosition
=
BatchAxis
.
GetAclPosition
();
if
(
isWait
)
{
MoveInfo
.
TimeOutSeconds
=
200
;
MoveInfo
.
CanWhileCount
=
0
;
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitBatchAxis
(
Config
.
Batch_Axis
,
targetP3
,
targetSpeed
));
}
Config
.
Batch_Axis
.
TargetPosition
=
targetP3
;
BatchAxis
.
AbsMove
(
null
,
targetP3
,
targetSpeed
);
//开始检测信号
BatchAxisStartCheck
();
LastMoveIsTest
=
IsTest
;
}
private
System
.
Timers
.
Timer
axisCheckTimer
=
null
;
private
string
TargetIoType
=
IO_Type
.
SL_AxisLocationCheck
;
private
IO_VALUE
TargetIoValue
=
IO_VALUE
.
HIGH
;
...
...
@@ -641,7 +675,7 @@ namespace OnlineStore.DeviceLibrary
return
true
;
}
p
rivate
bool
BatchAxisStopCheck
()
p
ublic
bool
BatchAxisStopCheck
()
{
if
(!(
axisCheckTimer
==
null
))
{
...
...
@@ -649,6 +683,15 @@ namespace OnlineStore.DeviceLibrary
}
return
true
;
}
public
bool
IsBatchMove
()
{
if
(
axisCheckTimer
!=
null
&&
axisCheckTimer
.
Enabled
)
{
return
true
;
}
return
false
;
}
private
bool
IsInProcess
=
false
;
private
DateTime
lastOkTime
=
DateTime
.
Now
;
private
void
CheckTimer_Elapsed
(
object
sender
,
System
.
Timers
.
ElapsedEventArgs
e
)
...
...
@@ -665,7 +708,7 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
info
(
Name
+
"上料轴,检测到 "
+
TargetIoType
+
"="
+
TargetIoValue
+
",停止运动"
);
BatchAxis
.
SuddenStop
();
BatchAxisStopCheck
();
}
}
}
catch
(
Exception
ex
)
{
...
...
source/DeviceLibrary/assemblyLine/FeedingEquip_InStore.cs
查看文件 @
301cb91
...
...
@@ -892,45 +892,14 @@ namespace OnlineStore.DeviceLibrary
}
}
private
void
BatchAxisToP3
(
bool
isFirstMove
=
true
,
bool
isWait
=
true
)
{
int
targetP3
=
Config
.
BatchAxisP3
;
int
targetSpeed
=
Config
.
BatchAxis_P3Speed
;
if
(!
isFirstMove
)
{
int
currPosition
=
BatchAxis
.
GetAclPosition
();
if
(
currPosition
!=
-
1
)
{
targetP3
=
currPosition
+
Config
.
Height_ChangeValue
*
80
;
if
(
targetP3
>
Config
.
BatchAxisP3
)
{
targetP3
=
Config
.
BatchAxisP3
;
}
LogUtil
.
info
(
Name
+
" BatchAxisToP3 目标P3: "
+
targetP3
+
"("
+
currPosition
+
")"
);
}
//targetSpeed = Config.BatchAxis_P3Speed / 2;
}
// 需要增加定时器,获取验证信号并停止伺服
StartMovePosition
=
BatchAxis
.
GetAclPosition
();
if
(
isWait
)
{
MoveInfo
.
TimeOutSeconds
=
200
;
MoveInfo
.
CanWhileCount
=
0
;
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitBatchAxis
(
Config
.
Batch_Axis
,
targetP3
,
targetSpeed
));
}
Config
.
Batch_Axis
.
TargetPosition
=
targetP3
;
BatchAxis
.
AbsMove
(
null
,
targetP3
,
targetSpeed
);
//开始检测信号
BatchAxisStartCheck
();
}
p
rivate
int
StartMovePosition
=
0
;
p
rivate
int
EndMovePosition
=
0
;
p
ublic
int
StartMovePosition
=
0
;
p
ublic
int
EndMovePosition
=
0
;
private
int
LastHeight
=
0
;
private
int
LastWidth
=
0
;
private
List
<
string
>
LastCodeList
=
new
List
<
string
>();
private
List
<
string
>
NextCodeList
=
new
List
<
string
>();
p
rivate
int
GetHeight
()
p
ublic
int
GetHeight
()
{
LastHeight
=
0
;
int
AxisChangeValue
=
Config
.
Height_ChangeValue
;
...
...
source/DeviceLibrary/assemblyLine/HY/HY_C1Line.cs
查看文件 @
301cb91
...
...
@@ -327,8 +327,8 @@ namespace OnlineStore.DeviceLibrary
//直接放盘通过
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
HY91_TrayCanGo
);
CheckLog
(
"托盘阻挡"
+
MoveInfo
.
SLog
+
" 无需处理,放托盘离开"
);
}
}
}
}
#
endregion
#
region
C1
线
->
出料线横移处理
31
...
...
@@ -369,10 +369,16 @@ namespace OnlineStore.DeviceLibrary
HY_StopCylinderUp
(
MoveInfo
);
OL_StopCylinderUp
(
MoveInfo
);
int
lineId
=
DeviceID
%
100
;
LogInfo
(
"C1线->出料线 【"
+
MoveInfo
.
MoveParam
.
ToShortStr
()
+
"】"
+
MoveInfo
.
SLog
+
" 更新料盘位置【"
+
MoveInfo
.
MoveParam
.
WareCode
+
"】【INBELT】【"
+
lineId
+
"】"
);
//更新料盘位置
SServerManager
.
UpdateTrayLoc
(
Name
,
MoveInfo
.
MoveParam
.
WareCode
,
LocStatus
.
INBELT
,
Config
.
LineName
);
//如果是出库料,才需要更新位置
TrayInfo
tray
=
TrayManager
.
GetTrayInfo
(
currTrayNum
);
if
(
tray
.
IsFull
&&
tray
.
InOrOutStore
.
Equals
(
2
))
{
int
lineId
=
DeviceID
%
100
;
LogInfo
(
"C1线->出料线 【"
+
MoveInfo
.
MoveParam
.
ToShortStr
()
+
"】"
+
MoveInfo
.
SLog
+
" 更新料盘位置【"
+
MoveInfo
.
MoveParam
.
WareCode
+
"】【INBELT】【"
+
lineId
+
"】"
);
//更新料盘位置
SServerManager
.
UpdateTrayLoc
(
Name
,
MoveInfo
.
MoveParam
.
WareCode
,
LocStatus
.
INBELT
,
Config
.
LineName
);
}
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
HY35_IOL_TopDown
))
{
...
...
@@ -704,7 +710,7 @@ namespace OnlineStore.DeviceLibrary
{
FeedingEquip
feed1
=
LineManager
.
Line
.
FeedingEquipMap
[
101
];
FeedingEquip
feed2
=
LineManager
.
Line
.
FeedingEquipMap
[
102
];
if
((!
feed1
.
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
InStore
))
||
(!
feed2
.
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
InStore
)))
if
((!
feed1
.
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
InStore
))
&&
(!
feed2
.
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
InStore
)))
{
return
true
;
}
...
...
source/DeviceLibrary/assemblyLine/HY/HY_Coveryor_Partial.cs
查看文件 @
301cb91
...
...
@@ -207,6 +207,9 @@ namespace OnlineStore.DeviceLibrary
{
MoveTimeOut
(
SecondMoveInfo
,
"等待移栽机构开始抓料超时"
);
}
}
else
if
(
SecondMoveInfo
.
IsStep
(
LineMoveStep
.
JHY_09_WaitProcessReel
))
{
//等待料盘拿走
}
else
if
(
SecondMoveInfo
.
IsStep
(
LineMoveStep
.
JHY_10_ReelProEnd
))
{
...
...
@@ -462,7 +465,7 @@ namespace OnlineStore.DeviceLibrary
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
JM_05_ClampWork
))
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
JM_06_UpdownToP1
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":升降轴到P1 ["
+
Config
.
UpDownAxisP1
+
"]"
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":升降轴到P1 ["
+
Config
.
UpDownAxisP1
+
"]"
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
UpDownAxisP1
,
Config
.
UpdownAxis_P1Speed
);
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
JM_06_UpdownToP1
))
...
...
@@ -480,15 +483,23 @@ namespace OnlineStore.DeviceLibrary
}
else
{
OutLog
(
logName
+
MoveInfo
.
SLog
+
":SecondMoveInfo当前无处理,暂时不用 JHY_10_ReelProEnd "
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":SecondMoveInfo当前无处理,暂时不用 JHY_10_ReelProEnd "
);
}
if
(
IsNgPro
())
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
JM_11_CylinderGive
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":接驳台气缸放料 "
);
CylinderMove
(
MoveInfo
,
IO_Type
.
HY_MoveCylinder_Take
,
IO_Type
.
HY_MoveCylinder_Give
);
}
else
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
JM_10_WaitJNoReel
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":等待接驳台无料 "
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck1
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck2
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck3
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck4
,
IO_VALUE
.
LOW
));
}
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
JM_10_WaitJNoReel
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":等待接驳台无料 "
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck1
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck2
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck3
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck4
,
IO_VALUE
.
LOW
));
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
JM_10_WaitJNoReel
))
{
...
...
@@ -533,7 +544,7 @@ namespace OnlineStore.DeviceLibrary
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
JM_13_ClampRelax
))
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
JM_14_UpdownToP1
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":升降轴上升到P1 ["
+
Config
.
UpDownAxisP1
+
"] "
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":升降轴上升到P1 ["
+
Config
.
UpDownAxisP1
+
"] "
);
UpdownAxis
.
AbsMove
(
MoveInfo
,
Config
.
UpDownAxisP1
,
Config
.
UpdownAxis_P1Speed
);
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
JM_14_UpdownToP1
))
...
...
@@ -541,8 +552,10 @@ namespace OnlineStore.DeviceLibrary
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
JM_15_ClampCheck
);
OutLog
(
logName
+
MoveInfo
.
SLog
+
":夹爪料盘检测无料,接驳台有料 "
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_ClampCylinder_Check
,
IO_VALUE
.
LOW
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck1
,
IO_VALUE
.
HIGH
));
if
(!
IsNgPro
())
{
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
HY_TrayCheck1
,
IO_VALUE
.
HIGH
));
}
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
JM_15_ClampCheck
))
{
...
...
@@ -571,7 +584,7 @@ namespace OnlineStore.DeviceLibrary
}
else
if
(
MoveInfo
.
IsTimeOut
(
60
))
{
MoveTimeOut
(
MoveInfo
,
"等待给服务器发送afterPutCutTask完成"
);
MoveTimeOut
(
MoveInfo
,
"等待给服务器发送afterPutCutTask完成"
);
}
}
else
...
...
source/DeviceLibrary/assemblymanager/TrayManager.cs
查看文件 @
301cb91
...
...
@@ -191,7 +191,7 @@ namespace OnlineStore.DeviceLibrary
{
try
{
List
<
TrayInfo
>
trayList
=
new
List
<
TrayInfo
>();
List
<
TrayInfo
>
trayList
=
new
List
<
TrayInfo
>(
TrayInfoMap
.
Values
);
List
<
string
>
lineList
=
new
List
<
string
>();
foreach
(
TrayInfo
tray
in
trayList
)
{
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论