Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC30-AutoInOutStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 243d29d0
由
几米阳光
编写于
2018-12-11 21:55:18 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
入库流程修改
1 个父辈
9267c47b
显示空白字符变更
内嵌
并排
正在显示
8 个修改的文件
包含
92 行增加
和
30 行删除
doc/设备IP地址分配.xlsx
source/ACSingleStore/记录.txt
source/Common/bean/Bean.cs
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean_Partial.cs
source/DeviceLibrary/acSingleStore/AutomaticBaiting.cs
source/DeviceLibrary/acSingleStore/AutomaticBaiting_Partial.cs
source/DeviceLibrary/store/model/StoreMoveInfo.cs
doc/设备IP地址分配.xlsx
查看文件 @
243d29d
此文件类型无法预览
source/ACSingleStore/记录.txt
查看文件 @
243d29d
...
...
@@ -38,15 +38,33 @@
批量上料开始按钮没有锁门
批量上料模块报警,出入库不影响
轴在原点的时候再次原点返回需要反向走相对量。
上料过程中报警了,复位后又开始自动上料
压紧轴原点返回之前,先相对走-2000;
叉子未后退完成,吸盘就下降了
如果是未扫到码或者没有入库成功,需要将料盘送出,送出之后批量上料功能才能继续。
需要修改还未修改的:
X12_上料机构出料检测信号:
批量出入库玩抽,打开门DI-21没有以后,上料机构上升,X12ON后停止,X12OFF以后再上升,检测到上极限亮了以后,X12OFF后,轴下降至原点位置。
X16_压紧轴机构计量检测:
此信号每4mm就会亮一次,压紧轴运动过程中需要检测此信号闪的次数。
X04_安全光栅:
光栅默认为High,每次开关门之前都要验证。
X22_气压检测:
运行过程中需要持续检测气压信号,若持续没有气压需要报警。
...
...
source/Common/bean/Bean.cs
查看文件 @
243d29d
...
...
@@ -200,5 +200,9 @@ namespace OnlineStore.Common
/// 温度报警值
/// </summary>
public
static
string
maxTemperature
=
"temp"
;
/// <summary>
/// 是否是单个出库,true表示单个出库,其他都是批量出库
/// </summary>
public
static
string
singleOut
=
"singleOut"
;
}
}
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean.cs
查看文件 @
243d29d
...
...
@@ -436,14 +436,18 @@ namespace OnlineStore.DeviceLibrary
}
private
void
OpenDoorAndWait
()
{
if
(
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
InStore
)
||
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
OutStore
)
)
if
(
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
InStore
))
{
//如果是批量出入库,不需要经过此门
if
(
StoreMove
.
IsBatchInOutStore
)
if
(
StoreMove
.
IsBatchInOutStore
&&
StoreMove
.
IsNeedInStore
)
{
return
;
}
}
else
if
(
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
OutStore
)
&&
StoreMove
.
IsBatchInOutStore
)
{
return
;
}
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Door_Down
,
IO_VALUE
.
LOW
));
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Door_Up
,
IO_VALUE
.
HIGH
));
KND
.
IOMove
(
IO_Type
.
Door_Down
,
IO_VALUE
.
LOW
);
...
...
@@ -451,14 +455,18 @@ namespace OnlineStore.DeviceLibrary
}
private
void
CloseDoorAndWait
()
{
if
(
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
InStore
)
||
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
OutStore
)
)
if
(
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
InStore
))
{
//如果是批量出入库,不需要经过此门
if
(
StoreMove
.
IsBatchInOutStore
)
if
(
StoreMove
.
IsBatchInOutStore
&&
StoreMove
.
IsNeedInStore
)
{
return
;
}
}
else
if
(
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
OutStore
)
&&
StoreMove
.
IsBatchInOutStore
)
{
return
;
}
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Door_Down
,
IO_VALUE
.
HIGH
));
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitIO
(
IO_Type
.
Door_Up
,
IO_VALUE
.
LOW
));
KND
.
IOMove
(
IO_Type
.
Door_Down
,
IO_VALUE
.
HIGH
);
...
...
@@ -977,14 +985,6 @@ namespace OnlineStore.DeviceLibrary
{
try
{
TimeSpan
span
=
DateTime
.
Now
-
preIoTimerOutTime
;
if
(
span
.
TotalSeconds
>
1
)
{
preIoTimerOutTime
=
DateTime
.
Now
;
if
(!
alarmType
.
Equals
(
StoreAlarmType
.
IoSingleTimeOut
))
{
return
;
}
if
(
storeRunStatus
<
StoreRunStatus
.
Runing
)
{
return
;
...
...
@@ -993,14 +993,21 @@ namespace OnlineStore.DeviceLibrary
{
return
;
}
TimeSpan
span
=
DateTime
.
Now
-
preIoTimerOutTime
;
if
(
span
.
TotalSeconds
<
1
)
{
return
;
}
preIoTimerOutTime
=
DateTime
.
Now
;
if
(
alarmType
.
Equals
(
StoreAlarmType
.
IoSingleTimeOut
)
||
alarmType
.
Equals
(
StoreAlarmType
.
BatchAlarm
)
||
alarmType
.
Equals
(
StoreAlarmType
.
BatchIoTimeOut
))
{
//若BOX和移栽都没有在等待Io的过程中则此Io超时异常可能已经处理过
if
(
alarmType
.
Equals
(
StoreAlarmType
.
IoSingleTimeOut
)
&&
StoreMove
.
IsInWait
==
false
)
if
(
alarmType
.
Equals
(
StoreAlarmType
.
IoSingleTimeOut
)
&&
StoreMove
.
IsInWait
==
false
)
{
LogUtil
.
info
(
StoreName
+
"当前空闲中,清理信号超时异常【"
+
alarmInfo
.
alarmDetail
+
"】"
);
alarmType
=
StoreAlarmType
.
None
;
WarnMsg
=
""
;
}
else
if
(
alarmType
.
Equals
(
StoreAlarmType
.
BatchAlarm
)
||
alarmType
.
Equals
(
StoreAlarmType
.
BatchIoTimeOut
))
}
else
if
(
alarmType
.
Equals
(
StoreAlarmType
.
BatchAlarm
)
||
alarmType
.
Equals
(
StoreAlarmType
.
BatchIoTimeOut
))
{
if
(
AutomaticBaiting
.
AutoBaitingStatus
.
Equals
(
StoreRunStatus
.
Runing
)
&&
AutomaticBaiting
.
StoreMove
.
IsInWait
.
Equals
(
false
))
{
...
...
@@ -1010,6 +1017,7 @@ namespace OnlineStore.DeviceLibrary
}
}
}
}
catch
(
Exception
ex
)
{
...
...
source/DeviceLibrary/acSingleStore/AC_SA_BoxBean_Partial.cs
查看文件 @
243d29d
...
...
@@ -281,6 +281,10 @@ namespace OnlineStore.DeviceLibrary
/// <summary>
/// 开始入库移动移动
/// </summary>
/// <param name="param">入库参数</param>
/// <param name="IsBatchWork">是否批量出库</param>
/// <param name="isNeedInStore">是否需要入库,不需要入库时直接等待拿走料盘</param>
/// <returns></returns>
public
bool
StartInStoreMove
(
InOutStoreParam
param
,
bool
IsBatchWork
,
bool
isNeedInStore
)
{
InOutWatch
.
Restart
();
...
...
source/DeviceLibrary/acSingleStore/AutomaticBaiting.cs
查看文件 @
243d29d
...
...
@@ -159,7 +159,7 @@ namespace OnlineStore.DeviceLibrary
if
(
IsNeedStartInout
)
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
AUTO_R03_AutoAxisHome
);
LogUtil
.
info
(
Name
+
"复位中:需要
批量入库,检测是否有料盘
"
);
LogUtil
.
info
(
Name
+
"复位中:需要
检测是否有料盘,批量轴匀速上升速度【"
+
StoreManager
.
Config
.
Batch_Axis
.
TargetSpeed
+
"】
"
);
ACAxisSpeedMove
(
StoreManager
.
Config
.
Batch_Axis
,
StoreManager
.
Config
.
Batch_Axis
.
TargetSpeed
);
}
else
...
...
@@ -244,7 +244,7 @@ namespace OnlineStore.DeviceLibrary
}
else
{
LogUtil
.
info
(
Name
+
" 入料 ,轴上升到检测到料盘"
);
LogUtil
.
info
(
Name
+
" 入料 ,轴上升到检测到料盘
,速度【"
+
StoreManager
.
Config
.
Batch_Axis
.
TargetSpeed
+
"】
"
);
ACAxisSpeedMove
(
StoreManager
.
Config
.
Batch_Axis
,
StoreManager
.
Config
.
Batch_Axis
.
TargetSpeed
);
}
}
...
...
@@ -294,7 +294,7 @@ namespace OnlineStore.DeviceLibrary
else
if
(
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
AUTO_I06_SuckingDisc_Up
))
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
AUTO_I07_BatchAxisUp
);
LogUtil
.
info
(
Name
+
"入料: 批量上下料轴上升"
);
LogUtil
.
info
(
Name
+
"入料: 批量上下料轴上升
速度【"
+
StoreManager
.
Config
.
Batch_Axis
.
TargetSpeed
+
"】
"
);
ACAxisSpeedMove
(
StoreManager
.
Config
.
Batch_Axis
,
StoreManager
.
Config
.
Batch_Axis
.
TargetSpeed
);
}
else
if
(
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
AUTO_I07_BatchAxisUp
))
...
...
@@ -303,10 +303,8 @@ namespace OnlineStore.DeviceLibrary
{
if
(
LastCode
.
Equals
(
""
))
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
AUTO_I10_WaitTrayGo
);
LogUtil
.
info
(
Name
+
"入料: 未扫到二维码,叉子过来拿料盘"
);
string
posId
=
StoreManager
.
Store
.
PositionNumList
[
0
];
StoreManager
.
Store
.
StartInStoreMove
(
new
InOutStoreParam
(
""
,
posId
),
true
,
false
);
LogUtil
.
info
(
Name
+
"入料: 未扫到二维码,将料盘送出,等待料盘拿走"
);
SendTrayOut
();
}
else
{
...
...
@@ -334,15 +332,14 @@ namespace OnlineStore.DeviceLibrary
}
else
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
AUTO_I10_WaitTrayGo
);
LogUtil
.
info
(
Name
+
"入料: 未扫到二维码,叉子过来拿料盘"
);
string
posId
=
StoreManager
.
Store
.
PositionNumList
[
0
];
StoreManager
.
Store
.
StartInStoreMove
(
new
InOutStoreParam
(
""
,
posId
),
true
,
false
);
LogUtil
.
info
(
Name
+
"入料: 未获取到PosID或启动入库失败,将料盘送出,等待料盘拿走"
);
SendTrayOut
();
}
}
else
if
(
StoreMove
.
MoveStep
.
Equals
(
StoreMoveStep
.
AUTO_I09_WaitTrayLeave
))
{
if
(
StoreManager
.
Store
.
StoreMove
.
MoveStep
>=
StoreMoveStep
.
SI_09_MoveToBag
)
if
(
StoreManager
.
Store
.
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
None
)
||
(
StoreManager
.
Store
.
StoreMove
.
IsNeedInStore
&&
StoreManager
.
Store
.
StoreMove
.
MoveStep
>=
StoreMoveStep
.
SI_09_MoveToBag
))
{
IsNeedScanCode
();
}
...
...
@@ -366,6 +363,16 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
error
(
Name
+
"未找到步骤:"
+
StoreMove
.
MoveType
);
}
}
private
static
void
SendTrayOut
()
{
StoreMove
.
NextMoveStep
(
StoreMoveStep
.
AUTO_I10_WaitTrayGo
);
StoreMove
.
TimeOutSeconds
=
120
;
string
posId
=
StoreManager
.
Store
.
PositionNumList
[
0
];
StoreManager
.
Store
.
StartInStoreMove
(
new
InOutStoreParam
(
""
,
posId
),
true
,
false
);
StoreMove
.
WaitList
.
Add
(
WaitResultInfo
.
WaitStoreRuning
());
}
private
static
void
SuckingDiscWork
()
{
KND
.
IOMove
(
IO_Type
.
SuckingDisc_Work
,
IO_VALUE
.
LOW
);
...
...
source/DeviceLibrary/acSingleStore/AutomaticBaiting_Partial.cs
查看文件 @
243d29d
...
...
@@ -136,6 +136,9 @@ namespace OnlineStore.DeviceLibrary
else
if
(
wait
.
WaitType
==
(
int
)
Wait_Type
.
ScanCode_11
)
{
wait
.
IsEnd
=
(
LastCode
.
Equals
(
""
).
Equals
(
false
));
}
else
if
(
wait
.
WaitType
==
(
int
)
Wait_Type
.
StoreRuning_13
)
{
wait
.
IsEnd
=
(
StoreManager
.
Store
.
storeRunStatus
.
Equals
(
StoreRunStatus
.
Runing
)
&&
StoreManager
.
Store
.
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
None
));
}
if
(
wait
.
IsEnd
)
{
...
...
@@ -400,6 +403,8 @@ namespace OnlineStore.DeviceLibrary
string
posId
=
data
[
ParamDefine
.
posId
];
string
plateW
=
data
[
ParamDefine
.
plateW
];
string
plateH
=
data
[
ParamDefine
.
plateH
];
string
singleOut
=
data
[
ParamDefine
.
singleOut
];
bool
isSingleOut
=
singleOut
.
ToLower
().
Equals
(
"true"
);
string
[]
posArray
=
posId
.
Split
(
'#'
);
if
(!(
posArray
.
Length
==
2
))
{
...
...
@@ -424,7 +429,7 @@ namespace OnlineStore.DeviceLibrary
LastPosId
=
posId
;
InOutStoreParam
param
=
new
InOutStoreParam
(
message
,
posId
,
plateH
,
plateW
,
0
);
StoreManager
.
Store
.
StartInStoreMove
(
param
,
true
);
StoreManager
.
Store
.
StartInStoreMove
(
param
,
!
isSingleOut
);
//如果当前正在出入库中,需要记录下来,等待空闲时执行
LogUtil
.
info
(
Name
+
" 收到服务器入库命令:库位号【"
+
posId
+
"】二维码【"
+
message
+
"】 开始入库!"
);
}
...
...
source/DeviceLibrary/store/model/StoreMoveInfo.cs
查看文件 @
243d29d
...
...
@@ -307,6 +307,12 @@ namespace OnlineStore.DeviceLibrary
wait
.
WaitType
=
(
int
)
Wait_Type
.
TakeTrayGo_12
;
return
wait
;
}
public
static
WaitResultInfo
WaitStoreRuning
()
{
WaitResultInfo
wait
=
new
WaitResultInfo
();
wait
.
WaitType
=
(
int
)
Wait_Type
.
StoreRuning_13
;
return
wait
;
}
public
string
ToStr
()
{
if
(
WaitType
==
(
int
)
Wait_Type
.
AxisMove_1
)
...
...
@@ -361,12 +367,18 @@ namespace OnlineStore.DeviceLibrary
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
TakeTrayGo_12
)
{
return
"等待操作人员拿走料盘"
;
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
StoreRuning_13
)
{
return
"等待送料结束"
;
}
else
{
return
"Wait位置类型:WaitType=【"
+
WaitType
+
"】"
;
}
}
/// <summary>
/// 当未结束时可以重复运动的次数
/// </summary>
...
...
@@ -475,6 +487,10 @@ namespace OnlineStore.DeviceLibrary
/// 12=操作人员拿走料盘,并点击确定。
/// </summary>
TakeTrayGo_12
=
12
,
/// <summary>
/// 等待料仓正常运行无操作,等待送料结束
/// </summary>
StoreRuning_13
,
}
public
enum
StoreMoveType
{
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论