Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
李娜
/
SO664-AssemblyLine
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 9e6f100f
由
LN
编写于
2021-01-23 11:42:07 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
仓门口的料没抓起时重抓一次。
1 个父辈
8f8742a5
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
93 行增加
和
43 行删除
source/DeviceLibrary/assemblyLine/EquipBase.cs
source/DeviceLibrary/assemblyLine/LineBean_Partial.cs
source/DeviceLibrary/assemblyLine/MoveEquip_Partial.cs
source/DeviceLibrary/model/StoreStep.cs
source/DeviceLibrary/assemblyLine/EquipBase.cs
查看文件 @
9e6f100
...
...
@@ -656,18 +656,27 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
info
(
Name
+
" "
+
posId
+
msg
);
}
}
protected
void
OutLog
(
string
msg
)
/// <summary>
///
/// </summary>
/// <param name="msg"></param>
/// <param name="levle">-1是默认值,0时打印debug,1打印info</param>
protected
void
OutLog
(
string
msg
,
int
levle
=
-
1
)
{
string
posId
=
MoveInfo
.
MoveParam
!=
null
?
"["
+
currTrayNum
+
"]["
+
MoveInfo
.
MoveParam
.
PosId
+
"]["
+
MoveInfo
.
MoveParam
.
WareCode
+
"]"
:
""
;
//baseConfig.DType.Equals(DeviceType.HYEquip)
if
(
baseConfig
.
DType
.
Equals
(
DeviceType
.
MoveEquip
))
string
posId
=
MoveInfo
.
MoveParam
!=
null
?
"["
+
currTrayNum
+
"]["
+
MoveInfo
.
MoveParam
.
PosId
+
"]["
+
MoveInfo
.
MoveParam
.
WareCode
+
"]"
:
""
;
if
(
levle
.
Equals
(-
1
)
&&
baseConfig
.
DType
.
Equals
(
DeviceType
.
MoveEquip
))
{
LogUtil
.
debug
(
Name
+
" "
+
posId
+
msg
)
;
}
else
levle
=
0
;
}
if
(
levle
.
Equals
(
1
))
{
LogUtil
.
info
(
Name
+
" "
+
posId
+
msg
);
}
else
if
(
levle
.
Equals
(
0
))
{
LogUtil
.
debug
(
Name
+
" "
+
posId
+
msg
);
}
}
public
virtual
string
GetMoveStr
()
...
...
source/DeviceLibrary/assemblyLine/LineBean_Partial.cs
查看文件 @
9e6f100
...
...
@@ -311,11 +311,11 @@ namespace OnlineStore.DeviceLibrary
//前进后退气缸后退以后才可以出库
else
if
(
move
.
runStatus
.
Equals
(
LineRunStatus
.
Busy
)
&&
move
.
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
OutStore
))
{
if
(
move
.
MoveInfo
.
MoveStep
>=
(
LineMoveStep
.
MO_
58
_CylinderDown
))
if
(
move
.
MoveInfo
.
MoveStep
>=
(
LineMoveStep
.
MO_
60
_CylinderDown
))
{
return
true
;
}
else
if
(
move
.
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_5
7
_CylinderAfter
)
&&
move
.
MoveInfo
.
IsInWait
.
Equals
(
false
)
else
if
(
move
.
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_5
9
_CylinderAfter
)
&&
move
.
MoveInfo
.
IsInWait
.
Equals
(
false
)
&&
move
.
CylinderIsOk
(
IO_Type
.
BeforeAfterCylinder_Before
,
IO_Type
.
BeforeAfterCylinder_After
))
{
return
true
;
...
...
source/DeviceLibrary/assemblyLine/MoveEquip_Partial.cs
查看文件 @
9e6f100
...
...
@@ -15,6 +15,8 @@ namespace OnlineStore.DeviceLibrary
{
#
region
出库
private
int
ClampCount
=
0
;
public
override
bool
StartOutStoreMove
(
InOutParam
param
)
{
string
posId
=
param
!=
null
?
param
.
PosId
:
""
;
...
...
@@ -76,6 +78,8 @@ namespace OnlineStore.DeviceLibrary
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_51_CylinderBefore
))
{
//重置夹料次数=0
ClampCount
=
0
;
if
(
CylinderIsOk
(
IO_Type
.
BeforeAfterCylinder_After
,
IO_Type
.
BeforeAfterCylinder_Before
))
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_52_CylinderDown
);
...
...
@@ -114,23 +118,43 @@ namespace OnlineStore.DeviceLibrary
UpdownUpMove
();
// CylinderMove(MoveInfo, IO_Type.UpDownCylinder_Down, IO_Type.UpDownCylinder_Up);
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_56_ResetClamp
))
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_52_CylinderDown
);
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 上下气缸下降 "
);
UpdownDownP3Move
(
MoveInfo
.
MoveParam
.
PlateH
);
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_55_CylinderUp
))
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_56_ClampCheck
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
200
));
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 检测夹爪料盘检测=HIGH"
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
ClampCylinder_Check
,
IO_VALUE
.
HIGH
));
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_57_ClampCheck
);
if
(
ClampCount
.
Equals
(
0
))
{
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 检测夹爪料盘检测=HIGH,超时1000"
);
MoveInfo
.
OneWaitCanEndStep
=
true
;
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
ClampCylinder_Check
,
IO_VALUE
.
HIGH
));
}
else
{
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
200
));
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 检测夹爪料盘检测=HIGH"
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
ClampCylinder_Check
,
IO_VALUE
.
HIGH
));
}
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_5
6
_ClampCheck
))
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_5
7
_ClampCheck
))
{
if
(
UpdownIsUp
())
{
if
(
IsBigStore
())
{
if
(
TrayIsOk
())
{
if
(
IOValue
(
IO_Type
.
ClampCylinder_Check
).
Equals
(
IO_VALUE
.
HIGH
))
{
if
(
IsBigStore
())
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_58_WaitTray
);
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 等待托盘到达"
);
}
else
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_5
7
_CylinderAfter
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_5
9
_CylinderAfter
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
200
));
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 前后气缸后退"
);
CylinderMove
(
MoveInfo
,
IO_Type
.
BeforeAfterCylinder_Before
,
IO_Type
.
BeforeAfterCylinder_After
);
...
...
@@ -138,10 +162,10 @@ namespace OnlineStore.DeviceLibrary
}
else
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_5
7_CylinderAfter
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
200
))
;
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
":
前后气缸后退"
);
CylinderMove
(
MoveInfo
,
IO_Type
.
BeforeAfterCylinder_Before
,
IO_Type
.
BeforeAfterCylinder_After
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_5
6_ResetClamp
);
ClampCount
=
1
;
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
":
第一次未抓到料,重新抓一次,夹爪先放松"
,
1
);
CylinderMove
(
MoveInfo
,
IO_Type
.
ClampCylinder_Work
,
IO_Type
.
ClampCylinder_Relax
);
}
}
else
...
...
@@ -150,11 +174,20 @@ namespace OnlineStore.DeviceLibrary
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 上下气缸上升"
);
UpdownUpMove
();
}
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_58_WaitTray
))
{
if
(
TrayIsOk
())
{
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_59_CylinderAfter
);
MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
200
));
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 前后气缸后退"
);
CylinderMove
(
MoveInfo
,
IO_Type
.
BeforeAfterCylinder_Before
,
IO_Type
.
BeforeAfterCylinder_After
);
}
}
#
endregion
#
region
移载装置,放物品到流水线操作
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_5
7
_CylinderAfter
))
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_5
9
_CylinderAfter
))
{
if
(
CylinderIsOk
(
IO_Type
.
BeforeAfterCylinder_Before
,
IO_Type
.
BeforeAfterCylinder_After
))
{
...
...
@@ -162,7 +195,7 @@ namespace OnlineStore.DeviceLibrary
{
int
trayNum
=
SecondMoveInfo
.
MoveParam
.
TrayNumber
;
//去掉直接丢盘处理
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_
58
_CylinderDown
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_
60
_CylinderDown
);
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 夹具检测编码完成, 上下气缸下降 ,更新料盘位置【"
+
MoveInfo
.
MoveParam
.
WareCode
+
"】【INLINE】【"
+
trayNum
+
"】,顶升气缸上升"
);
if
(
MoveInfo
.
MoveParam
!=
null
)
{
...
...
@@ -180,25 +213,25 @@ namespace OnlineStore.DeviceLibrary
}
}
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_
58
_CylinderDown
))
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_
60
_CylinderDown
))
{
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 夹料气缸放松,更新托盘【"
+
MoveInfo
.
MoveParam
.
TrayNumber
+
"】,有料盘,OutStore,【"
+
MoveInfo
.
MoveParam
.
ToStr
()
+
"】"
);
TrayManager
.
UpdateTrayInfo
(
MoveInfo
.
MoveParam
.
TrayNumber
,
true
,
ReelType
.
OutStore
,
MoveInfo
.
MoveParam
.
Clone
());
TrayInfo
tray
=
TrayManager
.
GetTrayInfo
(
MoveInfo
.
MoveParam
.
TrayNumber
);
LogInfo
(
"出库 "
+
MoveInfo
.
SLog
+
": 夹料气缸放松,更新托盘信息 "
+
tray
.
ToStr
()
+
""
);
LogInfo
(
"出库 "
+
MoveInfo
.
SLog
+
": 夹料气缸放松,更新托盘信息 "
+
tray
.
ToStr
()
+
""
);
//出库全部完成
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_
59
_CylinderRelax
);
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_
61
_CylinderRelax
);
CylinderMove
(
MoveInfo
,
IO_Type
.
ClampCylinder_Work
,
IO_Type
.
ClampCylinder_Relax
);
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_
59
_CylinderRelax
))
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_
61
_CylinderRelax
))
{
this
.
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_6
0
_CylinderUp
);
this
.
MoveInfo
.
NextMoveStep
(
LineMoveStep
.
MO_6
2
_CylinderUp
);
OutLog
(
"出库 "
+
MoveInfo
.
SLog
+
": 上下气缸上升,同时顶升气缸先下降"
);
UpdownUpMove
();
CylinderMove
(
null
,
IO_Type
.
TopCylinder_Up
,
IO_Type
.
TopCylinder_Down
);
}
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_6
0
_CylinderUp
))
else
if
(
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_6
2
_CylinderUp
))
{
// 减去需要的盘数
// TrayManager.DelNeedEmptyTrayNum();
...
...
@@ -499,9 +532,9 @@ namespace OnlineStore.DeviceLibrary
{
return
false
;
}
bool
moveOk
=
(
IsBigStore
()
&&
MoveInfo
.
MoveStep
>=
LineMoveStep
.
MO_5
6_ClampCheck
&&
MoveInfo
.
IsInWait
.
Equals
(
false
))
||
MoveInfo
.
MoveStep
>=
LineMoveStep
.
MO_57
_CylinderAfter
;
bool
moveOk
=
(
IsBigStore
()
&&
MoveInfo
.
MoveStep
>=
LineMoveStep
.
MO_5
8_WaitTray
)
||
MoveInfo
.
MoveStep
>=
LineMoveStep
.
MO_59
_CylinderAfter
;
if
(
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
OutStore
)
&&
moveOk
&&
(!
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_6
0
_CylinderUp
)))
&&
(!
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_6
2
_CylinderUp
)))
{
if
(
isFull
.
Equals
(
false
))
{
...
...
@@ -518,9 +551,9 @@ namespace OnlineStore.DeviceLibrary
{
return
false
;
}
bool
moveOk
=
(
IsBigStore
()
&&
MoveInfo
.
MoveStep
>=
LineMoveStep
.
MO_5
6_ClampCheck
&&
MoveInfo
.
IsInWait
.
Equals
(
false
))
||
MoveInfo
.
MoveStep
>=
LineMoveStep
.
MO_57
_CylinderAfter
;
bool
moveOk
=
(
IsBigStore
()
&&
MoveInfo
.
MoveStep
>=
LineMoveStep
.
MO_5
8_WaitTray
)
||
MoveInfo
.
MoveStep
>=
LineMoveStep
.
MO_59
_CylinderAfter
;
if
(
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
OutStore
)
&&
moveOk
&&
(!
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_6
0
_CylinderUp
)))
&&
(!
MoveInfo
.
IsStep
(
LineMoveStep
.
MO_6
2
_CylinderUp
)))
{
return
true
;
}
...
...
source/DeviceLibrary/model/StoreStep.cs
查看文件 @
9e6f100
...
...
@@ -303,7 +303,7 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// 移栽装置出库处理,开始出库
/// </summary>
MO_50_StartOutProcess
=
1250
,
MO_50_StartOutProcess
=
1250
,
/// <summary>
/// 移栽装置出库处理。。前后气缸1前进
/// </summary>
...
...
@@ -327,26 +327,34 @@ namespace OnlineStore.DeviceLibrary
MO_55_CylinderUp
,
/// <summary>
/// 移栽
装置出库处理。 夹料气缸检测
/// 移栽
出库:开始重抓一次
/// </summary>
MO_56_ClampCheck
,
MO_56_ResetClamp
,
/// <summary>
/// 移栽出库。 夹料气缸检测
/// </summary>
MO_57_ClampCheck
,
/// <summary>
/// 移栽出库:开始等待托盘
/// </summary>
MO_58_WaitTray
,
/// <summary>
/// 移栽装置出库处理。 前后气缸1后退
/// </summary>
MO_5
7
_CylinderAfter
,
MO_5
9
_CylinderAfter
,
/// <summary>
/// 移载(流水线)装置出库处理,上下气缸1下降
/// </summary>
MO_
58
_CylinderDown
,
MO_
60
_CylinderDown
,
/// <summary>
/// 移载(流水线)装置出库处理,夹料气缸1放松
/// </summary>
MO_
59
_CylinderRelax
,
MO_
61
_CylinderRelax
,
/// <summary>
/// 移载(流水线)装置出库处理,上下气缸1上升
/// </summary>
MO_6
0
_CylinderUp
,
MO_6
2
_CylinderUp
,
#
region
入料模块,紧急出料移栽处理
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论