Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
刘韬
/
SO815-AutoInOutStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
图表
网络
创建新的问题
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 29df02c8
由
几米阳光
编写于
2018-12-12 09:21:09 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
开门增加光栅验证。服务器通信增加是否单盘出库
1 个父辈
243d29d0
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
43 行增加
和
38 行删除
source/ACSingleStore/FrmStoreBox.Designer.cs
source/ACSingleStore/FrmStoreBox.cs
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean_Partial.cs
source/DeviceLibrary/acSingleStore/AutomaticBaiting_Partial.cs
source/ACSingleStore/FrmStoreBox.Designer.cs
查看文件 @
29df02c
此文件的差异被折叠,
点击展开。
source/ACSingleStore/FrmStoreBox.cs
查看文件 @
29df02c
...
...
@@ -1551,14 +1551,7 @@ namespace OnlineStore.AutoInOutStore
int
value
=
FormUtil
.
GetIntValue
(
txtUpDownDoor
);
AxisABSMove
(
store
.
Config
.
UpDown_Axis
,
value
,
store
.
Config
.
UpDownAxis_P7_Speed
);
}
}
private
void
chbIsUseBatch_CheckedChanged
(
object
sender
,
EventArgs
e
)
{
store
.
UseBatchInout
=
chbIsUseBatch
.
Checked
;
LogUtil
.
info
(
"切换是否使用批量上下料:"
+
store
.
UseBatchInout
);
}
}
private
void
BtnOpenDoor_Click
(
object
sender
,
EventArgs
e
)
{
if
(
store
.
storeRunStatus
.
Equals
(
StoreRunStatus
.
Runing
)
&&
AutomaticBaiting
.
AutoBaitingStatus
.
Equals
(
StoreRunStatus
.
Runing
))
...
...
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
查看文件 @
29df02c
...
...
@@ -17,7 +17,7 @@ namespace OnlineStore.DeviceLibrary
public
partial
class
AC_SA_BoxBean
:
AC_Store
{
private
bool
IsIntSlvBlock
=
false
;
public
bool
UseBatchInout
=
true
;
//
public bool UseBatchInout = true;
public
string
CID
=
""
;
public
AUTO_SA_Config
Config
;
/// <summary>
...
...
@@ -152,15 +152,15 @@ namespace OnlineStore.DeviceLibrary
return
false
;
}
}
if
(
UseBatchInout
)
{
//
if (UseBatchInout)
//
{
string
canStart
=
AutomaticBaiting
.
CanStart
();
if
(!
canStart
.
Equals
(
""
))
{
LogUtil
.
info
(
StoreName
+
canStart
);
return
false
;
}
}
//
}
autoNext
=
false
;
mainTimer
.
Enabled
=
false
;
alarmType
=
StoreAlarmType
.
None
;
...
...
@@ -178,7 +178,7 @@ namespace OnlineStore.DeviceLibrary
{
return
false
;
}
if
(
UseBatchInout
)
//
if (UseBatchInout)
{
AutomaticBaiting
.
Reset
(
false
);
}
...
...
@@ -775,7 +775,7 @@ namespace OnlineStore.DeviceLibrary
CheckAxisAlarm
();
ShowTimeLog
(
"轴报警检测完成"
);
}
if
(
UseBatchInout
)
//
if (UseBatchInout)
{
AutomaticBaiting
.
TimerProcess
();
}
...
...
@@ -1177,7 +1177,7 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
info
(
LOGGER
,
StoreName
+
"StopMove"
);
KND
.
IOMove
(
IO_Type
.
Door_Down
,
IO_VALUE
.
LOW
);
KND
.
IOMove
(
IO_Type
.
Door_Up
,
IO_VALUE
.
LOW
);
if
(
UseBatchInout
)
//
if (UseBatchInout)
{
AutomaticBaiting
.
StopMove
();
}
...
...
@@ -1451,18 +1451,21 @@ namespace OnlineStore.DeviceLibrary
string
posIdStr
=
data
[
ParamDefine
.
posId
];
string
plateWStr
=
data
[
ParamDefine
.
plateW
];
string
plateHStr
=
data
[
ParamDefine
.
plateH
];
string
singleOut
=
data
[
ParamDefine
.
singleOut
];
LogUtil
.
info
(
LOGGER
,
"收到服务器出库消息:poaIs="
+
posIdStr
+
",platew="
+
plateWStr
+
",plateh="
+
plateHStr
);
LogUtil
.
info
(
LOGGER
,
"收到服务器出库消息:poaIs="
+
posIdStr
+
",platew="
+
plateWStr
+
",plateh="
+
plateHStr
+
",singleOut="
+
singleOut
);
char
splitChar
=
'|'
;
string
[]
posIdArray
=
posIdStr
.
Split
(
splitChar
);
string
[]
plateWArray
=
plateWStr
.
Split
(
splitChar
);
string
[]
plateHArray
=
plateHStr
.
Split
(
splitChar
);
string
[]
singleOutArray
=
plateHStr
.
Split
(
splitChar
);
int
index
=
-
1
;
foreach
(
string
posId
in
posIdArray
)
{
index
++;
string
plateW
=
plateWArray
[
index
];
string
plateH
=
plateHArray
[
index
];
bool
isSingleOut
=
singleOutArray
[
index
].
ToLower
().
Equals
(
"true"
);
string
[]
posArray
=
posId
.
Split
(
'#'
);
if
(
posArray
.
Length
!=
2
)
{
...
...
@@ -1485,7 +1488,7 @@ namespace OnlineStore.DeviceLibrary
{
if
(
CanStarInOut
())
{
StartOutStoreMove
(
new
InOutStoreParam
(
""
,
posId
,
position
),
true
);
StartOutStoreMove
(
new
InOutStoreParam
(
""
,
posId
,
position
),
!
isSingleOut
);
}
else
{
...
...
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean_Partial.cs
查看文件 @
29df02c
...
...
@@ -384,7 +384,7 @@ namespace OnlineStore.DeviceLibrary
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SI_05_DoorWarToDevice
)
{
if
(
StoreMove
.
IsBatchInOutStore
&&
(!
StoreMove
.
IsNeedInStore
)
)
if
(
!
StoreMove
.
IsNeedInStore
)
{
InStoreLog
(
"送出料盘:SI_21 ,需要操作人员拿走料盘,进出轴(叉子)到门口位置P7 "
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_21_DeviceToDoor
);
...
...
@@ -502,9 +502,12 @@ namespace OnlineStore.DeviceLibrary
#
region
送出料盘处理
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SI_21_DeviceToDoor
)
{
InStoreLog
(
"送出料盘:SI_22 ,打开仓门 "
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_22_OpenDoor
);
OpenDoorAndWait
();
if
(
KND
.
IOValue
(
IO_Type
.
SafetyLightCurtains
).
Equals
(
IO_VALUE
.
HIGH
))
{
InStoreLog
(
"送出料盘:SI_22 ,打开仓门 "
);
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_22_OpenDoor
);
OpenDoorAndWait
();
}
}
else
if
(
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
SI_22_OpenDoor
))
{
...
...
@@ -517,16 +520,19 @@ namespace OnlineStore.DeviceLibrary
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SI_23_WaitTrayGo
)
{
InStoreLog
(
"送出料盘:SI_13 叉子从库位中返回,进出轴动作至P1(待机点) "
);
// 5= 入仓位完成(料仓Box把料盘放入对应的库位中,装置还未恢复原始状态)
string
posId
=
StoreMove
.
MoveParam
!=
null
?
StoreMove
.
MoveParam
.
PositionNum
:
""
;
lastPosId
=
""
;
lastPosIdStatus
=
StoreStatus
.
InStoreEnd
;
storeStatus
=
StoreStatus
.
InStoreEnd
;
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_13_InoutBack
);
InOutBackToP1
(
moveP
.
InOut_P1
);
CloseDoorAndWait
();
{
if
(
KND
.
IOValue
(
IO_Type
.
SafetyLightCurtains
).
Equals
(
IO_VALUE
.
HIGH
))
{
InStoreLog
(
"送出料盘:SI_13 叉子从库位中返回,进出轴动作至P1(待机点) "
);
// 5= 入仓位完成(料仓Box把料盘放入对应的库位中,装置还未恢复原始状态)
string
posId
=
StoreMove
.
MoveParam
!=
null
?
StoreMove
.
MoveParam
.
PositionNum
:
""
;
lastPosId
=
""
;
lastPosIdStatus
=
StoreStatus
.
InStoreEnd
;
storeStatus
=
StoreStatus
.
InStoreEnd
;
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SI_13_InoutBack
);
InOutBackToP1
(
moveP
.
InOut_P1
);
CloseDoorAndWait
();
}
}
#
endregion
...
...
@@ -703,8 +709,8 @@ namespace OnlineStore.DeviceLibrary
ComMoveToPosition
(
StoreMove
.
MoveParam
.
MoveP
.
ComPress_P3
);
ACAxisMove
(
Config
.
UpDown_Axis
,
StoreMove
.
MoveParam
.
MoveP
.
UpDown_OutLow_P8
,
Config
.
UpDownAxis_P8_Speed
);
}
else
{
else
if
(
KND
.
IOValue
(
IO_Type
.
SafetyLightCurtains
).
Equals
(
IO_VALUE
.
HIGH
))
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
SO_21_OpenDoor
);
OutStoreLog
(
"出库:SO_21打开仓门,压紧轴至P3(压紧前点),定位气缸下降"
);
ComMoveToPosition
(
StoreMove
.
MoveParam
.
MoveP
.
ComPress_P3
);
...
...
@@ -722,9 +728,12 @@ namespace OnlineStore.DeviceLibrary
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTakeTray
());
}
else
if
(
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
SO_22_WaitTrayGo
))
{
SO_13_InoutBack
();
CloseDoorAndWait
();
{
if
(
KND
.
IOValue
(
IO_Type
.
SafetyLightCurtains
).
Equals
(
IO_VALUE
.
HIGH
))
{
SO_13_InoutBack
();
CloseDoorAndWait
();
}
}
else
if
(
StoreMove
.
MoveStep
==
StoreMoveStep
.
SO_11_PutTray
)
{
...
...
source/DeviceLibrary/acSingleStore/AutomaticBaiting_Partial.cs
查看文件 @
29df02c
...
...
@@ -404,7 +404,7 @@ namespace OnlineStore.DeviceLibrary
string
plateW
=
data
[
ParamDefine
.
plateW
];
string
plateH
=
data
[
ParamDefine
.
plateH
];
string
singleOut
=
data
[
ParamDefine
.
singleOut
];
bool
isSingleOut
=
singleOut
.
ToLower
().
Equals
(
"true"
);
//
bool isSingleOut = singleOut.ToLower().Equals("true");
string
[]
posArray
=
posId
.
Split
(
'#'
);
if
(!(
posArray
.
Length
==
2
))
{
...
...
@@ -429,7 +429,7 @@ namespace OnlineStore.DeviceLibrary
LastPosId
=
posId
;
InOutStoreParam
param
=
new
InOutStoreParam
(
message
,
posId
,
plateH
,
plateW
,
0
);
StoreManager
.
Store
.
StartInStoreMove
(
param
,
!
isSingleOut
);
StoreManager
.
Store
.
StartInStoreMove
(
param
,
true
);
//如果当前正在出入库中,需要记录下来,等待空闲时执行
LogUtil
.
info
(
Name
+
" 收到服务器入库命令:库位号【"
+
posId
+
"】二维码【"
+
message
+
"】 开始入库!"
);
}
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论