Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC30-AutoInOutStore
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit ec655f8a
由
几米阳光
编写于
2019-06-05 09:21:16 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
出料逻辑修改。
1 个父辈
e1ba4c05
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
7 个修改的文件
包含
56 行增加
和
35 行删除
source/ACSingleStore/ResourceCulture.cs
source/ACSingleStore/记录.txt
source/DeviceLibrary/DeviceLibrary/PanasonicServo/BatchAxisController.cs
source/DeviceLibrary/acSingleStore/AutomaticBaiting.cs
source/DeviceLibrary/acSingleStore/AutomaticBaiting_Partial.cs
source/DeviceLibrary/store/StoreMoveStep.cs
source/DeviceLibrary/store/model/StoreMoveInfo.cs
source/ACSingleStore/ResourceCulture.cs
查看文件 @
ec655f8
...
@@ -14,7 +14,7 @@ namespace OnlineStore.AutoInOutStore
...
@@ -14,7 +14,7 @@ namespace OnlineStore.AutoInOutStore
{
{
public
class
ResourceCulture
public
class
ResourceCulture
{
{
public
static
bool
ShowLog
=
true
;
public
static
bool
ShowLog
=
false
;
public
static
string
China
=
"zh-CN"
;
public
static
string
China
=
"zh-CN"
;
public
static
string
English
=
"en-US"
;
public
static
string
English
=
"en-US"
;
public
static
string
German
=
"ge-DE"
;
public
static
string
German
=
"ge-DE"
;
...
...
source/ACSingleStore/记录.txt
查看文件 @
ec655f8
...
@@ -198,10 +198,11 @@ IO模块读取时间改为可配置。
...
@@ -198,10 +198,11 @@ IO模块读取时间改为可配置。
BUG需要修改:
吸盘吸料过程中需要一直检测吸盘气压信号
门锁未关闭时不能点关闭门锁。
...
...
source/DeviceLibrary/DeviceLibrary/PanasonicServo/BatchAxisController.cs
查看文件 @
ec655f8
...
@@ -16,7 +16,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -16,7 +16,8 @@ namespace OnlineStore.DeviceLibrary
private
static
bool
IsStop
=
false
;
private
static
bool
IsStop
=
false
;
private
static
System
.
Timers
.
Timer
checkTimer
=
null
;
private
static
System
.
Timers
.
Timer
checkTimer
=
null
;
private
static
string
TargetIoType
=
IO_Type
.
TrayCheck_LoadMaterial
;
private
static
string
TargetIoType
=
IO_Type
.
TrayCheck_LoadMaterial
;
public
static
bool
StartCheck
(
string
targetIo
)
private
static
IO_VALUE
TargetIoValue
=
IO_VALUE
.
HIGH
;
public
static
bool
StartCheck
(
string
targetIo
,
IO_VALUE
value
=
IO_VALUE
.
HIGH
)
{
{
if
(
checkTimer
==
null
)
if
(
checkTimer
==
null
)
{
{
...
@@ -26,8 +27,9 @@ namespace OnlineStore.DeviceLibrary
...
@@ -26,8 +27,9 @@ namespace OnlineStore.DeviceLibrary
checkTimer
.
Elapsed
+=
CheckTimer_Elapsed
;
checkTimer
.
Elapsed
+=
CheckTimer_Elapsed
;
checkTimer
.
Enabled
=
false
;
checkTimer
.
Enabled
=
false
;
}
}
TargetIoValue
=
value
;
TargetIoType
=
targetIo
;
TargetIoType
=
targetIo
;
checkTimer
.
Start
();
checkTimer
.
Start
();
return
true
;
return
true
;
}
}
...
@@ -46,9 +48,9 @@ namespace OnlineStore.DeviceLibrary
...
@@ -46,9 +48,9 @@ namespace OnlineStore.DeviceLibrary
if
(
IsInProcess
)
{
return
;
}
if
(
IsInProcess
)
{
return
;
}
IsInProcess
=
true
;
IsInProcess
=
true
;
bool
result
=
false
;
bool
result
=
false
;
if
(
IOManager
.
IOValue
(
TargetIoType
).
Equals
(
IO_VALUE
.
HIGH
))
if
(
IOManager
.
IOValue
(
TargetIoType
).
Equals
(
TargetIoValue
))
{
{
LogUtil
.
info
(
"批量上料轴,检测到
【"
+
TargetIoType
+
"】信号
,可以停止运动"
);
LogUtil
.
info
(
"批量上料轴,检测到
"
+
TargetIoType
+
"="
+
TargetIoValue
+
"
,可以停止运动"
);
result
=
true
;
result
=
true
;
}
}
else
if
(
IOManager
.
IOValue
(
IO_Type
.
BatchAxis_Limit
).
Equals
(
IO_VALUE
.
HIGH
))
else
if
(
IOManager
.
IOValue
(
IO_Type
.
BatchAxis_Limit
).
Equals
(
IO_VALUE
.
HIGH
))
...
...
source/DeviceLibrary/acSingleStore/AutomaticBaiting.cs
查看文件 @
ec655f8
此文件的差异被折叠,
点击展开。
source/DeviceLibrary/acSingleStore/AutomaticBaiting_Partial.cs
查看文件 @
ec655f8
...
@@ -262,9 +262,9 @@ namespace OnlineStore.DeviceLibrary
...
@@ -262,9 +262,9 @@ namespace OnlineStore.DeviceLibrary
public
static
bool
BatchAxisIsEnd
(
WaitResultInfo
wait
,
TimeSpan
startSpan
)
public
static
bool
BatchAxisIsEnd
(
WaitResultInfo
wait
,
TimeSpan
startSpan
)
{
{
bool
result
=
false
;
bool
result
=
false
;
if
(
IOManager
.
IOValue
(
wait
.
IoType
).
Equals
(
IO_VALUE
.
HIGH
))
if
(
IOManager
.
IOValue
(
wait
.
IoType
).
Equals
(
wait
.
IoValue
))
{
{
LogUtil
.
debug
(
wait
.
ToStr
()
+
" 检测到
【"
+
wait
.
IoType
+
"】信号
,可以停止运动"
);
LogUtil
.
debug
(
wait
.
ToStr
()
+
" 检测到
"
+
wait
.
IoType
+
"="
+
wait
.
IoValue
+
"
,可以停止运动"
);
result
=
true
;
result
=
true
;
}
}
else
if
(
IOManager
.
IOValue
(
IO_Type
.
BatchAxis_Limit
).
Equals
(
IO_VALUE
.
HIGH
))
else
if
(
IOManager
.
IOValue
(
IO_Type
.
BatchAxis_Limit
).
Equals
(
IO_VALUE
.
HIGH
))
...
@@ -567,32 +567,37 @@ namespace OnlineStore.DeviceLibrary
...
@@ -567,32 +567,37 @@ namespace OnlineStore.DeviceLibrary
{
{
map
.
Add
(
ParamDefine
.
doorStatus
,
ResourceControl
.
GetString
(
ResourceControl
.
doorOpen
,
"Doorlock open"
));
map
.
Add
(
ParamDefine
.
doorStatus
,
ResourceControl
.
GetString
(
ResourceControl
.
doorOpen
,
"Doorlock open"
));
}
}
if
(
IsWaitTragGo
&&
(
IsGetTrayGo
.
Equals
(
false
)))
if
(
IsWaitTragGo
&&
(
IsGetTrayGo
.
Equals
(
false
)))
{
{
map
[
ParamDefine
.
confirmReelOut
]
=
ParamDefine
.
enable
;
map
[
ParamDefine
.
confirmReelOut
]
=
ParamDefine
.
enable
;
}
}
else
if
(
CanOpenBatchDoor
())
else
if
(
CanOpenBatchDoor
())
{
{
if
(
DoorStatus
.
Equals
(
2
))
if
(
DoorStatus
.
Equals
(
2
))
{
{
if
(
BatchOutStoreCount
>
0
)
if
(
BatchOutStoreCount
>
0
)
{
{
map
[
ParamDefine
.
takeOutReel
]
=
ParamDefine
.
enable
;
map
[
ParamDefine
.
takeOutReel
]
=
ParamDefine
.
enable
;
}
}
else
else
{
{
map
[
ParamDefine
.
openLock
]
=
ParamDefine
.
enable
;
map
[
ParamDefine
.
openLock
]
=
ParamDefine
.
enable
;
map
[
ParamDefine
.
singleReelIn
]
=
ParamDefine
.
enable
;
map
[
ParamDefine
.
singleReelIn
]
=
ParamDefine
.
enable
;
}
}
}
}
else
else
if
(
IOManager
.
IOValue
(
IO_Type
.
DoorClose_LoadMaterial
).
Equals
(
IO_VALUE
.
HIGH
))
{
{
map
[
ParamDefine
.
closeLock
]
=
ParamDefine
.
enable
;
map
[
ParamDefine
.
closeLock
]
=
ParamDefine
.
enable
;
map
[
ParamDefine
.
startBatchIn
]
=
ParamDefine
.
enable
;
map
[
ParamDefine
.
startBatchIn
]
=
ParamDefine
.
enable
;
}
}
}
}
else
if
(
DoorStatus
.
Equals
(
1
)
&&
StoreMove
.
MoveType
.
Equals
(
StoreMoveType
.
OutStore
)
&&
IOManager
.
IOValue
(
IO_Type
.
DoorClose_LoadMaterial
).
Equals
(
IO_VALUE
.
HIGH
))
{
//出库过程中 可以关门
map
[
ParamDefine
.
closeLock
]
=
ParamDefine
.
enable
;
}
return
map
;
return
map
;
}
}
...
@@ -609,20 +614,20 @@ namespace OnlineStore.DeviceLibrary
...
@@ -609,20 +614,20 @@ namespace OnlineStore.DeviceLibrary
return
ResourceControl
.
GetString
(
ResourceControl
.
CnotOpen
,
"BUSY,open doorlock failure"
);
return
ResourceControl
.
GetString
(
ResourceControl
.
CnotOpen
,
"BUSY,open doorlock failure"
);
}
}
}
}
public
static
string
doStartBatchIn
()
public
static
string
doStartBatchIn
()
{
{
if
(!
DoorIsClose
())
if
(!
DoorIsClose
())
{
{
return
ResourceControl
.
GetString
(
ResourceControl
.
batchInError
,
"Batch storing Error: Close feeding device"
);
return
ResourceControl
.
GetString
(
ResourceControl
.
batchInError
,
"Batch storing Error: Close feeding device"
);
}
}
if
(
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Fixture
).
Equals
(
IO_VALUE
.
HIGH
))
if
(
IOManager
.
IOValue
(
IO_Type
.
TrayCheck_Fixture
).
Equals
(
IO_VALUE
.
HIGH
))
{
{
return
ResourceControl
.
GetString
(
ResourceControl
.
batchInError2
,
"Batch storing Error: gripper full, check before restoring"
);
return
ResourceControl
.
GetString
(
ResourceControl
.
batchInError2
,
"Batch storing Error: gripper full, check before restoring"
);
}
}
StopOutProcess
();
StopOutProcess
();
BatchDoorClose
(
false
);
BatchDoorClose
(
false
);
Reset
(
false
,
true
);
Reset
(
false
,
true
);
return
""
;
return
""
;
}
}
public
static
string
doTakeReel
()
public
static
string
doTakeReel
()
...
@@ -631,7 +636,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -631,7 +636,7 @@ namespace OnlineStore.DeviceLibrary
{
{
if
(
BatchOutStoreCount
>
0
&&
BatchOutStoreHeight
>
0
)
if
(
BatchOutStoreCount
>
0
&&
BatchOutStoreHeight
>
0
)
{
{
BatchDoorOpen
(
false
);
//
BatchDoorOpen(false);
return
StartOut
();
return
StartOut
();
//return "";
//return "";
}
}
...
...
source/DeviceLibrary/store/StoreMoveStep.cs
查看文件 @
ec655f8
...
@@ -556,22 +556,26 @@ namespace OnlineStore.DeviceLibrary
...
@@ -556,22 +556,26 @@ namespace OnlineStore.DeviceLibrary
AUTO_O00_Wait
=
1300
,
AUTO_O00_Wait
=
1300
,
/// <summary>
/// <summary>
///
等待门锁打开
///
批量轴先匀速下降到X12不亮
/// </summary>
/// </summary>
AUTO_O01_WaitDoorOpen
=
1301
,
AUTO_O01_BatchAxisDown
=
1301
,
/// <summary>
/// 打开门锁
/// </summary>
AUTO_O02_WaitDoorOpen
=
1302
,
/// <summary>
/// <summary>
/// 等待出料检测信号关闭
/// 等待出料检测信号关闭
/// </summary>
/// </summary>
AUTO_O0
2_WaitOutSingleLow
=
1302
,
AUTO_O0
3_WaitOutSingleLow
=
1303
,
/// <summary>
/// <summary>
/// 向上运动,等待DI12亮或者极限亮停止
/// 向上运动,等待DI12亮或者极限亮停止
/// </summary>
/// </summary>
AUTO_O0
3_SpeedMove
=
1303
,
AUTO_O0
4_SpeedMove
=
1304
,
/// <summary>
/// <summary>
/// 极限亮,返回P2点
/// 极限亮,返回P2点
/// </summary>
/// </summary>
AUTO_O05_BackToP2
=
130
4
,
AUTO_O05_BackToP2
=
130
5
,
#
endregion
#
endregion
...
...
source/DeviceLibrary/store/model/StoreMoveInfo.cs
查看文件 @
ec655f8
...
@@ -277,7 +277,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -277,7 +277,7 @@ namespace OnlineStore.DeviceLibrary
/// 10=等待批量上下料轴运动 停止
/// 10=等待批量上下料轴运动 停止
/// </summary>
/// </summary>
/// <returns></returns>
/// <returns></returns>
public
static
WaitResultInfo
WaitBatchAxisStop
(
ConfigMoveAxis
moveAxis
,
int
targetPosition
,
string
targetIoType
)
public
static
WaitResultInfo
WaitBatchAxisStop
(
ConfigMoveAxis
moveAxis
,
int
targetPosition
,
string
targetIoType
,
IO_VALUE
value
=
IO_VALUE
.
HIGH
)
{
{
WaitResultInfo
wait
=
new
WaitResultInfo
();
WaitResultInfo
wait
=
new
WaitResultInfo
();
wait
.
TargetPosition
=
targetPosition
;
wait
.
TargetPosition
=
targetPosition
;
...
@@ -287,6 +287,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -287,6 +287,7 @@ namespace OnlineStore.DeviceLibrary
wait
.
IsHomeMove
=
true
;
wait
.
IsHomeMove
=
true
;
wait
.
IsEnd
=
false
;
wait
.
IsEnd
=
false
;
wait
.
IoType
=
targetIoType
;
wait
.
IoType
=
targetIoType
;
wait
.
IoValue
=
value
;
return
wait
;
return
wait
;
}
}
/// <summary>
/// <summary>
...
@@ -350,11 +351,11 @@ namespace OnlineStore.DeviceLibrary
...
@@ -350,11 +351,11 @@ namespace OnlineStore.DeviceLibrary
}
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
WaitHeight_7
)
else
if
(
WaitType
==
(
int
)
Wait_Type
.
WaitHeight_7
)
{
{
return
ResourceControl
.
GetString
(
ResourceControl
.
trayHeight
,
"料盘高度"
)+
"【"
+
HeightValue
+
"】 "
;
return
ResourceControl
.
GetString
(
ResourceControl
.
trayHeight
,
"料盘高度"
)
+
"【"
+
HeightValue
+
"】 "
;
}
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
AxisLimitNegativeSingle_8
)
else
if
(
WaitType
==
(
int
)
Wait_Type
.
AxisLimitNegativeSingle_8
)
{
{
return
"【"
+
AxisInfo
.
DisplayStr
+
"】"
+
ResourceControl
.
GetString
(
ResourceControl
.
FuLimit
,
"负限位"
)+
"【"
+
IoValue
+
"】 "
;
return
"【"
+
AxisInfo
.
DisplayStr
+
"】"
+
ResourceControl
.
GetString
(
ResourceControl
.
FuLimit
,
"负限位"
)
+
"【"
+
IoValue
+
"】 "
;
}
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
AxisLimitPositiveSingle_9
)
else
if
(
WaitType
==
(
int
)
Wait_Type
.
AxisLimitPositiveSingle_9
)
{
{
...
@@ -362,20 +363,28 @@ namespace OnlineStore.DeviceLibrary
...
@@ -362,20 +363,28 @@ namespace OnlineStore.DeviceLibrary
}
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
BatchAxisMove_10
)
else
if
(
WaitType
==
(
int
)
Wait_Type
.
BatchAxisMove_10
)
{
{
return
ResourceControl
.
GetString
(
ResourceControl
.
BatchStop
,
"上料轴运动停止 "
);
return
ResourceControl
.
GetString
(
ResourceControl
.
BatchStop
,
"上料轴运动停止 "
);
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
ScanCode_11
)
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
ScanCode_11
)
{
{
return
ResourceControl
.
GetString
(
ResourceControl
.
ScanOk
,
"扫码结束"
);
return
ResourceControl
.
GetString
(
ResourceControl
.
ScanOk
,
"扫码结束"
);
}
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
TakeTrayGo_12
)
else
if
(
WaitType
==
(
int
)
Wait_Type
.
TakeTrayGo_12
)
{
{
return
ResourceControl
.
GetString
(
ResourceControl
.
TakeTrayGo
,
"操作人员拿走料盘"
);
if
(
AutomaticBaiting
.
WaitIoValue
.
Equals
(
IO_VALUE
.
HIGH
))
{
return
ResourceControl
.
GetString
(
"操作人员放入料盘"
,
"操作人员放入料盘"
);
}
else
{
return
ResourceControl
.
GetString
(
ResourceControl
.
TakeTrayGo
,
"操作人员拿走料盘"
);
}
}
}
else
if
(
WaitType
==
(
int
)
Wait_Type
.
StoreRuning_13
)
else
if
(
WaitType
==
(
int
)
Wait_Type
.
StoreRuning_13
)
{
{
return
ResourceControl
.
GetString
(
ResourceControl
.
WaitEnd
,
"等待送料结束"
);
return
ResourceControl
.
GetString
(
ResourceControl
.
WaitEnd
,
"等待送料结束"
);
}
}
else
else
{
{
return
"WaitType=【"
+
WaitType
+
"】"
;
return
"WaitType=【"
+
WaitType
+
"】"
;
}
}
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论