Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
RC1250-AssemblyLine
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit eebd5458
由
LN
编写于
2020-01-06 14:27:50 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
异常打印修改
1 个父辈
c9531543
隐藏空白字符变更
内嵌
并排
正在显示
32 个修改的文件
包含
124 行增加
和
103 行删除
source/AssemblyLineClient/FrmBase.cs
source/AssemblyLineClient/FrmDischargeLine.cs
source/AssemblyLineClient/FrmEquipBase.cs
source/AssemblyLineClient/FrmFeedingEquip.cs
source/AssemblyLineClient/FrmIOStatus.cs
source/AssemblyLineClient/FrmLineStore.cs
source/AssemblyLineClient/FrmMoveEquip.cs
source/AssemblyLineClient/FrmProvidingEquip.cs
source/Common/util/ConfigAppSettings.cs
source/Common/util/LogUtil.cs
source/DeviceLibrary/agvClient/AgvClient.cs
source/DeviceLibrary/assemblyLine/DischargeLine.cs
source/DeviceLibrary/assemblyLine/DischargeLine_Partial.cs
source/DeviceLibrary/assemblyLine/EquipBase.cs
source/DeviceLibrary/assemblyLine/FeedingEquip.cs
source/DeviceLibrary/assemblyLine/FeedingEquip_InStore.cs
source/DeviceLibrary/assemblyLine/LineBean.cs
source/DeviceLibrary/assemblyLine/LineBean_Partial.cs
source/DeviceLibrary/assemblyLine/MoveEquip_Partial.cs
source/DeviceLibrary/assemblyLine/ProvidingEquip_Partial.cs
source/DeviceLibrary/assemblymanager/ALineManager.cs
source/DeviceLibrary/assemblymanager/RFIDManagercs.cs
source/DeviceLibrary/assemblymanager/SServerManager.cs
source/DeviceLibrary/baan/WaitUtil.cs
source/DeviceLibrary/deviceLibrary/IO/AIOBOX/AIOBOXManager.cs
source/DeviceLibrary/deviceLibrary/IO/KangNaiDe/KNDManager.cs
source/DeviceLibrary/deviceLibrary/IO/KangNaiDe/MasterTcpClient.cs
source/DeviceLibrary/deviceLibrary/PanasonicServo/ACServerManager.cs
source/DeviceLibrary/deviceLibrary/halcon/CodeManager.cs
source/DeviceLibrary/model/KTK_Store.cs
source/DeviceLibrary/model/StoreStep.cs
source/DeviceLibrary/server/LineServer.cs
source/AssemblyLineClient/FrmBase.cs
查看文件 @
eebd545
...
...
@@ -36,7 +36,7 @@ namespace OnlineStore.AssemblyLine
catch
(
Exception
ex
)
{
str
=
version
;
LogUtil
.
error
(
"解析版本号【"
+
str
+
"】出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"解析版本号【"
+
str
+
"】出错:"
,
ex
);
}
if
(
IsShow
)
{
...
...
source/AssemblyLineClient/FrmDischargeLine.cs
查看文件 @
eebd545
...
...
@@ -132,7 +132,7 @@ namespace OnlineStore.AssemblyLine
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
equipBean
.
Name
+
"界面定时器出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
equipBean
.
Name
+
"界面定时器出错:"
,
ex
);
}
}
...
...
@@ -150,7 +150,7 @@ namespace OnlineStore.AssemblyLine
catch
(
Exception
ex
)
{
MessageBox
.
Show
(
ex
.
StackTrace
,
"Exception(异常)"
,
MessageBoxButtons
.
OK
,
MessageBoxIcon
.
Error
);
LogUtil
.
error
(
LOGGER
,
ex
.
StackTrace
);
LogUtil
.
error
(
""
,
ex
);
}
}
private
void
btnOpenDo_Click
(
object
sender
,
EventArgs
e
)
...
...
source/AssemblyLineClient/FrmEquipBase.cs
查看文件 @
eebd545
...
...
@@ -118,7 +118,7 @@ namespace OnlineStore.AssemblyLine
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"出错:"
+
ex
.
StackTrace
);
LogUtil
.
error
(
"出错:"
,
ex
);
}
}
protected
void
Reset
()
...
...
source/AssemblyLineClient/FrmFeedingEquip.cs
查看文件 @
eebd545
...
...
@@ -148,7 +148,7 @@ namespace OnlineStore.AssemblyLine
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
equipBean
.
Name
+
"界面定时器出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
equipBean
.
Name
+
"界面定时器出错:"
,
ex
);
}
}
...
...
@@ -166,7 +166,7 @@ namespace OnlineStore.AssemblyLine
catch
(
Exception
ex
)
{
MessageBox
.
Show
(
ex
.
StackTrace
,
"Exception(异常)"
,
MessageBoxButtons
.
OK
,
MessageBoxIcon
.
Error
);
LogUtil
.
error
(
LOGGER
,
ex
.
StackTrace
);
LogUtil
.
error
(
""
,
ex
);
}
}
private
void
btnOpenDo_Click
(
object
sender
,
EventArgs
e
)
...
...
source/AssemblyLineClient/FrmIOStatus.cs
查看文件 @
eebd545
...
...
@@ -116,7 +116,7 @@ namespace OnlineStore.AssemblyLine
catch
(
Exception
ex
)
{
MessageBox
.
Show
(
ex
.
StackTrace
,
"Exception(异常)"
,
MessageBoxButtons
.
OK
,
MessageBoxIcon
.
Error
);
LogUtil
.
error
(
LOGGER
,
ex
.
StackTrace
);
LogUtil
.
error
(
""
,
ex
);
}
}
...
...
source/AssemblyLineClient/FrmLineStore.cs
查看文件 @
eebd545
...
...
@@ -282,7 +282,7 @@ namespace OnlineStore.AssemblyLine
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"退出出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"退出出错:"
,
ex
);
}
//this.Close();
}
...
...
@@ -307,7 +307,7 @@ namespace OnlineStore.AssemblyLine
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"显示界面出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"显示界面出错:"
,
ex
);
}
}
...
...
source/AssemblyLineClient/FrmMoveEquip.cs
查看文件 @
eebd545
...
...
@@ -160,7 +160,7 @@ namespace OnlineStore.AssemblyLine
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
equipBean
.
Name
+
"界面定时器出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
equipBean
.
Name
+
"界面定时器出错:"
,
ex
);
}
}
...
...
@@ -178,7 +178,7 @@ namespace OnlineStore.AssemblyLine
catch
(
Exception
ex
)
{
MessageBox
.
Show
(
ex
.
StackTrace
,
"Exception(异常)"
,
MessageBoxButtons
.
OK
,
MessageBoxIcon
.
Error
);
LogUtil
.
error
(
LOGGER
,
ex
.
StackTrace
);
LogUtil
.
error
(
""
,
ex
);
}
}
private
void
btnOpenDo_Click
(
object
sender
,
EventArgs
e
)
...
...
source/AssemblyLineClient/FrmProvidingEquip.cs
查看文件 @
eebd545
...
...
@@ -164,7 +164,7 @@ namespace OnlineStore.AssemblyLine
catch
(
Exception
ex
)
{
MessageBox
.
Show
(
ex
.
StackTrace
,
"Exception(异常)"
,
MessageBoxButtons
.
OK
,
MessageBoxIcon
.
Error
);
LogUtil
.
error
(
LOGGER
,
ex
.
StackTrace
);
LogUtil
.
error
(
""
,
ex
);
}
}
private
void
btnOpenDo_Click
(
object
sender
,
EventArgs
e
)
...
...
source/Common/util/ConfigAppSettings.cs
查看文件 @
eebd545
...
...
@@ -145,7 +145,7 @@ namespace OnlineStore.Common
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"SaveValue保存配置出错:AppKey="
+
key
+
",AppValue="
+
value
+
","
+
ex
.
StackTrace
);
LogUtil
.
error
(
LOGGER
,
"SaveValue保存配置出错:AppKey="
+
key
+
",AppValue="
+
value
+
","
,
ex
);
}
}
...
...
@@ -172,7 +172,7 @@ namespace OnlineStore.Common
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"UpdateConfig保存配置出错:name="
+
name
+
",Xvalue="
+
Xvalue
+
","
+
ex
.
StackTrace
);
LogUtil
.
error
(
LOGGER
,
"UpdateConfig保存配置出错:name="
+
name
+
",Xvalue="
+
Xvalue
+
","
,
ex
);
}
}
...
...
@@ -206,7 +206,7 @@ namespace OnlineStore.Common
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"SetValue保存配置出错:AppKey="
+
AppKey
+
",AppValue="
+
AppValue
+
","
+
ex
.
StackTrace
);
LogUtil
.
error
(
LOGGER
,
"SetValue保存配置出错:AppKey="
+
AppKey
+
",AppValue="
+
AppValue
+
","
,
ex
);
}
}
}
...
...
source/Common/util/LogUtil.cs
查看文件 @
eebd545
...
...
@@ -79,13 +79,20 @@ namespace OnlineStore.Common
error
(
LOGGER
,
errorMsg
);
}
}
public
static
void
error
(
ILog
log
,
string
errorMsg
)
public
static
void
error
(
ILog
log
,
string
errorMsg
,
Exception
ex
=
null
)
{
if
(
errorMsg
.
Trim
().
Equals
(
""
))
{
return
;
}
log
.
Error
(
errorMsg
);
if
(
ex
==
null
)
{
log
.
Error
(
errorMsg
);
}
else
{
log
.
Error
(
errorMsg
,
ex
);
}
AddToBox
(
errorMsg
,
Color
.
Red
);
}
private
static
void
AddToBox
(
string
msg
,
Color
color
)
...
...
@@ -96,7 +103,7 @@ namespace OnlineStore.Common
}
catch
(
Exception
ex
)
{
LOGGER
.
Error
(
"出错:"
+
ex
.
StackTrace
);
LOGGER
.
Error
(
"出错:"
,
ex
);
}
}
private
static
List
<
string
>
logList
=
new
List
<
string
>();
...
...
@@ -171,9 +178,9 @@ namespace OnlineStore.Common
{
debug
(
LOGGER
,
msg
);
}
public
static
void
error
(
string
errorMsg
)
public
static
void
error
(
string
errorMsg
,
Exception
ex
=
null
)
{
error
(
LOGGER
,
errorMsg
);
error
(
LOGGER
,
errorMsg
,
ex
);
}
public
static
void
info
(
string
msg
)
{
...
...
source/DeviceLibrary/agvClient/AgvClient.cs
查看文件 @
eebd545
...
...
@@ -38,7 +38,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"初始化agvClient "
+
ServerIp
+
" 出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"初始化agvClient "
+
ServerIp
+
" 出错:"
,
ex
);
}
}
internal
static
bool
ISConnected
()
...
...
@@ -156,7 +156,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"释放 agvClient "
+
ServerIp
+
" 出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"释放 agvClient "
+
ServerIp
+
" 出错:"
,
ex
);
}
}
}
...
...
source/DeviceLibrary/assemblyLine/DischargeLine.cs
查看文件 @
eebd545
...
...
@@ -65,8 +65,7 @@ namespace OnlineStore.DeviceLibrary
MoveInfo
.
EndMove
();
SecondMoveInfo
.
EndMove
();
lineStatus
=
LineStatus
.
StoreOnline
;
runStatus
=
LineRunStatus
.
HomeMoving
;
LogInfo
(
"开始原点返回: (重置灯状态,关闭所有皮带线,定位气缸下降 )开始"
);
runStatus
=
LineRunStatus
.
HomeMoving
;
MoveInfo
.
NewMove
(
LineMoveType
.
ReturnHome
);
StartReset
();
if
(
isDebug
)
...
...
@@ -81,8 +80,7 @@ namespace OnlineStore.DeviceLibrary
/// </summary>
public
override
bool
Reset
()
{
StopMove
();
LogInfo
(
"开始重置: (重置灯状态,关闭所有皮带线,定位气缸下降 开始;"
);
StopMove
();
runStatus
=
LineRunStatus
.
Reset
;
MoveInfo
.
NewMove
(
LineMoveType
.
Reset
);
StartReset
();
...
...
@@ -90,6 +88,8 @@ namespace OnlineStore.DeviceLibrary
}
private
void
StartReset
()
{
LogInfo
(
"StartReset: 重置灯状态,关闭所有皮带线,定位气缸下降 开始;"
);
//复位时默认为有托盘
TrayLine1
.
LastTrayPosition
=
1
;
TrayLine2
.
LastTrayPosition
=
1
;
...
...
@@ -108,17 +108,14 @@ namespace OnlineStore.DeviceLibrary
CheckAndMove
(
IO_Type
.
SeparateDevice_Run
,
IO_VALUE
.
LOW
);
if
(
DeviceID
.
Equals
(
302
))
{
LogInfo
(
"后退NG气缸"
);
CylinderMove
(
MoveInfo
,
IO_Type
.
NGCylinder_Before
,
IO_Type
.
NGCylinder_After
);
}
if
(
IsDebug
)
{
mainTimer
.
Start
();
}
//三个流水线都转动到定位亮
//TrayLine1.LineStartTurn();
//TrayLine2.LineStartTurn();
//Line3Turn.StartLineRun(IO_Type.DLine_Run3, IO_Type.Location_Check3, Line3EndProcess);
isInPro
=
false
;
}
...
...
@@ -255,10 +252,13 @@ namespace OnlineStore.DeviceLibrary
StartOutStoreMove
(
new
InOutParam
());
}
}
if
(
runStatus
>=
(
LineRunStatus
.
HomeMoving
)
&&
NoAlarm
())
if
(
(
runStatus
.
Equals
(
LineRunStatus
.
Runing
)||
runStatus
.
Equals
(
LineRunStatus
.
Busy
))
&&
NoAlarm
())
{
TrayLine1
.
TimerPro
();
TrayLine2
.
TimerPro
();
if
(
NgISBack
())
{
TrayLine2
.
TimerPro
();
}
Line3TimerPro
();
}
IOTimeOutProcess
();
...
...
@@ -273,6 +273,21 @@ namespace OnlineStore.DeviceLibrary
IOMove
(
IO_Type
.
DLine_RunAlarm
,
IO_VALUE
.
HIGH
);
}
}
internal
bool
NgISBack
()
{
if
(
DeviceID
.
Equals
(
302
))
{
if
(
IOValue
(
IO_Type
.
NGCylinder_After
).
Equals
(
IO_VALUE
.
HIGH
)
&&
IOValue
(
IO_Type
.
NGCylinder_Before
).
Equals
(
IO_VALUE
.
LOW
))
{
return
true
;
}
}
else
{
return
true
;
}
return
false
;
}
internal
bool
Line3TurnIsStop
()
{
if
(
Line3Turn
.
InTurn
.
Equals
(
false
))
...
...
source/DeviceLibrary/assemblyLine/DischargeLine_Partial.cs
查看文件 @
eebd545
...
...
@@ -97,7 +97,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"FI_13_ScanCode扫码出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"FI_13_ScanCode扫码出错:"
,
ex
);
}
}
else
...
...
source/DeviceLibrary/assemblyLine/EquipBase.cs
查看文件 @
eebd545
...
...
@@ -145,7 +145,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"TimerProcess出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
Name
+
"TimerProcess出错:"
,
ex
);
}
isInPro
=
false
;
...
...
@@ -175,7 +175,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"IOTimeOutProcess出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"IOTimeOutProcess出错:"
,
ex
);
}
}
protected
bool
CanStartRun
()
...
...
@@ -504,7 +504,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
moveInfo
.
Name
+
" ["
+
moveInfo
.
MoveStep
+
"] CheckWait 出错:"
+
ex
.
StackTrace
+
ex
.
Message
+
ex
.
ToString
()
);
LogUtil
.
error
(
moveInfo
.
Name
+
" ["
+
moveInfo
.
MoveStep
+
"] CheckWait 出错:"
,
ex
);
}
}
...
...
source/DeviceLibrary/assemblyLine/FeedingEquip.cs
查看文件 @
eebd545
...
...
@@ -560,7 +560,7 @@ namespace OnlineStore.DeviceLibrary
}
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"CheckTimer_Elapsed出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"CheckTimer_Elapsed出错:"
,
ex
);
}
finally
{
...
...
@@ -690,7 +690,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"出库料架送入AGV出错:"
+
ex
);
LogUtil
.
error
(
"出库料架送入AGV出错:"
,
ex
);
}
finally
{
...
...
@@ -720,7 +720,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"UpdateShelfId出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
Name
+
"UpdateShelfId出错:"
,
ex
);
}
return
true
;
}
...
...
@@ -775,7 +775,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"AGV料架进入缓冲工位 出错:"
+
ex
);
LogUtil
.
error
(
"AGV料架进入缓冲工位 出错:"
,
ex
);
}
finally
{
...
...
source/DeviceLibrary/assemblyLine/FeedingEquip_InStore.cs
查看文件 @
eebd545
...
...
@@ -603,7 +603,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"FI_13_ScanCode扫码出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"FI_13_ScanCode扫码出错:"
,
ex
);
}
}
}
...
...
@@ -1047,7 +1047,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"CurrTrayIsNeed出错:"
+
ex
.
StackTrace
);
LogUtil
.
error
(
Name
+
"CurrTrayIsNeed出错:"
,
ex
);
}
return
false
;
...
...
source/DeviceLibrary/assemblyLine/LineBean.cs
查看文件 @
eebd545
...
...
@@ -164,7 +164,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"加载调试设备出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
Name
+
"加载调试设备出错:"
,
ex
);
}
}
...
...
@@ -651,7 +651,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"灯处理定时器出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
Name
+
"灯处理定时器出错:"
,
ex
);
}
Thread
.
Sleep
(
5
);
}
...
...
@@ -705,7 +705,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"定时检测报警出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
Name
+
"定时检测报警出错:"
,
ex
);
}
Thread
.
Sleep
(
1
);
}
...
...
@@ -782,7 +782,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"主定时器出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
Name
+
"主定时器出错:"
,
ex
);
}
Thread
.
Sleep
(
1
);
}
...
...
@@ -820,8 +820,6 @@ namespace OnlineStore.DeviceLibrary
#
region
扫码枪代码
/// <summary>
///是否已经接收到过出库信息
///</summary>
...
...
@@ -955,7 +953,8 @@ namespace OnlineStore.DeviceLibrary
Alarm
(
LineAlarmType
.
IoSingleTimeOut
);
}
}
}
}
public
string
GetMoveStr
()
{
string
msg
=
""
;
...
...
source/DeviceLibrary/assemblyLine/LineBean_Partial.cs
查看文件 @
eebd545
...
...
@@ -63,7 +63,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"IOTimeOutProcess出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"IOTimeOutProcess出错:"
,
ex
);
}
}
private
DateTime
preRWTime
=
DateTime
.
Now
;
...
...
@@ -173,7 +173,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
checkWaitInfo
.
Name
+
" ["
+
checkWaitInfo
.
MoveStep
+
"] CheckWait 出错:"
+
ex
.
StackTrace
+
ex
.
Message
+
ex
.
ToString
()
);
LogUtil
.
error
(
checkWaitInfo
.
Name
+
" ["
+
checkWaitInfo
.
MoveStep
+
"] CheckWait 出错:"
,
ex
);
}
}
...
...
@@ -271,7 +271,7 @@ namespace OnlineStore.DeviceLibrary
}
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
"Equip_TrayPEndEvent出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
Name
+
"Equip_TrayPEndEvent出错:"
,
ex
);
}
}
...
...
@@ -451,7 +451,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"SideWayTimerProcess 出错:"
+
ex
.
StackTrace
);
LogUtil
.
error
(
"SideWayTimerProcess 出错:"
,
ex
);
}
sdIsInprocess
=
false
;
}
...
...
source/DeviceLibrary/assemblyLine/MoveEquip_Partial.cs
查看文件 @
eebd545
...
...
@@ -533,7 +533,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"判断托盘是否需要顶升出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"判断托盘是否需要顶升出错:"
,
ex
);
}
}
else
if
(
SecondMoveInfo
.
MoveStep
.
Equals
(
LineMoveStep
.
MIO_05_WaitTime
))
...
...
source/DeviceLibrary/assemblyLine/ProvidingEquip_Partial.cs
查看文件 @
eebd545
...
...
@@ -504,7 +504,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
Name
+
ex
.
ToString
()
);
LogUtil
.
error
(
Name
,
ex
);
}
return
null
;
}
...
...
source/DeviceLibrary/assemblymanager/ALineManager.cs
查看文件 @
eebd545
...
...
@@ -153,7 +153,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"出错:"
+
ex
);
LogUtil
.
error
(
"出错:"
,
ex
);
MessageBox
.
Show
(
ex
.
ToString
(),
"加载配置错误(请检查配置)"
);
Application
.
Exit
();
}
...
...
@@ -178,7 +178,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"出错:"
+
ex
);
LogUtil
.
error
(
"出错:"
,
ex
);
}
}
public
static
void
SaveFeedingEquipConfig
(
FeedingEquip_Config
config
)
...
...
@@ -200,7 +200,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"出错:"
+
ex
);
LogUtil
.
error
(
"出错:"
,
ex
);
}
}
public
static
void
SaveProvidingEquipConfig
(
ProvidingEquip_Config
config
)
...
...
@@ -221,7 +221,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"出错:"
+
ex
);
LogUtil
.
error
(
"出错:"
,
ex
);
}
}
...
...
@@ -244,7 +244,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"出错:"
+
ex
);
LogUtil
.
error
(
"出错:"
,
ex
);
}
}
...
...
source/DeviceLibrary/assemblymanager/RFIDManagercs.cs
查看文件 @
eebd545
...
...
@@ -116,7 +116,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
//LogUtil.error("ReadRFID["+ip+"]出错:"
+ ex.ToString()
);
//LogUtil.error("ReadRFID["+ip+"]出错:"
,ex
);
}
return
new
RFIDData
(-
1
,
-
1
);
}
...
...
@@ -143,7 +143,7 @@ namespace OnlineStore.DeviceLibrary
RFIDReader
.
CloseAll
();
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"关闭RFID出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"关闭RFID出错:"
,
ex
);
}
}
}
...
...
source/DeviceLibrary/assemblymanager/SServerManager.cs
查看文件 @
eebd545
...
...
@@ -139,7 +139,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
deviceName
+
" "
+
ex
.
ToString
()
);
LogUtil
.
error
(
deviceName
+
" "
,
ex
);
}
return
""
;
}
...
...
@@ -193,7 +193,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
deviceName
+
" "
+
ex
.
ToString
()
);
LogUtil
.
error
(
deviceName
+
" "
,
ex
);
}
return
""
;
}
...
...
@@ -234,7 +234,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
deviceName
+
" "
+
ex
.
ToString
()
);
LogUtil
.
error
(
deviceName
+
" "
,
ex
);
}
return
msg
;
}
...
...
@@ -271,7 +271,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
deviceName
+
" "
+
ex
.
ToString
()
);
LogUtil
.
error
(
deviceName
+
" "
,
ex
);
}
return
""
;
}
...
...
source/DeviceLibrary/baan/WaitUtil.cs
查看文件 @
eebd545
...
...
@@ -47,7 +47,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"同步等待出现异常:"
+
ex
.
Message
);
LogUtil
.
error
(
"同步等待出现异常:"
,
ex
);
}
Thread
.
Sleep
(
sleepTime
);
waitSpan
=
System
.
DateTime
.
Now
.
Subtract
(
startTime
);
...
...
source/DeviceLibrary/deviceLibrary/IO/AIOBOX/AIOBOXManager.cs
查看文件 @
eebd545
...
...
@@ -82,7 +82,7 @@ namespace OnlineStore.DeviceLibrary
}
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"AOI 判断是否需要重连 出错"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"AOI 判断是否需要重连 出错"
,
ex
);
}
try
{
...
...
@@ -100,7 +100,7 @@ namespace OnlineStore.DeviceLibrary
GC
.
Collect
();
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"AOI ConTimer_Elapsed 出错: "
+
ex
.
ToString
()
);
LogUtil
.
error
(
"AOI ConTimer_Elapsed 出错: "
,
ex
);
}
isProcess
=
false
;
}
...
...
@@ -121,7 +121,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"关闭Io模块【"
+
ioIp
+
"】出错:"
+
ex
);
LogUtil
.
error
(
"关闭Io模块【"
+
ioIp
+
"】出错:"
,
ex
);
}
AIOMap
.
Remove
(
ioIp
);
}
...
...
@@ -232,7 +232,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"AioBox_DI_Changed_Event出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"AioBox_DI_Changed_Event出错:"
,
ex
);
}
}
private
void
AioBox_DO_Changed_Event
(
AIOBOX
box
,
Box_Sta
[]
sta
)
...
...
@@ -244,7 +244,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"AioBox_DO_Changed_Event出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"AioBox_DO_Changed_Event出错:"
,
ex
);
}
}
...
...
@@ -364,7 +364,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"aio.Close出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"aio.Close出错:"
,
ex
);
}
}
AIOMap
.
Clear
();
...
...
@@ -399,7 +399,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LOGGER
.
Error
(
"AIO WriteSingleDO ["
+
ioIp
+
"] ["
+
StartAddress
+
"] 出错啦:"
+
ex
.
ToString
()
);
LOGGER
.
Error
(
"AIO WriteSingleDO ["
+
ioIp
+
"] ["
+
StartAddress
+
"] 出错啦:"
,
ex
);
}
}
public
override
void
WriteSingleDO
(
string
ioIp
,
byte
slaveId
,
ushort
StartAddress
,
IO_VALUE
onOff
,
int
mSeconds
)
...
...
@@ -423,7 +423,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"**********定时回写入 出错:"
+
ex
.
StackTrace
);
LogUtil
.
error
(
LOGGER
,
"**********定时回写入 出错:"
,
ex
);
}
};
mytimer
.
AutoReset
=
false
;
//设置是否自动重启,即自动执行多次;
...
...
@@ -496,7 +496,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"GetDOValue ["
+
ioIP
+
"] ["
+
StartAddress
+
"] 出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"GetDOValue ["
+
ioIP
+
"] ["
+
StartAddress
+
"] 出错:"
,
ex
);
}
return
value
;
}
...
...
@@ -528,7 +528,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"GetDIValue ["
+
ioIP
+
"] ["
+
StartAddress
+
"] 出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"GetDIValue ["
+
ioIP
+
"] ["
+
StartAddress
+
"] 出错:"
,
ex
);
}
return
value
;
}
...
...
@@ -548,7 +548,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
" GetIOValue ["
+
configIO
.
IO_IP
+
"] ["
+
configIO
.
GetIOAddr
()
+
"] 获取数据出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
" GetIOValue ["
+
configIO
.
IO_IP
+
"] ["
+
configIO
.
GetIOAddr
()
+
"] 获取数据出错:"
,
ex
);
}
return
value
;
}
...
...
source/DeviceLibrary/deviceLibrary/IO/KangNaiDe/KNDManager.cs
查看文件 @
eebd545
...
...
@@ -122,7 +122,7 @@ namespace OnlineStore.DeviceLibrary
// }
// catch (Exception ex)
// {
// LogUtil.error(LOGGER, "出错啦:"
+ ex.ToString()
);
// LogUtil.error(LOGGER, "出错啦:"
,ex
);
// }
// return false;
//}
...
...
@@ -151,7 +151,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"出错啦:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
"出错啦:"
,
ex
);
}
Thread
.
Sleep
(
1
);
}
...
...
@@ -286,7 +286,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"**********定时回写入 出错:"
+
ex
.
StackTrace
);
LogUtil
.
error
(
LOGGER
,
"**********定时回写入 出错:"
,
ex
);
}
};
mytimer
.
AutoReset
=
false
;
//设置是否自动重启,即自动执行多次;
...
...
@@ -327,7 +327,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"SaveDOValue出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
"SaveDOValue出错:"
,
ex
);
}
}
public
override
IO_VALUE
GetDOValue
(
string
ioIP
,
byte
slaveId
,
ushort
StartAddress
)
...
...
@@ -393,7 +393,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"获取数据出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
"获取数据出错:"
,
ex
);
}
return
value
;
}
...
...
@@ -444,7 +444,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"SaveDIData出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
"SaveDIData出错:"
,
ex
);
//LOGGER.Error("处理接受数据出错:", ex);
}
}
...
...
@@ -553,7 +553,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"处理接受数据出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
"处理接受数据出错:"
,
ex
);
//LOGGER.Error("处理接受数据出错:", ex);
}
}
...
...
@@ -580,7 +580,7 @@ namespace OnlineStore.DeviceLibrary
default
:
break
;
}
LOGGER
.
Error
(
"接收数据出错:"
+
exc
);
LOGGER
.
Error
(
"接收数据出错:"
+
exc
);
//MessageBox.Show(exc, "Modbus slave exception");
}
...
...
@@ -605,7 +605,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"出错啦:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
"出错啦:"
,
ex
);
}
return
false
;
}
...
...
source/DeviceLibrary/deviceLibrary/IO/KangNaiDe/MasterTcpClient.cs
查看文件 @
eebd545
...
...
@@ -171,7 +171,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LOGGER
.
Error
(
"IO模块["
+
IP
+
"]出错:"
+
ex
.
ToString
()
);
LOGGER
.
Error
(
"IO模块["
+
IP
+
"]出错:"
,
ex
);
}
}
...
...
@@ -231,7 +231,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
clientipe
.
ToString
()
+
"收到数据:"
+
str
+
"分包出错 ["
+
currStartIndex
+
"]:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
clientipe
.
ToString
()
+
"收到数据:"
+
str
+
"分包出错 ["
+
currStartIndex
+
"]:"
,
ex
);
}
}
...
...
@@ -335,7 +335,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"IO模块["
+
IP
+
"]dispose出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
"IO模块["
+
IP
+
"]dispose出错:"
,
ex
);
}
socketClient
.
Close
();
}
...
...
source/DeviceLibrary/deviceLibrary/PanasonicServo/ACServerManager.cs
查看文件 @
eebd545
...
...
@@ -39,7 +39,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"UpdateAddrValue出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"UpdateAddrValue出错:"
,
ex
);
}
return
value
;
}
...
...
@@ -70,7 +70,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"UpdateAddrValue出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"UpdateAddrValue出错:"
,
ex
);
}
}
...
...
@@ -354,7 +354,7 @@ namespace OnlineStore.DeviceLibrary
}
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"轴【"
+
portName
+
"_"
+
slvAddr
+
"】原点返回前验证是否在原点出错:"
+
ex
.
StackTrace
);
LogUtil
.
error
(
"轴【"
+
portName
+
"_"
+
slvAddr
+
"】原点返回前验证是否在原点出错:"
,
ex
);
}
//默认负方向原点返回
UpdateBlock
(
portName
,
slvAddr
,
ACCMDManager
.
Block_HomeMove1
);
...
...
source/DeviceLibrary/deviceLibrary/halcon/CodeManager.cs
查看文件 @
eebd545
...
...
@@ -44,7 +44,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"解析摄像机配置出错:"
+
ex
.
StackTrace
);
LogUtil
.
error
(
"解析摄像机配置出错:"
,
ex
);
}
}
private
static
void
LoadCamera
(
bool
isReLoad
)
...
...
@@ -57,7 +57,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"加载HIK相机出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"加载HIK相机出错:"
,
ex
);
}
try
{
...
...
@@ -65,7 +65,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"加载Basler相机出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"加载Basler相机出错:"
,
ex
);
}
}
string
[]
names
=
CodeLibrary
.
HIKCamera
.
Instance
.
CameraName
;
...
...
@@ -157,7 +157,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"从相机【"
+
cameraName
+
"】获取图片出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"从相机【"
+
cameraName
+
"】获取图片出错:"
,
ex
);
}
return
bitm
;
}
...
...
@@ -231,7 +231,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"扫码出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"扫码出错:"
,
ex
);
}
return
codeList
;
}
...
...
source/DeviceLibrary/model/KTK_Store.cs
查看文件 @
eebd545
...
...
@@ -131,7 +131,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"BusyMoveProcess出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"BusyMoveProcess出错:"
,
ex
);
}
isInPro
=
false
;
}
...
...
source/DeviceLibrary/model/StoreStep.cs
查看文件 @
eebd545
...
...
@@ -954,7 +954,7 @@ namespace OnlineStore.DeviceLibrary
#
region
出料流水线处理,
30000
开始
/// <summary>
/// 出料流水线复位,定位气缸下降
/// 出料流水线复位,定位气缸下降
,NG气缸后退
/// </summary>
DL_R_CylinderDown
=
30001
,
/// <summary>
...
...
source/DeviceLibrary/server/LineServer.cs
查看文件 @
eebd545
...
...
@@ -190,7 +190,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
LOGGER
,
"关闭 监听出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
LOGGER
,
"关闭 监听出错:"
,
ex
);
}
}
public
static
bool
UpdateBoxDebug
(
int
id
,
int
isDebug
)
...
...
@@ -338,7 +338,7 @@ namespace OnlineStore.DeviceLibrary
}
catch
(
Exception
ex
)
{
LogUtil
.
error
(
"处理料仓消息【"
+
msg
+
"】出错:"
+
ex
.
ToString
()
);
LogUtil
.
error
(
"处理料仓消息【"
+
msg
+
"】出错:"
,
ex
);
}
}
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论