Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
顾剑亮
/
AGVControl-Qisda-ProductionLine
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit 672bcc80
由
张东亮
编写于
2020-12-08 19:59:34 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
页面刷新问题
1 个父辈
00ced36a
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
23 个修改的文件
包含
117 行增加
和
96 行删除
.vs/AGVControl-ProductionLine/v16/.suo
AGVControl-ProductionLine/App.config
AGVControl-ProductionLine/BLL/Common.cs
AGVControl-ProductionLine/BLL/Control.cs
AGVControl-ProductionLine/BLL/LineWebService.cs
AGVControl-ProductionLine/BLL/UnlockMissionManager.cs
AGVControl-ProductionLine/FrmMain.Designer.cs
AGVControl-ProductionLine/FrmMain.cs
AGVControl-ProductionLine/bean/Agv_Info.cs
AGVControl-ProductionLine/bean/UnlockedShelf.cs
AGVControl-ProductionLine/bean/job/ChargeJob.cs
AGVControl-ProductionLine/bean/job/SendFullShelfToLineJob.cs
AGVControl-ProductionLine/bin/Debug/AGVControl-ProductionLine.exe
AGVControl-ProductionLine/bin/Debug/AGVControl-ProductionLine.exe.config
AGVControl-ProductionLine/bin/Debug/AGVControl-ProductionLine.pdb
AGVControl-ProductionLine/bin/Debug/Config/UnlockInfo.json
AGVControl-ProductionLine/bin/Debug/Config/tempData.ini
AGVControl-ProductionLine/bin/Debug/logs/AgvServer.log
AGVControl-ProductionLine/bin/Debug/logs/LineWebService.log → AGVControl-ProductionLine/bin/Debug/logs/UnlockInfo.log
AGVControl-ProductionLine/obj/Debug/AGVControl-ProductionLine.csproj.FileListAbsolute.txt
AGVControl-ProductionLine/obj/Debug/AGVControl-ProductionLine.csproj.GenerateResource.cache
AGVControl-ProductionLine/obj/Debug/AGVControl-ProductionLine.exe
AGVControl-ProductionLine/obj/Debug/AGVControl-ProductionLine.pdb
.vs/AGVControl-ProductionLine/v16/.suo
查看文件 @
672bcc8
此文件类型无法预览
AGVControl-ProductionLine/App.config
查看文件 @
672bcc8
...
...
@@ -18,13 +18,17 @@
</
layout
>
</
appender
>
<
appender
name
=
"LineWebService"
type
=
"log4net.Appender.RollingFileAppender"
>
<
file
value
=
"logs/
LineWebService
.log"
/>
<
file
value
=
"logs/
UnlockInfo
.log"
/>
<
param
name
=
"Encoding"
value
=
"UTF-8"
/>
<
appendToFile
value
=
"true"
/>
<
rollingStyle
value
=
"Date"
/>
<
datePattern
value
=
"yyyy-MM-dd"
/>
<
param
name
=
"MaxSizeRollBackups"
value
=
"10"
/>
<!-- 切割最多文件数 -->
<
param
name
=
"MaximumFileSize"
value
=
"100MB"
/>
<!-- 每个文件的大小 -->
<
param
name
=
"RollingStyle"
value
=
"Size"
/>
<
param
name
=
"StaticLogFileName"
value
=
"true"
/>
<
layout
type
=
"log4net.Layout.PatternLayout"
>
<
conversionPattern
value
=
"[%date]
[%t][%c:%L]
%-5p %m%n"
/>
<
conversionPattern
value
=
"[%date]%-5p %m%n"
/>
</
layout
>
</
appender
>
<
logger
name
=
"LineWebService"
>
...
...
AGVControl-ProductionLine/BLL/Common.cs
查看文件 @
672bcc8
...
...
@@ -629,14 +629,14 @@ namespace AGVControl
{
nodeName
=
FullShelfDestInfo
.
location
;
Common
.
GetLineNameByNodeName
(
nodeName
,
out
string
line
);
Common
.
LogInfo
(
"A6出满料架的产线有空料架,优先处理 "
+
FullShelfDestInfo
.
ShowInfo
(
line
));
Common
.
log
.
Debug
(
"A6出满料架的产线有空料架,优先处理 "
+
FullShelfDestInfo
.
ShowInfo
(
line
));
return
true
;
}
else
if
(
FullShelfDestInfo
.
location
.
StartsWith
(
SettingString
.
D4_Name_Prefix
)
&&
!
SettingString
.
C4_AGV_IPs
.
Contains
(
agv
.
IP
))
{
nodeName
=
FullShelfDestInfo
.
location
;
Common
.
GetLineNameByNodeName
(
nodeName
,
out
string
line
);
Common
.
LogInfo
(
"A6出满料架的产线有空料架,优先处理 "
+
FullShelfDestInfo
.
ShowInfo
(
line
));
Common
.
log
.
Debug
(
"A6出满料架的产线有空料架,优先处理 "
+
FullShelfDestInfo
.
ShowInfo
(
line
));
return
true
;
}
...
...
@@ -646,7 +646,7 @@ namespace AGVControl
{
if
(
FullShelfDestInfo
!=
null
)
{
Common
.
LogInfo
(
"A6的出料信息不正确,请检查:"
+
FullShelfDestInfo
.
ShowInfo
(
"ERROR"
));
Common
.
log
.
Error
(
"A6的出料信息不正确,请检查:"
+
FullShelfDestInfo
.
ShowInfo
(
"ERROR"
));
//return false;
}
}
...
...
@@ -667,13 +667,13 @@ namespace AGVControl
if
(
loc
.
StartsWith
(
SettingString
.
C4_Name_Prefix
)
&&
SettingString
.
C4_AGV_IPs
.
Contains
(
agv
.
IP
))
{
nodeName
=
loc
;
Common
.
LogInfo
(
"双层线正在出的工单目标产线有空料架,优先处4C-"
+
loc
);
//
Common.LogInfo("双层线正在出的工单目标产线有空料架,优先处4C-" + loc);
return
true
;
}
else
if
(
loc
.
StartsWith
(
SettingString
.
D4_Name_Prefix
)
&&
!
SettingString
.
C4_AGV_IPs
.
Contains
(
agv
.
IP
))
{
nodeName
=
loc
;
Common
.
LogInfo
(
"双层线正在出的工单目标产线有空料架,优先处理4D-"
+
loc
);
Common
.
log
.
Debug
(
"双层线正在出的工单目标产线有空料架,优先处理4D-"
+
loc
);
return
true
;
}
}
...
...
@@ -874,7 +874,8 @@ namespace AGVControl
{
// if (warnMsg.Equals(""))
{
warnMsg
=
string
.
Format
(
"料架[{0}]在接驳台[{1}]最外侧,但没有解绑信息,请检查"
,
clientNode
.
RFID
,
clientNode
.
Name
);
string
res
=
AGVManager
.
GetRFIDs
(
clientNode
.
Name
);
warnMsg
=
string
.
Format
(
"[{1}]最外侧是料架[{0}],但没有解绑信息,请检查接驳台:料架由里到外顺序:{2}"
,
clientNode
.
RFID
,
clientNode
.
Name
,
res
);
Common
.
LogInfo
(
warnMsg
);
}
return
false
;
...
...
AGVControl-ProductionLine/BLL/Control.cs
查看文件 @
672bcc8
...
...
@@ -77,11 +77,16 @@ namespace AGVControl.BLL
{
if
(
NodeStateInProcess
)
return
;
NodeStateInProcess
=
true
;
List
<
AlarmMsg
>
msglist
=
new
List
<
AlarmMsg
>();
try
{
String
tmp
=
""
;
for
(
int
j
=
0
;
j
<
Common
.
nodeInfo
.
Count
;
j
++)
{
if
(!
Common
.
nodeInfo
[
j
].
Online
)
{
msglist
.
Add
(
new
AlarmMsg
(
Common
.
nodeInfo
[
j
].
AliceName
,
"lineAgv."
+
Common
.
nodeInfo
[
j
].
Name
+
".OffLine"
,
"离线"
));
}
if
(
Common
.
nodeInfo
[
j
].
Name
.
StartsWith
(
SettingString
.
D4_Name_Prefix
)
||
Common
.
nodeInfo
[
j
].
Name
.
StartsWith
(
SettingString
.
C4_Name_Prefix
))
{
if
(!
Common
.
nodeInfo
[
j
].
Name
.
Equals
(
SettingString
.
C4FeederIn
)
&&
!
Common
.
nodeInfo
[
j
].
Name
.
Equals
(
SettingString
.
C4FeederOut
)
&&
...
...
@@ -111,6 +116,7 @@ namespace AGVControl.BLL
}
}
}
AGVManager
.
updateDeviceAlarmMsg
(
msglist
);
}
catch
(
Exception
ex
)
{
...
...
@@ -119,29 +125,19 @@ namespace AGVControl.BLL
NodeStateInProcess
=
false
;
}
private
bool
AgvStateInProcess
=
false
;
private
eAGVState
preAGVState
=
eAGVState
.
None
;
//
private eAGVState preAGVState = eAGVState.None;
private
void
AgvStateTimer_Elapsed
(
object
sender
,
System
.
Timers
.
ElapsedEventArgs
e
)
{
bool
rtn
;
if
(
AgvStateInProcess
)
return
;
AgvStateInProcess
=
true
;
List
<
AlarmMsg
>
msglist
=
new
List
<
AlarmMsg
>();
String
tmp
=
""
;
for
(
int
j
=
0
;
j
<
Common
.
nodeInfo
.
Count
;
j
++)
{
if
(!
Common
.
nodeInfo
[
j
].
Online
)
{
msglist
.
Add
(
new
AlarmMsg
(
Common
.
nodeInfo
[
j
].
AliceName
,
"lineAgv."
+
Common
.
nodeInfo
[
j
].
Name
+
".OffLine"
,
"离线"
));
}
}
AGVManager
.
updateDeviceAlarmMsg
(
msglist
);
for
(
int
i
=
0
;
i
<
Common
.
agvInfo
.
Count
;
i
++)
{
//上报异常
bool
isAlarm
=
false
;
if
(
msglist
.
Count
>
0
)
msglist
.
Clear
();
//
if (msglist.Count > 0)
//
msglist.Clear();
try
{
if
(!
CheckOnline
(
i
))
continue
;
...
...
@@ -153,18 +149,16 @@ namespace AGVControl.BLL
Thread
.
Sleep
(
50
);
if
(
rtn
)
change
=
Common
.
agvInfo
[
i
].
SetState
(
stateID
,
stateStr
,
battery
,
mission_text
,
position
);
//更新状态stateID.Equals(eAGVState.Executing)
if
(
change
)
// if (change)
{
AgvChanged
?.
Invoke
(
i
);
}
Common
.
log
.
Debug
(
"获取AGV状态"
);
Thread
.
Sleep
(
50
);
rtn
=
Common
.
mir
.
Get_IO_Status
(
Common
.
agvInfo
[
i
],
out
bool
[]
input
,
out
bool
[]
output
);
Common
.
log
.
Debug
(
"获取IO状态"
);
//
rtn = Common.mir.Get_IO_Status(Common.agvInfo[i], out bool[] input, out bool[] output);
//
Common.log.Debug("获取IO状态");
preAGVState
=
Common
.
agvInfo
[
i
].
StateID
;
//
preAGVState = Common.agvInfo[i].StateID;
if
(
Common
.
agvInfo
[
i
].
StandTimeOut
)
{
...
...
AGVControl-ProductionLine/BLL/LineWebService.cs
查看文件 @
672bcc8
...
...
@@ -120,7 +120,7 @@ namespace BLL
else
{
res
=
new
Result
()
{
Succeed
=
true
,
ResultData
=
RFID
,
ErrorMessage
=
""
};
Log
.
Info
(
string
.
Format
(
"Unlock Request(GET) [emptyStation={0},rfid={1}]"
,
line
,
RFID
));
Log
.
Info
(
string
.
Format
(
"Unlock Request(GET) [emptyStation={0},rfid={1}]"
,
line
,
RFID
.
ToUpper
()
));
Common
.
LogInfo
(
"任务[GET]:"
+
value
+
" 出空料架 [emptyStation="
+
line
+
",rfid="
+
RFID
.
ToUpper
()
+
"]"
);
}
}
...
...
AGVControl-ProductionLine/BLL/UnlockMissionManager.cs
查看文件 @
672bcc8
...
...
@@ -27,7 +27,7 @@ namespace AGVControl
{
if
(
item
.
Name
.
StartsWith
(
"A"
)
||
item
.
Name
.
Equals
(
SettingString
.
D4FeederIn
)
||
item
.
Name
.
Equals
(
SettingString
.
C4FeederIn
))
continue
;
NodeUnlockMissions
.
Add
(
item
.
Name
,
new
UnlockedShelf
(
item
.
Name
));
NodeUnlockMissions
.
Add
(
item
.
Name
,
new
UnlockedShelf
());
UnlockMissions
=
new
Dictionary
<
string
,
UnlockInfo
>();
}
}
...
...
@@ -75,8 +75,12 @@ namespace AGVControl
{
UnlockMissions
[
nodeName
]
=
new
UnlockInfo
(
nodeName
,
NodeUnlockMissions
[
nodeName
].
EmptyCnt
,
NodeUnlockMissions
[
nodeName
].
GetRfidWithTime
());
WriteUnlockLineInfo
();
Common
.
WriteIni
(
nodeName
,
SettingString
.
EmptyShelfCnt
,
NodeUnlockMissions
[
nodeName
].
EmptyCnt
.
ToString
());
Common
.
LogInfo
(
string
.
Format
(
"{0}解绑任务添加成功:RFID={1}"
,
nodeName
,
rfid
));
MissionChanged
?.
Invoke
(
UnlockMissions
);
}
else
Common
.
LogInfo
(
string
.
Format
(
"{0}解绑任务添加失败:RFID={1}"
,
nodeName
,
rfid
));
return
rtn
;
}
public
bool
DelMission
(
string
nodeName
,
string
rfid
)
...
...
@@ -86,8 +90,12 @@ namespace AGVControl
{
UnlockMissions
[
nodeName
]
=
new
UnlockInfo
(
nodeName
,
NodeUnlockMissions
[
nodeName
].
EmptyCnt
,
NodeUnlockMissions
[
nodeName
].
GetRfidWithTime
());
WriteUnlockLineInfo
();
Common
.
WriteIni
(
nodeName
,
SettingString
.
EmptyShelfCnt
,
NodeUnlockMissions
[
nodeName
].
EmptyCnt
.
ToString
());
Common
.
LogInfo
(
string
.
Format
(
"{0}解绑任务删除成功:RFID={1}"
,
nodeName
,
rfid
));
MissionChanged
?.
Invoke
(
UnlockMissions
);
}
else
Common
.
LogInfo
(
string
.
Format
(
"{0}解绑任务删除失败:RFID={1}"
,
nodeName
,
rfid
));
return
rtn
;
}
/// <summary>
...
...
AGVControl-ProductionLine/FrmMain.Designer.cs
查看文件 @
672bcc8
...
...
@@ -167,6 +167,7 @@
this
.
DgvAgv
.
Size
=
new
System
.
Drawing
.
Size
(
1105
,
141
);
this
.
DgvAgv
.
TabIndex
=
3
;
this
.
DgvAgv
.
CellClick
+=
new
System
.
Windows
.
Forms
.
DataGridViewCellEventHandler
(
this
.
DgvAgv_CellClick
);
this
.
DgvAgv
.
CellContentClick
+=
new
System
.
Windows
.
Forms
.
DataGridViewCellEventHandler
(
this
.
DgvAgv_CellContentClick
);
//
// Column1
//
...
...
@@ -713,7 +714,7 @@
//
// btnClearStationRFID
//
this
.
btnClearStationRFID
.
Location
=
new
System
.
Drawing
.
Point
(
1
61
,
67
);
this
.
btnClearStationRFID
.
Location
=
new
System
.
Drawing
.
Point
(
1
51
,
91
);
this
.
btnClearStationRFID
.
Margin
=
new
System
.
Windows
.
Forms
.
Padding
(
2
);
this
.
btnClearStationRFID
.
Name
=
"btnClearStationRFID"
;
this
.
btnClearStationRFID
.
Size
=
new
System
.
Drawing
.
Size
(
125
,
35
);
...
...
@@ -740,10 +741,10 @@
//
// btnUpdateStatus
//
this
.
btnUpdateStatus
.
Location
=
new
System
.
Drawing
.
Point
(
8
,
102
);
this
.
btnUpdateStatus
.
Location
=
new
System
.
Drawing
.
Point
(
151
,
23
);
this
.
btnUpdateStatus
.
Margin
=
new
System
.
Windows
.
Forms
.
Padding
(
2
);
this
.
btnUpdateStatus
.
Name
=
"btnUpdateStatus"
;
this
.
btnUpdateStatus
.
Size
=
new
System
.
Drawing
.
Size
(
125
,
3
9
);
this
.
btnUpdateStatus
.
Size
=
new
System
.
Drawing
.
Size
(
125
,
3
5
);
this
.
btnUpdateStatus
.
TabIndex
=
41
;
this
.
btnUpdateStatus
.
Text
=
"物料状态上报"
;
this
.
btnUpdateStatus
.
UseVisualStyleBackColor
=
true
;
...
...
@@ -751,7 +752,7 @@
//
// btnGetStationRfid
//
this
.
btnGetStationRfid
.
Location
=
new
System
.
Drawing
.
Point
(
161
,
23
);
this
.
btnGetStationRfid
.
Location
=
new
System
.
Drawing
.
Point
(
8
,
91
);
this
.
btnGetStationRfid
.
Margin
=
new
System
.
Windows
.
Forms
.
Padding
(
2
);
this
.
btnGetStationRfid
.
Name
=
"btnGetStationRfid"
;
this
.
btnGetStationRfid
.
Size
=
new
System
.
Drawing
.
Size
(
125
,
35
);
...
...
AGVControl-ProductionLine/FrmMain.cs
查看文件 @
672bcc8
...
...
@@ -403,14 +403,13 @@ namespace AGVControl
try
{
agvRunInfo
[
i
].
Text
=
Common
.
agvInfo
[
i
].
RunInfo
();
Application
.
DoEvents
();
}
catch
(
Exception
ex
)
{
Common
.
log
.
Error
(
"显示"
+
Common
.
agvInfo
[
i
].
Name
+
"运行信息异常"
);
}
}
Application
.
DoEvents
();
//if (!Common.doubleLine_WO.Equals(""))
lblWO
.
Text
=
Common
.
doubleLine_WO
;
// if (!AGVManager.A6_Target.Equals(""))
...
...
@@ -668,19 +667,52 @@ namespace AGVControl
{
if
(
txtBoxLineName
.
Text
.
Equals
(
""
))
return
;
string
res
=
AGVManager
.
GetRFIDs
(
txtBoxLineName
.
Text
.
ToUpper
());
this
.
Invoke
(
new
Action
(()
=>
{
label11
.
Text
=
string
.
Format
(
"由里到外料架顺序:{0}"
,
res
);
}));
try
{
Task
.
Factory
.
StartNew
(
new
Action
(()
=>
{
string
res
=
AGVManager
.
GetRFIDs
(
txtBoxLineName
.
Text
.
ToUpper
());
this
.
Invoke
(
new
Action
(()
=>
{
label11
.
Text
=
string
.
Format
(
"由里到外料架顺序:{0}"
,
res
);
}));
}));
}
catch
{
}
}
private
void
btnClearStationRFID_Click
(
object
sender
,
EventArgs
e
)
{
if
(!
txtBoxLineName
.
Text
.
Equals
(
""
)
&&
!
txtBoxRFID
.
Text
.
Equals
(
""
))
{
bool
rtn
=
AGVManager
.
ClearRFID
(
txtBoxLineName
.
Text
.
ToUpper
(),
txtBoxRFID
.
Text
.
ToUpper
());
this
.
Invoke
(
new
Action
(()
=>
{
label11
.
Text
=
rtn
?
"清除接驳RFID成功:"
+
txtBoxLineName
.
Text
+
" "
+
txtBoxRFID
.
Text
:
"清除接驳RFID失败:"
+
txtBoxLineName
.
Text
+
" "
+
txtBoxRFID
.
Text
;
}));
txtBoxLineName
.
Text
=
""
;
txtBoxRFID
.
Text
=
""
;
try
{
Task
.
Factory
.
StartNew
(
new
Action
(()
=>
{
bool
rtn
=
AGVManager
.
ClearRFID
(
txtBoxLineName
.
Text
.
ToUpper
(),
txtBoxRFID
.
Text
.
ToUpper
());
this
.
Invoke
(
new
Action
(()
=>
{
label11
.
Text
=
rtn
?
"清除接驳RFID成功:"
+
txtBoxLineName
.
Text
+
" "
+
txtBoxRFID
.
Text
:
"清除接驳RFID失败:"
+
txtBoxLineName
.
Text
+
" "
+
txtBoxRFID
.
Text
;
}));
txtBoxLineName
.
Text
=
""
;
txtBoxRFID
.
Text
=
""
;
Common
.
LogInfo
(
rtn
?
"手动清除接驳RFID成功:"
+
txtBoxLineName
.
Text
+
" "
+
txtBoxRFID
.
Text
:
"手动清除接驳RFID失败:"
+
txtBoxLineName
.
Text
+
" "
+
txtBoxRFID
.
Text
);
}));
}
catch
{
}
}
}
/// <summary>
/// 点击小车状态刷新
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private
void
DgvAgv_CellContentClick
(
object
sender
,
DataGridViewCellEventArgs
e
)
{
Invoke
(
new
Action
(()
=>
{
try
{
for
(
int
i
=
0
;
i
<
Common
.
agvInfo
.
Count
;
i
++)
{
DgvAgv
.
Rows
[
i
].
SetValues
(
Common
.
agvInfo
[
i
].
ToRow
());
}
}
catch
{
}
}));
}
}
}
AGVControl-ProductionLine/bean/Agv_Info.cs
查看文件 @
672bcc8
...
...
@@ -195,27 +195,10 @@ namespace AGVControl
else
return
string
.
Format
(
"设备:{1}{0}RFID:{2}{0}任务信息:[任务名称={3}][任务状态={4}]{0}当前步骤:{5}{0}执行信息:{6}"
,
"\r\n"
,
Name
,
RFID
,
curJobTaskName
,
curJobTaskState
,
Msg
,
MissionText
);
//if (RFID.StartsWith("C"))
//{
// return string.Format("Name:{1}{0}RFID:{2}{0}CurJob:{3}{0}CurJobTaskInfo:[TaskName={4}][TaskID={5}][TaskState={6}]{0}RunInfo:{7}{0}BoxDestInfo:{8}{0}GetRack:{9}{0}MissionText:{10}",
// "\r\n", Name, RFID, CurJob.ToString(), curJobTaskName, curJobTaskID, curJobTaskState, Msg, BoxDestInfo, BLL.AGVManager.GetRackBy(RFID), MissionText);
//}
//else if (RFID.StartsWith("D"))
//{
// return string.Format("Name:{1}{0}RFID:{2}{0}CurJob:{3}{0}CurJobTaskInfo:[TaskName={4}][TaskID={5}][TaskState={6}]{0}RunInfo:{7}{0}BoxDestInfo:{8}{0}MissionText:{9}",
// "\r\n", Name, RFID, CurJob.ToString(), curJobTaskName, curJobTaskID, curJobTaskState, Msg, BoxDestInfo, MissionText);
//}
//else
// return string.Format("Name:{1}{0}RFID:{2}{0}CurJob:{3}{0}CurJobTaskInfo:[TaskName={4}][TaskID={5}][TaskState={6}]{0}RunInfo:{7}{0}MissionText:{8}",
// "\r\n", Name, RFID, CurJob.ToString(), curJobTaskName, curJobTaskID, curJobTaskState, Msg, MissionText);
}
else
return
string
.
Format
(
"设备:{1}{0}RFID:{2}{0}任务信息:[任务名称={3}][任务状态={4}]{0}执行信息:{5}"
,
"\r\n"
,
Name
,
RFID
,
curJobTaskName
,
curJobTaskState
,
MissionText
);
//return string.Format("Name:{1}{0}RFID:{2}{0}CurTaskInfo:[TaskName={3}][TaskID={4}][TaskState={5}]{0}MissionText:{6}",
// "\r\n", Name, RFID, curJobTaskName, curJobTaskID, curJobTaskState, MissionText);
}
/// <summary>
/// 任务重发
...
...
AGVControl-ProductionLine/bean/UnlockedShelf.cs
查看文件 @
672bcc8
...
...
@@ -12,9 +12,8 @@ namespace AGVControl
/// 已解绑料架信息
/// </summary>
/// <param name="nodeName"></param>
public
UnlockedShelf
(
string
nodeName
)
public
UnlockedShelf
()
{
this
.
NodeName
=
nodeName
;
Rfids
=
new
Dictionary
<
string
,
string
>();
}
/// <summary>
...
...
@@ -56,19 +55,8 @@ namespace AGVControl
System
.
Threading
.
Interlocked
.
Increment
(
ref
tmp
);
EmptyCnt
=
tmp
;
Rfids
.
Add
(
rfid
,
DateTime
.
Now
.
ToString
(
"yyyy/MM/dd/HH:mm:ss,fff"
));
Common
.
WriteIni
(
NodeName
,
SettingString
.
EmptyShelfCnt
,
EmptyCnt
.
ToString
());
//using (System.IO.StreamWriter file = new System.IO.StreamWriter(Common.CONFIG_PATH + "UnlockInfo.txt"))
//{
// foreach (var item in Rfids.Keys)
// {
// file.WriteLine(string.Format("{0},{1}", Rfids[item], item));
// }
//}
Common
.
LogInfo
(
string
.
Format
(
"{0}解绑任务添加成功:RFID={1}"
,
NodeName
,
rfid
));
return
true
;
}
Common
.
LogInfo
(
string
.
Format
(
"{0}解绑任务添加失败:RFID={1}"
,
NodeName
,
rfid
));
return
false
;
}
/// <summary>
...
...
@@ -88,16 +76,6 @@ namespace AGVControl
Rfids
.
Clear
();
}
//Rfids.Remove(rfid);
Common
.
WriteIni
(
NodeName
,
SettingString
.
EmptyShelfCnt
,
EmptyCnt
.
ToString
());
//using (System.IO.StreamWriter file = new System.IO.StreamWriter(Common.CONFIG_PATH + "UnlockInfo.txt"))
//{
// foreach (var item in Rfids.Keys)
// {
// file.WriteLine(string.Format("{0},{1}", Rfids[item], item));
// }
//}
Common
.
LogInfo
(
string
.
Format
(
"{0}解绑任务删除成功:RFID={1}"
,
NodeName
,
rfid
));
return
true
;
}
}
...
...
@@ -107,7 +85,6 @@ namespace AGVControl
Rfids
.
Clear
();
return
true
;
}
Common
.
LogInfo
(
string
.
Format
(
"{0}解绑任务删除失败:RFID={1}"
,
NodeName
,
rfid
));
return
false
;
}
}
...
...
AGVControl-ProductionLine/bean/job/ChargeJob.cs
查看文件 @
672bcc8
...
...
@@ -62,6 +62,8 @@ namespace AGVControl
runInfo
=
"在待机位,电量充足["
+
agv
.
Battery
+
"%],等待任务"
;
msg
+=
runInfo
;
ChargeStep
.
Msg
=
msg
;
Common
.
MoveToNode
(
agv
,
SettingString
.
Standby
);
UpdateJobTaskInfo
(
agv
.
CurTaskName
,
agv
.
CurTaskID
);
}
else
if
(
agvPlace
.
StartsWith
(
SettingString
.
C4_Name_Prefix
)
&&
Common
.
CheckIsInAirDoor
(
agvPlace
))
{
...
...
AGVControl-ProductionLine/bean/job/SendFullShelfToLineJob.cs
查看文件 @
672bcc8
...
...
@@ -145,13 +145,25 @@ namespace AGVControl
{
if
(!
Common
.
Check4CTarget
(
agv
,
FullShelfPlace
))
//未占用
{
SendFullShelfStep
.
ToNextStep
(
SEND_FULL_SHELF_STEP
.
WAIT_AGV_REACH_LINE
);
runInfo
=
"从临时待机位送往["
+
FullShelfPlace
+
"][RFID="
+
RFID
+
"]"
;
msg
+=
runInfo
;
SendFullShelfStep
.
Msg
=
msg
;
Common
.
DeleteStandyInfo
(
agv
);
Common
.
MoveToNode
(
agv
,
FullShelfPlace
);
UpdateJobTaskInfo
(
agv
.
CurTaskName
,
agv
.
CurTaskID
);
if
(
Common
.
CheckIsInAirDoor
(
FullShelfPlace
))
{
SendFullShelfStep
.
ToNextStep
(
SEND_FULL_SHELF_STEP
.
WAIT_AGV_REACH_AIR_DOOR
);
runInfo
=
"到临时待机位,去产线先过风淋门["
+
FullShelfPlace
+
"][RFID="
+
RFID
+
"]"
;
msg
+=
runInfo
;
SendFullShelfStep
.
Msg
=
msg
;
Common
.
DoorMission
(
agv
,
SettingString
.
DoorAirIn
);
UpdateJobTaskInfo
(
agv
.
CurTaskName
,
agv
.
CurTaskID
);
}
else
{
SendFullShelfStep
.
ToNextStep
(
SEND_FULL_SHELF_STEP
.
WAIT_AGV_REACH_LINE
);
runInfo
=
"从临时待机位送往["
+
FullShelfPlace
+
"][RFID="
+
RFID
+
"]"
;
msg
+=
runInfo
;
SendFullShelfStep
.
Msg
=
msg
;
Common
.
DeleteStandyInfo
(
agv
);
Common
.
MoveToNode
(
agv
,
FullShelfPlace
);
UpdateJobTaskInfo
(
agv
.
CurTaskName
,
agv
.
CurTaskID
);
}
}
}
}
...
...
AGVControl-ProductionLine/bin/Debug/AGVControl-ProductionLine.exe
查看文件 @
672bcc8
此文件类型无法预览
AGVControl-ProductionLine/bin/Debug/AGVControl-ProductionLine.exe.config
查看文件 @
672bcc8
...
...
@@ -18,13 +18,17 @@
</
layout
>
</
appender
>
<
appender
name
=
"LineWebService"
type
=
"log4net.Appender.RollingFileAppender"
>
<
file
value
=
"logs/
LineWebService
.log"
/>
<
file
value
=
"logs/
UnlockInfo
.log"
/>
<
param
name
=
"Encoding"
value
=
"UTF-8"
/>
<
appendToFile
value
=
"true"
/>
<
rollingStyle
value
=
"Date"
/>
<
datePattern
value
=
"yyyy-MM-dd"
/>
<
param
name
=
"MaxSizeRollBackups"
value
=
"10"
/>
<!-- 切割最多文件数 -->
<
param
name
=
"MaximumFileSize"
value
=
"100MB"
/>
<!-- 每个文件的大小 -->
<
param
name
=
"RollingStyle"
value
=
"Size"
/>
<
param
name
=
"StaticLogFileName"
value
=
"true"
/>
<
layout
type
=
"log4net.Layout.PatternLayout"
>
<
conversionPattern
value
=
"[%date]
[%t][%c:%L]
%-5p %m%n"
/>
<
conversionPattern
value
=
"[%date]%-5p %m%n"
/>
</
layout
>
</
appender
>
<
logger
name
=
"LineWebService"
>
...
...
AGVControl-ProductionLine/bin/Debug/AGVControl-ProductionLine.pdb
查看文件 @
672bcc8
此文件类型无法预览
AGVControl-ProductionLine/bin/Debug/Config/UnlockInfo.json
查看文件 @
672bcc8
{
"NodeUnlockMissions"
:{
"D1"
:{
"NodeName"
:
"D1"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D2"
:{
"NodeName"
:
"D2"
,
"EmptyCnt"
:
0
,
"Rfids"
:{
}},
"D3"
:{
"NodeName"
:
"D3"
,
"EmptyCnt"
:
1
,
"Rfids"
:{
"D3"
:
"2020/12/05/22:50:48,047"
}},
"D4"
:{
"NodeName"
:
"D4"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D5"
:{
"NodeName"
:
"D5"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D6"
:{
"NodeName"
:
"D6"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D8"
:{
"NodeName"
:
"D8"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D9"
:{
"NodeName"
:
"D9"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D10"
:{
"NodeName"
:
"D10"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D11"
:{
"NodeName"
:
"D11"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D12"
:{
"NodeName"
:
"D12"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D14"
:{
"NodeName"
:
"D14"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D15"
:{
"NodeName"
:
"D15"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D16"
:{
"NodeName"
:
"D16"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D22"
:{
"NodeName"
:
"D22"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C1"
:{
"NodeName"
:
"C1"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C2"
:{
"NodeName"
:
"C2"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C3"
:{
"NodeName"
:
"C3"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C4"
:{
"NodeName"
:
"C4"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C5"
:{
"NodeName"
:
"C5"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C6"
:{
"NodeName"
:
"C6"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C7"
:{
"NodeName"
:
"C7"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C8"
:{
"NodeName"
:
"C8"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C9"
:{
"NodeName"
:
"C9"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C10"
:{
"NodeName"
:
"C10"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C14"
:{
"NodeName"
:
"C14"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C15"
:{
"NodeName"
:
"C15"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C22"
:{
"NodeName"
:
"C22"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}}}}
{
"NodeUnlockMissions"
:{
"D1"
:{
"NodeName"
:
"D1"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D2"
:{
"NodeName"
:
"D2"
,
"EmptyCnt"
:
1
,
"Rfids"
:{
"D4"
:
"2020/12/06/11:51:42,731"
}},
"D3"
:{
"NodeName"
:
"D3"
,
"EmptyCnt"
:
1
,
"Rfids"
:{
"D3"
:
"2020/12/05/22:50:48,047"
}},
"D4"
:{
"NodeName"
:
"D4"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D5"
:{
"NodeName"
:
"D5"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D6"
:{
"NodeName"
:
"D6"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D8"
:{
"NodeName"
:
"D8"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D9"
:{
"NodeName"
:
"D9"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D10"
:{
"NodeName"
:
"D10"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D11"
:{
"NodeName"
:
"D11"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D12"
:{
"NodeName"
:
"D12"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D14"
:{
"NodeName"
:
"D14"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D15"
:{
"NodeName"
:
"D15"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D16"
:{
"NodeName"
:
"D16"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"D22"
:{
"NodeName"
:
"D22"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C1"
:{
"NodeName"
:
"C1"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C2"
:{
"NodeName"
:
"C2"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C3"
:{
"NodeName"
:
"C3"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C4"
:{
"NodeName"
:
"C4"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C5"
:{
"NodeName"
:
"C5"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C6"
:{
"NodeName"
:
"C6"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C7"
:{
"NodeName"
:
"C7"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C8"
:{
"NodeName"
:
"C8"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C9"
:{
"NodeName"
:
"C9"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C10"
:{
"NodeName"
:
"C10"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C14"
:{
"NodeName"
:
"C14"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C15"
:{
"NodeName"
:
"C15"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}},
"C22"
:{
"NodeName"
:
"C22"
,
"EmptyCnt"
:
0
,
"Rfids"
:{}}}}
AGVControl-ProductionLine/bin/Debug/Config/tempData.ini
查看文件 @
672bcc8
...
...
@@ -12,3 +12,5 @@ RFID=
RFID
=
[MiR_R1580]
RFID
=
[D2]
EmptyShelfCnt
=
1
AGVControl-ProductionLine/bin/Debug/logs/AgvServer.log
deleted
100644 → 0
查看文件 @
00ced36
此文件的差异被折叠,
点击展开。
AGVControl-ProductionLine/bin/Debug/logs/
LineWebService
.log
→
AGVControl-ProductionLine/bin/Debug/logs/
UnlockInfo
.log
查看文件 @
672bcc8
文件被删除
AGVControl-ProductionLine/obj/Debug/AGVControl-ProductionLine.csproj.FileListAbsolute.txt
查看文件 @
672bcc8
...
...
@@ -71,3 +71,4 @@ E:\Neotel\Projects\Gitee\AGVControl-Qisda-ProductionLine\AGVControl-ProductionLi
E:\Neotel\Projects\Gitee\AGVControl-Qisda-ProductionLine\AGVControl-ProductionLine\obj\Debug\AGVControl-ProductionLine.exe
E:\Neotel\Projects\Gitee\AGVControl-Qisda-ProductionLine\AGVControl-ProductionLine\obj\Debug\AGVControl-ProductionLine.pdb
C:\myproject\Gitee\AGVControl-Qisda-ProductionLine\AGVControl-ProductionLine\obj\Debug\AGVControl-ProductionLine.csprojAssemblyReference.cache
E:\Neotel\Projects\Gitee\AGVControl-Qisda-ProductionLine\AGVControl-ProductionLine\obj\Debug\AGVControl-ProductionLine.csprojAssemblyReference.cache
AGVControl-ProductionLine/obj/Debug/AGVControl-ProductionLine.csproj.GenerateResource.cache
查看文件 @
672bcc8
此文件类型无法预览
AGVControl-ProductionLine/obj/Debug/AGVControl-ProductionLine.exe
查看文件 @
672bcc8
此文件类型无法预览
AGVControl-ProductionLine/obj/Debug/AGVControl-ProductionLine.pdb
查看文件 @
672bcc8
此文件类型无法预览
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论