Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC1250-AssemblyLine
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 4d2406af
由
LN
编写于
2020-08-05 17:21:18 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
获取库位号时不判断是否有出库任务。
1 个父辈
3c1d6d22
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
45 行增加
和
23 行删除
source/DeviceLibrary/assemblyLine/LineBean_Partial.cs
source/DeviceLibrary/assemblyLine/LineBean_Shunt.cs
source/DeviceLibrary/assemblyLine/LineBean_Partial.cs
查看文件 @
4d2406a
...
@@ -1159,18 +1159,23 @@ namespace OnlineStore.DeviceLibrary
...
@@ -1159,18 +1159,23 @@ namespace OnlineStore.DeviceLibrary
return
false
;
return
false
;
}
}
MoveEquip
move
=
MoveEquipMap
[
id
];
MoveEquip
move
=
MoveEquipMap
[
id
];
if
(!
move
.
NoAlarm
()
||
move
.
IsDebug
||
move
.
waitOutStoreList
.
Count
>
0
)
if
(
move
.
IsDebug
)
//if (!move.NoErrorAlarm() || move.IsDebug || move.waitOutStoreList.Count > 0)
{
{
return
false
;
return
false
;
}
}
if
(
runStatus
.
Equals
(
LineRunStatus
.
Runing
)
||
runStatus
.
Equals
(
LineRunStatus
.
Busy
)
)
if
(
runStatus
>
LineRunStatus
.
Wait
&&
move
.
runStatus
>
LineRunStatus
.
Wait
)
{
{
if
((
move
.
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
None
)
||
move
.
MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
InStore
))
return
true
;
&&
(
move
.
runStatus
.
Equals
(
LineRunStatus
.
Runing
)
||
move
.
runStatus
.
Equals
(
LineRunStatus
.
Busy
)))
{
return
true
;
}
}
}
//if (runStatus.Equals(LineRunStatus.Runing) || runStatus.Equals(LineRunStatus.Busy))
//{
// if ((move.MoveInfo.MoveType.Equals(LineMoveType.None) || move.MoveInfo.MoveType.Equals(LineMoveType.InStore))
// && (move.runStatus.Equals(LineRunStatus.Runing) || move.runStatus.Equals(LineRunStatus.Busy)))
// {
// return true;
// }
//}
// LogUtil.error("runStatus【" + runStatus + "】,move.MoveInfo.MoveType【" + move.MoveInfo.MoveType + "】,move.runStatus【" + move.runStatus + "】 ");
// LogUtil.error("runStatus【" + runStatus + "】,move.MoveInfo.MoveType【" + move.MoveInfo.MoveType + "】,move.runStatus【" + move.runStatus + "】 ");
return
false
;
return
false
;
}
}
...
...
source/DeviceLibrary/assemblyLine/LineBean_Shunt.cs
查看文件 @
4d2406a
...
@@ -90,12 +90,15 @@ namespace OnlineStore.DeviceLibrary
...
@@ -90,12 +90,15 @@ namespace OnlineStore.DeviceLibrary
private
bool
Shunt_Updown2CanUp
()
private
bool
Shunt_Updown2CanUp
()
{
{
TimeSpan
span
=
DateTime
.
Now
-
Stop2DownTime
;
TimeSpan
span
=
DateTime
.
Now
-
Stop2DownTime
;
if
(
span
.
TotalMilliseconds
>=
3
000
)
if
(
span
.
TotalMilliseconds
>=
4
000
)
{
{
if
(
IOValue
(
IO_Type
.
Shunt_StopDown2_Back
).
Equals
(
IO_VALUE
.
LOW
)
if
(
IOValue
(
IO_Type
.
Shunt_StopDown2_Back
).
Equals
(
IO_VALUE
.
LOW
)
&&
IOValue
(
IO_Type
.
Shunt_Check3_Back
).
Equals
(
IO_VALUE
.
LOW
))
&&
IOValue
(
IO_Type
.
Shunt_Check3_Back
).
Equals
(
IO_VALUE
.
LOW
))
{
{
return
true
;
if
(
TrayManager
.
checkWatch
(
check3LowWatch
,
200
,
false
))
{
return
true
;
}
}
}
}
}
return
false
;
return
false
;
...
@@ -127,7 +130,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -127,7 +130,8 @@ namespace OnlineStore.DeviceLibrary
CylinderMove
(
null
,
IO_Type
.
Shunt_TopCylinder_Up1
,
IO_Type
.
Shunt_TopCylinder_Down1
);
CylinderMove
(
null
,
IO_Type
.
Shunt_TopCylinder_Up1
,
IO_Type
.
Shunt_TopCylinder_Down1
);
CylinderMove
(
null
,
IO_Type
.
Shunt_TopCylinder_Up2
,
IO_Type
.
Shunt_TopCylinder_Down2
);
CylinderMove
(
null
,
IO_Type
.
Shunt_TopCylinder_Up2
,
IO_Type
.
Shunt_TopCylinder_Down2
);
}
}
private
Stopwatch
check3LowWatch
=
new
Stopwatch
();
private
void
ShuntTimerProcess
()
private
void
ShuntTimerProcess
()
{
{
if
(
DisableShunt
)
if
(
DisableShunt
)
...
@@ -149,6 +153,16 @@ namespace OnlineStore.DeviceLibrary
...
@@ -149,6 +153,16 @@ namespace OnlineStore.DeviceLibrary
return
;
return
;
}
}
if
(
IOValue
(
IO_Type
.
Shunt_Check3_Back
).
Equals
(
IO_VALUE
.
LOW
))
{
TrayManager
.
checkWatch
(
check3LowWatch
,
30000
,
false
);
}
else
{
check3LowWatch
.
Stop
();
}
if
(
Shunt_MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
None
))
if
(
Shunt_MoveInfo
.
MoveType
.
Equals
(
LineMoveType
.
None
))
{
{
if
(
IOValue
(
IO_Type
.
Shunt_Check1_Front
).
Equals
(
IO_VALUE
.
HIGH
)&&
IOValue
(
IO_Type
.
Shunt_Check2_Middle
).
Equals
(
IO_VALUE
.
HIGH
))
if
(
IOValue
(
IO_Type
.
Shunt_Check1_Front
).
Equals
(
IO_VALUE
.
HIGH
)&&
IOValue
(
IO_Type
.
Shunt_Check2_Middle
).
Equals
(
IO_VALUE
.
HIGH
))
...
@@ -227,8 +241,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -227,8 +241,8 @@ namespace OnlineStore.DeviceLibrary
CylinderMove
(
Shunt_MoveInfo
,
IO_Type
.
Shunt_TopCylinder_Down1
,
IO_Type
.
Shunt_TopCylinder_Up1
);
CylinderMove
(
Shunt_MoveInfo
,
IO_Type
.
Shunt_TopCylinder_Down1
,
IO_Type
.
Shunt_TopCylinder_Up1
);
if
(
Shunt_Updown2CanUp
())
if
(
Shunt_Updown2CanUp
())
{
{
CylinderMove
(
null
,
IO_Type
.
Shunt_TopCylinder_Down2
,
IO_Type
.
Shunt_TopCylinder_Up2
);
CylinderMove
(
Shunt_MoveInfo
,
IO_Type
.
Shunt_TopCylinder_Down2
,
IO_Type
.
Shunt_TopCylinder_Up2
);
Shunt_MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Shunt_TopCylinder_Down2
,
IO_VALUE
.
LOW
));
//
Shunt_MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.Shunt_TopCylinder_Down2, IO_VALUE.LOW));
}
}
}
}
else
else
...
@@ -236,7 +250,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -236,7 +250,7 @@ namespace OnlineStore.DeviceLibrary
Shunt_MoveInfo
.
NextMoveStep
(
LineMoveStep
.
Shunt02_Stop1Down
);
Shunt_MoveInfo
.
NextMoveStep
(
LineMoveStep
.
Shunt02_Stop1Down
);
LogUtil
.
info
(
Name
+
"["
+
ShuntTrayNum
+
"]"
+
"分流横移: 不需要分流,直接放行,Shunt_StopDown1_Front 下降1200 "
);
LogUtil
.
info
(
Name
+
"["
+
ShuntTrayNum
+
"]"
+
"分流横移: 不需要分流,直接放行,Shunt_StopDown1_Front 下降1200 "
);
IOMove
(
IO_Type
.
Shunt_StopDown1_Front
,
IO_VALUE
.
HIGH
,
1200
);
IOMove
(
IO_Type
.
Shunt_StopDown1_Front
,
IO_VALUE
.
HIGH
,
1200
);
}
}
}
}
else
if
(
Shunt_MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
Shunt02_Stop1Down
))
else
if
(
Shunt_MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
Shunt02_Stop1Down
))
{
{
...
@@ -252,17 +266,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -252,17 +266,20 @@ namespace OnlineStore.DeviceLibrary
else
if
(
Shunt_MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
Shunt05_Top1Up
))
else
if
(
Shunt_MoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
Shunt05_Top1Up
))
{
{
if
(
CylinderIsOk
(
IO_Type
.
Shunt_TopCylinder_Down1
,
IO_Type
.
Shunt_TopCylinder_Up1
)
&&
if
(
Shunt_Updown2CanUp
())
IOValue
(
IO_Type
.
Shunt_TopCylinder_Down2
).
Equals
(
IO_VALUE
.
LOW
))
{
Shunt08_DriveMotorMove
();
}
else
if
(
Shunt_Updown2CanUp
())
{
{
Shunt_MoveInfo
.
NextMoveStep
(
LineMoveStep
.
Shunt07_Top2Up
);
if
(
CylinderIsOk
(
IO_Type
.
Shunt_TopCylinder_Down1
,
IO_Type
.
Shunt_TopCylinder_Up1
)
&&
ShuntLog
(
"分流横移:升降2开始上升 "
);
CylinderIsOk
(
IO_Type
.
Shunt_TopCylinder_Down2
,
IO_Type
.
Shunt_TopCylinder_Up2
))
CylinderMove
(
null
,
IO_Type
.
Shunt_TopCylinder_Down2
,
IO_Type
.
Shunt_TopCylinder_Up2
);
{
Shunt_MoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Shunt_TopCylinder_Down2
,
IO_VALUE
.
LOW
));
Shunt08_DriveMotorMove
();
}
else
{
Shunt_MoveInfo
.
NextMoveStep
(
LineMoveStep
.
Shunt07_Top2Up
);
ShuntLog
(
"分流横移:升降2开始上升 "
);
CylinderMove
(
Shunt_MoveInfo
,
IO_Type
.
Shunt_TopCylinder_Down2
,
IO_Type
.
Shunt_TopCylinder_Up2
);
//Shunt_MoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.Shunt_TopCylinder_Down2, IO_VALUE.LOW));
}
}
}
else
if
(
Shunt_MoveInfo
.
IsTimeOut
(
120
))
else
if
(
Shunt_MoveInfo
.
IsTimeOut
(
120
))
{
{
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论