Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
李娜
/
AutoCountMachine
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 8a6f686d
由
刘韬
编写于
2022-11-01 09:23:27 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
1
1 个父辈
aa4ad179
隐藏空白字符变更
内嵌
并排
正在显示
18 个修改的文件
包含
447 行增加
和
29 行删除
RC1266-AutoCountMachine/source/AutoCountClient/FrmInputEquip.cs
RC1266-AutoCountMachine/source/AutoCountClient/FrmOutputEquip.cs
RC1266-AutoCountMachine/source/AutoCountClient/FrmRobotMain.Designer.cs
RC1266-AutoCountMachine/source/AutoCountClient/FrmRobotMain.cs
RC1266-AutoCountMachine/source/Common/Setting_Init.cs
RC1266-AutoCountMachine/source/DeviceLibrary/DeviceLibrary.csproj
RC1266-AutoCountMachine/source/DeviceLibrary/FrmDevicePause.Designer.cs
RC1266-AutoCountMachine/source/DeviceLibrary/FrmDevicePause.cs
RC1266-AutoCountMachine/source/DeviceLibrary/FrmDevicePause.resx
RC1266-AutoCountMachine/source/DeviceLibrary/RobotConfig/Config_Robot.csv
RC1266-AutoCountMachine/source/DeviceLibrary/bean/InputEquip_InStore.cs
RC1266-AutoCountMachine/source/DeviceLibrary/bean/OutputEquip.cs
RC1266-AutoCountMachine/source/DeviceLibrary/bean/OutputEquip_Partial.cs
RC1266-AutoCountMachine/source/DeviceLibrary/bean/OutputEquip_Shelf.cs
RC1266-AutoCountMachine/source/DeviceLibrary/bean/RobotBean.cs
RC1266-AutoCountMachine/source/DeviceLibrary/bean/X_RAY_Equip.cs
RC1266-AutoCountMachine/source/DeviceLibrary/model/MoveStep.cs
RC1266-AutoCountMachine/source/LoadCVSLibrary/storeConfig/config/AIO_Type.cs
RC1266-AutoCountMachine/source/AutoCountClient/FrmInputEquip.cs
查看文件 @
8a6f686
...
@@ -26,6 +26,7 @@ namespace OnlineStore.AutoCountClient
...
@@ -26,6 +26,7 @@ namespace OnlineStore.AutoCountClient
private
InputEquip
equipBean
;
private
InputEquip
equipBean
;
internal
FrmInputEquip
(
InputEquip
moveEquip
)
internal
FrmInputEquip
(
InputEquip
moveEquip
)
{
{
FrmDevicePause
.
Init
(
this
);
equipBase
=
moveEquip
;
equipBase
=
moveEquip
;
this
.
equipBean
=
moveEquip
;
this
.
equipBean
=
moveEquip
;
Control
.
CheckForIllegalCrossThreadCalls
=
false
;
Control
.
CheckForIllegalCrossThreadCalls
=
false
;
...
...
RC1266-AutoCountMachine/source/AutoCountClient/FrmOutputEquip.cs
查看文件 @
8a6f686
...
@@ -829,6 +829,8 @@ namespace OnlineStore.AutoCountClient
...
@@ -829,6 +829,8 @@ namespace OnlineStore.AutoCountClient
}
}
private
void
btnMoveReset_Click
(
object
sender
,
EventArgs
e
)
private
void
btnMoveReset_Click
(
object
sender
,
EventArgs
e
)
{
{
if
(
MessageBox
.
Show
(
"请确认出口夹爪上是否有料盘,请在复位前取下. 点击确认继续"
,
""
,
MessageBoxButtons
.
OKCancel
)
!=
DialogResult
.
OK
)
return
;
LogUtil
.
info
(
equipBean
.
Name
+
"点击:取放料机构复位"
);
LogUtil
.
info
(
equipBean
.
Name
+
"点击:取放料机构复位"
);
if
(
equipBase
.
runStatus
>
(
RobotRunStatus
.
Wait
))
if
(
equipBase
.
runStatus
>
(
RobotRunStatus
.
Wait
))
{
{
...
...
RC1266-AutoCountMachine/source/AutoCountClient/FrmRobotMain.Designer.cs
查看文件 @
8a6f686
...
@@ -51,6 +51,8 @@
...
@@ -51,6 +51,8 @@
this
.
启动
AToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
启动
AToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
toolStripSeparator4
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
this
.
toolStripSeparator4
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
this
.
复位
RToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
复位
RToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
toolStripSeparator18
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
this
.
安全复位
ToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
toolStripSeparator3
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
this
.
toolStripSeparator3
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
this
.
停止
TToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
停止
TToolStripMenuItem
=
new
System
.
Windows
.
Forms
.
ToolStripMenuItem
();
this
.
toolStripSeparator1
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
this
.
toolStripSeparator1
=
new
System
.
Windows
.
Forms
.
ToolStripSeparator
();
...
@@ -290,6 +292,8 @@
...
@@ -290,6 +292,8 @@
this
.
启动
AToolStripMenuItem
,
this
.
启动
AToolStripMenuItem
,
this
.
toolStripSeparator4
,
this
.
toolStripSeparator4
,
this
.
复位
RToolStripMenuItem
,
this
.
复位
RToolStripMenuItem
,
this
.
toolStripSeparator18
,
this
.
安全复位
ToolStripMenuItem
,
this
.
toolStripSeparator3
,
this
.
toolStripSeparator3
,
this
.
停止
TToolStripMenuItem
,
this
.
停止
TToolStripMenuItem
,
this
.
toolStripSeparator1
,
this
.
toolStripSeparator1
,
...
@@ -302,50 +306,62 @@
...
@@ -302,50 +306,62 @@
// 启动AToolStripMenuItem
// 启动AToolStripMenuItem
//
//
this
.
启动
AToolStripMenuItem
.
Name
=
"启动AToolStripMenuItem"
;
this
.
启动
AToolStripMenuItem
.
Name
=
"启动AToolStripMenuItem"
;
this
.
启动
AToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
1
17
,
26
);
this
.
启动
AToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
1
80
,
26
);
this
.
启动
AToolStripMenuItem
.
Text
=
"启动 "
;
this
.
启动
AToolStripMenuItem
.
Text
=
"启动 "
;
this
.
启动
AToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
启动
AToolStripMenuItem_Click
);
this
.
启动
AToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
启动
AToolStripMenuItem_Click
);
//
//
// toolStripSeparator4
// toolStripSeparator4
//
//
this
.
toolStripSeparator4
.
Name
=
"toolStripSeparator4"
;
this
.
toolStripSeparator4
.
Name
=
"toolStripSeparator4"
;
this
.
toolStripSeparator4
.
Size
=
new
System
.
Drawing
.
Size
(
1
14
,
6
);
this
.
toolStripSeparator4
.
Size
=
new
System
.
Drawing
.
Size
(
1
77
,
6
);
//
//
// 复位RToolStripMenuItem
// 复位RToolStripMenuItem
//
//
this
.
复位
RToolStripMenuItem
.
Name
=
"复位RToolStripMenuItem"
;
this
.
复位
RToolStripMenuItem
.
Name
=
"复位RToolStripMenuItem"
;
this
.
复位
RToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
1
17
,
26
);
this
.
复位
RToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
1
80
,
26
);
this
.
复位
RToolStripMenuItem
.
Text
=
"复位"
;
this
.
复位
RToolStripMenuItem
.
Text
=
"复位"
;
this
.
复位
RToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
复位
RToolStripMenuItem_Click
);
this
.
复位
RToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
复位
RToolStripMenuItem_Click
);
//
//
// toolStripSeparator18
//
this
.
toolStripSeparator18
.
Name
=
"toolStripSeparator18"
;
this
.
toolStripSeparator18
.
Size
=
new
System
.
Drawing
.
Size
(
177
,
6
);
//
// 安全复位ToolStripMenuItem
//
this
.
安全复位
ToolStripMenuItem
.
Name
=
"安全复位ToolStripMenuItem"
;
this
.
安全复位
ToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
180
,
26
);
this
.
安全复位
ToolStripMenuItem
.
Text
=
"安全停止"
;
this
.
安全复位
ToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
安全复位
ToolStripMenuItem_Click
);
//
// toolStripSeparator3
// toolStripSeparator3
//
//
this
.
toolStripSeparator3
.
Name
=
"toolStripSeparator3"
;
this
.
toolStripSeparator3
.
Name
=
"toolStripSeparator3"
;
this
.
toolStripSeparator3
.
Size
=
new
System
.
Drawing
.
Size
(
1
14
,
6
);
this
.
toolStripSeparator3
.
Size
=
new
System
.
Drawing
.
Size
(
1
77
,
6
);
//
//
// 停止TToolStripMenuItem
// 停止TToolStripMenuItem
//
//
this
.
停止
TToolStripMenuItem
.
Name
=
"停止TToolStripMenuItem"
;
this
.
停止
TToolStripMenuItem
.
Name
=
"停止TToolStripMenuItem"
;
this
.
停止
TToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
1
17
,
26
);
this
.
停止
TToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
1
80
,
26
);
this
.
停止
TToolStripMenuItem
.
Text
=
"停止"
;
this
.
停止
TToolStripMenuItem
.
Text
=
"停止"
;
this
.
停止
TToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
停止
TToolStripMenuItem_Click
);
this
.
停止
TToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
停止
TToolStripMenuItem_Click
);
//
//
// toolStripSeparator1
// toolStripSeparator1
//
//
this
.
toolStripSeparator1
.
Name
=
"toolStripSeparator1"
;
this
.
toolStripSeparator1
.
Name
=
"toolStripSeparator1"
;
this
.
toolStripSeparator1
.
Size
=
new
System
.
Drawing
.
Size
(
1
14
,
6
);
this
.
toolStripSeparator1
.
Size
=
new
System
.
Drawing
.
Size
(
1
77
,
6
);
//
//
// 退出ToolStripMenuItem
// 退出ToolStripMenuItem
//
//
this
.
退出
ToolStripMenuItem
.
Name
=
"退出ToolStripMenuItem"
;
this
.
退出
ToolStripMenuItem
.
Name
=
"退出ToolStripMenuItem"
;
this
.
退出
ToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
1
17
,
26
);
this
.
退出
ToolStripMenuItem
.
Size
=
new
System
.
Drawing
.
Size
(
1
80
,
26
);
this
.
退出
ToolStripMenuItem
.
Text
=
"退出"
;
this
.
退出
ToolStripMenuItem
.
Text
=
"退出"
;
this
.
退出
ToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
退出
ToolStripMenuItem_Click_1
);
this
.
退出
ToolStripMenuItem
.
Click
+=
new
System
.
EventHandler
(
this
.
退出
ToolStripMenuItem_Click_1
);
//
//
// toolStripSeparator2
// toolStripSeparator2
//
//
this
.
toolStripSeparator2
.
Name
=
"toolStripSeparator2"
;
this
.
toolStripSeparator2
.
Name
=
"toolStripSeparator2"
;
this
.
toolStripSeparator2
.
Size
=
new
System
.
Drawing
.
Size
(
1
14
,
6
);
this
.
toolStripSeparator2
.
Size
=
new
System
.
Drawing
.
Size
(
1
77
,
6
);
this
.
toolStripSeparator2
.
Visible
=
false
;
this
.
toolStripSeparator2
.
Visible
=
false
;
//
//
// 设置TToolStripMenuItem
// 设置TToolStripMenuItem
...
@@ -721,6 +737,8 @@
...
@@ -721,6 +737,8 @@
private
System
.
Windows
.
Forms
.
ToolStripMenuItem
批量
ToolStripMenuItem
;
private
System
.
Windows
.
Forms
.
ToolStripMenuItem
批量
ToolStripMenuItem
;
private
System
.
Windows
.
Forms
.
ToolStripMenuItem
单盘
ToolStripMenuItem
;
private
System
.
Windows
.
Forms
.
ToolStripMenuItem
单盘
ToolStripMenuItem
;
private
System
.
Windows
.
Forms
.
CheckBox
CB_lookboard
;
private
System
.
Windows
.
Forms
.
CheckBox
CB_lookboard
;
private
System
.
Windows
.
Forms
.
ToolStripSeparator
toolStripSeparator18
;
private
System
.
Windows
.
Forms
.
ToolStripMenuItem
安全复位
ToolStripMenuItem
;
}
}
}
}
RC1266-AutoCountMachine/source/AutoCountClient/FrmRobotMain.cs
查看文件 @
8a6f686
...
@@ -107,7 +107,7 @@ namespace OnlineStore.AutoCountClient
...
@@ -107,7 +107,7 @@ namespace OnlineStore.AutoCountClient
LogUtil
.
error
(
"加载配置失败,直接退出程序"
);
LogUtil
.
error
(
"加载配置失败,直接退出程序"
);
Application
.
Exit
();
Application
.
Exit
();
}
}
FrmDevicePause
.
Init
(
this
);
formLineStatus
(
false
);
formLineStatus
(
false
);
string
title
=
ConfigAppSettings
.
GetValue
(
Setting_Init
.
App_Title
);
string
title
=
ConfigAppSettings
.
GetValue
(
Setting_Init
.
App_Title
);
this
.
Text
=
title
;
this
.
Text
=
title
;
...
@@ -366,6 +366,7 @@ namespace OnlineStore.AutoCountClient
...
@@ -366,6 +366,7 @@ namespace OnlineStore.AutoCountClient
}
}
启动
AToolStripMenuItem
.
Enabled
=
!
isStart
;
启动
AToolStripMenuItem
.
Enabled
=
!
isStart
;
停止
TToolStripMenuItem
.
Enabled
=
isStart
;
停止
TToolStripMenuItem
.
Enabled
=
isStart
;
安全复位
ToolStripMenuItem
.
Enabled
=
isStart
;
}
}
private
void
停止
TToolStripMenuItem_Click
(
object
sender
,
EventArgs
e
)
private
void
停止
TToolStripMenuItem_Click
(
object
sender
,
EventArgs
e
)
...
@@ -392,6 +393,8 @@ namespace OnlineStore.AutoCountClient
...
@@ -392,6 +393,8 @@ namespace OnlineStore.AutoCountClient
MessageBox
.
Show
(
robot
.
Name
+
"设备未启动,无法复位"
);
MessageBox
.
Show
(
robot
.
Name
+
"设备未启动,无法复位"
);
return
;
return
;
}
}
if
(
MessageBox
.
Show
(
"请确认出口夹爪上是否有料盘,请在复位前取下. 点击确认继续"
,
""
,
MessageBoxButtons
.
OKCancel
)
!=
DialogResult
.
OK
)
return
;
LogUtil
.
info
(
robot
.
Name
+
" 点击:复位"
);
LogUtil
.
info
(
robot
.
Name
+
" 点击:复位"
);
robot
.
Reset
();
robot
.
Reset
();
}
}
...
@@ -515,6 +518,9 @@ namespace OnlineStore.AutoCountClient
...
@@ -515,6 +518,9 @@ namespace OnlineStore.AutoCountClient
else
{
else
{
lblXrayWork
.
Text
=
"警告:点料过程中,请勿开门"
;
lblXrayWork
.
Text
=
"警告:点料过程中,请勿开门"
;
}
}
if
(
RobotManager
.
robot
.
SafeStop
)
{
lblXrayWork
.
Text
=
"设备开始停止,请等待当前料处理完毕"
;
}
foreach
(
var
cr
in
CodeManager
.
CamErrCount
)
foreach
(
var
cr
in
CodeManager
.
CamErrCount
)
{
{
if
(
cr
.
Value
>
5
)
if
(
cr
.
Value
>
5
)
...
@@ -1165,5 +1171,32 @@ namespace OnlineStore.AutoCountClient
...
@@ -1165,5 +1171,32 @@ namespace OnlineStore.AutoCountClient
this
.
msgValue
=
value
;
this
.
msgValue
=
value
;
}
}
}
}
private
void
安全复位
ToolStripMenuItem_Click
(
object
sender
,
EventArgs
e
)
{
if
(
robot
!=
null
)
{
if
(
robot
.
runStatus
.
Equals
(
RobotRunStatus
.
Wait
))
{
MessageBox
.
Show
(
robot
.
Name
+
"设备未启动,不需要停止"
);
return
;
}
if
(
MessageBox
.
Show
(
"请确认出口夹爪上是否有料盘,请在复位前取下. 点击确认继续"
,
""
,
MessageBoxButtons
.
OKCancel
)
!=
DialogResult
.
OK
)
return
;
LogUtil
.
info
(
robot
.
Name
+
" 点击:安全停止"
);
if
(
robot
.
inputEquip
.
MoveInfo
.
MoveType
==
RobotMoveType
.
None
)
robot
.
StopRun
();
else
{
robot
.
SafeStop
=
true
;
MessageBox
.
Show
(
"请等待设备入料口放盘完成后自动停止"
,
""
);
}
formLineStatus
(
false
);
}
}
}
}
}
}
RC1266-AutoCountMachine/source/Common/Setting_Init.cs
查看文件 @
8a6f686
...
@@ -96,7 +96,7 @@ namespace OnlineStore.Common
...
@@ -96,7 +96,7 @@ namespace OnlineStore.Common
/// </summary>
/// </summary>
public
static
string
LabelWaitMS
=
"LabelWaitMS"
;
public
static
string
LabelWaitMS
=
"LabelWaitMS"
;
public
static
string
GratingSignal
=
"
GratingSignal"
;
public
static
string
GratingSignal
=
"GratingSignal"
;
/// <summary>
/// <summary>
/// 启用贴标功能
/// 启用贴标功能
/// </summary>
/// </summary>
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/DeviceLibrary.csproj
查看文件 @
8a6f686
...
@@ -100,6 +100,12 @@
...
@@ -100,6 +100,12 @@
<Compile Include="bean\BatchMoveBean.cs" />
<Compile Include="bean\BatchMoveBean.cs" />
<Compile Include="bean\OutputEquip_Shelf.cs" />
<Compile Include="bean\OutputEquip_Shelf.cs" />
<Compile Include="deviceLibrary\TestPlate.cs" />
<Compile Include="deviceLibrary\TestPlate.cs" />
<Compile Include="FrmDevicePause.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="FrmDevicePause.Designer.cs">
<DependentUpon>FrmDevicePause.cs</DependentUpon>
</Compile>
<Compile Include="manager\ParamManager.cs" />
<Compile Include="manager\ParamManager.cs" />
<Compile Include="manager\RobotManager.cs" />
<Compile Include="manager\RobotManager.cs" />
<Compile Include="bean\OutputEquip_Partial.cs" />
<Compile Include="bean\OutputEquip_Partial.cs" />
...
@@ -193,7 +199,11 @@
...
@@ -193,7 +199,11 @@
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
</None>
</ItemGroup>
</ItemGroup>
<ItemGroup />
<ItemGroup>
<EmbeddedResource Include="FrmDevicePause.resx">
<DependentUpon>FrmDevicePause.cs</DependentUpon>
</EmbeddedResource>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Other similar extension points exist, see Microsoft.Common.targets.
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/FrmDevicePause.Designer.cs
0 → 100644
查看文件 @
8a6f686
namespace
OnlineStore
{
partial
class
FrmDevicePause
{
/// <summary>
/// Required designer variable.
/// </summary>
private
System
.
ComponentModel
.
IContainer
components
=
null
;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected
override
void
Dispose
(
bool
disposing
)
{
if
(
disposing
&&
(
components
!=
null
))
{
components
.
Dispose
();
}
base
.
Dispose
(
disposing
);
}
#
region
Windows
Form
Designer
generated
code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private
void
InitializeComponent
()
{
this
.
label1
=
new
System
.
Windows
.
Forms
.
Label
();
this
.
button_resume
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
button_close
=
new
System
.
Windows
.
Forms
.
Button
();
this
.
SuspendLayout
();
//
// label1
//
this
.
label1
.
Font
=
new
System
.
Drawing
.
Font
(
"宋体"
,
21.75F
,
System
.
Drawing
.
FontStyle
.
Bold
,
System
.
Drawing
.
GraphicsUnit
.
Point
,
((
byte
)(
134
)));
this
.
label1
.
ForeColor
=
System
.
Drawing
.
Color
.
Red
;
this
.
label1
.
Location
=
new
System
.
Drawing
.
Point
(
166
,
102
);
this
.
label1
.
Name
=
"label1"
;
this
.
label1
.
Size
=
new
System
.
Drawing
.
Size
(
340
,
107
);
this
.
label1
.
TabIndex
=
0
;
this
.
label1
.
Text
=
"光栅触发设备暂停"
;
this
.
label1
.
TextAlign
=
System
.
Drawing
.
ContentAlignment
.
MiddleCenter
;
//
// button_resume
//
this
.
button_resume
.
Location
=
new
System
.
Drawing
.
Point
(
64
,
309
);
this
.
button_resume
.
Name
=
"button_resume"
;
this
.
button_resume
.
Size
=
new
System
.
Drawing
.
Size
(
128
,
43
);
this
.
button_resume
.
TabIndex
=
1
;
this
.
button_resume
.
Text
=
"恢复运行"
;
this
.
button_resume
.
UseVisualStyleBackColor
=
true
;
this
.
button_resume
.
Click
+=
new
System
.
EventHandler
(
this
.
button_resume_Click
);
//
// button_close
//
this
.
button_close
.
Location
=
new
System
.
Drawing
.
Point
(
491
,
309
);
this
.
button_close
.
Name
=
"button_close"
;
this
.
button_close
.
Size
=
new
System
.
Drawing
.
Size
(
128
,
43
);
this
.
button_close
.
TabIndex
=
1
;
this
.
button_close
.
Text
=
"关闭转人工处理"
;
this
.
button_close
.
UseVisualStyleBackColor
=
true
;
this
.
button_close
.
Click
+=
new
System
.
EventHandler
(
this
.
button_close_Click
);
//
// FrmDevicePause
//
this
.
AutoScaleDimensions
=
new
System
.
Drawing
.
SizeF
(
6F
,
12F
);
this
.
AutoScaleMode
=
System
.
Windows
.
Forms
.
AutoScaleMode
.
Font
;
this
.
ClientSize
=
new
System
.
Drawing
.
Size
(
680
,
401
);
this
.
ControlBox
=
false
;
this
.
Controls
.
Add
(
this
.
button_close
);
this
.
Controls
.
Add
(
this
.
button_resume
);
this
.
Controls
.
Add
(
this
.
label1
);
this
.
FormBorderStyle
=
System
.
Windows
.
Forms
.
FormBorderStyle
.
None
;
this
.
MaximizeBox
=
false
;
this
.
MinimizeBox
=
false
;
this
.
Name
=
"FrmDevicePause"
;
this
.
ShowIcon
=
false
;
this
.
ShowInTaskbar
=
false
;
this
.
StartPosition
=
System
.
Windows
.
Forms
.
FormStartPosition
.
CenterScreen
;
this
.
Text
=
"FrmDevicePause"
;
this
.
ResumeLayout
(
false
);
}
#
endregion
private
System
.
Windows
.
Forms
.
Label
label1
;
private
System
.
Windows
.
Forms
.
Button
button_resume
;
private
System
.
Windows
.
Forms
.
Button
button_close
;
}
}
\ No newline at end of file
\ No newline at end of file
RC1266-AutoCountMachine/source/DeviceLibrary/FrmDevicePause.cs
0 → 100644
查看文件 @
8a6f686
using
System
;
using
System.Collections.Generic
;
using
System.ComponentModel
;
using
System.Data
;
using
System.Drawing
;
using
System.Linq
;
using
System.Text
;
using
System.Threading.Tasks
;
using
System.Windows.Forms
;
namespace
OnlineStore
{
public
partial
class
FrmDevicePause
:
Form
{
public
FrmDevicePause
()
{
InitializeComponent
();
}
public
event
EventHandler
onPause
;
static
Form
mainform
;
public
static
void
Init
(
Form
form
)
{
mainform
=
form
;
}
public
static
bool
ShowPauseWindows
()
{
return
(
bool
)
mainform
.
Invoke
(
new
Func
<
bool
>(()
=>
{
FrmDevicePause
frmDevice
=
new
FrmDevicePause
();
frmDevice
.
TopMost
=
true
;
return
frmDevice
.
ShowDialog
()
==
DialogResult
.
OK
;
}));
}
private
void
button_resume_Click
(
object
sender
,
EventArgs
e
)
{
DialogResult
=
DialogResult
.
OK
;
this
.
Close
();
}
private
void
button_close_Click
(
object
sender
,
EventArgs
e
)
{
this
.
Close
();
}
}
}
RC1266-AutoCountMachine/source/DeviceLibrary/FrmDevicePause.resx
0 → 100644
查看文件 @
8a6f686
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
\ No newline at end of file
\ No newline at end of file
RC1266-AutoCountMachine/source/DeviceLibrary/RobotConfig/Config_Robot.csv
查看文件 @
8a6f686
...
@@ -123,7 +123,7 @@ DI,3,下料机构复位,Reset_BTN,1,PRO_AOI_IP_4,X52,,,,,,,,,,
...
@@ -123,7 +123,7 @@ DI,3,下料机构复位,Reset_BTN,1,PRO_AOI_IP_4,X52,,,,,,,,,,
DI,3,下料机构联动,Start_BTN,2,PRO_AOI_IP_4,X53,,,,,,,,,,
DI,3,下料机构联动,Start_BTN,2,PRO_AOI_IP_4,X53,,,,,,,,,,
DI,3,打码机取码气缸前进端,TakeCode_Forward,3,PRO_AOI_IP_4,X54,,,,,,,,,,
DI,3,打码机取码气缸前进端,TakeCode_Forward,3,PRO_AOI_IP_4,X54,,,,,,,,,,
DI,3,打码机取码气缸后退端,TakeCode_Back,4,PRO_AOI_IP_4,X55,,,,,,,,,,
DI,3,打码机取码气缸后退端,TakeCode_Back,4,PRO_AOI_IP_4,X55,,,,,,,,,,
,3,X光点料机皮带出口检测,XRay_OutCheck
,5,PRO_AOI_IP_4,X56,,,,,,,,,,
DI,3,X光点料机皮带出口检测,PrinterOnPosition
,5,PRO_AOI_IP_4,X56,,,,,,,,,,
DI,3,出口皮带线料盘检测,Out_TrayCheck,6,PRO_AOI_IP_4,X57,,,,,,,,,,
DI,3,出口皮带线料盘检测,Out_TrayCheck,6,PRO_AOI_IP_4,X57,,,,,,,,,,
DI,3,点料机NG料气缸前进端,NGCylinder_Forward,7,PRO_AOI_IP_4,X58,,,,,,,,,,
DI,3,点料机NG料气缸前进端,NGCylinder_Forward,7,PRO_AOI_IP_4,X58,,,,,,,,,,
DI,3,点料机NG料气缸后退端,NGCylinder_Back,8,PRO_AOI_IP_4,X59,,,,,,,,,,
DI,3,点料机NG料气缸后退端,NGCylinder_Back,8,PRO_AOI_IP_4,X59,,,,,,,,,,
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/bean/InputEquip_InStore.cs
查看文件 @
8a6f686
...
@@ -92,6 +92,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -92,6 +92,7 @@ namespace OnlineStore.DeviceLibrary
}
}
//private Task GetTargetPTask = null;
//private Task GetTargetPTask = null;
int
getretry
=
0
;
int
getretry
=
0
;
protected
override
void
WorkingProcess
()
protected
override
void
WorkingProcess
()
{
{
if
(
MoveInfo
.
IsInWait
)
if
(
MoveInfo
.
IsInWait
)
...
@@ -423,8 +424,14 @@ namespace OnlineStore.DeviceLibrary
...
@@ -423,8 +424,14 @@ namespace OnlineStore.DeviceLibrary
TimeSpan
span
=
DateTime
.
Now
-
MoveInfo
.
MoveStartTime
;
TimeSpan
span
=
DateTime
.
Now
-
MoveInfo
.
MoveStartTime
;
TickLog
(
"放料完成"
,
false
);
TickLog
(
"放料完成"
,
false
);
WorkLog
(
"放料完成,耗时("
+
FormUtil
.
GetSpanStr
(
span
)
+
")"
);
WorkLog
(
"放料完成,耗时("
+
FormUtil
.
GetSpanStr
(
span
)
+
")"
);
MoveInfo
.
EndMove
();
if
(
RobotManager
.
robot
.
SafeStop
)
{
RobotManager
.
robot
.
SafeStop
=
false
;
MoveInfo
.
NextMoveStep
(
StepEnum
.
SafeStop
);
}
else
MoveInfo
.
EndMove
();
}
}
//放料重试复位
//放料重试复位
else
if
(
MoveInfo
.
IsStep
(
StepEnum
.
IW50_InOutToP2
))
else
if
(
MoveInfo
.
IsStep
(
StepEnum
.
IW50_InOutToP2
))
...
@@ -461,7 +468,14 @@ namespace OnlineStore.DeviceLibrary
...
@@ -461,7 +468,14 @@ namespace OnlineStore.DeviceLibrary
else
if
(
MoveInfo
.
IsStep
(
StepEnum
.
IW53_ResetFinish
))
else
if
(
MoveInfo
.
IsStep
(
StepEnum
.
IW53_ResetFinish
))
{
{
WorkLog
(
"放料重试复位完成"
);
WorkLog
(
"放料重试复位完成"
);
MoveInfo
.
EndMove
();
if
(
RobotManager
.
robot
.
SafeStop
)
{
RobotManager
.
robot
.
SafeStop
=
false
;
MoveInfo
.
NextMoveStep
(
StepEnum
.
SafeStop
);
}
else
MoveInfo
.
EndMove
();
}
}
}
}
...
@@ -520,7 +534,13 @@ namespace OnlineStore.DeviceLibrary
...
@@ -520,7 +534,13 @@ namespace OnlineStore.DeviceLibrary
{
{
return
;
return
;
}
}
if
(
CanStartWork
())
{
return
;
}
if
(
LeftBatchMove
.
MoveInfo
.
MoveStep
==
StepEnum
.
Wait
)
{
return
;
}
if
(
IOValue
(
IO_Type
.
LineIn_GratingSignal
).
Equals
(
IO_VALUE
.
LOW
))
if
(
IOValue
(
IO_Type
.
LineIn_GratingSignal
).
Equals
(
IO_VALUE
.
LOW
))
{
{
//LogUtil.error(Name+ "未检测到上料线体光栅信号,报警急停");
//LogUtil.error(Name+ "未检测到上料线体光栅信号,报警急停");
...
@@ -531,6 +551,12 @@ namespace OnlineStore.DeviceLibrary
...
@@ -531,6 +551,12 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
error
(
Name
+
"未检测到上料线体光栅信号,暂停运行"
);
LogUtil
.
error
(
Name
+
"未检测到上料线体光栅信号,暂停运行"
);
SetWarnMsg
(
"未检测到上料线体光栅信号,暂停运行"
);
SetWarnMsg
(
"未检测到上料线体光栅信号,暂停运行"
);
this
.
MoveStop
=
true
;
this
.
MoveStop
=
true
;
NeedAlarm
=
true
;
if
(
FrmDevicePause
.
ShowPauseWindows
())
{
this
.
MoveStop
=
false
;
}
NeedAlarm
=
false
;
}
}
}
}
}
}
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/bean/OutputEquip.cs
查看文件 @
8a6f686
...
@@ -209,6 +209,13 @@ namespace OnlineStore.DeviceLibrary
...
@@ -209,6 +209,13 @@ namespace OnlineStore.DeviceLibrary
}
}
public
void
SecMoveReset
()
public
void
SecMoveReset
()
{
{
if
(
SecMoveInfo
.
MoveStep
>=
StepEnum
.
OL01_Paste_Back
)
{
IsStartLabel
=
false
;
SecMoveInfo
.
NextMoveStep
(
StepEnum
.
OL13_RToP3
);
SecWorkLog
(
"贴标机构直接复位"
);
return
;
}
SecMoveInfo
.
NewMove
(
RobotMoveType
.
Reset
,
StepEnum
.
OLR01_LabelZHome
);
SecMoveInfo
.
NewMove
(
RobotMoveType
.
Reset
,
StepEnum
.
OLR01_LabelZHome
);
RobotManager
.
LastPrintStatus
=
Asa
.
PrintLabel
.
PrinterStatus
.
Unknown
;
RobotManager
.
LastPrintStatus
=
Asa
.
PrintLabel
.
PrinterStatus
.
Unknown
;
SecMoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
SecMoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
1000
));
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/bean/OutputEquip_Partial.cs
查看文件 @
8a6f686
...
@@ -118,7 +118,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -118,7 +118,7 @@ namespace OnlineStore.DeviceLibrary
}
}
return
false
;
return
false
;
}
}
int
NopaperCount
=
0
;
private
bool
CheckStartLabel
(
bool
needAlarm
=
false
)
private
bool
CheckStartLabel
(
bool
needAlarm
=
false
)
{
{
if
(
MoveInfo
.
MoveParam
==
null
)
if
(
MoveInfo
.
MoveParam
==
null
)
...
@@ -142,9 +142,15 @@ namespace OnlineStore.DeviceLibrary
...
@@ -142,9 +142,15 @@ namespace OnlineStore.DeviceLibrary
}
}
bool
NoPaper
=
IOValue
(
IO_Type
.
PasteCode_OK
).
Equals
(
IO_VALUE
.
HIGH
);
bool
NoPaper
=
IOValue
(
IO_Type
.
PasteCode_OK
).
Equals
(
IO_VALUE
.
HIGH
);
if
(
NoPaper
)
NopaperCount
++;
else
NopaperCount
=
0
;
bool
PrinterOnPosition
=
IOValue
(
IO_Type
.
PrinterOnPosition
).
Equals
(
IO_VALUE
.
LOW
);
//TODO 记录信息,判断贴标模块当前空闲,此时可以打印标签(取码气缸前进,打印标签,取码气缸后退)
//TODO 记录信息,判断贴标模块当前空闲,此时可以打印标签(取码气缸前进,打印标签,取码气缸后退)
if
(
SecMoveInfo
.
MoveType
.
Equals
(
RobotMoveType
.
None
)
&&
!
NoPaper
)
if
(
SecMoveInfo
.
MoveType
.
Equals
(
RobotMoveType
.
None
)
&&
NopaperCount
<=
3
&&
PrinterOnPosition
)
{
{
NeedAlarm
=
false
;
ClearTimeoutAlarm
(
"等待贴标模块空闲"
);
ClearTimeoutAlarm
(
"等待贴标模块空闲"
);
WorkLog
(
"取料: 贴标模块开始打印标签"
);
WorkLog
(
"取料: 贴标模块开始打印标签"
);
//TODO
//TODO
...
@@ -154,11 +160,19 @@ namespace OnlineStore.DeviceLibrary
...
@@ -154,11 +160,19 @@ namespace OnlineStore.DeviceLibrary
IsStartLabel
=
true
;
IsStartLabel
=
true
;
return
true
;
return
true
;
}
}
}
else
if
(!
PrinterOnPosition
)
{
WarnMsg
=
MoveInfo
.
Name
+
"["
+
MoveInfo
.
MoveStep
+
"]["
+
SecMoveInfo
.
MoveType
.
ToString
()
+
"]打印机没推倒位,请处理 超时["
+
FormUtil
.
GetSpanStr
(
MoveInfo
.
StepSpan
())
+
"]"
;
LogUtil
.
error
(
WarnMsg
,
MoveInfo
.
ErrorLogType
,
MoveInfo
.
logSeconds
());
Alarm
(
AlarmType
.
IoSingleTimeOut
);
NeedAlarm
=
true
;
}
else
if
(
NoPaper
)
}
else
if
(
NoPaper
)
{
{
WarnMsg
=
MoveInfo
.
Name
+
"["
+
MoveInfo
.
MoveStep
+
"]["
+
SecMoveInfo
.
MoveType
.
ToString
()
+
"]打印机缺纸,请处理 超时["
+
FormUtil
.
GetSpanStr
(
MoveInfo
.
StepSpan
())
+
"]"
;
WarnMsg
=
MoveInfo
.
Name
+
"["
+
MoveInfo
.
MoveStep
+
"]["
+
SecMoveInfo
.
MoveType
.
ToString
()
+
"]打印机缺纸,请处理 超时["
+
FormUtil
.
GetSpanStr
(
MoveInfo
.
StepSpan
())
+
"]"
;
LogUtil
.
error
(
WarnMsg
,
MoveInfo
.
ErrorLogType
,
MoveInfo
.
logSeconds
());
LogUtil
.
error
(
WarnMsg
,
MoveInfo
.
ErrorLogType
,
MoveInfo
.
logSeconds
());
Alarm
(
AlarmType
.
IoSingleTimeOut
);
Alarm
(
AlarmType
.
IoSingleTimeOut
);
NeedAlarm
=
true
;
}
}
else
if
(
needAlarm
&&
MoveInfo
.
IsTimeOut
(
120
))
else
if
(
needAlarm
&&
MoveInfo
.
IsTimeOut
(
120
))
...
@@ -564,7 +578,12 @@ namespace OnlineStore.DeviceLibrary
...
@@ -564,7 +578,12 @@ namespace OnlineStore.DeviceLibrary
{
{
WorkLog
(
"放料完成,耗时("
+
FormUtil
.
GetSpanStr
(
span
)
+
")"
);
WorkLog
(
"放料完成,耗时("
+
FormUtil
.
GetSpanStr
(
span
)
+
")"
);
TickLog
(
"出口料串,放料完成"
);
TickLog
(
"出口料串,放料完成"
);
MoveInfo
.
EndMove
();
if
(
RobotManager
.
robot
.
SafeStop
)
{
RobotManager
.
robot
.
SafeStop
=
false
;
MoveInfo
.
NextMoveStep
(
StepEnum
.
SafeStop
);
}
else
MoveInfo
.
EndMove
();
}
}
else
else
{
{
...
@@ -573,7 +592,13 @@ namespace OnlineStore.DeviceLibrary
...
@@ -573,7 +592,13 @@ namespace OnlineStore.DeviceLibrary
{
{
WorkLog
(
"放料完成,耗时("
+
FormUtil
.
GetSpanStr
(
span
)
+
")"
);
WorkLog
(
"放料完成,耗时("
+
FormUtil
.
GetSpanStr
(
span
)
+
")"
);
TickLog
(
"出口料串,放料完成"
);
TickLog
(
"出口料串,放料完成"
);
MoveInfo
.
EndMove
();
if
(
RobotManager
.
robot
.
SafeStop
)
{
RobotManager
.
robot
.
SafeStop
=
false
;
MoveInfo
.
NextMoveStep
(
StepEnum
.
SafeStop
);
}
else
MoveInfo
.
EndMove
();
}
}
}
}
...
@@ -709,7 +734,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -709,7 +734,7 @@ namespace OnlineStore.DeviceLibrary
WarnMsg
=
""
;
WarnMsg
=
""
;
ClearTimeoutAlarm
(
"打印标签状态完成"
);
ClearTimeoutAlarm
(
"打印标签状态完成"
);
ClearTimeoutAlarm
(
"打印标签任务完成"
);
ClearTimeoutAlarm
(
"打印标签任务完成"
);
Thread
.
Sleep
(
500
);
SecMoveInfo
.
NextMoveStep
(
StepEnum
.
OL05_TakeBack
);
SecMoveInfo
.
NextMoveStep
(
StepEnum
.
OL05_TakeBack
);
SecWorkLog
(
"贴标: 打印结束["
+
RobotManager
.
LastPrintStatus
+
"]["
+
(
isTimeOut
?
"超时90秒"
:
""
)
+
"], "
);
SecWorkLog
(
"贴标: 打印结束["
+
RobotManager
.
LastPrintStatus
+
"]["
+
(
isTimeOut
?
"超时90秒"
:
""
)
+
"], "
);
RobotManager
.
LastPrintStatus
=
Asa
.
PrintLabel
.
PrinterStatus
.
Idle
;
RobotManager
.
LastPrintStatus
=
Asa
.
PrintLabel
.
PrinterStatus
.
Idle
;
...
@@ -760,10 +785,17 @@ namespace OnlineStore.DeviceLibrary
...
@@ -760,10 +785,17 @@ namespace OnlineStore.DeviceLibrary
}
}
else
if
(
SecMoveInfo
.
IsStep
(
StepEnum
.
OL06_ZToP2
))
else
if
(
SecMoveInfo
.
IsStep
(
StepEnum
.
OL06_ZToP2
))
{
{
if
(
IOValue
(
IO_Type
.
Nozzle_Work
).
Equals
(
IO_VALUE
.
LOW
))
SecMoveInfo
.
NextMoveStep
(
StepEnum
.
OL07_Nozzle_Work
);
{
SecWorkLog
(
"贴标: 标签吸盘取码,等待吸盘信号到位 1.5s"
);
SecMoveInfo
.
NextMoveStep
(
StepEnum
.
OL07_Nozzle_Work
);
SecWorkLog
(
"贴标: 标签吸盘取码,等待吸盘信号到位 1.5s"
);
}
else
if
(
SecMoveInfo
.
IsTimeOut
(
5
))
{
WarnMsg
=
SecMoveInfo
.
Name
+
"["
+
SecMoveInfo
.
MoveStep
+
"]"
+
"吸标失败,请处理 超时["
+
FormUtil
.
GetSpanStr
(
SecMoveInfo
.
StepSpan
())
+
"]"
;
LogUtil
.
error
(
WarnMsg
,
SecMoveInfo
.
ErrorLogType
,
SecMoveInfo
.
logSeconds
());
Alarm
(
AlarmType
.
IoSingleTimeOut
);
NeedAlarm
=
true
;
}
//SecMoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.Nozzle_Work, IO_VALUE.HIGH));
//SecMoveInfo.WaitList.Add(WaitResultInfo.WaitIO(IO_Type.Nozzle_Work, IO_VALUE.HIGH));
//SecMoveInfo.WaitList.Add(WaitResultInfo.WaitTime(100));
//SecMoveInfo.WaitList.Add(WaitResultInfo.WaitTime(100));
//SecMoveInfo.OneWaitCanEndStep = true;
//SecMoveInfo.OneWaitCanEndStep = true;
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/bean/OutputEquip_Shelf.cs
查看文件 @
8a6f686
...
@@ -301,7 +301,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -301,7 +301,7 @@ namespace OnlineStore.DeviceLibrary
ShelfWorkLog
(
"批量提升运动过度"
);
ShelfWorkLog
(
"批量提升运动过度"
);
return
;
return
;
}
}
if
(
RobotManager
.
UseLabel
&&
MoveInfo
.
MoveParam
.
PlateW
<
13
)
if
(
RobotManager
.
UseLabel
)
{
{
ShelfMoveInfo
.
NextMoveStep
(
StepEnum
.
OS_25_WaitLabel
);
ShelfMoveInfo
.
NextMoveStep
(
StepEnum
.
OS_25_WaitLabel
);
ShelfMoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
2000
));
ShelfMoveInfo
.
WaitList
.
Add
(
WaitResultInfo
.
WaitTime
(
2000
));
...
@@ -668,6 +668,12 @@ namespace OnlineStore.DeviceLibrary
...
@@ -668,6 +668,12 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
error
(
Name
+
"未检测到入空料串线体光栅信号,暂停运行"
);
LogUtil
.
error
(
Name
+
"未检测到入空料串线体光栅信号,暂停运行"
);
SetWarnMsg
(
"未检测到入空料串线体光栅信号,暂停运行"
);
SetWarnMsg
(
"未检测到入空料串线体光栅信号,暂停运行"
);
this
.
MoveStop
=
true
;
this
.
MoveStop
=
true
;
NeedAlarm
=
true
;
if
(
FrmDevicePause
.
ShowPauseWindows
())
{
this
.
MoveStop
=
false
;
}
NeedAlarm
=
false
;
}
}
}
}
...
@@ -685,6 +691,12 @@ namespace OnlineStore.DeviceLibrary
...
@@ -685,6 +691,12 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
error
(
Name
+
"未检测到出料串线体光栅信号,暂停运行"
);
LogUtil
.
error
(
Name
+
"未检测到出料串线体光栅信号,暂停运行"
);
SetWarnMsg
(
"未检测到出料串线体光栅信号,暂停运行"
);
SetWarnMsg
(
"未检测到出料串线体光栅信号,暂停运行"
);
this
.
MoveStop
=
true
;
this
.
MoveStop
=
true
;
NeedAlarm
=
true
;
if
(
FrmDevicePause
.
ShowPauseWindows
())
{
this
.
MoveStop
=
false
;
}
NeedAlarm
=
false
;
}
}
}
}
}
}
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/bean/RobotBean.cs
查看文件 @
8a6f686
...
@@ -32,6 +32,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -32,6 +32,7 @@ namespace OnlineStore.DeviceLibrary
private
bool
canStart
=
false
;
private
bool
canStart
=
false
;
public
SQLite
sQLite
=
null
;
public
SQLite
sQLite
=
null
;
public
bool
LoadSuccess
=
false
;
public
bool
LoadSuccess
=
false
;
public
bool
SafeStop
=
false
;
public
RobotBean
(
Robot_Config
lineConfig
,
InputEquip_Config
fconfig
,
XRay_Config
xconfig
,
OutputEquip_Config
pconfig
)
public
RobotBean
(
Robot_Config
lineConfig
,
InputEquip_Config
fconfig
,
XRay_Config
xconfig
,
OutputEquip_Config
pconfig
)
{
{
equipsMap
=
new
Dictionary
<
int
,
EquipBase
>();
equipsMap
=
new
Dictionary
<
int
,
EquipBase
>();
...
@@ -51,6 +52,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -51,6 +52,7 @@ namespace OnlineStore.DeviceLibrary
ledProcessTimer
.
Elapsed
+=
LedProcessTimer_Elapsed
;
ledProcessTimer
.
Elapsed
+=
LedProcessTimer_Elapsed
;
List
<
string
>
ioList
=
new
List
<
string
>();
List
<
string
>
ioList
=
new
List
<
string
>();
ioList
=
new
List
<
string
>(
DeviceConfig
.
ProIOIpMap
.
Values
);
ioList
=
new
List
<
string
>(
DeviceConfig
.
ProIOIpMap
.
Values
);
...
@@ -248,6 +250,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -248,6 +250,8 @@ namespace OnlineStore.DeviceLibrary
}
}
else
else
{
{
SafeStop
=
false
;
mainTimer
.
Enabled
=
false
;
mainTimer
.
Enabled
=
false
;
//lineStatus = LineStatus.ResetMove;
//lineStatus = LineStatus.ResetMove;
runStatus
=
RobotRunStatus
.
HomeMoving
;
runStatus
=
RobotRunStatus
.
HomeMoving
;
...
@@ -300,7 +304,9 @@ namespace OnlineStore.DeviceLibrary
...
@@ -300,7 +304,9 @@ namespace OnlineStore.DeviceLibrary
public
override
bool
Reset
()
public
override
bool
Reset
()
{
{
SafeStop
=
false
;
bool
isNeedAllReset
=
false
;
bool
isNeedAllReset
=
false
;
if
(
isInSuddenDown
||
isNoAirCheck
)
if
(
isInSuddenDown
||
isNoAirCheck
)
{
{
...
@@ -353,6 +359,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -353,6 +359,8 @@ namespace OnlineStore.DeviceLibrary
{
{
if
(
isNeedAllReset
||
(!
equip
.
NoAlarm
()))
if
(
isNeedAllReset
||
(!
equip
.
NoAlarm
()))
{
{
SafeStop
=
false
;
LogUtil
.
info
(
Name
+
"收到复位信号,"
+
equip
.
Name
+
" 需要复位"
);
LogUtil
.
info
(
Name
+
"收到复位信号,"
+
equip
.
Name
+
" 需要复位"
);
equip
.
Reset
();
equip
.
Reset
();
Thread
.
Sleep
(
60
);
Thread
.
Sleep
(
60
);
...
@@ -373,6 +381,8 @@ namespace OnlineStore.DeviceLibrary
...
@@ -373,6 +381,8 @@ namespace OnlineStore.DeviceLibrary
}
}
if
(!
MoveInfo
.
IsInWait
)
if
(!
MoveInfo
.
IsInWait
)
{
{
SafeStop
=
false
;
bool
isOk
=
true
;
bool
isOk
=
true
;
string
msg
=
""
;
string
msg
=
""
;
//判断是否所有的已经返回完成
//判断是否所有的已经返回完成
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/bean/X_RAY_Equip.cs
查看文件 @
8a6f686
...
@@ -174,7 +174,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -174,7 +174,7 @@ namespace OnlineStore.DeviceLibrary
LogUtil
.
info
(
Name
+
"carerayImage.Open()="
+
cResult
);
LogUtil
.
info
(
Name
+
"carerayImage.Open()="
+
cResult
);
carerayImageError
=
!
cResult
;
carerayImageError
=
!
cResult
;
if
(
carerayImageError
)
if
(
carerayImageError
)
XPlate
UP
();
XPlate
ReStart
();
this
.
MoveStop
=
false
;
this
.
MoveStop
=
false
;
ISXPlateReady
=
true
;
ISXPlateReady
=
true
;
...
@@ -185,7 +185,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -185,7 +185,7 @@ namespace OnlineStore.DeviceLibrary
{
{
ISXPlateReady
=
false
;
ISXPlateReady
=
false
;
IOMove
(
IO_Type
.
X_Xplate_Power
,
IO_VALUE
.
LOW
);
IOMove
(
IO_Type
.
X_Xplate_Power
,
IO_VALUE
.
LOW
);
Thread
.
Sleep
(
1000
*
3
);
Thread
.
Sleep
(
1000
*
10
);
XPlateUP
();
XPlateUP
();
}
}
public
void
XRayDispose
()
public
void
XRayDispose
()
...
...
RC1266-AutoCountMachine/source/DeviceLibrary/model/MoveStep.cs
查看文件 @
8a6f686
...
@@ -928,7 +928,7 @@ namespace OnlineStore.DeviceLibrary
...
@@ -928,7 +928,7 @@ namespace OnlineStore.DeviceLibrary
#
endregion
#
endregion
SafeStop
}
}
public
enum
AlarmType
public
enum
AlarmType
...
...
RC1266-AutoCountMachine/source/LoadCVSLibrary/storeConfig/config/AIO_Type.cs
查看文件 @
8a6f686
...
@@ -284,6 +284,10 @@ namespace OnlineStore.LoadCSVLibrary
...
@@ -284,6 +284,10 @@ namespace OnlineStore.LoadCSVLibrary
/// DI,3,贴标机打码OK信号,PasteCode_OK,12,PRO_AOI_IP_4,X63,,,,,,,,,,
/// DI,3,贴标机打码OK信号,PasteCode_OK,12,PRO_AOI_IP_4,X63,,,,,,,,,,
/// </summary>
/// </summary>
public
static
string
PasteCode_OK
=
"PasteCode_OK"
;
public
static
string
PasteCode_OK
=
"PasteCode_OK"
;
/// <summary>
/// DI,3,贴标机打码OK信号,PasteCode_OK,12,PRO_AOI_IP_4,X63,,,,,,,,,,
/// </summary>
public
static
string
PrinterOnPosition
=
"PrinterOnPosition"
;
/// <summary>
/// <summary>
/// DI,3,吸嘴压力确认信号,Nozzle_Work,13,PRO_AOI_IP_4,X64,,,,,,,,,,
/// DI,3,吸嘴压力确认信号,Nozzle_Work,13,PRO_AOI_IP_4,X64,,,,,,,,,,
/// </summary>
/// </summary>
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论