Compare commits

..

24 Commits

Author SHA1 Message Date
ChiKyun Kim
649d87cae3 .. 2025-12-23 17:25:47 +09:00
backuppc
b3f661969a .. 2025-12-23 13:25:33 +09:00
backuppc
4f162e50b5 .. 2025-12-23 13:12:13 +09:00
backuppc
35df73fd29 xbee 값 설정기능 추가 2025-12-23 13:07:01 +09:00
ChiKyun Kim
8499c1c5be .. 2025-12-23 11:41:56 +09:00
backuppc
3408e3fc30 ... 2025-12-22 16:02:57 +09:00
ChiKyun Kim
5a4c73e4df Merge branch 'master' of file://k4fs3201n/k4bpartcenter$/Repository/K4/ENIG_AGV 2025-12-22 09:52:53 +09:00
ChiKyun Kim
34d1bdf504 add layout 2025-12-22 09:52:21 +09:00
backuppc
3cae423736 .. 2025-12-19 16:25:30 +09:00
ChiKyun Kim
d777adc219 BMS 를 RS232 클래스에서 폴링방식 전용 클래스로 변경
BMS 정보중 현재 사용 전류와 와트를 표시함
사용전류를 통해서 충전여부를 자동 판다시키고, 해당 값은 Manual Charge 플래그에 설정함.
2025-12-18 14:44:00 +09:00
ChiKyun Kim
b62cd5f52e 충방전 전류 및 전력량 계산 코드 추가 2025-12-18 10:55:04 +09:00
backuppc
32217c8501 Merge branch 'master' of https://git.tindevil.com/Amkor/ENIG 2025-12-18 10:32:48 +09:00
backuppc
9274727fa9 .. 2025-12-18 10:32:20 +09:00
2a44ba28a8 "fix:Enforce-Run-Mode-in-fAuto-VisibleChanged" 2025-12-18 00:43:22 +09:00
4bdc36040d "feat:Implement-Canvas-Run-Mode-and-Logic" 2025-12-18 00:38:59 +09:00
384f2affcb "refactor:Switch-serial-comm-to-polling" 2025-12-18 00:34:37 +09:00
ChiKyun Kim
51579591a2 add docment -
enable : signal2
2025-12-17 16:36:12 +09:00
ChiKyun Kim
cef2fa8095 flag,error 항목 정리, 2025-12-17 15:53:18 +09:00
backuppc
1f37871336 .. 2025-12-17 14:54:33 +09:00
eb0e08d290 .. 2025-12-16 23:31:47 +09:00
backuppc
4153362588 .. 2025-12-16 17:29:28 +09:00
67a48531ad .. 2025-12-15 22:06:53 +09:00
backuppc
a7f938ff19 .. 2025-12-15 17:34:43 +09:00
backuppc
9db88e5d6b .agvmap 확장자제거하고 .json 으로 통일한 mapeditor 와 호환성 유지 2025-12-15 08:33:42 +09:00
106 changed files with 58055 additions and 5979 deletions

View File

@@ -17,7 +17,7 @@
<DebugSymbols>true</DebugSymbols> <DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>..\..\..\..\..\..\Amkor\AGV4\</OutputPath> <OutputPath>..\..\..\..\..\..\Amkor\AGV4\Test\MapEditor\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants> <DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>

View File

@@ -36,20 +36,20 @@ namespace AGVMapEditor.Forms
{ {
public string FromNodeId { get; set; } public string FromNodeId { get; set; }
public string FromNodeName { get; set; } public string FromNodeName { get; set; }
public string FromRfidId { get; set; } public ushort FromRfidId { get; set; }
public string ToNodeId { get; set; } public string ToNodeId { get; set; }
public string ToNodeName { get; set; } public string ToNodeName { get; set; }
public string ToRfidId { get; set; } public ushort ToRfidId { get; set; }
public string ConnectionType { get; set; } public string ConnectionType { get; set; }
public override string ToString() public override string ToString()
{ {
// RFID가 있으면 RFID(노드이름), 없으면 NodeID(노드이름) 형태로 표시 // RFID가 있으면 RFID(노드이름), 없으면 NodeID(노드이름) 형태로 표시
string fromDisplay = !string.IsNullOrEmpty(FromRfidId) string fromDisplay = FromRfidId > 0
? $"{FromRfidId}({FromNodeName})" ? $"{FromRfidId}({FromNodeName})"
: $"---({FromNodeId})"; : $"---({FromNodeId})";
string toDisplay = !string.IsNullOrEmpty(ToRfidId) string toDisplay = ToRfidId > 0
? $"{ToRfidId}({ToNodeName})" ? $"{ToRfidId}({ToNodeName})"
: $"---({ToNodeId})"; : $"---({ToNodeId})";
@@ -420,7 +420,7 @@ namespace AGVMapEditor.Forms
return; return;
} }
var rfidDisplay = (_selectedNode as MapNode)?.RfidId ?? ""; var rfidDisplay = (_selectedNode as MapNode)?.RfidId ?? 0;
var result = MessageBox.Show($"노드 {rfidDisplay}[{_selectedNode.Id}] 를 삭제하시겠습니까?\n연결된 RFID 매핑도 함께 삭제됩니다.", var result = MessageBox.Show($"노드 {rfidDisplay}[{_selectedNode.Id}] 를 삭제하시겠습니까?\n연결된 RFID 매핑도 함께 삭제됩니다.",
"삭제 확인", MessageBoxButtons.YesNo, MessageBoxIcon.Question); "삭제 확인", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
@@ -546,8 +546,8 @@ namespace AGVMapEditor.Forms
{ {
var openFileDialog = new OpenFileDialog var openFileDialog = new OpenFileDialog
{ {
Filter = "AGV Map Files (*.agvmap;*.json)|*.agvmap;*.json|All Files (*.*)|*.*", Filter = "AGV Map Files (*.json)|*.json|All Files (*.*)|*.*",
DefaultExt = "agvmap", DefaultExt = "json",
}; };
@@ -595,9 +595,9 @@ namespace AGVMapEditor.Forms
{ {
var saveFileDialog = new SaveFileDialog var saveFileDialog = new SaveFileDialog
{ {
Filter = "AGV Map Files (*.agvmap)|*.agvmap", Filter = "AGV Map Files (*.json)|*.json",
DefaultExt = "agvmap", DefaultExt = "json",
FileName = "NewMap.agvmap" FileName = "NewMap.json"
}; };
if (saveFileDialog.ShowDialog() == DialogResult.OK) if (saveFileDialog.ShowDialog() == DialogResult.OK)
@@ -1107,8 +1107,8 @@ namespace AGVMapEditor.Forms
// RFID 값 변경시 중복 검사 // RFID 값 변경시 중복 검사
if (e.ChangedItem.PropertyDescriptor.Name == "RFID") if (e.ChangedItem.PropertyDescriptor.Name == "RFID")
{ {
string newRfidValue = e.ChangedItem.Value?.ToString(); var newRfidValue = ushort.Parse(e.ChangedItem.Value?.ToString());
if (!string.IsNullOrEmpty(newRfidValue) && CheckRfidDuplicate(newRfidValue)) if (newRfidValue != 0 && CheckRfidDuplicate(newRfidValue))
{ {
// 중복된 RFID 값 발견 // 중복된 RFID 값 발견
MessageBox.Show($"RFID 값 '{newRfidValue}'이(가) 이미 다른 노드에서 사용 중입니다.\n입력값을 되돌립니다.", MessageBox.Show($"RFID 값 '{newRfidValue}'이(가) 이미 다른 노드에서 사용 중입니다.\n입력값을 되돌립니다.",
@@ -1174,29 +1174,15 @@ namespace AGVMapEditor.Forms
/// </summary> /// </summary>
/// <param name="rfidValue">검사할 RFID 값</param> /// <param name="rfidValue">검사할 RFID 값</param>
/// <returns>중복되면 true, 아니면 false</returns> /// <returns>중복되면 true, 아니면 false</returns>
private bool CheckRfidDuplicate(string rfidValue) private bool CheckRfidDuplicate(ushort rfidValue)
{ {
if (string.IsNullOrEmpty(rfidValue) || this._mapCanvas.Nodes == null) if (rfidValue == 0 || this._mapCanvas.Nodes == null)
return false; return false;
// 현재 편집 중인 노드 제외하고 중복 검사 // 현재 편집 중인 노드 제외하고 중복 검사
string currentNodeId = null; string currentNodeId = null;
var selectedObject = _propertyGrid.SelectedObject; var selectedObject = _propertyGrid.SelectedObject;
// 다양한 PropertyWrapper 타입 처리
//if (selectedObject is NodePropertyWrapper nodeWrapper)
//{
// currentNodeId = nodeWrapper.WrappedNode?.NodeId;
//}
//else if (selectedObject is LabelNodePropertyWrapper labelWrapper)
//{
// currentNodeId = labelWrapper.WrappedNode?.NodeId;
//}
//else if (selectedObject is ImageNodePropertyWrapper imageWrapper)
//{
// currentNodeId = imageWrapper.WrappedNode?.NodeId;
//}
int duplicateCount = 0; int duplicateCount = 0;
foreach (var node in this._mapCanvas.Nodes) foreach (var node in this._mapCanvas.Nodes)
{ {
@@ -1205,7 +1191,7 @@ namespace AGVMapEditor.Forms
continue; continue;
// 같은 RFID 값을 가진 노드가 있는지 확인 // 같은 RFID 값을 가진 노드가 있는지 확인
if (!string.IsNullOrEmpty(node.RfidId) && node.RfidId.Equals(rfidValue, StringComparison.OrdinalIgnoreCase)) if (node.RfidId != 0 && node.RfidId == rfidValue)
{ {
duplicateCount++; duplicateCount++;
break; // 하나라도 발견되면 중복 break; // 하나라도 발견되면 중복

View File

@@ -815,6 +815,9 @@ namespace AGVNavigationCore.Controls
case StationType.Charger: case StationType.Charger:
DrawTriangleNodeShape(g, node, brush); DrawTriangleNodeShape(g, node, brush);
break; break;
case StationType.Limit:
DrawRectangleNodeShape(g, node, brush);
break;
default: default:
DrawCircleNodeShape(g, node, brush); DrawCircleNodeShape(g, node, brush);
break; break;
@@ -823,6 +826,83 @@ namespace AGVNavigationCore.Controls
} }
private void DrawRectangleNodeShape(Graphics g, MapNode node, Brush brush)
{
// 드래그 중인 노드는 약간 크게 그리기
bool isDraggingThisNode = _isDragging && node == _selectedNode;
int sizeAdjustment = isDraggingThisNode ? 4 : 0;
var rect = new Rectangle(
node.Position.X - NODE_RADIUS - sizeAdjustment,
node.Position.Y - NODE_RADIUS - sizeAdjustment,
NODE_SIZE + sizeAdjustment * 2,
NODE_SIZE + sizeAdjustment * 2
);
// 드래그 중인 노드의 그림자 효과
if (isDraggingThisNode)
{
var shadowRect = new Rectangle(rect.X + 3, rect.Y + 3, rect.Width, rect.Height);
using (var shadowBrush = new SolidBrush(Color.FromArgb(100, 0, 0, 0)))
{
g.FillRectangle(shadowBrush, shadowRect);
}
}
// 노드 그리기
g.FillRectangle(brush, rect);
g.DrawRectangle(Pens.Black, rect);
// 드래그 중인 노드 강조 (가장 강력한 효과)
if (isDraggingThisNode)
{
// 청록색 두꺼운 테두리
g.DrawRectangle(new Pen(Color.Cyan, 3), rect);
// 펄스 효과
var pulseRect = new Rectangle(rect.X - 4, rect.Y - 4, rect.Width + 8, rect.Height + 8);
g.DrawRectangle(new Pen(Color.FromArgb(150, 0, 255, 255), 2) { DashStyle = DashStyle.Dash }, pulseRect);
}
// 선택된 노드 강조 (단일 또는 다중)
else if (node == _selectedNode || (_selectedNodes != null && _selectedNodes.Contains(node)))
{
g.DrawRectangle(_selectedNodePen, rect);
}
// 목적지 노드 강조
if (node == _destinationNode)
{
// 금색 테두리로 목적지 강조
g.DrawRectangle(_destinationNodePen, rect);
// 펄싱 효과를 위한 추가 원 그리기
var pulseRect = new Rectangle(rect.X - 3, rect.Y - 3, rect.Width + 6, rect.Height + 6);
g.DrawRectangle(new Pen(Color.Gold, 2) { DashStyle = DashStyle.Dash }, pulseRect);
}
// 호버된 노드 강조 (드래그 중이 아닐 때만)
if (node == _hoveredNode && !isDraggingThisNode)
{
var hoverRect = new Rectangle(rect.X - 2, rect.Y - 2, rect.Width + 4, rect.Height + 4);
g.DrawRectangle(new Pen(Color.Orange, 2), hoverRect);
}
// RFID 중복 노드 표시 (빨간 X자)
if (_duplicateRfidNodes.Contains(node.Id))
{
DrawDuplicateRfidMarker(g, node);
}
// CanCross 가능 노드 표시 (교차지점으로 사용 가능)
if (node.DisableCross == true)
{
var crossRect = new Rectangle(rect.X - 3, rect.Y - 3, rect.Width + 6, rect.Height + 6);
g.DrawRectangle(new Pen(Color.DeepSkyBlue, 3), crossRect);
}
g.DrawLine(Pens.Black, rect.X, rect.Y, rect.Right, rect.Bottom);
g.DrawLine(Pens.Black, rect.Right, rect.Top, rect.X, rect.Bottom);
}
private void DrawCircleNodeShape(Graphics g, MapNode node, Brush brush) private void DrawCircleNodeShape(Graphics g, MapNode node, Brush brush)
{ {
// 드래그 중인 노드는 약간 크게 그리기 // 드래그 중인 노드는 약간 크게 그리기
@@ -1140,7 +1220,8 @@ namespace AGVNavigationCore.Controls
// 위쪽에 표시할 이름 (노드의 Name 속성) // 위쪽에 표시할 이름 (노드의 Name 속성)
string TopIDText = node.HasRfid() ? node.RfidId : $"[{node.Id}]"; string TopIDText = node.HasRfid() ? node.RfidId.ToString("0000") : $"[{node.Id}]";
// 아래쪽에 표시할 값 (RFID 우선, 없으면 노드ID) // 아래쪽에 표시할 값 (RFID 우선, 없으면 노드ID)
string BottomLabelText = node.Text; string BottomLabelText = node.Text;
@@ -1474,6 +1555,7 @@ namespace AGVNavigationCore.Controls
case StationType.UnLoader: bgColor = Color.Gold; break; case StationType.UnLoader: bgColor = Color.Gold; break;
case StationType.Clearner: bgColor = Color.DeepSkyBlue; break; case StationType.Clearner: bgColor = Color.DeepSkyBlue; break;
case StationType.Buffer: bgColor = Color.WhiteSmoke; break; case StationType.Buffer: bgColor = Color.WhiteSmoke; break;
case StationType.Limit: bgColor = Color.Red; break;
default: bgColor = Color.White; break; default: bgColor = Color.White; break;
} }

View File

@@ -119,6 +119,9 @@ namespace AGVNavigationCore.Controls
var worldPoint = ScreenToWorld(e.Location); var worldPoint = ScreenToWorld(e.Location);
var hitNode = GetItemAt(worldPoint); var hitNode = GetItemAt(worldPoint);
// 가동 모드에서는 더블클릭 편집 방지
if (_canvasMode == CanvasMode.Run) return;
if (hitNode == null) return; if (hitNode == null) return;
if (hitNode.Type == NodeType.Normal) if (hitNode.Type == NodeType.Normal)
@@ -146,15 +149,19 @@ namespace AGVNavigationCore.Controls
private void HandleNormalNodeDoubleClick(MapNode node) private void HandleNormalNodeDoubleClick(MapNode node)
{ {
// RFID 입력창 표시 // RFID 입력창 표시
string currentRfid = node.RfidId ?? ""; var currentRfid = node.RfidId;
string newRfid = Microsoft.VisualBasic.Interaction.InputBox( string newRfid = Microsoft.VisualBasic.Interaction.InputBox(
$"노드 '{node.RfidId}[{node.Id}]'의 RFID를 입력하세요:", $"노드 '{node.RfidId}[{node.Id}]'의 RFID를 입력하세요:",
"RFID 설정", "RFID 설정",
currentRfid); currentRfid.ToString());
if (!string.IsNullOrWhiteSpace(newRfid) && newRfid != currentRfid) if (ushort.TryParse(newRfid, out ushort newrfidvalue) == false) return;
if (newrfidvalue < 1) return;
if (newrfidvalue != currentRfid)
{ {
node.RfidId = newRfid.Trim(); node.RfidId = newrfidvalue;
MapChanged?.Invoke(this, EventArgs.Empty); MapChanged?.Invoke(this, EventArgs.Empty);
Invalidate(); Invalidate();
} }
@@ -700,8 +707,8 @@ namespace AGVNavigationCore.Controls
{ {
// 연결선을 클릭했을 때 삭제 확인 // 연결선을 클릭했을 때 삭제 확인
var (fromNode, toNode) = connection.Value; var (fromNode, toNode) = connection.Value;
string fromDisplay = !string.IsNullOrEmpty(fromNode.RfidId) ? fromNode.RfidId : fromNode.Id; string fromDisplay = fromNode.HasRfid() ? fromNode.RfidId.ToString("0000") : fromNode.Id;
string toDisplay = !string.IsNullOrEmpty(toNode.RfidId) ? toNode.RfidId : toNode.Id; string toDisplay = toNode.HasRfid() ? toNode.RfidId.ToString("0000") : toNode.Id;
var result = MessageBox.Show( var result = MessageBox.Show(
$"연결을 삭제하시겠습니까?\n\n{fromDisplay} ↔ {toDisplay}", $"연결을 삭제하시겠습니까?\n\n{fromDisplay} ↔ {toDisplay}",

View File

@@ -39,7 +39,8 @@ namespace AGVNavigationCore.Controls
{ {
Edit, // 편집 가능 (맵 에디터) Edit, // 편집 가능 (맵 에디터)
Sync, // 동기화 모드 (장비 설정 동기화) Sync, // 동기화 모드 (장비 설정 동기화)
Emulator // 에뮬레이터 모드 Emulator, // 에뮬레이터 모드
Run // 가동 모드 (User Request)
} }
/// <summary> /// <summary>
@@ -851,13 +852,13 @@ namespace AGVNavigationCore.Controls
return; return;
// RFID값과 해당 노드의 인덱스를 저장 // RFID값과 해당 노드의 인덱스를 저장
var rfidToNodeIndex = new Dictionary<string, List<int>>(); var rfidToNodeIndex = new Dictionary<ushort, List<int>>();
// 모든 노드의 RFID값 수집 // 모든 노드의 RFID값 수집
for (int i = 0; i < _nodes.Count; i++) for (int i = 0; i < _nodes.Count; i++)
{ {
var node = _nodes[i]; var node = _nodes[i];
if (!string.IsNullOrEmpty(node.RfidId)) if (node.HasRfid())
{ {
if (!rfidToNodeIndex.ContainsKey(node.RfidId)) if (!rfidToNodeIndex.ContainsKey(node.RfidId))
{ {

View File

@@ -73,7 +73,13 @@ namespace AGVNavigationCore.Models
/// <summary>버퍼</summary> /// <summary>버퍼</summary>
Buffer, Buffer,
/// <summary>충전기</summary> /// <summary>충전기</summary>
Charger Charger,
/// <summary>
/// 끝점(더이상 이동불가)
/// </summary>
Limit,
} }
/// <summary> /// <summary>

View File

@@ -83,7 +83,7 @@ namespace AGVNavigationCore.Models
[Category("RFID 정보")] [Category("RFID 정보")]
[Description("물리적 RFID 태그 ID입니다.")] [Description("물리적 RFID 태그 ID입니다.")]
public string RfidId { get; set; } = string.Empty; public UInt16 RfidId { get; set; } = 0;
[Category("노드 텍스트"), DisplayName("TextColor")] [Category("노드 텍스트"), DisplayName("TextColor")]
@@ -149,7 +149,7 @@ namespace AGVNavigationCore.Models
public override string ToString() public override string ToString()
{ {
return $"{RfidId}({Id}): {AliasName} ({Type}) at ({Position.X}, {Position.Y})"; return $"RFID:{RfidId}(NODE:{Id}): AS:{AliasName} ({Type}) at ({Position.X}, {Position.Y})";
} }
public bool IsNavigationNode() public bool IsNavigationNode()
@@ -161,7 +161,7 @@ namespace AGVNavigationCore.Models
public bool HasRfid() public bool HasRfid()
{ {
return !string.IsNullOrEmpty(RfidId); return RfidId > 0;
} }
} }
} }

View File

@@ -280,6 +280,7 @@ namespace AGVNavigationCore.Models
public bool SetCurrentNodeMarkStop() public bool SetCurrentNodeMarkStop()
{ {
if (_currentNode == null) return false; if (_currentNode == null) return false;
if (_currentPath == null) return false;
var = _currentPath.DetailedPath.Where(t => t.IsPass == false).OrderBy(t => t.seq).FirstOrDefault(); var = _currentPath.DetailedPath.Where(t => t.IsPass == false).OrderBy(t => t.seq).FirstOrDefault();
if ( == null) return false; if ( == null) return false;
.IsPass = true; .IsPass = true;
@@ -611,17 +612,6 @@ namespace AGVNavigationCore.Models
PositionChanged?.Invoke(this, (_currentPosition, _currentDirection, _currentNode)); PositionChanged?.Invoke(this, (_currentPosition, _currentDirection, _currentNode));
} }
/// <summary>
/// 현재 RFID 시뮬레이션 (현재 위치 기준)
/// </summary>
public string SimulateRfidReading(List<MapNode> mapNodes)
{
var closestNode = FindClosestNode(_currentPosition, mapNodes);
if (closestNode == null)
return null;
return closestNode.HasRfid() ? closestNode.RfidId : null;
}
#endregion #endregion
@@ -630,10 +620,11 @@ namespace AGVNavigationCore.Models
/// <summary> /// <summary>
/// 노드 ID를 RFID 값으로 변환 (NodeResolver 사용) /// 노드 ID를 RFID 값으로 변환 (NodeResolver 사용)
/// </summary> /// </summary>
public string GetRfidByNodeId(List<MapNode> _mapNodes, string nodeId) public ushort GetRfidByNodeId(List<MapNode> _mapNodes, string nodeId)
{ {
var node = _mapNodes?.FirstOrDefault(n => n.Id == nodeId); var node = _mapNodes?.FirstOrDefault(n => n.Id == nodeId);
return node?.HasRfid() == true ? node.RfidId : nodeId; if ((node?.HasRfid() ?? false) == false) return 0;
return node.RfidId;
} }

View File

@@ -447,7 +447,7 @@ namespace AGVNavigationCore.PathFinding.Planning
{ {
var node = path1.Path[i]; var node = path1.Path[i];
string nodeId = node.Id; string nodeId = node.Id;
string RfidId = node.RfidId; var RfidId = node.RfidId;
string nextNodeId = (i + 1 < path1.Path.Count) ? path1.Path[i + 1].Id : null; string nextNodeId = (i + 1 < path1.Path.Count) ? path1.Path[i + 1].Id : null;
// 노드 정보 생성 (현재 방향 유지) // 노드 정보 생성 (현재 방향 유지)
@@ -464,6 +464,8 @@ namespace AGVNavigationCore.PathFinding.Planning
{ {
nodeInfo.Speed = mapNode.SpeedLimit; nodeInfo.Speed = mapNode.SpeedLimit;
} }
detailedPath1.Add(nodeInfo);
} }
// path1에 상세 경로 정보 설정 // path1에 상세 경로 정보 설정

View File

@@ -770,9 +770,9 @@ namespace AGVNavigationCore.PathFinding.Planning
private string GetDisplayName(string nodeId) private string GetDisplayName(string nodeId)
{ {
var node = _mapNodes.FirstOrDefault(n => n.Id == nodeId); var node = _mapNodes.FirstOrDefault(n => n.Id == nodeId);
if (node != null && !string.IsNullOrEmpty(node.RfidId)) if (node != null && node.HasRfid())
{ {
return node.RfidId; return node.RfidId.ToString("0000");
} }
return $"({nodeId})"; return $"({nodeId})";
} }

View File

@@ -40,7 +40,7 @@ namespace AGVNavigationCore.PathFinding.Planning
/// <summary> /// <summary>
/// RFID Value /// RFID Value
/// </summary> /// </summary>
public string RfidId { get; set; } public ushort RfidId { get; set; }
/// <summary> /// <summary>
/// 해당 노드에서의 모터방향 /// 해당 노드에서의 모터방향
@@ -87,7 +87,7 @@ namespace AGVNavigationCore.PathFinding.Planning
/// </summary> /// </summary>
public string SpecialActionDescription { get; set; } public string SpecialActionDescription { get; set; }
public NodeMotorInfo(int seqno,string nodeId,string rfid, AgvDirection motorDirection, string nextNodeId = null, MagnetDirection magnetDirection = MagnetDirection.Straight) public NodeMotorInfo(int seqno,string nodeId,ushort rfid, AgvDirection motorDirection, string nextNodeId = null, MagnetDirection magnetDirection = MagnetDirection.Straight)
{ {
seq = seqno; seq = seqno;
NodeId = nodeId; NodeId = nodeId;
@@ -108,7 +108,7 @@ namespace AGVNavigationCore.PathFinding.Planning
/// </summary> /// </summary>
public override string ToString() public override string ToString()
{ {
var result = $"{RfidId}[{NodeId}]:{MotorDirection}"; var result = $"R{RfidId}[N{NodeId}]:{MotorDirection}";
// 마그넷 방향이 직진이 아닌 경우 표시 // 마그넷 방향이 직진이 아닌 경우 표시
if (MagnetDirection != MagnetDirection.Straight) if (MagnetDirection != MagnetDirection.Straight)

View File

@@ -204,7 +204,7 @@ namespace AGVNavigationCore.Utils
} }
Console.WriteLine( Console.WriteLine(
$"\n 최종선택: {bestNode?.RfidId ?? "null"}[{bestNode?.Id ?? "null"}] (점수: {bestScore:F4})"); $"\n 최종선택: {bestNode?.RfidId ?? 0}[{bestNode?.Id ?? "null"}] (점수: {bestScore:F4})");
Console.WriteLine( Console.WriteLine(
$"[GetNextNodeByDirection] ========== 다음 노드 선택 종료 ==========\n"); $"[GetNextNodeByDirection] ========== 다음 노드 선택 종료 ==========\n");

View File

@@ -11,22 +11,22 @@ namespace AGVNavigationCore.Utils
{ {
/// <summary> /// <summary>
/// DirectionalPathfinder 테스트 클래스 /// DirectionalPathfinder 테스트 클래스
/// NewMap.agvmap을 로드하여 방향별 다음 노드를 검증 /// NewMap.json 로드하여 방향별 다음 노드를 검증
/// </summary> /// </summary>
public class DirectionalPathfinderTest public class DirectionalPathfinderTest
{ {
private List<MapNode> _allNodes; private List<MapNode> _allNodes;
private Dictionary<string, MapNode> _nodesByRfidId; private Dictionary<ushort, MapNode> _nodesByRfidId;
private AGVDirectionCalculator _calculator; private AGVDirectionCalculator _calculator;
public DirectionalPathfinderTest() public DirectionalPathfinderTest()
{ {
_nodesByRfidId = new Dictionary<string, MapNode>(); _nodesByRfidId = new Dictionary<ushort, MapNode>();
_calculator = new AGVDirectionCalculator(); _calculator = new AGVDirectionCalculator();
} }
/// <summary> /// <summary>
/// NewMap.agvmap 파일 로드 /// NewMap.json 파일 로드
/// </summary> /// </summary>
public bool LoadMapFile(string filePath) public bool LoadMapFile(string filePath)
{ {
@@ -52,7 +52,7 @@ namespace AGVNavigationCore.Utils
// RFID ID로 인덱싱 // RFID ID로 인덱싱
foreach (var node in _allNodes) foreach (var node in _allNodes)
{ {
if (!string.IsNullOrEmpty(node.RfidId)) if (node.HasRfid())
{ {
_nodesByRfidId[node.RfidId] = node; _nodesByRfidId[node.RfidId] = node;
} }
@@ -71,7 +71,7 @@ namespace AGVNavigationCore.Utils
/// <summary> /// <summary>
/// 테스트: RFID 번호로 노드를 찾고, 다음 노드를 계산 /// 테스트: RFID 번호로 노드를 찾고, 다음 노드를 계산
/// </summary> /// </summary>
public void TestDirectionalMovement(string previousRfidId, string currentRfidId, AgvDirection direction) public void TestDirectionalMovement(ushort previousRfidId, ushort currentRfidId, AgvDirection direction)
{ {
Console.WriteLine($"\n========================================"); Console.WriteLine($"\n========================================");
Console.WriteLine($"테스트: {previousRfidId} → {currentRfidId} (방향: {direction})"); Console.WriteLine($"테스트: {previousRfidId} → {currentRfidId} (방향: {direction})");
@@ -140,7 +140,7 @@ namespace AGVNavigationCore.Utils
/// <summary> /// <summary>
/// 특정 RFID 노드의 상세 정보 출력 /// 특정 RFID 노드의 상세 정보 출력
/// </summary> /// </summary>
public void PrintNodeInfo(string rfidId) public void PrintNodeInfo(ushort rfidId)
{ {
if (!_nodesByRfidId.TryGetValue(rfidId, out var node)) if (!_nodesByRfidId.TryGetValue(rfidId, out var node))
{ {

View File

@@ -28,10 +28,10 @@ namespace AGVNavigationCore.Utils
Console.WriteLine("================================================\n"); Console.WriteLine("================================================\n");
// 테스트 노드 생성 // 테스트 노드 생성
var node001 = new MapNode { Id = "N001", RfidId = "001", Position = new Point(65, 229), ConnectedNodes = new List<string> { "N002" } }; var node001 = new MapNode { Id = "N001", RfidId = 001, Position = new Point(65, 229), ConnectedNodes = new List<string> { "N002" } };
var node002 = new MapNode { Id = "N002", RfidId = "002", Position = new Point(206, 244), ConnectedNodes = new List<string> { "N001", "N003" } }; var node002 = new MapNode { Id = "N002", RfidId = 002, Position = new Point(206, 244), ConnectedNodes = new List<string> { "N001", "N003" } };
var node003 = new MapNode { Id = "N003", RfidId = "003", Position = new Point(278, 278), ConnectedNodes = new List<string> { "N002", "N004" } }; var node003 = new MapNode { Id = "N003", RfidId = 003, Position = new Point(278, 278), ConnectedNodes = new List<string> { "N002", "N004" } };
var node004 = new MapNode { Id = "N004", RfidId = "004", Position = new Point(380, 340), ConnectedNodes = new List<string> { "N003", "N022", "N031" } }; var node004 = new MapNode { Id = "N004", RfidId = 004, Position = new Point(380, 340), ConnectedNodes = new List<string> { "N003", "N022", "N031" } };
var allNodes = new List<MapNode> { node001, node002, node003, node004 }; var allNodes = new List<MapNode> { node001, node002, node003, node004 };
@@ -114,7 +114,7 @@ namespace AGVNavigationCore.Utils
AgvDirection motorDir = currentMotorDirection ?? direction; AgvDirection motorDir = currentMotorDirection ?? direction;
Console.WriteLine($"설명: {description}"); Console.WriteLine($"설명: {description}");
Console.WriteLine($"이전 위치: {prevPos} (RFID: {allNodes.First(n => n.Position == prevPos)?.RfidId ?? "?"})"); Console.WriteLine($"이전 위치: {prevPos} (RFID: {allNodes.First(n => n.Position == prevPos)?.RfidId.ToString("0000") ?? "?"})");
Console.WriteLine($"현재 노드: {currentNode.Id} (RFID: {currentNode.RfidId}) - 위치: {currentNode.Position}"); Console.WriteLine($"현재 노드: {currentNode.Id} (RFID: {currentNode.RfidId}) - 위치: {currentNode.Position}");
Console.WriteLine($"현재 모터 방향: {motorDir}"); Console.WriteLine($"현재 모터 방향: {motorDir}");
Console.WriteLine($"요청 방향: {direction}"); Console.WriteLine($"요청 방향: {direction}");

View File

@@ -14,7 +14,7 @@ namespace AGVNavigationCore.Utils
{ {
public void RunTests() public void RunTests()
{ {
string mapFilePath = @"C:\Data\Source\(5613#) ENIG AGV\Source\Cs_HMI\Data\NewMap.agvmap"; string mapFilePath = @"C:\Data\Source\(5613#) ENIG AGV\Source\Cs_HMI\Data\NewMap.json";
var tester = new DirectionalPathfinderTest(); var tester = new DirectionalPathfinderTest();
@@ -29,26 +29,26 @@ namespace AGVNavigationCore.Utils
tester.PrintAllNodes(); tester.PrintAllNodes();
// 테스트 시나리오 1: 001 → 002 → Forward (003 기대) // 테스트 시나리오 1: 001 → 002 → Forward (003 기대)
tester.PrintNodeInfo("001"); tester.PrintNodeInfo(001);
tester.PrintNodeInfo("002"); tester.PrintNodeInfo(002);
tester.TestDirectionalMovement("001", "002", AgvDirection.Forward); tester.TestDirectionalMovement(001, 002, AgvDirection.Forward);
// 테스트 시나리오 2: 002 → 001 → Backward (000 또는 이전 기대) // 테스트 시나리오 2: 002 → 001 → Backward (000 또는 이전 기대)
tester.TestDirectionalMovement("002", "001", AgvDirection.Backward); tester.TestDirectionalMovement(002, 001, AgvDirection.Backward);
// 테스트 시나리오 3: 002 → 003 → Forward // 테스트 시나리오 3: 002 → 003 → Forward
tester.PrintNodeInfo("003"); tester.PrintNodeInfo(003);
tester.TestDirectionalMovement("002", "003", AgvDirection.Forward); tester.TestDirectionalMovement(002, 003, AgvDirection.Forward);
// 테스트 시나리오 4: 003 → 004 → Forward // 테스트 시나리오 4: 003 → 004 → Forward
tester.PrintNodeInfo("004"); tester.PrintNodeInfo(004);
tester.TestDirectionalMovement("003", "004", AgvDirection.Forward); tester.TestDirectionalMovement(003, 004, AgvDirection.Forward);
// 테스트 시나리오 5: 003 → 004 → Right (030 기대) // 테스트 시나리오 5: 003 → 004 → Right (030 기대)
tester.TestDirectionalMovement("003", "004", AgvDirection.Right); tester.TestDirectionalMovement(003, 004, AgvDirection.Right);
// 테스트 시나리오 6: 004 → 003 → Backward // 테스트 시나리오 6: 004 → 003 → Backward
tester.TestDirectionalMovement("004", "003", AgvDirection.Backward); tester.TestDirectionalMovement(004, 003, AgvDirection.Backward);
Console.WriteLine("\n\n=== 테스트 완료 ==="); Console.WriteLine("\n\n=== 테스트 완료 ===");
} }

View File

@@ -17,7 +17,7 @@
<DebugSymbols>true</DebugSymbols> <DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>..\..\..\..\..\..\Amkor\AGV4\</OutputPath> <OutputPath>..\..\..\..\..\..\Amkor\AGV4\Test\Simulator\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants> <DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>

View File

@@ -231,7 +231,7 @@ namespace AGVSimulator.Forms
{ {
using (var openDialog = new OpenFileDialog()) using (var openDialog = new OpenFileDialog())
{ {
openDialog.Filter = "AGV Map Files (*.agvmap)|*.agvmap|모든 파일 (*.*)|*.*"; openDialog.Filter = "AGV Map Files (*.json)|*.json|모든 파일 (*.*)|*.*";
openDialog.Title = "맵 파일 열기"; openDialog.Title = "맵 파일 열기";
if (openDialog.ShowDialog() == DialogResult.OK) if (openDialog.ShowDialog() == DialogResult.OK)
@@ -635,7 +635,7 @@ namespace AGVSimulator.Forms
/// <summary> /// <summary>
/// 맵 스캔 모드에서 RFID로부터 노드 생성 /// 맵 스캔 모드에서 RFID로부터 노드 생성
/// </summary> /// </summary>
private void CreateNodeFromRfidScan(string rfidId, VirtualAGV selectedAGV) private void CreateNodeFromRfidScan(ushort rfidId, VirtualAGV selectedAGV)
{ {
try try
{ {
@@ -644,7 +644,7 @@ namespace AGVSimulator.Forms
var currentDirection = directionItem?.Direction ?? AgvDirection.Forward; var currentDirection = directionItem?.Direction ?? AgvDirection.Forward;
// 중복 RFID 확인 // 중복 RFID 확인
var existingNode = _simulatorCanvas.Nodes?.FirstOrDefault(n => n.RfidId.Equals(rfidId, StringComparison.OrdinalIgnoreCase)); var existingNode = _simulatorCanvas.Nodes?.FirstOrDefault(n => n.RfidId == rfidId);
if (existingNode != null) if (existingNode != null)
{ {
// 이미 존재하는 노드로 이동 // 이미 존재하는 노드로 이동
@@ -805,7 +805,7 @@ namespace AGVSimulator.Forms
if (agv.CurrentNodeId != null && agv.CurrentNodeId != _lastSentNodeId) if (agv.CurrentNodeId != null && agv.CurrentNodeId != _lastSentNodeId)
{ {
var rfid = GetRfidByNodeId(agv.CurrentNodeId); var rfid = GetRfidByNodeId(agv.CurrentNodeId);
if (!string.IsNullOrEmpty(rfid)) if (rfid > 0)
{ {
SendTag(rfid); SendTag(rfid);
_lastSentNodeId = agv.CurrentNodeId; _lastSentNodeId = agv.CurrentNodeId;
@@ -842,7 +842,7 @@ namespace AGVSimulator.Forms
// RFID 값 확인 // RFID 값 확인
var rfidId = _rfidTextBox.Text.Trim(); var rfidId = _rfidTextBox.Text.Trim();
if (string.IsNullOrEmpty(rfidId)) if (ushort.TryParse(rfidId,out ushort rfidvalue)==false)
{ {
MessageBox.Show("RFID 값을 입력해주세요.", "알림", MessageBoxButtons.OK, MessageBoxIcon.Information); MessageBox.Show("RFID 값을 입력해주세요.", "알림", MessageBoxButtons.OK, MessageBoxIcon.Information);
return; return;
@@ -856,13 +856,13 @@ namespace AGVSimulator.Forms
// 맵 스캔 모드일 때: 노드 자동 생성 // 맵 스캔 모드일 때: 노드 자동 생성
if (_isMapScanMode) if (_isMapScanMode)
{ {
CreateNodeFromRfidScan(rfidId, selectedAGV); CreateNodeFromRfidScan(rfidvalue, selectedAGV);
this._simulatorCanvas.FitToNodes(); this._simulatorCanvas.FitToNodes();
return; return;
} }
// RFID에 해당하는 노드 직접 찾기 // RFID에 해당하는 노드 직접 찾기
var targetNode = _simulatorCanvas.Nodes?.FirstOrDefault(n => n.RfidId.Equals(rfidId, StringComparison.OrdinalIgnoreCase)); var targetNode = _simulatorCanvas.Nodes?.FirstOrDefault(n => n.RfidId == rfidvalue);
if (targetNode == null) if (targetNode == null)
{ {
MessageBox.Show($"RFID '{rfidId}'에 해당하는 노드를 찾을 수 없습니다.\n\n사용 가능한 RFID 목록:\n{GetAvailableRfidList()}", MessageBox.Show($"RFID '{rfidId}'에 해당하는 노드를 찾을 수 없습니다.\n\n사용 가능한 RFID 목록:\n{GetAvailableRfidList()}",
@@ -1255,10 +1255,12 @@ namespace AGVSimulator.Forms
/// <summary> /// <summary>
/// 노드 ID를 RFID 값으로 변환 (NodeResolver 사용) /// 노드 ID를 RFID 값으로 변환 (NodeResolver 사용)
/// </summary> /// </summary>
private string GetRfidByNodeId(string nodeId) private ushort GetRfidByNodeId(string nodeId)
{ {
var node = _simulatorCanvas.Nodes?.FirstOrDefault(n => n.Id == nodeId); var node = _simulatorCanvas.Nodes?.FirstOrDefault(n => n.Id == nodeId);
return node?.HasRfid() == true ? node.RfidId : nodeId; if (node == null) return 0;
if (node.HasRfid()) return node.RfidId;
else return 0;
} }
/// <summary> /// <summary>
@@ -1267,9 +1269,9 @@ namespace AGVSimulator.Forms
private string GetDisplayName(string nodeId) private string GetDisplayName(string nodeId)
{ {
var node = _simulatorCanvas.Nodes?.FirstOrDefault(n => n.Id == nodeId); var node = _simulatorCanvas.Nodes?.FirstOrDefault(n => n.Id == nodeId);
if (node != null && !string.IsNullOrEmpty(node.RfidId)) if (node != null && node.HasRfid())
{ {
return node.RfidId; return node.RfidId.ToString("0000");
} }
return $"({nodeId})"; return $"({nodeId})";
} }
@@ -1366,7 +1368,7 @@ namespace AGVSimulator.Forms
{ {
var info = advancedResult.DetailedPath[i]; var info = advancedResult.DetailedPath[i];
var rfidId = GetRfidByNodeId(info.NodeId); var rfidId = GetRfidByNodeId(info.NodeId);
var nextRfidId = info.NextNodeId != null ? GetRfidByNodeId(info.NextNodeId) : "END"; var nextRfidId = info.NextNodeId != null ? GetRfidByNodeId(info.NextNodeId).ToString("0000") : "-END-";
var flags = new List<string>(); var flags = new List<string>();
if (info.CanRotate) flags.Add("회전가능"); if (info.CanRotate) flags.Add("회전가능");
@@ -1616,12 +1618,8 @@ namespace AGVSimulator.Forms
/// </summary> /// </summary>
private string GetNodeDisplayName(MapNode node) private string GetNodeDisplayName(MapNode node)
{ {
if (node == null) if (node == null) return "-";
return "-"; if (node.HasRfid()) return node.RfidId.ToString("0000");
if (!string.IsNullOrEmpty(node.RfidId))
return node.RfidId;
return $"({node.Id})"; return $"({node.Id})";
} }
@@ -1792,7 +1790,7 @@ namespace AGVSimulator.Forms
this.Invoke((MethodInvoker)delegate this.Invoke((MethodInvoker)delegate
{ {
// RFID 텍스트박스에 값 입력 // RFID 텍스트박스에 값 입력
_rfidTextBox.Text = nodeA.RfidId; _rfidTextBox.Text = nodeA.RfidId.ToString();
// 방향 콤보박스 선택 // 방향 콤보박스 선택
SetDirectionComboBox(direction); SetDirectionComboBox(direction);
@@ -1808,7 +1806,7 @@ namespace AGVSimulator.Forms
this.Invoke((MethodInvoker)delegate this.Invoke((MethodInvoker)delegate
{ {
// RFID 텍스트박스에 값 입력 // RFID 텍스트박스에 값 입력
_rfidTextBox.Text = nodeB.RfidId; _rfidTextBox.Text = nodeB.RfidId.ToString();
// 방향 콤보박스 선택 // 방향 콤보박스 선택
SetDirectionComboBox(direction); SetDirectionComboBox(direction);
@@ -2038,9 +2036,9 @@ namespace AGVSimulator.Forms
using (var saveDialog = new SaveFileDialog()) using (var saveDialog = new SaveFileDialog())
{ {
saveDialog.Filter = "AGV Map Files (*.agvmap)|*.agvmap|모든 파일 (*.*)|*.*"; saveDialog.Filter = "AGV Map Files (*.json)|*.json|모든 파일 (*.*)|*.*";
saveDialog.Title = "맵 파일 저장"; saveDialog.Title = "맵 파일 저장";
saveDialog.DefaultExt = "agvmap"; saveDialog.DefaultExt = "json";
// 현재 파일이 있으면 기본 파일명으로 설정 // 현재 파일이 있으면 기본 파일명으로 설정
if (!string.IsNullOrEmpty(_currentMapFilePath)) if (!string.IsNullOrEmpty(_currentMapFilePath))
@@ -2051,7 +2049,7 @@ namespace AGVSimulator.Forms
else else
{ {
// 기본 파일명: 날짜_시간 형식 // 기본 파일명: 날짜_시간 형식
saveDialog.FileName = $"ScanMap_{DateTime.Now:yyyyMMdd_HHmmss}.agvmap"; saveDialog.FileName = $"ScanMap_{DateTime.Now:yyyyMMdd_HHmmss}.json";
} }
if (saveDialog.ShowDialog() == DialogResult.OK) if (saveDialog.ShowDialog() == DialogResult.OK)
@@ -2415,19 +2413,18 @@ namespace AGVSimulator.Forms
catch { } catch { }
} }
public void SendTag(string tagno) public void SendTag(ushort tagno)
{ {
if (_emulatorPort == null || !_emulatorPort.IsOpen) return; if (_emulatorPort == null || !_emulatorPort.IsOpen) return;
tagno = tagno.PadLeft(6, '0'); var tagnostr = tagno.ToString("000000");
if (tagno.Length > 6) tagno = tagno.Substring(0, 6);
var barr = new List<byte>(); var barr = new List<byte>();
barr.Add(0x02); barr.Add(0x02);
barr.Add((byte)'T'); barr.Add((byte)'T');
barr.Add((byte)'A'); barr.Add((byte)'A');
barr.Add((byte)'G'); barr.Add((byte)'G');
barr.AddRange(System.Text.Encoding.Default.GetBytes(tagno)); barr.AddRange(System.Text.Encoding.Default.GetBytes(tagnostr));
barr.Add((byte)'*'); barr.Add((byte)'*');
barr.Add((byte)'*'); barr.Add((byte)'*');
barr.Add(0x03); barr.Add(0x03);

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

View File

@@ -186,6 +186,7 @@
<Compile Include="Device\BMS.cs" /> <Compile Include="Device\BMS.cs" />
<Compile Include="Device\BMSInformationEventArgs.cs" /> <Compile Include="Device\BMSInformationEventArgs.cs" />
<Compile Include="Device\CFlag.cs" /> <Compile Include="Device\CFlag.cs" />
<Compile Include="Device\BMSSerialComm.cs" />
<Compile Include="Device\xbee.cs"> <Compile Include="Device\xbee.cs">
<SubType>Component</SubType> <SubType>Component</SubType>
</Compile> </Compile>
@@ -196,6 +197,12 @@
<Compile Include="Dialog\fCounter.Designer.cs"> <Compile Include="Dialog\fCounter.Designer.cs">
<DependentUpon>fCounter.cs</DependentUpon> <DependentUpon>fCounter.cs</DependentUpon>
</Compile> </Compile>
<Compile Include="Dialog\fXbeeSetting.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Dialog\fXbeeSetting.Designer.cs">
<DependentUpon>fXbeeSetting.cs</DependentUpon>
</Compile>
<Compile Include="Dialog\fStateMachineDebug.cs"> <Compile Include="Dialog\fStateMachineDebug.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
@@ -226,9 +233,6 @@
<Compile Include="Dialog\fSystem.Designer.cs"> <Compile Include="Dialog\fSystem.Designer.cs">
<DependentUpon>fSystem.cs</DependentUpon> <DependentUpon>fSystem.cs</DependentUpon>
</Compile> </Compile>
<Compile Include="Dialog\DriveDetector.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Dialog\fVolume.cs"> <Compile Include="Dialog\fVolume.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
@@ -363,9 +367,6 @@
<Compile Include="StateMachine\_SPS.cs"> <Compile Include="StateMachine\_SPS.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
<Compile Include="Device\_DeviceManagement.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="StateMachine\_Loop.cs"> <Compile Include="StateMachine\_Loop.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>
@@ -423,6 +424,9 @@
<EmbeddedResource Include="Dialog\fCounter.resx"> <EmbeddedResource Include="Dialog\fCounter.resx">
<DependentUpon>fCounter.cs</DependentUpon> <DependentUpon>fCounter.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="Dialog\fXbeeSetting.resx">
<DependentUpon>fXbeeSetting.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Dialog\fUpdateForm.resx"> <EmbeddedResource Include="Dialog\fUpdateForm.resx">
<DependentUpon>fUpdateForm.cs</DependentUpon> <DependentUpon>fUpdateForm.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>

View File

@@ -22,11 +22,31 @@ namespace Project
public Color SMSG_ShadowColor = Color.Transparent; public Color SMSG_ShadowColor = Color.Transparent;
public float SMSG_ProgressValue = 0; public float SMSG_ProgressValue = 0;
public string SMSG_Tag = string.Empty; public string SMSG_Tag = string.Empty;
//public event EventHandler SMSG_Update; /// <summary>
//public void UpdateStatusMessage() /// 이동대상위치(상차,하차,충전)
//{ /// </summary>
// SMSG_Update?.Invoke(null, null); private ePosition _targetPos = ePosition.NONE;
//} public string result_message = "";
public double result_progressmax = 0;
public double result_progressvalue = 0;
public DateTime StopMessageTimePLC = DateTime.Parse("1982-11-23");
public DateTime StopMessageTimeSWR = DateTime.Parse("1982-11-23");
public string StopMessagePLC = string.Empty;
public string StopMessageSWR = string.Empty;
private ePosition _currentpos = ePosition.NONE;
private string _currentposcw = string.Empty;
public ushort LastTAG { get; set; } = 0;
public ePosition NextPos = ePosition.NONE;
private char _comandKit { get; set; }
public string Memo;
public eResult ResultCode { get; set; }
public eECode ResultErrorCode;
public string ResultMessage { get; set; }
public Boolean isError { get; set; }
public int retry = 0;
public DateTime retryTime;
public Device.Socket.Message RecvMessage;
/// <summary> /// <summary>
/// 작업시작시간 /// 작업시작시간
/// </summary> /// </summary>
@@ -52,9 +72,6 @@ namespace Project
} }
} }
//public DateTime ChargeStartTime = DateTime.Parse("1982-11-23");
#region "AGV Status Value" #region "AGV Status Value"
public string PLC1_RawData { get; set; } public string PLC1_RawData { get; set; }
public string PLC2_RawData { get; set; } public string PLC2_RawData { get; set; }
@@ -62,25 +79,7 @@ namespace Project
#endregion #endregion
/// <summary>
/// 이동대상위치(상차,하차,충전)
/// </summary>
private ePosition _targetPos = ePosition.NONE;
public string result_message = "";
public double result_progressmax = 0;
public double result_progressvalue = 0;
public DateTime StopMessageTimePLC = DateTime.Parse("1982-11-23");
public DateTime StopMessageTimeSWR = DateTime.Parse("1982-11-23");
public string StopMessagePLC = string.Empty;
public string StopMessageSWR = string.Empty;
//public DateTime LastChar
//geTime = DateTime.Parse("1982-11-23");
public ePosition NextPos = ePosition.NONE;
public ePosition TargetPos public ePosition TargetPos
{ {
get get
@@ -94,7 +93,7 @@ namespace Project
} }
} }
private char _comandKit { get; set; }
public char CommandKit public char CommandKit
{ {
get get
@@ -110,27 +109,6 @@ namespace Project
} }
//private ePosition _currentPos = ePosition.NONE;
//public ePosition CurrentPos
//{
// get
// {
// return _currentPos;
// }
// set
// {
// if (_currentPos != value) //값이바뀔떄만 메세지 220628
// PUB.log.Add(string.Format("현재위치 설정:{0}->{1}", _currentPos, value));
// _currentPos = value;
// }
//}
private ePosition _currentpos = ePosition.NONE;
private string _currentposcw = string.Empty;
// public ePosition LastPos = ePosition.NONE;
public string LastTAG { get; set; } = string.Empty;
public ePosition CurrentPos public ePosition CurrentPos
{ {
get get
@@ -161,11 +139,7 @@ namespace Project
_currentposcw = value; _currentposcw = value;
} }
} }
public string Memo;
public eResult ResultCode { get; set; }
public eECode ResultErrorCode;
public string ResultMessage { get; set; }
#region "SetResultMessage" #region "SetResultMessage"
@@ -204,13 +178,6 @@ namespace Project
#endregion #endregion
public Boolean isError { get; set; }
public int retry = 0;
public DateTime retryTime;
public Device.Socket.Message RecvMessage;
public CResult() public CResult()
{ {
this.Clear(); this.Clear();

View File

@@ -9,12 +9,12 @@ using System.CodeDom;
namespace arDev namespace arDev
{ {
public class BMS : arRS232 public class BMS : BMSSerialComm
{ {
public BMS() public BMS()
{ {
MinRecvLength = 34;
} }
/// <summary> /// <summary>
@@ -55,28 +55,60 @@ namespace arDev
{ {
tempBuffer.Add(incomByte); tempBuffer.Add(incomByte);
var queylen = QueryIndex == 0 ? 34 : 23; if (tempBuffer.Count > 7)
if (tempBuffer.Count == queylen)
{ {
if (incomByte != 0x77) byte len = tempBuffer[3];
if (tempBuffer.Count >= 4 + len + 3) // Start+Reg+Status+Len + Data + Chk(2) + End
{
if (tempBuffer.Last() == 0x77)
{
//데이터가 맞게 수신됨
LastReceiveBuffer = tempBuffer.ToArray();
bComplete = true;
}
else
{ {
//종단기호가 맞지 않다. 이자료는 폐기한다. //종단기호가 맞지 않다. 이자료는 폐기한다.
var hexstr = string.Join(" ", tempBuffer.Select(t => t.ToString("X2"))); var hexstr = string.Join(" ", tempBuffer.Select(t => t.ToString("X2")));
RaiseMessage(MessageType.Error, $"discard : {hexstr}"); RaiseMessage(MessageType.Error, $"discard : {hexstr}");
tempBuffer.Clear(); tempBuffer.Clear();
} }
else
{
//데이터가 맞게 수신됨
LastReceiveBuffer = tempBuffer.ToArray();
bComplete = true;
}
findSTX = false; findSTX = false;
} }
else
{
//아직 모자르므로 대기한다
} }
// [22 - 12 - 27 14:32:49] open: True
//[22 - 12 - 27 14:32:49] Send: DD A5 03 00 FF FD 77 0D
//[22 - 12 - 27 14:32:50] Send: DD A5 03 00 FF FD 77 0D
//[22 - 12 - 27 14:32:50] Recv: 26.61v,81.4 %
//[22 - 12 - 27 14:32:50] Recv: DD 03 00 1B 0A 65 00 00 21 63 29 04 00 00 2C 92 00 00 00 00 00 00 28 51 03 08 02 0B 69 0B 66 FC 9C 77
//[22 - 12 - 27 14:32:50] Send: DD A5 03 00 FF FD 77 0D
//[22 - 12 - 27 14:32:51] Recv: 26.61v,81.4 %
//[22 - 12 - 27 14:32:51] Recv: DD 03 00 1B 0A 65 00 00 21 63 29 04 00 00 2C 92 00 00 00 00 00 00 28 51 03 08 02 0B 69 0B 66 FC 9C 77
//var queylen = QueryIndex == 0 ? 34 : 23;
//if (tempBuffer.Count == queylen)
//{
// if (incomByte != 0x77)
// {
// //종단기호가 맞지 않다. 이자료는 폐기한다.
// var hexstr = string.Join(" ", tempBuffer.Select(t => t.ToString("X2")));
// RaiseMessage(MessageType.Error, $"discard : {hexstr}");
// tempBuffer.Clear();
// }
// else
// {
// //데이터가 맞게 수신됨
// LastReceiveBuffer = tempBuffer.ToArray();
// bComplete = true;
// }
// findSTX = false;
//}
//else
//{
// //아직 모자르므로 대기한다
//}
} }
} }
} }
@@ -106,7 +138,7 @@ namespace arDev
else else
{ {
var rxstr = string.Join(" ", data.Select(t => t.ToString("X2"))); var rxstr = string.Join(" ", data.Select(t => t.ToString("X2")));
RaiseMessage(MessageType.Recv, $"Querh:{QueryIndex},Data:{rxstr}" ); RaiseMessage(MessageType.Recv, rxstr);
} }
if (QueryIndex == 0) if (QueryIndex == 0)
@@ -179,6 +211,13 @@ namespace arDev
batH = (UInt16)(batH | batL); batH = (UInt16)(batH | batL);
Current_Volt = (float)(batH / 100.0); Current_Volt = (float)(batH / 100.0);
//충방전전류
Int16 batHi = (Int16)LastReceiveBuffer[6];
Int16 batLi = (Int16)LastReceiveBuffer[7];
batHi = (Int16)(batHi << 8);
batHi = (Int16)(batHi | batLi);
Charge_Amp = (float)(batHi / 100.0);
//잔량확인 //잔량확인
batH = (UInt16)LastReceiveBuffer[8]; batH = (UInt16)LastReceiveBuffer[8];
batL = (UInt16)LastReceiveBuffer[9]; batL = (UInt16)LastReceiveBuffer[9];
@@ -224,107 +263,80 @@ namespace arDev
return false; return false;
} }
} }
/// <summary>
private bool _autocharge = false; /// 현재 충전중인지?
public Boolean AutoCharge /// </summary>
{ public bool IsCharging { get; private set; }
get { return _autocharge; } DateTime ChargeStart = DateTime.Now;
set { _autocharge = false; } DateTime ChargeEnd = DateTime.Now;
}
//public void ClearManualChargeCheckValue()
//{
// chk_timee = new DateTime(1982, 11, 23);
// chk_times = new DateTime(1982, 11, 23);
// chk_valuee = 0f;
// chk_values = 0f;
//}
void CheckManualCharge() void CheckManualCharge()
{ {
if (AutoCharge) //충방전전력이 1보다 크면 충전으로 한다.
if (Charge_Amp > 0.1)
{ {
if (chk_timee.Year != 1982) //기존에 충전상태가 OFF였다면 충전중으로 알려준다
if (IsCharging == false)
{ {
chk_timee = new DateTime(1982, 11, 23); IsCharging = true;
chk_valuee = 999f; ChargeStart = DateTime.Now;
} ChargeEnd = new DateTime(1982, 11, 23);
if (chk_times.Year != 1982)
{
chk_times = new DateTime(1982, 11, 23);
chk_values = 999f;
}
}
if (chk_times.Year == 1982)
{
chk_times = DateTime.Now;
chk_values = Current_Level;
}
else
{
if (chk_timee.Year == 1982)
{
if ((Current_Level - chk_values) >= 0.1)
{
//충전중이다
chk_timee = DateTime.Now;
chk_valuee = Current_Level;
try try
{ {
ChargeDetect?.Invoke(this, new ChargetDetectArgs(chk_times, chk_values, chk_timee, chk_valuee)); ChargeDetect?.Invoke(this, new ChargetDetectArgs(ChargeStart, true, Current_Level));
}
catch (Exception ex) { RaiseMessage(MessageType.Error, ex.Message); }
}
else if ((Current_Level - chk_values) <= -0.1)
{
//방전중이다
if (chk_times.Year != 1982) chk_times = new DateTime(1982, 11, 23);
if (chk_timee.Year != 1982) chk_timee = new DateTime(1982, 11, 23);
}
else
{
//아직 변화가 없으니 종료일을 기록하지 않는다
}
}
else
{
//이미 종료일이 셋팅된 상태이다
if ((Current_Level - chk_valuee) >= 0.1)
{
//종료시간을 시작값에 넣는다
chk_times = chk_timee;
chk_values = chk_valuee;
chk_timee = DateTime.Now;
chk_valuee = Current_Level;
try
{
ChargeDetect?.Invoke(this, new ChargetDetectArgs(chk_times, chk_values, chk_timee, chk_valuee));
} }
catch (Exception ex) { RaiseMessage(MessageType.Error, ex.Message); } catch (Exception ex) { RaiseMessage(MessageType.Error, ex.Message); }
} }
else if ((Current_Level - chk_valuee) <= -0.1) else
{ {
//방전중이다 //충전상태가 유지되고 있다.
if (chk_times.Year != 1982) chk_times = new DateTime(1982, 11, 23); }
if (chk_timee.Year != 1982) chk_timee = new DateTime(1982, 11, 23);
} }
else else
{ {
//아직 변화가 없으니 종료일을 기록하지 않는다 //충전이해제되었다.. 단 바로 해제하지않고 1초정도 텀을 주고 OFF한다.
if (IsCharging)
{
if (ChargeEnd.Year == 1982)
{
ChargeEnd = DateTime.Now;
}
else
{
var ts = DateTime.Now - ChargeEnd;
if (ts.TotalSeconds > 2) //충전종료시그널후 2초후에 충전off를 알린다.
{
ChargeEnd = DateTime.Now;
IsCharging = false;
try
{
ChargeDetect?.Invoke(this, new ChargetDetectArgs(ChargeEnd, false, Current_Level));
}
catch (Exception ex) { RaiseMessage(MessageType.Error, ex.Message); }
}
}
}
else
{
//방전상태가 유지되고 있다.
} }
} }
}
}
}
public DateTime chk_times { get; set; } = new DateTime(1982, 11, 23); public DateTime chk_times { get; set; } = new DateTime(1982, 11, 23);
public DateTime chk_timee { get; set; } = new DateTime(1982, 11, 23); public DateTime chk_timee { get; set; } = new DateTime(1982, 11, 23);
public float chk_values { get; set; } = 0f; public float chk_values { get; set; } = 0f;
public float chk_valuee { get; set; } = 0f; public float chk_valuee { get; set; } = 0f;
public float Charge_Amp { get; set; } = 0f;
public Int16 Charge_watt
{
get
{
return (Int16)((Charge_Amp) * Current_Volt);
}
}
/// <summary> /// <summary>
/// 전압 /// 전압
/// </summary> /// </summary>
@@ -407,7 +419,8 @@ namespace arDev
cmd.Add(0xFF); cmd.Add(0xFF);
cmd.Add(0xFD); cmd.Add(0xFD);
cmd.Add(0x77); cmd.Add(0x77);
cmd.Add(0x0D); //cmd.Add(0x0D);
//_device.DiscardInBuffer();
return WriteData(cmd.ToArray()); return WriteData(cmd.ToArray());
} }
@@ -423,7 +436,8 @@ namespace arDev
cmd.Add(0xFF); cmd.Add(0xFF);
cmd.Add(0xFC); cmd.Add(0xFC);
cmd.Add(0x77); cmd.Add(0x77);
cmd.Add(0x0D); //cmd.Add(0x0D);
//_device.DiscardInBuffer();
return WriteData(cmd.ToArray()); return WriteData(cmd.ToArray());
} }

View File

@@ -4,16 +4,14 @@ namespace arDev
{ {
public class ChargetDetectArgs : EventArgs public class ChargetDetectArgs : EventArgs
{ {
public DateTime times { get; set; } public DateTime time { get; set; }
public DateTime timee { get; set; } public float level { get; set; }
public float values { get; set; } public bool Detected { get; set; }
public float valuee { get; set; } public ChargetDetectArgs(DateTime times, bool detected, float values)
public ChargetDetectArgs(DateTime times, float values, DateTime timee, float valuee)
{ {
this.times = times; this.time = times;
this.times = timee; this.level = values;
this.values = values; this.Detected = detected;
this.valuee = valuee;
} }
} }
public class BMSInformationEventArgs : EventArgs public class BMSInformationEventArgs : EventArgs

View File

@@ -0,0 +1,607 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading;
namespace arDev
{
public abstract class BMSSerialComm : ISerialComm, IDisposable
{
protected System.IO.Ports.SerialPort _device;
protected ManualResetEvent _mre;
protected byte[] LastReceiveBuffer = new byte[] { };
/// <summary>
/// 최종 전송 메세지
/// </summary>
public byte[] lastSendBuffer = new byte[] { };
//public int ValidCheckTimeMSec { get; set; } = 5000;
protected List<byte> tempBuffer = new List<byte>();
protected Boolean findSTX = false;
public string ErrorMessage { get; set; }
public DateTime LastConnTime { get; set; }
public DateTime LastConnTryTime { get; set; }
public DateTime lastSendTime;
/// <summary>
/// 메세지 수신시 사용하는 내부버퍼
/// </summary>
protected List<byte> _buffer = new List<byte>();
/// <summary>
/// 데이터조회간격(초)
/// </summary>
public float ScanInterval { get; set; }
// public byte[] LastRecvData;
public string LastRecvString
{
get
{
if (LastReceiveBuffer == null) return String.Empty;
else return System.Text.Encoding.Default.GetString(LastReceiveBuffer);
}
}
/// <summary>
/// 마지막으로 데이터를 받은 시간
/// </summary>
public DateTime lastRecvTime;
public int WriteError = 0;
public string WriteErrorMessage = string.Empty;
public int WaitTimeout { get; set; } = 1000;
public int MinRecvLength { get; set; } = 1;
// Polling Thread related
protected Thread _recvThread;
protected volatile bool _isReading = false;
/// <summary>
/// 포트이름
/// </summary>
[Description("시리얼 포트 이름")]
[Category("설정"), DisplayName("Port Name")]
public string PortName
{
get
{
if (_device == null) return string.Empty;
else return _device.PortName;
}
set
{
if (this.IsOpen)
{
Message?.Invoke(this, new MessageEventArgs("포트가 열려있어 포트이름을 변경할 수 없습니다", true));
}
else if (String.IsNullOrEmpty(value) == false)
_device.PortName = value;
else
{
Message?.Invoke(this, new MessageEventArgs("No PortName", true));
}
}
}
public int BaudRate
{
get
{
if (_device == null) return 0;
else return _device.BaudRate;
}
set
{
if (this.IsOpen)
{
Message?.Invoke(this, new MessageEventArgs("포트가 열려있어 BaudRate(를) 변경할 수 없습니다", true));
}
else if (value != 0)
_device.BaudRate = value;
else Message?.Invoke(this, new MessageEventArgs("No baud rate", true));
}
}
public BMSSerialComm()
{
_device = new System.IO.Ports.SerialPort();
this.BaudRate = 9600;
ScanInterval = 10;
// _device.DataReceived += barcode_DataReceived; // Removed event handler
_device.ErrorReceived += this.barcode_ErrorReceived;
_device.WriteTimeout = 3000;
_device.ReadTimeout = 3000;
_device.ReadBufferSize = 8192;
_device.WriteBufferSize = 8192;
//_device.DiscardInBuffer();
//_device.DiscardOutBuffer();
ErrorMessage = string.Empty;
lastRecvTime = DateTime.Parse("1982-11-23");
LastConnTime = DateTime.Parse("1982-11-23");
LastConnTryTime = DateTime.Parse("1982-11-23");
lastRecvTime = DateTime.Parse("1982-11-23");
this._mre = new ManualResetEvent(true);
}
~BMSSerialComm()
{
Dispose(false);
}
// Flag: Has Dispose already been called?
bool disposed = false;
// Public implementation of Dispose pattern callable by consumers.
public void Dispose()
{
Dispose(true);
GC.SuppressFinalize(this);
}
// Protected implementation of Dispose pattern.
protected virtual void Dispose(bool disposing)
{
if (disposed)
return;
if (disposing)
{
// Free any other managed objects here.
//
}
// Stop reading thread
_isReading = false;
// _device.DataReceived -= barcode_DataReceived; // Removed event handler
_device.ErrorReceived -= this.barcode_ErrorReceived;
if (_recvThread != null && _recvThread.IsAlive)
{
_recvThread.Join(500);
}
if (_device != null)
{
if (_device.IsOpen) _device.Close();
_device.Dispose();
}
// Free any unmanaged objects here.
//
disposed = true;
}
public Boolean Open()
{
try
{
if (_device.IsOpen == false)
{
_device.Open();
}
if (_device.IsOpen)
{
// Start polling thread
if (_isReading == false)
{
_isReading = true;
_recvThread = new Thread(ReadPort);
_recvThread.IsBackground = true;
_recvThread.Start();
}
return true;
}
return false;
}
catch (Exception ex)
{
ErrorMessage = ex.Message;
Message.Invoke(this, new MessageEventArgs(ex.Message, true));
return false;
}
}
public string GetHexString(Byte[] input)
{
System.Text.StringBuilder sb = new System.Text.StringBuilder();
foreach (byte b in input)
sb.Append(" " + b.ToString("X2"));
return sb.ToString();
}
/// <summary>
/// 포트가 열려있는지 확인
/// </summary>
[Description("현재 시리얼포트가 열려있는지 확인합니다")]
[Category("정보"), DisplayName("Port Open")]
public Boolean IsOpen
{
get
{
if (_device == null) return false;
return _device.IsOpen;
}
}
public virtual bool Close()
{
try
{
_isReading = false; // Stop thread loop
if (_recvThread != null && _recvThread.IsAlive)
{
if (!_recvThread.Join(500)) // Wait for thread to finish
{
// _recvThread.Abort(); // Avoid Abort if possible
}
}
if (_device != null && _device.IsOpen)
{
_device.DiscardInBuffer();
_device.DiscardOutBuffer();
_device.Close(); //dispose에서는 포트를 직접 클리어하지 않게 해뒀다.
return true;
}
else return false;
}
catch (Exception)
{
return false;
}
}
protected Boolean RaiseRecvData()
{
return RaiseRecvData(LastReceiveBuffer.ToArray(), false);
}
/// <summary>
/// 수신받은 메세지를 발생 시킵니다
/// </summary>
/// <param name="data"></param>
/// <returns></returns>
public virtual Boolean RaiseRecvData(byte[] Data, bool udpatelastbuffer)
{
//181206 - 최종수신 메세지 기록
lastRecvTime = DateTime.Now;
if (udpatelastbuffer && Data != null)
{
if (LastReceiveBuffer == null || LastReceiveBuffer.Length != Data.Length)
{
LastReceiveBuffer = new byte[Data.Length];
Array.Copy(Data, LastReceiveBuffer, Data.Length);
}
}
try
{
// UI update might need Invoke if this event handler updates UI directly,
// but usually the subscriber handles Invoke.
// Since we are running on a background thread now, subscribers must be aware.
Message?.Invoke(this, new MessageEventArgs(Data, true)); //recvmessage
if (ProcessRecvData(Data) == false)
{
//Message?.Invoke(this, new MessageEventArgs(Data, true)); //recvmessage
Message?.Invoke(this, new MessageEventArgs(this.ErrorMessage, true)); //errormessage
return false;
}
else
{
return true;
}
}
catch (Exception ex)
{
this.ErrorMessage = ex.Message;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
return false;
}
}
/// <summary>
/// 수신받은 자료를 처리한다
/// </summary>
/// <param name="data"></param>
/// <returns></returns>
public abstract bool ProcessRecvData(byte[] data);
#region "Internal Events"
void barcode_ErrorReceived(object sender, System.IO.Ports.SerialErrorReceivedEventArgs e)
{
Message?.Invoke(this, new MessageEventArgs(e.ToString(), true));
}
byte[] buffer = new byte[] { };
// Replaced with ReadPort Loop
/*
void barcode_DataReceived(object sender, System.IO.Ports.SerialDataReceivedEventArgs e)
{
try
{
int ReadCount = _device.BytesToRead;
buffer = new byte[ReadCount];
_device.Read(buffer, 0, buffer.Length);
System.Text.StringBuilder LogMsg = new StringBuilder();
byte[] remainBuffer;
Repeat:
if (CustomParser(buffer, out remainBuffer))
{
//분석완료이므로 받은 데이터를 버퍼에 기록한다
if (LastReceiveBuffer == null || (LastReceiveBuffer.Length != tempBuffer.Count))
Array.Resize(ref LastReceiveBuffer, tempBuffer.Count);
Array.Copy(tempBuffer.ToArray(), LastReceiveBuffer, tempBuffer.Count);
tempBuffer.Clear();
//수신메세지발생
RaiseRecvData();
if (remainBuffer != null && remainBuffer.Length > 0)
{
//버퍼를 변경해서 다시 전송을 해준다.
Array.Resize(ref buffer, remainBuffer.Length);
Array.Copy(remainBuffer, buffer, remainBuffer.Length);
goto Repeat; //남은 버퍼가 있다면 진행을 해준다.
}
}
}
catch (Exception ex)
{
//if (IsOpen)
//{
// //_device.DiscardInBuffer();
// //_device.DiscardOutBuffer();
//}
ErrorMessage = ex.Message;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
}
}
*/
void ReadPort()
{
while (_isReading)
{
try
{
if (_device == null || !_device.IsOpen)
{
Thread.Sleep(100);
continue;
}
int readCount = _device.BytesToRead;
if (readCount > 0)
{
byte[] buffer = new byte[readCount];
_device.Read(buffer, 0, buffer.Length);
byte[] remainBuffer;
Repeat:
if (CustomParser(buffer, out remainBuffer))
{
//분석완료이므로 받은 데이터를 버퍼에 기록한다
if (LastReceiveBuffer == null || (LastReceiveBuffer.Length != tempBuffer.Count))
Array.Resize(ref LastReceiveBuffer, tempBuffer.Count);
Array.Copy(tempBuffer.ToArray(), LastReceiveBuffer, tempBuffer.Count);
tempBuffer.Clear();
//수신메세지발생
RaiseRecvData();
if (remainBuffer != null && remainBuffer.Length > 0)
{
//버퍼를 변경해서 다시 전송을 해준다.
buffer = new byte[remainBuffer.Length]; // Reallocate buffer for remaining data
Array.Copy(remainBuffer, buffer, remainBuffer.Length);
goto Repeat; //남은 버퍼가 있다면 진행을 해준다.
}
}
}
else
{
Thread.Sleep(20); // Data 없음, 대기
}
}
catch (Exception ex)
{
// Thread 상에서 Exception 발생 시 로그 남기고 계속 진행 여부 결정
// 여기서는 에러 메시지 발생시키고 Sleep
ErrorMessage = ex.Message;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
Thread.Sleep(1000);
}
}
}
#endregion
#region "External Events"
/// <summary>
/// 오류 및 기타 일반 메세지
/// </summary>
public event EventHandler<MessageEventArgs> Message;
#endregion
#region "Event Args"
/// <summary>
/// 데이터를 수신할떄 사용함(RAW 포함)
/// </summary>
public class ReceiveDataEventArgs : EventArgs
{
private byte[] _buffer = null;
/// <summary>
/// 바이트배열의 버퍼값
/// </summary>
public byte[] Value { get { return _buffer; } }
/// <summary>
/// 버퍼(바이트배열)의 데이터를 문자로 반환합니다.
/// </summary>
public string StrValue
{
get
{
//return string.Empty;
if (_buffer == null || _buffer.Length < 1) return string.Empty;
else return System.Text.Encoding.Default.GetString(_buffer);
}
}
public ReceiveDataEventArgs(byte[] buffer)
{
_buffer = buffer;
}
}
/// <summary>
/// 메세지를 강제 발생
/// </summary>
/// <param name="mt"></param>
/// <param name="message"></param>
protected virtual void RaiseMessage(MessageType mt, string message)
{
this.Message?.Invoke(this, new MessageEventArgs(mt, message));
}
public enum MessageType
{
Normal,
Error,
Send,
Recv,
}
public class MessageEventArgs : EventArgs
{
public MessageType MsgType { get; set; }
private string _message = string.Empty;
/// <summary>
/// Recv,Send,Normal,Error 모두 지원
/// </summary>
public string Message { get { return _message; } }
private byte[] _data = null;
/// <summary>
/// Recv,Send에서만 값이 존재 합니다
/// </summary>
public byte[] Data { get { return _data; } }
public MessageEventArgs(string Message, bool isError = false)
{
if (isError) MsgType = MessageType.Error;
else MsgType = MessageType.Normal;
_message = Message;
}
public MessageEventArgs(MessageType msgtype, string Message)
{
MsgType = msgtype;
_message = Message;
_data = System.Text.Encoding.Default.GetBytes(Message);
}
public MessageEventArgs(byte[] buffer, bool isRecv = true)
{
if (isRecv) MsgType = MessageType.Recv;
else MsgType = MessageType.Send;
_data = new byte[buffer.Length];
Array.Copy(buffer, _data, Data.Length);
_message = System.Text.Encoding.Default.GetString(_data);
}
}
#endregion
protected abstract bool CustomParser(byte[] buf, out byte[] remainBuffer);
/// <summary>
/// 포트가 열려있거나 데이터 수신시간이 없는경우 false를 반환합니다
/// </summary>
public Boolean IsValid
{
get
{
if (IsOpen == false) return false;
if (lastRecvTime.Year == 1982) return false;
var ts = DateTime.Now - lastRecvTime;
if (ts.TotalSeconds > (this.ScanInterval * 2.5)) return false;
return true;
}
}
protected bool WriteData(string cmd)
{
return WriteData(System.Text.Encoding.Default.GetBytes(cmd));
}
/// <summary>
/// 포트에 쓰기(barcode_DataReceived 이벤트로 메세지수신)
/// </summary>
protected Boolean WriteData(byte[] data)
{
Boolean bRet = false;
//171205 : 타임아웃시간추가
if (!_mre.WaitOne(WaitTimeout))
{
ErrorMessage = $"WriteData:MRE:WaitOne:TimeOut {WaitTimeout}ms";
this.Message?.Invoke(this, new MessageEventArgs(ErrorMessage, true));
return false;
}
_mre.Reset();
//Array.Resize(ref data, data.Length + 2);
try
{
lastSendTime = DateTime.Now;
if (lastSendBuffer == null) lastSendBuffer = new byte[data.Length]; //171113
else Array.Resize(ref lastSendBuffer, data.Length);
Array.Copy(data, lastSendBuffer, data.Length);
for (int i = 0; i < data.Length; i++)
_device.Write(data, i, 1);
//_device.Write(data, 0, data.Length);
//171113
this.Message?.Invoke(this, new MessageEventArgs(data, false));
bRet = true;
WriteError = 0;
WriteErrorMessage = string.Empty;
}
catch (Exception ex)
{
// this.isinit = false;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
bRet = false;
WriteError += 1; //연속쓰기오류횟수
WriteErrorMessage = ex.Message;
}
finally
{
_mre.Set();
}
return bRet;
}
}
}

View File

@@ -14,11 +14,11 @@ using System.Windows.Forms;
namespace Project.Device namespace Project.Device
{ {
public class Xbee : SerialPort public class Xbee : SerialPort, arDev.ISerialComm
{ {
public string buffer = string.Empty; public string buffer = string.Empty;
public System.Text.StringBuilder newbuffer = new StringBuilder(); public System.Text.StringBuilder newbuffer = new StringBuilder();
public string errorMessage = string.Empty; public string ErrorMessage { get; set; } = string.Empty;
public DateTime LastStatusSendTime { get; set; } = DateTime.Now; public DateTime LastStatusSendTime { get; set; } = DateTime.Now;
private EEProtocol proto; private EEProtocol proto;
@@ -38,6 +38,8 @@ namespace Project.Device
public Xbee() public Xbee()
{ {
this.WriteTimeout = 500;
this.ReadTimeout = 500;
this.DataReceived += Xbee_DataReceived; this.DataReceived += Xbee_DataReceived;
proto = new EEProtocol(); proto = new EEProtocol();
proto.OnDataReceived += Proto_OnDataReceived; proto.OnDataReceived += Proto_OnDataReceived;
@@ -65,11 +67,23 @@ namespace Project.Device
} }
catch (Exception ex) catch (Exception ex)
{ {
errorMessage = ex.Message; ErrorMessage = ex.Message;
return false; return false;
} }
} }
public new bool Close()
{
try
{
base.Close();
return true;
}
catch
{
return false;
}
}
public new bool Open() public new bool Open()
{ {
try try
@@ -79,8 +93,8 @@ namespace Project.Device
} }
catch (Exception ex) catch (Exception ex)
{ {
errorMessage = ex.Message; ErrorMessage = ex.Message;
PUB.logxbee.AddE(errorMessage); PUB.logxbee.AddE(ErrorMessage);
return false; return false;
} }
} }
@@ -92,19 +106,14 @@ namespace Project.Device
var cmd = e.ReceivedPacket.Command.ToString("X2"); var cmd = e.ReceivedPacket.Command.ToString("X2");
var id = e.ReceivedPacket.ID.ToString("X2"); var id = e.ReceivedPacket.ID.ToString("X2");
PUB.logxbee.Add("RX", $"{hexstrRaw}\nID:{id},CMD:{cmd},DATA:{hexstr}"); PUB.logxbee.Add("RX", $"{hexstrRaw}\nID:{id},CMD:{cmd},DATA:{hexstr}");
ProtocReceived?.Invoke(this, e); ProtocReceived?.Invoke(this, e);
} }
private void Proto_OnMessage(object sender, EEProtocol.MessageEventArgs e) private void Proto_OnMessage(object sender, EEProtocol.MessageEventArgs e)
{ {
MessageReceived?.Invoke(this, new MessageArgs(e.IsError, e.Message)); MessageReceived?.Invoke(this, new MessageArgs(e.IsError, e.Message));
} }
private void Xbee_DataReceived(object sender, System.IO.Ports.SerialDataReceivedEventArgs e) private void Xbee_DataReceived(object sender, System.IO.Ports.SerialDataReceivedEventArgs e)
{ {
var dev = sender as System.IO.Ports.SerialPort; var dev = sender as System.IO.Ports.SerialPort;
@@ -112,6 +121,7 @@ namespace Project.Device
dev.Read(buffer, 0, buffer.Length); dev.Read(buffer, 0, buffer.Length);
proto.ProcessReceivedData(buffer); proto.ProcessReceivedData(buffer);
} }
/// <summary> /// <summary>
/// 이동완료 신호 전송 /// 이동완료 신호 전송
/// </summary> /// </summary>
@@ -147,10 +157,12 @@ namespace Project.Device
byte cmd = (byte)ENIGProtocol.AGVCommandEH.Error; byte cmd = (byte)ENIGProtocol.AGVCommandEH.Error;
if (errormessage.Length > 30) errormessage = errormessage.Substring(0, 29); if (errormessage.Length > 30) errormessage = errormessage.Substring(0, 29);
var data = new byte[] { (byte)errcode }; var data = new List<byte>();
data.Add((byte)errcode);
var datamsg = System.Text.Encoding.Default.GetBytes(errormessage); var datamsg = System.Text.Encoding.Default.GetBytes(errormessage);
data.AddRange(datamsg);
var packet = proto.CreatePacket(id, cmd, data); var packet = proto.CreatePacket(id, cmd, data.ToArray());
Send(packet); Send(packet);
} }
@@ -166,12 +178,18 @@ namespace Project.Device
public bool CleanerInComplete { get; set; } public bool CleanerInComplete { get; set; }
public bool CleanerOutComplete { get; set; } public bool CleanerOutComplete { get; set; }
ManualResetEvent sendlock = new ManualResetEvent(true);
/// <summary> /// <summary>
/// AGV상태를 Xbee 로 전송한다 /// AGV상태를 Xbee 로 전송한다
/// </summary> /// </summary>
public void SendStatus() public void SendStatus()
{ {
if (this.IsOpen == false) return;
if (sendlock.WaitOne() == false) return;
sendlock.Reset();
/* /*
Mode[1] : 0=manual, 1=auto Mode[1] : 0=manual, 1=auto
RunSt[1] : 0=stop, 1=run, 2=error RunSt[1] : 0=stop, 1=run, 2=error
@@ -222,17 +240,17 @@ namespace Project.Device
data[5] = (byte)((VAR.BOOL[eVarBool.FLAG_CHARGEONA] || VAR.BOOL[eVarBool.FLAG_CHARGEONM]) ? 1 : 0); data[5] = (byte)((VAR.BOOL[eVarBool.FLAG_CHARGEONA] || VAR.BOOL[eVarBool.FLAG_CHARGEONM]) ? 1 : 0);
// CartSt // CartSt
if (PUB.AGV.signal.cart_detect1 && PUB.AGV.signal.cart_detect2) if (PUB.AGV.signal2.cart_detect1 && PUB.AGV.signal2.cart_detect2)
data[6] = 1; // 센서두개가 모두 감지되는 경우 data[6] = 1; // 센서두개가 모두 감지되는 경우
else if (PUB.AGV.signal.cart_detect1 == false && PUB.AGV.signal.cart_detect2 == false) else if (PUB.AGV.signal2.cart_detect1 == false && PUB.AGV.signal2.cart_detect2 == false)
data[6] = 0; // 센서두개가 모두 감지되지 않는 경우 data[6] = 0; // 센서두개가 모두 감지되지 않는 경우
else else
data[6] = 2; // 센서하나만 감지되는 경우 data[6] = 2; // 센서하나만 감지되는 경우
// LiftSt // LiftSt
if (PUB.AGV.signal.lift_up) if (PUB.AGV.signal1.lift_up)
data[7] = 1; // 위로 올라가는 경우 data[7] = 1; // 위로 올라가는 경우
else if (PUB.AGV.signal.lift_down) else if (PUB.AGV.signal1.lift_down)
data[7] = 0; // 아래로 내려가는 경우 data[7] = 0; // 아래로 내려가는 경우
else else
data[7] = 2; // unknown (기본값) data[7] = 2; // unknown (기본값)
@@ -246,14 +264,21 @@ namespace Project.Device
var cmd = (byte)ENIGProtocol.AGVCommandEH.Status; var cmd = (byte)ENIGProtocol.AGVCommandEH.Status;
var packet = proto.CreatePacket(PUB.setting.XBE_ID, cmd, data); var packet = proto.CreatePacket(PUB.setting.XBE_ID, cmd, data);
if (Send(packet)) if (Send(packet))
PUB.logxbee.AddI($"Send status {packet.Length} {packet.HexString()}"); PUB.logxbee.AddI($"Send status [O] : {packet.Length} {packet.HexString()}");
else
PUB.logxbee.AddE($"Send status [X] : {packet.Length} {packet.HexString()}");
LastStatusSendTime = DateTime.Now; LastStatusSendTime = DateTime.Now;
} }
catch (Exception ex) catch (Exception ex)
{ {
errorMessage = ex.Message; ErrorMessage = ex.Message;
PUB.logxbee.AddE(errorMessage); PUB.logxbee.AddE(ErrorMessage);
} }
finally
{
sendlock.Set();
}
} }

View File

@@ -1,323 +0,0 @@
using System;
using System.Collections.Generic;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Media.Animation;
using AR;
using arCtl;
using COMM;
using Project.StateMachine;
namespace Project
{
/// <summary>
/// 장치 연결 및 상태 전송을 담당하는 별도 태스크
/// </summary>
public partial class fMain
{
// 장치 관리 태스크 관련
private Task deviceManagementTask;
private CancellationTokenSource deviceManagementCts;
private volatile bool isDeviceManagementRunning = false;
/// <summary>
/// 장치 관리 태스크 시작 (IDLE 상태 진입 시 호출)
/// </summary>
public void StartDeviceManagementTask()
{
if (isDeviceManagementRunning)
{
PUB.log.Add("DeviceManagement", "이미 실행 중입니다.");
return;
}
isDeviceManagementRunning = true;
deviceManagementCts = new CancellationTokenSource();
deviceManagementTask = Task.Factory.StartNew(
() => DeviceManagementWorker(deviceManagementCts.Token),
deviceManagementCts.Token,
TaskCreationOptions.LongRunning,
TaskScheduler.Default
);
PUB.log.Add("DeviceManagement", "장치 관리 태스크 시작");
}
/// <summary>
/// 장치 관리 태스크 종료
/// File : /device/_DeviceManagement.cs
/// </summary>
public void StopDeviceManagementTask()
{
if (!isDeviceManagementRunning)
return;
isDeviceManagementRunning = false;
try
{
deviceManagementCts?.Cancel();
if (deviceManagementTask != null)
{
if (!deviceManagementTask.Wait(3000)) // 3초 대기
{
PUB.log.AddE("DeviceManagement:태스크 종료 대기 시간 초과");
}
}
}
catch (Exception ex)
{
PUB.log.AddE($"DeviceManagement 종료 중 오류: {ex.Message}");
}
finally
{
deviceManagementCts?.Dispose();
deviceManagementCts = null;
deviceManagementTask = null;
PUB.log.Add("DeviceManagement", "장치 관리 태스크 종료");
}
}
/// <summary>
/// 장치 관리 워커 (별도 태스크에서 실행)
/// - 장치 연결 관리 (AGV, XBee, BMS)
/// - 자동 상태 전송 (XBee, BMS)
/// </summary>
private void DeviceManagementWorker(CancellationToken cancellationToken)
{
PUB.log.Add("DeviceManagementWorker", "시작");
DateTime lastXbeStatusSendTime = DateTime.Now;
DateTime lastBmsQueryTime = DateTime.Now;
while (!cancellationToken.IsCancellationRequested && isDeviceManagementRunning)
{
try
{
// 상태머신이 IDLE 이상이고 CLOSING 미만일 때만 동작
if (PUB.sm.Step >= eSMStep.IDLE && PUB.sm.Step < eSMStep.CLOSING)
{
// ========== 1. 장치 연결 관리 ==========
ManageDeviceConnections();
// ========== 2. XBee 상태 전송 ==========
if (PUB.XBE != null && PUB.XBE.IsOpen)
{
var tsXbe = DateTime.Now - lastXbeStatusSendTime;
if (tsXbe.TotalSeconds >= PUB.setting.interval_xbe)
{
lastXbeStatusSendTime = DateTime.Now;
ThreadPool.QueueUserWorkItem(_ =>
{
try
{
PUB.XBE.SendStatus();
}
catch (Exception ex)
{
PUB.log.AddE($"XBee SendStatus 오류: {ex.Message}");
}
});
}
}
// ========== 3. BMS 쿼리 및 배터리 경고 ==========
if (PUB.BMS != null && PUB.BMS.IsOpen)
{
var tsBms = DateTime.Now - lastBmsQueryTime;
if (tsBms.TotalSeconds >= PUB.setting.interval_bms)
{
lastBmsQueryTime = DateTime.Now;
ThreadPool.QueueUserWorkItem(_ =>
{
try
{
PUB.BMS.SendQuery();
}
catch (Exception ex)
{
PUB.log.AddE($"BMS SendQuery 오류: {ex.Message}");
}
});
}
// 배터리 경고음
try
{
Update_BatteryWarnSpeak();
}
catch (Exception ex)
{
PUB.log.AddE($"BatteryWarnSpeak 오류: {ex.Message}");
}
}
}
}
catch (Exception ex)
{
PUB.log.AddE($"DeviceManagementWorker 오류: {ex.Message}");
}
// 1초 대기 (또는 취소 요청 시 즉시 종료)
try
{
Task.Delay(1000, cancellationToken).Wait();
}
catch (OperationCanceledException)
{
break;
}
}
PUB.log.Add("DeviceManagementWorker", "종료");
}
/// <summary>
/// 장치 연결 상태 관리
/// </summary>
private void ManageDeviceConnections()
{
try
{
// AGV 연결
ConnectSerialPort(PUB.AGV, PUB.setting.Port_AGV, PUB.setting.Baud_AGV,
eVarTime.LastConn_AGV, eVarTime.LastConnTry_AGV, eVarTime.LastRecv_AGV);
// XBee 연결
ConnectSerialPort(PUB.XBE, PUB.setting.Port_XBE, PUB.setting.Baud_XBE,
eVarTime.LastConn_XBE, eVarTime.LastConnTry_XBE, eVarTime.LastRecv_XBE);
// BMS 연결
if (PUB.BMS.IsOpen == false)
{
var ts = VAR.TIME.RUN(eVarTime.LastConn_BAT);
if (ts.TotalSeconds > 3)
{
PUB.log.Add($"BMS 연결 시도: {PUB.setting.Port_BAT}");
PUB.BMS.PortName = PUB.setting.Port_BAT;
if (PUB.BMS.Open())
PUB.log.AddI($"BMS 연결 완료({PUB.setting.Port_BAT})");
VAR.TIME.Update(eVarTime.LastConn_BAT);
VAR.TIME.Update(eVarTime.LastConnTry_BAT);
}
}
else if (PUB.BMS.IsValid == false)
{
var ts = VAR.TIME.RUN(eVarTime.LastConnTry_BAT);
if (ts.TotalSeconds > (PUB.setting.interval_bms * 2.5))
{
PUB.log.Add("BMS 자동 연결 해제 (응답 없음)");
PUB.BMS.Close();
VAR.TIME.Set(eVarTime.LastConn_BAT, DateTime.Now.AddSeconds(5));
}
}
}
catch (Exception ex)
{
PUB.log.AddE($"ManageDeviceConnections 오류: {ex.Message}");
}
}
/// <summary>
/// 시리얼 포트 연결 (arDev.arRS232)
/// </summary>
bool ConnectSerialPort(arDev.arRS232 dev, string port, int baud, eVarTime conn, eVarTime conntry, eVarTime recvtime)
{
if(port.isEmpty()) return false;
if (dev.IsOpen == false && port.isEmpty() == false)
{
var tsPLC = VAR.TIME.RUN(conntry);
if (tsPLC.TotalSeconds > 5)
{
VAR.TIME.Update(conntry);
try
{
VAR.TIME.Update(recvtime);
dev.PortName = port;
dev.BaudRate = baud;
if (dev.Open())
{
PUB.log.Add(port, $"[AGV:{port}:{baud}] 연결 완료");
}
else
{
//존재하지 않는 포트라면 sync를 벗어난다
var ports = System.IO.Ports.SerialPort.GetPortNames().Select(t => t.ToLower()).ToList();
if (ports.Contains(PUB.setting.Port_AGV.ToLower()) == false)
{
return false;
}
else
{
var errmessage = dev.errorMessage;
PUB.log.AddE($"[AGV:{port}:{baud}] {errmessage}");
}
}
VAR.TIME.Update(conn);
VAR.TIME.Update(conntry);
}
catch (Exception ex)
{
PUB.log.AddE(ex.Message);
}
}
}
else if (dev.PortName.Equals(port) == false)
{
PUB.log.Add(port, $"포트 변경({dev.PortName}->{port})으로 연결 종료");
dev.Close();
VAR.TIME.Update(conntry);
}
return true;
}
/// <summary>
/// 시리얼 포트 연결 (Device.Xbee)
/// </summary>
void ConnectSerialPort(Device.Xbee dev, string port, int baud, eVarTime conn, eVarTime conntry, eVarTime recvtime)
{
if (dev.IsOpen == false && port.isEmpty() == false)
{
var tsPLC = VAR.TIME.RUN(conntry);
if (tsPLC.TotalSeconds > 5)
{
VAR.TIME.Update(conntry);
try
{
VAR.TIME.Update(recvtime);
dev.PortName = port;
dev.BaudRate = baud;
if (dev.Open())
{
PUB.log.Add(port, $"[XBEE:{port}:{baud}] 연결 완료");
}
else
{
var errmessage = dev.errorMessage;
PUB.log.AddE($"[XBEE:{port}:{baud}] {errmessage}");
}
VAR.TIME.Update(conn);
VAR.TIME.Update(conntry);
}
catch (Exception ex)
{
PUB.log.AddE(ex.Message);
}
}
}
else if (dev.PortName.Equals(port) == false)
{
PUB.log.Add(port, $"포트 변경({dev.PortName}->{port})으로 연결 종료");
dev.Close();
VAR.TIME[(int)conntry] = DateTime.Now;
}
}
}
}

View File

@@ -1,815 +0,0 @@
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms; // required for Message
using System.Runtime.InteropServices; // required for Marshal
using System.IO;
using Microsoft.Win32.SafeHandles;
// DriveDetector - rev. 1, Oct. 31 2007
namespace usbdetect
{
/// <summary>
/// Hidden Form which we use to receive Windows messages about flash drives
/// </summary>
internal class DetectorForm : Form
{
private Label label1;
private DriveDetector mDetector = null;
/// <summary>
/// Set up the hidden form.
/// </summary>
/// <param name="detector">DriveDetector object which will receive notification about USB drives, see WndProc</param>
public DetectorForm(DriveDetector detector)
{
mDetector = detector;
this.MinimizeBox = false;
this.MaximizeBox = false;
this.ShowInTaskbar = false;
this.ShowIcon = false;
this.FormBorderStyle = FormBorderStyle.None;
this.Load += new System.EventHandler(this.Load_Form);
this.Activated += new EventHandler(this.Form_Activated);
}
private void Load_Form(object sender, EventArgs e)
{
// We don't really need this, just to display the label in designer ...
InitializeComponent();
// Create really small form, invisible anyway.
this.Size = new System.Drawing.Size(5, 5);
}
private void Form_Activated(object sender, EventArgs e)
{
this.Visible = false;
}
/// <summary>
/// This function receives all the windows messages for this window (form).
/// We call the DriveDetector from here so that is can pick up the messages about
/// drives arrived and removed.
/// </summary>
protected override void WndProc(ref Message m)
{
base.WndProc(ref m);
if (mDetector != null)
{
mDetector.WndProc(ref m);
}
}
private void InitializeComponent()
{
this.label1 = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(13, 30);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(377, 12);
this.label1.TabIndex = 0;
this.label1.Text = "This is invisible form. To see DriveDetector code click View Code";
//
// DetectorForm
//
this.ClientSize = new System.Drawing.Size(435, 80);
this.Controls.Add(this.label1);
this.Name = "DetectorForm";
this.ResumeLayout(false);
this.PerformLayout();
}
} // class DetectorForm
// Delegate for event handler to handle the device events
public delegate void DriveDetectorEventHandler(Object sender, DriveDetectorEventArgs e);
/// <summary>
/// Our class for passing in custom arguments to our event handlers
///
/// </summary>
public class DriveDetectorEventArgs : EventArgs
{
public DriveDetectorEventArgs()
{
Cancel = false;
Drive = "";
HookQueryRemove = false;
}
/// <summary>
/// Get/Set the value indicating that the event should be cancelled
/// Only in QueryRemove handler.
/// </summary>
public bool Cancel;
/// <summary>
/// Drive letter for the device which caused this event
/// </summary>
public string Drive;
/// <summary>
/// Set to true in your DeviceArrived event handler if you wish to receive the
/// QueryRemove event for this drive.
/// </summary>
public bool HookQueryRemove;
}
/// <summary>
/// Detects insertion or removal of removable drives.
/// Use it in 1 or 2 steps:
/// 1) Create instance of this class in your project and add handlers for the
/// DeviceArrived, DeviceRemoved and QueryRemove events.
/// AND (if you do not want drive detector to creaate a hidden form))
/// 2) Override WndProc in your form and call DriveDetector's WndProc from there.
/// If you do not want to do step 2, just use the DriveDetector constructor without arguments and
/// it will create its own invisible form to receive messages from Windows.
/// </summary>
class DriveDetector : IDisposable
{
/// <summary>
/// Events signalized to the client app.
/// Add handlers for these events in your form to be notified of removable device events
/// </summary>
public event DriveDetectorEventHandler DeviceArrived;
public event DriveDetectorEventHandler DeviceRemoved;
public event DriveDetectorEventHandler QueryRemove;
/// <summary>
/// The easiest way to use DriveDetector.
/// It will create hidden form for processing Windows messages about USB drives
/// You do not need to override WndProc in your form.
/// </summary>
public DriveDetector()
{
DetectorForm frm = new DetectorForm(this);
frm.Show(); // will be hidden immediatelly
Init(frm, null);
}
/// <summary>
/// Alternate constructor.
/// Pass in your Form and DriveDetector will not create hidden form.
/// </summary>
/// <param name="control">object which will receive Windows messages.
/// Pass "this" as this argument from your form class.</param>
public DriveDetector(Control control)
{
Init(control, null);
}
/// <summary>
/// Consructs DriveDetector object setting also path to file which should be opened
/// when registering for query remove.
/// </summary>
///<param name="control">object which will receive Windows messages.
/// Pass "this" as this argument from your form class.</param>
/// <param name="FileToOpen">Optional. Name of a file on the removable drive which should be opened.
/// If null, root directory of the drive will be opened. Opening a file is needed for us
/// to be able to register for the query remove message. TIP: For files use relative path without drive letter.
/// e.g. "SomeFolder\file_on_flash.txt"</param>
public DriveDetector(Control control, string FileToOpen)
{
Init(control, FileToOpen);
}
/// <summary>
/// init the DriveDetector object
/// </summary>
/// <param name="intPtr"></param>
private void Init(Control control, string fileToOpen)
{
mFileToOpen = fileToOpen;
mFileOnFlash = null;
mDeviceNotifyHandle = IntPtr.Zero;
mRecipientHandle = control.Handle;
mDirHandle = IntPtr.Zero; // handle to the root directory of the flash drive which we open
mCurrentDrive = "";
}
/// <summary>
/// Gets the value indicating whether the query remove event will be fired.
/// </summary>
public bool IsQueryHooked
{
get
{
if (mDeviceNotifyHandle == IntPtr.Zero)
return false;
else
return true;
}
}
/// <summary>
/// Gets letter of drive which is currently hooked. Empty string if none.
/// See also IsQueryHooked.
/// </summary>
public string HookedDrive
{
get
{
return mCurrentDrive;
}
}
/// <summary>
/// Gets the file stream for file which this class opened on a drive to be notified
/// about it's removal.
/// This will be null unless you specified a file to open (DriveDetector opens root directory of the flash drive)
/// </summary>
public FileStream OpenedFile
{
get
{
return mFileOnFlash;
}
}
/// <summary>
/// Hooks specified drive to receive a message when it is being removed.
/// This can be achieved also by setting e.HookQueryRemove to true in your
/// DeviceArrived event handler.
/// By default DriveDetector will open the root directory of the flash drive to obtain notification handle
/// from Windows (to learn when the drive is about to be removed).
/// </summary>
/// <param name="fileOnDrive">Drive letter or relative path to a file on the drive which should be
/// used to get a handle - required for registering to receive query remove messages.
/// If only drive letter is specified (e.g. "D:\\", root directory of the drive will be opened.</param>
/// <returns>true if hooked ok, false otherwise</returns>
public bool EnableQueryRemove(string fileOnDrive)
{
if (fileOnDrive == null || fileOnDrive.Length == 0)
throw new ArgumentException("Drive path must be supplied to register for Query remove.");
if ( fileOnDrive.Length == 2 && fileOnDrive[1] == ':' )
fileOnDrive += '\\'; // append "\\" if only drive letter with ":" was passed in.
if (mDeviceNotifyHandle != IntPtr.Zero)
{
// Unregister first...
RegisterForDeviceChange(false, null);
}
if (Path.GetFileName(fileOnDrive).Length == 0 ||!File.Exists(fileOnDrive))
mFileToOpen = null; // use root directory...
else
mFileToOpen = fileOnDrive;
RegisterQuery(Path.GetPathRoot(fileOnDrive));
if (mDeviceNotifyHandle == IntPtr.Zero)
return false; // failed to register
return true;
}
/// <summary>
/// Unhooks any currently hooked drive so that the query remove
/// message is not generated for it.
/// </summary>
public void DisableQueryRemove()
{
if (mDeviceNotifyHandle != IntPtr.Zero)
{
RegisterForDeviceChange(false, null);
}
}
/// <summary>
/// Unregister and close the file we may have opened on the removable drive.
/// Garbage collector will call this method.
/// </summary>
public void Dispose()
{
RegisterForDeviceChange(false, null);
}
#region WindowProc
/// <summary>
/// Message handler which must be called from client form.
/// Processes Windows messages and calls event handlers.
/// </summary>
/// <param name="m"></param>
public void WndProc(ref Message m)
{
int devType;
char c;
if (m.Msg == WM_DEVICECHANGE)
{
// WM_DEVICECHANGE can have several meanings depending on the WParam value...
switch (m.WParam.ToInt32())
{
//
// New device has just arrived
//
case DBT_DEVICEARRIVAL:
devType = Marshal.ReadInt32(m.LParam, 4);
if (devType == DBT_DEVTYP_VOLUME)
{
DEV_BROADCAST_VOLUME vol;
vol = (DEV_BROADCAST_VOLUME)
Marshal.PtrToStructure(m.LParam, typeof(DEV_BROADCAST_VOLUME));
// Get the drive letter
c = DriveMaskToLetter(vol.dbcv_unitmask);
//
// Call the client event handler
//
// We should create copy of the event before testing it and
// calling the delegate - if any
DriveDetectorEventHandler tempDeviceArrived = DeviceArrived;
if ( tempDeviceArrived != null )
{
DriveDetectorEventArgs e = new DriveDetectorEventArgs();
e.Drive = c + ":\\";
tempDeviceArrived(this, e);
// Register for query remove if requested
if (e.HookQueryRemove)
{
// If something is already hooked, unhook it now
if (mDeviceNotifyHandle != IntPtr.Zero)
{
RegisterForDeviceChange(false, null);
}
RegisterQuery(c + ":\\");
}
} // if has event handler
}
break;
//
// Device is about to be removed
// Any application can cancel the removal
//
case DBT_DEVICEQUERYREMOVE:
devType = Marshal.ReadInt32(m.LParam, 4);
if (devType == DBT_DEVTYP_HANDLE)
{
// TODO: we could get the handle for which this message is sent
// from vol.dbch_handle and compare it against a list of handles for
// which we have registered the query remove message (?)
//DEV_BROADCAST_HANDLE vol;
//vol = (DEV_BROADCAST_HANDLE)
// Marshal.PtrToStructure(m.LParam, typeof(DEV_BROADCAST_HANDLE));
// if ( vol.dbch_handle ....
//
// Call the event handler in client
//
DriveDetectorEventHandler tempQuery = QueryRemove;
if (tempQuery != null)
{
DriveDetectorEventArgs e = new DriveDetectorEventArgs();
e.Drive = mCurrentDrive; // drive which is hooked
tempQuery(this, e);
// If the client wants to cancel, let Windows know
if (e.Cancel)
{
m.Result = (IntPtr)BROADCAST_QUERY_DENY;
}
else
{
// Change 28.10.2007: Unregister the notification, this will
// close the handle to file or root directory also.
// We have to close it anyway to allow the removal so
// even if some other app cancels the removal we would not know about it...
RegisterForDeviceChange(false, null); // will also close the mFileOnFlash
}
}
}
break;
//
// Device has been removed
//
case DBT_DEVICEREMOVECOMPLETE:
devType = Marshal.ReadInt32(m.LParam, 4);
if (devType == DBT_DEVTYP_VOLUME)
{
devType = Marshal.ReadInt32(m.LParam, 4);
if (devType == DBT_DEVTYP_VOLUME)
{
DEV_BROADCAST_VOLUME vol;
vol = (DEV_BROADCAST_VOLUME)
Marshal.PtrToStructure(m.LParam, typeof(DEV_BROADCAST_VOLUME));
c = DriveMaskToLetter(vol.dbcv_unitmask);
//
// Call the client event handler
//
DriveDetectorEventHandler tempDeviceRemoved = DeviceRemoved;
if (tempDeviceRemoved != null)
{
DriveDetectorEventArgs e = new DriveDetectorEventArgs();
e.Drive = c + ":\\";
tempDeviceRemoved(this, e);
}
// TODO: we could unregister the notify handle here if we knew it is the
// right drive which has been just removed
//RegisterForDeviceChange(false, null);
}
}
break;
}
}
}
#endregion
#region Private Area
/// <summary>
/// New: 28.10.2007 - handle to root directory of flash drive which is opened
/// for device notification
/// </summary>
private IntPtr mDirHandle = IntPtr.Zero;
/// <summary>
/// Class which contains also handle to the file opened on the flash drive
/// </summary>
private FileStream mFileOnFlash = null;
/// <summary>
/// Name of the file to try to open on the removable drive for query remove registration
/// </summary>
private string mFileToOpen;
/// <summary>
/// Handle to file which we keep opened on the drive if query remove message is required by the client
/// </summary>
private IntPtr mDeviceNotifyHandle;
/// <summary>
/// Handle of the window which receives messages from Windows. This will be a form.
/// </summary>
private IntPtr mRecipientHandle;
/// <summary>
/// Drive which is currently hooked for query remove
/// </summary>
private string mCurrentDrive;
// Win32 constants
private const int DBT_DEVTYP_DEVICEINTERFACE = 5;
private const int DBT_DEVTYP_HANDLE = 6;
private const int BROADCAST_QUERY_DENY = 0x424D5144;
private const int WM_DEVICECHANGE = 0x0219;
private const int DBT_DEVICEARRIVAL = 0x8000; // system detected a new device
private const int DBT_DEVICEQUERYREMOVE = 0x8001; // Preparing to remove (any program can disable the removal)
private const int DBT_DEVICEREMOVECOMPLETE = 0x8004; // removed
private const int DBT_DEVTYP_VOLUME = 0x00000002; // drive type is logical volume
/// <summary>
/// Registers for receiving the query remove message for a given drive.
/// We need to open a handle on that drive and register with this handle.
/// Client can specify this file in mFileToOpen or we will open root directory of the drive
/// </summary>
/// <param name="drive">drive for which to register. </param>
private void RegisterQuery(string drive)
{
bool register = true;
if (mFileToOpen == null)
{
// Change 28.10.2007 - Open the root directory if no file specified - leave mFileToOpen null
// If client gave us no file, let's pick one on the drive...
//mFileToOpen = GetAnyFile(drive);
//if (mFileToOpen.Length == 0)
// return; // no file found on the flash drive
}
else
{
// Make sure the path in mFileToOpen contains valid drive
// If there is a drive letter in the path, it may be different from the actual
// letter assigned to the drive now. We will cut it off and merge the actual drive
// with the rest of the path.
if (mFileToOpen.Contains(":"))
{
string tmp = mFileToOpen.Substring(3);
string root = Path.GetPathRoot(drive);
mFileToOpen = Path.Combine(root, tmp);
}
else
mFileToOpen = Path.Combine(drive, mFileToOpen);
}
try
{
//mFileOnFlash = new FileStream(mFileToOpen, FileMode.Open);
// Change 28.10.2007 - Open the root directory
if (mFileToOpen == null) // open root directory
mFileOnFlash = null;
else
mFileOnFlash = new FileStream(mFileToOpen, FileMode.Open);
}
catch (Exception)
{
// just do not register if the file could not be opened
register = false;
}
if (register)
{
//RegisterForDeviceChange(true, mFileOnFlash.SafeFileHandle);
//mCurrentDrive = drive;
// Change 28.10.2007 - Open the root directory
if (mFileOnFlash == null)
RegisterForDeviceChange(drive);
else
// old version
RegisterForDeviceChange(true, mFileOnFlash.SafeFileHandle);
mCurrentDrive = drive;
}
}
/// <summary>
/// New version which gets the handle automatically for specified directory
/// Only for registering! Unregister with the old version of this function...
/// </summary>
/// <param name="register"></param>
/// <param name="dirPath">e.g. C:\\dir</param>
private void RegisterForDeviceChange(string dirPath)
{
IntPtr handle = Native.OpenDirectory(dirPath);
if (handle == IntPtr.Zero)
{
mDeviceNotifyHandle = IntPtr.Zero;
return;
}
else
mDirHandle = handle; // save handle for closing it when unregistering
// Register for handle
DEV_BROADCAST_HANDLE data = new DEV_BROADCAST_HANDLE();
data.dbch_devicetype = DBT_DEVTYP_HANDLE;
data.dbch_reserved = 0;
data.dbch_nameoffset = 0;
//data.dbch_data = null;
//data.dbch_eventguid = 0;
data.dbch_handle = handle;
data.dbch_hdevnotify = (IntPtr)0;
int size = Marshal.SizeOf(data);
data.dbch_size = size;
IntPtr buffer = Marshal.AllocHGlobal(size);
Marshal.StructureToPtr(data, buffer, true);
mDeviceNotifyHandle = Native.RegisterDeviceNotification(mRecipientHandle, buffer, 0);
}
/// <summary>
/// Registers to be notified when the volume is about to be removed
/// This is requierd if you want to get the QUERY REMOVE messages
/// </summary>
/// <param name="register">true to register, false to unregister</param>
/// <param name="fileHandle">handle of a file opened on the removable drive</param>
private void RegisterForDeviceChange(bool register, SafeFileHandle fileHandle)
{
if (register)
{
// Register for handle
DEV_BROADCAST_HANDLE data = new DEV_BROADCAST_HANDLE();
data.dbch_devicetype = DBT_DEVTYP_HANDLE;
data.dbch_reserved = 0;
data.dbch_nameoffset = 0;
//data.dbch_data = null;
//data.dbch_eventguid = 0;
data.dbch_handle = fileHandle.DangerousGetHandle(); //Marshal. fileHandle;
data.dbch_hdevnotify = (IntPtr)0;
int size = Marshal.SizeOf(data);
data.dbch_size = size;
IntPtr buffer = Marshal.AllocHGlobal(size);
Marshal.StructureToPtr(data, buffer, true);
mDeviceNotifyHandle = Native.RegisterDeviceNotification(mRecipientHandle, buffer, 0);
}
else
{
// close the directory handle
if (mDirHandle != IntPtr.Zero)
{
Native.CloseDirectoryHandle(mDirHandle);
// string er = Marshal.GetLastWin32Error().ToString();
}
// unregister
if (mDeviceNotifyHandle != IntPtr.Zero)
{
Native.UnregisterDeviceNotification(mDeviceNotifyHandle);
}
mDeviceNotifyHandle = IntPtr.Zero;
mDirHandle = IntPtr.Zero;
mCurrentDrive = "";
if (mFileOnFlash != null)
{
mFileOnFlash.Close();
mFileOnFlash = null;
}
}
}
/// <summary>
/// Gets drive letter from a bit mask where bit 0 = A, bit 1 = B etc.
/// There can actually be more than one drive in the mask but we
/// just use the last one in this case.
/// </summary>
/// <param name="mask"></param>
/// <returns></returns>
private static char DriveMaskToLetter(int mask)
{
char letter;
string drives = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
// 1 = A
// 2 = B
// 4 = C...
int cnt = 0;
int pom = mask / 2;
while (pom != 0)
{
// while there is any bit set in the mask
// shift it to the righ...
pom = pom / 2;
cnt++;
}
if (cnt < drives.Length)
letter = drives[cnt];
else
letter = '?';
return letter;
}
/* 28.10.2007 - no longer needed
/// <summary>
/// Searches for any file in a given path and returns its full path
/// </summary>
/// <param name="drive">drive to search</param>
/// <returns>path of the file or empty string</returns>
private string GetAnyFile(string drive)
{
string file = "";
// First try files in the root
string[] files = Directory.GetFiles(drive);
if (files.Length == 0)
{
// if no file in the root, search whole drive
files = Directory.GetFiles(drive, "*.*", SearchOption.AllDirectories);
}
if (files.Length > 0)
file = files[0]; // get the first file
// return empty string if no file found
return file;
}*/
#endregion
#region Native Win32 API
/// <summary>
/// WinAPI functions
/// </summary>
private class Native
{
// HDEVNOTIFY RegisterDeviceNotification(HANDLE hRecipient,LPVOID NotificationFilter,DWORD Flags);
[DllImport("user32.dll", CharSet = CharSet.Auto)]
public static extern IntPtr RegisterDeviceNotification(IntPtr hRecipient, IntPtr NotificationFilter, uint Flags);
[DllImport("user32.dll", CharSet = CharSet.Auto)]
public static extern uint UnregisterDeviceNotification(IntPtr hHandle);
//
// CreateFile - MSDN
const uint GENERIC_READ = 0x80000000;
const uint OPEN_EXISTING = 3;
const uint FILE_SHARE_READ = 0x00000001;
const uint FILE_SHARE_WRITE = 0x00000002;
const uint FILE_ATTRIBUTE_NORMAL = 128;
const uint FILE_FLAG_BACKUP_SEMANTICS = 0x02000000;
static readonly IntPtr INVALID_HANDLE_VALUE = new IntPtr(-1);
// should be "static extern unsafe"
[DllImport("kernel32", SetLastError = true)]
static extern IntPtr CreateFile(
string FileName, // file name
uint DesiredAccess, // access mode
uint ShareMode, // share mode
uint SecurityAttributes, // Security Attributes
uint CreationDisposition, // how to create
uint FlagsAndAttributes, // file attributes
int hTemplateFile // handle to template file
);
[DllImport("kernel32", SetLastError = true)]
static extern bool CloseHandle(
IntPtr hObject // handle to object
);
/// <summary>
/// Opens a directory, returns it's handle or zero.
/// </summary>
/// <param name="dirPath">path to the directory, e.g. "C:\\dir"</param>
/// <returns>handle to the directory. Close it with CloseHandle().</returns>
static public IntPtr OpenDirectory(string dirPath)
{
// open the existing file for reading
IntPtr handle = CreateFile(
dirPath,
GENERIC_READ,
FILE_SHARE_READ | FILE_SHARE_WRITE,
0,
OPEN_EXISTING,
FILE_FLAG_BACKUP_SEMANTICS | FILE_ATTRIBUTE_NORMAL,
0);
if ( handle == INVALID_HANDLE_VALUE)
return IntPtr.Zero;
else
return handle;
}
public static bool CloseDirectoryHandle(IntPtr handle)
{
return CloseHandle(handle);
}
}
// Structure with information for RegisterDeviceNotification.
[StructLayout(LayoutKind.Sequential)]
public struct DEV_BROADCAST_HANDLE
{
public int dbch_size;
public int dbch_devicetype;
public int dbch_reserved;
public IntPtr dbch_handle;
public IntPtr dbch_hdevnotify;
public Guid dbch_eventguid;
public long dbch_nameoffset;
//public byte[] dbch_data[1]; // = new byte[1];
public byte dbch_data;
public byte dbch_data1;
}
// Struct for parameters of the WM_DEVICECHANGE message
[StructLayout(LayoutKind.Sequential)]
public struct DEV_BROADCAST_VOLUME
{
public int dbcv_size;
public int dbcv_devicetype;
public int dbcv_reserved;
public int dbcv_unitmask;
}
#endregion
}
}

View File

@@ -31,16 +31,15 @@
this.rtsys = new arCtl.LogTextBox(); this.rtsys = new arCtl.LogTextBox();
this.rtTx = new arCtl.LogTextBox(); this.rtTx = new arCtl.LogTextBox();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.rtAGV = new arCtl.LogTextBox();
this.rtBMS = new arCtl.LogTextBox();
this.rtXbee = new arCtl.LogTextBox();
this.panel1 = new System.Windows.Forms.Panel(); this.panel1 = new System.Windows.Forms.Panel();
this.label1 = new System.Windows.Forms.Label(); this.rtXbee = new arCtl.LogTextBox();
this.titleXBEE = new System.Windows.Forms.Label();
this.panel2 = new System.Windows.Forms.Panel(); this.panel2 = new System.Windows.Forms.Panel();
this.panel3 = new System.Windows.Forms.Panel(); this.rtBMS = new arCtl.LogTextBox();
this.titleBMS = new System.Windows.Forms.Label();
this.panel4 = new System.Windows.Forms.Panel(); this.panel4 = new System.Windows.Forms.Panel();
this.label2 = new System.Windows.Forms.Label(); this.rtAGV = new arCtl.LogTextBox();
this.label3 = new System.Windows.Forms.Label(); this.titleAGV = new System.Windows.Forms.Label();
this.tableLayoutPanel1.SuspendLayout(); this.tableLayoutPanel1.SuspendLayout();
this.panel1.SuspendLayout(); this.panel1.SuspendLayout();
this.panel2.SuspendLayout(); this.panel2.SuspendLayout();
@@ -99,8 +98,7 @@
this.tableLayoutPanel1.Controls.Add(this.rtsys, 0, 0); this.tableLayoutPanel1.Controls.Add(this.rtsys, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.rtTx, 2, 0); this.tableLayoutPanel1.Controls.Add(this.rtTx, 2, 0);
this.tableLayoutPanel1.Controls.Add(this.panel1, 1, 1); this.tableLayoutPanel1.Controls.Add(this.panel1, 1, 1);
this.tableLayoutPanel1.Controls.Add(this.panel2, 3, 1); this.tableLayoutPanel1.Controls.Add(this.panel2, 2, 1);
this.tableLayoutPanel1.Controls.Add(this.panel3, 2, 1);
this.tableLayoutPanel1.Controls.Add(this.panel4, 0, 1); this.tableLayoutPanel1.Controls.Add(this.panel4, 0, 1);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0); this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
@@ -111,45 +109,15 @@
this.tableLayoutPanel1.Size = new System.Drawing.Size(681, 495); this.tableLayoutPanel1.Size = new System.Drawing.Size(681, 495);
this.tableLayoutPanel1.TabIndex = 2; this.tableLayoutPanel1.TabIndex = 2;
// //
// rtAGV // panel1
// //
this.rtAGV.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224))))); this.panel1.Controls.Add(this.rtXbee);
this.rtAGV.ColorList = new arCtl.sLogMessageColor[0]; this.panel1.Controls.Add(this.titleXBEE);
this.rtAGV.DateFormat = "mm:ss.fff"; this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.rtAGV.DefaultColor = System.Drawing.Color.LightGray; this.panel1.Location = new System.Drawing.Point(173, 349);
this.rtAGV.Dock = System.Windows.Forms.DockStyle.Fill; this.panel1.Name = "panel1";
this.rtAGV.EnableDisplayTimer = false; this.panel1.Size = new System.Drawing.Size(164, 143);
this.rtAGV.EnableGubunColor = true; this.panel1.TabIndex = 3;
this.rtAGV.Font = new System.Drawing.Font("맑은 고딕", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.rtAGV.ListFormat = "[{0}] {1}";
this.rtAGV.Location = new System.Drawing.Point(0, 14);
this.rtAGV.MaxListCount = ((ushort)(1000));
this.rtAGV.MaxTextLength = ((uint)(400000u));
this.rtAGV.MessageInterval = 50;
this.rtAGV.Name = "rtAGV";
this.rtAGV.Size = new System.Drawing.Size(164, 129);
this.rtAGV.TabIndex = 2;
this.rtAGV.Text = "";
//
// rtBMS
//
this.rtBMS.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
this.rtBMS.ColorList = new arCtl.sLogMessageColor[0];
this.rtBMS.DateFormat = "mm:ss.fff";
this.rtBMS.DefaultColor = System.Drawing.Color.LightGray;
this.rtBMS.Dock = System.Windows.Forms.DockStyle.Fill;
this.rtBMS.EnableDisplayTimer = false;
this.rtBMS.EnableGubunColor = true;
this.rtBMS.Font = new System.Drawing.Font("맑은 고딕", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.rtBMS.ListFormat = "[{0}] {1}";
this.rtBMS.Location = new System.Drawing.Point(0, 14);
this.rtBMS.MaxListCount = ((ushort)(1000));
this.rtBMS.MaxTextLength = ((uint)(400000u));
this.rtBMS.MessageInterval = 50;
this.rtBMS.Name = "rtBMS";
this.rtBMS.Size = new System.Drawing.Size(165, 129);
this.rtBMS.TabIndex = 2;
this.rtBMS.Text = "";
// //
// rtXbee // rtXbee
// //
@@ -171,73 +139,96 @@
this.rtXbee.TabIndex = 2; this.rtXbee.TabIndex = 2;
this.rtXbee.Text = ""; this.rtXbee.Text = "";
// //
// panel1 // titleXBEE
// //
this.panel1.Controls.Add(this.rtXbee); this.titleXBEE.Dock = System.Windows.Forms.DockStyle.Top;
this.panel1.Controls.Add(this.label1); this.titleXBEE.Location = new System.Drawing.Point(0, 0);
this.panel1.Dock = System.Windows.Forms.DockStyle.Fill; this.titleXBEE.Name = "titleXBEE";
this.panel1.Location = new System.Drawing.Point(173, 349); this.titleXBEE.Size = new System.Drawing.Size(164, 14);
this.panel1.Name = "panel1"; this.titleXBEE.TabIndex = 0;
this.panel1.Size = new System.Drawing.Size(164, 143); this.titleXBEE.Text = "MC ID";
this.panel1.TabIndex = 3; this.titleXBEE.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// label1
//
this.label1.Dock = System.Windows.Forms.DockStyle.Top;
this.label1.Location = new System.Drawing.Point(0, 0);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(164, 14);
this.label1.TabIndex = 0;
this.label1.Text = "MC ID";
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
// //
// panel2 // panel2
// //
this.tableLayoutPanel1.SetColumnSpan(this.panel2, 2);
this.panel2.Controls.Add(this.rtBMS); this.panel2.Controls.Add(this.rtBMS);
this.panel2.Controls.Add(this.label3); this.panel2.Controls.Add(this.titleBMS);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill; this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(513, 349); this.panel2.Location = new System.Drawing.Point(343, 349);
this.panel2.Name = "panel2"; this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(165, 143); this.panel2.Size = new System.Drawing.Size(335, 143);
this.panel2.TabIndex = 4; this.panel2.TabIndex = 4;
// //
// panel3 // rtBMS
// //
this.panel3.Dock = System.Windows.Forms.DockStyle.Fill; this.rtBMS.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
this.panel3.Location = new System.Drawing.Point(343, 349); this.rtBMS.ColorList = new arCtl.sLogMessageColor[0];
this.panel3.Name = "panel3"; this.rtBMS.DateFormat = "mm:ss.fff";
this.panel3.Size = new System.Drawing.Size(164, 143); this.rtBMS.DefaultColor = System.Drawing.Color.LightGray;
this.panel3.TabIndex = 5; this.rtBMS.Dock = System.Windows.Forms.DockStyle.Fill;
this.rtBMS.EnableDisplayTimer = false;
this.rtBMS.EnableGubunColor = true;
this.rtBMS.Font = new System.Drawing.Font("맑은 고딕", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.rtBMS.ListFormat = "[{0}] {1}";
this.rtBMS.Location = new System.Drawing.Point(0, 14);
this.rtBMS.MaxListCount = ((ushort)(1000));
this.rtBMS.MaxTextLength = ((uint)(400000u));
this.rtBMS.MessageInterval = 50;
this.rtBMS.Name = "rtBMS";
this.rtBMS.Size = new System.Drawing.Size(335, 129);
this.rtBMS.TabIndex = 2;
this.rtBMS.Text = "";
//
// titleBMS
//
this.titleBMS.Dock = System.Windows.Forms.DockStyle.Top;
this.titleBMS.Location = new System.Drawing.Point(0, 0);
this.titleBMS.Name = "titleBMS";
this.titleBMS.Size = new System.Drawing.Size(335, 14);
this.titleBMS.TabIndex = 3;
this.titleBMS.Text = "BMS";
this.titleBMS.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
// //
// panel4 // panel4
// //
this.panel4.Controls.Add(this.rtAGV); this.panel4.Controls.Add(this.rtAGV);
this.panel4.Controls.Add(this.label2); this.panel4.Controls.Add(this.titleAGV);
this.panel4.Dock = System.Windows.Forms.DockStyle.Fill; this.panel4.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel4.Location = new System.Drawing.Point(3, 349); this.panel4.Location = new System.Drawing.Point(3, 349);
this.panel4.Name = "panel4"; this.panel4.Name = "panel4";
this.panel4.Size = new System.Drawing.Size(164, 143); this.panel4.Size = new System.Drawing.Size(164, 143);
this.panel4.TabIndex = 6; this.panel4.TabIndex = 6;
// //
// label2 // rtAGV
// //
this.label2.Dock = System.Windows.Forms.DockStyle.Top; this.rtAGV.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
this.label2.Location = new System.Drawing.Point(0, 0); this.rtAGV.ColorList = new arCtl.sLogMessageColor[0];
this.label2.Name = "label2"; this.rtAGV.DateFormat = "mm:ss.fff";
this.label2.Size = new System.Drawing.Size(164, 14); this.rtAGV.DefaultColor = System.Drawing.Color.LightGray;
this.label2.TabIndex = 3; this.rtAGV.Dock = System.Windows.Forms.DockStyle.Fill;
this.label2.Text = "AGV"; this.rtAGV.EnableDisplayTimer = false;
this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.rtAGV.EnableGubunColor = true;
this.rtAGV.Font = new System.Drawing.Font("맑은 고딕", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.rtAGV.ListFormat = "[{0}] {1}";
this.rtAGV.Location = new System.Drawing.Point(0, 14);
this.rtAGV.MaxListCount = ((ushort)(1000));
this.rtAGV.MaxTextLength = ((uint)(400000u));
this.rtAGV.MessageInterval = 50;
this.rtAGV.Name = "rtAGV";
this.rtAGV.Size = new System.Drawing.Size(164, 129);
this.rtAGV.TabIndex = 2;
this.rtAGV.Text = "";
// //
// label3 // titleAGV
// //
this.label3.Dock = System.Windows.Forms.DockStyle.Top; this.titleAGV.Dock = System.Windows.Forms.DockStyle.Top;
this.label3.Location = new System.Drawing.Point(0, 0); this.titleAGV.Location = new System.Drawing.Point(0, 0);
this.label3.Name = "label3"; this.titleAGV.Name = "titleAGV";
this.label3.Size = new System.Drawing.Size(165, 14); this.titleAGV.Size = new System.Drawing.Size(164, 14);
this.label3.TabIndex = 3; this.titleAGV.TabIndex = 3;
this.label3.Text = "BMS"; this.titleAGV.Text = "AGV";
this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.titleAGV.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
// //
// fLog // fLog
// //
@@ -267,11 +258,10 @@
private arCtl.LogTextBox rtBMS; private arCtl.LogTextBox rtBMS;
private arCtl.LogTextBox rtXbee; private arCtl.LogTextBox rtXbee;
private System.Windows.Forms.Panel panel1; private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.Label label1; private System.Windows.Forms.Label titleXBEE;
private System.Windows.Forms.Panel panel2; private System.Windows.Forms.Panel panel2;
private System.Windows.Forms.Panel panel3;
private System.Windows.Forms.Panel panel4; private System.Windows.Forms.Panel panel4;
private System.Windows.Forms.Label label3; private System.Windows.Forms.Label titleBMS;
private System.Windows.Forms.Label label2; private System.Windows.Forms.Label titleAGV;
} }
} }

View File

@@ -29,7 +29,9 @@ namespace Project.Dialog
private void fLog_Load(object sender, EventArgs e) private void fLog_Load(object sender, EventArgs e)
{ {
this.label1.Text = $"XBEE:{PUB.setting.XBE_ID}"; this.titleXBEE.Text = $"XBEE({PUB.setting.Port_XBE},ID:{PUB.setting.XBE_ID})";
this.titleAGV.Text = $"AGV({PUB.setting.Port_AGV}:{PUB.setting.Baud_AGV})";
this.titleBMS.Text = $"BMS({PUB.setting.Port_BAT}:{PUB.setting.Baud_BAT})";
var colorlist = new arCtl.sLogMessageColor[] var colorlist = new arCtl.sLogMessageColor[]
{ {
new arCtl.sLogMessageColor("NOR",Color.Black), new arCtl.sLogMessageColor("NOR",Color.Black),

View File

@@ -28,530 +28,307 @@
/// </summary> /// </summary>
private void InitializeComponent() private void InitializeComponent()
{ {
this.lbMsg = new arCtl.arLabel(); this.btOpenDir = new System.Windows.Forms.Button();
this.arLabel4 = new arCtl.arLabel(); this.arLabel4 = new System.Windows.Forms.Button();
this.arLabel9 = new arCtl.arLabel(); this.btShutdown = new System.Windows.Forms.Button();
this.arLabel10 = new arCtl.arLabel(); this.btRestart = new System.Windows.Forms.Button();
this.arLabel1 = new arCtl.arLabel(); this.btStartMenu = new System.Windows.Forms.Button();
this.arLabel6 = new arCtl.arLabel(); this.btTaskMgr = new System.Windows.Forms.Button();
this.arLabel2 = new arCtl.arLabel(); this.btProcessList = new System.Windows.Forms.Button();
this.label1 = new System.Windows.Forms.Label(); this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label(); this.label2 = new System.Windows.Forms.Label();
this.arLabel3 = new arCtl.arLabel(); this.btEmulator = new System.Windows.Forms.Button();
this.arLabel5 = new arCtl.arLabel(); this.btMakePatch = new System.Windows.Forms.Button();
this.arLabel7 = new arCtl.arLabel(); this.btAutoRestart = new System.Windows.Forms.Button();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.button1 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.button3 = new System.Windows.Forms.Button();
this.tableLayoutPanel1.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
// lbMsg // btOpenDir
// //
this.lbMsg.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btOpenDir.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.lbMsg.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(18)))), ((int)(((byte)(18)))), ((int)(((byte)(18))))); this.btOpenDir.Cursor = System.Windows.Forms.Cursors.Hand;
this.lbMsg.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btOpenDir.Dock = System.Windows.Forms.DockStyle.Fill;
this.lbMsg.BorderColor = System.Drawing.Color.LightSkyBlue; this.btOpenDir.Font = new System.Drawing.Font("Consolas", 12F);
this.lbMsg.BorderColorOver = System.Drawing.Color.Red; this.btOpenDir.ForeColor = System.Drawing.Color.White;
this.lbMsg.BorderSize = new System.Windows.Forms.Padding(1); this.btOpenDir.Location = new System.Drawing.Point(5, 5);
this.lbMsg.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btOpenDir.Margin = new System.Windows.Forms.Padding(5);
this.lbMsg.Cursor = System.Windows.Forms.Cursors.Hand; this.btOpenDir.Name = "btOpenDir";
this.lbMsg.Font = new System.Drawing.Font("Consolas", 12F); this.btOpenDir.Size = new System.Drawing.Size(201, 79);
this.lbMsg.ForeColor = System.Drawing.Color.White; this.btOpenDir.TabIndex = 2;
this.lbMsg.GradientEnable = true; this.btOpenDir.Text = "폴더열기";
this.lbMsg.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btOpenDir.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.lbMsg.GradientRepeatBG = true; this.btOpenDir.Click += new System.EventHandler(this.lbMsg_Click);
this.lbMsg.isButton = true;
this.lbMsg.Location = new System.Drawing.Point(9, 8);
this.lbMsg.Margin = new System.Windows.Forms.Padding(5);
this.lbMsg.MouseDownColor = System.Drawing.Color.Yellow;
this.lbMsg.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.lbMsg.msg = null;
this.lbMsg.Name = "lbMsg";
this.lbMsg.ProgressBorderColor = System.Drawing.Color.Black;
this.lbMsg.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.lbMsg.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.lbMsg.ProgressEnable = false;
this.lbMsg.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.lbMsg.ProgressForeColor = System.Drawing.Color.Black;
this.lbMsg.ProgressMax = 100F;
this.lbMsg.ProgressMin = 0F;
this.lbMsg.ProgressPadding = new System.Windows.Forms.Padding(0);
this.lbMsg.ProgressValue = 0F;
this.lbMsg.ShadowColor = System.Drawing.Color.Black;
this.lbMsg.Sign = "";
this.lbMsg.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.lbMsg.SignColor = System.Drawing.Color.Yellow;
this.lbMsg.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.lbMsg.Size = new System.Drawing.Size(165, 100);
this.lbMsg.TabIndex = 2;
this.lbMsg.Text = "폴더열기";
this.lbMsg.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.lbMsg.TextShadow = true;
this.lbMsg.TextVisible = true;
this.lbMsg.Click += new System.EventHandler(this.lbMsg_Click);
// //
// arLabel4 // arLabel4
// //
this.arLabel4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.arLabel4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel4.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(18)))), ((int)(((byte)(18)))), ((int)(((byte)(18)))));
this.arLabel4.BackgroundImagePadding = new System.Windows.Forms.Padding(0);
this.arLabel4.BorderColor = System.Drawing.Color.LightSkyBlue;
this.arLabel4.BorderColorOver = System.Drawing.Color.Red;
this.arLabel4.BorderSize = new System.Windows.Forms.Padding(1);
this.arLabel4.ColorTheme = arCtl.arLabel.eColorTheme.Custom;
this.arLabel4.Cursor = System.Windows.Forms.Cursors.Hand; this.arLabel4.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel4.Dock = System.Windows.Forms.DockStyle.Bottom;
this.arLabel4.Font = new System.Drawing.Font("Consolas", 12F); this.arLabel4.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel4.ForeColor = System.Drawing.Color.White; this.arLabel4.ForeColor = System.Drawing.Color.White;
this.arLabel4.GradientEnable = true; this.arLabel4.Location = new System.Drawing.Point(10, 412);
this.arLabel4.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
this.arLabel4.GradientRepeatBG = true;
this.arLabel4.isButton = true;
this.arLabel4.Location = new System.Drawing.Point(9, 387);
this.arLabel4.Margin = new System.Windows.Forms.Padding(5); this.arLabel4.Margin = new System.Windows.Forms.Padding(5);
this.arLabel4.MouseDownColor = System.Drawing.Color.Yellow;
this.arLabel4.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.arLabel4.msg = null;
this.arLabel4.Name = "arLabel4"; this.arLabel4.Name = "arLabel4";
this.arLabel4.ProgressBorderColor = System.Drawing.Color.Black; this.arLabel4.Size = new System.Drawing.Size(633, 51);
this.arLabel4.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arLabel4.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arLabel4.ProgressEnable = false;
this.arLabel4.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.arLabel4.ProgressForeColor = System.Drawing.Color.Black;
this.arLabel4.ProgressMax = 100F;
this.arLabel4.ProgressMin = 0F;
this.arLabel4.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arLabel4.ProgressValue = 0F;
this.arLabel4.ShadowColor = System.Drawing.Color.Black;
this.arLabel4.Sign = "";
this.arLabel4.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.arLabel4.SignColor = System.Drawing.Color.Yellow;
this.arLabel4.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.arLabel4.Size = new System.Drawing.Size(503, 51);
this.arLabel4.TabIndex = 2; this.arLabel4.TabIndex = 2;
this.arLabel4.Text = "닫기"; this.arLabel4.Text = "닫기";
this.arLabel4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.arLabel4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel4.TextShadow = true;
this.arLabel4.TextVisible = true;
this.arLabel4.Click += new System.EventHandler(this.arLabel4_Click); this.arLabel4.Click += new System.EventHandler(this.arLabel4_Click);
// //
// arLabel9 // btShutdown
// //
this.arLabel9.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btShutdown.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel9.BackColor2 = System.Drawing.Color.Red; this.btShutdown.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel9.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btShutdown.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel9.BorderColor = System.Drawing.Color.LightSkyBlue; this.btShutdown.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel9.BorderColorOver = System.Drawing.Color.Red; this.btShutdown.ForeColor = System.Drawing.Color.White;
this.arLabel9.BorderSize = new System.Windows.Forms.Padding(1); this.btShutdown.Location = new System.Drawing.Point(5, 94);
this.arLabel9.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btShutdown.Margin = new System.Windows.Forms.Padding(5);
this.arLabel9.Cursor = System.Windows.Forms.Cursors.Hand; this.btShutdown.Name = "btShutdown";
this.arLabel9.Font = new System.Drawing.Font("Consolas", 12F); this.btShutdown.Size = new System.Drawing.Size(201, 79);
this.arLabel9.ForeColor = System.Drawing.Color.White; this.btShutdown.TabIndex = 2;
this.arLabel9.GradientEnable = true; this.btShutdown.Text = "시스템 종료";
this.arLabel9.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btShutdown.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel9.GradientRepeatBG = true; this.btShutdown.Click += new System.EventHandler(this.arLabel9_Click);
this.arLabel9.isButton = true;
this.arLabel9.Location = new System.Drawing.Point(9, 112);
this.arLabel9.Margin = new System.Windows.Forms.Padding(5);
this.arLabel9.MouseDownColor = System.Drawing.Color.Yellow;
this.arLabel9.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.arLabel9.msg = null;
this.arLabel9.Name = "arLabel9";
this.arLabel9.ProgressBorderColor = System.Drawing.Color.Black;
this.arLabel9.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arLabel9.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arLabel9.ProgressEnable = false;
this.arLabel9.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.arLabel9.ProgressForeColor = System.Drawing.Color.Black;
this.arLabel9.ProgressMax = 100F;
this.arLabel9.ProgressMin = 0F;
this.arLabel9.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arLabel9.ProgressValue = 0F;
this.arLabel9.ShadowColor = System.Drawing.Color.Black;
this.arLabel9.Sign = "";
this.arLabel9.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.arLabel9.SignColor = System.Drawing.Color.Yellow;
this.arLabel9.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.arLabel9.Size = new System.Drawing.Size(165, 100);
this.arLabel9.TabIndex = 2;
this.arLabel9.Text = "시스템 종료";
this.arLabel9.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel9.TextShadow = true;
this.arLabel9.TextVisible = true;
this.arLabel9.Click += new System.EventHandler(this.arLabel9_Click);
// //
// arLabel10 // btRestart
// //
this.arLabel10.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btRestart.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel10.BackColor2 = System.Drawing.Color.DarkBlue; this.btRestart.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel10.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btRestart.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel10.BorderColor = System.Drawing.Color.LightSkyBlue; this.btRestart.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel10.BorderColorOver = System.Drawing.Color.Red; this.btRestart.ForeColor = System.Drawing.Color.White;
this.arLabel10.BorderSize = new System.Windows.Forms.Padding(1); this.btRestart.Location = new System.Drawing.Point(216, 94);
this.arLabel10.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btRestart.Margin = new System.Windows.Forms.Padding(5);
this.arLabel10.Cursor = System.Windows.Forms.Cursors.Hand; this.btRestart.Name = "btRestart";
this.arLabel10.Font = new System.Drawing.Font("Consolas", 12F); this.btRestart.Size = new System.Drawing.Size(201, 79);
this.arLabel10.ForeColor = System.Drawing.Color.White; this.btRestart.TabIndex = 2;
this.arLabel10.GradientEnable = true; this.btRestart.Text = "시스템 재시작";
this.arLabel10.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btRestart.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel10.GradientRepeatBG = true; this.btRestart.Click += new System.EventHandler(this.arLabel10_Click);
this.arLabel10.isButton = true;
this.arLabel10.Location = new System.Drawing.Point(178, 112);
this.arLabel10.Margin = new System.Windows.Forms.Padding(5);
this.arLabel10.MouseDownColor = System.Drawing.Color.Yellow;
this.arLabel10.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.arLabel10.msg = null;
this.arLabel10.Name = "arLabel10";
this.arLabel10.ProgressBorderColor = System.Drawing.Color.Black;
this.arLabel10.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arLabel10.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arLabel10.ProgressEnable = false;
this.arLabel10.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.arLabel10.ProgressForeColor = System.Drawing.Color.Black;
this.arLabel10.ProgressMax = 100F;
this.arLabel10.ProgressMin = 0F;
this.arLabel10.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arLabel10.ProgressValue = 0F;
this.arLabel10.ShadowColor = System.Drawing.Color.Black;
this.arLabel10.Sign = "";
this.arLabel10.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.arLabel10.SignColor = System.Drawing.Color.Yellow;
this.arLabel10.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.arLabel10.Size = new System.Drawing.Size(165, 100);
this.arLabel10.TabIndex = 2;
this.arLabel10.Text = "시스템 재시작";
this.arLabel10.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel10.TextShadow = true;
this.arLabel10.TextVisible = true;
this.arLabel10.Click += new System.EventHandler(this.arLabel10_Click);
// //
// arLabel1 // btStartMenu
// //
this.arLabel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btStartMenu.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel1.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(18)))), ((int)(((byte)(18)))), ((int)(((byte)(18))))); this.btStartMenu.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel1.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btStartMenu.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel1.BorderColor = System.Drawing.Color.LightSkyBlue; this.btStartMenu.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel1.BorderColorOver = System.Drawing.Color.Red; this.btStartMenu.ForeColor = System.Drawing.Color.White;
this.arLabel1.BorderSize = new System.Windows.Forms.Padding(1); this.btStartMenu.Location = new System.Drawing.Point(427, 5);
this.arLabel1.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btStartMenu.Margin = new System.Windows.Forms.Padding(5);
this.arLabel1.Cursor = System.Windows.Forms.Cursors.Hand; this.btStartMenu.Name = "btStartMenu";
this.arLabel1.Font = new System.Drawing.Font("Consolas", 12F); this.btStartMenu.Size = new System.Drawing.Size(201, 79);
this.arLabel1.ForeColor = System.Drawing.Color.White; this.btStartMenu.TabIndex = 2;
this.arLabel1.GradientEnable = true; this.btStartMenu.Text = "시작메뉴";
this.arLabel1.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btStartMenu.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel1.GradientRepeatBG = true; this.btStartMenu.Click += new System.EventHandler(this.arLabel1_Click);
this.arLabel1.isButton = true;
this.arLabel1.Location = new System.Drawing.Point(347, 8);
this.arLabel1.Margin = new System.Windows.Forms.Padding(5);
this.arLabel1.MouseDownColor = System.Drawing.Color.Yellow;
this.arLabel1.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.arLabel1.msg = null;
this.arLabel1.Name = "arLabel1";
this.arLabel1.ProgressBorderColor = System.Drawing.Color.Black;
this.arLabel1.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arLabel1.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arLabel1.ProgressEnable = false;
this.arLabel1.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.arLabel1.ProgressForeColor = System.Drawing.Color.Black;
this.arLabel1.ProgressMax = 100F;
this.arLabel1.ProgressMin = 0F;
this.arLabel1.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arLabel1.ProgressValue = 0F;
this.arLabel1.ShadowColor = System.Drawing.Color.Black;
this.arLabel1.Sign = "";
this.arLabel1.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.arLabel1.SignColor = System.Drawing.Color.Yellow;
this.arLabel1.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.arLabel1.Size = new System.Drawing.Size(165, 100);
this.arLabel1.TabIndex = 2;
this.arLabel1.Text = "시작메뉴";
this.arLabel1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel1.TextShadow = true;
this.arLabel1.TextVisible = true;
this.arLabel1.Click += new System.EventHandler(this.arLabel1_Click);
// //
// arLabel6 // btTaskMgr
// //
this.arLabel6.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btTaskMgr.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel6.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(18)))), ((int)(((byte)(18)))), ((int)(((byte)(18))))); this.btTaskMgr.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel6.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btTaskMgr.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel6.BorderColor = System.Drawing.Color.LightSkyBlue; this.btTaskMgr.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel6.BorderColorOver = System.Drawing.Color.Red; this.btTaskMgr.ForeColor = System.Drawing.Color.White;
this.arLabel6.BorderSize = new System.Windows.Forms.Padding(1); this.btTaskMgr.Location = new System.Drawing.Point(216, 5);
this.arLabel6.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btTaskMgr.Margin = new System.Windows.Forms.Padding(5);
this.arLabel6.Cursor = System.Windows.Forms.Cursors.Hand; this.btTaskMgr.Name = "btTaskMgr";
this.arLabel6.Font = new System.Drawing.Font("Consolas", 12F); this.btTaskMgr.Size = new System.Drawing.Size(201, 79);
this.arLabel6.ForeColor = System.Drawing.Color.White; this.btTaskMgr.TabIndex = 2;
this.arLabel6.GradientEnable = true; this.btTaskMgr.Text = "작업관리자";
this.arLabel6.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btTaskMgr.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel6.GradientRepeatBG = true; this.btTaskMgr.Click += new System.EventHandler(this.arLabel6_Click);
this.arLabel6.isButton = true;
this.arLabel6.Location = new System.Drawing.Point(178, 8);
this.arLabel6.Margin = new System.Windows.Forms.Padding(5);
this.arLabel6.MouseDownColor = System.Drawing.Color.Yellow;
this.arLabel6.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.arLabel6.msg = null;
this.arLabel6.Name = "arLabel6";
this.arLabel6.ProgressBorderColor = System.Drawing.Color.Black;
this.arLabel6.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arLabel6.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arLabel6.ProgressEnable = false;
this.arLabel6.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.arLabel6.ProgressForeColor = System.Drawing.Color.Black;
this.arLabel6.ProgressMax = 100F;
this.arLabel6.ProgressMin = 0F;
this.arLabel6.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arLabel6.ProgressValue = 0F;
this.arLabel6.ShadowColor = System.Drawing.Color.Black;
this.arLabel6.Sign = "";
this.arLabel6.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.arLabel6.SignColor = System.Drawing.Color.Yellow;
this.arLabel6.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.arLabel6.Size = new System.Drawing.Size(165, 100);
this.arLabel6.TabIndex = 2;
this.arLabel6.Text = "작업관리자";
this.arLabel6.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel6.TextShadow = true;
this.arLabel6.TextVisible = true;
this.arLabel6.Click += new System.EventHandler(this.arLabel6_Click);
// //
// arLabel2 // btProcessList
// //
this.arLabel2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btProcessList.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel2.BackColor2 = System.Drawing.Color.DarkBlue; this.btProcessList.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel2.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btProcessList.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel2.BorderColor = System.Drawing.Color.LightSkyBlue; this.btProcessList.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel2.BorderColorOver = System.Drawing.Color.Red; this.btProcessList.ForeColor = System.Drawing.Color.White;
this.arLabel2.BorderSize = new System.Windows.Forms.Padding(1); this.btProcessList.Location = new System.Drawing.Point(427, 94);
this.arLabel2.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btProcessList.Margin = new System.Windows.Forms.Padding(5);
this.arLabel2.Cursor = System.Windows.Forms.Cursors.Hand; this.btProcessList.Name = "btProcessList";
this.arLabel2.Font = new System.Drawing.Font("Consolas", 12F); this.btProcessList.Size = new System.Drawing.Size(201, 79);
this.arLabel2.ForeColor = System.Drawing.Color.White; this.btProcessList.TabIndex = 2;
this.arLabel2.GradientEnable = true; this.btProcessList.Text = "Process List";
this.arLabel2.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btProcessList.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel2.GradientRepeatBG = true; this.btProcessList.Click += new System.EventHandler(this.arLabel2_Click);
this.arLabel2.isButton = true;
this.arLabel2.Location = new System.Drawing.Point(347, 112);
this.arLabel2.Margin = new System.Windows.Forms.Padding(5);
this.arLabel2.MouseDownColor = System.Drawing.Color.Yellow;
this.arLabel2.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.arLabel2.msg = null;
this.arLabel2.Name = "arLabel2";
this.arLabel2.ProgressBorderColor = System.Drawing.Color.Black;
this.arLabel2.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arLabel2.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arLabel2.ProgressEnable = false;
this.arLabel2.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.arLabel2.ProgressForeColor = System.Drawing.Color.Black;
this.arLabel2.ProgressMax = 100F;
this.arLabel2.ProgressMin = 0F;
this.arLabel2.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arLabel2.ProgressValue = 0F;
this.arLabel2.ShadowColor = System.Drawing.Color.Black;
this.arLabel2.Sign = "";
this.arLabel2.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.arLabel2.SignColor = System.Drawing.Color.Yellow;
this.arLabel2.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.arLabel2.Size = new System.Drawing.Size(165, 100);
this.arLabel2.TabIndex = 2;
this.arLabel2.Text = "Process List";
this.arLabel2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel2.TextShadow = true;
this.arLabel2.TextVisible = true;
this.arLabel2.Click += new System.EventHandler(this.arLabel2_Click);
// //
// label1 // label1
// //
this.label1.Dock = System.Windows.Forms.DockStyle.Bottom;
this.label1.Font = new System.Drawing.Font("맑은 고딕", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129))); this.label1.Font = new System.Drawing.Font("맑은 고딕", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.label1.ForeColor = System.Drawing.Color.White; this.label1.ForeColor = System.Drawing.Color.White;
this.label1.Location = new System.Drawing.Point(9, 327); this.label1.Location = new System.Drawing.Point(10, 389);
this.label1.Name = "label1"; this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(515, 23); this.label1.Size = new System.Drawing.Size(633, 23);
this.label1.TabIndex = 3; this.label1.TabIndex = 3;
this.label1.Text = "label1"; this.label1.Text = "label1";
// //
// label2 // label2
// //
this.label2.Dock = System.Windows.Forms.DockStyle.Bottom;
this.label2.Font = new System.Drawing.Font("맑은 고딕", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129))); this.label2.Font = new System.Drawing.Font("맑은 고딕", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.label2.ForeColor = System.Drawing.Color.White; this.label2.ForeColor = System.Drawing.Color.White;
this.label2.Location = new System.Drawing.Point(9, 359); this.label2.Location = new System.Drawing.Point(10, 366);
this.label2.Name = "label2"; this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(515, 23); this.label2.Size = new System.Drawing.Size(633, 23);
this.label2.TabIndex = 3; this.label2.TabIndex = 3;
this.label2.Text = "label1"; this.label2.Text = "label1";
// //
// arLabel3 // btEmulator
// //
this.arLabel3.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btEmulator.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel3.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(18)))), ((int)(((byte)(18)))), ((int)(((byte)(18))))); this.btEmulator.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel3.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btEmulator.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel3.BorderColor = System.Drawing.Color.LightSkyBlue; this.btEmulator.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel3.BorderColorOver = System.Drawing.Color.Red; this.btEmulator.ForeColor = System.Drawing.Color.White;
this.arLabel3.BorderSize = new System.Windows.Forms.Padding(1); this.btEmulator.Location = new System.Drawing.Point(5, 183);
this.arLabel3.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btEmulator.Margin = new System.Windows.Forms.Padding(5);
this.arLabel3.Cursor = System.Windows.Forms.Cursors.Hand; this.btEmulator.Name = "btEmulator";
this.arLabel3.Font = new System.Drawing.Font("Consolas", 12F); this.btEmulator.Size = new System.Drawing.Size(201, 79);
this.arLabel3.ForeColor = System.Drawing.Color.White; this.btEmulator.TabIndex = 4;
this.arLabel3.GradientEnable = true; this.btEmulator.Text = "Emulator";
this.arLabel3.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btEmulator.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel3.GradientRepeatBG = true; this.btEmulator.Click += new System.EventHandler(this.arLabel3_Click);
this.arLabel3.isButton = true;
this.arLabel3.Location = new System.Drawing.Point(9, 216);
this.arLabel3.Margin = new System.Windows.Forms.Padding(5);
this.arLabel3.MouseDownColor = System.Drawing.Color.Yellow;
this.arLabel3.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.arLabel3.msg = null;
this.arLabel3.Name = "arLabel3";
this.arLabel3.ProgressBorderColor = System.Drawing.Color.Black;
this.arLabel3.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arLabel3.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arLabel3.ProgressEnable = false;
this.arLabel3.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.arLabel3.ProgressForeColor = System.Drawing.Color.Black;
this.arLabel3.ProgressMax = 100F;
this.arLabel3.ProgressMin = 0F;
this.arLabel3.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arLabel3.ProgressValue = 0F;
this.arLabel3.ShadowColor = System.Drawing.Color.Black;
this.arLabel3.Sign = "";
this.arLabel3.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.arLabel3.SignColor = System.Drawing.Color.Yellow;
this.arLabel3.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.arLabel3.Size = new System.Drawing.Size(165, 100);
this.arLabel3.TabIndex = 4;
this.arLabel3.Text = "Emulator";
this.arLabel3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel3.TextShadow = true;
this.arLabel3.TextVisible = true;
this.arLabel3.Click += new System.EventHandler(this.arLabel3_Click);
// //
// arLabel5 // btMakePatch
// //
this.arLabel5.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btMakePatch.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel5.BackColor2 = System.Drawing.Color.Pink; this.btMakePatch.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel5.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btMakePatch.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel5.BorderColor = System.Drawing.Color.LightSkyBlue; this.btMakePatch.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel5.BorderColorOver = System.Drawing.Color.Red; this.btMakePatch.ForeColor = System.Drawing.Color.White;
this.arLabel5.BorderSize = new System.Windows.Forms.Padding(1); this.btMakePatch.Location = new System.Drawing.Point(216, 183);
this.arLabel5.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btMakePatch.Margin = new System.Windows.Forms.Padding(5);
this.arLabel5.Cursor = System.Windows.Forms.Cursors.Hand; this.btMakePatch.Name = "btMakePatch";
this.arLabel5.Font = new System.Drawing.Font("Consolas", 12F); this.btMakePatch.Size = new System.Drawing.Size(201, 79);
this.arLabel5.ForeColor = System.Drawing.Color.White; this.btMakePatch.TabIndex = 5;
this.arLabel5.GradientEnable = true; this.btMakePatch.Text = "패치파일 생성";
this.arLabel5.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btMakePatch.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel5.GradientRepeatBG = true; this.btMakePatch.Click += new System.EventHandler(this.arLabel5_Click);
this.arLabel5.isButton = true;
this.arLabel5.Location = new System.Drawing.Point(178, 216);
this.arLabel5.Margin = new System.Windows.Forms.Padding(5);
this.arLabel5.MouseDownColor = System.Drawing.Color.Yellow;
this.arLabel5.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.arLabel5.msg = null;
this.arLabel5.Name = "arLabel5";
this.arLabel5.ProgressBorderColor = System.Drawing.Color.Black;
this.arLabel5.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arLabel5.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arLabel5.ProgressEnable = false;
this.arLabel5.ProgressFont = new System.Drawing.Font("Consolas", 10F);
this.arLabel5.ProgressForeColor = System.Drawing.Color.Black;
this.arLabel5.ProgressMax = 100F;
this.arLabel5.ProgressMin = 0F;
this.arLabel5.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arLabel5.ProgressValue = 0F;
this.arLabel5.ShadowColor = System.Drawing.Color.Black;
this.arLabel5.Sign = "";
this.arLabel5.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.arLabel5.SignColor = System.Drawing.Color.Yellow;
this.arLabel5.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.arLabel5.Size = new System.Drawing.Size(165, 100);
this.arLabel5.TabIndex = 5;
this.arLabel5.Text = "패치파일 생성";
this.arLabel5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel5.TextShadow = true;
this.arLabel5.TextVisible = true;
this.arLabel5.Click += new System.EventHandler(this.arLabel5_Click);
// //
// arLabel7 // btAutoRestart
// //
this.arLabel7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72))))); this.btAutoRestart.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(72)))), ((int)(((byte)(72)))), ((int)(((byte)(72)))));
this.arLabel7.BackColor2 = System.Drawing.Color.DarkBlue; this.btAutoRestart.Cursor = System.Windows.Forms.Cursors.Hand;
this.arLabel7.BackgroundImagePadding = new System.Windows.Forms.Padding(0); this.btAutoRestart.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel7.BorderColor = System.Drawing.Color.LightSkyBlue; this.btAutoRestart.Font = new System.Drawing.Font("Consolas", 12F);
this.arLabel7.BorderColorOver = System.Drawing.Color.Red; this.btAutoRestart.ForeColor = System.Drawing.Color.White;
this.arLabel7.BorderSize = new System.Windows.Forms.Padding(1); this.btAutoRestart.Location = new System.Drawing.Point(427, 183);
this.arLabel7.ColorTheme = arCtl.arLabel.eColorTheme.Custom; this.btAutoRestart.Margin = new System.Windows.Forms.Padding(5);
this.arLabel7.Cursor = System.Windows.Forms.Cursors.Hand; this.btAutoRestart.Name = "btAutoRestart";
this.arLabel7.Font = new System.Drawing.Font("Consolas", 12F); this.btAutoRestart.Size = new System.Drawing.Size(201, 79);
this.arLabel7.ForeColor = System.Drawing.Color.White; this.btAutoRestart.TabIndex = 6;
this.arLabel7.GradientEnable = true; this.btAutoRestart.Text = "자동 재시작";
this.arLabel7.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical; this.btAutoRestart.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.arLabel7.GradientRepeatBG = true; this.btAutoRestart.Click += new System.EventHandler(this.arLabel7_Click);
this.arLabel7.isButton = true; //
this.arLabel7.Location = new System.Drawing.Point(347, 216); // tableLayoutPanel1
this.arLabel7.Margin = new System.Windows.Forms.Padding(5); //
this.arLabel7.MouseDownColor = System.Drawing.Color.Yellow; this.tableLayoutPanel1.ColumnCount = 3;
this.arLabel7.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.arLabel7.msg = null; this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.arLabel7.Name = "arLabel7"; this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.arLabel7.ProgressBorderColor = System.Drawing.Color.Black; this.tableLayoutPanel1.Controls.Add(this.btOpenDir, 0, 0);
this.arLabel7.ProgressColor1 = System.Drawing.Color.LightSkyBlue; this.tableLayoutPanel1.Controls.Add(this.btAutoRestart, 2, 2);
this.arLabel7.ProgressColor2 = System.Drawing.Color.DeepSkyBlue; this.tableLayoutPanel1.Controls.Add(this.btTaskMgr, 1, 0);
this.arLabel7.ProgressEnable = false; this.tableLayoutPanel1.Controls.Add(this.btMakePatch, 1, 2);
this.arLabel7.ProgressFont = new System.Drawing.Font("Consolas", 10F); this.tableLayoutPanel1.Controls.Add(this.btStartMenu, 2, 0);
this.arLabel7.ProgressForeColor = System.Drawing.Color.Black; this.tableLayoutPanel1.Controls.Add(this.btEmulator, 0, 2);
this.arLabel7.ProgressMax = 100F; this.tableLayoutPanel1.Controls.Add(this.btShutdown, 0, 1);
this.arLabel7.ProgressMin = 0F; this.tableLayoutPanel1.Controls.Add(this.btRestart, 1, 1);
this.arLabel7.ProgressPadding = new System.Windows.Forms.Padding(0); this.tableLayoutPanel1.Controls.Add(this.btProcessList, 2, 1);
this.arLabel7.ProgressValue = 0F; this.tableLayoutPanel1.Controls.Add(this.button1, 0, 3);
this.arLabel7.ShadowColor = System.Drawing.Color.Black; this.tableLayoutPanel1.Controls.Add(this.button2, 1, 3);
this.arLabel7.Sign = ""; this.tableLayoutPanel1.Controls.Add(this.button3, 2, 3);
this.arLabel7.SignAlign = System.Drawing.ContentAlignment.BottomRight; this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.arLabel7.SignColor = System.Drawing.Color.Yellow; this.tableLayoutPanel1.Location = new System.Drawing.Point(10, 10);
this.arLabel7.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic); this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.arLabel7.Size = new System.Drawing.Size(165, 100); this.tableLayoutPanel1.RowCount = 4;
this.arLabel7.TabIndex = 6; this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.arLabel7.Text = "자동 재시작"; this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.arLabel7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.arLabel7.TextShadow = true; this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.arLabel7.TextVisible = true; this.tableLayoutPanel1.Size = new System.Drawing.Size(633, 356);
this.arLabel7.Click += new System.EventHandler(this.arLabel7_Click); this.tableLayoutPanel1.TabIndex = 7;
//
// button1
//
this.button1.Dock = System.Windows.Forms.DockStyle.Fill;
this.button1.Location = new System.Drawing.Point(3, 270);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(205, 83);
this.button1.TabIndex = 7;
this.button1.Text = "Map Editor";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click_1);
//
// button2
//
this.button2.Dock = System.Windows.Forms.DockStyle.Fill;
this.button2.Enabled = false;
this.button2.Location = new System.Drawing.Point(214, 270);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(205, 83);
this.button2.TabIndex = 7;
this.button2.Text = "---";
this.button2.UseVisualStyleBackColor = true;
//
// button3
//
this.button3.Dock = System.Windows.Forms.DockStyle.Fill;
this.button3.Enabled = false;
this.button3.Location = new System.Drawing.Point(425, 270);
this.button3.Name = "button3";
this.button3.Size = new System.Drawing.Size(205, 83);
this.button3.TabIndex = 7;
this.button3.Text = "---";
this.button3.UseVisualStyleBackColor = true;
// //
// fSystem // fSystem
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); this.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40)))));
this.ClientSize = new System.Drawing.Size(519, 451); this.ClientSize = new System.Drawing.Size(653, 473);
this.Controls.Add(this.arLabel7); this.Controls.Add(this.tableLayoutPanel1);
this.Controls.Add(this.arLabel5);
this.Controls.Add(this.arLabel3);
this.Controls.Add(this.label2); this.Controls.Add(this.label2);
this.Controls.Add(this.label1); this.Controls.Add(this.label1);
this.Controls.Add(this.arLabel4); this.Controls.Add(this.arLabel4);
this.Controls.Add(this.lbMsg);
this.Controls.Add(this.arLabel9);
this.Controls.Add(this.arLabel10);
this.Controls.Add(this.arLabel1);
this.Controls.Add(this.arLabel2);
this.Controls.Add(this.arLabel6);
this.MaximizeBox = false; this.MaximizeBox = false;
this.MinimizeBox = false; this.MinimizeBox = false;
this.Name = "fSystem"; this.Name = "fSystem";
this.Padding = new System.Windows.Forms.Padding(10);
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "fSystem"; this.Text = "fSystem";
this.Load += new System.EventHandler(this.fSystem_Load); this.Load += new System.EventHandler(this.fSystem_Load);
this.tableLayoutPanel1.ResumeLayout(false);
this.ResumeLayout(false); this.ResumeLayout(false);
} }
#endregion #endregion
private arCtl.arLabel lbMsg; private System.Windows.Forms.Button btOpenDir;
private arCtl.arLabel arLabel4; private System.Windows.Forms.Button arLabel4;
private arCtl.arLabel arLabel6; private System.Windows.Forms.Button btTaskMgr;
private arCtl.arLabel arLabel9; private System.Windows.Forms.Button btShutdown;
private arCtl.arLabel arLabel10; private System.Windows.Forms.Button btRestart;
private arCtl.arLabel arLabel1; private System.Windows.Forms.Button btStartMenu;
private arCtl.arLabel arLabel2; private System.Windows.Forms.Button btProcessList;
private System.Windows.Forms.Label label1; private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2; private System.Windows.Forms.Label label2;
private arCtl.arLabel arLabel3; private System.Windows.Forms.Button btEmulator;
private arCtl.arLabel arLabel5; private System.Windows.Forms.Button btMakePatch;
private arCtl.arLabel arLabel7; private System.Windows.Forms.Button btAutoRestart;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.Button button3;
} }
} }

View File

@@ -154,5 +154,13 @@ namespace Project.Dialog
{ {
PUB.SystemReboot(5,true); PUB.SystemReboot(5,true);
} }
private void button1_Click_1(object sender, EventArgs e)
{
//mapeditor
var fn = new System.IO.FileInfo(@".\test\AGVMapEditor.exe");
if (fn.Exists == false) return;
UTIL.RunExplorer(fn.FullName);
}
} }
} }

View File

@@ -0,0 +1,239 @@
namespace Project.Dialog
{
partial class fXbeeSetting
{
/// <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.components = new System.ComponentModel.Container();
this.button1 = new System.Windows.Forms.Button();
this.tbBaud = new System.Windows.Forms.TextBox();
this.tbPortName = new System.Windows.Forms.ComboBox();
this.panel1 = new System.Windows.Forms.Panel();
this.button2 = new System.Windows.Forms.Button();
this.btmy = new System.Windows.Forms.Button();
this.tbmy = new System.Windows.Forms.TextBox();
this.btch = new System.Windows.Forms.Button();
this.tbch = new System.Windows.Forms.TextBox();
this.btpand = new System.Windows.Forms.Button();
this.tbpanid = new System.Windows.Forms.TextBox();
this.panel2 = new System.Windows.Forms.Panel();
this.rtXbee = new arCtl.LogTextBox();
this.serialPort1 = new System.IO.Ports.SerialPort(this.components);
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
this.SuspendLayout();
//
// button1
//
this.button1.Location = new System.Drawing.Point(25, 45);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(227, 26);
this.button1.TabIndex = 0;
this.button1.Text = "open/close";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// tbBaud
//
this.tbBaud.Font = new System.Drawing.Font("굴림", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.tbBaud.Location = new System.Drawing.Point(152, 13);
this.tbBaud.Name = "tbBaud";
this.tbBaud.Size = new System.Drawing.Size(100, 26);
this.tbBaud.TabIndex = 2;
this.tbBaud.Text = "9600";
this.tbBaud.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
//
// tbPortName
//
this.tbPortName.Font = new System.Drawing.Font("굴림", 12F);
this.tbPortName.FormattingEnabled = true;
this.tbPortName.Location = new System.Drawing.Point(25, 15);
this.tbPortName.Name = "tbPortName";
this.tbPortName.Size = new System.Drawing.Size(121, 24);
this.tbPortName.TabIndex = 3;
//
// panel1
//
this.panel1.Controls.Add(this.button2);
this.panel1.Controls.Add(this.btmy);
this.panel1.Controls.Add(this.tbmy);
this.panel1.Controls.Add(this.btch);
this.panel1.Controls.Add(this.tbch);
this.panel1.Controls.Add(this.btpand);
this.panel1.Controls.Add(this.tbpanid);
this.panel1.Controls.Add(this.tbPortName);
this.panel1.Controls.Add(this.button1);
this.panel1.Controls.Add(this.tbBaud);
this.panel1.Dock = System.Windows.Forms.DockStyle.Top;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(580, 118);
this.panel1.TabIndex = 4;
//
// button2
//
this.button2.Location = new System.Drawing.Point(293, 15);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(75, 89);
this.button2.TabIndex = 10;
this.button2.Text = "Read Setting";
this.button2.UseVisualStyleBackColor = true;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// btmy
//
this.btmy.Location = new System.Drawing.Point(480, 78);
this.btmy.Name = "btmy";
this.btmy.Size = new System.Drawing.Size(86, 26);
this.btmy.TabIndex = 9;
this.btmy.Text = "My";
this.btmy.UseVisualStyleBackColor = true;
this.btmy.Click += new System.EventHandler(this.btmy_Click);
//
// tbmy
//
this.tbmy.Font = new System.Drawing.Font("굴림", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.tbmy.Location = new System.Drawing.Point(374, 78);
this.tbmy.Name = "tbmy";
this.tbmy.Size = new System.Drawing.Size(100, 26);
this.tbmy.TabIndex = 8;
this.tbmy.Text = "9600";
this.tbmy.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
//
// btch
//
this.btch.Location = new System.Drawing.Point(480, 47);
this.btch.Name = "btch";
this.btch.Size = new System.Drawing.Size(86, 26);
this.btch.TabIndex = 7;
this.btch.Text = "Channel";
this.btch.UseVisualStyleBackColor = true;
this.btch.Click += new System.EventHandler(this.btch_Click);
//
// tbch
//
this.tbch.Font = new System.Drawing.Font("굴림", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.tbch.Location = new System.Drawing.Point(374, 47);
this.tbch.Name = "tbch";
this.tbch.Size = new System.Drawing.Size(100, 26);
this.tbch.TabIndex = 6;
this.tbch.Text = "9600";
this.tbch.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
//
// btpand
//
this.btpand.Location = new System.Drawing.Point(480, 15);
this.btpand.Name = "btpand";
this.btpand.Size = new System.Drawing.Size(86, 26);
this.btpand.TabIndex = 5;
this.btpand.Text = "PanID";
this.btpand.UseVisualStyleBackColor = true;
this.btpand.Click += new System.EventHandler(this.btpand_Click);
//
// tbpanid
//
this.tbpanid.Font = new System.Drawing.Font("굴림", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.tbpanid.Location = new System.Drawing.Point(374, 15);
this.tbpanid.Name = "tbpanid";
this.tbpanid.Size = new System.Drawing.Size(100, 26);
this.tbpanid.TabIndex = 4;
this.tbpanid.Text = "9600";
this.tbpanid.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
//
// panel2
//
this.panel2.Controls.Add(this.rtXbee);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(0, 118);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(580, 338);
this.panel2.TabIndex = 5;
//
// rtXbee
//
this.rtXbee.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
this.rtXbee.ColorList = new arCtl.sLogMessageColor[0];
this.rtXbee.DateFormat = "mm:ss.fff";
this.rtXbee.DefaultColor = System.Drawing.Color.LightGray;
this.rtXbee.Dock = System.Windows.Forms.DockStyle.Fill;
this.rtXbee.EnableDisplayTimer = false;
this.rtXbee.EnableGubunColor = true;
this.rtXbee.Font = new System.Drawing.Font("맑은 고딕", 6.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.rtXbee.ListFormat = "[{0}] {1}";
this.rtXbee.Location = new System.Drawing.Point(0, 0);
this.rtXbee.MaxListCount = ((ushort)(1000));
this.rtXbee.MaxTextLength = ((uint)(400000u));
this.rtXbee.MessageInterval = 50;
this.rtXbee.Name = "rtXbee";
this.rtXbee.Size = new System.Drawing.Size(580, 338);
this.rtXbee.TabIndex = 2;
this.rtXbee.Text = "";
//
// serialPort1
//
this.serialPort1.ReadTimeout = 1000;
this.serialPort1.WriteTimeout = 1000;
//
// fXbeeSetting
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(580, 456);
this.Controls.Add(this.panel2);
this.Controls.Add(this.panel1);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "fXbeeSetting";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "Form1";
this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.fXbeeSetting_FormClosed);
this.Load += new System.EventHandler(this.fXbeeSetting_Load);
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.panel2.ResumeLayout(false);
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Button button1;
private System.Windows.Forms.TextBox tbBaud;
private System.Windows.Forms.ComboBox tbPortName;
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.Panel panel2;
private arCtl.LogTextBox rtXbee;
private System.Windows.Forms.Button btpand;
private System.Windows.Forms.TextBox tbpanid;
private System.Windows.Forms.Button btmy;
private System.Windows.Forms.TextBox tbmy;
private System.Windows.Forms.Button btch;
private System.Windows.Forms.TextBox tbch;
private System.Windows.Forms.Button button2;
private System.IO.Ports.SerialPort serialPort1;
}
}

View File

@@ -0,0 +1,193 @@
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;
using AR;
using COMM;
namespace Project.Dialog
{
public partial class fXbeeSetting : Form
{
public fXbeeSetting()
{
InitializeComponent();
VAR.BOOL[eVarBool.DISABLE_AUTOCONN_XBEE] = true;
PUB.XBE.Close();
this.serialPort1.DataReceived += SerialPort1_DataReceived;
}
private void fXbeeSetting_Load(object sender, EventArgs e)
{
this.tbPortName.Items.Clear();
foreach (var item in System.IO.Ports.SerialPort.GetPortNames())
{
this.tbPortName.Items.Add(item);
}
this.tbPortName.Text = PUB.setting.Port_XBE;
this.tbBaud.Text = PUB.setting.Baud_XBE.ToString();
}
void showlog(string Message)
{
if (rtXbee.Visible)
{
rtXbee.AddMsg(DateTime.Now, "NORMAL", Message);
}
}
void showlog(arCtl.LogTextBox rtRx, DateTime LogTime, string TypeStr, string Message)
{
if (rtRx.Visible)
{
rtRx.AddMsg(LogTime, TypeStr, Message);
}
}
private void button1_Click(object sender, EventArgs e)
{
if (this.serialPort1.IsOpen)
{
serialPort1.Close();
showlog("closed");
}
else
{
serialPort1.PortName = tbPortName.Text;
serialPort1.BaudRate = int.Parse(tbBaud.Text);
serialPort1.Open();
showlog("open");
}
}
private void fXbeeSetting_FormClosed(object sender, FormClosedEventArgs e)
{
VAR.BOOL[eVarBool.DISABLE_AUTOCONN_XBEE] = false;
}
private volatile bool isCommandExecuting = false;
private void SerialPort1_DataReceived(object sender, System.IO.Ports.SerialDataReceivedEventArgs e)
{
if (isCommandExecuting) return;
try
{
string data = serialPort1.ReadExisting();
var hexdata = System.Text.Encoding.Default.GetBytes(data);
var hexstr = string.Join(" ", hexdata.Select(t => t.ToString("X2")));
if (!string.IsNullOrEmpty(data))
{
this.BeginInvoke(new Action(() =>
{
showlog($"RxAsync: {hexstr}");
}));
}
}
catch { }
}
private string Cmd(string cmd, int timeout = 1000)
{
isCommandExecuting = true;
try
{
if (!serialPort1.IsOpen) return "Error: Port Closed";
serialPort1.DiscardInBuffer();
serialPort1.Write(cmd);
System.Threading.Thread.Sleep(20);
serialPort1.ReadTimeout = timeout;
string res = serialPort1.ReadTo("\r");
System.Threading.Thread.Sleep(20);
showlog($"Tx:{cmd.Trim()}, Rx:{res}");
//명령수신호 10ms 대기후 다음 명령을 전송
System.Threading.Thread.Sleep(20);
return res;
}
catch (Exception ex)
{
showlog($"Err: {ex.Message}");
return "Error";
}
finally
{
isCommandExecuting = false;
}
}
private void btpand_Click(object sender, EventArgs e)
{
//각명령마다 회신을 확인하고 다음명령을 실행해야함
//명령수신호 10ms 대기후 다음 명령을 전송
//명령을 설정하면 응답은 OK\d 형태로 입력된다.
var cmds = new string[] {
"+++",
$"ATID{tbpanid.Text}\r" ,
$"ATCN\r"};
foreach (var cmd in cmds)
{
if(!Cmd(cmd).Contains("OK"))
{
showlog("FAIL");
break;
}
}
}
private void btch_Click(object sender, EventArgs e)
{
var cmds = new string[] {
"+++",
$"ATCH{tbch.Text}\r" ,
$"ATCN\r"};
foreach (var cmd in cmds)
{
if (!Cmd(cmd).Contains("OK"))
{
showlog("FAIL");
break;
}
}
}
private void btmy_Click(object sender, EventArgs e)
{
var cmds = new string[] {
"+++",
$"ATMY{tbmy.Text}\r" ,
$"ATCN\r"};
foreach (var cmd in cmds)
{
if (!Cmd(cmd).Contains("OK"))
{
showlog("FAIL");
break;
}
}
}
private void button2_Click(object sender, EventArgs e)
{
//read all(id,ch,my)
if (Cmd("+++").Contains("OK"))
{
var id = Cmd("ATID\r");
var ch = Cmd("ATCH\r");
var my = Cmd("ATMY\r");
Cmd("ATCN\r");
this.BeginInvoke(new Action(() => {
this.tbpanid.Text = id;
this.tbch.Text = ch;
this.tbmy.Text = my;
}));
}
}
}
}

View File

@@ -0,0 +1,123 @@
<?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>
<metadata name="serialPort1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>

View File

@@ -647,7 +647,7 @@ namespace Project
/// <param name="rfidId">읽은 RFID ID</param> /// <param name="rfidId">읽은 RFID ID</param>
/// <param name="motorDirection">모터 방향 (Forward/Backward)</param> /// <param name="motorDirection">모터 방향 (Forward/Backward)</param>
/// <returns>업데이트 성공 여부</returns> /// <returns>업데이트 성공 여부</returns>
public static bool UpdateAGVFromRFID(string rfidId, AgvDirection motorDirection = AgvDirection.Forward) public static bool UpdateAGVFromRFID(ushort rfidId, AgvDirection motorDirection = AgvDirection.Forward)
{ {
var _mapNodes = PUB._mapCanvas.Nodes; var _mapNodes = PUB._mapCanvas.Nodes;
if (_virtualAGV == null || _mapNodes == null) return false; if (_virtualAGV == null || _mapNodes == null) return false;

View File

@@ -113,6 +113,13 @@ namespace Project
{ {
case AGVNavigationCore.Models.StationType.Buffer: case AGVNavigationCore.Models.StationType.Buffer:
//현재위치가 마지막경로의 NODEID와 일치해야한다 //현재위치가 마지막경로의 NODEID와 일치해야한다
if (PUB._virtualAGV.CurrentPath == null)
{
PUB.log.AddAT("목적지 버퍼이동완료 했지만 상세경로가 없습니다");
PUB.XBE.BufferInComplete = false;
PUB.XBE.BufferOutComplete = false;
break;
}
var lastPath = PUB._virtualAGV.CurrentPath.DetailedPath.LastOrDefault(); var lastPath = PUB._virtualAGV.CurrentPath.DetailedPath.LastOrDefault();
if (lastPath.NodeId.Equals(PUB._virtualAGV.CurrentNode.Id)) if (lastPath.NodeId.Equals(PUB._virtualAGV.CurrentNode.Id))
{ {

View File

@@ -54,8 +54,8 @@ namespace Project
// 1분 타임아웃 체크 // 1분 타임아웃 체크
if (stepTime.TotalMinutes >= 1) if (stepTime.TotalMinutes >= 1)
{ {
PUB.XBE.errorMessage = $"충전해제가 실패되었습니다(1분)"; PUB.XBE.ErrorMessage = $"충전해제가 실패되었습니다(1분)";
PUB.log.AddE(PUB.XBE.errorMessage); PUB.log.AddE(PUB.XBE.ErrorMessage);
PUB.sm.SetNewStep(eSMStep.IDLE); PUB.sm.SetNewStep(eSMStep.IDLE);
return false; return false;
} }

View File

@@ -17,6 +17,7 @@ namespace Project
{ {
///명령어 재전송 간격(기본 2초) ///명령어 재전송 간격(기본 2초)
var CommandInterval = 2; var CommandInterval = 2;
var funcName = "_SM_RUN_GOTO";
//충전 상태가 OFF되어야 동작하게한다 //충전 상태가 OFF되어야 동작하게한다
if (_SM_RUN_CHGOFF(isFirst, stepTime) == false) if (_SM_RUN_CHGOFF(isFirst, stepTime) == false)
@@ -29,269 +30,48 @@ namespace Project
VAR.TIME.Update(eVarTime.CheckGotoTargetSet); VAR.TIME.Update(eVarTime.CheckGotoTargetSet);
} }
//PUB._virtualAGV. //라이더멈춤이 설정되어있다면 음성으로 알려준다 200409
if (PUB.AGV.system1.stop_by_front_detect == true)
{
var tsSpeak = DateTime.Now - LastSpeakTime;
if (tsSpeak.TotalSeconds >= PUB.setting.alarmSoundTerm)
{
PUB.Speak(Lang.);
LastSpeakTime = DateTime.Now;
}
return false;
}
//목적지가 설정되었는지 체크한다. var idx = 1;
//Z if (PUB.mapctl.Manager.agv.TargetRFID.IsEmpty) if (PUB.sm.RunStepSeq == idx++)
// { {
// //최대 5초간 설정여부를 확인하고 if(PUB._virtualAGV.TargetNode == null)
// if (VAR.TIME.RUN(eVarTime.CheckGotoTargetSet).TotalSeconds > 5) {
// { PUB.log.Add($"대상노드가 없어 이동을할 수 없습니다");
// //실패시에는 READY로 전환한다. PUB.sm.SetNewRunStep(ERunStep.READY);
// PUB.sm.SetNewRunStep(ERunStep.READY); return false;
// PUB.Speak(Lang.목적지가없어대기상태로전환합니다); }
// } PUB.sm.UpdateRunStepSeq();
// return false; return false;
// } }
else if (PUB.sm.RunStepSeq == idx++)
//var idx = 1; {
//var BeforePredictIdx = -1; //모션 전후진 제어
//var predict = PUB.mapctl.Manager.PredictResult; if (UpdateMotionPositionForMark(funcName))
//if (PUB.sm.RunStepSeq == idx++) {
//{ PUB.AGV.AGVMoveStop(funcName);
// PUB.Speak(Lang.위치로이동합니다); PUB.sm.UpdateRunStepSeq();
// PUB.log.Add($"목적지 위치 이동시작({PUB.mapctl.Manager.agv.TargetRFID.Value})"); }
// VAR.TIME.Update(eVarTime.CheckGotoTargetSet); return false;
// VAR.TIME.Set(eVarTime.SendGotoCommand, DateTime.Now.AddDays(-1)); }
// PUB.sm.UpdateRunStepSeq(); else if (PUB.sm.RunStepSeq == idx++)
// return false; {
//} //QC까지 모두 완료되었다.(완전히 정차할때까지 기다린다)
//else if (PUB.sm.RunStepSeq == idx++) PUB.Speak(Lang., true);
//{ PUB.AddEEDB($"홈검색완료({PUB.Result.TargetPos})");
// //멈춰야하는경우 PUB.sm.UpdateRunStepSeq();
// if (predict.MoveState == AGVControl.AGVMoveState.Stop) return false;
// { }
// if (PUB.AGV.system1.agv_run)
// {
// if (VAR.TIME.RUN(eVarTime.SendGotoCommand).TotalSeconds > 2)
// {
// PUB.Speak("AGV Stop");
// PUB.AGV.AGVMoveStop("Predict", arDev.Narumi.eStopOpt.Stop);
// VAR.TIME.Update(eVarTime.SendGotoCommand);
// }
// return false;
// }
// else
// {
// //완료되었거나 턴을진행해야한다
// if (predict.ReasonCode == AGVControl.AGVActionReasonCode.Arrived ||
// predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnMove ||
// predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnPoint)
// {
// GotoTurnStep = 0;
// GotoTurnSetTime = DateTime.Now.AddDays(-1);
// PUB.sm.UpdateRunStepSeq();
// }
// return false;
// }
// }
// else //이동해야하는 경우
// {
// //속도와 방향이 불일치하는 경우 다시 설정한다 (속도: H,L,M,[S]
// AGVControl.AgvDir AGV_Direction = (AGVControl.AgvDir)PUB.AGV.data.Direction;
// AGVControl.AgvSpeed AGV_Speed = (AGVControl.AgvSpeed)PUB.AGV.data.Speed;
// AGVControl.AgvSts AGV_Sts = (AGVControl.AgvSts)PUB.AGV.data.Sts;
// //상태값이 바뀌었다면 전송을 해야한다
// if (predict.Direction != AGV_Direction || predict.MoveSpeed != AGV_Speed || predict.MoveDiv != AGV_Sts)
// {
// if (VAR.TIME.RUN(eVarTime.SendGotoCommand).TotalSeconds > CommandInterval)
// {
// arDev.Narumi.eBunki v_bunki = arDev.Narumi.eBunki.Strate;
// if (predict.MoveDiv == AGVControl.AgvSts.Straight) v_bunki = arDev.Narumi.eBunki.Strate;
// else if (predict.MoveDiv == AGVControl.AgvSts.Left) v_bunki = arDev.Narumi.eBunki.Left;
// else if (predict.MoveDiv == AGVControl.AgvSts.Right) v_bunki = arDev.Narumi.eBunki.Right;
// arDev.Narumi.eMoveDir v_dir = arDev.Narumi.eMoveDir.Backward;
// if (predict.Direction == AGVControl.AgvDir.Forward) v_dir = arDev.Narumi.eMoveDir.Forward;
// else if (predict.Direction == AGVControl.AgvDir.Backward) v_dir = arDev.Narumi.eMoveDir.Backward;
// arDev.Narumi.eMoveSpd v_spd = arDev.Narumi.eMoveSpd.Low;
// if (predict.MoveSpeed == AGVControl.AgvSpeed.Middle) v_spd = arDev.Narumi.eMoveSpd.Middle;
// else if (predict.MoveSpeed == AGVControl.AgvSpeed.High) v_spd = arDev.Narumi.eMoveSpd.High;
// else if (predict.MoveSpeed == AGVControl.AgvSpeed.Low) v_spd = arDev.Narumi.eMoveSpd.Low;
// //이동셋팅을 해준다
// PUB.AGV.AGVMoveSet(new arDev.Narumi.BunkiData
// {
// Bunki = v_bunki,
// Direction = v_dir,
// PBSSensor = 1,
// Speed = v_spd,
// });
// if (predict.MoveSpeed == AGVControl.AgvSpeed.MarkStop)
// {
// PUB.AGV.AGVMoveStop("Predict", arDev.Narumi.eStopOpt.Stop);
// }
// VAR.TIME.Update(eVarTime.SendGotoCommand);
// }
// return false;
// }
// //정지상태라면 이동 명령을 전달한다
// if (PUB.AGV.system1.agv_run == false)
// {
// if (VAR.TIME.RUN(eVarTime.SendGotoCommand).TotalSeconds > CommandInterval)
// {
// PUB.Speak("AGV Start");
// arDev.Narumi.eRunOpt v_dir = arDev.Narumi.eRunOpt.Backward;
// if (predict.Direction == AGVControl.AgvDir.Forward) v_dir = arDev.Narumi.eRunOpt.Forward;
// else if (predict.Direction == AGVControl.AgvDir.Backward) v_dir = arDev.Narumi.eRunOpt.Backward;
// PUB.AGV.AGVMoveRun(v_dir);
// VAR.TIME.Update(eVarTime.SendGotoCommand);
// }
// return false;
// }
// }
// //예측이 업데이트되지 않으면 오류 처리해야한다
// if (BeforePredictIdx == -1) BeforePredictIdx = (int)predict.Idx;
// else if (BeforePredictIdx != predict.Idx) //이전사용한 IDX와 다르다면 예측이 실행된 경우이다
// BeforePredictIdx = (int)predict.Idx;
// else
// {
// //5초이상 예측값이 업데이트되지 않으면 오류 처리한다.
// var tsPredict = DateTime.Now - predict.CreateTime;
// if (tsPredict.TotalSeconds > 5)
// {
// PUB.XBE.SendError(ENIGProtocol.AGVErrorCode.PredictFix, Lang.예측값이계산되지않아이동을중단합니다);
// PUB.Speak(Lang.예측값이계산되지않아이동을중단합니다);
// PUB.sm.SetNewRunStep(ERunStep.READY);
// }
// }
// return false;
//}
//else if (PUB.sm.RunStepSeq == idx++)
//{
// if (predict.ReasonCode == AGVControl.AGVActionReasonCode.Arrived)
// {
// PUB.Speak(Lang.목적지이동이완료되었습니다);
// PUB.sm.SetNewRunStep(ERunStep.READY);
// PUB.sm.UpdateRunStepSeq();
// }
// else if (predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnMove ||
// predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnPoint)
// {
// //턴을 해야하는 경우이다
// //좌턴을 기본으로 진행하며, 좌턴이동 후 마크스탑을 입력한다
// if (GotoTurnStep == 0)
// {
// //턴을 한적이 없으므로 턴을 먼저 진행한다
// arDev.Narumi.eMoveDir moveDir = arDev.Narumi.eMoveDir.Backward;
// if (predict.Direction == AGVControl.AgvDir.Forward) moveDir = arDev.Narumi.eMoveDir.Forward;
// if (PUB.AGV.data.Sts != 'L' || PUB.AGV.data.Speed != 'L' || PUB.AGV.data.Direction != moveDir.ToString()[0])
// {
// //셋팅이 다르다면 3초간격으로 전송한다
// var tsTurnSet = DateTime.Now - GotoTurnSetTime;
// if (tsTurnSet.TotalSeconds > 3)
// {
// PUB.AGV.AGVMoveSet(new arDev.Narumi.BunkiData
// {
// Bunki = arDev.Narumi.eBunki.Left,
// Direction = moveDir,
// PBSSensor = 1,
// Speed = arDev.Narumi.eMoveSpd.Low,
// });
// GotoTurnSetTime = DateTime.Now;
// PUB.log.Add("Turn Bunki Set");
// }
// }
// else
// {
// PUB.mapctl.Manager.agv.CurrentRFID.TurnOK = false;
// PUB.mapctl.Manager.agv.CurrentRFID.TurnStart = DateTime.Now;
// PUB.sm.UpdateRunStepSeq(); //셋팅이 맞으니 다음스텝으로 진행한다
// GotoTurnStep += 1;
// }
// }
// }
// else PUB.sm.UpdateRunStepSeq();
// return false;
//}
//else if (PUB.sm.RunStepSeq == idx++)
//{
// //턴이완료되길 기다린다.
// if (predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnMove ||
// predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnPoint)
// {
// //(최소5초는 기다리고 판단한다)
// if (stepTime.TotalSeconds < 5) return false;
// //최대30초는 기다려준다
// if (stepTime.TotalSeconds > 30)
// {
// var ermsg = "Turn Timeout(30sec)";
// PUB.log.AddE(ermsg);
// PUB.XBE.SendError(ENIGProtocol.AGVErrorCode.TurnTimeout, ermsg);
// PUB.sm.SetNewRunStep(ERunStep.READY);
// }
// //모션이 멈추었다면 턴이완료된것이다.
// if (PUB.AGV.system1.agv_stop)
// {
// if (PUB.AGV.system1.Mark1_check == false && PUB.AGV.system1.Mark2_check == false)
// {
// PUB.log.AddE($"Turn 완료이나 Mark 센서가 확인되지 않았습니다");
// }
// GotoTurnStep += 1;
// PUB.sm.UpdateRunStepSeq();
// }
// else
// {
// //아직 이동중이므로 대기한다
// }
// }
// else PUB.sm.UpdateRunStepSeq(); //기타사항은 다음으로 넘어간다
// return false;
//}
//else if (PUB.sm.RunStepSeq == idx++)
//{
// if (predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnMove ||
// predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnPoint)
// {
// if (GotoTurnStep < 2)
// {
// PUB.XBE.SendError(ENIGProtocol.AGVErrorCode.TurnError, "턴시퀀스 완료 실패");
// PUB.log.AddE($"턴완료시퀀스가 2가아닙니다. 대기 상태로 강제 전환합니다");
// PUB.sm.SetNewRunStep(ERunStep.READY);
// }
// else
// {
// PUB.log.AddI("Turn Complete");
// }
// //방향전환용 턴이라면 이동기록을 추가해서 방향이 맞도록 처리해주자
// if (predict.ReasonCode == AGVControl.AGVActionReasonCode.NeedTurnMove)
// {
// var rfid = PUB.mapctl.Manager.agv.CurrentRFID;
// var lastHistory = PUB.mapctl.Manager.agv.MovementHistory.Last();
// //원래방향에서 반대로 처리한다
// var revDir = lastHistory.Direction == AGVControl.AgvDir.Backward ? AGVControl.AgvDir.Forward : AGVControl.AgvDir.Backward;
// PUB.mapctl.Manager.agv.AddToMovementHistory(rfid.Value, rfid.Location, revDir);
// }
// else
// {
// //이동용 RFID에서 턴명령이 들어있는경우였다
// PUB.mapctl.Manager.agv.CurrentRFID.TurnEnd = DateTime.Now;
// PUB.mapctl.Manager.agv.CurrentRFID.TurnOK = true;
// }
// PUB.sm.UpdateRunStepSeq();
// }
// else PUB.sm.UpdateRunStepSeq();
// return false;
//}
//좌턴이동명령 전송
//마크스탑전송
//마크스탑이 확인되면 나머지는 경로예측에 맡긴다
return true; return true;
} }

View File

@@ -13,8 +13,11 @@ namespace Project
public Boolean _SM_RUN_POSCHK(bool isFirst, TimeSpan stepTime) public Boolean _SM_RUN_POSCHK(bool isFirst, TimeSpan stepTime)
{ {
//현재위치가 설정되어있는지 확인한다, 현재위치값이 있는 경우 True 를 반환 //현재위치가 설정되어있는지 확인한다, 현재위치값이 있는 경우 True 를 반환
var currentnode = PUB.FindByNodeID(PUB._virtualAGV.CurrentNode.Id); if (PUB._virtualAGV.CurrentNode != null && PUB._virtualAGV.PrevNode != null)
if (currentnode != null) return true; return true;
//최소2개의 노드정보가 있어야 진행가능하므로 prevNode 값이 있는지 확인한다.
//이동을 하지 않고있다면 전진을 진행한다 //이동을 하지 않고있다면 전진을 진행한다
if (PUB.AGV.system1.agv_run == false) if (PUB.AGV.system1.agv_run == false)
@@ -30,7 +33,7 @@ namespace Project
PBSSensor = 1, PBSSensor = 1,
Speed = arDev.Narumi.eMoveSpd.Low, Speed = arDev.Narumi.eMoveSpd.Low,
}); });
PUB.AGV.AGVMoveRun(); PUB.AGV.AGVMoveRun(arDev.Narumi.eRunOpt.Forward);
VAR.TIME.Update(eVarTime.LastRunCommandTime); VAR.TIME.Update(eVarTime.LastRunCommandTime);
} }
} }

View File

@@ -17,9 +17,6 @@ namespace Project
{ {
PUB.bShutdown = true; PUB.bShutdown = true;
// 장치 관리 태스크 종료
StopDeviceManagementTask();
PUB.AddEEDB("프로그램 종료"); PUB.AddEEDB("프로그램 종료");
PUB.log.Add("Program Close"); PUB.log.Add("Program Close");
PUB.LogFlush(); PUB.LogFlush();

View File

@@ -117,6 +117,11 @@ namespace Project
PUB.sm.SetNewRunStep(ERunStep.READY); PUB.sm.SetNewRunStep(ERunStep.READY);
return false; return false;
} }
else
{
PUB._mapCanvas.CurrentPath = PathResult.result;
PUB._virtualAGV.SetPath(PathResult.result);
}
PUB.log.AddI($"경로생성 {PUB._virtualAGV.StartNode.RfidId} -> {PUB._virtualAGV.TargetNode.RfidId}"); PUB.log.AddI($"경로생성 {PUB._virtualAGV.StartNode.RfidId} -> {PUB._virtualAGV.TargetNode.RfidId}");
} }
@@ -133,8 +138,16 @@ namespace Project
return false; return false;
} }
//predict 를 이용하여 다음 이동을 모두 확인한다. //predict 를 이용하여 다음 이동을 모두 확인한다.
var nextAction = PUB._virtualAGV.Predict(); var nextAction = PUB._virtualAGV.Predict();
if(nextAction.Reason == AGVNavigationCore.Models.eAGVCommandReason.PathOut)
{
//경로이탈
PUB._virtualAGV.CurrentPath.DetailedPath.Clear();
return false;
}
var message = $"[다음 행동 예측]\n\n" + var message = $"[다음 행동 예측]\n\n" +
$"모터: {nextAction.Motor}\n" + $"모터: {nextAction.Motor}\n" +
@@ -244,7 +257,7 @@ namespace Project
PBSSensor = 1, PBSSensor = 1,
Speed = arDev.Narumi.eMoveSpd.Low, Speed = arDev.Narumi.eMoveSpd.Low,
}); });
PUB.AGV.AGVMoveRun();// PUB.AGV.AGVMoveRun( arDev.Narumi.eRunOpt.Forward);//
tm_gocharge_command = DateTime.Now; tm_gocharge_command = DateTime.Now;
} }
} }
@@ -265,7 +278,13 @@ namespace Project
PUB.AGV.error.Emergency == false && PUB.AGV.error.Emergency == false &&
PUB.AGV.system1.agv_run == false) PUB.AGV.system1.agv_run == false)
{ {
//PUB.PLC.Move(Device.PLC.Rundirection.Backward, "UpdateMotionPosition #1(" + sender + ")"); PUB.AGV.AGVMoveSet(new arDev.Narumi.BunkiData
{
Bunki = arDev.Narumi.eBunki.Strate,
Direction = arDev.Narumi.eMoveDir.Backward,
PBSSensor = 1,
Speed = arDev.Narumi.eMoveSpd.Low,
});
PUB.AGV.AGVMoveRun(arDev.Narumi.eRunOpt.Backward);// PUB.AGV.AGVMoveRun(arDev.Narumi.eRunOpt.Backward);//
LastCommandTime = DateTime.Now; LastCommandTime = DateTime.Now;
} }

View File

@@ -18,22 +18,19 @@ namespace Project
{ {
private void AGV_Message(object sender, arDev.Narumi.MessageEventArgs e) private void AGV_Message(object sender, arDev.Narumi.MessageEventArgs e)
{ {
if (e.MsgType == arDev.arRS232.MessageType.Normal) if (e.MsgType == arDev.NarumiSerialComm.MessageType.Normal)
PUB.logagv.AddE(e.Message); PUB.logagv.AddE(e.Message);
else if (e.MsgType == arDev.arRS232.MessageType.Normal) else if (e.MsgType == arDev.NarumiSerialComm.MessageType.Normal)
PUB.logagv.Add(e.Message); PUB.logagv.Add(e.Message);
else if (e.MsgType == arDev.arRS232.MessageType.Recv) else if (e.MsgType == arDev.NarumiSerialComm.MessageType.Recv)
{ {
if (e.Message.Substring(1).StartsWith("STS") == false) if (e.Message.Substring(1).StartsWith("STS") == false)
PUB.logagv.Add("AGV-RX", e.Message); PUB.logagv.Add("AGV-RX", e.Message);
} }
else if (e.MsgType == arDev.arRS232.MessageType.Send) else if (e.MsgType == arDev.NarumiSerialComm.MessageType.Send)
PUB.logagv.Add("AGV-TX", e.Message); PUB.logagv.Add("AGV-TX", e.Message);
else else
{ {
PUB.logagv.Add(e.MsgType.ToString(), e.Message); PUB.logagv.Add(e.MsgType.ToString(), e.Message);
} }
} }
@@ -44,6 +41,7 @@ namespace Project
{ {
try try
{ {
VAR.TIME.Set(eVarTime.LastRecv_AGV, DateTime.Now);
//데이터 파싱 //데이터 파싱
switch (e.DataType) switch (e.DataType)
{ {
@@ -55,7 +53,7 @@ namespace Project
var agv_chg = PUB.AGV.system1.Battery_charging; var agv_chg = PUB.AGV.system1.Battery_charging;
var agv_stp = PUB.AGV.system1.agv_stop; var agv_stp = PUB.AGV.system1.agv_stop;
var agv_run = PUB.AGV.system1.agv_run; var agv_run = PUB.AGV.system1.agv_run;
var agv_mrk = PUB.AGV.signal.mark_sensor; var agv_mrk = PUB.AGV.signal1.mark_sensor;
//if (chg_run && PUB.AGV.system1.agv_run) PUB.Speak("이동을 시작 합니다"); //if (chg_run && PUB.AGV.system1.agv_run) PUB.Speak("이동을 시작 합니다");
@@ -108,8 +106,7 @@ namespace Project
PUB.log.Add($"충전상태전환 {agv_chg}"); PUB.log.Add($"충전상태전환 {agv_chg}");
VAR.BOOL[eVarBool.FLAG_CHARGEONA] = agv_chg; VAR.BOOL[eVarBool.FLAG_CHARGEONA] = agv_chg;
} }
//자동충전해제시 곧바로 수동 충전되는 경우가 있어 자동 상태를 BMS에 넣는다 230118
PUB.BMS.AutoCharge = agv_chg;
if (PUB.AGV.error.Charger_pos_error != VAR.BOOL[eVarBool.CHG_POSERR]) if (PUB.AGV.error.Charger_pos_error != VAR.BOOL[eVarBool.CHG_POSERR])
{ {
@@ -131,10 +128,10 @@ namespace Project
} }
//마크센서 상태가 변경이 되었다면 //마크센서 상태가 변경이 되었다면
if (VAR.BOOL[eVarBool.MARK_SENSOR] != PUB.AGV.signal.mark_sensor) if (VAR.BOOL[eVarBool.MARK_SENSOR] != PUB.AGV.signal1.mark_sensor)
{ {
PUB.logagv.Add($"MARK_SENSOR 변경({PUB.AGV.signal.mark_sensor})"); PUB.logagv.Add($"MARK_SENSOR 변경({PUB.AGV.signal1.mark_sensor})");
VAR.BOOL[eVarBool.MARK_SENSOR] = PUB.AGV.signal.mark_sensor; VAR.BOOL[eVarBool.MARK_SENSOR] = PUB.AGV.signal1.mark_sensor;
//AGV가 멈췄고 마크센서가 ON되었다면 마지막 RFID 위치가 확정된경우이다 //AGV가 멈췄고 마크센서가 ON되었다면 마지막 RFID 위치가 확정된경우이다
if (agv_stp && VAR.BOOL[eVarBool.MARK_SENSOR]) if (agv_stp && VAR.BOOL[eVarBool.MARK_SENSOR])
@@ -161,7 +158,7 @@ namespace Project
{ {
//자동 실행 중이다. //자동 실행 중이다.
PUB.Result.LastTAG = PUB.AGV.data.TagNo.ToString("0000"); PUB.Result.LastTAG = PUB.AGV.data.TagNo;//.ToString("0000");
PUB.log.Add($"AGV 태그수신 : {PUB.AGV.data.TagNo} LastTag:{PUB.Result.LastTAG}"); PUB.log.Add($"AGV 태그수신 : {PUB.AGV.data.TagNo} LastTag:{PUB.Result.LastTAG}");
//POT/NOT 보면 일단 바로 멈추게한다 //POT/NOT 보면 일단 바로 멈추게한다
if (PUB.Result.CurrentPos == ePosition.POT || PUB.Result.CurrentPos == ePosition.NOT) if (PUB.Result.CurrentPos == ePosition.POT || PUB.Result.CurrentPos == ePosition.NOT)
@@ -172,7 +169,7 @@ namespace Project
} }
//virtual agv setting //virtual agv setting
var CurrentNode = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.RfidId.Equals(PUB.Result.LastTAG, StringComparison.OrdinalIgnoreCase)); var CurrentNode = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.RfidId == PUB.Result.LastTAG);
if (CurrentNode == null) if (CurrentNode == null)
{ {
//없는 노드는 자동으로 추가한다 //없는 노드는 자동으로 추가한다
@@ -237,7 +234,6 @@ namespace Project
PUB._mapCanvas.PredictMessage = message; PUB._mapCanvas.PredictMessage = message;
} }
} }
catch (Exception ex) catch (Exception ex)
{ {

View File

@@ -25,9 +25,12 @@ namespace Project
DateTime lastbmstime = DateTime.Now; DateTime lastbmstime = DateTime.Now;
private void Bms_Message(object sender, arDev.BMS.MessageEventArgs e) private void Bms_Message(object sender, arDev.BMS.MessageEventArgs e)
{ {
if (e.MsgType == arDev.arRS232.MessageType.Error) PUB.logbms.AddE( e.Message);
if (e.MsgType == arDev.BMSSerialComm.MessageType.Error) PUB.logbms.AddE(e.Message);
else else
{ {
VAR.TIME[eVarTime.LastRecv_BAT] = DateTime.Now;
var hexstr = e.Data.GetHexString().Trim(); var hexstr = e.Data.GetHexString().Trim();
bool addlog = false; bool addlog = false;
var logtimesec = 30; var logtimesec = 30;
@@ -134,31 +137,43 @@ namespace Project
} }
if (addlog) if (addlog)
PUB.logbms.Add("BMS:" + hexstr); {
//if (e.MsgType == arDev.arRS232.MessageType.Recv)
// PUB.logbms.Add("RX", e.Data.GetHexString());
//else if (e.MsgType == arDev.arRS232.MessageType.Send)
// PUB.logbms.Add("TX", e.Data.GetHexString());
//else
{
PUB.logbms.Add(e.MsgType.ToString(),e.Message);
}
}
} }
} }
private void BMS_ChargeDetect(object sender, arDev.ChargetDetectArgs e) private void BMS_ChargeDetect(object sender, arDev.ChargetDetectArgs e)
{ {
//자동충전중이아니고 멈춰있다면 수동 충전으로 전환한다 //자동충전중이아니고 멈춰있다면 수동 충전으로 전환한다
if (PUB.AGV.system1.Battery_charging == false && PUB.AGV.system1.agv_stop == true && VAR.BOOL[eVarBool.FLAG_CHARGEONM] == false) VAR.TIME[eVarTime.LastRecv_BAT] = DateTime.Now;
if (e.Detected == true) //충전이 감지되었다.
{ {
if (PUB.setting.DetectManualCharge) if (VAR.BOOL[eVarBool.FLAG_AUTORUN] == false && VAR.BOOL[eVarBool.FLAG_CHARGEONM] == false)
{ {
VAR.BOOL[eVarBool.FLAG_CHARGEONM] = true; VAR.BOOL[eVarBool.FLAG_CHARGEONM] = true;
PUB.Speak(Lang.); PUB.Speak(Lang.);
if (PUB.AGV.system1.agv_run == true) PUB.AGV.AGVMoveStop("수동충전감지");
} }
else
{
PUB.log.Add($"충전이 감지되었지만 메뉴얼 전환 비활성화됨");
} }
else PUB.logbms.AddI("Battery Charge Off");
} }
}
private void Bms_BMSDataReceive(object sender, EventArgs e) private void Bms_BMSDataReceive(object sender, EventArgs e)
{ {
VAR.TIME[eVarTime.LastRecv_BAT] = DateTime.Now;
//PUB.mapctl.Manager.agv.BatteryLevel = PUB.BMS.Current_Level; //PUB.mapctl.Manager.agv.BatteryLevel = PUB.BMS.Current_Level;
//PUB.mapctl.Manager.agv.BatteryTemp1 = PUB.BMS.Current_temp1; //PUB.mapctl.Manager.agv.BatteryTemp1 = PUB.BMS.Current_temp1;
//PUB.mapctl.Manager.agv.BatteryTemp2 = PUB.BMS.Current_temp2; //PUB.mapctl.Manager.agv.BatteryTemp2 = PUB.BMS.Current_temp2;
@@ -188,6 +203,7 @@ namespace Project
} }
private void BMS_BMSCellDataReceive(object sender, arDev.BMSCelvoltageEventArgs e) private void BMS_BMSCellDataReceive(object sender, arDev.BMSCelvoltageEventArgs e)
{ {
VAR.TIME[eVarTime.LastRecv_BAT] = DateTime.Now;
EEMStatus.MakeBMSInformation_Cell(); EEMStatus.MakeBMSInformation_Cell();
} }
} }

View File

@@ -76,7 +76,8 @@ namespace Project
} }
} }
string lockstep = string.Empty;
System.Threading.ManualResetEvent mreloop = new System.Threading.ManualResetEvent(true);
void sm_Running(object sender, StateMachine.StateMachine.RunningEventArgs e) void sm_Running(object sender, StateMachine.StateMachine.RunningEventArgs e)
{ {
@@ -89,6 +90,11 @@ namespace Project
} }
else PUB.sm.WaitFirstRun = false; else PUB.sm.WaitFirstRun = false;
if (mreloop.WaitOne(1) == false) return;
mreloop.Reset();
lockstep = e.Step.ToString();
//main loop //main loop
switch (e.Step) switch (e.Step)
{ {
@@ -154,8 +160,6 @@ namespace Project
UpdateStatusMessage("준비 완료", Color.Red, Color.Gold); UpdateStatusMessage("준비 완료", Color.Red, Color.Gold);
if (startuptime.Year == 1982) startuptime = DateTime.Now; if (startuptime.Year == 1982) startuptime = DateTime.Now;
// 장치 관리 태스크 시작 (IDLE 진입 시 한 번만)
StartDeviceManagementTask();
// 동기화 모드 종료 (혹시 남아있을 경우) // 동기화 모드 종료 (혹시 남아있을 경우)
if (PUB._mapCanvas != null) if (PUB._mapCanvas != null)
@@ -191,8 +195,11 @@ namespace Project
if (e.isFirst) if (e.isFirst)
{ {
// 동기화 완료 시 캔버스 모드 복귀 // 동기화 완료 시 캔버스 모드 복귀
this.Invoke(new Action(() => {
if (PUB._mapCanvas != null) if (PUB._mapCanvas != null)
PUB._mapCanvas.SetSyncStatus("설정 동기화", 0f, "환경설정 값으로 AGV컨트롤러를 설정 합니다"); PUB._mapCanvas.SetSyncStatus("설정 동기화", 0f, "환경설정 값으로 AGV컨트롤러를 설정 합니다");
}));
} }
if (_SM_RUN_SYNC(runStepisFirst, PUB.sm.GetRunSteptime)) if (_SM_RUN_SYNC(runStepisFirst, PUB.sm.GetRunSteptime))
{ {
@@ -207,7 +214,6 @@ namespace Project
PUB.Speak( Lang.); PUB.Speak( Lang.);
PUB.sm.SetNewStep(eSMStep.IDLE); PUB.sm.SetNewStep(eSMStep.IDLE);
return;
} }
break; break;
@@ -271,6 +277,8 @@ namespace Project
} }
break; break;
} }
mreloop.Set();
} }
void DeleteFile(string path) void DeleteFile(string path)

View File

@@ -21,22 +21,208 @@ namespace Project
{ {
DateTime chargesynctime = DateTime.Now; DateTime chargesynctime = DateTime.Now;
DateTime agvsendstarttime = DateTime.Now; DateTime agvsendstarttime = DateTime.Now;
DateTime lastXbeStatusSendTime = DateTime.Now;
DateTime lastBmsQueryTime = DateTime.Now;
object connectobj = new object();
void sm_SPS(object sender, EventArgs e) void sm_SPS(object sender, EventArgs e)
{ {
if (PUB.sm.Step < eSMStep.IDLE || PUB.sm.Step >= eSMStep.CLOSING) return; if (PUB.sm == null || PUB.sm.Step < eSMStep.IDLE || PUB.sm.Step >= eSMStep.CLOSING || PUB.bShutdown == true) return;
// SPS는 이제 간단한 작업만 수행 // SPS는 이제 간단한 작업만 수행
// 장치 연결 및 상태 전송은 별도 태스크(_DeviceManagement.cs)에서 처리 // 장치 연결 및 상태 전송은 별도 태스크(_DeviceManagement.cs)에서 처리
// 장치 연결이 별도로 존재할때 1회 수신 후 통신이 전체 먹통되는 증상이 있어 우선 복귀 251215
try try
{ {
// 여기에 SPS에서 처리해야 할 간단한 작업만 남김
// 현재는 비어있음 - 필요한 경우 추가 // ========== 1. 장치 연결 관리 ==========
// AGV 연결
lock (connectobj)
{
ConnectSerialPort(PUB.AGV, PUB.setting.Port_AGV, PUB.setting.Baud_AGV,
eVarTime.LastConn_AGV, eVarTime.LastConnTry_AGV, eVarTime.LastRecv_AGV);
}
// XBee 연결
lock (connectobj)
{
if (VAR.BOOL[eVarBool.DISABLE_AUTOCONN_XBEE] == false)
{
ConnectSerialPort(PUB.XBE, PUB.setting.Port_XBE, PUB.setting.Baud_XBE,
eVarTime.LastConn_XBE, eVarTime.LastConnTry_XBE, null);
}
}
// BMS 연결
lock (connectobj)
{
if (PUB.BMS.IsOpen == false)
{
var ts = VAR.TIME.RUN(eVarTime.LastConn_BAT);
if (ts.TotalSeconds > 3)
{
PUB.log.Add($"BMS 연결 시도: {PUB.setting.Port_BAT}");
PUB.BMS.PortName = PUB.setting.Port_BAT;
if (PUB.BMS.Open())
PUB.log.AddI($"BMS 연결 완료({PUB.setting.Port_BAT})");
VAR.TIME.Update(eVarTime.LastConn_BAT);
VAR.TIME.Update(eVarTime.LastConnTry_BAT);
}
}
else if (PUB.BMS.IsValid == false)
{
var ts = VAR.TIME.RUN(eVarTime.LastConnTry_BAT);
if (ts.TotalSeconds > (Math.Max(10, PUB.setting.interval_bms) * 2.5))
{
this.BeginInvoke(new Action(() =>
{
PUB.log.Add("BMS 자동 연결 해제 (응답 없음)");
PUB.BMS.Close();
}));
VAR.TIME.Set(eVarTime.LastConn_BAT, DateTime.Now.AddSeconds(5));
}
}
}
// ========== 2. XBee 상태 전송 ==========
if (PUB.XBE != null && PUB.XBE.IsOpen)
{
var tsXbe = DateTime.Now - lastXbeStatusSendTime;
if (tsXbe.TotalSeconds >= PUB.setting.interval_xbe)
{
lastXbeStatusSendTime = DateTime.Now;
ThreadPool.QueueUserWorkItem(_ =>
{
try
{
PUB.XBE.SendStatus();
}
catch (Exception ex)
{
PUB.log.AddE($"XBee SendStatus 오류: {ex.Message}");
}
});
}
}
// ========== 3. BMS 쿼리 및 배터리 경고 ==========
if (PUB.BMS != null && PUB.BMS.IsOpen)
{
var tsBms = DateTime.Now - lastBmsQueryTime;
if (tsBms.TotalSeconds >= PUB.setting.interval_bms)
{
lastBmsQueryTime = DateTime.Now;
ThreadPool.QueueUserWorkItem(_ =>
{
try
{
PUB.BMS.SendQuery();
}
catch (Exception ex)
{
PUB.log.AddE($"BMS SendQuery 오류: {ex.Message}");
}
});
}
// 배터리 경고음
try
{
Update_BatteryWarnSpeak();
}
catch (Exception ex)
{
PUB.log.AddE($"BatteryWarnSpeak 오류: {ex.Message}");
}
}
} }
catch (Exception ex) catch (Exception ex)
{ {
PUB.log.AddE($"sm_SPS Exception: {ex.Message}"); PUB.log.AddE($"sm_SPS Exception: {ex.Message}");
} }
} }
/// <summary>
/// 시리얼 포트 연결 (arDev.arRS232)
/// </summary>
bool ConnectSerialPort(arDev.ISerialComm dev, string port, int baud, eVarTime conn, eVarTime conntry, eVarTime? recvtime)
{
if (port.isEmpty()) return false;
if (dev.IsOpen == false && port.isEmpty() == false)
{
var tsPLC = VAR.TIME.RUN(conntry);
if (tsPLC.TotalSeconds > 5)
{
VAR.TIME.Update(conntry);
try
{
if (recvtime != null) VAR.TIME.Update(recvtime);
dev.PortName = port;
dev.BaudRate = baud;
PUB.log.Add($"Connect to {port}:{baud}");
if (dev.Open())
{
if (recvtime != null) VAR.TIME[recvtime] = DateTime.Now; //값을 수신한것처럼한다
PUB.log.Add(port, $"[{port}:{baud}] 연결 완료");
}
else
{
//존재하지 않는 포트라면 sync를 벗어난다
var ports = System.IO.Ports.SerialPort.GetPortNames().Select(t => t.ToLower()).ToList();
if (ports.Contains(PUB.setting.Port_AGV.ToLower()) == false)
{
return false;
}
else
{
var errmessage = dev.ErrorMessage;
PUB.log.AddE($"[AGV:{port}:{baud}] {errmessage}");
}
}
VAR.TIME.Update(conn);
VAR.TIME.Update(conntry);
}
catch (Exception ex)
{
PUB.log.AddE(ex.Message);
}
}
}
else if (dev.PortName.Equals(port) == false)
{
this.BeginInvoke(new Action(() =>
{
PUB.log.Add(port, $"포트 변경({dev.PortName}->{port})으로 연결 종료");
VAR.TIME.Set(conntry, DateTime.Now);
dev.Close();
}));
VAR.TIME.Update(conntry);
}
else if (dev.IsOpen && recvtime != null)
{
//연결은 되었으나 통신이 지난지 10초가 지났다면 자동종료한다
var tsRecv = VAR.TIME.RUN(recvtime);
var tsConn = VAR.TIME.RUN(conntry);
if (tsRecv.TotalSeconds > 30 && tsConn.TotalSeconds > 5)
{
this.BeginInvoke(new Action(() =>
{
PUB.log.Add($"{port} 자동 연결 해제 (응답 없음)");
dev.Close();
}));
VAR.TIME.Set(conntry, DateTime.Now);
}
}
return true;
}
} }
} }

View File

@@ -570,6 +570,10 @@ namespace Project
{ {
UpdateStatusMessage("AGV 연결실패", Color.Tomato, Color.Black); UpdateStatusMessage("AGV 연결실패", Color.Tomato, Color.Black);
} }
else if(PUB.AGV.IsValid==false)
{
UpdateStatusMessage("AGV 통신상태 불량", Color.Tomato, Color.Black);
}
else if (PUB.AGV.error.Emergency) else if (PUB.AGV.error.Emergency)
{ {
if (PUB.AGV.error.runerror_by_no_magent_line) if (PUB.AGV.error.runerror_by_no_magent_line)
@@ -581,6 +585,14 @@ namespace Project
UpdateStatusMessage("비상 정지", Color.Tomato, Color.Black); UpdateStatusMessage("비상 정지", Color.Tomato, Color.Black);
} }
} }
else if (PUB.BMS != null || PUB.BMS.IsOpen==false)
{
UpdateStatusMessage("BMS가 연결되지 않았습니다", Color.Tomato, Color.Black);
}
else if (PUB.BMS != null || PUB.BMS.IsValid == false)
{
UpdateStatusMessage("BMS 통신상태 불량", Color.Tomato, Color.Black);
}
//else if (PUB.PLC.IsOpen == false) //else if (PUB.PLC.IsOpen == false)
//{ //{
// UpdateStatusMessage(Lang.PLC연결실패, Color.Tomato, Color.Black); // UpdateStatusMessage(Lang.PLC연결실패, Color.Tomato, Color.Black);
@@ -649,7 +661,7 @@ namespace Project
stMsg = Lang.; stMsg = Lang.;
//else if (PUB.PLC.GetValueI(arDev.FakePLC.DIName.PINI_EMG)) //else if (PUB.PLC.GetValueI(arDev.FakePLC.DIName.PINI_EMG))
// stMsg = Lang.비상정지신호가감지되었습니다; // stMsg = Lang.비상정지신호가감지되었습니다;
else if (PUB.AGV.signal.front_gate_out == true) else if (PUB.AGV.signal1.front_gate_out == true)
stMsg = Lang.; stMsg = Lang.;
else if (PUB.AGV.error.runerror_by_no_magent_line) else if (PUB.AGV.error.runerror_by_no_magent_line)
stMsg = "마그네틱 라인을 벗어났습니다"; stMsg = "마그네틱 라인을 벗어났습니다";

View File

@@ -48,7 +48,9 @@ namespace Project
if (data.Length > 4) if (data.Length > 4)
{ {
var currTag = System.Text.Encoding.Default.GetString(data, 1, data.Length - 1); var currTag = System.Text.Encoding.Default.GetString(data, 1, data.Length - 1);
var node = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.RfidId == currTag); if (ushort.TryParse(currTag, out ushort currtagValue))
{
var node = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.RfidId == currtagValue);
if (node == null) if (node == null)
{ {
PUB.log.AddE($"[{logPrefix}-SetCurrent] 노드정보를 찾을 수 없습니다 RFID:{currTag}"); PUB.log.AddE($"[{logPrefix}-SetCurrent] 노드정보를 찾을 수 없습니다 RFID:{currTag}");
@@ -63,6 +65,8 @@ namespace Project
PUB._mapCanvas.SetAGVPosition(PUB.setting.MCID, node, PUB._virtualAGV.CurrentDirection); PUB._mapCanvas.SetAGVPosition(PUB.setting.MCID, node, PUB._virtualAGV.CurrentDirection);
PUB._virtualAGV.SetPosition(node, PUB._virtualAGV.CurrentDirection); PUB._virtualAGV.SetPosition(node, PUB._virtualAGV.CurrentDirection);
} }
else PUB.log.AddE($"[{logPrefix}-SetCurrent] TagString Value Errorr:{data}");
}
else PUB.log.AddE($"[{logPrefix}-SetCurrent] TagString Lenght Errorr:{data.Length}"); else PUB.log.AddE($"[{logPrefix}-SetCurrent] TagString Lenght Errorr:{data.Length}");
break; break;
@@ -107,18 +111,32 @@ namespace Project
} }
break; break;
case ENIGProtocol.AGVCommandHE.GotoAlias:
case ENIGProtocol.AGVCommandHE.Goto: //move to tag case ENIGProtocol.AGVCommandHE.Goto: //move to tag
if (data.Length > 4) var datalength = cmd == ENIGProtocol.AGVCommandHE.GotoAlias ? 2 : 1;
if (data.Length > datalength)
{ {
var currTag = System.Text.Encoding.Default.GetString(data, 1, data.Length - 1); var currTag = System.Text.Encoding.Default.GetString(data, 1, data.Length - 1).Trim();
var targetNode = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.RfidId == currTag); MapNode targetNode = null;
if(cmd == ENIGProtocol.AGVCommandHE.GotoAlias)
{
targetNode = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.AliasName == currTag);
}
else
{
if (ushort.TryParse(currTag, out ushort currtagvalue))
targetNode = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.RfidId == currtagvalue);
else PUB.log.Add($"targstring 이 숫자가 아니라서 대상을 설정할 수 없습니다 값:{currTag}");
}
if (targetNode != null)
{
//자동상태가아니라면 처리하지 않는다. //자동상태가아니라면 처리하지 않는다.
if (VAR.BOOL[eVarBool.FLAG_AUTORUN] == false) if (VAR.BOOL[eVarBool.FLAG_AUTORUN] == false)
{ {
PUB.log.AddE($"[{logPrefix}-Goto] 자동실행상태가 아닙니다"); PUB.log.AddE($"[{logPrefix}-Goto] 자동실행상태가 아닙니다");
PUB.XBE.SendError(ENIGProtocol.AGVErrorCode.ManualMode, $"{currTag}"); PUB.XBE.SendError(ENIGProtocol.AGVErrorCode.ManualMode, $"{currTag}");
return;
} }
//목적지 //목적지
@@ -131,40 +149,46 @@ namespace Project
} }
///출발지 ///출발지
var startNode = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.RfidId == PUB._virtualAGV.CurrentNode.Id); var startNode = PUB._mapCanvas.Nodes.FirstOrDefault(t => t.RfidId == PUB._virtualAGV.CurrentNode.RfidId);
PUB._virtualAGV.StartNode = startNode; PUB._virtualAGV.StartNode = startNode;
if (startNode == null) if (startNode == null)
{ {
PUB.log.AddE($"[{logPrefix}-Goto] 시작노드가 없습니다(현재위치 없음) NodeID:{PUB._virtualAGV.CurrentNode.Id}"); PUB.log.AddE($"[{logPrefix}-Goto] 시작노드가 없습니다(현재위치 없음) NodeID:{PUB._virtualAGV.CurrentNode.Id}");
} }
if (startNode != null) //대상이동으로 처리한다.
if(PUB.sm.RunStep != ERunStep.GOTO)
{ {
//시작위치가 존재한다면 경로를 예측한다. PUB.sm.SetNewRunStep(StateMachine.ERunStep.GOTO);
var rltGoto = CalcPath(startNode, targetNode); PUB.sm.ResetRunStepSeq();
if (rltGoto.result == null)
{
PUB.log.AddE($"[{logPrefix}-Goto] 경로예측실패 {rltGoto.message}");
}
else
{
//경로예측을 화면에 표시해준다.
PUB._virtualAGV.SetPath(rltGoto.result);
var pathWithRfid = rltGoto.result.GetSimplePath().Select(nodeId => PUB._virtualAGV.GetRfidByNodeId(PUB._mapCanvas.Nodes, nodeId)).ToList();
PUB.log.Add($"경로예측결과:{pathWithRfid}");
}
} }
//대상이동으로 처리한다.
PUB.sm.SetNewRunStep(StateMachine.ERunStep.GOTO);
//Move to //Move to
PUB.log.Add($"[{logPrefix}-Goto] {startNode.RfidId} -> {targetNode.RfidId}"); PUB.log.Add($"[{logPrefix}-{cmd}] {startNode.RfidId} -> {targetNode.RfidId}");
} }
else PUB.log.AddE($"[{logPrefix}-Goto] TagString Lenght Errorr:{data.Length}"); else PUB.log.AddE($"[{logPrefix}-{cmd}] 대상노드가 없습니다 {data}");
}
else PUB.log.AddE($"[{logPrefix}-{cmd}] Length Error:{data.Length}");
break; break;
case ENIGProtocol.AGVCommandHE.LTurn180:
PUB.log.Add($"[{logPrefix}-LTurn180]");
PUB.AGV.AGVMoveLeft180Turn();
break;
case ENIGProtocol.AGVCommandHE.RTurn180:
PUB.log.Add($"[{logPrefix}-RTurn180]");
PUB.AGV.AGVMoveRight180Turn();
break;
case ENIGProtocol.AGVCommandHE.LTurn:
PUB.log.Add($"[{logPrefix}-LTurn]");
PUB.AGV.AGVMoveManual(arDev.Narumi.ManulOpt.LT, arDev.Narumi.Speed.Low, arDev.Narumi.Sensor.AllOn);
break;
case ENIGProtocol.AGVCommandHE.RTurn:
PUB.log.Add($"[{logPrefix}-RTurn]");
PUB.AGV.AGVMoveManual(arDev.Narumi.ManulOpt.RT, arDev.Narumi.Speed.Low, arDev.Narumi.Sensor.AllOn);
break;
case ENIGProtocol.AGVCommandHE.Stop: //stop case ENIGProtocol.AGVCommandHE.Stop: //stop
PUB.log.Add($"[{logPrefix}-Stop]"); PUB.log.Add($"[{logPrefix}-Stop]");
PUB.AGV.AGVMoveStop("xbee"); PUB.AGV.AGVMoveStop("xbee");
@@ -198,6 +222,7 @@ namespace Project
var MotDirection = data[1]; //0=back, 1=forward var MotDirection = data[1]; //0=back, 1=forward
var MagDirection = data[2]; //0=straight, 1=left, 2=right var MagDirection = data[2]; //0=straight, 1=left, 2=right
var AutSpeed = data[3]; //0=slow, 1=normal, 2=fast var AutSpeed = data[3]; //0=slow, 1=normal, 2=fast
var Lidar = data[4]; //0=off, 1=on
var bunkidata = new arDev.Narumi.BunkiData(); var bunkidata = new arDev.Narumi.BunkiData();
@@ -214,9 +239,12 @@ namespace Project
else if (MagDirection == 1) bunkidata.Bunki = arDev.Narumi.eBunki.Left; else if (MagDirection == 1) bunkidata.Bunki = arDev.Narumi.eBunki.Left;
else bunkidata.Bunki = arDev.Narumi.eBunki.Strate; else bunkidata.Bunki = arDev.Narumi.eBunki.Strate;
if (Lidar == 0) bunkidata.PBSSensor = 0;
else bunkidata.PBSSensor = 2;
PUB.log.Add($"[{logPrefix}-AutoMove] DIR:{bunkidata.Direction}-{bunkidata.Bunki},SPD:{bunkidata.Speed}"); PUB.log.Add($"[{logPrefix}-AutoMove] DIR:{bunkidata.Direction}-{bunkidata.Bunki},SPD:{bunkidata.Speed}");
PUB.AGV.AGVMoveSet(bunkidata); PUB.AGV.AGVMoveSet(bunkidata);
PUB.AGV.AGVMoveRun(); PUB.AGV.AGVMoveRun((MotDirection == 0 ? arDev.Narumi.eRunOpt.Backward : arDev.Narumi.eRunOpt.Forward));
break; break;
case ENIGProtocol.AGVCommandHE.MarkStop: //Set MarkStop case ENIGProtocol.AGVCommandHE.MarkStop: //Set MarkStop
@@ -247,6 +275,10 @@ namespace Project
} }
break; break;
default:
PUB.logagv.AddE($"Unknown Command : {cmd} Sender:{e.ReceivedPacket.ID}, Target:{data[0]}");
PUB.XBE.SendError(ENIGProtocol.AGVErrorCode.UnknownCommand, $"{cmd}");
break;
} }
} }
} }
@@ -284,12 +316,25 @@ namespace Project
_simulatorCanvas.FitToNodes(); _simulatorCanvas.FitToNodes();
string Message = string.Empty; string Message = string.Empty;
if (advancedResult.Success) if (advancedResult != null && advancedResult.Success)
{ {
// 도킹 검증이 없는 경우 추가 검증 수행 // 도킹 검증이 없는 경우 추가 검증 수행
if (advancedResult.DockingValidation == null || !advancedResult.DockingValidation.IsValidationRequired) if (advancedResult.DockingValidation == null || !advancedResult.DockingValidation.IsValidationRequired)
advancedResult.DockingValidation = DockingValidator.ValidateDockingDirection(advancedResult, _mapNodes); advancedResult.DockingValidation = DockingValidator.ValidateDockingDirection(advancedResult, _mapNodes);
//마지막대상이 버퍼라면 시퀀스처리를 해야한다
if (targetNode.StationType == StationType.Buffer&& advancedResult.DetailedPath.Any())
{
var lastDetailPath = advancedResult.DetailedPath.Last();
if (lastDetailPath.NodeId == targetNode.Id) //마지막노드 재확인
{
//버퍼에 도킹할때에는 마지막 노드에서 멈추고 시퀀스를 적용해야한다
advancedResult.DetailedPath = advancedResult.DetailedPath.Take(advancedResult.DetailedPath.Count - 1).ToList();
Console.WriteLine("최종위치가 버퍼이므로 마지막 RFID에서 멈추도록 합니다");
}
}
_simulatorCanvas.CurrentPath = advancedResult; _simulatorCanvas.CurrentPath = advancedResult;
//_pathLengthLabel.Text = $"경로 길이: {advancedResult.TotalDistance:F1}"; //_pathLengthLabel.Text = $"경로 길이: {advancedResult.TotalDistance:F1}";
//_statusLabel.Text = $"경로 계산 완료 ({advancedResult.CalculationTimeMs}ms)"; //_statusLabel.Text = $"경로 계산 완료 ({advancedResult.CalculationTimeMs}ms)";
@@ -304,12 +349,12 @@ namespace Project
//UpdateAdvancedPathDebugInfo(advancedResult); //UpdateAdvancedPathDebugInfo(advancedResult);
} }
else else if(advancedResult != null)
{ {
// 경로 실패시 디버깅 정보 초기화 // 경로 실패시 디버깅 정보 초기화
//_pathDebugLabel.Text = $"경로: 실패 - {advancedResult.ErrorMessage}"; //_pathDebugLabel.Text = $"경로: 실패 - {advancedResult.ErrorMessage}";
advancedResult = null;
Message = $"경로를 찾을 수 없습니다:\n{advancedResult.ErrorMessage}"; Message = $"경로를 찾을 수 없습니다:\n{advancedResult.ErrorMessage}";
advancedResult = null;
} }
return (advancedResult, Message); return (advancedResult, Message);

View File

@@ -30,17 +30,18 @@
{ {
this.components = new System.ComponentModel.Container(); this.components = new System.ComponentModel.Container();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.richTextBox1 = new System.Windows.Forms.RichTextBox(); this.rtSystem0 = new System.Windows.Forms.RichTextBox();
this.richTextBox2 = new System.Windows.Forms.RichTextBox(); this.rtSystem1 = new System.Windows.Forms.RichTextBox();
this.richTextBox3 = new System.Windows.Forms.RichTextBox(); this.rtSignal1 = new System.Windows.Forms.RichTextBox();
this.richTextBox4 = new System.Windows.Forms.RichTextBox(); this.rtError = new System.Windows.Forms.RichTextBox();
this.label1 = new System.Windows.Forms.Label(); this.label1 = new System.Windows.Forms.Label();
this.timer1 = new System.Windows.Forms.Timer(this.components); this.timer1 = new System.Windows.Forms.Timer(this.components);
this.panel1 = new System.Windows.Forms.Panel(); this.panel1 = new System.Windows.Forms.Panel();
this.lbIP = new System.Windows.Forms.Label();
this.button7 = new System.Windows.Forms.Button(); this.button7 = new System.Windows.Forms.Button();
this.button6 = new System.Windows.Forms.Button(); this.button6 = new System.Windows.Forms.Button();
this.button5 = new System.Windows.Forms.Button(); this.button5 = new System.Windows.Forms.Button();
this.button17 = new System.Windows.Forms.Button();
this.lbIP = new System.Windows.Forms.Label();
this.button3 = new System.Windows.Forms.Button(); this.button3 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button(); this.button2 = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button(); this.button1 = new System.Windows.Forms.Button();
@@ -48,13 +49,16 @@
this.button4 = new System.Windows.Forms.Button(); this.button4 = new System.Windows.Forms.Button();
this.button9 = new System.Windows.Forms.Button(); this.button9 = new System.Windows.Forms.Button();
this.panel2 = new System.Windows.Forms.Panel(); this.panel2 = new System.Windows.Forms.Panel();
this.button16 = new System.Windows.Forms.Button(); this.lbPortName = new System.Windows.Forms.Label();
this.button10 = new System.Windows.Forms.Button(); this.button15 = new System.Windows.Forms.Button();
this.button14 = new System.Windows.Forms.Button();
this.button11 = new System.Windows.Forms.Button(); this.button11 = new System.Windows.Forms.Button();
this.button12 = new System.Windows.Forms.Button(); this.button12 = new System.Windows.Forms.Button();
this.button13 = new System.Windows.Forms.Button(); this.button13 = new System.Windows.Forms.Button();
this.button14 = new System.Windows.Forms.Button(); this.button10 = new System.Windows.Forms.Button();
this.button15 = new System.Windows.Forms.Button(); this.button16 = new System.Windows.Forms.Button();
this.rtData = new System.Windows.Forms.RichTextBox();
this.rtSignal2 = new System.Windows.Forms.RichTextBox();
this.tableLayoutPanel1.SuspendLayout(); this.tableLayoutPanel1.SuspendLayout();
this.panel1.SuspendLayout(); this.panel1.SuspendLayout();
this.panel2.SuspendLayout(); this.panel2.SuspendLayout();
@@ -67,11 +71,13 @@
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F));
this.tableLayoutPanel1.Controls.Add(this.richTextBox1, 0, 0); this.tableLayoutPanel1.Controls.Add(this.rtSignal2, 2, 1);
this.tableLayoutPanel1.Controls.Add(this.richTextBox2, 1, 0); this.tableLayoutPanel1.Controls.Add(this.rtSystem0, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.richTextBox3, 2, 0); this.tableLayoutPanel1.Controls.Add(this.rtSystem1, 1, 0);
this.tableLayoutPanel1.Controls.Add(this.richTextBox4, 3, 0); this.tableLayoutPanel1.Controls.Add(this.rtSignal1, 2, 0);
this.tableLayoutPanel1.Controls.Add(this.rtError, 3, 0);
this.tableLayoutPanel1.Controls.Add(this.label1, 0, 2); this.tableLayoutPanel1.Controls.Add(this.label1, 0, 2);
this.tableLayoutPanel1.Controls.Add(this.rtData, 3, 1);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(3, 3); this.tableLayoutPanel1.Location = new System.Drawing.Point(3, 3);
this.tableLayoutPanel1.Name = "tableLayoutPanel1"; this.tableLayoutPanel1.Name = "tableLayoutPanel1";
@@ -82,45 +88,47 @@
this.tableLayoutPanel1.Size = new System.Drawing.Size(1050, 461); this.tableLayoutPanel1.Size = new System.Drawing.Size(1050, 461);
this.tableLayoutPanel1.TabIndex = 6; this.tableLayoutPanel1.TabIndex = 6;
// //
// richTextBox1 // rtSystem0
// //
this.richTextBox1.Dock = System.Windows.Forms.DockStyle.Fill; this.rtSystem0.Dock = System.Windows.Forms.DockStyle.Fill;
this.richTextBox1.Location = new System.Drawing.Point(3, 3); this.rtSystem0.Font = new System.Drawing.Font("Calibri", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(2)));
this.richTextBox1.Name = "richTextBox1"; this.rtSystem0.Location = new System.Drawing.Point(3, 3);
this.tableLayoutPanel1.SetRowSpan(this.richTextBox1, 2); this.rtSystem0.Name = "rtSystem0";
this.richTextBox1.Size = new System.Drawing.Size(256, 404); this.tableLayoutPanel1.SetRowSpan(this.rtSystem0, 2);
this.richTextBox1.TabIndex = 1; this.rtSystem0.Size = new System.Drawing.Size(256, 404);
this.richTextBox1.Text = ""; this.rtSystem0.TabIndex = 1;
this.rtSystem0.Text = "test2\ntest3\nteat\nasdfjalsdf\nasdjfklasdfj\nkalsdjfalksdjfa\nsdjfklasdjfklasjdf\n";
// //
// richTextBox2 // rtSystem1
// //
this.richTextBox2.Dock = System.Windows.Forms.DockStyle.Fill; this.rtSystem1.Dock = System.Windows.Forms.DockStyle.Fill;
this.richTextBox2.Location = new System.Drawing.Point(265, 3); this.rtSystem1.Font = new System.Drawing.Font("Calibri", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(2)));
this.richTextBox2.Name = "richTextBox2"; this.rtSystem1.Location = new System.Drawing.Point(265, 3);
this.tableLayoutPanel1.SetRowSpan(this.richTextBox2, 2); this.rtSystem1.Name = "rtSystem1";
this.richTextBox2.Size = new System.Drawing.Size(256, 404); this.tableLayoutPanel1.SetRowSpan(this.rtSystem1, 2);
this.richTextBox2.TabIndex = 1; this.rtSystem1.Size = new System.Drawing.Size(256, 404);
this.richTextBox2.Text = ""; this.rtSystem1.TabIndex = 1;
this.rtSystem1.Text = "test2\ntest3\nteat\nasdfjalsdf\nasdjfklasdfj\nkalsdjfalksdjfa\nsdjfklasdjfklasjdf\n";
// //
// richTextBox3 // rtSignal1
// //
this.richTextBox3.Dock = System.Windows.Forms.DockStyle.Fill; this.rtSignal1.Dock = System.Windows.Forms.DockStyle.Fill;
this.richTextBox3.Location = new System.Drawing.Point(527, 3); this.rtSignal1.Font = new System.Drawing.Font("Calibri", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(2)));
this.richTextBox3.Name = "richTextBox3"; this.rtSignal1.Location = new System.Drawing.Point(527, 3);
this.tableLayoutPanel1.SetRowSpan(this.richTextBox3, 2); this.rtSignal1.Name = "rtSignal1";
this.richTextBox3.Size = new System.Drawing.Size(256, 404); this.rtSignal1.Size = new System.Drawing.Size(256, 199);
this.richTextBox3.TabIndex = 1; this.rtSignal1.TabIndex = 1;
this.richTextBox3.Text = ""; this.rtSignal1.Text = "test2\ntest3\nteat\nasdfjalsdf\nasdjfklasdfj\nkalsdjfalksdjfa\nsdjfklasdjfklasjdf\n";
// //
// richTextBox4 // rtError
// //
this.richTextBox4.Dock = System.Windows.Forms.DockStyle.Fill; this.rtError.Dock = System.Windows.Forms.DockStyle.Fill;
this.richTextBox4.Location = new System.Drawing.Point(789, 3); this.rtError.Font = new System.Drawing.Font("Calibri", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(2)));
this.richTextBox4.Name = "richTextBox4"; this.rtError.Location = new System.Drawing.Point(789, 3);
this.tableLayoutPanel1.SetRowSpan(this.richTextBox4, 2); this.rtError.Name = "rtError";
this.richTextBox4.Size = new System.Drawing.Size(258, 404); this.rtError.Size = new System.Drawing.Size(258, 199);
this.richTextBox4.TabIndex = 1; this.rtError.TabIndex = 1;
this.richTextBox4.Text = ""; this.rtError.Text = "test2\ntest3\nteat\nasdfjalsdf\nasdjfklasdfj\nkalsdjfalksdjfa\nsdjfklasdjfklasjdf\n";
// //
// label1 // label1
// //
@@ -141,10 +149,11 @@
// //
// panel1 // panel1
// //
this.panel1.Controls.Add(this.lbIP);
this.panel1.Controls.Add(this.button7); this.panel1.Controls.Add(this.button7);
this.panel1.Controls.Add(this.button6); this.panel1.Controls.Add(this.button6);
this.panel1.Controls.Add(this.button5); this.panel1.Controls.Add(this.button5);
this.panel1.Controls.Add(this.button17);
this.panel1.Controls.Add(this.lbIP);
this.panel1.Controls.Add(this.button3); this.panel1.Controls.Add(this.button3);
this.panel1.Controls.Add(this.button2); this.panel1.Controls.Add(this.button2);
this.panel1.Controls.Add(this.button1); this.panel1.Controls.Add(this.button1);
@@ -156,22 +165,10 @@
this.panel1.Size = new System.Drawing.Size(1050, 58); this.panel1.Size = new System.Drawing.Size(1050, 58);
this.panel1.TabIndex = 7; this.panel1.TabIndex = 7;
// //
// lbIP
//
this.lbIP.Dock = System.Windows.Forms.DockStyle.Fill;
this.lbIP.Font = new System.Drawing.Font("Tahoma", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.lbIP.ForeColor = System.Drawing.Color.White;
this.lbIP.Location = new System.Drawing.Point(252, 0);
this.lbIP.Name = "lbIP";
this.lbIP.Size = new System.Drawing.Size(398, 58);
this.lbIP.TabIndex = 8;
this.lbIP.Text = "000.000.000.000";
this.lbIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// button7 // button7
// //
this.button7.Dock = System.Windows.Forms.DockStyle.Right; this.button7.Dock = System.Windows.Forms.DockStyle.Right;
this.button7.Location = new System.Drawing.Point(650, 0); this.button7.Location = new System.Drawing.Point(570, 0);
this.button7.Name = "button7"; this.button7.Name = "button7";
this.button7.Size = new System.Drawing.Size(80, 58); this.button7.Size = new System.Drawing.Size(80, 58);
this.button7.TabIndex = 6; this.button7.TabIndex = 6;
@@ -182,7 +179,7 @@
// button6 // button6
// //
this.button6.Dock = System.Windows.Forms.DockStyle.Right; this.button6.Dock = System.Windows.Forms.DockStyle.Right;
this.button6.Location = new System.Drawing.Point(730, 0); this.button6.Location = new System.Drawing.Point(650, 0);
this.button6.Name = "button6"; this.button6.Name = "button6";
this.button6.Size = new System.Drawing.Size(80, 58); this.button6.Size = new System.Drawing.Size(80, 58);
this.button6.TabIndex = 5; this.button6.TabIndex = 5;
@@ -193,7 +190,7 @@
// button5 // button5
// //
this.button5.Dock = System.Windows.Forms.DockStyle.Right; this.button5.Dock = System.Windows.Forms.DockStyle.Right;
this.button5.Location = new System.Drawing.Point(810, 0); this.button5.Location = new System.Drawing.Point(730, 0);
this.button5.Name = "button5"; this.button5.Name = "button5";
this.button5.Size = new System.Drawing.Size(80, 58); this.button5.Size = new System.Drawing.Size(80, 58);
this.button5.TabIndex = 4; this.button5.TabIndex = 4;
@@ -201,6 +198,29 @@
this.button5.UseVisualStyleBackColor = true; this.button5.UseVisualStyleBackColor = true;
this.button5.Click += new System.EventHandler(this.button5_Click); this.button5.Click += new System.EventHandler(this.button5_Click);
// //
// button17
//
this.button17.Dock = System.Windows.Forms.DockStyle.Right;
this.button17.Location = new System.Drawing.Point(810, 0);
this.button17.Name = "button17";
this.button17.Size = new System.Drawing.Size(80, 58);
this.button17.TabIndex = 9;
this.button17.Text = "Run(Bwd)";
this.button17.UseVisualStyleBackColor = true;
this.button17.Click += new System.EventHandler(this.button17_Click);
//
// lbIP
//
this.lbIP.Dock = System.Windows.Forms.DockStyle.Fill;
this.lbIP.Font = new System.Drawing.Font("Tahoma", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.lbIP.ForeColor = System.Drawing.Color.White;
this.lbIP.Location = new System.Drawing.Point(252, 0);
this.lbIP.Name = "lbIP";
this.lbIP.Size = new System.Drawing.Size(638, 58);
this.lbIP.TabIndex = 8;
this.lbIP.Text = "000.000.000.000";
this.lbIP.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// button3 // button3
// //
this.button3.Dock = System.Windows.Forms.DockStyle.Left; this.button3.Dock = System.Windows.Forms.DockStyle.Left;
@@ -241,7 +261,7 @@
this.button8.Name = "button8"; this.button8.Name = "button8";
this.button8.Size = new System.Drawing.Size(80, 58); this.button8.Size = new System.Drawing.Size(80, 58);
this.button8.TabIndex = 7; this.button8.TabIndex = 7;
this.button8.Text = "Run"; this.button8.Text = "Run(Fwd)";
this.button8.UseVisualStyleBackColor = true; this.button8.UseVisualStyleBackColor = true;
this.button8.Click += new System.EventHandler(this.button8_Click); this.button8.Click += new System.EventHandler(this.button8_Click);
// //
@@ -269,6 +289,7 @@
// //
// panel2 // panel2
// //
this.panel2.Controls.Add(this.lbPortName);
this.panel2.Controls.Add(this.button15); this.panel2.Controls.Add(this.button15);
this.panel2.Controls.Add(this.button14); this.panel2.Controls.Add(this.button14);
this.panel2.Controls.Add(this.button11); this.panel2.Controls.Add(this.button11);
@@ -283,27 +304,39 @@
this.panel2.Size = new System.Drawing.Size(1050, 58); this.panel2.Size = new System.Drawing.Size(1050, 58);
this.panel2.TabIndex = 8; this.panel2.TabIndex = 8;
// //
// button16 // lbPortName
// //
this.button16.Dock = System.Windows.Forms.DockStyle.Left; this.lbPortName.Dock = System.Windows.Forms.DockStyle.Fill;
this.button16.Location = new System.Drawing.Point(0, 0); this.lbPortName.Font = new System.Drawing.Font("Tahoma", 15F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.button16.Name = "button16"; this.lbPortName.ForeColor = System.Drawing.Color.White;
this.button16.Size = new System.Drawing.Size(162, 58); this.lbPortName.Location = new System.Drawing.Point(607, 0);
this.button16.TabIndex = 0; this.lbPortName.Name = "lbPortName";
this.button16.Text = "백턴유지시간"; this.lbPortName.Size = new System.Drawing.Size(203, 58);
this.button16.UseVisualStyleBackColor = true; this.lbPortName.TabIndex = 15;
this.button16.Click += new System.EventHandler(this.button16_Click); this.lbPortName.Text = "--";
this.lbPortName.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
// //
// button10 // button15
// //
this.button10.Dock = System.Windows.Forms.DockStyle.Left; this.button15.Dock = System.Windows.Forms.DockStyle.Left;
this.button10.Location = new System.Drawing.Point(162, 0); this.button15.Location = new System.Drawing.Point(523, 0);
this.button10.Name = "button10"; this.button15.Name = "button15";
this.button10.Size = new System.Drawing.Size(162, 58); this.button15.Size = new System.Drawing.Size(84, 58);
this.button10.TabIndex = 1; this.button15.TabIndex = 14;
this.button10.Text = "GateOut Off Time"; this.button15.Text = "Mag Off";
this.button10.UseVisualStyleBackColor = true; this.button15.UseVisualStyleBackColor = true;
this.button10.Click += new System.EventHandler(this.button10_Click); this.button15.Click += new System.EventHandler(this.button15_Click);
//
// button14
//
this.button14.Dock = System.Windows.Forms.DockStyle.Left;
this.button14.Location = new System.Drawing.Point(439, 0);
this.button14.Name = "button14";
this.button14.Size = new System.Drawing.Size(84, 58);
this.button14.TabIndex = 13;
this.button14.Text = "Mag On";
this.button14.UseVisualStyleBackColor = true;
this.button14.Click += new System.EventHandler(this.button14_Click);
// //
// button11 // button11
// //
@@ -338,27 +371,47 @@
this.button13.UseVisualStyleBackColor = true; this.button13.UseVisualStyleBackColor = true;
this.button13.Click += new System.EventHandler(this.button13_Click); this.button13.Click += new System.EventHandler(this.button13_Click);
// //
// button14 // button10
// //
this.button14.Dock = System.Windows.Forms.DockStyle.Left; this.button10.Dock = System.Windows.Forms.DockStyle.Left;
this.button14.Location = new System.Drawing.Point(439, 0); this.button10.Location = new System.Drawing.Point(162, 0);
this.button14.Name = "button14"; this.button10.Name = "button10";
this.button14.Size = new System.Drawing.Size(84, 58); this.button10.Size = new System.Drawing.Size(162, 58);
this.button14.TabIndex = 13; this.button10.TabIndex = 1;
this.button14.Text = "Mag On"; this.button10.Text = "GateOut Off Time";
this.button14.UseVisualStyleBackColor = true; this.button10.UseVisualStyleBackColor = true;
this.button14.Click += new System.EventHandler(this.button14_Click); this.button10.Click += new System.EventHandler(this.button10_Click);
// //
// button15 // button16
// //
this.button15.Dock = System.Windows.Forms.DockStyle.Left; this.button16.Dock = System.Windows.Forms.DockStyle.Left;
this.button15.Location = new System.Drawing.Point(523, 0); this.button16.Location = new System.Drawing.Point(0, 0);
this.button15.Name = "button15"; this.button16.Name = "button16";
this.button15.Size = new System.Drawing.Size(84, 58); this.button16.Size = new System.Drawing.Size(162, 58);
this.button15.TabIndex = 14; this.button16.TabIndex = 0;
this.button15.Text = "Mag Off"; this.button16.Text = "백턴유지시간";
this.button15.UseVisualStyleBackColor = true; this.button16.UseVisualStyleBackColor = true;
this.button15.Click += new System.EventHandler(this.button15_Click); this.button16.Click += new System.EventHandler(this.button16_Click);
//
// rtData
//
this.rtData.Dock = System.Windows.Forms.DockStyle.Fill;
this.rtData.Font = new System.Drawing.Font("Calibri", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(2)));
this.rtData.Location = new System.Drawing.Point(789, 208);
this.rtData.Name = "rtData";
this.rtData.Size = new System.Drawing.Size(258, 199);
this.rtData.TabIndex = 3;
this.rtData.Text = "test2\ntest3\nteat\nasdfjalsdf\nasdjfklasdfj\nkalsdjfalksdjfa\nsdjfklasdjfklasjdf\n";
//
// rtSignal2
//
this.rtSignal2.Dock = System.Windows.Forms.DockStyle.Fill;
this.rtSignal2.Font = new System.Drawing.Font("Calibri", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(2)));
this.rtSignal2.Location = new System.Drawing.Point(527, 208);
this.rtSignal2.Name = "rtSignal2";
this.rtSignal2.Size = new System.Drawing.Size(256, 199);
this.rtSignal2.TabIndex = 4;
this.rtSignal2.Text = "test2\ntest3\nteat\nasdfjalsdf\nasdjfklasdfj\nkalsdjfalksdjfa\nsdjfklasdjfklasjdf\n";
// //
// fAgv // fAgv
// //
@@ -385,10 +438,10 @@
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.Timer timer1; private System.Windows.Forms.Timer timer1;
private System.Windows.Forms.RichTextBox richTextBox1; private System.Windows.Forms.RichTextBox rtSystem0;
private System.Windows.Forms.RichTextBox richTextBox2; private System.Windows.Forms.RichTextBox rtSystem1;
private System.Windows.Forms.RichTextBox richTextBox3; private System.Windows.Forms.RichTextBox rtSignal1;
private System.Windows.Forms.RichTextBox richTextBox4; private System.Windows.Forms.RichTextBox rtError;
private System.Windows.Forms.Panel panel1; private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.Button button1; private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button button2; private System.Windows.Forms.Button button2;
@@ -409,5 +462,9 @@
private System.Windows.Forms.Button button11; private System.Windows.Forms.Button button11;
private System.Windows.Forms.Button button12; private System.Windows.Forms.Button button12;
private System.Windows.Forms.Button button13; private System.Windows.Forms.Button button13;
private System.Windows.Forms.Label lbPortName;
private System.Windows.Forms.Button button17;
private System.Windows.Forms.RichTextBox rtData;
private System.Windows.Forms.RichTextBox rtSignal2;
} }
} }

View File

@@ -38,11 +38,13 @@ namespace Project.ViewForm
lbIP.Text = PUB.IP; lbIP.Text = PUB.IP;
label1.Text = PUB.AGV.LastSTS; label1.Text = PUB.AGV.LastSTS;
richTextBox1.Rtf = PUB.AGV.system0.ToRtfString(); rtSystem0.Rtf = PUB.AGV.system0.ToRtfString();
richTextBox2.Rtf = PUB.AGV.system1.ToRtfString(); rtSystem1.Rtf = PUB.AGV.system1.ToRtfString();
richTextBox3.Rtf = CombineRtfStrings(PUB.AGV.signal.ToRtfString(), PUB.AGV.data.ToRtfString()); rtSignal1.Rtf = PUB.AGV.signal1.ToRtfString();
richTextBox4.Rtf = PUB.AGV.error.ToRtfString(); rtSignal2.Rtf = PUB.AGV.signal2.ToRtfString();
rtData.Rtf = PUB.AGV.data.ToRtfString();
rtError.Rtf = PUB.AGV.error.ToRtfString();
lbPortName.Text = $"AGV:{PUB.setting.Port_AGV}\nBMS:{PUB.setting.Port_BAT}";
timer1.Start(); timer1.Start();
} }
@@ -133,7 +135,7 @@ namespace Project.ViewForm
private void button8_Click(object sender, EventArgs e) private void button8_Click(object sender, EventArgs e)
{ {
PUB.AGV.AGVMoveRun(); PUB.AGV.AGVMoveRun( arDev.Narumi.eRunOpt.Forward);
} }
private void button9_Click(object sender, EventArgs e) private void button9_Click(object sender, EventArgs e)
@@ -190,5 +192,10 @@ namespace Project.ViewForm
{ {
PUB.AGV.LiftControl(arDev.Narumi.LiftCommand.STP); PUB.AGV.LiftControl(arDev.Narumi.LiftCommand.STP);
} }
private void button17_Click(object sender, EventArgs e)
{
PUB.AGV.AGVMoveRun(arDev.Narumi.eRunOpt.Backward);
}
} }
} }

View File

@@ -30,29 +30,11 @@ namespace Project.ViewForm
InitializeMapCanvas(); InitializeMapCanvas();
//PUB.mapctl = new AGVControl.MapControl();
//PUB.mapctl.Dock = DockStyle.Fill;
//PUB.mapctl.Visible = true;
//PUB.mapctl.Font = this.panel1.Font;
//PUB.mapctl.BackColor = Color.FromArgb(32, 32, 32);
//this.panel1.Controls.Add(PUB.mapctl);
} }
private void InitializeMapCanvas() private void InitializeMapCanvas()
{ {
PUB._mapCanvas.NodeSelect += OnNodeSelected;;
// RfidMappings 제거 - MapNode에 통합됨
// 이벤트 연결
//PUB._mapCanvas.NodeAdded += OnNodeAdded;
// 이벤트 연결
//PUB._mapCanvas.NodeAdded += OnNodeAdded;
PUB._mapCanvas.NodeSelect += OnNodeSelected;
//PUB._mapCanvas.NodeMoved += OnNodeMoved;
//PUB._mapCanvas.NodeDeleted += OnNodeDeleted;
//PUB._mapCanvas.ConnectionDeleted += OnConnectionDeleted;
//PUB._mapCanvas.ImageNodeDoubleClicked += OnImageNodeDoubleClicked;
//PUB._mapCanvas.MapChanged += OnMapChanged;
// 스플리터 패널에 맵 캔버스 추가 // 스플리터 패널에 맵 캔버스 추가
panel1.Controls.Add(PUB._mapCanvas); panel1.Controls.Add(PUB._mapCanvas);
@@ -61,9 +43,18 @@ namespace Project.ViewForm
private void OnNodeSelected(object sender, NodeBase node, MouseEventArgs e) private void OnNodeSelected(object sender, NodeBase node, MouseEventArgs e)
{ {
if (e.Button != MouseButtons.Right) return;
if (node == null) return; if (node == null) return;
if ((node is MapNode mapnode) == false) return; var mapnode = node as MapNode;
if (mapnode == null) return;
// [Run Mode] Left Click: AGV Operation
if (PUB._mapCanvas.Mode == AGVNavigationCore.Controls.UnifiedAGVCanvas.CanvasMode.Run && e.Button == MouseButtons.Left)
{
HandleRunModeClick(mapnode);
return;
}
if (e.Button != MouseButtons.Right) return;
// 도킹 가능한 노드인지 또는 작업 노드인지 확인 // 도킹 가능한 노드인지 또는 작업 노드인지 확인
if (mapnode.isDockingNode == false) return; if (mapnode.isDockingNode == false) return;
@@ -146,112 +137,15 @@ namespace Project.ViewForm
private void fAuto_Load(object sender, EventArgs e) private void fAuto_Load(object sender, EventArgs e)
{ {
ctlAuto1.dev_agv = PUB.AGV; ctlAuto1.dev_agv = PUB.AGV;
// ctlAuto1.dev_plc = PUB.PLC;
ctlAuto1.dev_bms = PUB.BMS; ctlAuto1.dev_bms = PUB.BMS;
ctlAuto1.dev_xbe = PUB.XBE; ctlAuto1.dev_xbe = PUB.XBE;
PUB.AGV.DataReceive += AGV_DataReceive; PUB.AGV.DataReceive += AGV_DataReceive;
//auto load
var mapPath = new System.IO.DirectoryInfo("route");
if (mapPath.Exists == false) mapPath.Create();
//맵파일로딩
if (PUB.setting.LastMapFile.isEmpty()) PUB.setting.LastMapFile = System.IO.Path.Combine(mapPath.FullName, "default.agvmap");
System.IO.FileInfo filePath = new System.IO.FileInfo(PUB.setting.LastMapFile);
if (filePath.Exists == false) filePath = new System.IO.FileInfo(System.IO.Path.Combine(mapPath.FullName, "default.agvmap"));
if (filePath.Exists == false) //그래도없다면 맵폴더에서 파일을 찾아본다.
{
var files = mapPath.GetFiles("*.agvmap");
if (files.Any()) filePath = files[0];
}
if (filePath.Exists)
{
var result = MapLoader.LoadMapFromFile(filePath.FullName);
if (result.Success)
{
if (PUB._mapCanvas.Nodes == null) PUB._mapCanvas.Nodes = new List<MapNode>();
else PUB._mapCanvas.Nodes.Clear();
PUB._mapCanvas.Nodes.AddRange(result.Nodes);
// 맵 캔버스에 데이터 설정
PUB._mapCanvas.Nodes = PUB._mapCanvas.Nodes;
PUB._mapCanvas.MapFileName = filePath.FullName;
// 🔥 맵 설정 적용 (배경색, 그리드 표시)
if (result.Settings != null)
{
PUB._mapCanvas.BackColor = System.Drawing.Color.FromArgb(result.Settings.BackgroundColorArgb);
PUB._mapCanvas.ShowGrid = result.Settings.ShowGrid;
}
// 🔥 가상 AGV 초기화 (첫 노드 위치에 생성)
if (PUB._virtualAGV == null && PUB._mapCanvas.Nodes.Count > 0)
{
var startNode = PUB._mapCanvas.Nodes.FirstOrDefault(n => n.IsNavigationNode());
if (startNode != null)
{
PUB._virtualAGV = new VirtualAGV(PUB.setting.MCID, startNode.Position, AgvDirection.Forward);
PUB._virtualAGV.LowBatteryThreshold = PUB.setting.BatteryLimit_Low;
PUB._virtualAGV.SetPosition(startNode, AgvDirection.Forward);
// 캔버스에 AGV 리스트 설정
var agvList = new System.Collections.Generic.List<AGVNavigationCore.Controls.IAGV> { PUB._virtualAGV };
PUB._mapCanvas.AGVList = agvList;
PUB.log.Add($"가상 AGV 생성: {startNode.Id} 위치");
}
}
else if (PUB._virtualAGV != null)
{
PUB._virtualAGV.LowBatteryThreshold = PUB.setting.BatteryLimit_Low;
// 기존 AGV가 있으면 캔버스에 다시 연결
var agvList = new System.Collections.Generic.List<AGVNavigationCore.Controls.IAGV> { PUB._virtualAGV };
PUB._mapCanvas.AGVList = agvList;
}
// 맵 로드 후 자동으로 맵에 맞춤
PUB._mapCanvas.FitToNodes();
PUB.log.Add($"맵 파일 로드 완료: {filePath.Name}, 노드 수: {result.Nodes.Count}");
}
else
{
PUB.log.Add($"맵 파일 로딩 실패: {result.ErrorMessage}");
MessageBox.Show($"맵 파일 로딩 실패: {result.ErrorMessage}", "오류",
MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
else
{
PUB.log.Add($"맵 파일을 찾을 수 없습니다: {filePath.FullName}");
}
//var fn = string.Empty;
//if (files.Any() == false)
//{
// fn = AR.UTIL.MakePath("sample.route");
//}
//else if (files.Count() == 1)
//{
// fn = files.First().FullName;
//}
//if (fn.isEmpty() == false)
//{
// var fi = new System.IO.FileInfo(AR.UTIL.CurrentPath + "\\sample.route");
// if (fi.Exists)
// {
// PUB.log.Add($"autoload : {fi.FullName}");
// var rlt = PUB.mapctl.LoadFromFile(fi.FullName, out string errmsg);
// if (rlt == false) AR.UTIL.MsgE(errmsg);
// }
//}
this.timer1.Start(); this.timer1.Start();
// Set Run Mode
PUB._mapCanvas.Mode = AGVNavigationCore.Controls.UnifiedAGVCanvas.CanvasMode.Run;
} }
private void AGV_DataReceive(object sender, arDev.Narumi.DataEventArgs e) private void AGV_DataReceive(object sender, arDev.Narumi.DataEventArgs e)
{ {
@@ -288,6 +182,9 @@ namespace Project.ViewForm
PUB.sm.StepChanged -= Sm_StepChanged; PUB.sm.StepChanged -= Sm_StepChanged;
this.ctlAuto1.ButtonClick -= CtlAuto1_ButtonClick; this.ctlAuto1.ButtonClick -= CtlAuto1_ButtonClick;
PUB.AGV.DataReceive -= AGV_DataReceive; PUB.AGV.DataReceive -= AGV_DataReceive;
// Reset Mode to Edit
PUB._mapCanvas.Mode = AGVNavigationCore.Controls.UnifiedAGVCanvas.CanvasMode.Edit;
} }
bool tmrun = false; bool tmrun = false;
@@ -295,7 +192,15 @@ namespace Project.ViewForm
private void fAuto_VisibleChanged(object sender, EventArgs e) private void fAuto_VisibleChanged(object sender, EventArgs e)
{ {
this.timer1.Enabled = this.Visible; this.timer1.Enabled = this.Visible;
if (timer1.Enabled) timer1.Start(); if (timer1.Enabled)
{
timer1.Start();
// 화면이 보일 때 Run 모드로 강제 설정
if (PUB._mapCanvas.Mode != AGVNavigationCore.Controls.UnifiedAGVCanvas.CanvasMode.Run)
{
PUB._mapCanvas.Mode = AGVNavigationCore.Controls.UnifiedAGVCanvas.CanvasMode.Run;
}
}
else timer1.Stop(); else timer1.Stop();
} }
@@ -330,5 +235,49 @@ namespace Project.ViewForm
//tmrun = false; //tmrun = false;
} }
private void HandleRunModeClick(MapNode targetNode)
{
if (targetNode == null) return;
ENIGProtocol.AGVCommandHE targetCmd = ENIGProtocol.AGVCommandHE.Goto;
string confirmMsg = "";
if (targetNode.StationType == StationType.Charger)
{
if (MessageBox.Show($"[{targetNode.Id}] 충전기로 이동하여 충전을 진행하시겠습니까?", "작업 확인", MessageBoxButtons.YesNo) == DialogResult.Yes)
{
targetCmd = ENIGProtocol.AGVCommandHE.Charger;
ExecuteManualCommand(targetNode, targetCmd);
}
return;
}
else if (targetNode.isDockingNode)
{
// Loader, Unloader, Buffer, Cleaner - Pick/Drop Selection
ContextMenuStrip menu = new ContextMenuStrip();
var pickOn = new ToolStripMenuItem("Pick On (Move & Pick)");
pickOn.Click += (s, args) => ExecuteManualCommand(targetNode, ENIGProtocol.AGVCommandHE.PickOn);
menu.Items.Add(pickOn);
var pickOff = new ToolStripMenuItem("Pick Off (Move & Drop)");
pickOff.Click += (s, args) => ExecuteManualCommand(targetNode, ENIGProtocol.AGVCommandHE.PickOff);
menu.Items.Add(pickOff);
menu.Show(Cursor.Position);
return;
}
else
{
// Normal Node
if (MessageBox.Show($"[{targetNode.Id}] 노드로 이동하시겠습니까?", "이동 확인", MessageBoxButtons.YesNo) == DialogResult.Yes)
{
targetCmd = ENIGProtocol.AGVCommandHE.Goto;
ExecuteManualCommand(targetNode, targetCmd);
}
return;
}
}
} }
} }

View File

@@ -64,7 +64,7 @@ namespace Project.ViewForm
{ {
timer1.Stop(); timer1.Stop();
this.arLabel1.Text = PUB.BMS.Current_Level.ToString("N1") + "%"; this.arLabel1.Text = PUB.BMS.Current_Level.ToString("N1") + "%";
this.arLabel1.Sign = PUB.BMS.Current_Volt.ToString() + "v"; this.arLabel1.Sign = $"{PUB.BMS.Current_Volt}v, {PUB.BMS.Charge_watt}w";// PUB.BMS.Current_Volt.ToString() + "v";
this.cv1.Text = PUB.BMS.CellVoltage[0].ToString("N3") + "v"; this.cv1.Text = PUB.BMS.CellVoltage[0].ToString("N3") + "v";
this.cv2.Text = PUB.BMS.CellVoltage[1].ToString("N3") + "v"; this.cv2.Text = PUB.BMS.CellVoltage[1].ToString("N3") + "v";
this.cv3.Text = PUB.BMS.CellVoltage[2].ToString("N3") + "v"; this.cv3.Text = PUB.BMS.CellVoltage[2].ToString("N3") + "v";

View File

@@ -29,34 +29,42 @@
private void InitializeComponent() private void InitializeComponent()
{ {
this.components = new System.ComponentModel.Container(); this.components = new System.ComponentModel.Container();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel(); this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.listView1 = new System.Windows.Forms.ListView();
this.columnHeader1 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.columnHeader2 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.listView2 = new System.Windows.Forms.ListView();
this.columnHeader3 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.columnHeader4 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.listView3 = new System.Windows.Forms.ListView();
this.columnHeader5 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.columnHeader6 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.listView4 = new System.Windows.Forms.ListView();
this.columnHeader7 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.columnHeader8 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
this.timer1 = new System.Windows.Forms.Timer(this.components); this.timer1 = new System.Windows.Forms.Timer(this.components);
this.dv1 = new System.Windows.Forms.DataGridView();
this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dv2 = new System.Windows.Forms.DataGridView();
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dv3 = new System.Windows.Forms.DataGridView();
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dv4 = new System.Windows.Forms.DataGridView();
this.dataGridViewTextBoxColumn5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.dataGridViewTextBoxColumn6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
this.tableLayoutPanel1.SuspendLayout(); this.tableLayoutPanel1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.dv1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dv2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dv3)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dv4)).BeginInit();
this.SuspendLayout(); this.SuspendLayout();
// //
// tableLayoutPanel1 // tableLayoutPanel1
// //
this.tableLayoutPanel1.ColumnCount = 4; this.tableLayoutPanel1.ColumnCount = 4;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 30F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 30F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 25F)); this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 20F));
this.tableLayoutPanel1.Controls.Add(this.listView1, 0, 0); this.tableLayoutPanel1.Controls.Add(this.dv4, 2, 1);
this.tableLayoutPanel1.Controls.Add(this.listView2, 1, 0); this.tableLayoutPanel1.Controls.Add(this.dv3, 2, 0);
this.tableLayoutPanel1.Controls.Add(this.listView3, 2, 0); this.tableLayoutPanel1.Controls.Add(this.dv2, 1, 0);
this.tableLayoutPanel1.Controls.Add(this.listView4, 3, 0); this.tableLayoutPanel1.Controls.Add(this.dv1, 0, 0);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(3, 3); this.tableLayoutPanel1.Location = new System.Drawing.Point(3, 3);
this.tableLayoutPanel1.Name = "tableLayoutPanel1"; this.tableLayoutPanel1.Name = "tableLayoutPanel1";
@@ -66,92 +74,167 @@
this.tableLayoutPanel1.Size = new System.Drawing.Size(1050, 577); this.tableLayoutPanel1.Size = new System.Drawing.Size(1050, 577);
this.tableLayoutPanel1.TabIndex = 6; this.tableLayoutPanel1.TabIndex = 6;
// //
// listView1
//
this.listView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.columnHeader1,
this.columnHeader2});
this.listView1.Dock = System.Windows.Forms.DockStyle.Fill;
this.listView1.HideSelection = false;
this.listView1.Location = new System.Drawing.Point(3, 3);
this.listView1.Name = "listView1";
this.tableLayoutPanel1.SetRowSpan(this.listView1, 2);
this.listView1.Size = new System.Drawing.Size(256, 571);
this.listView1.TabIndex = 0;
this.listView1.UseCompatibleStateImageBehavior = false;
this.listView1.View = System.Windows.Forms.View.Details;
this.listView1.SelectedIndexChanged += new System.EventHandler(this.listView1_SelectedIndexChanged);
//
// columnHeader1
//
this.columnHeader1.Width = 120;
//
// columnHeader2
//
this.columnHeader2.Width = 120;
//
// listView2
//
this.listView2.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.columnHeader3,
this.columnHeader4});
this.listView2.Dock = System.Windows.Forms.DockStyle.Fill;
this.listView2.HideSelection = false;
this.listView2.Location = new System.Drawing.Point(265, 3);
this.listView2.Name = "listView2";
this.tableLayoutPanel1.SetRowSpan(this.listView2, 2);
this.listView2.Size = new System.Drawing.Size(256, 571);
this.listView2.TabIndex = 0;
this.listView2.UseCompatibleStateImageBehavior = false;
this.listView2.View = System.Windows.Forms.View.Details;
//
// columnHeader3
//
this.columnHeader3.Width = 120;
//
// listView3
//
this.listView3.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.columnHeader5,
this.columnHeader6});
this.listView3.Dock = System.Windows.Forms.DockStyle.Fill;
this.listView3.HideSelection = false;
this.listView3.Location = new System.Drawing.Point(527, 3);
this.listView3.Name = "listView3";
this.tableLayoutPanel1.SetRowSpan(this.listView3, 2);
this.listView3.Size = new System.Drawing.Size(256, 571);
this.listView3.TabIndex = 0;
this.listView3.UseCompatibleStateImageBehavior = false;
this.listView3.View = System.Windows.Forms.View.Details;
//
// columnHeader5
//
this.columnHeader5.Width = 120;
//
// listView4
//
this.listView4.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.columnHeader7,
this.columnHeader8});
this.listView4.Dock = System.Windows.Forms.DockStyle.Fill;
this.listView4.HideSelection = false;
this.listView4.Location = new System.Drawing.Point(789, 3);
this.listView4.Name = "listView4";
this.tableLayoutPanel1.SetRowSpan(this.listView4, 2);
this.listView4.Size = new System.Drawing.Size(258, 571);
this.listView4.TabIndex = 0;
this.listView4.UseCompatibleStateImageBehavior = false;
this.listView4.View = System.Windows.Forms.View.Details;
//
// columnHeader7
//
this.columnHeader7.Width = 120;
//
// timer1 // timer1
// //
this.timer1.Interval = 500; this.timer1.Interval = 500;
this.timer1.Tick += new System.EventHandler(this.timer1_Tick); this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
// //
// dv1
//
this.dv1.AllowUserToAddRows = false;
this.dv1.AllowUserToDeleteRows = false;
this.dv1.AllowUserToResizeRows = false;
this.dv1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dv1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.Column1,
this.Column2});
dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle4.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle4.Font = new System.Drawing.Font("Calibri", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
dataGridViewCellStyle4.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle4.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dv1.DefaultCellStyle = dataGridViewCellStyle4;
this.dv1.Dock = System.Windows.Forms.DockStyle.Fill;
this.dv1.Location = new System.Drawing.Point(3, 3);
this.dv1.Name = "dv1";
this.dv1.ReadOnly = true;
this.dv1.RowHeadersVisible = false;
this.tableLayoutPanel1.SetRowSpan(this.dv1, 2);
this.dv1.RowTemplate.Height = 23;
this.dv1.Size = new System.Drawing.Size(309, 571);
this.dv1.TabIndex = 1;
//
// Column1
//
this.Column1.HeaderText = "Column1";
this.Column1.Name = "Column1";
this.Column1.ReadOnly = true;
//
// Column2
//
this.Column2.HeaderText = "Column2";
this.Column2.Name = "Column2";
this.Column2.ReadOnly = true;
//
// dv2
//
this.dv2.AllowUserToAddRows = false;
this.dv2.AllowUserToDeleteRows = false;
this.dv2.AllowUserToResizeRows = false;
this.dv2.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dv2.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.dataGridViewTextBoxColumn1,
this.dataGridViewTextBoxColumn2});
dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle3.Font = new System.Drawing.Font("Calibri", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
dataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dv2.DefaultCellStyle = dataGridViewCellStyle3;
this.dv2.Dock = System.Windows.Forms.DockStyle.Fill;
this.dv2.Location = new System.Drawing.Point(318, 3);
this.dv2.Name = "dv2";
this.dv2.ReadOnly = true;
this.dv2.RowHeadersVisible = false;
this.tableLayoutPanel1.SetRowSpan(this.dv2, 2);
this.dv2.RowTemplate.Height = 23;
this.dv2.Size = new System.Drawing.Size(309, 571);
this.dv2.TabIndex = 2;
//
// dataGridViewTextBoxColumn1
//
this.dataGridViewTextBoxColumn1.HeaderText = "Column1";
this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1";
this.dataGridViewTextBoxColumn1.ReadOnly = true;
//
// dataGridViewTextBoxColumn2
//
this.dataGridViewTextBoxColumn2.HeaderText = "Column2";
this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2";
this.dataGridViewTextBoxColumn2.ReadOnly = true;
//
// dv3
//
this.dv3.AllowUserToAddRows = false;
this.dv3.AllowUserToDeleteRows = false;
this.dv3.AllowUserToResizeRows = false;
this.dv3.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dv3.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.dataGridViewTextBoxColumn3,
this.dataGridViewTextBoxColumn4});
this.tableLayoutPanel1.SetColumnSpan(this.dv3, 2);
dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle2.Font = new System.Drawing.Font("Calibri", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dv3.DefaultCellStyle = dataGridViewCellStyle2;
this.dv3.Dock = System.Windows.Forms.DockStyle.Fill;
this.dv3.Location = new System.Drawing.Point(633, 3);
this.dv3.Name = "dv3";
this.dv3.ReadOnly = true;
this.dv3.RowHeadersVisible = false;
this.dv3.RowTemplate.Height = 23;
this.dv3.Size = new System.Drawing.Size(414, 282);
this.dv3.TabIndex = 3;
//
// dataGridViewTextBoxColumn3
//
this.dataGridViewTextBoxColumn3.HeaderText = "Column1";
this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3";
this.dataGridViewTextBoxColumn3.ReadOnly = true;
//
// dataGridViewTextBoxColumn4
//
this.dataGridViewTextBoxColumn4.HeaderText = "Column2";
this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4";
this.dataGridViewTextBoxColumn4.ReadOnly = true;
//
// dv4
//
this.dv4.AllowUserToAddRows = false;
this.dv4.AllowUserToDeleteRows = false;
this.dv4.AllowUserToResizeRows = false;
this.dv4.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
this.dv4.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
this.dataGridViewTextBoxColumn5,
this.dataGridViewTextBoxColumn6});
this.tableLayoutPanel1.SetColumnSpan(this.dv4, 2);
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Window;
dataGridViewCellStyle1.Font = new System.Drawing.Font("Calibri", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.ControlText;
dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
this.dv4.DefaultCellStyle = dataGridViewCellStyle1;
this.dv4.Dock = System.Windows.Forms.DockStyle.Fill;
this.dv4.Location = new System.Drawing.Point(633, 291);
this.dv4.Name = "dv4";
this.dv4.ReadOnly = true;
this.dv4.RowHeadersVisible = false;
this.dv4.RowTemplate.Height = 23;
this.dv4.Size = new System.Drawing.Size(414, 283);
this.dv4.TabIndex = 4;
//
// dataGridViewTextBoxColumn5
//
this.dataGridViewTextBoxColumn5.HeaderText = "Column1";
this.dataGridViewTextBoxColumn5.Name = "dataGridViewTextBoxColumn5";
this.dataGridViewTextBoxColumn5.ReadOnly = true;
//
// dataGridViewTextBoxColumn6
//
this.dataGridViewTextBoxColumn6.HeaderText = "Column2";
this.dataGridViewTextBoxColumn6.Name = "dataGridViewTextBoxColumn6";
this.dataGridViewTextBoxColumn6.ReadOnly = true;
//
// fFlag // fFlag
// //
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
@@ -165,6 +248,10 @@
this.Load += new System.EventHandler(this.fFlag_Load); this.Load += new System.EventHandler(this.fFlag_Load);
this.VisibleChanged += new System.EventHandler(this.fFlag_VisibleChanged); this.VisibleChanged += new System.EventHandler(this.fFlag_VisibleChanged);
this.tableLayoutPanel1.ResumeLayout(false); this.tableLayoutPanel1.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.dv1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dv2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dv3)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dv4)).EndInit();
this.ResumeLayout(false); this.ResumeLayout(false);
} }
@@ -173,17 +260,17 @@
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1; private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.Timer timer1; private System.Windows.Forms.Timer timer1;
private System.Windows.Forms.ListView listView1; private System.Windows.Forms.DataGridView dv4;
private System.Windows.Forms.ListView listView2; private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn5;
private System.Windows.Forms.ListView listView3; private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn6;
private System.Windows.Forms.ListView listView4; private System.Windows.Forms.DataGridView dv3;
private System.Windows.Forms.ColumnHeader columnHeader1; private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn3;
private System.Windows.Forms.ColumnHeader columnHeader2; private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn4;
private System.Windows.Forms.ColumnHeader columnHeader3; private System.Windows.Forms.DataGridView dv2;
private System.Windows.Forms.ColumnHeader columnHeader4; private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn1;
private System.Windows.Forms.ColumnHeader columnHeader5; private System.Windows.Forms.DataGridViewTextBoxColumn dataGridViewTextBoxColumn2;
private System.Windows.Forms.ColumnHeader columnHeader6; private System.Windows.Forms.DataGridView dv1;
private System.Windows.Forms.ColumnHeader columnHeader7; private System.Windows.Forms.DataGridViewTextBoxColumn Column1;
private System.Windows.Forms.ColumnHeader columnHeader8; private System.Windows.Forms.DataGridViewTextBoxColumn Column2;
} }
} }

View File

@@ -30,16 +30,18 @@ namespace Project.ViewForm
void MakeControl() void MakeControl()
{ {
ListView[] lvs = new ListView[] { listView1, listView2, listView3, listView4 }; DataGridView[] dvs = new DataGridView[] { dv1, dv2, dv3, dv4 };
foreach (var lv in lvs)
foreach(var lv in dvs)
{ {
lv.Columns.Clear(); lv.Columns.Clear();
lv.Columns.Add("Idx"); lv.Columns.Add("idx", "*");
lv.Columns.Add("Title"); lv.Columns.Add("Title", "Title");
lv.Columns.Add("Value"); lv.Columns.Add("Value", "Value");
lv.Columns[0].Width = 25; lv.Columns[0].Width = 25;
lv.Columns[1].Width = 150; lv.Columns[1].Width = 150;
lv.Columns[2].Width = 100; lv.Columns[2].AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill;
} }
Array valuelist; Array valuelist;
@@ -47,38 +49,33 @@ namespace Project.ViewForm
foreach (var item in valuelist) foreach (var item in valuelist)
{ {
var v = (COMM.eVarBool)item; var v = (COMM.eVarBool)item;
var lv = listView1.Items.Add($"{(int)v}"); dv1.Rows.Add($"{(int)v}", item, "--");
lv.SubItems.Add($"{item}");
lv.SubItems.Add("--");
} }
valuelist = Enum.GetValues(typeof(COMM.eVarInt32)); valuelist = Enum.GetValues(typeof(COMM.eVarInt32));
foreach (var item in valuelist) foreach (var item in valuelist)
{ {
var v = (COMM.eVarInt32)item; var v = (COMM.eVarInt32)item;
var lv = listView2.Items.Add($"{(int)v}"); dv2.Rows.Add($"{(int)v}", item, "--");
lv.SubItems.Add($"{item}");
lv.SubItems.Add("--");
} }
valuelist = Enum.GetValues(typeof(COMM.eVarString)); valuelist = Enum.GetValues(typeof(COMM.eVarString));
foreach (var item in valuelist) foreach (var item in valuelist)
{ {
var v = (COMM.eVarString)item; var v = (COMM.eVarString)item;
var lv = listView3.Items.Add($"{(int)v}"); dv3.Rows.Add($"{(int)v}", item, "--");
lv.SubItems.Add($"{item}");
lv.SubItems.Add("--");
} }
valuelist = Enum.GetValues(typeof(COMM.eVarTime)); valuelist = Enum.GetValues(typeof(COMM.eVarTime));
foreach (var item in valuelist) foreach (var item in valuelist)
{ {
var v = (COMM.eVarString)item; var v = (COMM.eVarString)item;
var lv = listView4.Items.Add($"{(int)v}"); dv4.Rows.Add($"{(int)v}", item, "--");
lv.SubItems.Add($"{item}");
lv.SubItems.Add("--");
} }
foreach (var dv in dvs)
dv.AutoResizeColumns();
} }
@@ -91,42 +88,32 @@ namespace Project.ViewForm
private void timer1_Tick(object sender, EventArgs e) private void timer1_Tick(object sender, EventArgs e)
{ {
timer1.Stop(); timer1.Stop();
listView1.SuspendLayout(); foreach(DataGridViewRow item in this.dv1.Rows)
foreach (ListViewItem item in listView1.Items)
{ {
var idx = int.Parse(item.SubItems[0].Text); var idx = int.Parse(item.Cells["idx"].Value.ToString());
var v = VAR.BOOL.Get(idx); var v = VAR.BOOL.Get(idx);
var desc = VAR.BOOL.GetCodeDesc(idx); item.Cells["value"].Value = v ? "O" : "X";
item.SubItems[2].Text = v ? "O" : "X";
} }
listView1.ResumeLayout();
listView2.SuspendLayout(); foreach (DataGridViewRow item in this.dv2.Rows)
foreach (ListViewItem item in listView2.Items)
{ {
var idx = int.Parse(item.SubItems[0].Text); var idx = int.Parse(item.Cells["idx"].Value.ToString());
var v = VAR.I32.Get(idx); var v = VAR.I32.Get(idx);
var desc = VAR.I32.GetCodeDesc(idx); item.Cells["value"].Value = v.ToString();
item.SubItems[2].Text = v.ToString();
} }
listView2.ResumeLayout();
listView3.SuspendLayout(); foreach (DataGridViewRow item in this.dv3.Rows)
foreach (ListViewItem item in listView3.Items)
{ {
var idx = int.Parse(item.SubItems[0].Text); var idx = int.Parse(item.Cells["idx"].Value.ToString());
var v = VAR.STR.Get(idx); var v = VAR.STR.Get(idx);
var desc = VAR.STR.GetCodeDesc(idx); item.Cells["value"].Value = v;
item.SubItems[2].Text = v;
} }
listView3.ResumeLayout(); foreach (DataGridViewRow item in this.dv4.Rows)
listView4.SuspendLayout();
foreach (ListViewItem item in listView4.Items)
{ {
var idx = int.Parse(item.SubItems[0].Text); var idx = int.Parse(item.Cells["idx"].Value.ToString());
var v = VAR.TIME.Get(idx); var v = VAR.TIME.Get(idx);
var desc = VAR.TIME.GetCodeDesc(idx); item.Cells["value"].Value = v.ToString("HH:mm:ss.fff");
item.SubItems[2].Text = v.ToString("HH:mm:ss.fff");
} }
listView4.ResumeLayout();
timer1.Start(); timer1.Start();
} }

View File

@@ -117,6 +117,30 @@
<resheader name="writer"> <resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader> </resheader>
<metadata name="dataGridViewTextBoxColumn5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="dataGridViewTextBoxColumn2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="Column2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> <metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value> <value>17, 17</value>
</metadata> </metadata>

View File

@@ -41,45 +41,45 @@
this.btErrReset = new System.Windows.Forms.Button(); this.btErrReset = new System.Windows.Forms.Button();
this.timer1 = new System.Windows.Forms.Timer(this.components); this.timer1 = new System.Windows.Forms.Timer(this.components);
this.panel2 = new System.Windows.Forms.Panel(); this.panel2 = new System.Windows.Forms.Panel();
this.btRight180 = new System.Windows.Forms.Button(); this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
this.btBack180 = new System.Windows.Forms.Button();
this.btLeft180 = new System.Windows.Forms.Button(); this.btLeft180 = new System.Windows.Forms.Button();
this.btRight180 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button(); this.button1 = new System.Windows.Forms.Button();
this.groupBox1 = new System.Windows.Forms.GroupBox(); this.groupBox1 = new System.Windows.Forms.GroupBox();
this.radpbs2 = new AGVControl.MyRadioButton();
this.panel9 = new System.Windows.Forms.Panel(); this.panel9 = new System.Windows.Forms.Panel();
this.radpbs1 = new AGVControl.MyRadioButton();
this.panel3 = new System.Windows.Forms.Panel(); this.panel3 = new System.Windows.Forms.Panel();
this.radpbs0 = new AGVControl.MyRadioButton();
this.grpSpeed = new System.Windows.Forms.GroupBox(); this.grpSpeed = new System.Windows.Forms.GroupBox();
this.radspdh = new AGVControl.MyRadioButton();
this.panel8 = new System.Windows.Forms.Panel(); this.panel8 = new System.Windows.Forms.Panel();
this.radspdm = new AGVControl.MyRadioButton();
this.panel4 = new System.Windows.Forms.Panel(); this.panel4 = new System.Windows.Forms.Panel();
this.radspdl = new AGVControl.MyRadioButton();
this.grpBunki = new System.Windows.Forms.GroupBox(); this.grpBunki = new System.Windows.Forms.GroupBox();
this.radright = new AGVControl.MyRadioButton();
this.panel7 = new System.Windows.Forms.Panel(); this.panel7 = new System.Windows.Forms.Panel();
this.radstrai = new AGVControl.MyRadioButton();
this.panel5 = new System.Windows.Forms.Panel(); this.panel5 = new System.Windows.Forms.Panel();
this.radleft = new AGVControl.MyRadioButton();
this.groupBox2 = new System.Windows.Forms.GroupBox(); this.groupBox2 = new System.Windows.Forms.GroupBox();
this.arLabel1 = new arCtl.arLabel(); this.arLabel1 = new arCtl.arLabel();
this.panel12 = new System.Windows.Forms.Panel(); this.panel12 = new System.Windows.Forms.Panel();
this.panel6 = new System.Windows.Forms.Panel();
this.label1 = new System.Windows.Forms.Label();
this.radpbs2 = new AGVControl.MyRadioButton();
this.radpbs1 = new AGVControl.MyRadioButton();
this.radpbs0 = new AGVControl.MyRadioButton();
this.radspdh = new AGVControl.MyRadioButton();
this.radspdm = new AGVControl.MyRadioButton();
this.radspdl = new AGVControl.MyRadioButton();
this.radright = new AGVControl.MyRadioButton();
this.radstrai = new AGVControl.MyRadioButton();
this.radleft = new AGVControl.MyRadioButton();
this.radbackward = new AGVControl.MyRadioButton(); this.radbackward = new AGVControl.MyRadioButton();
this.panel6 = new System.Windows.Forms.Panel();
this.radforward = new AGVControl.MyRadioButton(); this.radforward = new AGVControl.MyRadioButton();
this.label1 = new System.Windows.Forms.Label();
this.guideSensor1 = new Narumi.UC.GuideSensor(); this.guideSensor1 = new Narumi.UC.GuideSensor();
this.btBack180 = new System.Windows.Forms.Button();
this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
this.button2 = new System.Windows.Forms.Button();
this.tableLayoutPanel1.SuspendLayout(); this.tableLayoutPanel1.SuspendLayout();
this.panel2.SuspendLayout(); this.panel2.SuspendLayout();
this.tableLayoutPanel2.SuspendLayout();
this.groupBox1.SuspendLayout(); this.groupBox1.SuspendLayout();
this.grpSpeed.SuspendLayout(); this.grpSpeed.SuspendLayout();
this.grpBunki.SuspendLayout(); this.grpBunki.SuspendLayout();
this.groupBox2.SuspendLayout(); this.groupBox2.SuspendLayout();
this.tableLayoutPanel2.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
// tableLayoutPanel1 // tableLayoutPanel1
@@ -124,7 +124,7 @@
this.btStart.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal; this.btStart.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal;
this.btStart.GradientRepeatBG = false; this.btStart.GradientRepeatBG = false;
this.btStart.isButton = true; this.btStart.isButton = true;
this.btStart.Location = new System.Drawing.Point(204, 201); this.btStart.Location = new System.Drawing.Point(204, 200);
this.btStart.MouseDownColor = System.Drawing.Color.Yellow; this.btStart.MouseDownColor = System.Drawing.Color.Yellow;
this.btStart.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); this.btStart.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.btStart.msg = new string[] { this.btStart.msg = new string[] {
@@ -146,7 +146,7 @@
this.btStart.SignAlign = System.Drawing.ContentAlignment.BottomRight; this.btStart.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.btStart.SignColor = System.Drawing.Color.Yellow; this.btStart.SignColor = System.Drawing.Color.Yellow;
this.btStart.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic); this.btStart.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.btStart.Size = new System.Drawing.Size(195, 192); this.btStart.Size = new System.Drawing.Size(195, 191);
this.btStart.TabIndex = 6; this.btStart.TabIndex = 6;
this.btStart.Text = "RUN"; this.btStart.Text = "RUN";
this.btStart.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.btStart.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
@@ -171,7 +171,7 @@
this.btRight.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal; this.btRight.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal;
this.btRight.GradientRepeatBG = false; this.btRight.GradientRepeatBG = false;
this.btRight.isButton = true; this.btRight.isButton = true;
this.btRight.Location = new System.Drawing.Point(405, 201); this.btRight.Location = new System.Drawing.Point(405, 200);
this.btRight.MouseDownColor = System.Drawing.Color.Yellow; this.btRight.MouseDownColor = System.Drawing.Color.Yellow;
this.btRight.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); this.btRight.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.btRight.msg = null; this.btRight.msg = null;
@@ -191,7 +191,7 @@
this.btRight.SignAlign = System.Drawing.ContentAlignment.BottomRight; this.btRight.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.btRight.SignColor = System.Drawing.Color.Yellow; this.btRight.SignColor = System.Drawing.Color.Yellow;
this.btRight.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic); this.btRight.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.btRight.Size = new System.Drawing.Size(196, 192); this.btRight.Size = new System.Drawing.Size(196, 191);
this.btRight.TabIndex = 0; this.btRight.TabIndex = 0;
this.btRight.Text = "좌회전"; this.btRight.Text = "좌회전";
this.btRight.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.btRight.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
@@ -237,7 +237,7 @@
this.btBack.SignAlign = System.Drawing.ContentAlignment.BottomRight; this.btBack.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.btBack.SignColor = System.Drawing.Color.Yellow; this.btBack.SignColor = System.Drawing.Color.Yellow;
this.btBack.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic); this.btBack.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.btBack.Size = new System.Drawing.Size(195, 192); this.btBack.Size = new System.Drawing.Size(195, 191);
this.btBack.TabIndex = 0; this.btBack.TabIndex = 0;
this.btBack.Text = "후진"; this.btBack.Text = "후진";
this.btBack.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.btBack.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
@@ -262,7 +262,7 @@
this.btForward.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal; this.btForward.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal;
this.btForward.GradientRepeatBG = false; this.btForward.GradientRepeatBG = false;
this.btForward.isButton = true; this.btForward.isButton = true;
this.btForward.Location = new System.Drawing.Point(204, 399); this.btForward.Location = new System.Drawing.Point(204, 397);
this.btForward.MouseDownColor = System.Drawing.Color.Yellow; this.btForward.MouseDownColor = System.Drawing.Color.Yellow;
this.btForward.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); this.btForward.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.btForward.msg = null; this.btForward.msg = null;
@@ -282,7 +282,7 @@
this.btForward.SignAlign = System.Drawing.ContentAlignment.BottomRight; this.btForward.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.btForward.SignColor = System.Drawing.Color.Yellow; this.btForward.SignColor = System.Drawing.Color.Yellow;
this.btForward.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic); this.btForward.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.btForward.Size = new System.Drawing.Size(195, 192); this.btForward.Size = new System.Drawing.Size(195, 194);
this.btForward.TabIndex = 0; this.btForward.TabIndex = 0;
this.btForward.Text = "전진"; this.btForward.Text = "전진";
this.btForward.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.btForward.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
@@ -307,7 +307,7 @@
this.btLeft.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal; this.btLeft.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal;
this.btLeft.GradientRepeatBG = false; this.btLeft.GradientRepeatBG = false;
this.btLeft.isButton = true; this.btLeft.isButton = true;
this.btLeft.Location = new System.Drawing.Point(3, 201); this.btLeft.Location = new System.Drawing.Point(3, 200);
this.btLeft.MouseDownColor = System.Drawing.Color.Yellow; this.btLeft.MouseDownColor = System.Drawing.Color.Yellow;
this.btLeft.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64))))); this.btLeft.MouseOverColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.btLeft.msg = null; this.btLeft.msg = null;
@@ -327,7 +327,7 @@
this.btLeft.SignAlign = System.Drawing.ContentAlignment.BottomRight; this.btLeft.SignAlign = System.Drawing.ContentAlignment.BottomRight;
this.btLeft.SignColor = System.Drawing.Color.Yellow; this.btLeft.SignColor = System.Drawing.Color.Yellow;
this.btLeft.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic); this.btLeft.SignFont = new System.Drawing.Font("Consolas", 7F, System.Drawing.FontStyle.Italic);
this.btLeft.Size = new System.Drawing.Size(195, 192); this.btLeft.Size = new System.Drawing.Size(195, 191);
this.btLeft.TabIndex = 0; this.btLeft.TabIndex = 0;
this.btLeft.Text = "우회전"; this.btLeft.Text = "우회전";
this.btLeft.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.btLeft.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
@@ -341,7 +341,7 @@
this.btMarkStop.Font = new System.Drawing.Font("맑은 고딕", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129))); this.btMarkStop.Font = new System.Drawing.Font("맑은 고딕", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.btMarkStop.Location = new System.Drawing.Point(3, 3); this.btMarkStop.Location = new System.Drawing.Point(3, 3);
this.btMarkStop.Name = "btMarkStop"; this.btMarkStop.Name = "btMarkStop";
this.btMarkStop.Size = new System.Drawing.Size(195, 192); this.btMarkStop.Size = new System.Drawing.Size(195, 191);
this.btMarkStop.TabIndex = 7; this.btMarkStop.TabIndex = 7;
this.btMarkStop.Text = "마크정지"; this.btMarkStop.Text = "마크정지";
this.btMarkStop.UseVisualStyleBackColor = true; this.btMarkStop.UseVisualStyleBackColor = true;
@@ -351,9 +351,9 @@
// //
this.btchargeOff.Dock = System.Windows.Forms.DockStyle.Fill; this.btchargeOff.Dock = System.Windows.Forms.DockStyle.Fill;
this.btchargeOff.Font = new System.Drawing.Font("맑은 고딕", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129))); this.btchargeOff.Font = new System.Drawing.Font("맑은 고딕", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.btchargeOff.Location = new System.Drawing.Point(405, 399); this.btchargeOff.Location = new System.Drawing.Point(405, 397);
this.btchargeOff.Name = "btchargeOff"; this.btchargeOff.Name = "btchargeOff";
this.btchargeOff.Size = new System.Drawing.Size(196, 192); this.btchargeOff.Size = new System.Drawing.Size(196, 194);
this.btchargeOff.TabIndex = 8; this.btchargeOff.TabIndex = 8;
this.btchargeOff.Text = "충전해제"; this.btchargeOff.Text = "충전해제";
this.btchargeOff.UseVisualStyleBackColor = true; this.btchargeOff.UseVisualStyleBackColor = true;
@@ -363,9 +363,9 @@
// //
this.btChargeOn.Dock = System.Windows.Forms.DockStyle.Fill; this.btChargeOn.Dock = System.Windows.Forms.DockStyle.Fill;
this.btChargeOn.Font = new System.Drawing.Font("맑은 고딕", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129))); this.btChargeOn.Font = new System.Drawing.Font("맑은 고딕", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.btChargeOn.Location = new System.Drawing.Point(3, 399); this.btChargeOn.Location = new System.Drawing.Point(3, 397);
this.btChargeOn.Name = "btChargeOn"; this.btChargeOn.Name = "btChargeOn";
this.btChargeOn.Size = new System.Drawing.Size(195, 192); this.btChargeOn.Size = new System.Drawing.Size(195, 194);
this.btChargeOn.TabIndex = 9; this.btChargeOn.TabIndex = 9;
this.btChargeOn.Text = "충전"; this.btChargeOn.Text = "충전";
this.btChargeOn.UseVisualStyleBackColor = true; this.btChargeOn.UseVisualStyleBackColor = true;
@@ -377,7 +377,7 @@
this.btErrReset.Font = new System.Drawing.Font("맑은 고딕", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129))); this.btErrReset.Font = new System.Drawing.Font("맑은 고딕", 20F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.btErrReset.Location = new System.Drawing.Point(405, 3); this.btErrReset.Location = new System.Drawing.Point(405, 3);
this.btErrReset.Name = "btErrReset"; this.btErrReset.Name = "btErrReset";
this.btErrReset.Size = new System.Drawing.Size(196, 192); this.btErrReset.Size = new System.Drawing.Size(196, 191);
this.btErrReset.TabIndex = 10; this.btErrReset.TabIndex = 10;
this.btErrReset.Text = "오류소거"; this.btErrReset.Text = "오류소거";
this.btErrReset.UseVisualStyleBackColor = true; this.btErrReset.UseVisualStyleBackColor = true;
@@ -403,19 +403,38 @@
this.panel2.TabIndex = 9; this.panel2.TabIndex = 9;
this.panel2.Paint += new System.Windows.Forms.PaintEventHandler(this.panel2_Paint); this.panel2.Paint += new System.Windows.Forms.PaintEventHandler(this.panel2_Paint);
// //
// btRight180 // tableLayoutPanel2
// //
this.btRight180.BackColor = System.Drawing.Color.WhiteSmoke; this.tableLayoutPanel2.ColumnCount = 2;
this.btRight180.Dock = System.Windows.Forms.DockStyle.Fill; this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.btRight180.Font = new System.Drawing.Font("맑은 고딕", 10F, System.Drawing.FontStyle.Bold); this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.btRight180.ForeColor = System.Drawing.Color.Black; this.tableLayoutPanel2.Controls.Add(this.btBack180, 1, 0);
this.btRight180.Location = new System.Drawing.Point(3, 62); this.tableLayoutPanel2.Controls.Add(this.btLeft180, 0, 0);
this.btRight180.Name = "btRight180"; this.tableLayoutPanel2.Controls.Add(this.btRight180, 0, 1);
this.btRight180.Size = new System.Drawing.Size(196, 53); this.tableLayoutPanel2.Controls.Add(this.button2, 1, 1);
this.btRight180.TabIndex = 6; this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.btRight180.Text = "180도 우회전"; this.tableLayoutPanel2.Location = new System.Drawing.Point(0, 438);
this.btRight180.UseVisualStyleBackColor = false; this.tableLayoutPanel2.Name = "tableLayoutPanel2";
this.btRight180.Click += new System.EventHandler(this.btRight180_Click); this.tableLayoutPanel2.RowCount = 2;
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.Size = new System.Drawing.Size(404, 118);
this.tableLayoutPanel2.TabIndex = 12;
//
// btBack180
//
this.btBack180.BackColor = System.Drawing.Color.WhiteSmoke;
this.btBack180.Cursor = System.Windows.Forms.Cursors.Hand;
this.btBack180.Dock = System.Windows.Forms.DockStyle.Fill;
this.btBack180.Font = new System.Drawing.Font("맑은 고딕", 10F, System.Drawing.FontStyle.Bold);
this.btBack180.ForeColor = System.Drawing.Color.Black;
this.btBack180.Location = new System.Drawing.Point(205, 3);
this.btBack180.Name = "btBack180";
this.btBack180.Size = new System.Drawing.Size(196, 53);
this.btBack180.TabIndex = 15;
this.btBack180.Text = "자석 (ON)";
this.btBack180.UseVisualStyleBackColor = false;
this.btBack180.Click += new System.EventHandler(this.btBack180_Click);
// //
// btLeft180 // btLeft180
// //
@@ -431,6 +450,35 @@
this.btLeft180.UseVisualStyleBackColor = false; this.btLeft180.UseVisualStyleBackColor = false;
this.btLeft180.Click += new System.EventHandler(this.btLeft180_Click); this.btLeft180.Click += new System.EventHandler(this.btLeft180_Click);
// //
// btRight180
//
this.btRight180.BackColor = System.Drawing.Color.WhiteSmoke;
this.btRight180.Dock = System.Windows.Forms.DockStyle.Fill;
this.btRight180.Font = new System.Drawing.Font("맑은 고딕", 10F, System.Drawing.FontStyle.Bold);
this.btRight180.ForeColor = System.Drawing.Color.Black;
this.btRight180.Location = new System.Drawing.Point(3, 62);
this.btRight180.Name = "btRight180";
this.btRight180.Size = new System.Drawing.Size(196, 53);
this.btRight180.TabIndex = 6;
this.btRight180.Text = "180도 우회전";
this.btRight180.UseVisualStyleBackColor = false;
this.btRight180.Click += new System.EventHandler(this.btRight180_Click);
//
// button2
//
this.button2.BackColor = System.Drawing.Color.WhiteSmoke;
this.button2.Cursor = System.Windows.Forms.Cursors.Hand;
this.button2.Dock = System.Windows.Forms.DockStyle.Fill;
this.button2.Font = new System.Drawing.Font("맑은 고딕", 10F, System.Drawing.FontStyle.Bold);
this.button2.ForeColor = System.Drawing.Color.Black;
this.button2.Location = new System.Drawing.Point(205, 62);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(196, 53);
this.button2.TabIndex = 15;
this.button2.Text = "자석(OFF)";
this.button2.UseVisualStyleBackColor = false;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// button1 // button1
// //
this.button1.Dock = System.Windows.Forms.DockStyle.Top; this.button1.Dock = System.Windows.Forms.DockStyle.Top;
@@ -459,6 +507,25 @@
this.groupBox1.TabStop = false; this.groupBox1.TabStop = false;
this.groupBox1.Text = "근접센서(PBS)"; this.groupBox1.Text = "근접센서(PBS)";
// //
// radpbs2
//
this.radpbs2.BackColor = System.Drawing.Color.WhiteSmoke;
this.radpbs2.Bordercolor = System.Drawing.Color.DimGray;
this.radpbs2.BorderRadius = 7;
this.radpbs2.BorderSize = 2;
this.radpbs2.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radpbs2.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radpbs2.CheckWidth = 30;
this.radpbs2.Dock = System.Windows.Forms.DockStyle.Left;
this.radpbs2.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radpbs2.Location = new System.Drawing.Point(278, 19);
this.radpbs2.Name = "radpbs2";
this.radpbs2.Size = new System.Drawing.Size(119, 66);
this.radpbs2.TabIndex = 10;
this.radpbs2.Text = "On(2)";
this.radpbs2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radpbs2.UseVisualStyleBackColor = false;
//
// panel9 // panel9
// //
this.panel9.Dock = System.Windows.Forms.DockStyle.Left; this.panel9.Dock = System.Windows.Forms.DockStyle.Left;
@@ -467,6 +534,28 @@
this.panel9.Size = new System.Drawing.Size(15, 66); this.panel9.Size = new System.Drawing.Size(15, 66);
this.panel9.TabIndex = 12; this.panel9.TabIndex = 12;
// //
// radpbs1
//
this.radpbs1.BackColor = System.Drawing.Color.WhiteSmoke;
this.radpbs1.Bordercolor = System.Drawing.Color.DimGray;
this.radpbs1.BorderRadius = 7;
this.radpbs1.BorderSize = 2;
this.radpbs1.Checked = true;
this.radpbs1.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radpbs1.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radpbs1.CheckWidth = 30;
this.radpbs1.Dock = System.Windows.Forms.DockStyle.Left;
this.radpbs1.Font = new System.Drawing.Font("맑은 고딕", 16F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radpbs1.ForeColor = System.Drawing.Color.Blue;
this.radpbs1.Location = new System.Drawing.Point(144, 19);
this.radpbs1.Name = "radpbs1";
this.radpbs1.Size = new System.Drawing.Size(119, 66);
this.radpbs1.TabIndex = 9;
this.radpbs1.TabStop = true;
this.radpbs1.Text = "On(1)";
this.radpbs1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radpbs1.UseVisualStyleBackColor = false;
//
// panel3 // panel3
// //
this.panel3.Dock = System.Windows.Forms.DockStyle.Left; this.panel3.Dock = System.Windows.Forms.DockStyle.Left;
@@ -475,6 +564,25 @@
this.panel3.Size = new System.Drawing.Size(15, 66); this.panel3.Size = new System.Drawing.Size(15, 66);
this.panel3.TabIndex = 11; this.panel3.TabIndex = 11;
// //
// radpbs0
//
this.radpbs0.BackColor = System.Drawing.Color.WhiteSmoke;
this.radpbs0.Bordercolor = System.Drawing.Color.DimGray;
this.radpbs0.BorderRadius = 7;
this.radpbs0.BorderSize = 2;
this.radpbs0.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radpbs0.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radpbs0.CheckWidth = 30;
this.radpbs0.Dock = System.Windows.Forms.DockStyle.Left;
this.radpbs0.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radpbs0.Location = new System.Drawing.Point(10, 19);
this.radpbs0.Name = "radpbs0";
this.radpbs0.Size = new System.Drawing.Size(119, 66);
this.radpbs0.TabIndex = 8;
this.radpbs0.Text = "Off(0)";
this.radpbs0.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radpbs0.UseVisualStyleBackColor = false;
//
// grpSpeed // grpSpeed
// //
this.grpSpeed.Controls.Add(this.radspdh); this.grpSpeed.Controls.Add(this.radspdh);
@@ -491,6 +599,25 @@
this.grpSpeed.TabStop = false; this.grpSpeed.TabStop = false;
this.grpSpeed.Text = "속도"; this.grpSpeed.Text = "속도";
// //
// radspdh
//
this.radspdh.BackColor = System.Drawing.Color.WhiteSmoke;
this.radspdh.Bordercolor = System.Drawing.Color.DimGray;
this.radspdh.BorderRadius = 7;
this.radspdh.BorderSize = 2;
this.radspdh.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radspdh.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radspdh.CheckWidth = 30;
this.radspdh.Dock = System.Windows.Forms.DockStyle.Left;
this.radspdh.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radspdh.Location = new System.Drawing.Point(278, 19);
this.radspdh.Name = "radspdh";
this.radspdh.Size = new System.Drawing.Size(119, 66);
this.radspdh.TabIndex = 2;
this.radspdh.Text = "고속";
this.radspdh.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radspdh.UseVisualStyleBackColor = false;
//
// panel8 // panel8
// //
this.panel8.Dock = System.Windows.Forms.DockStyle.Left; this.panel8.Dock = System.Windows.Forms.DockStyle.Left;
@@ -499,6 +626,28 @@
this.panel8.Size = new System.Drawing.Size(15, 66); this.panel8.Size = new System.Drawing.Size(15, 66);
this.panel8.TabIndex = 13; this.panel8.TabIndex = 13;
// //
// radspdm
//
this.radspdm.BackColor = System.Drawing.Color.WhiteSmoke;
this.radspdm.Bordercolor = System.Drawing.Color.DimGray;
this.radspdm.BorderRadius = 7;
this.radspdm.BorderSize = 2;
this.radspdm.Checked = true;
this.radspdm.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radspdm.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radspdm.CheckWidth = 30;
this.radspdm.Dock = System.Windows.Forms.DockStyle.Left;
this.radspdm.Font = new System.Drawing.Font("맑은 고딕", 16F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radspdm.ForeColor = System.Drawing.Color.Blue;
this.radspdm.Location = new System.Drawing.Point(144, 19);
this.radspdm.Name = "radspdm";
this.radspdm.Size = new System.Drawing.Size(119, 66);
this.radspdm.TabIndex = 1;
this.radspdm.TabStop = true;
this.radspdm.Text = "중속";
this.radspdm.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radspdm.UseVisualStyleBackColor = false;
//
// panel4 // panel4
// //
this.panel4.Dock = System.Windows.Forms.DockStyle.Left; this.panel4.Dock = System.Windows.Forms.DockStyle.Left;
@@ -507,6 +656,25 @@
this.panel4.Size = new System.Drawing.Size(15, 66); this.panel4.Size = new System.Drawing.Size(15, 66);
this.panel4.TabIndex = 12; this.panel4.TabIndex = 12;
// //
// radspdl
//
this.radspdl.BackColor = System.Drawing.Color.WhiteSmoke;
this.radspdl.Bordercolor = System.Drawing.Color.DimGray;
this.radspdl.BorderRadius = 7;
this.radspdl.BorderSize = 2;
this.radspdl.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radspdl.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radspdl.CheckWidth = 30;
this.radspdl.Dock = System.Windows.Forms.DockStyle.Left;
this.radspdl.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radspdl.Location = new System.Drawing.Point(10, 19);
this.radspdl.Name = "radspdl";
this.radspdl.Size = new System.Drawing.Size(119, 66);
this.radspdl.TabIndex = 0;
this.radspdl.Text = "저속";
this.radspdl.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radspdl.UseVisualStyleBackColor = false;
//
// grpBunki // grpBunki
// //
this.grpBunki.Controls.Add(this.radright); this.grpBunki.Controls.Add(this.radright);
@@ -523,6 +691,25 @@
this.grpBunki.TabStop = false; this.grpBunki.TabStop = false;
this.grpBunki.Text = "분기"; this.grpBunki.Text = "분기";
// //
// radright
//
this.radright.BackColor = System.Drawing.Color.WhiteSmoke;
this.radright.Bordercolor = System.Drawing.Color.DimGray;
this.radright.BorderRadius = 7;
this.radright.BorderSize = 2;
this.radright.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radright.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radright.CheckWidth = 30;
this.radright.Dock = System.Windows.Forms.DockStyle.Left;
this.radright.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radright.Location = new System.Drawing.Point(278, 19);
this.radright.Name = "radright";
this.radright.Size = new System.Drawing.Size(119, 66);
this.radright.TabIndex = 4;
this.radright.Text = "우측";
this.radright.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radright.UseVisualStyleBackColor = false;
//
// panel7 // panel7
// //
this.panel7.Dock = System.Windows.Forms.DockStyle.Left; this.panel7.Dock = System.Windows.Forms.DockStyle.Left;
@@ -531,6 +718,28 @@
this.panel7.Size = new System.Drawing.Size(15, 66); this.panel7.Size = new System.Drawing.Size(15, 66);
this.panel7.TabIndex = 13; this.panel7.TabIndex = 13;
// //
// radstrai
//
this.radstrai.BackColor = System.Drawing.Color.WhiteSmoke;
this.radstrai.Bordercolor = System.Drawing.Color.DimGray;
this.radstrai.BorderRadius = 7;
this.radstrai.BorderSize = 2;
this.radstrai.Checked = true;
this.radstrai.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radstrai.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radstrai.CheckWidth = 30;
this.radstrai.Dock = System.Windows.Forms.DockStyle.Left;
this.radstrai.Font = new System.Drawing.Font("맑은 고딕", 16F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radstrai.ForeColor = System.Drawing.Color.Blue;
this.radstrai.Location = new System.Drawing.Point(144, 19);
this.radstrai.Name = "radstrai";
this.radstrai.Size = new System.Drawing.Size(119, 66);
this.radstrai.TabIndex = 3;
this.radstrai.TabStop = true;
this.radstrai.Text = "직진";
this.radstrai.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radstrai.UseVisualStyleBackColor = false;
//
// panel5 // panel5
// //
this.panel5.Dock = System.Windows.Forms.DockStyle.Left; this.panel5.Dock = System.Windows.Forms.DockStyle.Left;
@@ -539,6 +748,25 @@
this.panel5.Size = new System.Drawing.Size(15, 66); this.panel5.Size = new System.Drawing.Size(15, 66);
this.panel5.TabIndex = 12; this.panel5.TabIndex = 12;
// //
// radleft
//
this.radleft.BackColor = System.Drawing.Color.WhiteSmoke;
this.radleft.Bordercolor = System.Drawing.Color.DimGray;
this.radleft.BorderRadius = 7;
this.radleft.BorderSize = 2;
this.radleft.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radleft.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radleft.CheckWidth = 30;
this.radleft.Dock = System.Windows.Forms.DockStyle.Left;
this.radleft.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radleft.Location = new System.Drawing.Point(10, 19);
this.radleft.Name = "radleft";
this.radleft.Size = new System.Drawing.Size(119, 66);
this.radleft.TabIndex = 5;
this.radleft.Text = "좌측";
this.radleft.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radleft.UseVisualStyleBackColor = false;
//
// groupBox2 // groupBox2
// //
this.groupBox2.Controls.Add(this.arLabel1); this.groupBox2.Controls.Add(this.arLabel1);
@@ -610,208 +838,6 @@
this.panel12.Size = new System.Drawing.Size(15, 66); this.panel12.Size = new System.Drawing.Size(15, 66);
this.panel12.TabIndex = 14; this.panel12.TabIndex = 14;
// //
// panel6
//
this.panel6.Dock = System.Windows.Forms.DockStyle.Left;
this.panel6.Location = new System.Drawing.Point(129, 19);
this.panel6.Name = "panel6";
this.panel6.Size = new System.Drawing.Size(15, 66);
this.panel6.TabIndex = 12;
//
// label1
//
this.label1.BackColor = System.Drawing.Color.Blue;
this.label1.Dock = System.Windows.Forms.DockStyle.Bottom;
this.label1.Font = new System.Drawing.Font("맑은 고딕", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.label1.ForeColor = System.Drawing.Color.White;
this.label1.Location = new System.Drawing.Point(607, 577);
this.label1.Name = "label1";
this.label1.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
this.label1.Size = new System.Drawing.Size(404, 38);
this.label1.TabIndex = 9;
this.label1.Text = "----------";
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// radpbs2
//
this.radpbs2.BackColor = System.Drawing.Color.WhiteSmoke;
this.radpbs2.Bordercolor = System.Drawing.Color.DimGray;
this.radpbs2.BorderRadius = 7;
this.radpbs2.BorderSize = 2;
this.radpbs2.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radpbs2.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radpbs2.CheckWidth = 30;
this.radpbs2.Dock = System.Windows.Forms.DockStyle.Left;
this.radpbs2.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radpbs2.Location = new System.Drawing.Point(278, 19);
this.radpbs2.Name = "radpbs2";
this.radpbs2.Size = new System.Drawing.Size(119, 66);
this.radpbs2.TabIndex = 10;
this.radpbs2.Text = "On(2)";
this.radpbs2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radpbs2.UseVisualStyleBackColor = false;
//
// radpbs1
//
this.radpbs1.BackColor = System.Drawing.Color.WhiteSmoke;
this.radpbs1.Bordercolor = System.Drawing.Color.DimGray;
this.radpbs1.BorderRadius = 7;
this.radpbs1.BorderSize = 2;
this.radpbs1.Checked = true;
this.radpbs1.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radpbs1.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radpbs1.CheckWidth = 30;
this.radpbs1.Dock = System.Windows.Forms.DockStyle.Left;
this.radpbs1.Font = new System.Drawing.Font("맑은 고딕", 16F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radpbs1.ForeColor = System.Drawing.Color.Blue;
this.radpbs1.Location = new System.Drawing.Point(144, 19);
this.radpbs1.Name = "radpbs1";
this.radpbs1.Size = new System.Drawing.Size(119, 66);
this.radpbs1.TabIndex = 9;
this.radpbs1.TabStop = true;
this.radpbs1.Text = "On(1)";
this.radpbs1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radpbs1.UseVisualStyleBackColor = false;
//
// radpbs0
//
this.radpbs0.BackColor = System.Drawing.Color.WhiteSmoke;
this.radpbs0.Bordercolor = System.Drawing.Color.DimGray;
this.radpbs0.BorderRadius = 7;
this.radpbs0.BorderSize = 2;
this.radpbs0.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radpbs0.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radpbs0.CheckWidth = 30;
this.radpbs0.Dock = System.Windows.Forms.DockStyle.Left;
this.radpbs0.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radpbs0.Location = new System.Drawing.Point(10, 19);
this.radpbs0.Name = "radpbs0";
this.radpbs0.Size = new System.Drawing.Size(119, 66);
this.radpbs0.TabIndex = 8;
this.radpbs0.Text = "Off(0)";
this.radpbs0.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radpbs0.UseVisualStyleBackColor = false;
//
// radspdh
//
this.radspdh.BackColor = System.Drawing.Color.WhiteSmoke;
this.radspdh.Bordercolor = System.Drawing.Color.DimGray;
this.radspdh.BorderRadius = 7;
this.radspdh.BorderSize = 2;
this.radspdh.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radspdh.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radspdh.CheckWidth = 30;
this.radspdh.Dock = System.Windows.Forms.DockStyle.Left;
this.radspdh.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radspdh.Location = new System.Drawing.Point(278, 19);
this.radspdh.Name = "radspdh";
this.radspdh.Size = new System.Drawing.Size(119, 66);
this.radspdh.TabIndex = 2;
this.radspdh.Text = "고속";
this.radspdh.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radspdh.UseVisualStyleBackColor = false;
//
// radspdm
//
this.radspdm.BackColor = System.Drawing.Color.WhiteSmoke;
this.radspdm.Bordercolor = System.Drawing.Color.DimGray;
this.radspdm.BorderRadius = 7;
this.radspdm.BorderSize = 2;
this.radspdm.Checked = true;
this.radspdm.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radspdm.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radspdm.CheckWidth = 30;
this.radspdm.Dock = System.Windows.Forms.DockStyle.Left;
this.radspdm.Font = new System.Drawing.Font("맑은 고딕", 16F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radspdm.ForeColor = System.Drawing.Color.Blue;
this.radspdm.Location = new System.Drawing.Point(144, 19);
this.radspdm.Name = "radspdm";
this.radspdm.Size = new System.Drawing.Size(119, 66);
this.radspdm.TabIndex = 1;
this.radspdm.TabStop = true;
this.radspdm.Text = "중속";
this.radspdm.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radspdm.UseVisualStyleBackColor = false;
//
// radspdl
//
this.radspdl.BackColor = System.Drawing.Color.WhiteSmoke;
this.radspdl.Bordercolor = System.Drawing.Color.DimGray;
this.radspdl.BorderRadius = 7;
this.radspdl.BorderSize = 2;
this.radspdl.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radspdl.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radspdl.CheckWidth = 30;
this.radspdl.Dock = System.Windows.Forms.DockStyle.Left;
this.radspdl.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radspdl.Location = new System.Drawing.Point(10, 19);
this.radspdl.Name = "radspdl";
this.radspdl.Size = new System.Drawing.Size(119, 66);
this.radspdl.TabIndex = 0;
this.radspdl.Text = "저속";
this.radspdl.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radspdl.UseVisualStyleBackColor = false;
//
// radright
//
this.radright.BackColor = System.Drawing.Color.WhiteSmoke;
this.radright.Bordercolor = System.Drawing.Color.DimGray;
this.radright.BorderRadius = 7;
this.radright.BorderSize = 2;
this.radright.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radright.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radright.CheckWidth = 30;
this.radright.Dock = System.Windows.Forms.DockStyle.Left;
this.radright.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radright.Location = new System.Drawing.Point(278, 19);
this.radright.Name = "radright";
this.radright.Size = new System.Drawing.Size(119, 66);
this.radright.TabIndex = 4;
this.radright.Text = "우측";
this.radright.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radright.UseVisualStyleBackColor = false;
//
// radstrai
//
this.radstrai.BackColor = System.Drawing.Color.WhiteSmoke;
this.radstrai.Bordercolor = System.Drawing.Color.DimGray;
this.radstrai.BorderRadius = 7;
this.radstrai.BorderSize = 2;
this.radstrai.Checked = true;
this.radstrai.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radstrai.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radstrai.CheckWidth = 30;
this.radstrai.Dock = System.Windows.Forms.DockStyle.Left;
this.radstrai.Font = new System.Drawing.Font("맑은 고딕", 16F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radstrai.ForeColor = System.Drawing.Color.Blue;
this.radstrai.Location = new System.Drawing.Point(144, 19);
this.radstrai.Name = "radstrai";
this.radstrai.Size = new System.Drawing.Size(119, 66);
this.radstrai.TabIndex = 3;
this.radstrai.TabStop = true;
this.radstrai.Text = "직진";
this.radstrai.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radstrai.UseVisualStyleBackColor = false;
//
// radleft
//
this.radleft.BackColor = System.Drawing.Color.WhiteSmoke;
this.radleft.Bordercolor = System.Drawing.Color.DimGray;
this.radleft.BorderRadius = 7;
this.radleft.BorderSize = 2;
this.radleft.CheckOffColor = System.Drawing.Color.FromArgb(((int)(((byte)(64)))), ((int)(((byte)(64)))), ((int)(((byte)(64)))));
this.radleft.CheckOnColor = System.Drawing.Color.LimeGreen;
this.radleft.CheckWidth = 30;
this.radleft.Dock = System.Windows.Forms.DockStyle.Left;
this.radleft.Font = new System.Drawing.Font("맑은 고딕", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.radleft.Location = new System.Drawing.Point(10, 19);
this.radleft.Name = "radleft";
this.radleft.Size = new System.Drawing.Size(119, 66);
this.radleft.TabIndex = 5;
this.radleft.Text = "좌측";
this.radleft.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radleft.UseVisualStyleBackColor = false;
//
// radbackward // radbackward
// //
this.radbackward.BackColor = System.Drawing.Color.WhiteSmoke; this.radbackward.BackColor = System.Drawing.Color.WhiteSmoke;
@@ -831,6 +857,14 @@
this.radbackward.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.radbackward.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radbackward.UseVisualStyleBackColor = false; this.radbackward.UseVisualStyleBackColor = false;
// //
// panel6
//
this.panel6.Dock = System.Windows.Forms.DockStyle.Left;
this.panel6.Location = new System.Drawing.Point(129, 19);
this.panel6.Name = "panel6";
this.panel6.Size = new System.Drawing.Size(15, 66);
this.panel6.TabIndex = 12;
//
// radforward // radforward
// //
this.radforward.BackColor = System.Drawing.Color.WhiteSmoke; this.radforward.BackColor = System.Drawing.Color.WhiteSmoke;
@@ -853,6 +887,20 @@
this.radforward.TextAlign = System.Drawing.ContentAlignment.MiddleCenter; this.radforward.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.radforward.UseVisualStyleBackColor = false; this.radforward.UseVisualStyleBackColor = false;
// //
// label1
//
this.label1.BackColor = System.Drawing.Color.Blue;
this.label1.Dock = System.Windows.Forms.DockStyle.Bottom;
this.label1.Font = new System.Drawing.Font("맑은 고딕", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129)));
this.label1.ForeColor = System.Drawing.Color.White;
this.label1.Location = new System.Drawing.Point(607, 577);
this.label1.Name = "label1";
this.label1.Padding = new System.Windows.Forms.Padding(0, 3, 0, 3);
this.label1.Size = new System.Drawing.Size(404, 38);
this.label1.TabIndex = 9;
this.label1.Text = "----------";
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// guideSensor1 // guideSensor1
// //
this.guideSensor1.Dock = System.Windows.Forms.DockStyle.Top; this.guideSensor1.Dock = System.Windows.Forms.DockStyle.Top;
@@ -865,54 +913,6 @@
this.guideSensor1.TabIndex = 8; this.guideSensor1.TabIndex = 8;
this.guideSensor1.Text = "guideSensor1"; this.guideSensor1.Text = "guideSensor1";
// //
// btBack180
//
this.btBack180.BackColor = System.Drawing.Color.WhiteSmoke;
this.btBack180.Cursor = System.Windows.Forms.Cursors.Hand;
this.btBack180.Dock = System.Windows.Forms.DockStyle.Fill;
this.btBack180.Font = new System.Drawing.Font("맑은 고딕", 10F, System.Drawing.FontStyle.Bold);
this.btBack180.ForeColor = System.Drawing.Color.Black;
this.btBack180.Location = new System.Drawing.Point(205, 3);
this.btBack180.Name = "btBack180";
this.btBack180.Size = new System.Drawing.Size(196, 53);
this.btBack180.TabIndex = 15;
this.btBack180.Text = "백후 180도 회전 (Left)";
this.btBack180.UseVisualStyleBackColor = false;
this.btBack180.Click += new System.EventHandler(this.btBack180_Click);
//
// tableLayoutPanel2
//
this.tableLayoutPanel2.ColumnCount = 2;
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.Controls.Add(this.btBack180, 1, 0);
this.tableLayoutPanel2.Controls.Add(this.btLeft180, 0, 0);
this.tableLayoutPanel2.Controls.Add(this.btRight180, 0, 1);
this.tableLayoutPanel2.Controls.Add(this.button2, 1, 1);
this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel2.Location = new System.Drawing.Point(0, 438);
this.tableLayoutPanel2.Name = "tableLayoutPanel2";
this.tableLayoutPanel2.RowCount = 2;
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel2.Size = new System.Drawing.Size(404, 118);
this.tableLayoutPanel2.TabIndex = 12;
//
// button2
//
this.button2.BackColor = System.Drawing.Color.WhiteSmoke;
this.button2.Cursor = System.Windows.Forms.Cursors.Hand;
this.button2.Dock = System.Windows.Forms.DockStyle.Fill;
this.button2.Font = new System.Drawing.Font("맑은 고딕", 10F, System.Drawing.FontStyle.Bold);
this.button2.ForeColor = System.Drawing.Color.Black;
this.button2.Location = new System.Drawing.Point(205, 62);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(196, 53);
this.button2.TabIndex = 15;
this.button2.Text = "백후 180도 회전(Right)";
this.button2.UseVisualStyleBackColor = false;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// fManual // fManual
// //
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
@@ -930,11 +930,11 @@
this.VisibleChanged += new System.EventHandler(this.fManual_VisibleChanged); this.VisibleChanged += new System.EventHandler(this.fManual_VisibleChanged);
this.tableLayoutPanel1.ResumeLayout(false); this.tableLayoutPanel1.ResumeLayout(false);
this.panel2.ResumeLayout(false); this.panel2.ResumeLayout(false);
this.tableLayoutPanel2.ResumeLayout(false);
this.groupBox1.ResumeLayout(false); this.groupBox1.ResumeLayout(false);
this.grpSpeed.ResumeLayout(false); this.grpSpeed.ResumeLayout(false);
this.grpBunki.ResumeLayout(false); this.grpBunki.ResumeLayout(false);
this.groupBox2.ResumeLayout(false); this.groupBox2.ResumeLayout(false);
this.tableLayoutPanel2.ResumeLayout(false);
this.ResumeLayout(false); this.ResumeLayout(false);
} }

View File

@@ -79,8 +79,9 @@ namespace Project.ViewForm
} }
if (PUB.CheckManualChargeMode() == false) return; if (PUB.CheckManualChargeMode() == false) return;
arDev.Narumi.Speed spd = arDev.Narumi.Speed.Low; arDev.Narumi.Speed spd = arDev.Narumi.Speed.Low;
if (radspdh.Checked) spd = arDev.Narumi.Speed.High; if (radspdh.Checked) spd = arDev.Narumi.Speed.High;
else if (radspdl.Checked) spd = arDev.Narumi.Speed.Mid; else if (radspdm.Checked) spd = arDev.Narumi.Speed.Mid;
arDev.Narumi.Sensor ss = arDev.Narumi.Sensor.PBSOff; arDev.Narumi.Sensor ss = arDev.Narumi.Sensor.PBSOff;
if (radpbs0.Checked) ss = arDev.Narumi.Sensor.PBSOn; if (radpbs0.Checked) ss = arDev.Narumi.Sensor.PBSOn;
PUB.AGV.AGVMoveManual(arDev.Narumi.ManulOpt.BS, spd, ss); PUB.AGV.AGVMoveManual(arDev.Narumi.ManulOpt.BS, spd, ss);
@@ -109,7 +110,7 @@ namespace Project.ViewForm
if (PUB.CheckManualChargeMode() == false) return; if (PUB.CheckManualChargeMode() == false) return;
arDev.Narumi.Speed spd = arDev.Narumi.Speed.Low; arDev.Narumi.Speed spd = arDev.Narumi.Speed.Low;
if (radspdh.Checked) spd = arDev.Narumi.Speed.High; if (radspdh.Checked) spd = arDev.Narumi.Speed.High;
else if (radspdl.Checked) spd = arDev.Narumi.Speed.Mid; else if (radspdm.Checked) spd = arDev.Narumi.Speed.Mid;
arDev.Narumi.Sensor ss = arDev.Narumi.Sensor.PBSOff; arDev.Narumi.Sensor ss = arDev.Narumi.Sensor.PBSOff;
if (radpbs0.Checked) ss = arDev.Narumi.Sensor.PBSOn; if (radpbs0.Checked) ss = arDev.Narumi.Sensor.PBSOn;
PUB.AGV.AGVMoveManual(arDev.Narumi.ManulOpt.FS, spd, ss); PUB.AGV.AGVMoveManual(arDev.Narumi.ManulOpt.FS, spd, ss);
@@ -200,7 +201,7 @@ namespace Project.ViewForm
if (dlg != DialogResult.Yes) return; if (dlg != DialogResult.Yes) return;
var opt = makeopt(); var opt = makeopt();
PUB.AGV.AGVMoveSet(opt); PUB.AGV.AGVMoveSet(opt);
PUB.AGV.AGVMoveRun(); PUB.AGV.AGVMoveRun(opt.Direction == arDev.Narumi.eMoveDir.Forward ? arDev.Narumi.eRunOpt.Forward : arDev.Narumi.eRunOpt.Backward);
} }
else else
{ {
@@ -234,8 +235,8 @@ namespace Project.ViewForm
//마크정보 //마크정보
guideSensor1.SensorValue = PUB.AGV.data.guidesensor; guideSensor1.SensorValue = PUB.AGV.data.guidesensor;
guideSensor1.LMark = PUB.AGV.signal.mark_sensor_1; guideSensor1.LMark = PUB.AGV.signal1.mark_sensor_1;
guideSensor1.RMark = PUB.AGV.signal.mark_sensor_2; guideSensor1.RMark = PUB.AGV.signal1.mark_sensor_2;
guideSensor1.Invalidate(); guideSensor1.Invalidate();
if (PUB.AGV.system1.agv_run || PUB.AGV.system1.agv_run_manual) if (PUB.AGV.system1.agv_run || PUB.AGV.system1.agv_run_manual)
@@ -392,12 +393,12 @@ namespace Project.ViewForm
private void btBack180_Click(object sender, EventArgs e) private void btBack180_Click(object sender, EventArgs e)
{ {
//[STX] C T B 0 0 0 0 9 9 [ETX] //[STX] C T B 0 0 0 0 9 9 [ETX]
PUB.AGV.AGVMoveBack180Turn(true); PUB.AGV.LiftControl(arDev.Narumi.LiftCommand.ON);// (;// (true);
} }
private void button2_Click(object sender, EventArgs e) private void button2_Click(object sender, EventArgs e)
{ {
PUB.AGV.AGVMoveBack180Turn(false); PUB.AGV.LiftControl(arDev.Narumi.LiftCommand.OFF);
} }
} }
} }

View File

@@ -109,6 +109,7 @@ namespace Project
this.lbIDLE = new arCtl.arLabel(); this.lbIDLE = new arCtl.arLabel();
this.lbStStep = new arCtl.arLabel(); this.lbStStep = new arCtl.arLabel();
this.panTopMenu = new System.Windows.Forms.Panel(); this.panTopMenu = new System.Windows.Forms.Panel();
this.lbBat = new AGVControl.BatteryLevelGauge();
this.pictureBox1 = new System.Windows.Forms.PictureBox(); this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.cmDebug = new System.Windows.Forms.ContextMenuStrip(this.components); this.cmDebug = new System.Windows.Forms.ContextMenuStrip(this.components);
this.mapFileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.mapFileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
@@ -121,12 +122,12 @@ namespace Project
this.debugtestToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.debugtestToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.pandBottomDIO = new System.Windows.Forms.Panel(); this.pandBottomDIO = new System.Windows.Forms.Panel();
this.panel9 = new System.Windows.Forms.Panel(); this.panel9 = new System.Windows.Forms.Panel();
this.IOState = new arFrame.Control.GridView();
this.SSInfo = new arFrame.Control.GridView();
this.panDlg = new System.Windows.Forms.Panel(); this.panDlg = new System.Windows.Forms.Panel();
this.arPanel2 = new arCtl.arPanel(); this.arPanel2 = new arCtl.arPanel();
this.arPanel1 = new arCtl.arPanel(); this.arPanel1 = new arCtl.arPanel();
this.IOState = new arFrame.Control.GridView(); this.xbeeSettingToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.SSInfo = new arFrame.Control.GridView();
this.lbBat = new AGVControl.BatteryLevelGauge();
this.panRight.SuspendLayout(); this.panRight.SuspendLayout();
this.tableLayoutPanel1.SuspendLayout(); this.tableLayoutPanel1.SuspendLayout();
this.panel4.SuspendLayout(); this.panel4.SuspendLayout();
@@ -1622,6 +1623,26 @@ namespace Project
this.panTopMenu.Size = new System.Drawing.Size(1278, 50); this.panTopMenu.Size = new System.Drawing.Size(1278, 50);
this.panTopMenu.TabIndex = 134; this.panTopMenu.TabIndex = 134;
// //
// lbBat
//
this.lbBat.BorderColor = System.Drawing.Color.DimGray;
this.lbBat.CurA = 0F;
this.lbBat.Dock = System.Windows.Forms.DockStyle.Right;
this.lbBat.Font = new System.Drawing.Font("Microsoft Sans Serif", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.lbBat.ForeColor = System.Drawing.Color.Gray;
this.lbBat.IsOpen = true;
this.lbBat.Location = new System.Drawing.Point(830, 0);
this.lbBat.MaxA = 0F;
this.lbBat.Name = "lbBat";
this.lbBat.Padding = new System.Windows.Forms.Padding(0, 12, 0, 12);
this.lbBat.sign = "%";
this.lbBat.Size = new System.Drawing.Size(48, 50);
this.lbBat.TabIndex = 23;
this.lbBat.Text = "12";
this.lbBat.VLevel = 50F;
this.lbBat.Volt = 0F;
this.lbBat.Click += new System.EventHandler(this.lbBat_Click);
//
// pictureBox1 // pictureBox1
// //
this.pictureBox1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40))))); this.pictureBox1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(40)))), ((int)(((byte)(40)))), ((int)(((byte)(40)))));
@@ -1652,9 +1673,10 @@ namespace Project
this.ToolStripMenuItem, this.ToolStripMenuItem,
this.demoListLotToolStripMenuItem, this.demoListLotToolStripMenuItem,
this.toolStripMenuItem5, this.toolStripMenuItem5,
this.refreshListToolStripMenuItem}); this.refreshListToolStripMenuItem,
this.xbeeSettingToolStripMenuItem});
this.cmDebug.Name = "cmVision"; this.cmDebug.Name = "cmVision";
this.cmDebug.Size = new System.Drawing.Size(229, 324); this.cmDebug.Size = new System.Drawing.Size(229, 368);
// //
// mapFileToolStripMenuItem // mapFileToolStripMenuItem
// //
@@ -1732,70 +1754,6 @@ namespace Project
this.panel9.Size = new System.Drawing.Size(1278, 35); this.panel9.Size = new System.Drawing.Size(1278, 35);
this.panel9.TabIndex = 0; this.panel9.TabIndex = 0;
// //
// panDlg
//
this.panDlg.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(64)))));
this.panDlg.Dock = System.Windows.Forms.DockStyle.Fill;
this.panDlg.Location = new System.Drawing.Point(1, 58);
this.panDlg.Margin = new System.Windows.Forms.Padding(0);
this.panDlg.Name = "panDlg";
this.panDlg.Size = new System.Drawing.Size(1014, 706);
this.panDlg.TabIndex = 146;
//
// arPanel2
//
this.arPanel2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(5)))), ((int)(((byte)(5)))), ((int)(((byte)(5)))));
this.arPanel2.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20)))));
this.arPanel2.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(25)))), ((int)(((byte)(25)))));
this.arPanel2.BorderSize = new System.Windows.Forms.Padding(0, 0, 0, 5);
this.arPanel2.Dock = System.Windows.Forms.DockStyle.Top;
this.arPanel2.Font = new System.Drawing.Font("Consolas", 10F, System.Drawing.FontStyle.Italic);
this.arPanel2.ForeColor = System.Drawing.Color.Khaki;
this.arPanel2.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
this.arPanel2.GradientRepeatBG = false;
this.arPanel2.Location = new System.Drawing.Point(1, 55);
this.arPanel2.Name = "arPanel2";
this.arPanel2.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arPanel2.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arPanel2.ProgressMax = 100F;
this.arPanel2.ProgressMin = 0F;
this.arPanel2.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arPanel2.ProgressValue = 0F;
this.arPanel2.ShadowColor = System.Drawing.Color.Black;
this.arPanel2.ShowBorder = true;
this.arPanel2.Size = new System.Drawing.Size(1278, 3);
this.arPanel2.TabIndex = 145;
this.arPanel2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.arPanel2.TextShadow = false;
this.arPanel2.UseProgressBar = false;
//
// arPanel1
//
this.arPanel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(5)))), ((int)(((byte)(5)))), ((int)(((byte)(5)))));
this.arPanel1.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20)))));
this.arPanel1.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(25)))), ((int)(((byte)(25)))));
this.arPanel1.BorderSize = new System.Windows.Forms.Padding(0, 0, 0, 5);
this.arPanel1.Dock = System.Windows.Forms.DockStyle.Top;
this.arPanel1.Font = new System.Drawing.Font("Consolas", 10F, System.Drawing.FontStyle.Italic);
this.arPanel1.ForeColor = System.Drawing.Color.Khaki;
this.arPanel1.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
this.arPanel1.GradientRepeatBG = false;
this.arPanel1.Location = new System.Drawing.Point(1, 51);
this.arPanel1.Name = "arPanel1";
this.arPanel1.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arPanel1.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arPanel1.ProgressMax = 100F;
this.arPanel1.ProgressMin = 0F;
this.arPanel1.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arPanel1.ProgressValue = 0F;
this.arPanel1.ShadowColor = System.Drawing.Color.Black;
this.arPanel1.ShowBorder = true;
this.arPanel1.Size = new System.Drawing.Size(1278, 4);
this.arPanel1.TabIndex = 135;
this.arPanel1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.arPanel1.TextShadow = false;
this.arPanel1.UseProgressBar = false;
//
// IOState // IOState
// //
this.IOState.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(50)))), ((int)(((byte)(50)))), ((int)(((byte)(50))))); this.IOState.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(50)))), ((int)(((byte)(50)))), ((int)(((byte)(50)))));
@@ -1948,25 +1906,76 @@ namespace Project
((ushort)(0))}; ((ushort)(0))};
this.SSInfo.Click += new System.EventHandler(this.SSInfo_Click); this.SSInfo.Click += new System.EventHandler(this.SSInfo_Click);
// //
// lbBat // panDlg
// //
this.lbBat.BorderColor = System.Drawing.Color.DimGray; this.panDlg.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(64)))));
this.lbBat.CurA = 0F; this.panDlg.Dock = System.Windows.Forms.DockStyle.Fill;
this.lbBat.Dock = System.Windows.Forms.DockStyle.Right; this.panDlg.Location = new System.Drawing.Point(1, 58);
this.lbBat.Font = new System.Drawing.Font("Microsoft Sans Serif", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.panDlg.Margin = new System.Windows.Forms.Padding(0);
this.lbBat.ForeColor = System.Drawing.Color.Gray; this.panDlg.Name = "panDlg";
this.lbBat.IsOpen = true; this.panDlg.Size = new System.Drawing.Size(1014, 706);
this.lbBat.Location = new System.Drawing.Point(830, 0); this.panDlg.TabIndex = 146;
this.lbBat.MaxA = 0F; //
this.lbBat.Name = "lbBat"; // arPanel2
this.lbBat.Padding = new System.Windows.Forms.Padding(0, 12, 0, 12); //
this.lbBat.sign = "%"; this.arPanel2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(5)))), ((int)(((byte)(5)))), ((int)(((byte)(5)))));
this.lbBat.Size = new System.Drawing.Size(48, 50); this.arPanel2.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20)))));
this.lbBat.TabIndex = 23; this.arPanel2.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(25)))), ((int)(((byte)(25)))));
this.lbBat.Text = "12"; this.arPanel2.BorderSize = new System.Windows.Forms.Padding(0, 0, 0, 5);
this.lbBat.VLevel = 50F; this.arPanel2.Dock = System.Windows.Forms.DockStyle.Top;
this.lbBat.Volt = 0F; this.arPanel2.Font = new System.Drawing.Font("Consolas", 10F, System.Drawing.FontStyle.Italic);
this.lbBat.Click += new System.EventHandler(this.lbBat_Click); this.arPanel2.ForeColor = System.Drawing.Color.Khaki;
this.arPanel2.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
this.arPanel2.GradientRepeatBG = false;
this.arPanel2.Location = new System.Drawing.Point(1, 55);
this.arPanel2.Name = "arPanel2";
this.arPanel2.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arPanel2.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arPanel2.ProgressMax = 100F;
this.arPanel2.ProgressMin = 0F;
this.arPanel2.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arPanel2.ProgressValue = 0F;
this.arPanel2.ShadowColor = System.Drawing.Color.Black;
this.arPanel2.ShowBorder = true;
this.arPanel2.Size = new System.Drawing.Size(1278, 3);
this.arPanel2.TabIndex = 145;
this.arPanel2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.arPanel2.TextShadow = false;
this.arPanel2.UseProgressBar = false;
//
// arPanel1
//
this.arPanel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(5)))), ((int)(((byte)(5)))), ((int)(((byte)(5)))));
this.arPanel1.BackColor2 = System.Drawing.Color.FromArgb(((int)(((byte)(20)))), ((int)(((byte)(20)))), ((int)(((byte)(20)))));
this.arPanel1.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(25)))), ((int)(((byte)(25)))));
this.arPanel1.BorderSize = new System.Windows.Forms.Padding(0, 0, 0, 5);
this.arPanel1.Dock = System.Windows.Forms.DockStyle.Top;
this.arPanel1.Font = new System.Drawing.Font("Consolas", 10F, System.Drawing.FontStyle.Italic);
this.arPanel1.ForeColor = System.Drawing.Color.Khaki;
this.arPanel1.GradientMode = System.Drawing.Drawing2D.LinearGradientMode.Vertical;
this.arPanel1.GradientRepeatBG = false;
this.arPanel1.Location = new System.Drawing.Point(1, 51);
this.arPanel1.Name = "arPanel1";
this.arPanel1.ProgressColor1 = System.Drawing.Color.LightSkyBlue;
this.arPanel1.ProgressColor2 = System.Drawing.Color.DeepSkyBlue;
this.arPanel1.ProgressMax = 100F;
this.arPanel1.ProgressMin = 0F;
this.arPanel1.ProgressPadding = new System.Windows.Forms.Padding(0);
this.arPanel1.ProgressValue = 0F;
this.arPanel1.ShadowColor = System.Drawing.Color.Black;
this.arPanel1.ShowBorder = true;
this.arPanel1.Size = new System.Drawing.Size(1278, 4);
this.arPanel1.TabIndex = 135;
this.arPanel1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
this.arPanel1.TextShadow = false;
this.arPanel1.UseProgressBar = false;
//
// xbeeSettingToolStripMenuItem
//
this.xbeeSettingToolStripMenuItem.Name = "xbeeSettingToolStripMenuItem";
this.xbeeSettingToolStripMenuItem.Size = new System.Drawing.Size(228, 22);
this.xbeeSettingToolStripMenuItem.Text = "xbee setting";
this.xbeeSettingToolStripMenuItem.Click += new System.EventHandler(this.xbeeSettingToolStripMenuItem_Click);
// //
// fMain // fMain
// //
@@ -2089,6 +2098,7 @@ namespace Project
private ToolStripMenuItem saveToolStripMenuItem; private ToolStripMenuItem saveToolStripMenuItem;
private ToolStripMenuItem loadToolStripMenuItem; private ToolStripMenuItem loadToolStripMenuItem;
private ToolStripMenuItem editorToolStripMenuItem; private ToolStripMenuItem editorToolStripMenuItem;
private ToolStripMenuItem xbeeSettingToolStripMenuItem;
} }
} }

View File

@@ -33,7 +33,6 @@ namespace Project
bool remoteClose = false; bool remoteClose = false;
bool forceClose = false; bool forceClose = false;
readonly usbdetect.DriveDetector usbdet;
public fMain() public fMain()
{ {
InitializeComponent(); InitializeComponent();
@@ -57,10 +56,6 @@ namespace Project
if (DateTime.Now > PUB.LastInputTime) PUB.LastInputTime = DateTime.Now; if (DateTime.Now > PUB.LastInputTime) PUB.LastInputTime = DateTime.Now;
}; };
usbdet = new usbdetect.DriveDetector(this);
usbdet.DeviceArrived += Usbdet_DeviceArrived;
usbdet.DeviceRemoved += Usbdet_DeviceRemoved;
PUB._mapCanvas = new AGVNavigationCore.Controls.UnifiedAGVCanvas(); PUB._mapCanvas = new AGVNavigationCore.Controls.UnifiedAGVCanvas();
PUB._mapCanvas.Dock = DockStyle.Fill; PUB._mapCanvas.Dock = DockStyle.Fill;
@@ -68,8 +63,6 @@ namespace Project
PUB._mapCanvas.BackColor = Color.FromArgb(32, 32, 32); PUB._mapCanvas.BackColor = Color.FromArgb(32, 32, 32);
PUB._mapCanvas.ForeColor = Color.White; PUB._mapCanvas.ForeColor = Color.White;
this.panTopMenu.MouseMove += LbTitle_MouseMove; this.panTopMenu.MouseMove += LbTitle_MouseMove;
this.panTopMenu.MouseUp += LbTitle_MouseUp; this.panTopMenu.MouseUp += LbTitle_MouseUp;
this.panTopMenu.MouseDown += LbTitle_MouseDown; this.panTopMenu.MouseDown += LbTitle_MouseDown;
@@ -82,32 +75,6 @@ namespace Project
} }
protected override void WndProc(ref Message m)
{
base.WndProc(ref m);
if (usbdet != null)
{
usbdet.WndProc(ref m);
}
}
private void Usbdet_DeviceRemoved(object sender, usbdetect.DriveDetectorEventArgs e)
{
//throw new NotImplementedException();
Console.WriteLine(e.Drive);
}
private void Usbdet_DeviceArrived(object sender, usbdetect.DriveDetectorEventArgs e)
{
//throw new NotImplementedException();
using (var fUpdate = new Dialog.fUpdateForm(e.Drive))
if (fUpdate.ShowDialog() == DialogResult.Yes)
{
//종료한다
remoteClose = true;
this.Close();
}
}
private void __Closing(object sender, FormClosingEventArgs e) private void __Closing(object sender, FormClosingEventArgs e)
{ {
@@ -182,6 +149,9 @@ namespace Project
VAR.STR[eVarString.SWVersion] = Application.ProductVersion; VAR.STR[eVarString.SWVersion] = Application.ProductVersion;
AutoLoadMapData();
//SETTING H/W //SETTING H/W
this.IOState.ItemClick += gridView2_ItemClick; this.IOState.ItemClick += gridView2_ItemClick;
VAR.BOOL.PropertyChanged += BOOL_PropertyChanged; VAR.BOOL.PropertyChanged += BOOL_PropertyChanged;
@@ -290,6 +260,73 @@ namespace Project
PUB.AddEEDB("프로그램 시작"); PUB.AddEEDB("프로그램 시작");
} }
void AutoLoadMapData()
{
//auto load
var mapPath = new System.IO.DirectoryInfo("route");
if (mapPath.Exists == false) mapPath.Create();
//맵파일로딩
var basefile = System.IO.Path.Combine(mapPath.FullName, "default.json");
if (System.IO.File.Exists(basefile) == false)
if (PUB.setting.LastMapFile.isEmpty() == false) basefile = PUB.setting.LastMapFile;
System.IO.FileInfo filePath = new System.IO.FileInfo(basefile);
if (filePath.Exists == false) //그래도없다면 맵폴더에서 파일을 찾아본다.
{
var files = mapPath.GetFiles("*.json");
if (files.Any()) filePath = files[0];
}
if (filePath.Exists)
{
var result = MapLoader.LoadMapFromFile(filePath.FullName);
if (result.Success)
{
PUB._mapCanvas.SetMapLoadResult(result);
PUB._mapCanvas.MapFileName = filePath.FullName;
// 🔥 가상 AGV 초기화 (첫 노드 위치에 생성)
if (PUB._virtualAGV == null && PUB._mapCanvas.Nodes.Count > 0)
{
var startNode = PUB._mapCanvas.Nodes.FirstOrDefault(n => n.IsNavigationNode());
if (startNode != null)
{
PUB._virtualAGV = new VirtualAGV(PUB.setting.MCID, startNode.Position, AgvDirection.Forward);
PUB._virtualAGV.LowBatteryThreshold = PUB.setting.BatteryLimit_Low;
PUB._virtualAGV.SetPosition(startNode, AgvDirection.Forward);
// 캔버스에 AGV 리스트 설정
var agvList = new System.Collections.Generic.List<AGVNavigationCore.Controls.IAGV> { PUB._virtualAGV };
PUB._mapCanvas.AGVList = agvList;
PUB.log.Add($"가상 AGV 생성: {startNode.Id} 위치");
}
}
else if (PUB._virtualAGV != null)
{
PUB._virtualAGV.LowBatteryThreshold = PUB.setting.BatteryLimit_Low;
// 기존 AGV가 있으면 캔버스에 다시 연결
var agvList = new System.Collections.Generic.List<AGVNavigationCore.Controls.IAGV> { PUB._virtualAGV };
PUB._mapCanvas.AGVList = agvList;
}
PUB.log.Add($"맵 파일 로드 완료: {filePath.Name}, 노드 수: {result.Nodes.Count}");
}
else
{
PUB.log.Add($"맵 파일 로딩 실패: {result.ErrorMessage}");
MessageBox.Show($"맵 파일 로딩 실패: {result.ErrorMessage}", "오류",
MessageBoxButtons.OK, MessageBoxIcon.Error);
}
}
else
{
PUB.log.Add($"맵 파일을 찾을 수 없습니다: {filePath.FullName}");
}
}
#region "Mouse Form Move" #region "Mouse Form Move"
private Boolean fMove = false; private Boolean fMove = false;
@@ -745,6 +782,12 @@ namespace Project
{ {
if (VAR.BOOL[eVarBool.FLAG_CHARGEONM]) if (VAR.BOOL[eVarBool.FLAG_CHARGEONM])
{ {
if (PUB.BMS.IsValid && PUB.BMS.IsCharging)
{
UTIL.MsgE("현재 배터리에서 충전 상태가 감지되고 있어 해제할 수 없습니다");
return;
}
var dlg = UTIL.MsgQ("수동 충전을 해제 할까요?"); var dlg = UTIL.MsgQ("수동 충전을 해제 할까요?");
if (dlg != DialogResult.Yes) return; if (dlg != DialogResult.Yes) return;
VAR.BOOL[eVarBool.FLAG_CHARGEONM] = false; VAR.BOOL[eVarBool.FLAG_CHARGEONM] = false;
@@ -769,8 +812,8 @@ namespace Project
//mapsave //mapsave
using (var sd = new SaveFileDialog()) using (var sd = new SaveFileDialog())
{ {
sd.Filter = "AGV Map Files (*.agvmap)|*.agvmap|All Files (*.*)|*.*"; sd.Filter = "AGV Map Files (*.json)|*.json|All Files (*.*)|*.*";
sd.DefaultExt = "agvmap"; sd.DefaultExt = "json";
sd.FileName = PUB._mapCanvas.MapFileName; sd.FileName = PUB._mapCanvas.MapFileName;
if (sd.ShowDialog() == DialogResult.OK) if (sd.ShowDialog() == DialogResult.OK)
{ {
@@ -785,8 +828,8 @@ namespace Project
var od = new OpenFileDialog var od = new OpenFileDialog
{ {
Filter = "AGV Map Files (*.agvmap;*.json)|*.agvmap;*.json|All Files (*.*)|*.*", Filter = "AGV Map Files (*.json)|*.json|All Files (*.*)|*.*",
DefaultExt = "agvmap", DefaultExt = "json",
FileName = PUB._mapCanvas.MapFileName, FileName = PUB._mapCanvas.MapFileName,
}; };
@@ -991,5 +1034,11 @@ namespace Project
MessageBoxButtons.OK, MessageBoxIcon.Error); MessageBoxButtons.OK, MessageBoxIcon.Error);
} }
} }
private void xbeeSettingToolStripMenuItem_Click(object sender, EventArgs e)
{
var f = new Dialog.fXbeeSetting();
f.Show();
}
} }
} }

View File

@@ -126,160 +126,163 @@
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /> <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="btDebug.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="btDebug.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAA0lJREFUWEfV iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAA2xJREFUWEfV
ll+IVVUUxm/+Q0ECQUUwBzEiLKTQEPPJSHsrIqiHCHwIIiiZHiVhHtQiBPWhl9QiB5maLsZMQk9BNwyG l01IVFEUx1+fFEQQVASVRBFREYVGVKvCaldEYIsQWgQRmNgyClxkRQTZok0fRknYx1BoQaugiQKZRp0Z
21m/te+dGedVa6TpbUQpKitvrDt7Lues2TP3zNAIffBxD9/e+1vr7HP3WrtS+T8DWG30+rJDVXeq6jfA x2bbh5HtjMJIzZp+53oc38cd51Yk9Ic/955zz/mfM/e9d98b779GZ2fnDKGak4eurq7V8AnFvwtlLj5d
X0Z7Ns3PWxbU6/WHgCngOtCMtOcpG/Pz/3OMjIysa7VaK7xumo15vRSAE8Bhr+dhAYDnRORs3H5788nI /rdIJBJLKNoHX8OMUuZ9sqZh/w7t7e2z8/n8VDULEJ+sqfl7oPsGeFBNK6QAMbs6Ojou6vbLL+9VZvQy
ZvwMZ0TkUCrBPETkdeB4R1DVyyJyrjArB1XdA1wDWiU5Duz2PrMAzlvMjqCqn4jIYGFWBNAD3EoE6cbp NLK+09agH8QcIueUmuaa3sd5Rc0IWK8g4RXMO7IHlmt6BKxdlZpqmgLXaeCumgEQXAY/QVuhidifTCaX
LMu2eT8D8AXwcUcQkfeAemFWBPBBwrws3/d+BuAH++x54UXg99SZBoYSxmU5lPCz2vGHiLzQEUdHRzfH qkwArN2DTWqaLTmDI6FmAPjPQVsBF55VmQDwv4QNahrHXvgNRp5pfK3QJu7CVpUpAJ+cHYP86D3q8rzu
8/x8YfbMgoGEcVkOeD8LDNwNIWzyA4Oq+l2r1Xogr8fdaQB/JwIsxD9V9Y28l3lbDOCzvN5GlmWPA78B 7u6FOOV53q2uAvC3QJu4C1tUpgApjH84lUotUNco5B6ggWfcwVPUZUCw7E4ajkBbkWIcQu+wyhiIttRg
fbPaxMTEGmBjfF4fQnhWRI4B/fEo1oHvVfUr4FNVPQm8LCKP1mq1VYUAMy/TB/waQnjMj7Whqq/E8jqs 7ba6xsENs5aFr7BeXV4ul5uJPV/nc+i6kkZP4mtGSB7FBHzB/CHjDcbTjFXErIrH49ONiA+s1cMBdNao
qm8Bt+Pb/ARUgd4QwtN++yzRLMu2hBCeUNXXROQU8DUwISKXgFdF5IptvSWYXzsHIrI3Trbd8NvqOW1v KwgE9hMgx2sb8xrGz1B+zTsYg3UkbwlvnzTKD1iEfz151TRwntjHMMf8FuMBxkeMw7BK0+wgcJMGy26E
lNA9bc5wCOEpH29eAKcTRkuifRrv3xWq+qE3WiqtRHv/AprN5lYR2ZFnyeP3T6TXPQe8v8VsBxeRg4kF tzXMfjgQ8tkoMW00uFHLlAYJF3wCf0W5NCrrDpIu2cT+hGg1qqwdmUxmMdu+3E8SXR6/H0rbmp8tYX2p
Zdkb6fVStFNVqVarK7Mse9IaTp7xnzxnUZ72jzd63dO8vL/FtNj+a3QAPOONPBeRwAHv3xW1Wm1trg4k aYpj7LAkuLJOaVsrSe6JSi8Wi03jDt7ANlX4SWNyJ1sTx0hctdC25qdo+bWFUlNqm12wgcTtYaEwpbjQ
WTKBO+bl/bsituGQMFxsAubR4/3nRZZl+4EacC9WQPv1potJ4Ofo8a2q7vPxClDVd63pxPK5K2ofJUzL tuYnDWxTWXdwkMwieewcsNKxgS+ipbLuIFFewymfUISODYhGmcqWBtdmKwlx+BPKCSijTdi1gQ9QNJ4S
JnDRPOx2pKqfx4Z21MdtQ0Tetj6tqi/l9Xq9/iBwI2HeLYHJsbGxDXkv6wPWJYE383rFmkus/UcKAxGx u1nL2EHACQJHuGZyfK5T32XmNmGXBm6KBmM5cXcY5YV2XHwRUPQoi4ME7lOXAV+6c/G/gZECJRrozWaz
MP3ogyyQwM1Go/GI9zGo6juxN7S7bBsWON7159yIZtFoNLaralYigauWsF8/i9jif7Fu2xHtgli4pc4D 81TGAF8VHIJH1DUKebnglLO/Vl0B0JwcTG9hoMgEDbxPp9MrNT0A4o+xLu8G85Y1wKiF8q1f9F8OgstI
6/HxSj2WSGDcnv2FJgUR+RK40BHsgpG/iJQB8LDVc6M9+/GFEC8m/R1hwZK4DLBdut8x58W/ttbNMuq+ ThJTKFSkgefSsKZFoK/4j+TVqMs00IRj/Cu1COQdj7h8UmelWKiBHpmHP2hsQOMB8dfUNA00w8KHiAuI
hk4AAAAASUVORK5CYII= XyHnuVDm6naC1JKaanrmONbppEB2abJrFoHn/QK21s0ynEiLrwAAAABJRU5ErkJggg==
</value> </value>
</data> </data>
<data name="btOpenDir.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="btOpenDir.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAa9JREFUWEfl iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAb9JREFUWEft
ls8rhEEch/2IEoo/QKHcXJzEiaNyEA64cXLk5OAi/gInR04Or6IcnRy2t/b9fGbHbr0XkdoTYTlIUfbV lr8vBEEUxxchEST8ARIkOo1KqFwpUQgKdFRKKoVG+AtUSirFSkiuVCk2m9zt7e7dJtcIkVxFcK4QCYld
+/a+b3aalux+N2XquWzPNE/T7Mzb1PTvh+/77SSXSG5UYdKcV7dB8ohk8A1lAHPm3LoMkm+WBW2Ustns 3517e9ZkHGLfRuEln8zsvLf7/e7M7A/tP8rlckehUFgCG03IUHnygYsfgeALfMuy5uiUZAMXf5bEPqOa
gDm/5mFZqBolktc1ogBM/TagXjw5jtNqCyiT1CSPSTqSZDKZbjPgnuRo+Fs+n+8sFAq9kgRB0FIRAGAR y+UG6bTkQiHUjCq4/CU2ZnOK5H9sICkedF1vUxnwgQuOgc6JYRg9soFbMBaOlUqlLs/z+jgJgqD1gwGs
wDDJK8uWSfAMYCEJeHddt4PkoUWU5C4J0PFu3FgkSYpJwL7Wuic+hKYkBoDTKEAptRZet6bQAHaiAAAT yyIYQf8iGmOmBr2FyMCLaZqdaA/pOC1uIgMuzcYVHadFJTKw77puL9pwE8pFbGAJssKAbdtraDPxZErs
ANYtgigA5sOAcvi3IHlgCtJorYeigxcfwAtTEOYlugtInsRP8k8fpboAwI0uIgBbAEZMoQHsJTfhDIAV CANwMgnWpSQ70JwPDfjhY4H2IJ5MAyz7sNh4tAGL8WQKPIp3ATon9En+7kcpETD9ZnjjGjpbYFRVxMye
iyDNahSgte4nuWsRRMnlcmNRQBAEzUqpc1MQ5sP3/a40IHwYLJIkl9Hi8SEctAjSOGmAUmrWIogCYDMN MIDODAysSMk0WBUGsBEGcLArJdlxHGdcGMBGaMF74ExVxMgr9l13wwAGalIBN+dCPAys/5CigBud5DUN
ILltCtIopabTgPBFMgVpPM/r+7oDRVMQ5jFdPA54sEiSnFUEKKWWSb5aRAluPc8brwgIB8k286tVgvRL 0z+rKGAFN71J8uIp2JYLuMFNT5O8WIKsqoiTfD7fT/JiBipyATP3JF0PDNxJBdycknQ9sB7LGHySiri4
+C+NT9lLlLEeyHt7AAAAAElFTkSuQmCC xvRPkPR7INEu/7Vy0PgT/juhaW/ZS5SxdhC40QAAAABJRU5ErkJggg==
</value> </value>
</data> </data>
<data name="btMReset.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="btMReset.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAA99JREFUWEft iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAABAlJREFUWEft
V1uLHEUUHrxfHkRFhJBL16kxBoMYUUQIRkXFBy8gGC8PKl4I3laNF3TdqdP1GEFEQR9EQUSIYvIiKCJi V91vFFUU3wiC6AMBY0xIgb13ltJAjBoJMSF+BYkPIgkJH/ogxo8QP6ha1MDandn7qAkxmsiDoYkhJoUA
fDH+Ax/UB0126tSsYDTxEqPJjHw9Xb09Z3t2dpc85oOC6Tpffed09alzalqtE1gmBr51UteZy3qebhVn LyQYQwj1BfkPeFAeBLozszWh0PJR0XbX3296ZvbOfnVteewvOdmZc37nzJk7555zNzOP/4uqyTxQctWT
HhFHjwa2d3d9tmmw7YpTNf+4ITi7OeT0njD9IkyDMeNgzOlD8WaLXr9iRN++RJg+bXA2aezBWq23LGBr ZaO3Bq56L3D1+77n7C6Z7FPVvc88KLT7D991NvlF/WPg6b8g1RYyFhb1scCo58Vt7ghNbh0Cn6l7UCcy
henPmui/4uhLYXq6y3RDdO2NXU/rxZlrgjNPiqPPhOm/Gv9wcPRQ0ovT7QuWHFRk+0JNqC85fTDXaVvN RF8JMztwaRHothX0Hyz5Ofx+UvL05tDNrS8Z3Y1P8Zzvqn2w/QzbvxZ/wnf1OxIuE+Zzj3WcVOg5X1iB
04g+y8TRLrUb07PbV58pTHPQCp5u1OtGEJjuLZwOFx8StndoziQEZ+9BTqQgApOvBbRd8yvMdugiYfqn KkFR/zRSyDlibonQZLNI5KTlS8kP93Utwe8IpOIb/bLQm8P39BskivN44DnbxdQxUDOvw3dMYlQR08TX
JP4hnq7UHOA7v/G0fS+tPRcDv7UdiC67Fp+h2sWlBFBLuH5gc5u2JwS2U5MExdNaYdqtPsdYfgvJlEg4 kD6hNWK4oNeA8LcQbwVGbxBTCpfM+kVXD65aRuG1qFMI3ewLiDEhseIXap8AjHHBVXxPvSbqBqA+eoXX
TgvsbGYC05v4niGntyrB3Lz/41T7dGF6HZx5Pv3Q4HyRAHL7Tkk4JjNm3YjN2U5NYL8wHak9I/P3Vc/O MiCSXwXbKYvXlp9hMcUkbidRJwg81Y+l/J7fE1vycBKwqI5e7s0txvW35AidL/NHwklLiwSKzhEhTAX9
vDxcQ180OG8OAFVMmH4DITj6StslN280CDWOyNYVmltbJ+NUzPn1VB8HXqRztH5LfLahEnH2KW3/yWdn arWoIwSuU7ACXIPcs+5Z+VeTe1d9Oe2jzya6tDQmwC4Gww0SsHXOizoB3vI7K0BbwQ5y6VPdmVnAXTFi
TKiCafy8opIcvLk9iQQ2N6X5gb/uFLxRZPORyuRv0BPQA4Rpb20en2Mn1mDtqJdFIGzuKwX6+/2aVdW8 urUtowf00iiojcBke5IgrvOxqBP8abIPwdauC8ZyZVYt2TdqWxwExbdF1Oj9Ly7kG4WeOg6bXckXOBM4
X3VWw1sO4DxxyiAWcLC2clAcS3pcmF7rPX/h2fX5AsNKZV8VZ7fV58cG4LNNiRNc+3Jt1wGEGbsmzUe2 A3D9m6Xn5xikD30lzMxA8bwpASrXzMoVosbKrHhY9Cnhw4WSkSQaOPQVSoTQ1R9C/03588cfEVUN053K
D1QOJqFIJGfvj0w7hOlozcFeBAHnkc23tfkjSFj0AKxNOsLZzYmzWH0Zi1m/+jxhOrDgLReOWb31gDh6 OYTl3yuqCC0TwEOFgqaTe7oZx07A73dWxnqszluinhlRIbnOntDTX8F5MgmOZWcSfDg+z0VLf48FyxlA
JnHQwLS9haOhj0uvs86kt0AzanA2bryr9cWZr0vbr43JieLQIDRAMYG9aLfzpwBFJ9V4DBQlFCf87oNb XwmDFc6+EnPa9ZeWGDZdy+E8GgdpI8P1S09gS34aczjARF0Dt0b9dikXVqv4LTiMrIfMJANRUAvoDb+K
18aLFMUN9ty8XbdVGBsA0/eJE9k8gVxATYg5vZI4KMvFHNMOcEaVoW0/rrjObtb2AmMC2I2GorlAZHqs 7XrT4oShTwhpQTOhPRq3tV3AphP3eAqbEpsTryvkRkEFfBHopyJ7Uf0g6jRgbJ6Ap38XCka0+oi1wJ6A
EmU7pe0JaOWJF539RNsrqADSVh9GS9VcYEnt2JurhOmvUuvvRS809QDU5eEgLiiaPwmRzdbiPjHUOBad Vv11zGFbjnSwkSP0BCjuEwkXJytRpwFjswROcaAIJQU87IOYx8Ek6gZwlMc8FPNpUTcCBDuBeKknOFKF
uUtzRhDZXl8miuCNcI0a+RyOdqGx6HUauNAUN+P5XexHNs9pXiNCx1zcnd5wfvXM9CC2rhbIUXHm8+JE kkJH49iojYhxR2LdbXugASFJoO7wMMYDitA6Bj7FTvjekhhToat2iak50BxeIhES8I3wmxfnacExi4NF
eLMFfFxM0TvE0bPooupSeih6c+eol2WivJbvGdmNJQwkHALUeitGeVvaKUy/a2e10UMR6vnsar3+uAG9 6C3BA010Mq6tYgXJfCbm9vALam0p3/Oo3PJo9jYC3JVAlElsp1+iHYGjN/k8mHJ2IMH9nKLg2IfScXyG
Hp0QSTX8W2Yejky39Bxdir9tmn8Ck/A/N4AkP8Mw5xAAAAAASUVORK5CYII= HRJudpBj+ZAVtCNhwTFBCTN3yGlpEHLTflCdlCEDZZN9VtzuPzjrOQlZVFh2/C1T72JLvlp29RP82ya0
eXSITOY/N4AkP6QQbUkAAAAASUVORK5CYII=
</value> </value>
</data> </data>
<data name="btCapture.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="btCapture.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAkVJREFUWEft iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAkNJREFUWEft
ls+rjGEUxwcpCz8WJPnxD7j3rqRYSGRBLK4kkWyJLORPEJENdyULV8pm/Aeo2czined8zmtmMSiKxSBZ lU1LVFEYx6+F0KKXhRKR9QVSVxLoQqJoUdjCiAgl3CpKi/AjiGG0KVfRIiVoM34DC2Yzi7nz1sxiKkjQ
+32vV+d6JzNnnhnvcEfJPfWpt/M9z3O+8z7v88xTKi3EvxKVSmUZMKWqgf5RA64CS/34Pw5gGsgKMuXH xahEazVfp98znYnT47nTmRgHIg/8OM88/3PO87/n3HsmOG7/TIvH46cymcxsNptN0Ue1EJ5Bq5nWuMai
/zLK5fISERkXkT0e4FSkySBmVPW4nydn3Hp1NU/TdDvwMjLRqHihqtvmmler1RXA60jRqGk1m83lpfwV c1D2ZNZM82+xWOxkOp3ugpsaFhxTBf7EHjv10LUWdEktU/Zny+VyfUxaUYscJcsY7K0UTyQSZ0isqQHN
e9H4FsnNK9a7ZGsVEc7Zl6yqd7yWM5vvhrtG/jwbqRuI9Y4aUNUttjwictJpM8C1EMI602u12mrDni0H oFQsFk8Hsi0OUThw5BqK1A7krBzCY/pWtDdaM+ybr+GtYOJ9o3kjtZ0GyPXI8WBkVGl78DyVSl0QPQzD
XM9reprF6GsAeKyqV4B3Hbn3qroXWAVcAl51aC0RuZgkyUoR2We1kTl7GGSgB1U9EkLYBDz1WgdPkiTZ NkFiyaG9MGPsOZFEGoCP5J/Sf7NyG+Ru0Z+DJ7Bq8kIJs9PJZPIs/W1+b1haJLUMHIJxD3jKy8SftWbx
CByLaD0MY+B+lmWL87X2miexWhF5GNG6KGxARA4ZPt8PVT0IHPZ5T2EDwBrgdiQfRURuNRqNtT7vKWrg CROX6IdV3kk9BhbL5fIJxspZu3SbpIxlJ947tN/wNsBi9wSX5oI179Lf13mNtwFoh3mViwSzrwuFwnmX
a5Zli4q80jaq+sDG2FivubpCBjI7sYB7Pj+Acn7C+nwXhQ2o6g7grM/3Q1XPhBB2+rxnGAM3bI8Db70W ZuNrYJctbfHZ0iqs+U7mEO9qzcZ7B+TGol/Q+RrEzA3r0n7hbYAx/fSPdD4Kxk/wxVxzaTb1GHgp3zjx
4U3+629GND9vMQPAlxDCmKruBj5G9DYfgF3AhI2J6F0MY8B4lqbp+hDCVhGRiF6zI9xqgOcRvYdhDRgt V605WDdP/0rlD+FtAHZ4ok7G3iDeUprNJlyHbtgxuUjqMSB84W/7Ikau8kKmHXrIWj0yhnhJaU7qNSCU
YH9+9o+JyFEjTdPNllPVA+6IHsjvGGjzCLggIicMewbqkbqBzBkAJr3wF5ks1ev1DcDniDhqPtn3Mnct YMDc/Z34GBIoekVyrHUH3b6ia/I3Bqp8gCmKjwgSQ95o3lQMEAxqoYkMBvl8voNgWwnN4Lu8L3J0cgwT
s307zP/4PGAn5Omft9If127bOueByyPGekx0NV+I/zq+A9PgZ1seSUA0AAAAAElFTkSuQmCC JLz/xxuA3JDjleLVRkI+nUmYOWKkRrcpe9z++xYEPwDT4GdbjzYebAAAAABJRU5ErkJggg==
</value> </value>
</data> </data>
<data name="btShowManual.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="btShowManual.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAPJJREFUWEft iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAP5JREFUWEft
lj0KwkAQhVNY6n0Uj6BtagvxEFqJvYWnEL1EmiDKvEmXG9gK3kDZsIZk3Jj4s7iEffBB2Pl5r9iEBIGX lj0KwkAQhVNY6n0Uj6BtagvxEFqJvYWnEL1EmiBKfrrcIK3gDfSNTDZk2WQj65IQ9sFHZObtzCMkQc/J
lyti5j6A/Qt2ADYAJnEc9+S8OlM13aN65XyO8pLzAYAQwK0hVyKaPmaZeabODH1VhGX39wNkENESwEqe qTdKkmQax/G1gQs4gVUYhhM+JkQ16rGHvKoZX2gXHyuFhg/eLXlFUbTmoxR+QzXJ04TPR0tRUTJpQYg9
N+A3Ab7AeoC13le103qA3MBQK9VztS1AHS0PQESHwofnqW49gAt3wAfwAf4bwIXXsA4HAxDR0NBohSRJ rge53oL/BDDAeoAjoHl1M60HEAsUvUpfiIqSyYTOA+gYeAC8njdciw+PyjP8Z8AFcAG6DdCH11BHDwPg
BtI/iKKoA+Akmy1wVF7SP1Oapl1mXjDzVv5IGrgUlqpnWS+hd86Vh/T9SMw8BnDWjGTdy6up7uxqphcq ts0VRiukaTrjtaWCIBih+ZDNFrjTLl5bVZZlY/y/24EzjMVDVMcTFEPpt8oj4Jlb2sHrzISBSwzMmQWX
UCfvAAAAAElFTkSuQmCC nZx+lOd9AOxqphdZ7gKgAAAAAElFTkSuQmCC
</value> </value>
</data> </data>
<data name="btTopMenu_Volume.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="btTopMenu_Volume.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAABGdBTUEAALGPC/xhBQAABGpJREFUWEe1 iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAABGdBTUEAALGPC/xhBQAABHFJREFUWEe1
WFtIdFUUnp8ur0U9dCGK6il6DrrwU1AP8Ue9DRFBvzhnrz0XFcX77R9BFARREVHqQRRRMQM172g+mIga mFtIXFcUhifk8pqSPORCSGn7VPIcaFpCA+lDSUjfpIRCI97vKN5vGUEUhEFFRGkfRBEVa0GtdzQ+WBE1
hL4o+ntDJAXvqaNkumJt5gznrLMbxxnng485Z1/W+mbvtfbluFxxIiUl5UUhxMdSyh+klF4ASBNCpAoh EPRF0XhDJAreo45Dra78a7tncs6e7ajjnAUfnnPW2mv97r32uYzNXwsODv4iPDz8+8jIyN9BVERERBzO
vjAM4w3ePinw+XzvAEAZAPwJANcAgFG4AQCNJJrbSRhCiPcB4JcYRPwf5wDgK273znC73c8DQBUA/KNx Q8BPYWFh92SYtRYdHf01CueBd+AQkA/mQQWLlsMDZ0j6AMn/BqeJOIlR8Fym89+CgoKuIVER+E8mvij/
Eg9/9fv9r3I/MSE1NfX18D/jRhPlrmEYD7m/qACAd8MxwI3dFy+EEN9wv1oAwGsAsK4xct+89Hq9n3H/ xMTE3Jbpz2chISF3kYD/M13ii7CCHnssy5zNMOgbwD2gSxgI9tEGv8hyvg3Bd8CcYbBVuKKiop7IsnrL
NpSVlT0LAL9rOieLhx6P5y2uIwIAKNV0ipuBQAALCwsd5VZKKX9zuVwPuBaXYRhvA0CId7iN+fn5ODU1 y8u7gsB/lYFWshEaGvqlLO9tCMhVBlyI2NhYyszM1Prc4B72BqUvHSswGBrtKwQ41QGnkZ6eToODg1RU
hVVVVY66iooKDIVC2Nra6qizUkr5HdfjklL+xBtGo5QSm5ub8ezsDAn9/f22ehJKv+Xl5XhycqLachsW VOTlKygoIKfTSTU1NV4+IxD1Usr4bLj4py74JBBPVVVVtLu7S2xtbW0mPwvlv/n5+bS9vS1ijX6F97jF
PnW73c9ExAQCgZcpyDQNtSwqKsKlpSUlxAQXtL29jePj4+j1erGyshLPz89VP27LpC3rhBB+3kBHGpW2 XJZSbDZM7U1cdClBJ5KVlUWTk5NCiNtUQUtLS9TX10doXCosLKS9vT0xzhhjxLTrcBKjC1LhWamtrSWX
tja8vLy0idEJys7OxvX1dRwYGFDvo6OjODs767BpUgjRbRU0yBsQ09LSsKamBmtra7GhoQE3Nja4jghM yyVlfDZVUHJyMs3NzVF7e7s47+npoZGREVOMEWhoknKEoA5dUFxcHBUXF1NJSQmVl5fT/Py8LO9tbkH1
QR0dHWr0MjMzsaCgQE1pMBjEvLw8vLq6wpycHIefMP8GgOdIzwMAONE0UE5ihSnI5/Ph3NwczszMqPeR 9fVi9hITEykjI0Msqd1up7S0NDo4OKCUlBSvOpKP4CrruYSDbYPDAxc5q7kF4QFMo6OjNDw8LM67u7up
kREcGxtTzysrK9jS0uLwY1II8QGl+pu8wiQZihXWKcvIyFAjU1JSooL64OBAlff29uLk5KTDj4WPKd0f t7dXHE9PT1N1dbUnvwom5iFv9fuqww0nOqsZlywhIUHMTE5Ojmjq9fV1cb2lpYUGBgY8cRpe8XZ/rHEI
aioSEkScnp7Grq4uFXfX19dq+inTlpeXHX4sDFK6P9JUJCyop6dHZRk9Hx0dqdGieNza2nL4sbA6aYIo /BXEDA0NUWNjo+i7w8NDsfy806ampkxxCnbe7s80DsFFBDU3N4tdxsebm5titrgfFxcXTXEKDssE8e7q
u4aGhtQzpXxxcTHW1dXh2tqaw49NULKmbGFhQQUwxZN1yubn5x1+LAwmJahpAby4uMCsrCxsbGxU6xGV 7OwUx7zls7OzqbS0lGZnZ01xCg7Llmx8fFw0MPeTccnGxsZMcQp2S5qab4D7+/uUlJREFRUV4n7E13kJ
0xQODg46/Fj4OGra05wvLi4qrq6ucg02mIJIDMUJxRC904jQYkrPu7u7WF1d7fBjUqU9AQAGeKWO9fX1 Ozo6PHEaXvnc9rzmExMTgpmZGVlab25BLIb7hHuIz3lG+GbKxysrK+RwODz5VcS2Z8NJu+rUUVZWRhsb
eHh4yLUomII2Nzexr69PZVdTU5Pax2jaSMj+/r7aSrjdMCMLIwnyaRpoSbFAi93NzY1WkEka3dPTU/Un G1KC2dyCFhYWqLW1VeyuyspK8RzjZWMha2tr4lGi5pV4bowsKNrg8An3At/sjo6OpJRjU3uIZ3dnZ0f8
SAQFc3t7u8OehT9Htg6Px/PSXTZXIh03dnZ2tII6Ozvx+PhYiaH34eFhJSjK6NCIfh0RFB6lH3mj20gH EyyCm7murs4Uo/CXEMOGl6QbuHDmhyvDrxvLy8tSjllQQ0MDbW1tCTF83tXVJQT5mB2e0RdSzrHh4h9q
MNo0KYu6u7sj5TRFVJeeno4TExO4t7eHubm5jv4WrtiOHwQ6SsZzQCPS2cfv99vKaLenUaKgpmfex0op 0GnwCxg/NHkXNTU1ea7zErEvPj6e+vv7aXV1lVJTU01jFaZNrx9s/CoJx7lf0Bh+98HnjekaP+15lrip
5bc2MSYAoJg3jpcU1KWlpY5yDce4jgho2OiMq+mULB7QOsh12EA3SwBY03S+b9Ld7FPuX4vwRTGZd7OQ +djoU8Hs/CplmA3ObDXYX7ipc3NztT6FXlne23jakOiNZpBVrIP7srze+MsSQbOGQVbB32Y/yrK+DcH8
I6tuQ/jCOKMxlij/8nq9n3B/MYFWTgCouMePDT2GYbzC/dwZhmG8J6XsivdzjBBiVkr5JbebMOgyKYR4 oWjlt5nTa1edZhjEH4zDhiSB4gO2/w+yzPkMg6+CAhCoHxua8TC/JdP7b0jyLaa4EQn9+jkGvTKC8T/L
AgB/AMC/3DHjKgA0SCk/4naSAgB4wTCMD4UQ31s+6aVIKT+nTzm8faz4DwnDvF8jQGuEAAAAAElFTkSu dIEz/phE8tco8hb8byyqYQaUQ8gjOdxaQ7HrEPgdBP6Gou6f9IJx/JR/ypFh5zSb7RMJw7xfBlQNxwAA
QmCC AABJRU5ErkJggg==
</value> </value>
</data> </data>
<data name="arLabel5.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="arLabel5.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAjpJREFUWEfV iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAlxJREFUWEfV
V7tu1UAQDb+CBBUiTSigAZE+SsTjCxAdCGo+ANrkK6DjkYiEd3v3nNnbkFBEfESSKxHpgi4atGutx2Nj l81u00AUhcOrIMGqgg0sYEMFe1QE5QlQd63oug/QbstT0B2UVgEKgW1+7GxoWSAeghKJSgGF70bHlpnc
uA4RRzqN53HG9nh2vLDwPyKEcInktoi8VQJ4DeCC9TsxkHxMclYSwCPrd2IQkRdOAU+t31wAcJPkBxG5 cYbW5edIn6LcuefesT0e263/Ur1e7/pgMHiZZdmB0e/327Cg4fMXzTdhUoUJbGj4/MVRP3cm8FTDzYiC
aG0k920BJHetn8ZqDgA3rK0TInKb5DQlPhaRB7PZ7IzaQghXSX53CpjGGC+rj/qSvE/yW7aRvGV1XGi1 DyjcodkVhUoR/1RtLg41XMq8xDvUuq9QmjA+xDhW4RP+P55MJhdsjOt/i9h3jVUZ53l+w3Isl/9r8K0Y
hXjJjyQ/O9ctI4B3zvVprycB4KUTPAi1d6xeAwDOkjy0wQNwMhqNzls9FyJy10kwL+9YnVZoE7W8x7+i g2UbmyubrQxhg3fwIYh55NR448THSWeCpF3H3Ai2dtQmLiZwkeTj0NwAo263e1lt6sVMV5wCZ+WRys+X
Diqr0YnUxV9sIkPFeqI49ooiEqxGJ2KMyzZJwQMAKzaG5GpX7+j4tjEV0mx/kr6AryR/2ASZnniGiKxZ LaLIdTwV1GqrdJq0ij+GhQJM2yIDL2cKZ7Sn0mnidrrjFRJfOKK7Si1FfAmia8e2b6XOSnv7lu6Az/Cj
/4I6O3SAPddRHmNcqgJJbjkBDQJATdHB715Hwa0qSJvEcfC4XlNzQHLDiWuw1pinXgDJTevQQqmpOSA5 MIZ4zQtxpPc8j7C9wzawZ7DJQV6TbTr7ffBMv0DzvixRkVd7OSrsyzK99dpOgse2LFGR8yTwuFhPWf6B
duI8blZBukzoeU7yGcm9lrMgc7WmWCCdI9Y/U3PuqoZqdS4wInLdSZB5qN1uY5L4keP/i52foUXPQRTT CRDYCxMiZLJERc4w8MTYk2V6BhZgg+AOHIH3LChYkm1G1LDniOcxrOYh7Fgv6ynbrFjNtyvGkGNb7Uot
+1Z2PvY/HkRagIh8sonm4Ju8T/QCgIdOknl5z+q40OYoNpkheRxjXLR6DegO5wQPxfdWr4G2lUz3/74r peZfg9yS2tswVOJGlINdb6P2tP/2RmQTwPTeK3ZKXltNlZ8vTue6U+SsrKp8vWxxkFy8yTTJCbvfVbWJ
Gckd53q/lUyhC2RRxEQXlGwDcK3lsJqGEK5kv7TUTLKt91KaodXq6Tgej89ZWzoxbQF71k9jNUfvO+8L i8ROYGySt2oTl1bzzG3ImjjgN+mVDF4FMSPtlcxE8rIZZBzRfEVDNsFFYt7DasytdlNpxUvNqBiDtJfS
kq9sAYP/mHRBdwengH/3a3bqP6dD4if8nu9RoGmrKgAAAABJRU5ErkJggg== QjZb2B0Oh5cUKkUxe2KGEzjScCnzWo3kI08VzV4EzW1vb/bDpE403HIm8Oc+zfQC8/c+TptTq/UT/J7v
URSJG9cAAAAASUVORK5CYII=
</value> </value>
</data> </data>
<data name="btClose.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="btClose.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAplJREFUWEft iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAsRJREFUWEft
V7tuFEEQdALkPHIgByIQfAE2GRAZCMCQmAyZDA74AhAPG/7AwIectNfVeyQXnY0TbEJMgu2Ah+rUc/Q2 lz9TU0EUxdOovWKv9Golo59AsRMr0ELQRjsHO4n4CWD8A/oNUD9IZpKQxCYVIg1gKTYChejvvDmbbN57
s3d7xojEJY20mqrumenpnpmdmtrHLlAUxREAp0TkkojM8Jt9UbenEJGTIvIEQBfAz5pWqurjoihORPtd IS8gY8OZOZPHuefe3b27+xJKpzgKqtXqhdXV1Sv1ev0OHNezNIdPBgw0Cl8xWAv+6cNmo9GYZzKXnXZ8
oyzLYwBeANjJDFjXqH0O4Gj0NxFU9TyAjeB8U1WXATxU1Zts9s2+zaDdEJFz0W8jiMhVAFvO2YqIzAI4 NJvNixR+A/ejgQZR3tdwxGWOBlZzgyLbLhq4g77C5xyfD0U/S9uxJ3Cbro253HAg8R4FdqNiX9Em+Txj
ELUJ5ABcA7Dq7LZU9UrUjoStfDi4iLzq9XoHo64O1AJY9JNoHAnb889u8HtR0xQAFtwk1htViiXcwEhV SwaKwSm4DkPeLpObsKUYSNDKO4Mz8Lt2u33W4YGQl7ylkA93C3fCe/49JJP4zKGhQf5sqAO3Ct0UjDpw
X3quiYOoAbDkFvPMc3+ApeayfdWHvSzLC5Zkd6pWv0GOGmpTX7/fPwTgo/ncGVmiVudptrOpn+XkMvx7 SRKdeGs5QZECaQ91lkM9FrNoOR8YRjGG074et53O3ETTIXtsKQPF5JHXUmltbe0c2jeomvuHXlEmoHse
bhI2ODlqqB2WoKrecFvxqGrpAOBDchCTTkTm3AA/ANwdwc17W6uOL8ar54aw4zXt/XLkibDKQSRyfdGO ZjtpWYVHYDjhv2FmEtIck0fezhWkkw+siy8tZ0Hwi0076UPHhGbQwwAH8KlDebEnDiXgb92OH443LPdC
APAuTbDdbh+OPPf4jAv/g8gnZAYcOzjBw8ot8HTkGUZeKklwK/IeIeTZsEeYTfI/HXkmyrSLwFzkPWom e2eD9n7Fcg+IxatMOpGn2d4D9E/2HFQqlfOWu2Dfrtmg9r+wnAHx9IADBxeIzdmnBV613AWD6kslGKYt
MMyJHETktpvAxcj//y3wSSgibyNPZAafJAnfp2hlk5DgfW6iJmU43PMMV9kOO4y+2uLEcxXwMZGiwFst 5yLVcjHT9jScE+rfttyFxGCQ2XIu+kygcybyQM6j4GesW5a7+O9bEB9CJvDRcg+IHecQfrYn/xAKBJs2
9e/xQdSqWjrwmPxHR/Ga+dzudrvHq1YB9pJJs130XLxocogaAK+TP1V96rksLNz+FbQQNU0B4L7z8ylO FbmGnT3PifVsh19GPxXHW7ecBa2ZdxFxyrIm9i9fRGXLWeg1ieEkXsUbUDX3Wq3WJYfygUm/ZMJslywn
rhZ8PITX0BJDGXV1oFZV3zj7b51O52zUjQSfUWESa6p6PVaHBzlLuLTng8FV9XLUNoJFYt05Y2M58WJp SH/R5CHtocb7UI9OLFjuD4xqd/wraNahoUHu86jOZpEFJOCcjJEQ/xpaVisdHgh5We2HKP9XrVa77nAx
8chm47f1DUrNh33ilUdw3/iSmfBZvs2Ea7znTWAlypVqZsDUyLXGltrfgkep/ZrNpF+z2uN1H2PwC9Ia UGCCxHgSG2j307cjhmI+cGHPk8HR7toyHNyJraiYqOukL5YyhadFPVtLrlrEzaFXnob2jYksUmyYn+V7
w16WomAQAAAAAElFTkSuQmCC TGyh8J4XAcV0RbXSRjRQmoqVB16140KvUgbSv2bjop77vl5PcShKpb/SGsNeH5IytgAAAABJRU5ErkJg
gg==
</value> </value>
</data> </data>
<data name="pictureBox1.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64"> <data name="pictureBox1.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value> <value>
iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAYAAAAeP4ixAAAABGdBTUEAALGPC/xhBQAAA5JJREFUaEPt iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAYAAAAeP4ixAAAABGdBTUEAALGPC/xhBQAAA5hJREFUaEPt
mn1TElEUxv12fZVm+g7NNNMokqQ1KouACBKjKIovwAJLaqRGgCkpooiYjpbmS5omyctpzjV2bK8Ku+7m mvtTElEUx/3v+lea6X9oppnGV5LV+EABUSRG8f3gvaZGagaakuIDFdPR0nykaZqv0/1eASmuAstursbX
UpyZ3z/sc5jz7N17OHeHhoZ6qDQe2h4/eOR4wtQSWLPQRwNesM+7YDg1XhNgrViz0AcxgoLARqgmwFrr +fyye45zvnDv2XN3KMhLq3poefzgke2J/i6BmmPlXwk3rBNt1DHbeydArag5Vv6VcBEB3uW+OwFqzRvR
RtRE3YjaqBtRAmvcCYaZ3luxzw9SeYhqjHjW/NASMMHi9uqtNPsNVC6iGiOd0zZIbq9BpVC9kSYfAyUo EnkjWiNvRA0axuxUM9x4I9aJVmGuZow4FjxU5jXS1Nr8jZR4aoT5mjFSNWSh8NoCpZPmjRS59HTB/qC1
kWK3j3aplaiJFXk174LxxAQxgWaeejqpvVETe0Qb6ILT3BkxkthKgWHGTmkqce9GRld9wEw5+D3QxvWA 3Q3htwE0beQ1Gy96Q/3cBMw8dVQJ9wfQ9B4p9dbSwfEhNxJanWUFW4VxN3HrRrrnXaQftHET0AupnpyL
N+OndJW4dyPtYSus7X0iJo7OTkAXMlGaarhXI/4NDjSsgV+N/qgHnIsjlK4aJBkxRhzQwhkpnnFGcC5V HmHsTdy6kQp/Ay1sfuYmdg/3SddnFMal41aNeJYlKnbXcBNQc8BB9qkuYWw6ZBkxjNqoTDKk8Ixhn868
X4gt7oRgcpqYKBSLoGEZSlMtkoxgC7wuTs5PQRcyUvqb0Pj1cH6RI7nRbALMEQelqRZZjWB0TNhhLM1S EAt7APrCQ9zE2fk5M6UXxmWCLCNogSLtHx2wpWEQ5ogo9lTT0ckxzw1EQ2RiH5AoLhMUNQJV9lupJ+IW
OULcKQ+Y3w7webqgGXzrQUpXLZKMNLEMuOZYnqE5P1kNjNXdLHSErVSOkBeTFtg6/Exydo/3ofW1mdKI 5iXTOesg07uWWBaRzmci15JPGJsJsowUsSXQNu5O0D7u4d8GNL8RpUq2gUV5ybwcMNPqzhees7G3ReVv
QZKRsbQPhpbHeXri/TAQY/m728x2QSBL55Vh1znQ+o28vnfWDa7kGKUTgyQj19Ho00OhWCCFTaQiYI05 TMK4TJFlpCfiovaZ3gT1Y83UEnTzoqASdy15o6l5cdxLEpV6DLFoosaRTmoL9whjM0WWERGFrmq2Yc94
KU2Z7mgfhNMxos0XCzeOHWKQzYgp4oDZzIfL4gp50N5SnManh4tCnmjD6ShYYn2URiyyGWGzQdAFTPzj Yf2zo9QQtAvjQF2gifyRII89ZTnXjR3ZoJgRI9uoI4sfL4s7O2Wf+PXFFTPTJywG8kcCZA42CeOyQTEj
Yn/nhsHkKKXDR8g26+Z1+IhhrlAnFtmMILiBNw92SIH734+u3cD42Zfjr0SDU+7LKQulkYKsRkZWvGAM 7qiPdGwMj8v6vpNaw90pcVhCFraU4sISQ+7fcdmimBGADbyyvc4L3PqxK9zAuPZ17xuPwZT7atCcEiMH
O/m73cpZ/pib2PUgPOe6+evYfrENC79HCrIaQXDjnuZ+kEITWyvAXJlkcSJ4n02Qa7n8T2gO3LyPxCK7 RY10zTnJ4LfzIqFyyfzH3ORm7fW5VBe7S7z9og0n/w+5KGoEYOMeHP/khYZW50ifNMliIvjAHnzQ8ekv
katnCwycpXCmwmuNvk6+s3HLM2CLD1D5UpHdCIKtuFS6PO15P06RwxDOYDgUlqPSb41YFDGCJ7mFzWVS KvHmvsnjKG4k+WwBYZbCTIV7ha6qRGeTZobZiNKSki8XxY0AtOKLi8vTnvPTID8MYQbDUBhXumdNtqhi
MM5SeHDScSY4PPtGPsvsbUL7m8q//mJQxIg3E4A2zsLffdzUeGAqBzPpINOBMO8uKGIEwTa7d3JACsc2 BCe5yZUZXjBmKRycdJKRdg6/82uLmytU8Tb90z8bVDHiXPSyA5KZFw1hU+PAFJd+wManA1GuXFQxAtBm
i0dYDGwE2mAXpb8rihm5/OEb5lehHNgIsCEI9XdFMSMIHpSwzV4NnJzLXUxOFDWCr0C53ydAjKWdNOin N/e3eeFoszjCQmgEpT62rAQ5uaCakcsHXwcvPlloBGgIopxcUM0IwEEJbTZZmJzjXUxJVDWCV6BS7AQI
xb8hqQZFjWB7bfIy/Ms1XcBMXo1SOhlQ1shGCBwLLv7lGq6Q8LpcKG7kb1E3ojbqRtTG/2Hkn/gLxz/z Ta9HqHoo+zckmaCqEbTXIqc+8XJN5zXxV6PC2BxR1wjDNtmWeLmGb0gUowSqG/lX5I1ojbwRrfF/GLkX
p5p6qCR+AaqNxnTXLPGFAAAAAElFTkSuQmCC P+G4Nz+qyUsTKij4DaqNxnRXLBhpAAAAAElFTkSuQmCC
</value> </value>
</data> </data>
<metadata name="cmDebug.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"> <metadata name="cmDebug.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">

View File

@@ -172,14 +172,17 @@ namespace Project.StateMachine
var runningStartTime = DateTime.Now; var runningStartTime = DateTime.Now;
var runningTask = System.Threading.Tasks.Task.Run(() => var runningTask = System.Threading.Tasks.Task.Run(() =>
{ {
try
{ //try
//{
runningHandler(this, new RunningEventArgs(Step, firstRun, StepRunTime)); runningHandler(this, new RunningEventArgs(Step, firstRun, StepRunTime));
} //}
catch (Exception ex) //catch (Exception ex)
{ //{
RaiseMessage("SM-ERROR-RUNNING", $"Running Exception: {ex.Message}\n{ex.StackTrace}"); // RaiseMessage("SM-ERROR-RUNNING", $"Running Exception: {ex.Message}\n{ex.StackTrace}");
} //}
}); });
// 타임아웃 2초 // 타임아웃 2초
@@ -193,7 +196,8 @@ namespace Project.StateMachine
{ {
RaiseMessage("SM-ERROR-RUNNING", $"Running Exception: {ex.Message}\n{ex.StackTrace}"); RaiseMessage("SM-ERROR-RUNNING", $"Running Exception: {ex.Message}\n{ex.StackTrace}");
} }
} System.Threading.Thread.Sleep(1); }
System.Threading.Thread.Sleep(1);
} }
} }
catch (Exception ex) catch (Exception ex)
@@ -252,11 +256,8 @@ namespace Project.StateMachine
if (handler != null) if (handler != null)
{ {
var args = new StepChangeEventArgs(OldStep, newstep_); var args = new StepChangeEventArgs(OldStep, newstep_);
System.Threading.ThreadPool.QueueUserWorkItem(_ =>
{
try { handler(this, args); } try { handler(this, args); }
catch { /* 이벤트 핸들러 예외 무시 */ } catch { /* 이벤트 핸들러 예외 무시 */ }
});
} }
} }
else else
@@ -374,11 +375,8 @@ namespace Project.StateMachine
if (handler != null) if (handler != null)
{ {
var args = new StepChangeEventArgs(ostep, _step); var args = new StepChangeEventArgs(ostep, _step);
System.Threading.ThreadPool.QueueUserWorkItem(_ =>
{
try { handler(this, args); } try { handler(this, args); }
catch { /* 이벤트 핸들러 예외 무시 */ } catch { /* 이벤트 핸들러 예외 무시 */ }
});
} }
} //171214 } //171214

View File

@@ -12,7 +12,7 @@ using AR;
namespace arDev namespace arDev
{ {
public partial class Narumi : arRS232 public partial class Narumi
{ {
public bool AGVMoveSet(BunkiData opt) public bool AGVMoveSet(BunkiData opt)
@@ -236,12 +236,12 @@ namespace arDev
case eAgvCmd.ChargeOf: case eAgvCmd.ChargeOf:
cmdString = $"CBT{param}O0003"; ///0003=충전대기시간 cmdString = $"CBT{param}O0003"; ///0003=충전대기시간
retval = AddCommand(cmdString); retval = AddCommand(cmdString);
RaiseMessage(arRS232.MessageType.Normal, "충전취소전송"); RaiseMessage(NarumiSerialComm.MessageType.Normal, "충전취소전송");
break; break;
case eAgvCmd.ChargeOn: case eAgvCmd.ChargeOn:
cmdString = $"CBT{param}I0003"; ///0003=충전대기시간 cmdString = $"CBT{param}I0003"; ///0003=충전대기시간
retval = AddCommand(cmdString); retval = AddCommand(cmdString);
RaiseMessage(arRS232.MessageType.Normal, "충전명령전송"); RaiseMessage(NarumiSerialComm.MessageType.Normal, "충전명령전송");
break; break;
case eAgvCmd.TurnLeft: case eAgvCmd.TurnLeft:

View File

@@ -0,0 +1,69 @@
using System;
using System.Linq;
using AR;
namespace arDev
{
public partial class Narumi
{
public class Dataframe
{
public byte STX { get; private set; }
public byte ETX { get; private set; }
public byte[] Data { get; private set; }
public string DataString { get; private set; }
public byte[] checksum { get; private set; } = new byte[2];
public bool Valid { get; private set; } = false;
public string Message { get; private set; } = string.Empty;
public byte[] Buffer { get; private set; }
public string Cmd { get; private set; } = string.Empty;
public bool Parse(byte[] data, int MinRecvLength = 0)
{
if (data == null || data.Any() == false)
{
this.Message = string.Format("수신 데이터가 없습니다");
return false;
}
else if (data.Length < 5)
{
this.Message = $"데이터의 길이가 5보다 작습니다 길이={data.Length}";
return false;
}
else if (MinRecvLength > 0 && data.Length < MinRecvLength)
{
this.Message = $"데이터의 길이가 {MinRecvLength}보다 작습니다 길이={data.Length}";
return false;
}
else if (data[0] != 0x02 || data[data.Length - 1] != 0x03)
{
this.Message = $"STX/ETX Error";
return false;
}
Buffer = new byte[data.Length];
Array.Copy(data, Buffer, data.Length);
STX = data[0];
ETX = data[data.Length - 1];
Array.Copy(data, data.Length - 3, checksum, 0, 2);
Data = new byte[data.Length - 4];
Array.Copy(data, 1, Data, 0, data.Length - 4);
if (data.Length > 2) Cmd = System.Text.Encoding.Default.GetString(Data, 0, 3);
this.DataString = System.Text.Encoding.Default.GetString(Data);
Valid = true;
return true;
}
public Dataframe(byte[] buffer = null, int minlen = 0)
{
if (buffer != null) Parse(buffer);
}
}
}
}

View File

@@ -47,8 +47,10 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="DataEventArgs.cs" /> <Compile Include="DataEventArgs.cs" />
<Compile Include="Dataframe.cs" />
<Compile Include="EnumData.cs" /> <Compile Include="EnumData.cs" />
<Compile Include="Command.cs" /> <Compile Include="Command.cs" />
<Compile Include="NarumiSerialComm.cs" />
<Compile Include="Structure\ErrorFlag.cs" /> <Compile Include="Structure\ErrorFlag.cs" />
<Compile Include="Narumi.cs" /> <Compile Include="Narumi.cs" />
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />

View File

@@ -8,18 +8,17 @@ using System.Threading.Tasks;
using System.Collections; using System.Collections;
using COMM; using COMM;
using AR; using AR;
using System.Xml;
namespace arDev namespace arDev
{ {
public partial class Narumi : arRS232 public partial class Narumi : arDev.NarumiSerialComm
{ {
Hashtable SystemCheck, ErrorCheck; Hashtable SystemCheck, ErrorCheck;
private Queue Errlog; // 에러발생시 코드 임시 저장용(쓰레드 동기화용) private Queue Errlog; // 에러발생시 코드 임시 저장용(쓰레드 동기화용)
public int nBatteryNo { get; set; } = 0; public int nBatteryNo { get; set; } = 0;
public Narumi() public Narumi()
{ {
SystemCheck = new Hashtable(); SystemCheck = new Hashtable();
@@ -124,75 +123,18 @@ namespace arDev
return bComplete; return bComplete;
} }
public class Dataframe
{
public byte STX { get; private set; }
public byte ETX { get; private set; }
public byte[] Data { get; private set; }
public string DataString { get; private set; }
public byte[] checksum { get; private set; } = new byte[2];
public bool Valid { get; private set; } = false;
public string Message { get; private set; } = string.Empty;
public byte[] Buffer { get; private set; }
public string Cmd { get; private set; } = string.Empty;
public bool Parse(byte[] data, int MinRecvLength = 0)
{
if (data == null || data.Any() == false)
{
this.Message = string.Format("수신 데이터가 없습니다");
return false;
}
else if (data.Length < 5)
{
this.Message = $"데이터의 길이가 5보다 작습니다 길이={data.Length}";
return false;
}
else if (MinRecvLength > 0 && data.Length < MinRecvLength)
{
this.Message = $"데이터의 길이가 {MinRecvLength}보다 작습니다 길이={data.Length}";
return false;
}
else if (data[0] != 0x02 || data[data.Length - 1] != 0x03)
{
this.Message = $"STX/ETX Error";
return false;
}
Buffer = new byte[data.Length];
Array.Copy(data, Buffer, data.Length);
STX = data[0];
ETX = data[data.Length - 1];
Array.Copy(data, data.Length - 3, checksum, 0, 2);
Data = new byte[data.Length - 4];
Array.Copy(data, 1, Data, 0, data.Length - 4);
if (data.Length > 2) Cmd = System.Text.Encoding.Default.GetString(Data, 0, 3);
this.DataString = System.Text.Encoding.Default.GetString(Data);
Valid = true;
return true;
}
public Dataframe(byte[] buffer = null, int minlen = 0)
{
if (buffer != null) Parse(buffer);
}
}
public override bool ProcessRecvData(byte[] data) public override bool ProcessRecvData(byte[] data)
{ {
//LastReceiveBuffer //LastReceiveBuffer
var frame = new Dataframe(data, MinRecvLength); var frame = new Dataframe(data, MinRecvLength);
if (frame.Valid == false) if (frame.Valid == false)
{ {
RaiseMessage(arRS232.MessageType.Error, frame.Message); RaiseMessage(MessageType.Error, frame.Message);
return false; return false;
} }
else if (frame.DataString.StartsWith("$") == false && CheckSum(data) == false) else if (frame.DataString.StartsWith("$") == false && CheckSum(data) == false)
{ {
RaiseMessage(arRS232.MessageType.Error, "Checksum Error MSG=" + frame.DataString); RaiseMessage(MessageType.Error, "Checksum Error MSG=" + frame.DataString);
return false; return false;
} }
@@ -218,7 +160,7 @@ namespace arDev
// $로 시작되는 AGV 상태 표시 // $로 시작되는 AGV 상태 표시
//var text_Sts_Etc = Encoding.Default.GetString(bRcvData, 3, bRcvData.Length - 2).TrimStart(' '); //20210311 김정만 - SmartX FrameWork 사용 안함으로 주석처리 //var text_Sts_Etc = Encoding.Default.GetString(bRcvData, 3, bRcvData.Length - 2).TrimStart(' '); //20210311 김정만 - SmartX FrameWork 사용 안함으로 주석처리
//var sMessageOther = Encoding.Default.GetString(bRcvData, 3, bRcvData.Length - 2).TrimStart(' '); //var sMessageOther = Encoding.Default.GetString(bRcvData, 3, bRcvData.Length - 2).TrimStart(' ');
RaiseMessage(arRS232.MessageType.Normal, "$메세지수신:" + frame.DataString); RaiseMessage(MessageType.Normal, "$메세지수신:" + frame.DataString);
} }
else else
{ {
@@ -228,7 +170,7 @@ namespace arDev
} }
catch (Exception ex) catch (Exception ex)
{ {
RaiseMessage(arRS232.MessageType.Error, ex.Message); RaiseMessage(MessageType.Error, ex.Message);
retval = false; retval = false;
} }
} }
@@ -279,14 +221,15 @@ namespace arDev
public SystemFlag1 system1 = new SystemFlag1(); public SystemFlag1 system1 = new SystemFlag1();
public ErrorFlag error = new ErrorFlag(); public ErrorFlag error = new ErrorFlag();
public AgvData data = new AgvData(); public AgvData data = new AgvData();
public Signal signal = new Signal(); public Signal1 signal1 = new Signal1();
public Signal2 signal2 = new Signal2();
#region [] STS(AGV상태정보) #region [] STS(AGV상태정보)
public string LastSTS { get; set; } = string.Empty; public string LastSTS { get; set; } = string.Empty;
private void RevSTS(Dataframe frame) private void RevSTS(Dataframe frame)
{ {
LastSTS = frame.DataString; LastSTS = frame.DataString;
string rcvdNow = frame.DataString; string rcvdNow = frame.DataString.Replace("\0","");
byte[] bRcvData = frame.Buffer; byte[] bRcvData = frame.Buffer;
var encoding = System.Text.Encoding.Default; var encoding = System.Text.Encoding.Default;
try try
@@ -322,42 +265,15 @@ namespace arDev
data.guidesensor = int.Parse(rcvdNow.Substring(idx, 1)); idx += 1; //가이드 좌측부터 1~9 data.guidesensor = int.Parse(rcvdNow.Substring(idx, 1)); idx += 1; //가이드 좌측부터 1~9
nDataTemp = Convert.ToByte(rcvdNow.Substring(idx, 2), 16); nDataTemp = Convert.ToByte(rcvdNow.Substring(idx, 2), 16);
signal.SetValue(nDataTemp); signal1.SetValue(nDataTemp); idx += 2;
//data.Sts = encoding.GetString(bRcvData, 19, 3); //20210311 김정만 - SmartX FrameWork 사용 안함으로 주석처리 if(idx <= rcvdNow.Length-2)
{
//var Sts_cSpeed = encoding.GetString(bRcvData, 19, 1)[0]; nDataTemp = Convert.ToByte(rcvdNow.Substring(idx, 2), 16);
//var Sts_cDirection = encoding.GetString(bRcvData, 20, 1)[0]; signal2.SetValue(nDataTemp);
//var Sts_cFB = encoding.GetString(bRcvData, 21, 1)[0]; }
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////가이드센서 정보 (22)//////////////////////////////////////////////////////////////////////////////////////////////////////////
//var Sts_nGuide = 0;
//if (bRcvData[22] > 47 && bRcvData[22] < 58) { Sts_nGuide = Convert.ToInt32(encoding.GetString(bRcvData, 22, 1)); }
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////마크센서 & 포토센서 정보 (23~24)////////////////////////////////////////////////////////////////////////////////////////////////////
//nDataTemp = Convert.ToInt32(encoding.GetString(bRcvData, 23, 2), 16);
//data.Sts_bMark1 = Convert.ToBoolean(nDataTemp & 0x4);
//data.Sts_bMark2 = Convert.ToBoolean(nDataTemp & 0x8);
//data.Sts_bCargo = Convert.ToBoolean(nDataTemp & 0x10);
////포토센서
//if (Sts_cFB == 'F')
//{
// system.Sts_nSenser = Convert.ToInt32(encoding.GetString(bRcvData, 26, 1));
//}
//else if (Sts_cFB == 'B')
//{
// system.Sts_nSenser = Convert.ToInt32(encoding.GetString(bRcvData, 27, 1));
//}
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//AGV 속도/분기/방향 (19~21)//////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
DataReceive?.Invoke(this, new DataEventArgs(DataType.STS)); DataReceive?.Invoke(this, new DataEventArgs(DataType.STS));
} }

View File

@@ -0,0 +1,609 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading;
namespace arDev
{
public abstract class NarumiSerialComm : ISerialComm, IDisposable
{
protected System.IO.Ports.SerialPort _device;
protected ManualResetEvent _mre;
protected byte[] LastReceiveBuffer = new byte[] { };
/// <summary>
/// 최종 전송 메세지
/// </summary>
public byte[] lastSendBuffer = new byte[] { };
//public int ValidCheckTimeMSec { get; set; } = 5000;
protected List<byte> tempBuffer = new List<byte>();
protected Boolean findSTX = false;
public string ErrorMessage { get; set; }
public DateTime LastConnTime { get; set; }
public DateTime LastConnTryTime { get; set; }
public DateTime lastSendTime;
/// <summary>
/// 메세지 수신시 사용하는 내부버퍼
/// </summary>
protected List<byte> _buffer = new List<byte>();
/// <summary>
/// 데이터조회간격(초)
/// </summary>
public float ScanInterval { get; set; }
// public byte[] LastRecvData;
public string LastRecvString
{
get
{
if (LastReceiveBuffer == null) return String.Empty;
else return System.Text.Encoding.Default.GetString(LastReceiveBuffer);
}
}
/// <summary>
/// 마지막으로 데이터를 받은 시간
/// </summary>
public DateTime lastRecvTime;
public int WriteError = 0;
public string WriteErrorMessage = string.Empty;
public int WaitTimeout { get; set; } = 1000;
public int MinRecvLength { get; set; } = 1;
// Polling Thread related
protected Thread _recvThread;
protected volatile bool _isReading = false;
/// <summary>
/// 포트이름
/// </summary>
[Description("시리얼 포트 이름")]
[Category("설정"), DisplayName("Port Name")]
public string PortName
{
get
{
if (_device == null) return string.Empty;
else return _device.PortName;
}
set
{
if (this.IsOpen)
{
Message?.Invoke(this, new MessageEventArgs("포트가 열려있어 포트이름을 변경할 수 없습니다", true));
}
else if (String.IsNullOrEmpty(value) == false)
_device.PortName = value;
else
{
Message?.Invoke(this, new MessageEventArgs("No PortName", true));
}
}
}
public int BaudRate
{
get
{
if (_device == null) return 0;
else return _device.BaudRate;
}
set
{
if (this.IsOpen)
{
Message?.Invoke(this, new MessageEventArgs("포트가 열려있어 BaudRate(를) 변경할 수 없습니다", true));
}
else if (value != 0)
_device.BaudRate = value;
else Message?.Invoke(this, new MessageEventArgs("No baud rate", true));
}
}
public NarumiSerialComm()
{
_device = new System.IO.Ports.SerialPort();
this.BaudRate = 57600;
ScanInterval = 10;
// _device.DataReceived += barcode_DataReceived; // Removed event handler
_device.ErrorReceived += this.barcode_ErrorReceived;
_device.WriteTimeout = 3000;
_device.ReadTimeout = 3000;
_device.ReadBufferSize = 8192;
_device.WriteBufferSize = 8192;
//_device.DiscardInBuffer();
//_device.DiscardOutBuffer();
ErrorMessage = string.Empty;
lastRecvTime = DateTime.Parse("1982-11-23");
LastConnTime = DateTime.Parse("1982-11-23");
LastConnTryTime = DateTime.Parse("1982-11-23");
lastRecvTime = DateTime.Parse("1982-11-23");
this._mre = new ManualResetEvent(true);
}
~NarumiSerialComm()
{
Dispose(false);
}
// Flag: Has Dispose already been called?
bool disposed = false;
// Public implementation of Dispose pattern callable by consumers.
public void Dispose()
{
Dispose(true);
GC.SuppressFinalize(this);
}
// Protected implementation of Dispose pattern.
protected virtual void Dispose(bool disposing)
{
if (disposed)
return;
if (disposing)
{
// Free any other managed objects here.
//
}
// Stop reading thread
_isReading = false;
// _device.DataReceived -= barcode_DataReceived; // Removed event handler
_device.ErrorReceived -= this.barcode_ErrorReceived;
if (_recvThread != null && _recvThread.IsAlive)
{
_recvThread.Join(500);
}
if (_device != null)
{
if (_device.IsOpen) _device.Close();
_device.Dispose();
}
// Free any unmanaged objects here.
//
disposed = true;
}
public Boolean Open()
{
try
{
if (_device.IsOpen == false)
{
_device.Open();
}
if (_device.IsOpen)
{
// Start polling thread
if (_isReading == false)
{
_isReading = true;
_recvThread = new Thread(ReadPort);
_recvThread.IsBackground = true;
_recvThread.Start();
}
return true;
}
return false;
}
catch (Exception ex)
{
ErrorMessage = ex.Message;
Message.Invoke(this, new MessageEventArgs(ex.Message, true));
return false;
}
}
public string GetHexString(Byte[] input)
{
System.Text.StringBuilder sb = new System.Text.StringBuilder();
foreach (byte b in input)
sb.Append(" " + b.ToString("X2"));
return sb.ToString();
}
/// <summary>
/// 포트가 열려있는지 확인
/// </summary>
[Description("현재 시리얼포트가 열려있는지 확인합니다")]
[Category("정보"), DisplayName("Port Open")]
public Boolean IsOpen
{
get
{
if (_device == null) return false;
return _device.IsOpen;
}
}
public virtual bool Close()
{
try
{
_isReading = false; // Stop thread loop
if (_recvThread != null && _recvThread.IsAlive)
{
if (!_recvThread.Join(500)) // Wait for thread to finish
{
// _recvThread.Abort(); // Avoid Abort if possible
}
}
if (_device != null && _device.IsOpen)
{
_device.DiscardInBuffer();
_device.DiscardOutBuffer();
_device.Close(); //dispose에서는 포트를 직접 클리어하지 않게 해뒀다.
return true;
}
else return false;
}
catch (Exception)
{
return false;
}
}
protected Boolean RaiseRecvData()
{
return RaiseRecvData(LastReceiveBuffer.ToArray(), false);
}
/// <summary>
/// 수신받은 메세지를 발생 시킵니다
/// </summary>
/// <param name="data"></param>
/// <returns></returns>
public virtual Boolean RaiseRecvData(byte[] Data, bool udpatelastbuffer)
{
//181206 - 최종수신 메세지 기록
lastRecvTime = DateTime.Now;
if (udpatelastbuffer && Data != null)
{
if (LastReceiveBuffer == null || LastReceiveBuffer.Length != Data.Length)
{
LastReceiveBuffer = new byte[Data.Length];
Array.Copy(Data, LastReceiveBuffer, Data.Length);
}
}
try
{
// UI update might need Invoke if this event handler updates UI directly,
// but usually the subscriber handles Invoke.
// Since we are running on a background thread now, subscribers must be aware.
Message?.Invoke(this, new MessageEventArgs(Data, true)); //recvmessage
if (ProcessRecvData(Data) == false)
{
//Message?.Invoke(this, new MessageEventArgs(Data, true)); //recvmessage
Message?.Invoke(this, new MessageEventArgs(this.ErrorMessage, true)); //errormessage
return false;
}
else
{
return true;
}
}
catch (Exception ex)
{
this.ErrorMessage = ex.Message;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
return false;
}
}
/// <summary>
/// 수신받은 자료를 처리한다
/// </summary>
/// <param name="data"></param>
/// <returns></returns>
public abstract bool ProcessRecvData(byte[] data);
#region "Internal Events"
void barcode_ErrorReceived(object sender, System.IO.Ports.SerialErrorReceivedEventArgs e)
{
Message?.Invoke(this, new MessageEventArgs(e.ToString(), true));
}
byte[] buffer = new byte[] { };
// Replaced with ReadPort Loop
/*
void barcode_DataReceived(object sender, System.IO.Ports.SerialDataReceivedEventArgs e)
{
try
{
int ReadCount = _device.BytesToRead;
buffer = new byte[ReadCount];
_device.Read(buffer, 0, buffer.Length);
System.Text.StringBuilder LogMsg = new StringBuilder();
byte[] remainBuffer;
Repeat:
if (CustomParser(buffer, out remainBuffer))
{
//분석완료이므로 받은 데이터를 버퍼에 기록한다
if (LastReceiveBuffer == null || (LastReceiveBuffer.Length != tempBuffer.Count))
Array.Resize(ref LastReceiveBuffer, tempBuffer.Count);
Array.Copy(tempBuffer.ToArray(), LastReceiveBuffer, tempBuffer.Count);
tempBuffer.Clear();
//수신메세지발생
RaiseRecvData();
if (remainBuffer != null && remainBuffer.Length > 0)
{
//버퍼를 변경해서 다시 전송을 해준다.
Array.Resize(ref buffer, remainBuffer.Length);
Array.Copy(remainBuffer, buffer, remainBuffer.Length);
goto Repeat; //남은 버퍼가 있다면 진행을 해준다.
}
}
}
catch (Exception ex)
{
//if (IsOpen)
//{
// //_device.DiscardInBuffer();
// //_device.DiscardOutBuffer();
//}
ErrorMessage = ex.Message;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
}
}
*/
void ReadPort()
{
while (_isReading)
{
try
{
if (_device == null || !_device.IsOpen)
{
Thread.Sleep(100);
continue;
}
int readCount = _device.BytesToRead;
if (readCount > 0)
{
byte[] buffer = new byte[readCount];
_device.Read(buffer, 0, buffer.Length);
byte[] remainBuffer;
Repeat:
if (CustomParser(buffer, out remainBuffer))
{
//분석완료이므로 받은 데이터를 버퍼에 기록한다
if (LastReceiveBuffer == null || (LastReceiveBuffer.Length != tempBuffer.Count))
Array.Resize(ref LastReceiveBuffer, tempBuffer.Count);
Array.Copy(tempBuffer.ToArray(), LastReceiveBuffer, tempBuffer.Count);
tempBuffer.Clear();
//수신메세지발생
RaiseRecvData();
if (remainBuffer != null && remainBuffer.Length > 0)
{
//버퍼를 변경해서 다시 전송을 해준다.
buffer = new byte[remainBuffer.Length]; // Reallocate buffer for remaining data
Array.Copy(remainBuffer, buffer, remainBuffer.Length);
goto Repeat; //남은 버퍼가 있다면 진행을 해준다.
}
}
}
else
{
Thread.Sleep(20); // Data 없음, 대기
}
}
catch (Exception ex)
{
// Thread 상에서 Exception 발생 시 로그 남기고 계속 진행 여부 결정
// 여기서는 에러 메시지 발생시키고 Sleep
ErrorMessage = ex.Message;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
Thread.Sleep(1000);
}
}
}
#endregion
#region "External Events"
/// <summary>
/// 오류 및 기타 일반 메세지
/// </summary>
public event EventHandler<MessageEventArgs> Message;
#endregion
#region "Event Args"
/// <summary>
/// 데이터를 수신할떄 사용함(RAW 포함)
/// </summary>
public class ReceiveDataEventArgs : EventArgs
{
private byte[] _buffer = null;
/// <summary>
/// 바이트배열의 버퍼값
/// </summary>
public byte[] Value { get { return _buffer; } }
/// <summary>
/// 버퍼(바이트배열)의 데이터를 문자로 반환합니다.
/// </summary>
public string StrValue
{
get
{
//return string.Empty;
if (_buffer == null || _buffer.Length < 1) return string.Empty;
else return System.Text.Encoding.Default.GetString(_buffer);
}
}
public ReceiveDataEventArgs(byte[] buffer)
{
_buffer = buffer;
}
}
/// <summary>
/// 메세지를 강제 발생
/// </summary>
/// <param name="mt"></param>
/// <param name="message"></param>
protected virtual void RaiseMessage(MessageType mt, string message)
{
this.Message?.Invoke(this, new MessageEventArgs(mt, message));
}
public enum MessageType
{
Normal,
Error,
Send,
Recv,
}
public class MessageEventArgs : EventArgs
{
public MessageType MsgType { get; set; }
private string _message = string.Empty;
/// <summary>
/// Recv,Send,Normal,Error 모두 지원
/// </summary>
public string Message { get { return _message; } }
private byte[] _data = null;
/// <summary>
/// Recv,Send에서만 값이 존재 합니다
/// </summary>
public byte[] Data { get { return _data; } }
public MessageEventArgs(string Message, bool isError = false)
{
if (isError) MsgType = MessageType.Error;
else MsgType = MessageType.Normal;
_message = Message;
}
public MessageEventArgs(MessageType msgtype, string Message)
{
MsgType = msgtype;
_message = Message;
_data = System.Text.Encoding.Default.GetBytes(Message);
}
public MessageEventArgs(byte[] buffer, bool isRecv = true)
{
if (isRecv) MsgType = MessageType.Recv;
else MsgType = MessageType.Send;
_data = new byte[buffer.Length];
Array.Copy(buffer, _data, Data.Length);
_message = System.Text.Encoding.Default.GetString(_data);
}
}
#endregion
protected abstract bool CustomParser(byte[] buf, out byte[] remainBuffer);
/// <summary>
/// 포트가 열려있거나 데이터 수신시간이 없는경우 false를 반환합니다
/// </summary>
public Boolean IsValid
{
get
{
if (IsOpen == false) return false;
if (lastRecvTime.Year == 1982) return false;
var ts = DateTime.Now - lastRecvTime;
if (ts.TotalSeconds > (this.ScanInterval * 2.5)) return false;
return true;
}
}
protected bool WriteData(string cmd)
{
return WriteData(System.Text.Encoding.Default.GetBytes(cmd));
}
/// <summary>
/// 포트에 쓰기(barcode_DataReceived 이벤트로 메세지수신)
/// </summary>
protected Boolean WriteData(byte[] data)
{
Boolean bRet = false;
//171205 : 타임아웃시간추가
if (!_mre.WaitOne(WaitTimeout))
{
ErrorMessage = $"WriteData:MRE:WaitOne:TimeOut {WaitTimeout}ms";
this.Message?.Invoke(this, new MessageEventArgs(ErrorMessage, true));
return false;
}
_mre.Reset();
//Array.Resize(ref data, data.Length + 2);
try
{
lastSendTime = DateTime.Now;
if (lastSendBuffer == null) lastSendBuffer = new byte[data.Length]; //171113
else Array.Resize(ref lastSendBuffer, data.Length);
Array.Copy(data, lastSendBuffer, data.Length);
for (int i = 0; i < data.Length; i++)
_device.Write(data, i, 1);
//_device.Write(data, 0, data.Length);
//171113
this.Message?.Invoke(this, new MessageEventArgs(data, false));
bRet = true;
WriteError = 0;
WriteErrorMessage = string.Empty;
}
catch (Exception ex)
{
// this.isinit = false;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
bRet = false;
WriteError += 1; //연속쓰기오류횟수
WriteErrorMessage = ex.Message;
}
finally
{
_mre.Set();
}
return bRet;
}
}
}

View File

@@ -24,20 +24,26 @@ namespace arDev
Charger_pos_error, Charger_pos_error,
line_out_error = 4, line_out_error = 4,
spare_5 ,
spare_6 ,
spare_7 ,
spare_8 ,
spare_9 ,
/// <summary> /// <summary>
/// 기동시 자석 감지 에러 /// 기동시 자석 감지 에러
/// </summary> /// </summary>
runerror_by_no_magent_line, runerror_by_no_magent_line=5,
/// <summary> /// <summary>
/// 호출제어기 통신 오류 /// 호출제어기 통신 오류
/// </summary> /// </summary>
controller_comm_error = 11, controller_comm_error =6,
/// <summary>
/// 배터리 저전압
/// </summary>
battery_low_voltage=7,
spare08=8,
lift_timeout=9,
lift_driver_overcurrent=10,
lift_driver_emergency = 11,
/// <summary> /// <summary>
/// 도착경보기 통신 오류 /// 도착경보기 통신 오류
/// </summary> /// </summary>

View File

@@ -4,10 +4,26 @@ namespace arDev
{ {
public partial class Narumi public partial class Narumi
{ {
public enum eSignal1
public class Signal
{ {
private COMM.Flag _value { get; set; } = new COMM.Flag(16); front_gate_out = 0,
rear_gte_out,
mark_sensor_1,
mark_sensor_2,
lift_down_sensor,
lift_up_sensor,
magnet_relay,
charger_align_sensor,
}
public enum eSignal2
{
cart_detect1 = 0,
cart_detect2,
}
public class Signal1
{
private COMM.Flag _value { get; set; } = new COMM.Flag(8);
public void SetValue(Int16 value) { this._value.writeValue(value); } public void SetValue(Int16 value) { this._value.writeValue(value); }
public UInt16 Value public UInt16 Value
{ {
@@ -16,60 +32,37 @@ namespace arDev
return (UInt16)_value.Value; return (UInt16)_value.Value;
} }
} }
public enum eflag
{
front_gate_out = 0,
rear_gte_out,
mark_sensor_1,
mark_sensor_2,
front_left_sensor,
front_right_sensor,
front_center_sensor,
charger_align_sensor,
lift_down,
lift_up,
magnet_on,
ChargetSensor,
cart_detect1,
cart_detect2,
Spare1,
Spare2
}
public bool GetValue(eflag idx) public bool GetValue(eSignal1 idx)
{ {
return _value.Get((int)idx); return _value.Get((int)idx);
} }
public bool GetChanged(eflag idx) public bool GetChanged(eSignal1 idx)
{ {
return _value.GetChanged((int)idx); return _value.GetChanged((int)idx);
} }
public Boolean front_gate_out { get { return GetValue(eflag.front_gate_out); } } public Boolean front_gate_out { get { return GetValue(eSignal1.front_gate_out); } }
public Boolean rear_sensor_out { get { return GetValue(eflag.rear_gte_out); } } public Boolean rear_sensor_out { get { return GetValue(eSignal1.rear_gte_out); } }
public Boolean mark_sensor_1 { get { return GetValue(eflag.mark_sensor_1); } } public Boolean mark_sensor_1 { get { return GetValue(eSignal1.mark_sensor_1); } }
public Boolean mark_sensor_2 { get { return GetValue(eflag.mark_sensor_2); } } public Boolean mark_sensor_2 { get { return GetValue(eSignal1.mark_sensor_2); } }
public Boolean mark_sensor { get { return mark_sensor_1 || mark_sensor_2; } } public Boolean mark_sensor { get { return mark_sensor_1 || mark_sensor_2; } }
public Boolean front_left_sensor { get { return GetValue(eflag.front_left_sensor); } } public Boolean charger_align_sensor { get { return GetValue(eSignal1.charger_align_sensor); } }
public Boolean front_right_sensor { get { return GetValue(eflag.front_right_sensor); } } public Boolean lift_up { get { return GetValue(eSignal1.lift_up_sensor); } }
public Boolean front_center_sensor { get { return GetValue(eflag.front_center_sensor); } } public Boolean lift_down { get { return GetValue(eSignal1.lift_down_sensor); } }
public Boolean charger_align_sensor { get { return GetValue(eflag.charger_align_sensor); } } public Boolean magnet_on { get { return GetValue(eSignal1.magnet_relay); } }
public Boolean lift_up { get { return GetValue(eflag.lift_up); } }
public Boolean lift_down { get { return GetValue(eflag.lift_down); } }
public Boolean magnet_on { get { return GetValue(eflag.magnet_on); } }
public Boolean cart_detect1 { get { return GetValue(eflag.cart_detect1); } }
public Boolean cart_detect2 { get { return GetValue(eflag.cart_detect2); } }
public override string ToString() public override string ToString()
{ {
//모든사태값을 탭으로 구분하여 문자를 생성한다 //모든사태값을 탭으로 구분하여 문자를 생성한다
var sb = new System.Text.StringBuilder(); var sb = new System.Text.StringBuilder();
for (int i = 0; i < 16; i++) for (int i = 0; i < 16; i++)
{ {
var def = Enum.IsDefined(typeof(eflag), i); var def = Enum.IsDefined(typeof(eSignal1), i);
if (def) if (def)
{ {
var flag = (eflag)i; var flag = (eSignal1)i;
var value = _value.Get(i); var value = _value.Get(i);
sb.AppendLine($"[{i:00}][{flag}] : {value}"); sb.AppendLine($"[{i:00}][{flag}] : {value}");
} }
@@ -86,10 +79,87 @@ namespace arDev
for (int i = 0; i < 16; i++) for (int i = 0; i < 16; i++)
{ {
var def = Enum.IsDefined(typeof(eflag), i); var def = Enum.IsDefined(typeof(eSignal1), i);
if (def) if (def)
{ {
var flag = (eflag)i; var flag = (eSignal1)i;
var value = _value.Get(i);
string line = $"[{i:00}][{flag}] : {value}";
// : true가 포함된 줄은 파란색
if (value == true)
{
sb.AppendLine(@"\cf1 " + line + @"\cf0\line");
}
else
{
sb.AppendLine(line + @"\line");
}
}
}
sb.AppendLine("}");
return sb.ToString();
}
}
public class Signal2
{
private COMM.Flag _value { get; set; } = new COMM.Flag(8);
public void SetValue(Int16 value) { this._value.writeValue(value); }
public UInt16 Value
{
get
{
return (UInt16)_value.Value;
}
}
public bool GetValue(eSignal2 idx)
{
return _value.Get((int)idx);
}
public bool GetChanged(eSignal2 idx)
{
return _value.GetChanged((int)idx);
}
public Boolean cart_detect1 { get { return GetValue(eSignal2.cart_detect1); } }
public Boolean cart_detect2 { get { return GetValue(eSignal2.cart_detect2); } }
public override string ToString()
{
//모든사태값을 탭으로 구분하여 문자를 생성한다
var sb = new System.Text.StringBuilder();
for (int i = 0; i < 16; i++)
{
var def = Enum.IsDefined(typeof(eSignal2), i);
if(def)
{
var flag = (eSignal2)i;
var value = _value.Get(i);
sb.AppendLine($"[{i:00}][{flag}] : {value}");
}
}
return sb.ToString();
}
public string ToRtfString()
{
var sb = new System.Text.StringBuilder();
sb.AppendLine(@"{\rtf1\ansi\deff0");
sb.AppendLine(@"{\colortbl ;\red0\green0\blue255;}"); // Color 1 = Blue
for (int i = 0; i < 16; i++)
{
var def = Enum.IsDefined(typeof(eSignal2), i);
if (def)
{
var flag = (eSignal2)i;
var value = _value.Get(i); var value = _value.Get(i);
string line = $"[{i:00}][{flag}] : {value}"; string line = $"[{i:00}][{flag}] : {value}";

View File

@@ -44,6 +44,7 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="Flag.cs" /> <Compile Include="Flag.cs" />
<Compile Include="ISerialComm.cs" />
<Compile Include="RS232.cs" /> <Compile Include="RS232.cs" />
<Compile Include="Var.cs" /> <Compile Include="Var.cs" />
<Compile Include="Enum.cs" /> <Compile Include="Enum.cs" />

View File

@@ -114,7 +114,7 @@ namespace COMM
WAIT_CHARGEACK, WAIT_CHARGEACK,
//agv area start ( 64 ~ 95) //agv area start ( 64 ~ 95)
DISABLE_AUTOCONN_XBEE,
//area start (96~127) //area start (96~127)

View File

@@ -0,0 +1,18 @@
using System;
namespace arDev
{
/// <summary>
/// 시리얼통신모듈의기본형태정의
/// </summary>
public interface ISerialComm
{
string PortName { get; set; }
int BaudRate { get; set; }
bool IsOpen { get; }
string ErrorMessage { get; set; }
Boolean Open();
Boolean Close();
}
}

View File

@@ -7,7 +7,8 @@ using System.Threading;
namespace arDev namespace arDev
{ {
public abstract partial class arRS232 : IDisposable
public abstract partial class arRS232 : ISerialComm, IDisposable
{ {
protected System.IO.Ports.SerialPort _device; protected System.IO.Ports.SerialPort _device;
protected ManualResetEvent _mre; protected ManualResetEvent _mre;
@@ -19,7 +20,7 @@ namespace arDev
//public int ValidCheckTimeMSec { get; set; } = 5000; //public int ValidCheckTimeMSec { get; set; } = 5000;
protected List<byte> tempBuffer = new List<byte>(); protected List<byte> tempBuffer = new List<byte>();
protected Boolean findSTX = false; protected Boolean findSTX = false;
public string errorMessage { get; set; } public string ErrorMessage { get; set; }
public DateTime LastConnTime { get; set; } public DateTime LastConnTime { get; set; }
public DateTime LastConnTryTime { get; set; } public DateTime LastConnTryTime { get; set; }
public DateTime lastSendTime; public DateTime lastSendTime;
@@ -111,7 +112,7 @@ namespace arDev
_device.ReadBufferSize = 8192; _device.ReadBufferSize = 8192;
_device.WriteBufferSize = 8192; _device.WriteBufferSize = 8192;
errorMessage = string.Empty; ErrorMessage = string.Empty;
lastRecvTime = DateTime.Parse("1982-11-23"); lastRecvTime = DateTime.Parse("1982-11-23");
LastConnTime = DateTime.Parse("1982-11-23"); LastConnTime = DateTime.Parse("1982-11-23");
LastConnTryTime = DateTime.Parse("1982-11-23"); LastConnTryTime = DateTime.Parse("1982-11-23");
@@ -164,7 +165,7 @@ namespace arDev
} }
catch (Exception ex) catch (Exception ex)
{ {
errorMessage = ex.Message; ErrorMessage = ex.Message;
Message.Invoke(this, new MessageEventArgs(ex.Message, true)); Message.Invoke(this, new MessageEventArgs(ex.Message, true));
return false; return false;
} }
@@ -191,14 +192,16 @@ namespace arDev
} }
} }
public virtual void Close(Boolean PortClose = true) public virtual bool Close()
{ {
if (_device != null && _device.IsOpen) if (_device != null && _device.IsOpen)
{ {
_device.DiscardInBuffer(); _device.DiscardInBuffer();
_device.DiscardOutBuffer(); _device.DiscardOutBuffer();
if (PortClose) _device.Close(); //dispose에서는 포트를 직접 클리어하지 않게 해뒀다. _device.Close(); //dispose에서는 포트를 직접 클리어하지 않게 해뒀다.
return true;
} }
else return false;
} }
protected Boolean RaiseRecvData() protected Boolean RaiseRecvData()
{ {
@@ -228,7 +231,7 @@ namespace arDev
if (ProcessRecvData(Data) == false) if (ProcessRecvData(Data) == false)
{ {
//Message?.Invoke(this, new MessageEventArgs(Data, true)); //recvmessage //Message?.Invoke(this, new MessageEventArgs(Data, true)); //recvmessage
Message?.Invoke(this, new MessageEventArgs(this.errorMessage, true)); //errormessage Message?.Invoke(this, new MessageEventArgs(this.ErrorMessage, true)); //errormessage
return false; return false;
} }
else else
@@ -239,7 +242,7 @@ namespace arDev
} }
catch (Exception ex) catch (Exception ex)
{ {
this.errorMessage = ex.Message; this.ErrorMessage = ex.Message;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true)); this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
return false; return false;
} }
@@ -301,7 +304,7 @@ namespace arDev
// //_device.DiscardInBuffer(); // //_device.DiscardInBuffer();
// //_device.DiscardOutBuffer(); // //_device.DiscardOutBuffer();
//} //}
errorMessage = ex.Message; ErrorMessage = ex.Message;
this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true)); this.Message?.Invoke(this, new MessageEventArgs(ex.Message, true));
} }
@@ -444,8 +447,8 @@ namespace arDev
//171205 : 타임아웃시간추가 //171205 : 타임아웃시간추가
if (!_mre.WaitOne(WaitTimeout)) if (!_mre.WaitOne(WaitTimeout))
{ {
errorMessage = $"WriteData:MRE:WaitOne:TimeOut {WaitTimeout}ms"; ErrorMessage = $"WriteData:MRE:WaitOne:TimeOut {WaitTimeout}ms";
this.Message?.Invoke(this, new MessageEventArgs(errorMessage, true)); this.Message?.Invoke(this, new MessageEventArgs(ErrorMessage, true));
return false; return false;
} }

Submodule Cs_HMI/SubProject/CommUtil updated: ed05439991...b070b711f0

Submodule Cs_HMI/SubProject/EnigProtocol updated: 2a5bb77dab...14ff055fa9

View File

@@ -29,10 +29,33 @@ namespace Test_ACS
this.rbAGV2 = new System.Windows.Forms.RadioButton(); this.rbAGV2 = new System.Windows.Forms.RadioButton();
this.rbAGV1 = new System.Windows.Forms.RadioButton(); this.rbAGV1 = new System.Windows.Forms.RadioButton();
this.grpCommands = new System.Windows.Forms.GroupBox(); this.grpCommands = new System.Windows.Forms.GroupBox();
this.button8 = new System.Windows.Forms.Button();
this.button10 = new System.Windows.Forms.Button();
this.button7 = new System.Windows.Forms.Button();
this.button9 = new System.Windows.Forms.Button();
this.groupBox2 = new System.Windows.Forms.GroupBox();
this.radSpdL = new System.Windows.Forms.RadioButton();
this.radSpdM = new System.Windows.Forms.RadioButton();
this.radSpdH = new System.Windows.Forms.RadioButton();
this.groupBox1 = new System.Windows.Forms.GroupBox(); this.groupBox1 = new System.Windows.Forms.GroupBox();
this.panel3 = new System.Windows.Forms.Panel();
this.radLidarOff = new System.Windows.Forms.RadioButton();
this.radLidarOn = new System.Windows.Forms.RadioButton();
this.button6 = new System.Windows.Forms.Button();
this.panel2 = new System.Windows.Forms.Panel();
this.radRight = new System.Windows.Forms.RadioButton();
this.radLeft = new System.Windows.Forms.RadioButton();
this.radStraight = new System.Windows.Forms.RadioButton();
this.panel1 = new System.Windows.Forms.Panel();
this.radForw = new System.Windows.Forms.RadioButton();
this.radBack = new System.Windows.Forms.RadioButton();
this.btAMove = new System.Windows.Forms.Button(); this.btAMove = new System.Windows.Forms.Button();
this.grpManual = new System.Windows.Forms.GroupBox(); this.grpManual = new System.Windows.Forms.GroupBox();
this.chkMarkStop = new System.Windows.Forms.CheckBox(); this.button5 = new System.Windows.Forms.Button();
this.button4 = new System.Windows.Forms.Button();
this.button3 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button();
this.btnMarkStop = new System.Windows.Forms.Button(); this.btnMarkStop = new System.Windows.Forms.Button();
this.btnReset = new System.Windows.Forms.Button(); this.btnReset = new System.Windows.Forms.Button();
this.btnStop = new System.Windows.Forms.Button(); this.btnStop = new System.Windows.Forms.Button();
@@ -76,26 +99,15 @@ namespace Test_ACS
this.lblRunSt = new System.Windows.Forms.Label(); this.lblRunSt = new System.Windows.Forms.Label();
this.lblModeValue = new System.Windows.Forms.Label(); this.lblModeValue = new System.Windows.Forms.Label();
this.lblMode = new System.Windows.Forms.Label(); this.lblMode = new System.Windows.Forms.Label();
this.radSpdL = new System.Windows.Forms.RadioButton(); this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
this.radSpdM = new System.Windows.Forms.RadioButton();
this.radSpdH = new System.Windows.Forms.RadioButton();
this.button1 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.button3 = new System.Windows.Forms.Button();
this.button4 = new System.Windows.Forms.Button();
this.button5 = new System.Windows.Forms.Button();
this.groupBox2 = new System.Windows.Forms.GroupBox();
this.panel1 = new System.Windows.Forms.Panel();
this.radBack = new System.Windows.Forms.RadioButton();
this.radForw = new System.Windows.Forms.RadioButton();
this.panel2 = new System.Windows.Forms.Panel();
this.radLeft = new System.Windows.Forms.RadioButton();
this.radStraight = new System.Windows.Forms.RadioButton();
this.radRight = new System.Windows.Forms.RadioButton();
this.grpConnection.SuspendLayout(); this.grpConnection.SuspendLayout();
this.grpAGV.SuspendLayout(); this.grpAGV.SuspendLayout();
this.grpCommands.SuspendLayout(); this.grpCommands.SuspendLayout();
this.groupBox2.SuspendLayout();
this.groupBox1.SuspendLayout(); this.groupBox1.SuspendLayout();
this.panel3.SuspendLayout();
this.panel2.SuspendLayout();
this.panel1.SuspendLayout();
this.grpManual.SuspendLayout(); this.grpManual.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.txtRFID)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.txtRFID)).BeginInit();
this.grpLift.SuspendLayout(); this.grpLift.SuspendLayout();
@@ -106,9 +118,7 @@ namespace Test_ACS
this.tabInfo.SuspendLayout(); this.tabInfo.SuspendLayout();
this.tabPage1.SuspendLayout(); this.tabPage1.SuspendLayout();
this.grpAGVStatus.SuspendLayout(); this.grpAGVStatus.SuspendLayout();
this.groupBox2.SuspendLayout(); this.tableLayoutPanel2.SuspendLayout();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
// grpConnection // grpConnection
@@ -121,7 +131,7 @@ namespace Test_ACS
this.grpConnection.Controls.Add(this.lblPort); this.grpConnection.Controls.Add(this.lblPort);
this.grpConnection.Location = new System.Drawing.Point(12, 12); this.grpConnection.Location = new System.Drawing.Point(12, 12);
this.grpConnection.Name = "grpConnection"; this.grpConnection.Name = "grpConnection";
this.grpConnection.Size = new System.Drawing.Size(260, 120); this.grpConnection.Size = new System.Drawing.Size(260, 82);
this.grpConnection.TabIndex = 0; this.grpConnection.TabIndex = 0;
this.grpConnection.TabStop = false; this.grpConnection.TabStop = false;
this.grpConnection.Text = "연결 설정"; this.grpConnection.Text = "연결 설정";
@@ -138,9 +148,9 @@ namespace Test_ACS
// //
// btnConnect // btnConnect
// //
this.btnConnect.Location = new System.Drawing.Point(15, 81); this.btnConnect.Location = new System.Drawing.Point(179, 53);
this.btnConnect.Name = "btnConnect"; this.btnConnect.Name = "btnConnect";
this.btnConnect.Size = new System.Drawing.Size(234, 30); this.btnConnect.Size = new System.Drawing.Size(70, 21);
this.btnConnect.TabIndex = 4; this.btnConnect.TabIndex = 4;
this.btnConnect.Text = "연결"; this.btnConnect.Text = "연결";
this.btnConnect.UseVisualStyleBackColor = true; this.btnConnect.UseVisualStyleBackColor = true;
@@ -150,7 +160,7 @@ namespace Test_ACS
// //
this.txtBaudRate.Location = new System.Drawing.Point(85, 53); this.txtBaudRate.Location = new System.Drawing.Point(85, 53);
this.txtBaudRate.Name = "txtBaudRate"; this.txtBaudRate.Name = "txtBaudRate";
this.txtBaudRate.Size = new System.Drawing.Size(164, 21); this.txtBaudRate.Size = new System.Drawing.Size(88, 21);
this.txtBaudRate.TabIndex = 3; this.txtBaudRate.TabIndex = 3;
this.txtBaudRate.Text = "9600"; this.txtBaudRate.Text = "9600";
this.txtBaudRate.TextAlign = System.Windows.Forms.HorizontalAlignment.Center; this.txtBaudRate.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
@@ -190,7 +200,7 @@ namespace Test_ACS
this.grpAGV.Controls.Add(this.rbAGV1); this.grpAGV.Controls.Add(this.rbAGV1);
this.grpAGV.Location = new System.Drawing.Point(278, 12); this.grpAGV.Location = new System.Drawing.Point(278, 12);
this.grpAGV.Name = "grpAGV"; this.grpAGV.Name = "grpAGV";
this.grpAGV.Size = new System.Drawing.Size(200, 120); this.grpAGV.Size = new System.Drawing.Size(167, 82);
this.grpAGV.TabIndex = 1; this.grpAGV.TabIndex = 1;
this.grpAGV.TabStop = false; this.grpAGV.TabStop = false;
this.grpAGV.Text = "AGV 선택"; this.grpAGV.Text = "AGV 선택";
@@ -198,7 +208,7 @@ namespace Test_ACS
// rbAGV2 // rbAGV2
// //
this.rbAGV2.AutoSize = true; this.rbAGV2.AutoSize = true;
this.rbAGV2.Location = new System.Drawing.Point(20, 60); this.rbAGV2.Location = new System.Drawing.Point(20, 51);
this.rbAGV2.Name = "rbAGV2"; this.rbAGV2.Name = "rbAGV2";
this.rbAGV2.Size = new System.Drawing.Size(95, 16); this.rbAGV2.Size = new System.Drawing.Size(95, 16);
this.rbAGV2.TabIndex = 1; this.rbAGV2.TabIndex = 1;
@@ -210,7 +220,7 @@ namespace Test_ACS
// //
this.rbAGV1.AutoSize = true; this.rbAGV1.AutoSize = true;
this.rbAGV1.Checked = true; this.rbAGV1.Checked = true;
this.rbAGV1.Location = new System.Drawing.Point(20, 30); this.rbAGV1.Location = new System.Drawing.Point(20, 21);
this.rbAGV1.Name = "rbAGV1"; this.rbAGV1.Name = "rbAGV1";
this.rbAGV1.Size = new System.Drawing.Size(95, 16); this.rbAGV1.Size = new System.Drawing.Size(95, 16);
this.rbAGV1.TabIndex = 0; this.rbAGV1.TabIndex = 0;
@@ -221,11 +231,13 @@ namespace Test_ACS
// //
// grpCommands // grpCommands
// //
this.grpCommands.Controls.Add(this.button8);
this.grpCommands.Controls.Add(this.button10);
this.grpCommands.Controls.Add(this.button7);
this.grpCommands.Controls.Add(this.button9);
this.grpCommands.Controls.Add(this.groupBox2); this.grpCommands.Controls.Add(this.groupBox2);
this.grpCommands.Controls.Add(this.groupBox1); this.grpCommands.Controls.Add(this.groupBox1);
this.grpCommands.Controls.Add(this.grpManual); this.grpCommands.Controls.Add(this.grpManual);
this.grpCommands.Controls.Add(this.chkMarkStop);
this.grpCommands.Controls.Add(this.btnMarkStop);
this.grpCommands.Controls.Add(this.btnReset); this.grpCommands.Controls.Add(this.btnReset);
this.grpCommands.Controls.Add(this.btnStop); this.grpCommands.Controls.Add(this.btnStop);
this.grpCommands.Controls.Add(this.btnGotoAlias); this.grpCommands.Controls.Add(this.btnGotoAlias);
@@ -235,30 +247,238 @@ namespace Test_ACS
this.grpCommands.Controls.Add(this.lblAlias); this.grpCommands.Controls.Add(this.lblAlias);
this.grpCommands.Controls.Add(this.txtRFID); this.grpCommands.Controls.Add(this.txtRFID);
this.grpCommands.Controls.Add(this.lblRFID); this.grpCommands.Controls.Add(this.lblRFID);
this.grpCommands.Location = new System.Drawing.Point(12, 138); this.grpCommands.Location = new System.Drawing.Point(12, 98);
this.grpCommands.Name = "grpCommands"; this.grpCommands.Name = "grpCommands";
this.grpCommands.Size = new System.Drawing.Size(466, 312); this.grpCommands.Size = new System.Drawing.Size(433, 307);
this.grpCommands.TabIndex = 2; this.grpCommands.TabIndex = 2;
this.grpCommands.TabStop = false; this.grpCommands.TabStop = false;
this.grpCommands.Text = "ACS 명령"; this.grpCommands.Text = "ACS 명령";
// //
// button8
//
this.button8.Location = new System.Drawing.Point(102, 264);
this.button8.Name = "button8";
this.button8.Size = new System.Drawing.Size(93, 35);
this.button8.TabIndex = 14;
this.button8.Text = "RT180";
this.button8.UseVisualStyleBackColor = true;
this.button8.Click += new System.EventHandler(this.button8_Click);
//
// button10
//
this.button10.Location = new System.Drawing.Point(102, 229);
this.button10.Name = "button10";
this.button10.Size = new System.Drawing.Size(93, 35);
this.button10.TabIndex = 16;
this.button10.Text = "R-turn";
this.button10.UseVisualStyleBackColor = true;
this.button10.Click += new System.EventHandler(this.button10_Click);
//
// button7
//
this.button7.Location = new System.Drawing.Point(15, 264);
this.button7.Name = "button7";
this.button7.Size = new System.Drawing.Size(85, 35);
this.button7.TabIndex = 13;
this.button7.Text = "LT180";
this.button7.UseVisualStyleBackColor = true;
this.button7.Click += new System.EventHandler(this.button7_Click);
//
// button9
//
this.button9.Location = new System.Drawing.Point(15, 228);
this.button9.Name = "button9";
this.button9.Size = new System.Drawing.Size(85, 35);
this.button9.TabIndex = 15;
this.button9.Text = "L-Turn";
this.button9.UseVisualStyleBackColor = true;
this.button9.Click += new System.EventHandler(this.button9_Click);
//
// groupBox2
//
this.groupBox2.Controls.Add(this.radSpdL);
this.groupBox2.Controls.Add(this.radSpdM);
this.groupBox2.Controls.Add(this.radSpdH);
this.groupBox2.Location = new System.Drawing.Point(146, 117);
this.groupBox2.Name = "groupBox2";
this.groupBox2.Size = new System.Drawing.Size(49, 106);
this.groupBox2.TabIndex = 12;
this.groupBox2.TabStop = false;
this.groupBox2.Text = "속도";
this.groupBox2.Enter += new System.EventHandler(this.groupBox2_Enter);
//
// radSpdL
//
this.radSpdL.AutoSize = true;
this.radSpdL.Location = new System.Drawing.Point(9, 20);
this.radSpdL.Name = "radSpdL";
this.radSpdL.Size = new System.Drawing.Size(30, 16);
this.radSpdL.TabIndex = 7;
this.radSpdL.TabStop = true;
this.radSpdL.Tag = "0";
this.radSpdL.Text = "L";
this.radSpdL.UseVisualStyleBackColor = true;
//
// radSpdM
//
this.radSpdM.AutoSize = true;
this.radSpdM.Location = new System.Drawing.Point(9, 47);
this.radSpdM.Name = "radSpdM";
this.radSpdM.Size = new System.Drawing.Size(34, 16);
this.radSpdM.TabIndex = 7;
this.radSpdM.TabStop = true;
this.radSpdM.Tag = "1";
this.radSpdM.Text = "M";
this.radSpdM.UseVisualStyleBackColor = true;
//
// radSpdH
//
this.radSpdH.AutoSize = true;
this.radSpdH.Location = new System.Drawing.Point(9, 74);
this.radSpdH.Name = "radSpdH";
this.radSpdH.Size = new System.Drawing.Size(31, 16);
this.radSpdH.TabIndex = 7;
this.radSpdH.TabStop = true;
this.radSpdH.Tag = "2";
this.radSpdH.Text = "H";
this.radSpdH.UseVisualStyleBackColor = true;
//
// groupBox1 // groupBox1
// //
this.groupBox1.Controls.Add(this.panel3);
this.groupBox1.Controls.Add(this.button6);
this.groupBox1.Controls.Add(this.panel2); this.groupBox1.Controls.Add(this.panel2);
this.groupBox1.Controls.Add(this.panel1); this.groupBox1.Controls.Add(this.panel1);
this.groupBox1.Controls.Add(this.btAMove); this.groupBox1.Controls.Add(this.btAMove);
this.groupBox1.Location = new System.Drawing.Point(201, 153); this.groupBox1.Controls.Add(this.btnMarkStop);
this.groupBox1.Location = new System.Drawing.Point(201, 117);
this.groupBox1.Name = "groupBox1"; this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(244, 106); this.groupBox1.Size = new System.Drawing.Size(225, 183);
this.groupBox1.TabIndex = 8; this.groupBox1.TabIndex = 8;
this.groupBox1.TabStop = false; this.groupBox1.TabStop = false;
this.groupBox1.Text = "자동 이동"; this.groupBox1.Text = "자동 이동";
// //
// panel3
//
this.panel3.Controls.Add(this.radLidarOff);
this.panel3.Controls.Add(this.radLidarOn);
this.panel3.Location = new System.Drawing.Point(10, 98);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(139, 33);
this.panel3.TabIndex = 12;
//
// radLidarOff
//
this.radLidarOff.AutoSize = true;
this.radLidarOff.Location = new System.Drawing.Point(60, 9);
this.radLidarOff.Name = "radLidarOff";
this.radLidarOff.Size = new System.Drawing.Size(38, 16);
this.radLidarOff.TabIndex = 0;
this.radLidarOff.Text = "Off";
this.radLidarOff.UseVisualStyleBackColor = true;
//
// radLidarOn
//
this.radLidarOn.AutoSize = true;
this.radLidarOn.Checked = true;
this.radLidarOn.Location = new System.Drawing.Point(12, 9);
this.radLidarOn.Name = "radLidarOn";
this.radLidarOn.Size = new System.Drawing.Size(39, 16);
this.radLidarOn.TabIndex = 0;
this.radLidarOn.TabStop = true;
this.radLidarOn.Tag = "On";
this.radLidarOn.Text = "On";
this.radLidarOn.UseVisualStyleBackColor = true;
//
// button6
//
this.button6.Location = new System.Drawing.Point(155, 94);
this.button6.Name = "button6";
this.button6.Size = new System.Drawing.Size(65, 83);
this.button6.TabIndex = 12;
this.button6.Text = "정지";
this.button6.UseVisualStyleBackColor = true;
this.button6.Click += new System.EventHandler(this.button6_Click);
//
// panel2
//
this.panel2.Controls.Add(this.radRight);
this.panel2.Controls.Add(this.radLeft);
this.panel2.Controls.Add(this.radStraight);
this.panel2.Location = new System.Drawing.Point(10, 59);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(139, 33);
this.panel2.TabIndex = 11;
//
// radRight
//
this.radRight.AutoSize = true;
this.radRight.Location = new System.Drawing.Point(93, 9);
this.radRight.Name = "radRight";
this.radRight.Size = new System.Drawing.Size(31, 16);
this.radRight.TabIndex = 1;
this.radRight.TabStop = true;
this.radRight.Text = "R";
this.radRight.UseVisualStyleBackColor = true;
//
// radLeft
//
this.radLeft.AutoSize = true;
this.radLeft.Location = new System.Drawing.Point(51, 9);
this.radLeft.Name = "radLeft";
this.radLeft.Size = new System.Drawing.Size(30, 16);
this.radLeft.TabIndex = 0;
this.radLeft.TabStop = true;
this.radLeft.Text = "L";
this.radLeft.UseVisualStyleBackColor = true;
//
// radStraight
//
this.radStraight.AutoSize = true;
this.radStraight.Location = new System.Drawing.Point(12, 9);
this.radStraight.Name = "radStraight";
this.radStraight.Size = new System.Drawing.Size(31, 16);
this.radStraight.TabIndex = 0;
this.radStraight.TabStop = true;
this.radStraight.Text = "S";
this.radStraight.UseVisualStyleBackColor = true;
//
// panel1
//
this.panel1.Controls.Add(this.radForw);
this.panel1.Controls.Add(this.radBack);
this.panel1.Location = new System.Drawing.Point(10, 20);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(139, 33);
this.panel1.TabIndex = 10;
//
// radForw
//
this.radForw.AutoSize = true;
this.radForw.Location = new System.Drawing.Point(51, 9);
this.radForw.Name = "radForw";
this.radForw.Size = new System.Drawing.Size(30, 16);
this.radForw.TabIndex = 0;
this.radForw.TabStop = true;
this.radForw.Text = "F";
this.radForw.UseVisualStyleBackColor = true;
//
// radBack
//
this.radBack.AutoSize = true;
this.radBack.Location = new System.Drawing.Point(12, 9);
this.radBack.Name = "radBack";
this.radBack.Size = new System.Drawing.Size(31, 16);
this.radBack.TabIndex = 0;
this.radBack.TabStop = true;
this.radBack.Text = "B";
this.radBack.UseVisualStyleBackColor = true;
//
// btAMove // btAMove
// //
this.btAMove.Location = new System.Drawing.Point(155, 16); this.btAMove.Location = new System.Drawing.Point(155, 16);
this.btAMove.Name = "btAMove"; this.btAMove.Name = "btAMove";
this.btAMove.Size = new System.Drawing.Size(81, 76); this.btAMove.Size = new System.Drawing.Size(65, 76);
this.btAMove.TabIndex = 6; this.btAMove.TabIndex = 6;
this.btAMove.Text = "실행"; this.btAMove.Text = "실행";
this.btAMove.UseVisualStyleBackColor = true; this.btAMove.UseVisualStyleBackColor = true;
@@ -271,30 +491,75 @@ namespace Test_ACS
this.grpManual.Controls.Add(this.button3); this.grpManual.Controls.Add(this.button3);
this.grpManual.Controls.Add(this.button2); this.grpManual.Controls.Add(this.button2);
this.grpManual.Controls.Add(this.button1); this.grpManual.Controls.Add(this.button1);
this.grpManual.Location = new System.Drawing.Point(15, 153); this.grpManual.Location = new System.Drawing.Point(15, 117);
this.grpManual.Name = "grpManual"; this.grpManual.Name = "grpManual";
this.grpManual.Size = new System.Drawing.Size(125, 106); this.grpManual.Size = new System.Drawing.Size(125, 106);
this.grpManual.TabIndex = 8; this.grpManual.TabIndex = 8;
this.grpManual.TabStop = false; this.grpManual.TabStop = false;
this.grpManual.Text = "수동 이동"; this.grpManual.Text = "수동 이동";
// //
// chkMarkStop // button5
// //
this.chkMarkStop.AutoSize = true; this.button5.Location = new System.Drawing.Point(43, 72);
this.chkMarkStop.Location = new System.Drawing.Point(193, 125); this.button5.Name = "button5";
this.chkMarkStop.Name = "chkMarkStop"; this.button5.Size = new System.Drawing.Size(34, 27);
this.chkMarkStop.Size = new System.Drawing.Size(76, 16); this.button5.TabIndex = 12;
this.chkMarkStop.TabIndex = 7; this.button5.Tag = "1";
this.chkMarkStop.Text = "정지 설정"; this.button5.Text = "F";
this.chkMarkStop.UseVisualStyleBackColor = true; this.button5.UseVisualStyleBackColor = true;
this.button5.Click += new System.EventHandler(this.btnManual_Click);
//
// button4
//
this.button4.Location = new System.Drawing.Point(81, 44);
this.button4.Name = "button4";
this.button4.Size = new System.Drawing.Size(34, 27);
this.button4.TabIndex = 11;
this.button4.Tag = "3";
this.button4.Text = "R";
this.button4.UseVisualStyleBackColor = true;
this.button4.Click += new System.EventHandler(this.btnManual_Click);
//
// button3
//
this.button3.Location = new System.Drawing.Point(8, 44);
this.button3.Name = "button3";
this.button3.Size = new System.Drawing.Size(34, 27);
this.button3.TabIndex = 10;
this.button3.Tag = "2";
this.button3.Text = "L";
this.button3.UseVisualStyleBackColor = true;
this.button3.Click += new System.EventHandler(this.btnManual_Click);
//
// button2
//
this.button2.Location = new System.Drawing.Point(43, 44);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(34, 27);
this.button2.TabIndex = 9;
this.button2.Tag = "S";
this.button2.Text = "S";
this.button2.UseVisualStyleBackColor = true;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// button1
//
this.button1.Location = new System.Drawing.Point(43, 14);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(34, 27);
this.button1.TabIndex = 8;
this.button1.Tag = "0";
this.button1.Text = "B";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.btnManual_Click);
// //
// btnMarkStop // btnMarkStop
// //
this.btnMarkStop.Location = new System.Drawing.Point(10, 117); this.btnMarkStop.Location = new System.Drawing.Point(10, 137);
this.btnMarkStop.Name = "btnMarkStop"; this.btnMarkStop.Name = "btnMarkStop";
this.btnMarkStop.Size = new System.Drawing.Size(177, 30); this.btnMarkStop.Size = new System.Drawing.Size(139, 40);
this.btnMarkStop.TabIndex = 6; this.btnMarkStop.TabIndex = 6;
this.btnMarkStop.Text = "마크센서 정지"; this.btnMarkStop.Text = "마크 정지";
this.btnMarkStop.UseVisualStyleBackColor = true; this.btnMarkStop.UseVisualStyleBackColor = true;
this.btnMarkStop.Click += new System.EventHandler(this.btnMarkStop_Click); this.btnMarkStop.Click += new System.EventHandler(this.btnMarkStop_Click);
// //
@@ -399,21 +664,20 @@ namespace Test_ACS
// //
// grpLift // grpLift
// //
this.grpLift.Controls.Add(this.btnLiftStop); this.grpLift.Controls.Add(this.tableLayoutPanel2);
this.grpLift.Controls.Add(this.btnLiftDown); this.grpLift.Location = new System.Drawing.Point(12, 535);
this.grpLift.Controls.Add(this.btnLiftUp);
this.grpLift.Location = new System.Drawing.Point(298, 456);
this.grpLift.Name = "grpLift"; this.grpLift.Name = "grpLift";
this.grpLift.Size = new System.Drawing.Size(180, 120); this.grpLift.Size = new System.Drawing.Size(433, 79);
this.grpLift.TabIndex = 9; this.grpLift.TabIndex = 9;
this.grpLift.TabStop = false; this.grpLift.TabStop = false;
this.grpLift.Text = "리프트 제어"; this.grpLift.Text = "리프트 제어";
// //
// btnLiftStop // btnLiftStop
// //
this.btnLiftStop.Location = new System.Drawing.Point(121, 20); this.btnLiftStop.Dock = System.Windows.Forms.DockStyle.Fill;
this.btnLiftStop.Location = new System.Drawing.Point(287, 3);
this.btnLiftStop.Name = "btnLiftStop"; this.btnLiftStop.Name = "btnLiftStop";
this.btnLiftStop.Size = new System.Drawing.Size(48, 90); this.btnLiftStop.Size = new System.Drawing.Size(137, 53);
this.btnLiftStop.TabIndex = 2; this.btnLiftStop.TabIndex = 2;
this.btnLiftStop.Text = "정지"; this.btnLiftStop.Text = "정지";
this.btnLiftStop.UseVisualStyleBackColor = true; this.btnLiftStop.UseVisualStyleBackColor = true;
@@ -421,9 +685,10 @@ namespace Test_ACS
// //
// btnLiftDown // btnLiftDown
// //
this.btnLiftDown.Location = new System.Drawing.Point(65, 20); this.btnLiftDown.Dock = System.Windows.Forms.DockStyle.Fill;
this.btnLiftDown.Location = new System.Drawing.Point(145, 3);
this.btnLiftDown.Name = "btnLiftDown"; this.btnLiftDown.Name = "btnLiftDown";
this.btnLiftDown.Size = new System.Drawing.Size(48, 90); this.btnLiftDown.Size = new System.Drawing.Size(136, 53);
this.btnLiftDown.TabIndex = 1; this.btnLiftDown.TabIndex = 1;
this.btnLiftDown.Text = "하강"; this.btnLiftDown.Text = "하강";
this.btnLiftDown.UseVisualStyleBackColor = true; this.btnLiftDown.UseVisualStyleBackColor = true;
@@ -431,9 +696,10 @@ namespace Test_ACS
// //
// btnLiftUp // btnLiftUp
// //
this.btnLiftUp.Location = new System.Drawing.Point(9, 20); this.btnLiftUp.Dock = System.Windows.Forms.DockStyle.Fill;
this.btnLiftUp.Location = new System.Drawing.Point(3, 3);
this.btnLiftUp.Name = "btnLiftUp"; this.btnLiftUp.Name = "btnLiftUp";
this.btnLiftUp.Size = new System.Drawing.Size(48, 90); this.btnLiftUp.Size = new System.Drawing.Size(136, 53);
this.btnLiftUp.TabIndex = 0; this.btnLiftUp.TabIndex = 0;
this.btnLiftUp.Text = "상승"; this.btnLiftUp.Text = "상승";
this.btnLiftUp.UseVisualStyleBackColor = true; this.btnLiftUp.UseVisualStyleBackColor = true;
@@ -451,9 +717,9 @@ namespace Test_ACS
// grpLogs // grpLogs
// //
this.grpLogs.Controls.Add(this.tabLogs); this.grpLogs.Controls.Add(this.tabLogs);
this.grpLogs.Location = new System.Drawing.Point(484, 12); this.grpLogs.Location = new System.Drawing.Point(451, 12);
this.grpLogs.Name = "grpLogs"; this.grpLogs.Name = "grpLogs";
this.grpLogs.Size = new System.Drawing.Size(520, 564); this.grpLogs.Size = new System.Drawing.Size(520, 602);
this.grpLogs.TabIndex = 3; this.grpLogs.TabIndex = 3;
this.grpLogs.TabStop = false; this.grpLogs.TabStop = false;
this.grpLogs.Text = "로그"; this.grpLogs.Text = "로그";
@@ -467,7 +733,7 @@ namespace Test_ACS
this.tabLogs.Location = new System.Drawing.Point(3, 17); this.tabLogs.Location = new System.Drawing.Point(3, 17);
this.tabLogs.Name = "tabLogs"; this.tabLogs.Name = "tabLogs";
this.tabLogs.SelectedIndex = 0; this.tabLogs.SelectedIndex = 0;
this.tabLogs.Size = new System.Drawing.Size(514, 544); this.tabLogs.Size = new System.Drawing.Size(514, 582);
this.tabLogs.TabIndex = 0; this.tabLogs.TabIndex = 0;
// //
// tabRX // tabRX
@@ -476,7 +742,7 @@ namespace Test_ACS
this.tabRX.Location = new System.Drawing.Point(4, 22); this.tabRX.Location = new System.Drawing.Point(4, 22);
this.tabRX.Name = "tabRX"; this.tabRX.Name = "tabRX";
this.tabRX.Padding = new System.Windows.Forms.Padding(3); this.tabRX.Padding = new System.Windows.Forms.Padding(3);
this.tabRX.Size = new System.Drawing.Size(506, 518); this.tabRX.Size = new System.Drawing.Size(506, 556);
this.tabRX.TabIndex = 1; this.tabRX.TabIndex = 1;
this.tabRX.Text = "패킷"; this.tabRX.Text = "패킷";
this.tabRX.UseVisualStyleBackColor = true; this.tabRX.UseVisualStyleBackColor = true;
@@ -497,19 +763,19 @@ namespace Test_ACS
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20F)); this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F)); this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.tableLayoutPanel1.Size = new System.Drawing.Size(500, 512); this.tableLayoutPanel1.Size = new System.Drawing.Size(500, 550);
this.tableLayoutPanel1.TabIndex = 1; this.tableLayoutPanel1.TabIndex = 1;
// //
// txtRxLog // txtRxLog
// //
this.txtRxLog.Dock = System.Windows.Forms.DockStyle.Fill; this.txtRxLog.Dock = System.Windows.Forms.DockStyle.Fill;
this.txtRxLog.Font = new System.Drawing.Font("Consolas", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.txtRxLog.Font = new System.Drawing.Font("Consolas", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.txtRxLog.Location = new System.Drawing.Point(3, 279); this.txtRxLog.Location = new System.Drawing.Point(3, 298);
this.txtRxLog.Multiline = true; this.txtRxLog.Multiline = true;
this.txtRxLog.Name = "txtRxLog"; this.txtRxLog.Name = "txtRxLog";
this.txtRxLog.ReadOnly = true; this.txtRxLog.ReadOnly = true;
this.txtRxLog.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; this.txtRxLog.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
this.txtRxLog.Size = new System.Drawing.Size(494, 230); this.txtRxLog.Size = new System.Drawing.Size(494, 249);
this.txtRxLog.TabIndex = 0; this.txtRxLog.TabIndex = 0;
this.txtRxLog.Text = "1"; this.txtRxLog.Text = "1";
// //
@@ -522,7 +788,7 @@ namespace Test_ACS
this.txtTxLog.Name = "txtTxLog"; this.txtTxLog.Name = "txtTxLog";
this.txtTxLog.ReadOnly = true; this.txtTxLog.ReadOnly = true;
this.txtTxLog.ScrollBars = System.Windows.Forms.ScrollBars.Vertical; this.txtTxLog.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
this.txtTxLog.Size = new System.Drawing.Size(494, 230); this.txtTxLog.Size = new System.Drawing.Size(494, 249);
this.txtTxLog.TabIndex = 0; this.txtTxLog.TabIndex = 0;
// //
// label1 // label1
@@ -538,7 +804,7 @@ namespace Test_ACS
// label2 // label2
// //
this.label2.Dock = System.Windows.Forms.DockStyle.Fill; this.label2.Dock = System.Windows.Forms.DockStyle.Fill;
this.label2.Location = new System.Drawing.Point(3, 256); this.label2.Location = new System.Drawing.Point(3, 275);
this.label2.Name = "label2"; this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(494, 20); this.label2.Size = new System.Drawing.Size(494, 20);
this.label2.TabIndex = 1; this.label2.TabIndex = 1;
@@ -607,9 +873,9 @@ namespace Test_ACS
this.grpAGVStatus.Controls.Add(this.lblRunSt); this.grpAGVStatus.Controls.Add(this.lblRunSt);
this.grpAGVStatus.Controls.Add(this.lblModeValue); this.grpAGVStatus.Controls.Add(this.lblModeValue);
this.grpAGVStatus.Controls.Add(this.lblMode); this.grpAGVStatus.Controls.Add(this.lblMode);
this.grpAGVStatus.Location = new System.Drawing.Point(12, 456); this.grpAGVStatus.Location = new System.Drawing.Point(12, 409);
this.grpAGVStatus.Name = "grpAGVStatus"; this.grpAGVStatus.Name = "grpAGVStatus";
this.grpAGVStatus.Size = new System.Drawing.Size(280, 120); this.grpAGVStatus.Size = new System.Drawing.Size(433, 120);
this.grpAGVStatus.TabIndex = 4; this.grpAGVStatus.TabIndex = 4;
this.grpAGVStatus.TabStop = false; this.grpAGVStatus.TabStop = false;
this.grpAGVStatus.Text = "AGV 상태"; this.grpAGVStatus.Text = "AGV 상태";
@@ -757,189 +1023,28 @@ namespace Test_ACS
this.lblMode.TabIndex = 0; this.lblMode.TabIndex = 0;
this.lblMode.Text = "모드:"; this.lblMode.Text = "모드:";
// //
// radSpdL // tableLayoutPanel2
// //
this.radSpdL.AutoSize = true; this.tableLayoutPanel2.ColumnCount = 3;
this.radSpdL.Location = new System.Drawing.Point(9, 20); this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.radSpdL.Name = "radSpdL"; this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.radSpdL.Size = new System.Drawing.Size(30, 16); this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 33.33333F));
this.radSpdL.TabIndex = 7; this.tableLayoutPanel2.Controls.Add(this.btnLiftStop, 2, 0);
this.radSpdL.TabStop = true; this.tableLayoutPanel2.Controls.Add(this.btnLiftUp, 0, 0);
this.radSpdL.Tag = "0"; this.tableLayoutPanel2.Controls.Add(this.btnLiftDown, 1, 0);
this.radSpdL.Text = "L"; this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.radSpdL.UseVisualStyleBackColor = true; this.tableLayoutPanel2.Location = new System.Drawing.Point(3, 17);
// this.tableLayoutPanel2.Name = "tableLayoutPanel2";
// radSpdM this.tableLayoutPanel2.RowCount = 1;
// this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
this.radSpdM.AutoSize = true; this.tableLayoutPanel2.Size = new System.Drawing.Size(427, 59);
this.radSpdM.Location = new System.Drawing.Point(9, 47); this.tableLayoutPanel2.TabIndex = 0;
this.radSpdM.Name = "radSpdM";
this.radSpdM.Size = new System.Drawing.Size(34, 16);
this.radSpdM.TabIndex = 7;
this.radSpdM.TabStop = true;
this.radSpdM.Tag = "1";
this.radSpdM.Text = "M";
this.radSpdM.UseVisualStyleBackColor = true;
//
// radSpdH
//
this.radSpdH.AutoSize = true;
this.radSpdH.Location = new System.Drawing.Point(9, 74);
this.radSpdH.Name = "radSpdH";
this.radSpdH.Size = new System.Drawing.Size(31, 16);
this.radSpdH.TabIndex = 7;
this.radSpdH.TabStop = true;
this.radSpdH.Tag = "2";
this.radSpdH.Text = "H";
this.radSpdH.UseVisualStyleBackColor = true;
//
// button1
//
this.button1.Location = new System.Drawing.Point(43, 14);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(34, 27);
this.button1.TabIndex = 8;
this.button1.Tag = "0";
this.button1.Text = "B";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.btnManual_Click);
//
// button2
//
this.button2.Location = new System.Drawing.Point(43, 44);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(34, 27);
this.button2.TabIndex = 9;
this.button2.Tag = "S";
this.button2.Text = "S";
this.button2.UseVisualStyleBackColor = true;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// button3
//
this.button3.Location = new System.Drawing.Point(8, 44);
this.button3.Name = "button3";
this.button3.Size = new System.Drawing.Size(34, 27);
this.button3.TabIndex = 10;
this.button3.Tag = "2";
this.button3.Text = "L";
this.button3.UseVisualStyleBackColor = true;
this.button3.Click += new System.EventHandler(this.btnManual_Click);
//
// button4
//
this.button4.Location = new System.Drawing.Point(81, 44);
this.button4.Name = "button4";
this.button4.Size = new System.Drawing.Size(34, 27);
this.button4.TabIndex = 11;
this.button4.Tag = "3";
this.button4.Text = "R";
this.button4.UseVisualStyleBackColor = true;
this.button4.Click += new System.EventHandler(this.btnManual_Click);
//
// button5
//
this.button5.Location = new System.Drawing.Point(43, 72);
this.button5.Name = "button5";
this.button5.Size = new System.Drawing.Size(34, 27);
this.button5.TabIndex = 12;
this.button5.Tag = "1";
this.button5.Text = "F";
this.button5.UseVisualStyleBackColor = true;
this.button5.Click += new System.EventHandler(this.btnManual_Click);
//
// groupBox2
//
this.groupBox2.Controls.Add(this.radSpdL);
this.groupBox2.Controls.Add(this.radSpdM);
this.groupBox2.Controls.Add(this.radSpdH);
this.groupBox2.Location = new System.Drawing.Point(146, 153);
this.groupBox2.Name = "groupBox2";
this.groupBox2.Size = new System.Drawing.Size(49, 106);
this.groupBox2.TabIndex = 12;
this.groupBox2.TabStop = false;
this.groupBox2.Text = "속도";
this.groupBox2.Enter += new System.EventHandler(this.groupBox2_Enter);
//
// panel1
//
this.panel1.Controls.Add(this.radForw);
this.panel1.Controls.Add(this.radBack);
this.panel1.Location = new System.Drawing.Point(10, 20);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(139, 33);
this.panel1.TabIndex = 10;
//
// radBack
//
this.radBack.AutoSize = true;
this.radBack.Location = new System.Drawing.Point(12, 9);
this.radBack.Name = "radBack";
this.radBack.Size = new System.Drawing.Size(31, 16);
this.radBack.TabIndex = 0;
this.radBack.TabStop = true;
this.radBack.Text = "B";
this.radBack.UseVisualStyleBackColor = true;
//
// radForw
//
this.radForw.AutoSize = true;
this.radForw.Location = new System.Drawing.Point(51, 9);
this.radForw.Name = "radForw";
this.radForw.Size = new System.Drawing.Size(30, 16);
this.radForw.TabIndex = 0;
this.radForw.TabStop = true;
this.radForw.Text = "F";
this.radForw.UseVisualStyleBackColor = true;
//
// panel2
//
this.panel2.Controls.Add(this.radRight);
this.panel2.Controls.Add(this.radLeft);
this.panel2.Controls.Add(this.radStraight);
this.panel2.Location = new System.Drawing.Point(10, 59);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(139, 33);
this.panel2.TabIndex = 11;
//
// radLeft
//
this.radLeft.AutoSize = true;
this.radLeft.Location = new System.Drawing.Point(51, 9);
this.radLeft.Name = "radLeft";
this.radLeft.Size = new System.Drawing.Size(30, 16);
this.radLeft.TabIndex = 0;
this.radLeft.TabStop = true;
this.radLeft.Text = "L";
this.radLeft.UseVisualStyleBackColor = true;
//
// radStraight
//
this.radStraight.AutoSize = true;
this.radStraight.Location = new System.Drawing.Point(12, 9);
this.radStraight.Name = "radStraight";
this.radStraight.Size = new System.Drawing.Size(31, 16);
this.radStraight.TabIndex = 0;
this.radStraight.TabStop = true;
this.radStraight.Text = "S";
this.radStraight.UseVisualStyleBackColor = true;
//
// radRight
//
this.radRight.AutoSize = true;
this.radRight.Location = new System.Drawing.Point(93, 9);
this.radRight.Name = "radRight";
this.radRight.Size = new System.Drawing.Size(31, 16);
this.radRight.TabIndex = 1;
this.radRight.TabStop = true;
this.radRight.Text = "R";
this.radRight.UseVisualStyleBackColor = true;
// //
// MainForm // MainForm
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1016, 585); this.ClientSize = new System.Drawing.Size(979, 621);
this.Controls.Add(this.grpLift); this.Controls.Add(this.grpLift);
this.Controls.Add(this.grpAGVStatus); this.Controls.Add(this.grpAGVStatus);
this.Controls.Add(this.grpLogs); this.Controls.Add(this.grpLogs);
@@ -957,7 +1062,15 @@ namespace Test_ACS
this.grpAGV.PerformLayout(); this.grpAGV.PerformLayout();
this.grpCommands.ResumeLayout(false); this.grpCommands.ResumeLayout(false);
this.grpCommands.PerformLayout(); this.grpCommands.PerformLayout();
this.groupBox2.ResumeLayout(false);
this.groupBox2.PerformLayout();
this.groupBox1.ResumeLayout(false); this.groupBox1.ResumeLayout(false);
this.panel3.ResumeLayout(false);
this.panel3.PerformLayout();
this.panel2.ResumeLayout(false);
this.panel2.PerformLayout();
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.grpManual.ResumeLayout(false); this.grpManual.ResumeLayout(false);
((System.ComponentModel.ISupportInitialize)(this.txtRFID)).EndInit(); ((System.ComponentModel.ISupportInitialize)(this.txtRFID)).EndInit();
this.grpLift.ResumeLayout(false); this.grpLift.ResumeLayout(false);
@@ -971,12 +1084,7 @@ namespace Test_ACS
this.tabPage1.ResumeLayout(false); this.tabPage1.ResumeLayout(false);
this.grpAGVStatus.ResumeLayout(false); this.grpAGVStatus.ResumeLayout(false);
this.grpAGVStatus.PerformLayout(); this.grpAGVStatus.PerformLayout();
this.groupBox2.ResumeLayout(false); this.tableLayoutPanel2.ResumeLayout(false);
this.groupBox2.PerformLayout();
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.panel2.ResumeLayout(false);
this.panel2.PerformLayout();
this.ResumeLayout(false); this.ResumeLayout(false);
} }
@@ -1000,7 +1108,6 @@ namespace Test_ACS
private System.Windows.Forms.Button btnStop; private System.Windows.Forms.Button btnStop;
private System.Windows.Forms.Button btnReset; private System.Windows.Forms.Button btnReset;
private System.Windows.Forms.Button btnMarkStop; private System.Windows.Forms.Button btnMarkStop;
private System.Windows.Forms.CheckBox chkMarkStop;
private System.Windows.Forms.GroupBox grpManual; private System.Windows.Forms.GroupBox grpManual;
private System.Windows.Forms.GroupBox grpLift; private System.Windows.Forms.GroupBox grpLift;
private System.Windows.Forms.Button btnLiftStop; private System.Windows.Forms.Button btnLiftStop;
@@ -1057,5 +1164,14 @@ namespace Test_ACS
private System.Windows.Forms.RadioButton radStraight; private System.Windows.Forms.RadioButton radStraight;
private System.Windows.Forms.RadioButton radForw; private System.Windows.Forms.RadioButton radForw;
private System.Windows.Forms.RadioButton radBack; private System.Windows.Forms.RadioButton radBack;
private System.Windows.Forms.Button button6;
private System.Windows.Forms.Button button8;
private System.Windows.Forms.Button button7;
private System.Windows.Forms.Button button9;
private System.Windows.Forms.Button button10;
private System.Windows.Forms.Panel panel3;
private System.Windows.Forms.RadioButton radLidarOff;
private System.Windows.Forms.RadioButton radLidarOn;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
} }
} }

View File

@@ -61,6 +61,14 @@ namespace Test_ACS
case AGVCommandEH.Status: case AGVCommandEH.Status:
UpdateAGVStatus(e.ReceivedPacket.Data); UpdateAGVStatus(e.ReceivedPacket.Data);
break; break;
case AGVCommandEH.Error:
var errorcode = (AGVErrorCode)e.ReceivedPacket.Data[0];
var errorMessage = System.Text.Encoding.UTF8.GetString(e.ReceivedPacket.Data, 1, e.ReceivedPacket.Data.Length - 1);
AddLog($"Error Received : {errorcode} ID:{e.ReceivedPacket.ID} MSG:{errorMessage}", LogType.Info);
break;
default:
AddLog($"unknown command:{command}", LogType.Error);
break;
} }
} }
@@ -153,6 +161,7 @@ namespace Test_ACS
serialPort.Close(); serialPort.Close();
btnConnect.Text = "연결"; btnConnect.Text = "연결";
AddLog("포트 닫힘", LogType.Info); AddLog("포트 닫힘", LogType.Info);
} }
else else
{ {
@@ -163,6 +172,7 @@ namespace Test_ACS
serialPort.Open(); serialPort.Open();
btnConnect.Text = "해제"; btnConnect.Text = "해제";
AddLog($"{serialPort.PortName}:{serialPort.BaudRate} 연결됨", LogType.Info); AddLog($"{serialPort.PortName}:{serialPort.BaudRate} 연결됨", LogType.Info);
SaveSettings();
} }
catch (Exception ex) catch (Exception ex)
{ {
@@ -178,22 +188,22 @@ namespace Test_ACS
private void cmbPort_SelectedIndexChanged(object sender, EventArgs e) private void cmbPort_SelectedIndexChanged(object sender, EventArgs e)
{ {
SaveSettings(); //SaveSettings();
} }
private void txtBaudRate_TextChanged(object sender, EventArgs e) private void txtBaudRate_TextChanged(object sender, EventArgs e)
{ {
SaveSettings(); //SaveSettings();
} }
private void txtRFID_TextChanged(object sender, EventArgs e) private void txtRFID_TextChanged(object sender, EventArgs e)
{ {
SaveSettings(); //SaveSettings();
} }
private void txtAlias_TextChanged(object sender, EventArgs e) private void txtAlias_TextChanged(object sender, EventArgs e)
{ {
SaveSettings(); //SaveSettings();
} }
private void rbAGV1_CheckedChanged(object sender, EventArgs e) private void rbAGV1_CheckedChanged(object sender, EventArgs e)
@@ -201,7 +211,7 @@ namespace Test_ACS
if (rbAGV1.Checked) if (rbAGV1.Checked)
{ {
selectedAGV = 11; selectedAGV = 11;
SaveSettings(); //SaveSettings();
} }
} }
@@ -210,7 +220,7 @@ namespace Test_ACS
if (rbAGV2.Checked) if (rbAGV2.Checked)
{ {
selectedAGV = 12; selectedAGV = 12;
SaveSettings(); //SaveSettings();
} }
} }
@@ -250,6 +260,7 @@ namespace Test_ACS
var aliasHex = string.Join("", aliasBytes.Select(b => b.ToString("X2"))); var aliasHex = string.Join("", aliasBytes.Select(b => b.ToString("X2")));
var dataStr = targetID + aliasHex; var dataStr = targetID + aliasHex;
SendCommand(AGVCommandHE.GotoAlias, dataStr); SendCommand(AGVCommandHE.GotoAlias, dataStr);
SaveSettings();
} }
private void btnStop_Click(object sender, EventArgs e) private void btnStop_Click(object sender, EventArgs e)
@@ -288,7 +299,7 @@ namespace Test_ACS
{ {
// MarkStop: data = TargetID(2 hex) + MarkStop(1 byte) // MarkStop: data = TargetID(2 hex) + MarkStop(1 byte)
var targetID = selectedAGV.ToString("X2"); var targetID = selectedAGV.ToString("X2");
var markStop = chkMarkStop.Checked ? "01" : "00"; var markStop = "01";// chkMarkStop.Checked ? "01" : "00";
SendCommand(AGVCommandHE.MarkStop, targetID + markStop); SendCommand(AGVCommandHE.MarkStop, targetID + markStop);
} }
@@ -524,9 +535,6 @@ namespace Test_ACS
protected override void OnFormClosing(FormClosingEventArgs e) protected override void OnFormClosing(FormClosingEventArgs e)
{ {
// 설정 저장
SaveSettings();
if (serialPort != null && serialPort.IsOpen) if (serialPort != null && serialPort.IsOpen)
{ {
serialPort.Close(); serialPort.Close();
@@ -548,7 +556,10 @@ namespace Test_ACS
if (radSpdM.Checked) speed = 1; if (radSpdM.Checked) speed = 1;
else if (radSpdH.Checked) speed = 2; else if (radSpdH.Checked) speed = 2;
var dataBytes = new byte[] { Motdirection, Magdirection, speed }; byte lidar = 2;
if (radLidarOff.Checked) lidar = 0;
var dataBytes = new byte[] { Motdirection, Magdirection, speed ,lidar};
var dataStr = targetID + string.Join("", dataBytes.Select(b => b.ToString("X2"))); var dataStr = targetID + string.Join("", dataBytes.Select(b => b.ToString("X2")));
SendCommand(AGVCommandHE.AutoMove, dataStr); SendCommand(AGVCommandHE.AutoMove, dataStr);
} }
@@ -564,5 +575,39 @@ namespace Test_ACS
{ {
} }
private void button6_Click(object sender, EventArgs e)
{
var targetID = selectedAGV.ToString("X2");
SendCommand(AGVCommandHE.Stop, targetID);
}
private void button7_Click(object sender, EventArgs e)
{
//lt180
var targetID = selectedAGV.ToString("X2");
SendCommand(AGVCommandHE.LTurn180, targetID);
}
private void button8_Click(object sender, EventArgs e)
{
//rt180
var targetID = selectedAGV.ToString("X2");
SendCommand(AGVCommandHE.RTurn180, targetID);
}
private void button9_Click(object sender, EventArgs e)
{
//l turn
var targetID = selectedAGV.ToString("X2");
SendCommand(AGVCommandHE.LTurn, targetID);
}
private void button10_Click(object sender, EventArgs e)
{
///r-turn
var targetID = selectedAGV.ToString("X2");
SendCommand(AGVCommandHE.RTurn, targetID);
}
} }
} }

View File

@@ -18,7 +18,7 @@
<DebugSymbols>true</DebugSymbols> <DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>..\..\..\..\..\..\Amkor\AGV4\Test\</OutputPath> <OutputPath>..\..\..\..\..\..\Amkor\AGV4\Test\ACS\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants> <DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>

View File

@@ -38,7 +38,7 @@ namespace Test_BMS
private void Bms_Message(object sender, arDev.arRS232.MessageEventArgs e) private void Bms_Message(object sender, arDev.BMSSerialComm.MessageEventArgs e)
{ {
var sb = new System.Text.StringBuilder(); var sb = new System.Text.StringBuilder();
if (e.Data != null) if (e.Data != null)
@@ -48,13 +48,13 @@ namespace Test_BMS
} }
else sb.Append(e.Message); else sb.Append(e.Message);
if (e.MsgType == arDev.arRS232.MessageType.Error) if (e.MsgType == arDev.BMSSerialComm.MessageType.Error)
addmsg(e.Message); addmsg(e.Message);
else if(e.MsgType == arDev.arRS232.MessageType.Send) else if(e.MsgType == arDev.BMSSerialComm.MessageType.Send)
{ {
addmsg($"Tx:{sb}"); addmsg($"Tx:{sb}");
} }
else if(e.MsgType == arDev.arRS232.MessageType.Recv) else if(e.MsgType == arDev.BMSSerialComm.MessageType.Recv)
{ {
addmsg($"Rx:{sb}"); addmsg($"Rx:{sb}");
} }

View File

@@ -56,6 +56,9 @@
<Compile Include="..\..\Project\Device\BMSInformationEventArgs.cs"> <Compile Include="..\..\Project\Device\BMSInformationEventArgs.cs">
<Link>BMSInformationEventArgs.cs</Link> <Link>BMSInformationEventArgs.cs</Link>
</Compile> </Compile>
<Compile Include="..\..\Project\Device\BMSSerialComm.cs">
<Link>BMSSerialComm.cs</Link>
</Compile>
<Compile Include="Form1.cs"> <Compile Include="Form1.cs">
<SubType>Form</SubType> <SubType>Form</SubType>
</Compile> </Compile>

View File

@@ -31,7 +31,7 @@ namespace Test_BMS
log2.Flush(); log2.Flush();
} }
private void Dev_Message(object sender, arDev.arRS232.MessageEventArgs e) private void Dev_Message(object sender, arDev.NarumiSerialComm.MessageEventArgs e)
{ {
addmsg(e.MsgType.ToString(), e.Message);// $"{e.MsgType}:{e.Message}"); addmsg(e.MsgType.ToString(), e.Message);// $"{e.MsgType}:{e.Message}");
} }
@@ -53,7 +53,7 @@ namespace Test_BMS
this.rt0.Text = $"system0-{dev.system0.Value:X2}\n" + dev.system0.ToString(); this.rt0.Text = $"system0-{dev.system0.Value:X2}\n" + dev.system0.ToString();
this.rt1.Text = $"system1-{dev.system1.Value:X2}\n" + dev.system1.ToString(); this.rt1.Text = $"system1-{dev.system1.Value:X2}\n" + dev.system1.ToString();
this.rt2.Text = $"error-{dev.error.Value:X2}\n" + dev.error.ToString(); this.rt2.Text = $"error-{dev.error.Value:X2}\n" + dev.error.ToString();
this.rt3.Text = $"iosignal-{dev.signal.Value:X2}\n" + dev.signal.ToString() + "data\n" + dev.data.ToString(); this.rt3.Text = $"iosignal-{dev.signal1.Value:X2}\n" + dev.signal1.ToString() + "data\n" + dev.data.ToString();
//this.rt4.Text = "data\n" + dev.data.ToString(); //this.rt4.Text = "data\n" + dev.data.ToString();

View File

@@ -18,7 +18,7 @@
<DebugSymbols>true</DebugSymbols> <DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>..\..\..\..\..\..\Amkor\AGV4\Test\</OutputPath> <OutputPath>..\..\..\..\..\..\Amkor\AGV4\Test\AGV\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants> <DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
@@ -36,7 +36,7 @@
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="arControl.Net4"> <Reference Include="arControl.Net4">
<HintPath>..\Sub\arCtl\obj\Debug\arControl.Net4.dll</HintPath> <HintPath>..\..\DLL\arControl.Net4.dll</HintPath>
</Reference> </Reference>
<Reference Include="ArLog.Net4"> <Reference Include="ArLog.Net4">
<HintPath>..\..\DLL\ArLog.Net4.dll</HintPath> <HintPath>..\..\DLL\ArLog.Net4.dll</HintPath>

View File

@@ -18,7 +18,7 @@
<DebugSymbols>true</DebugSymbols> <DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>..\..\..\..\..\..\Amkor\AGV4\Test\</OutputPath> <OutputPath>..\..\..\..\..\..\Amkor\AGV4\Test\PortScan\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants> <DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,218 @@
:0400000015EF06F002
:08000800046ED8CF05F0E0CF33
:1000100006F00001E9CF0CF0EACF07F0E1CF08F0DD
:10002000E2CF09F0D9CF0AF0DACF0BF0F3CF12F01C
:10003000F4CF13F0FACF14F0F5CF15F0F6CF16F099
:10004000F7CF17F000C00EF001C00FF002C010F0A3
:1000500003C011F09DAA30EF00F09EBA75EF00F0DA
:1000600076A036EF00F077B0F3EF00F076A23CEF29
:1000700000F077B2EFEF00F09DA042EF00F09EB0ED
:100080009DEF00F076AA48EF00F077BAE9EF00F0B4
:1000900076AE4EEF00F077BEE6EF00F00EC000F057
:1000A0000FC001F010C002F011C003F00CC0E9FF56
:1000B00007C0EAFF078E08C0E1FF09C0E2FF0AC0DF
:1000C000D9FF0BC0DAFF12C0F3FF13C0F4FF14C056
:1000D000FAFF15C0F5FF16C0F6FF17C0F7FF045072
:1000E00006C0E0FF05C0D8FF10009EAAFED7AECF25
:1000F00001F1010120A006D0013D03D0466A476A04
:10010000209005D0472C03D0070E0125466E47509E
:10011000472A036A480FE96E000E0320EA6E01C108
:10012000EFFF4650475C01E1208247501D0801E285
:10013000476A9E9A00014EEF00F0D80ECF6EF00E87
:10014000CE6E252AD8B4262A275202E128520BE087
:100150002750D8B42806272E06D0285204E1286A52
:10016000960E276E1F86422AD8B4432A43500608AB
:1001700007E2FF0A03E14250D00802E2819C1F8E91
:10018000292AD8B42A2A2A5203E12950450803E231
:100190002A6A296A1F80212A21500908D8B013D061
:1001A000216A222A22500908D8B00DD0226A232AB7
:1001B00023500908D8B007D0236A242A24503B08CA
:1001C000D8B001D0246A9E904EEF00F0779E4EEF9B
:1001D00000F0819C1F8E769A779A4EEF00F01F8C6C
:1001E00077924EEF00F01F8C77904EEF00F0E339DE
:1001F000700B006ED89000361F0E6F1400106F6EDB
:100200006ECF00F0003A0030070BE35DF9E1120019
:10021000C00E0E0143150309436F3F0E4315436F94
:10022000F80E44150209446FC70E44151809446FAF
:10023000449D448FF80E45150109456F459D000109
:10024000BEEF01F0F5C0FCF0F4C0FBF0FA5352E051
:10025000FBC0E9FFFCC0EAFFF6C0EFFFFB51D8B4DA
:10026000FC07FB07FBC0E9FFFCC0EAFFF7C0EFFF9C
:10027000FB51D8B4FC07FB07FBC0E9FFFCC0EAFF59
:10028000F851030BEF6EFBC0E9FFFCC0EAFFF8C0BA
:1002900000F0003600360036F80E00160050E00B75
:1002A000EF10EF6EFBC0E9FFFCC0EAFFEF5008095A
:1002B000EF6EFB51D8B4FC07FB07FBC0E9FFFCC0A5
:1002C000EAFFF8C000F0003A0032070E00160050B6
:1002D000070BEF6EFBC0E9FFFCC0EAFFF9C000F0BE
:1002E000003600360036F80E00160050F80BEF10FE
:1002F000EF6E3FD0FBC0E9FFFCC0EAFFEF6AFB51A5
:10030000D8B4FC07FB07FBC0E9FFFCC0EAFFEF6ABB
:10031000FB51D8B4FC07FB07FBC0E9FFFCC0EAFFB8
:10032000F6C000F0003A0036E00E00160050E00B78
:10033000EF6EFB51D8B4FC07FB07FBC0E9FFFCC024
:10034000EAFFF6C000F00032003200321F0E001645
:1003500000501F0BEF6EFBC0E9FFFCC0EAFFF7C0C7
:1003600000F0003A0036E00E00160050E00BEF10EF
:10037000EF6E1200040EE36F3ADF4AD7606A9F0EF9
:100380006014606E608460CF10FF709A70980E0EDB
:10039000F56FFB0EF46FF96BF86BF76BF66BFA6B9E
:1003A00051DF0E0EF56FE30EF46FF96BF86BF76B20
:1003B000F66BFA6B47DF0E0EF56FE70EF46FF96B15
:1003C000F86BF76BF66BFA6B3DDF0E0EF56FF469A9
:1003D000F96BF86BF76BF66BFA6B34DF0E0EF56F9B
:1003E000EB0EF46FF96BF86BF76BF66BFA6B2ADFB9
:1003F0000E0EF56FEF0EF46FF96BF86BF76BF66B93
:10040000FA6B20DF0E0EF56FF30EF46FF96BF86BDD
:10041000F76BF66BFA6B16DF0E0EF56FF70EF46FD7
:10042000F96BF86BF76BF66BFA6B0CDF9350FB0B09
:100430000809936EE36BDBDE4CEF02F0266A256A57
:100440002650E55D04E3FCE1E451255CF9E312008C
:10045000D36A400E9B6E646AF29CF29EF2BEFDD798
:100460009D909D9A769A76927690000E926E3B0EB3
:10047000936E800E946E806A816A826A819C819EEE
:100480003E6A3D6A3C6A280E3B6E3F903F92070EE3
:10049000406E010E416E6ED7070ECD6EAA6AD80E61
:1004A000CF6EF00ECE6E1F6A206A3E6A3D6A3C6ACD
:1004B000280E3B6E436A426A456A446A9D8A9D8063
:1004C00076827680768AC00EF212E56BC80EE46FF3
:1004D000B5DF8288818C818E9BEF06F09EA8FED7C7
:1004E000AD6E8BEF02F0819C20802092466A476AB5
:1004F000E66BE4C0E9FFE5C0EAFFEF50E65D0DE220
:10050000010EE625E425E96E000EE521EA6EEFCF47
:10051000E7F0E751E3D7E62BECD71200E7C0EDF0A8
:10052000E6C0ECF0EA5302E1EB5325E0E9C003F04A
:10053000E8C0E9FFE9C0EAFFEF521DE0EDC0EFF0CF
:10054000EC51EC2BD8B4ED2BEE6FE9C003F0E85181
:10055000E82BD8B4E92BE96E03C0EAFFEFCFF0F047
:10056000EFC0EAFFEEC0E9FFF0C0EFFFEA51D8B4F8
:10057000EB07EA07D7D7EA5302E1EB530FE0EDC0F0
:1005800003F0EC51EC2BD8B4ED2BE96E03C0EAFF7D
:10059000EF6AEA51D8B4EB07EA07EDD7E6C001F0FD
:1005A000E7C002F01200266A256A2650000811E210
:1005B000FF0A03E125502C080CE2442AD8B4452A4E
:1005C000455203E14450050801E21F92000E016EFE
:1005D00030D020A2EAD7483C01D003D0000E016EF3
:1005E00028D0030EE425E96E000EE521EA6EEF50F7
:1005F0004A5C03E0000E016E1CD0818C4A50210839
:1006000016E14B5211E14C520FE11F84A10E676FAE
:10061000E76B680EE66FE96B4D0EE86FEB6B060E4D
:10062000EA6F7CDF6E6B03D0010E016E02D0010E0B
:10063000016E12001F92E56B860EE46F54DFE56BCE
:10064000860EE46FB0DF015203E1000E016E44D06C
:10065000E56B910EE46F47DFE56B910EE46FA3DF6E
:10066000015203E1000E016E37D0E56BA70EE46F77
:100670003ADFE56BA70EE46F96DF015203E1000E4F
:10068000016E2AD0E56BB20EE46F2DDFE56BB20E82
:10069000E46F89DF015203E1000E016E1DD0E56BAE
:1006A0009C0EE46F20DFE56B9C0EE46F7CDF015253
:1006B00003E1000E016E10D0E56BBD0EE46F13DF99
:1006C000E56BBD0EE46F6FDF015203E1000E016EBA
:1006D00003D01F82010E016E12001FA215D0E76B1E
:1006E000670EE66FE96BD30EE86FEB6B070EEA6FF0
:1006F00015DFE76B6E0EE66FE96BD30EE86FEB6B01
:10070000070EEA6F0BDF14D0E76B670EE66FE96B3D
:10071000DB0EE86FEB6B070EEA6F00DFE76B6E0E28
:10072000E66FE96BDB0EE86FEB6B070EEA6FF6DE48
:100730002A6A296A1F801200819E7CDF2A6A296A40
:10074000246A24C023F023C022F022C021F0C5DF98
:10075000030E286EE80E276E1F9E1F9A818E04EFEF
:1007600006F01F96E56BC80EE46FBDDEE56BC80EA4
:10077000E46F19DF015204E0010E016E03D002D0D4
:10078000000E016E09EF06F00F0EF26F660EF16FAC
:100790000F0120B708D0F10E6F1408096F6E000129
:1007A000F36B1BD00F0110B709D0F10E6F140609BF
:1007B0006F6E010E0001F36F10D00F0100B709D06A
:1007C000F10E6F1404096F6E020E0001F36F05D075
:1007D0000F01000E016E3BD00001ED51030B006EC6
:1007E000FC0E60140010606E0F0EF56F640EF46F57
:1007F000E9C0F9F0E8C0F8F0E7C0F7F0E6C0F6F0BD
:10080000EEC0FAF01FDDECC065FF659CEFB1658CB2
:10081000F06BEC51F05D14E2EAC0E9FFEBC0EAFFD7
:10082000EFCFF6F0F2C0EAFFF1C0E9FFF6C0EFFF4C
:10083000F12BD8B4F22BEA2BD8B4EB2BF02BE9D761
:100840006086F10E6F146F6E010E016E0F010001D4
:100850004CEF04F00F0120A704D010A702D000B77E
:100860001CD01F90000E3FB2010E0001E46F000E7D
:100870003FB0010EE56FE96BE86BE76B280EE66FA2
:10088000EB6B670EEA6F40C0ECF041C0EDF0E4C0E6
:10089000EEF0E5C0EFF078D70F0100011200E36B36
:1008A0002A6A296A1F90E56BC80EE46FC7DDC2DEB5
:1008B00014DF1FB0CFDF1FB206D0E32BE3510508D2
:1008C00001E2FF00F0D7286A960E276E0BEF06F0C4
:1008D000F56BF46BF36BF26BF0C0F7F0EFC0F6F072
:1008E000F153D8B489D0F6C0E9FFF7C0EAFFF56B41
:1008F000F46BF36BEFCFF2F0F651D8B4F707F607CD
:10090000F6C0E9FFF7C0EAFFEF50FA6BF96BF86F3A
:10091000006A0050F213F851F313F951F413FA512D
:10092000F513F651D8B4F707F607F6C0E9FFF7C09C
:10093000EAFFEF50FB6BFA6BF96BF86F030EF817D9
:10094000F96BFA6BFB6B006A016A0050F2130150FD
:10095000F313F851F413F951F513F6C0E9FFF7C09A
:10096000EAFFEF50FB6BFA6BF96BF86FE00EF817CC
:10097000F96BFA6BFB6B006AF835016EF935026EA4
:10098000FA35036E01360236033601360236033677
:10099000013602360336013602360336E00E011602
:1009A0000050F2130150F3130250F4130350F513E7
:1009B000F651D8B4F707F607F6C0E9FFF7C0EAFF2B
:1009C000EF50F96BF86F006A016AF835026EF9357D
:1009D000036E02360336023603360236033602361B
:1009E0000336E00E02160050F2130150F3130250CA
:1009F000F4130350F51353D0020EF65F000EF75BAD
:100A0000F6C0E9FFF7C0EAFFEF50FB6BFA6BF96B3A
:100A1000F86FE00EF817F96BFA6BFB6BFB31F56FB3
:100A2000FA31F46FF931F36FF831F26FF533F433D3
:100A3000F333F233F533F433F333F233F533F43382
:100A4000F333F233F533F433F333F233070EF517A0
:100A5000F651D8B4F707F607F6C0E9FFF7C0EAFF8A
:100A6000EF50FB6BFA6BF96BF86FF835006EF935E8
:100A7000016EFA35026EFB35036E00360136023622
:100A800003360036013602360336F80E00160050E3
:100A9000F2130150F3130250F4130350F513F2C094
:100AA00000F0F3C001F0F4C002F0F5C003F0A6EFCF
:100AB00005F01F9CE46B320EE36F60AE17D0F10EB1
:100AC0006F146F6E2D98A4902D9071BE2D80719E25
:100AD00060A40BD0000E60B0010E070B006ED89022
:100AE0000036F10E2D1400102D6E1CD00F0110AF2A
:100AF00015D0F10E6F140A096F6E2D88A4922D90F7
:100B000071BC2D80719C1051070B070B006ED890A3
:100B10000036F10E2D1400102D6E03D0000E016E64
:100B20004AD0000165500F0B3A6E2D9A65BC2D8A94
:100B30002D9C62B62D8C000E2DBC010EE86F0F0EA1
:100B4000F06F640EEF6FE8C0F1F0C2D603C031F071
:100B500002C030F001C02FF000C02EF00F0EE76F82
:100B6000660EE66FE56B3A50E55D14E2E6C0E9FF1C
:100B7000E7C0EAFFEFCFEAF0E4C0EAFFE3C0E9FF35
:100B8000EAC0EFFFE32BD8B4E42BE62BD8B4E72B75
:100B9000E52BE9D7F10E6F146F6E2D9EA4BE2D8E3E
:100BA000A49E2DA804D00F01109F03D00001609EC9
:100BB0000F01010E016E015223E0436A426A2E507A
:100BC0000A081EE12F521CE130521AE1315218E19D
:100BD000325053080BE13350590808E134505308A0
:100BE00005E11F8A000179DD0AD00F013250280883
:100BF00007E13350530804E11F8A00016EDD0F0145
:100C000000010FEF06F098D51FA204D01FA601D057
:100C1000A8D501D044D61FB01DDE1FBC4AD71FAED9
:100C200001D0FF00F1D79CEF06F0F86AD09E078E46
:100C30003E0E006E0F0E016E020EE96E000EEA6EA1
:100C4000EE6A002EFDD7012EFBD7A786560EAF6E9B
:100C5000000E7D6EA60EAC6E900EAB6E3E6A3D6AC7
:100C60003C6A280E3B6E3F903F92070E406E030E8B
:100C7000416E0F015C51800B5C6F000E5D6FC19681
:100C8000C198C19A5E6B5F6B34D0020019000012EC
:100C9000008609FF04060001C200A4600006FF01EF
:100CA00097094BB404C000478007FF029201F4404B
:100CB000AD00000007FF02930005517D0000000811
:100CC000FF039102010142C500000AFF0522000056
:100CD0001300642A8907FF022100FAD61B000000D6
:100CE000C75354532D4F4B00C75354532D4E4700F9
:100CF0000000000EF86E0C0EF76E8A0EF66E0900FC
:100D0000F550006E000A13E00900F550016EE8BED0
:100D100005D00F0BEA6E0900F5CFE9FF01BC090011
:100D200001AC0900F5CFEEFF004EE9D7F9D7F86A1C
:0A0D3000000128EF02F067D703006E
:020000040030CA
:0E00000015127E7C0009910000800FE00F4079
:00000001FF
;PIC18F26K80
;CRC=2FAE CREATED="27-11-24 15:30"

View File

@@ -0,0 +1,218 @@
:0400000015EF06F002
:08000800046ED8CF05F0E0CF33
:1000100006F00001E9CF0CF0EACF07F0E1CF08F0DD
:10002000E2CF09F0D9CF0AF0DACF0BF0F3CF12F01C
:10003000F4CF13F0FACF14F0F5CF15F0F6CF16F099
:10004000F7CF17F000C00EF001C00FF002C010F0A3
:1000500003C011F09DAA30EF00F09EBA75EF00F0DA
:1000600076A036EF00F077B0F3EF00F076A23CEF29
:1000700000F077B2EFEF00F09DA042EF00F09EB0ED
:100080009DEF00F076AA48EF00F077BAE9EF00F0B4
:1000900076AE4EEF00F077BEE6EF00F00EC000F057
:1000A0000FC001F010C002F011C003F00CC0E9FF56
:1000B00007C0EAFF078E08C0E1FF09C0E2FF0AC0DF
:1000C000D9FF0BC0DAFF12C0F3FF13C0F4FF14C056
:1000D000FAFF15C0F5FF16C0F6FF17C0F7FF045072
:1000E00006C0E0FF05C0D8FF10009EAAFED7AECF25
:1000F00001F1010120A006D0013D03D0466A476A04
:10010000209005D0472C03D0070E0125466E47509E
:10011000472A036A480FE96E000E0320EA6E01C108
:10012000EFFF4650475C01E1208247501D0801E285
:10013000476A9E9A00014EEF00F0D80ECF6EF00E87
:10014000CE6E252AD8B4262A275202E128520BE087
:100150002750D8B42806272E06D0285204E1286A52
:10016000960E276E1F86422AD8B4432A43500608AB
:1001700007E2FF0A03E14250D00802E2819C1F8E91
:10018000292AD8B42A2A2A5203E12950450803E231
:100190002A6A296A1F80212A21500908D8B013D061
:1001A000216A222A22500908D8B00DD0226A232AB7
:1001B00023500908D8B007D0236A242A24503B08CA
:1001C000D8B001D0246A9E904EEF00F0779E4EEF9B
:1001D00000F0819C1F8E769A779A4EEF00F01F8C6C
:1001E00077924EEF00F01F8C77904EEF00F0E339DE
:1001F000700B006ED89000361F0E6F1400106F6EDB
:100200006ECF00F0003A0030070BE35DF9E1120019
:10021000C00E0E0143150309436F3F0E4315436F94
:10022000F80E44150209446FC70E44151809446FAF
:10023000449D448FF80E45150109456F459D000109
:10024000BEEF01F0F5C0FCF0F4C0FBF0FA5352E051
:10025000FBC0E9FFFCC0EAFFF6C0EFFFFB51D8B4DA
:10026000FC07FB07FBC0E9FFFCC0EAFFF7C0EFFF9C
:10027000FB51D8B4FC07FB07FBC0E9FFFCC0EAFF59
:10028000F851030BEF6EFBC0E9FFFCC0EAFFF8C0BA
:1002900000F0003600360036F80E00160050E00B75
:1002A000EF10EF6EFBC0E9FFFCC0EAFFEF5008095A
:1002B000EF6EFB51D8B4FC07FB07FBC0E9FFFCC0A5
:1002C000EAFFF8C000F0003A0032070E00160050B6
:1002D000070BEF6EFBC0E9FFFCC0EAFFF9C000F0BE
:1002E000003600360036F80E00160050F80BEF10FE
:1002F000EF6E3FD0FBC0E9FFFCC0EAFFEF6AFB51A5
:10030000D8B4FC07FB07FBC0E9FFFCC0EAFFEF6ABB
:10031000FB51D8B4FC07FB07FBC0E9FFFCC0EAFFB8
:10032000F6C000F0003A0036E00E00160050E00B78
:10033000EF6EFB51D8B4FC07FB07FBC0E9FFFCC024
:10034000EAFFF6C000F00032003200321F0E001645
:1003500000501F0BEF6EFBC0E9FFFCC0EAFFF7C0C7
:1003600000F0003A0036E00E00160050E00BEF10EF
:10037000EF6E1200040EE36F3ADF4AD7606A9F0EF9
:100380006014606E608460CF10FF709A70980E0EDB
:10039000F56FFB0EF46FF96BF86BF76BF66BFA6B9E
:1003A00051DF0E0EF56FE30EF46FF96BF86BF76B20
:1003B000F66BFA6B47DF0E0EF56FE70EF46FF96B15
:1003C000F86BF76BF66BFA6B3DDF0E0EF56FF469A9
:1003D000F96BF86BF76BF66BFA6B34DF0E0EF56F9B
:1003E000EB0EF46FF96BF86BF76BF66BFA6B2ADFB9
:1003F0000E0EF56FEF0EF46FF96BF86BF76BF66B93
:10040000FA6B20DF0E0EF56FF30EF46FF96BF86BDD
:10041000F76BF66BFA6B16DF0E0EF56FF70EF46FD7
:10042000F96BF86BF76BF66BFA6B0CDF9350FB0B09
:100430000809936EE36BDBDE4CEF02F0266A256A57
:100440002650E55D04E3FCE1E451255CF9E312008C
:10045000D36A400E9B6E646AF29CF29EF2BEFDD798
:100460009D909D9A769A76927690000E926E3B0EB3
:10047000936E800E946E806A816A826A819C819EEE
:100480003E6A3D6A3C6A280E3B6E3F903F92070EE3
:10049000406E010E416E6ED7070ECD6EAA6AD80E61
:1004A000CF6EF00ECE6E1F6A206A3E6A3D6A3C6ACD
:1004B000280E3B6E436A426A456A446A9D8A9D8063
:1004C00076827680768AC00EF212E56BC80EE46FF3
:1004D000B5DF8288818C818E9BEF06F09EA8FED7C7
:1004E000AD6E8BEF02F0819C20802092466A476AB5
:1004F000E66BE4C0E9FFE5C0EAFFEF50E65D0DE220
:10050000010EE625E425E96E000EE521EA6EEFCF47
:10051000E7F0E751E3D7E62BECD71200E7C0EDF0A8
:10052000E6C0ECF0EA5302E1EB5325E0E9C003F04A
:10053000E8C0E9FFE9C0EAFFEF521DE0EDC0EFF0CF
:10054000EC51EC2BD8B4ED2BEE6FE9C003F0E85181
:10055000E82BD8B4E92BE96E03C0EAFFEFCFF0F047
:10056000EFC0EAFFEEC0E9FFF0C0EFFFEA51D8B4F8
:10057000EB07EA07D7D7EA5302E1EB530FE0EDC0F0
:1005800003F0EC51EC2BD8B4ED2BE96E03C0EAFF7D
:10059000EF6AEA51D8B4EB07EA07EDD7E6C001F0FD
:1005A000E7C002F01200266A256A2650000811E210
:1005B000FF0A03E125502C080CE2442AD8B4452A4E
:1005C000455203E14450050801E21F92000E016EFE
:1005D00030D020A2EAD7483C01D003D0000E016EF3
:1005E00028D0030EE425E96E000EE521EA6EEF50F7
:1005F0004A5C03E0000E016E1CD0818C4A50210839
:1006000016E14B5211E14C520FE11F84A10E676FAE
:10061000E76B680EE66FE96B4D0EE86FEB6B060E4D
:10062000EA6F7CDF6E6B03D0010E016E02D0010E0B
:10063000016E12001F92E56B860EE46F54DFE56BCE
:10064000860EE46FB0DF015203E1000E016E44D06C
:10065000E56B910EE46F47DFE56B910EE46FA3DF6E
:10066000015203E1000E016E37D0E56BA70EE46F77
:100670003ADFE56BA70EE46F96DF015203E1000E4F
:10068000016E2AD0E56BB20EE46F2DDFE56BB20E82
:10069000E46F89DF015203E1000E016E1DD0E56BAE
:1006A0009C0EE46F20DFE56B9C0EE46F7CDF015253
:1006B00003E1000E016E10D0E56BBD0EE46F13DF99
:1006C000E56BBD0EE46F6FDF015203E1000E016EBA
:1006D00003D01F82010E016E12001FA215D0E76B1E
:1006E000670EE66FE96BD30EE86FEB6B070EEA6FF0
:1006F00015DFE76B6E0EE66FE96BD30EE86FEB6B01
:10070000070EEA6F0BDF14D0E76B670EE66FE96B3D
:10071000DB0EE86FEB6B070EEA6F00DFE76B6E0E28
:10072000E66FE96BDB0EE86FEB6B070EEA6FF6DE48
:100730002A6A296A1F801200819E7CDF2A6A296A40
:10074000246A24C023F023C022F022C021F0C5DF98
:10075000030E286EE80E276E1F9E1F9A818E04EFEF
:1007600006F01F96E56BC80EE46FBDDEE56BC80EA4
:10077000E46F19DF015204E0010E016E03D002D0D4
:10078000000E016E09EF06F00F0EF26F660EF16FAC
:100790000F0120B708D0F10E6F1408096F6E000129
:1007A000F36B1BD00F0110B709D0F10E6F140609BF
:1007B0006F6E010E0001F36F10D00F0100B709D06A
:1007C000F10E6F1404096F6E020E0001F36F05D075
:1007D0000F01000E016E3BD00001ED51030B006EC6
:1007E000FC0E60140010606E0F0EF56F640EF46F57
:1007F000E9C0F9F0E8C0F8F0E7C0F7F0E6C0F6F0BD
:10080000EEC0FAF01FDDECC065FF659CEFB1658CB2
:10081000F06BEC51F05D14E2EAC0E9FFEBC0EAFFD7
:10082000EFCFF6F0F2C0EAFFF1C0E9FFF6C0EFFF4C
:10083000F12BD8B4F22BEA2BD8B4EB2BF02BE9D761
:100840006086F10E6F146F6E010E016E0F010001D4
:100850004CEF04F00F0120A704D010A702D000B77E
:100860001CD01F90000E3FB2010E0001E46F000E7D
:100870003FB0010EE56FE96BE86BE76B280EE66FA2
:10088000EB6B670EEA6F40C0ECF041C0EDF0E4C0E6
:10089000EEF0E5C0EFF078D70F0100011200E36B36
:1008A0002A6A296A1F90E56BC80EE46FC7DDC2DEB5
:1008B00014DF1FB0CFDF1FB206D0E32BE3510508D2
:1008C00001E2FF00F0D7286A960E276E0BEF06F0C4
:1008D000F56BF46BF36BF26BF0C0F7F0EFC0F6F072
:1008E000F153D8B489D0F6C0E9FFF7C0EAFFF56B41
:1008F000F46BF36BEFCFF2F0F651D8B4F707F607CD
:10090000F6C0E9FFF7C0EAFFEF50FA6BF96BF86F3A
:10091000006A0050F213F851F313F951F413FA512D
:10092000F513F651D8B4F707F607F6C0E9FFF7C09C
:10093000EAFFEF50FB6BFA6BF96BF86F030EF817D9
:10094000F96BFA6BFB6B006A016A0050F2130150FD
:10095000F313F851F413F951F513F6C0E9FFF7C09A
:10096000EAFFEF50FB6BFA6BF96BF86FE00EF817CC
:10097000F96BFA6BFB6B006AF835016EF935026EA4
:10098000FA35036E01360236033601360236033677
:10099000013602360336013602360336E00E011602
:1009A0000050F2130150F3130250F4130350F513E7
:1009B000F651D8B4F707F607F6C0E9FFF7C0EAFF2B
:1009C000EF50F96BF86F006A016AF835026EF9357D
:1009D000036E02360336023603360236033602361B
:1009E0000336E00E02160050F2130150F3130250CA
:1009F000F4130350F51353D0020EF65F000EF75BAD
:100A0000F6C0E9FFF7C0EAFFEF50FB6BFA6BF96B3A
:100A1000F86FE00EF817F96BFA6BFB6BFB31F56FB3
:100A2000FA31F46FF931F36FF831F26FF533F433D3
:100A3000F333F233F533F433F333F233F533F43382
:100A4000F333F233F533F433F333F233070EF517A0
:100A5000F651D8B4F707F607F6C0E9FFF7C0EAFF8A
:100A6000EF50FB6BFA6BF96BF86FF835006EF935E8
:100A7000016EFA35026EFB35036E00360136023622
:100A800003360036013602360336F80E00160050E3
:100A9000F2130150F3130250F4130350F513F2C094
:100AA00000F0F3C001F0F4C002F0F5C003F0A6EFCF
:100AB00005F01F9CE46B320EE36F60AE17D0F10EB1
:100AC0006F146F6E2D98A4902D9071BE2D80719E25
:100AD00060A40BD0000E60B0010E070B006ED89022
:100AE0000036F10E2D1400102D6E1CD00F0110AF2A
:100AF00015D0F10E6F140A096F6E2D88A4922D90F7
:100B000071BC2D80719C1051070B070B006ED890A3
:100B10000036F10E2D1400102D6E03D0000E016E64
:100B20004AD0000165500F0B3A6E2D9A65BC2D8A94
:100B30002D9C62B62D8C000E2DBC010EE86F0F0EA1
:100B4000F06F640EEF6FE8C0F1F0C2D603C031F071
:100B500002C030F001C02FF000C02EF00F0EE76F82
:100B6000660EE66FE56B3A50E55D14E2E6C0E9FF1C
:100B7000E7C0EAFFEFCFEAF0E4C0EAFFE3C0E9FF35
:100B8000EAC0EFFFE32BD8B4E42BE62BD8B4E72B75
:100B9000E52BE9D7F10E6F146F6E2D9EA4BE2D8E3E
:100BA000A49E2DA804D00F01109F03D00001609EC9
:100BB0000F01010E016E015223E0436A426A2E507A
:100BC0000A081EE12F521CE130521AE1315218E19D
:100BD000325053080BE13350590808E134505308A0
:100BE00005E11F8A000179DD0AD00F013250280883
:100BF00007E13350530804E11F8A00016EDD0F0145
:100C000000010FEF06F098D51FA204D01FA601D057
:100C1000A8D501D044D61FB01DDE1FBC4AD71FAED9
:100C200001D0FF00F1D79CEF06F0F86AD09E078E46
:100C30003E0E006E0F0E016E020EE96E000EEA6EA1
:100C4000EE6A002EFDD7012EFBD7A786560EAF6E9B
:100C5000000E7D6EA60EAC6E900EAB6E3E6A3D6AC7
:100C60003C6A280E3B6E3F903F92070E406E030E8B
:100C7000416E0F015C51800B5C6F000E5D6FC19681
:100C8000C198C19A5E6B5F6B34D0020019000012EC
:100C9000008609FF04060001C200A4600006FF01EF
:100CA00097094BB404C000478007FF029203E84253
:100CB000B100000007FF02930005517D000000080D
:100CC000FF039102010142C500000AFF0522000056
:100CD0001300642A8907FF022100FAD61B000000D6
:100CE000C75354532D4F4B00C75354532D4E4700F9
:100CF0000000000EF86E0C0EF76E8A0EF66E0900FC
:100D0000F550006E000A13E00900F550016EE8BED0
:100D100005D00F0BEA6E0900F5CFE9FF01BC090011
:100D200001AC0900F5CFEEFF004EE9D7F9D7F86A1C
:0A0D3000000128EF02F067D703006E
:020000040030CA
:0E00000015127E7C0009910000800FE00F4079
:00000001FF
;PIC18F26K80
;CRC=365A CREATED="27-11-24 15:30"

View File

@@ -0,0 +1,218 @@
:0400000015EF06F002
:08000800046ED8CF05F0E0CF33
:1000100006F00001E9CF0CF0EACF07F0E1CF08F0DD
:10002000E2CF09F0D9CF0AF0DACF0BF0F3CF12F01C
:10003000F4CF13F0FACF14F0F5CF15F0F6CF16F099
:10004000F7CF17F000C00EF001C00FF002C010F0A3
:1000500003C011F09DAA30EF00F09EBA75EF00F0DA
:1000600076A036EF00F077B0F3EF00F076A23CEF29
:1000700000F077B2EFEF00F09DA042EF00F09EB0ED
:100080009DEF00F076AA48EF00F077BAE9EF00F0B4
:1000900076AE4EEF00F077BEE6EF00F00EC000F057
:1000A0000FC001F010C002F011C003F00CC0E9FF56
:1000B00007C0EAFF078E08C0E1FF09C0E2FF0AC0DF
:1000C000D9FF0BC0DAFF12C0F3FF13C0F4FF14C056
:1000D000FAFF15C0F5FF16C0F6FF17C0F7FF045072
:1000E00006C0E0FF05C0D8FF10009EAAFED7AECF25
:1000F00001F1010120A006D0013D03D0466A476A04
:10010000209005D0472C03D0070E0125466E47509E
:10011000472A036A480FE96E000E0320EA6E01C108
:10012000EFFF4650475C01E1208247501D0801E285
:10013000476A9E9A00014EEF00F0D80ECF6EF00E87
:10014000CE6E252AD8B4262A275202E128520BE087
:100150002750D8B42806272E06D0285204E1286A52
:10016000960E276E1F86422AD8B4432A43500608AB
:1001700007E2FF0A03E14250D00802E2819C1F8E91
:10018000292AD8B42A2A2A5203E12950450803E231
:100190002A6A296A1F80212A21500908D8B013D061
:1001A000216A222A22500908D8B00DD0226A232AB7
:1001B00023500908D8B007D0236A242A24503B08CA
:1001C000D8B001D0246A9E904EEF00F0779E4EEF9B
:1001D00000F0819C1F8E769A779A4EEF00F01F8C6C
:1001E00077924EEF00F01F8C77904EEF00F0E339DE
:1001F000700B006ED89000361F0E6F1400106F6EDB
:100200006ECF00F0003A0030070BE35DF9E1120019
:10021000C00E0E0143150309436F3F0E4315436F94
:10022000F80E44150209446FC70E44151809446FAF
:10023000449D448FF80E45150109456F459D000109
:10024000BEEF01F0F5C0FCF0F4C0FBF0FA5352E051
:10025000FBC0E9FFFCC0EAFFF6C0EFFFFB51D8B4DA
:10026000FC07FB07FBC0E9FFFCC0EAFFF7C0EFFF9C
:10027000FB51D8B4FC07FB07FBC0E9FFFCC0EAFF59
:10028000F851030BEF6EFBC0E9FFFCC0EAFFF8C0BA
:1002900000F0003600360036F80E00160050E00B75
:1002A000EF10EF6EFBC0E9FFFCC0EAFFEF5008095A
:1002B000EF6EFB51D8B4FC07FB07FBC0E9FFFCC0A5
:1002C000EAFFF8C000F0003A0032070E00160050B6
:1002D000070BEF6EFBC0E9FFFCC0EAFFF9C000F0BE
:1002E000003600360036F80E00160050F80BEF10FE
:1002F000EF6E3FD0FBC0E9FFFCC0EAFFEF6AFB51A5
:10030000D8B4FC07FB07FBC0E9FFFCC0EAFFEF6ABB
:10031000FB51D8B4FC07FB07FBC0E9FFFCC0EAFFB8
:10032000F6C000F0003A0036E00E00160050E00B78
:10033000EF6EFB51D8B4FC07FB07FBC0E9FFFCC024
:10034000EAFFF6C000F00032003200321F0E001645
:1003500000501F0BEF6EFBC0E9FFFCC0EAFFF7C0C7
:1003600000F0003A0036E00E00160050E00BEF10EF
:10037000EF6E1200040EE36F3ADF4AD7606A9F0EF9
:100380006014606E608460CF10FF709A70980E0EDB
:10039000F56FFB0EF46FF96BF86BF76BF66BFA6B9E
:1003A00051DF0E0EF56FE30EF46FF96BF86BF76B20
:1003B000F66BFA6B47DF0E0EF56FE70EF46FF96B15
:1003C000F86BF76BF66BFA6B3DDF0E0EF56FF469A9
:1003D000F96BF86BF76BF66BFA6B34DF0E0EF56F9B
:1003E000EB0EF46FF96BF86BF76BF66BFA6B2ADFB9
:1003F0000E0EF56FEF0EF46FF96BF86BF76BF66B93
:10040000FA6B20DF0E0EF56FF30EF46FF96BF86BDD
:10041000F76BF66BFA6B16DF0E0EF56FF70EF46FD7
:10042000F96BF86BF76BF66BFA6B0CDF9350FB0B09
:100430000809936EE36BDBDE4CEF02F0266A256A57
:100440002650E55D04E3FCE1E451255CF9E312008C
:10045000D36A400E9B6E646AF29CF29EF2BEFDD798
:100460009D909D9A769A76927690000E926E3B0EB3
:10047000936E800E946E806A816A826A819C819EEE
:100480003E6A3D6A3C6A280E3B6E3F903F92070EE3
:10049000406E010E416E6ED7070ECD6EAA6AD80E61
:1004A000CF6EF00ECE6E1F6A206A3E6A3D6A3C6ACD
:1004B000280E3B6E436A426A456A446A9D8A9D8063
:1004C00076827680768AC00EF212E56BC80EE46FF3
:1004D000B5DF8288818C818E9BEF06F09EA8FED7C7
:1004E000AD6E8BEF02F0819C20802092466A476AB5
:1004F000E66BE4C0E9FFE5C0EAFFEF50E65D0DE220
:10050000010EE625E425E96E000EE521EA6EEFCF47
:10051000E7F0E751E3D7E62BECD71200E7C0EDF0A8
:10052000E6C0ECF0EA5302E1EB5325E0E9C003F04A
:10053000E8C0E9FFE9C0EAFFEF521DE0EDC0EFF0CF
:10054000EC51EC2BD8B4ED2BEE6FE9C003F0E85181
:10055000E82BD8B4E92BE96E03C0EAFFEFCFF0F047
:10056000EFC0EAFFEEC0E9FFF0C0EFFFEA51D8B4F8
:10057000EB07EA07D7D7EA5302E1EB530FE0EDC0F0
:1005800003F0EC51EC2BD8B4ED2BE96E03C0EAFF7D
:10059000EF6AEA51D8B4EB07EA07EDD7E6C001F0FD
:1005A000E7C002F01200266A256A2650000811E210
:1005B000FF0A03E125502C080CE2442AD8B4452A4E
:1005C000455203E14450050801E21F92000E016EFE
:1005D00030D020A2EAD7483C01D003D0000E016EF3
:1005E00028D0030EE425E96E000EE521EA6EEF50F7
:1005F0004A5C03E0000E016E1CD0818C4A50210839
:1006000016E14B5211E14C520FE11F84A10E676FAE
:10061000E76B680EE66FE96B4D0EE86FEB6B060E4D
:10062000EA6F7CDF6E6B03D0010E016E02D0010E0B
:10063000016E12001F92E56B860EE46F54DFE56BCE
:10064000860EE46FB0DF015203E1000E016E44D06C
:10065000E56B910EE46F47DFE56B910EE46FA3DF6E
:10066000015203E1000E016E37D0E56BA70EE46F77
:100670003ADFE56BA70EE46F96DF015203E1000E4F
:10068000016E2AD0E56BB20EE46F2DDFE56BB20E82
:10069000E46F89DF015203E1000E016E1DD0E56BAE
:1006A0009C0EE46F20DFE56B9C0EE46F7CDF015253
:1006B00003E1000E016E10D0E56BBD0EE46F13DF99
:1006C000E56BBD0EE46F6FDF015203E1000E016EBA
:1006D00003D01F82010E016E12001FA215D0E76B1E
:1006E000670EE66FE96BD30EE86FEB6B070EEA6FF0
:1006F00015DFE76B6E0EE66FE96BD30EE86FEB6B01
:10070000070EEA6F0BDF14D0E76B670EE66FE96B3D
:10071000DB0EE86FEB6B070EEA6F00DFE76B6E0E28
:10072000E66FE96BDB0EE86FEB6B070EEA6FF6DE48
:100730002A6A296A1F801200819E7CDF2A6A296A40
:10074000246A24C023F023C022F022C021F0C5DF98
:10075000030E286EE80E276E1F9E1F9A818E04EFEF
:1007600006F01F96E56BC80EE46FBDDEE56BC80EA4
:10077000E46F19DF015204E0010E016E03D002D0D4
:10078000000E016E09EF06F00F0EF26F660EF16FAC
:100790000F0120B708D0F10E6F1408096F6E000129
:1007A000F36B1BD00F0110B709D0F10E6F140609BF
:1007B0006F6E010E0001F36F10D00F0100B709D06A
:1007C000F10E6F1404096F6E020E0001F36F05D075
:1007D0000F01000E016E3BD00001ED51030B006EC6
:1007E000FC0E60140010606E0F0EF56F640EF46F57
:1007F000E9C0F9F0E8C0F8F0E7C0F7F0E6C0F6F0BD
:10080000EEC0FAF01FDDECC065FF659CEFB1658CB2
:10081000F06BEC51F05D14E2EAC0E9FFEBC0EAFFD7
:10082000EFCFF6F0F2C0EAFFF1C0E9FFF6C0EFFF4C
:10083000F12BD8B4F22BEA2BD8B4EB2BF02BE9D761
:100840006086F10E6F146F6E010E016E0F010001D4
:100850004CEF04F00F0120A704D010A702D000B77E
:100860001CD01F90000E3FB2010E0001E46F000E7D
:100870003FB0010EE56FE96BE86BE76B280EE66FA2
:10088000EB6B670EEA6F40C0ECF041C0EDF0E4C0E6
:10089000EEF0E5C0EFF078D70F0100011200E36B36
:1008A0002A6A296A1F90E56BC80EE46FC7DDC2DEB5
:1008B00014DF1FB0CFDF1FB206D0E32BE3510508D2
:1008C00001E2FF00F0D7286A960E276E0BEF06F0C4
:1008D000F56BF46BF36BF26BF0C0F7F0EFC0F6F072
:1008E000F153D8B489D0F6C0E9FFF7C0EAFFF56B41
:1008F000F46BF36BEFCFF2F0F651D8B4F707F607CD
:10090000F6C0E9FFF7C0EAFFEF50FA6BF96BF86F3A
:10091000006A0050F213F851F313F951F413FA512D
:10092000F513F651D8B4F707F607F6C0E9FFF7C09C
:10093000EAFFEF50FB6BFA6BF96BF86F030EF817D9
:10094000F96BFA6BFB6B006A016A0050F2130150FD
:10095000F313F851F413F951F513F6C0E9FFF7C09A
:10096000EAFFEF50FB6BFA6BF96BF86FE00EF817CC
:10097000F96BFA6BFB6B006AF835016EF935026EA4
:10098000FA35036E01360236033601360236033677
:10099000013602360336013602360336E00E011602
:1009A0000050F2130150F3130250F4130350F513E7
:1009B000F651D8B4F707F607F6C0E9FFF7C0EAFF2B
:1009C000EF50F96BF86F006A016AF835026EF9357D
:1009D000036E02360336023603360236033602361B
:1009E0000336E00E02160050F2130150F3130250CA
:1009F000F4130350F51353D0020EF65F000EF75BAD
:100A0000F6C0E9FFF7C0EAFFEF50FB6BFA6BF96B3A
:100A1000F86FE00EF817F96BFA6BFB6BFB31F56FB3
:100A2000FA31F46FF931F36FF831F26FF533F433D3
:100A3000F333F233F533F433F333F233F533F43382
:100A4000F333F233F533F433F333F233070EF517A0
:100A5000F651D8B4F707F607F6C0E9FFF7C0EAFF8A
:100A6000EF50FB6BFA6BF96BF86FF835006EF935E8
:100A7000016EFA35026EFB35036E00360136023622
:100A800003360036013602360336F80E00160050E3
:100A9000F2130150F3130250F4130350F513F2C094
:100AA00000F0F3C001F0F4C002F0F5C003F0A6EFCF
:100AB00005F01F9CE46B320EE36F60AE17D0F10EB1
:100AC0006F146F6E2D98A4902D9071BE2D80719E25
:100AD00060A40BD0000E60B0010E070B006ED89022
:100AE0000036F10E2D1400102D6E1CD00F0110AF2A
:100AF00015D0F10E6F140A096F6E2D88A4922D90F7
:100B000071BC2D80719C1051070B070B006ED890A3
:100B10000036F10E2D1400102D6E03D0000E016E64
:100B20004AD0000165500F0B3A6E2D9A65BC2D8A94
:100B30002D9C62B62D8C000E2DBC010EE86F0F0EA1
:100B4000F06F640EEF6FE8C0F1F0C2D603C031F071
:100B500002C030F001C02FF000C02EF00F0EE76F82
:100B6000660EE66FE56B3A50E55D14E2E6C0E9FF1C
:100B7000E7C0EAFFEFCFEAF0E4C0EAFFE3C0E9FF35
:100B8000EAC0EFFFE32BD8B4E42BE62BD8B4E72B75
:100B9000E52BE9D7F10E6F146F6E2D9EA4BE2D8E3E
:100BA000A49E2DA804D00F01109F03D00001609EC9
:100BB0000F01010E016E015223E0436A426A2E507A
:100BC0000A081EE12F521CE130521AE1315218E19D
:100BD000325053080BE13350590808E134505308A0
:100BE00005E11F8A000179DD0AD00F013250280883
:100BF00007E13350530804E11F8A00016EDD0F0145
:100C000000010FEF06F098D51FA204D01FA601D057
:100C1000A8D501D044D61FB01DDE1FBC4AD71FAED9
:100C200001D0FF00F1D79CEF06F0F86AD09E078E46
:100C30003E0E006E0F0E016E020EE96E000EEA6EA1
:100C4000EE6A002EFDD7012EFBD7A786560EAF6E9B
:100C5000000E7D6EA60EAC6E900EAB6E3E6A3D6AC7
:100C60003C6A280E3B6E3F903F92070E406E030E8B
:100C7000416E0F015C51800B5C6F000E5D6FC19681
:100C8000C198C19A5E6B5F6B34D0020019000012EC
:100C9000008609FF04060001C200A4600006FF01EF
:100CA00097094BB404C000478007FF029205DC445B
:100CB0008500000007FF02930005517D0000000839
:100CC000FF039102010142C500000AFF0522000056
:100CD0001300642A8907FF022100FAD61B000000D6
:100CE000C75354532D4F4B00C75354532D4E4700F9
:100CF0000000000EF86E0C0EF76E8A0EF66E0900FC
:100D0000F550006E000A13E00900F550016EE8BED0
:100D100005D00F0BEA6E0900F5CFE9FF01BC090011
:100D200001AC0900F5CFEEFF004EE9D7F9D7F86A1C
:0A0D3000000128EF02F067D703006E
:020000040030CA
:0E00000015127E7C0009910000800FE00F4079
:00000001FF
;PIC18F26K80
;CRC=C271 CREATED="27-11-24 15:29"

View File

@@ -0,0 +1,218 @@
:0400000015EF06F002
:08000800046ED8CF05F0E0CF33
:1000100006F00001E9CF0CF0EACF07F0E1CF08F0DD
:10002000E2CF09F0D9CF0AF0DACF0BF0F3CF12F01C
:10003000F4CF13F0FACF14F0F5CF15F0F6CF16F099
:10004000F7CF17F000C00EF001C00FF002C010F0A3
:1000500003C011F09DAA30EF00F09EBA75EF00F0DA
:1000600076A036EF00F077B0F3EF00F076A23CEF29
:1000700000F077B2EFEF00F09DA042EF00F09EB0ED
:100080009DEF00F076AA48EF00F077BAE9EF00F0B4
:1000900076AE4EEF00F077BEE6EF00F00EC000F057
:1000A0000FC001F010C002F011C003F00CC0E9FF56
:1000B00007C0EAFF078E08C0E1FF09C0E2FF0AC0DF
:1000C000D9FF0BC0DAFF12C0F3FF13C0F4FF14C056
:1000D000FAFF15C0F5FF16C0F6FF17C0F7FF045072
:1000E00006C0E0FF05C0D8FF10009EAAFED7AECF25
:1000F00001F1010120A006D0013D03D0466A476A04
:10010000209005D0472C03D0070E0125466E47509E
:10011000472A036A480FE96E000E0320EA6E01C108
:10012000EFFF4650475C01E1208247501D0801E285
:10013000476A9E9A00014EEF00F0D80ECF6EF00E87
:10014000CE6E252AD8B4262A275202E128520BE087
:100150002750D8B42806272E06D0285204E1286A52
:10016000960E276E1F86422AD8B4432A43500608AB
:1001700007E2FF0A03E14250D00802E2819C1F8E91
:10018000292AD8B42A2A2A5203E12950450803E231
:100190002A6A296A1F80212A21500908D8B013D061
:1001A000216A222A22500908D8B00DD0226A232AB7
:1001B00023500908D8B007D0236A242A24503B08CA
:1001C000D8B001D0246A9E904EEF00F0779E4EEF9B
:1001D00000F0819C1F8E769A779A4EEF00F01F8C6C
:1001E00077924EEF00F01F8C77904EEF00F0E339DE
:1001F000700B006ED89000361F0E6F1400106F6EDB
:100200006ECF00F0003A0030070BE35DF9E1120019
:10021000C00E0E0143150309436F3F0E4315436F94
:10022000F80E44150209446FC70E44151809446FAF
:10023000449D448FF80E45150109456F459D000109
:10024000BEEF01F0F5C0FCF0F4C0FBF0FA5352E051
:10025000FBC0E9FFFCC0EAFFF6C0EFFFFB51D8B4DA
:10026000FC07FB07FBC0E9FFFCC0EAFFF7C0EFFF9C
:10027000FB51D8B4FC07FB07FBC0E9FFFCC0EAFF59
:10028000F851030BEF6EFBC0E9FFFCC0EAFFF8C0BA
:1002900000F0003600360036F80E00160050E00B75
:1002A000EF10EF6EFBC0E9FFFCC0EAFFEF5008095A
:1002B000EF6EFB51D8B4FC07FB07FBC0E9FFFCC0A5
:1002C000EAFFF8C000F0003A0032070E00160050B6
:1002D000070BEF6EFBC0E9FFFCC0EAFFF9C000F0BE
:1002E000003600360036F80E00160050F80BEF10FE
:1002F000EF6E3FD0FBC0E9FFFCC0EAFFEF6AFB51A5
:10030000D8B4FC07FB07FBC0E9FFFCC0EAFFEF6ABB
:10031000FB51D8B4FC07FB07FBC0E9FFFCC0EAFFB8
:10032000F6C000F0003A0036E00E00160050E00B78
:10033000EF6EFB51D8B4FC07FB07FBC0E9FFFCC024
:10034000EAFFF6C000F00032003200321F0E001645
:1003500000501F0BEF6EFBC0E9FFFCC0EAFFF7C0C7
:1003600000F0003A0036E00E00160050E00BEF10EF
:10037000EF6E1200040EE36F3ADF4AD7606A9F0EF9
:100380006014606E608460CF10FF709A70980E0EDB
:10039000F56FFB0EF46FF96BF86BF76BF66BFA6B9E
:1003A00051DF0E0EF56FE30EF46FF96BF86BF76B20
:1003B000F66BFA6B47DF0E0EF56FE70EF46FF96B15
:1003C000F86BF76BF66BFA6B3DDF0E0EF56FF469A9
:1003D000F96BF86BF76BF66BFA6B34DF0E0EF56F9B
:1003E000EB0EF46FF96BF86BF76BF66BFA6B2ADFB9
:1003F0000E0EF56FEF0EF46FF96BF86BF76BF66B93
:10040000FA6B20DF0E0EF56FF30EF46FF96BF86BDD
:10041000F76BF66BFA6B16DF0E0EF56FF70EF46FD7
:10042000F96BF86BF76BF66BFA6B0CDF9350FB0B09
:100430000809936EE36BDBDE4CEF02F0266A256A57
:100440002650E55D04E3FCE1E451255CF9E312008C
:10045000D36A400E9B6E646AF29CF29EF2BEFDD798
:100460009D909D9A769A76927690000E926E3B0EB3
:10047000936E800E946E806A816A826A819C819EEE
:100480003E6A3D6A3C6A280E3B6E3F903F92070EE3
:10049000406E010E416E6ED7070ECD6EAA6AD80E61
:1004A000CF6EF00ECE6E1F6A206A3E6A3D6A3C6ACD
:1004B000280E3B6E436A426A456A446A9D8A9D8063
:1004C00076827680768AC00EF212E56BC80EE46FF3
:1004D000B5DF8288818C818E9BEF06F09EA8FED7C7
:1004E000AD6E8BEF02F0819C20802092466A476AB5
:1004F000E66BE4C0E9FFE5C0EAFFEF50E65D0DE220
:10050000010EE625E425E96E000EE521EA6EEFCF47
:10051000E7F0E751E3D7E62BECD71200E7C0EDF0A8
:10052000E6C0ECF0EA5302E1EB5325E0E9C003F04A
:10053000E8C0E9FFE9C0EAFFEF521DE0EDC0EFF0CF
:10054000EC51EC2BD8B4ED2BEE6FE9C003F0E85181
:10055000E82BD8B4E92BE96E03C0EAFFEFCFF0F047
:10056000EFC0EAFFEEC0E9FFF0C0EFFFEA51D8B4F8
:10057000EB07EA07D7D7EA5302E1EB530FE0EDC0F0
:1005800003F0EC51EC2BD8B4ED2BE96E03C0EAFF7D
:10059000EF6AEA51D8B4EB07EA07EDD7E6C001F0FD
:1005A000E7C002F01200266A256A2650000811E210
:1005B000FF0A03E125502C080CE2442AD8B4452A4E
:1005C000455203E14450050801E21F92000E016EFE
:1005D00030D020A2EAD7483C01D003D0000E016EF3
:1005E00028D0030EE425E96E000EE521EA6EEF50F7
:1005F0004A5C03E0000E016E1CD0818C4A50210839
:1006000016E14B5211E14C520FE11F84A10E676FAE
:10061000E76B680EE66FE96B4D0EE86FEB6B060E4D
:10062000EA6F7CDF6E6B03D0010E016E02D0010E0B
:10063000016E12001F92E56B860EE46F54DFE56BCE
:10064000860EE46FB0DF015203E1000E016E44D06C
:10065000E56B910EE46F47DFE56B910EE46FA3DF6E
:10066000015203E1000E016E37D0E56BA70EE46F77
:100670003ADFE56BA70EE46F96DF015203E1000E4F
:10068000016E2AD0E56BB20EE46F2DDFE56BB20E82
:10069000E46F89DF015203E1000E016E1DD0E56BAE
:1006A0009C0EE46F20DFE56B9C0EE46F7CDF015253
:1006B00003E1000E016E10D0E56BBD0EE46F13DF99
:1006C000E56BBD0EE46F6FDF015203E1000E016EBA
:1006D00003D01F82010E016E12001FA215D0E76B1E
:1006E000670EE66FE96BD30EE86FEB6B070EEA6FF0
:1006F00015DFE76B6E0EE66FE96BD30EE86FEB6B01
:10070000070EEA6F0BDF14D0E76B670EE66FE96B3D
:10071000DB0EE86FEB6B070EEA6F00DFE76B6E0E28
:10072000E66FE96BDB0EE86FEB6B070EEA6FF6DE48
:100730002A6A296A1F801200819E7CDF2A6A296A40
:10074000246A24C023F023C022F022C021F0C5DF98
:10075000030E286EE80E276E1F9E1F9A818E04EFEF
:1007600006F01F96E56BC80EE46FBDDEE56BC80EA4
:10077000E46F19DF015204E0010E016E03D002D0D4
:10078000000E016E09EF06F00F0EF26F660EF16FAC
:100790000F0120B708D0F10E6F1408096F6E000129
:1007A000F36B1BD00F0110B709D0F10E6F140609BF
:1007B0006F6E010E0001F36F10D00F0100B709D06A
:1007C000F10E6F1404096F6E020E0001F36F05D075
:1007D0000F01000E016E3BD00001ED51030B006EC6
:1007E000FC0E60140010606E0F0EF56F640EF46F57
:1007F000E9C0F9F0E8C0F8F0E7C0F7F0E6C0F6F0BD
:10080000EEC0FAF01FDDECC065FF659CEFB1658CB2
:10081000F06BEC51F05D14E2EAC0E9FFEBC0EAFFD7
:10082000EFCFF6F0F2C0EAFFF1C0E9FFF6C0EFFF4C
:10083000F12BD8B4F22BEA2BD8B4EB2BF02BE9D761
:100840006086F10E6F146F6E010E016E0F010001D4
:100850004CEF04F00F0120A704D010A702D000B77E
:100860001CD01F90000E3FB2010E0001E46F000E7D
:100870003FB0010EE56FE96BE86BE76B280EE66FA2
:10088000EB6B670EEA6F40C0ECF041C0EDF0E4C0E6
:10089000EEF0E5C0EFF078D70F0100011200E36B36
:1008A0002A6A296A1F90E56BC80EE46FC7DDC2DEB5
:1008B00014DF1FB0CFDF1FB206D0E32BE3510508D2
:1008C00001E2FF00F0D7286A960E276E0BEF06F0C4
:1008D000F56BF46BF36BF26BF0C0F7F0EFC0F6F072
:1008E000F153D8B489D0F6C0E9FFF7C0EAFFF56B41
:1008F000F46BF36BEFCFF2F0F651D8B4F707F607CD
:10090000F6C0E9FFF7C0EAFFEF50FA6BF96BF86F3A
:10091000006A0050F213F851F313F951F413FA512D
:10092000F513F651D8B4F707F607F6C0E9FFF7C09C
:10093000EAFFEF50FB6BFA6BF96BF86F030EF817D9
:10094000F96BFA6BFB6B006A016A0050F2130150FD
:10095000F313F851F413F951F513F6C0E9FFF7C09A
:10096000EAFFEF50FB6BFA6BF96BF86FE00EF817CC
:10097000F96BFA6BFB6B006AF835016EF935026EA4
:10098000FA35036E01360236033601360236033677
:10099000013602360336013602360336E00E011602
:1009A0000050F2130150F3130250F4130350F513E7
:1009B000F651D8B4F707F607F6C0E9FFF7C0EAFF2B
:1009C000EF50F96BF86F006A016AF835026EF9357D
:1009D000036E02360336023603360236033602361B
:1009E0000336E00E02160050F2130150F3130250CA
:1009F000F4130350F51353D0020EF65F000EF75BAD
:100A0000F6C0E9FFF7C0EAFFEF50FB6BFA6BF96B3A
:100A1000F86FE00EF817F96BFA6BFB6BFB31F56FB3
:100A2000FA31F46FF931F36FF831F26FF533F433D3
:100A3000F333F233F533F433F333F233F533F43382
:100A4000F333F233F533F433F333F233070EF517A0
:100A5000F651D8B4F707F607F6C0E9FFF7C0EAFF8A
:100A6000EF50FB6BFA6BF96BF86FF835006EF935E8
:100A7000016EFA35026EFB35036E00360136023622
:100A800003360036013602360336F80E00160050E3
:100A9000F2130150F3130250F4130350F513F2C094
:100AA00000F0F3C001F0F4C002F0F5C003F0A6EFCF
:100AB00005F01F9CE46B320EE36F60AE17D0F10EB1
:100AC0006F146F6E2D98A4902D9071BE2D80719E25
:100AD00060A40BD0000E60B0010E070B006ED89022
:100AE0000036F10E2D1400102D6E1CD00F0110AF2A
:100AF00015D0F10E6F140A096F6E2D88A4922D90F7
:100B000071BC2D80719C1051070B070B006ED890A3
:100B10000036F10E2D1400102D6E03D0000E016E64
:100B20004AD0000165500F0B3A6E2D9A65BC2D8A94
:100B30002D9C62B62D8C000E2DBC010EE86F0F0EA1
:100B4000F06F640EEF6FE8C0F1F0C2D603C031F071
:100B500002C030F001C02FF000C02EF00F0EE76F82
:100B6000660EE66FE56B3A50E55D14E2E6C0E9FF1C
:100B7000E7C0EAFFEFCFEAF0E4C0EAFFE3C0E9FF35
:100B8000EAC0EFFFE32BD8B4E42BE62BD8B4E72B75
:100B9000E52BE9D7F10E6F146F6E2D9EA4BE2D8E3E
:100BA000A49E2DA804D00F01109F03D00001609EC9
:100BB0000F01010E016E015223E0436A426A2E507A
:100BC0000A081EE12F521CE130521AE1315218E19D
:100BD000325053080BE13350590808E134505308A0
:100BE00005E11F8A000179DD0AD00F013250280883
:100BF00007E13350530804E11F8A00016EDD0F0145
:100C000000010FEF06F098D51FA204D01FA601D057
:100C1000A8D501D044D61FB01DDE1FBC4AD71FAED9
:100C200001D0FF00F1D79CEF06F0F86AD09E078E46
:100C30003E0E006E0F0E016E020EE96E000EEA6EA1
:100C4000EE6A002EFDD7012EFBD7A786560EAF6E9B
:100C5000000E7D6EA60EAC6E900EAB6E3E6A3D6AC7
:100C60003C6A280E3B6E3F903F92070E406E030E8B
:100C7000416E0F015C51800B5C6F000E5D6FC19681
:100C8000C198C19A5E6B5F6B34D0020019000012EC
:100C9000008609FF04060001C200A4600006FF01EF
:100CA00097094BB404C000478007FF029207D04663
:100CB0008900000007FF02930005517D0000000835
:100CC000FF039102010142C500000AFF0522000056
:100CD0001300642A8907FF022100FAD61B000000D6
:100CE000C75354532D4F4B00C75354532D4E4700F9
:100CF0000000000EF86E0C0EF76E8A0EF66E0900FC
:100D0000F550006E000A13E00900F550016EE8BED0
:100D100005D00F0BEA6E0900F5CFE9FF01BC090011
:100D200001AC0900F5CFEEFF004EE9D7F9D7F86A1C
:0A0D3000000128EF02F067D703006E
:020000040030CA
:0E00000015127E7C0009910000800FE00F4079
:00000001FF
;PIC18F26K80
;CRC=0CAC CREATED="27-11-24 15:28"

View File

@@ -0,0 +1,218 @@
:0400000015EF06F002
:08000800046ED8CF05F0E0CF33
:1000100006F00001E9CF0CF0EACF07F0E1CF08F0DD
:10002000E2CF09F0D9CF0AF0DACF0BF0F3CF12F01C
:10003000F4CF13F0FACF14F0F5CF15F0F6CF16F099
:10004000F7CF17F000C00EF001C00FF002C010F0A3
:1000500003C011F09DAA30EF00F09EBA75EF00F0DA
:1000600076A036EF00F077B0F3EF00F076A23CEF29
:1000700000F077B2EFEF00F09DA042EF00F09EB0ED
:100080009DEF00F076AA48EF00F077BAE9EF00F0B4
:1000900076AE4EEF00F077BEE6EF00F00EC000F057
:1000A0000FC001F010C002F011C003F00CC0E9FF56
:1000B00007C0EAFF078E08C0E1FF09C0E2FF0AC0DF
:1000C000D9FF0BC0DAFF12C0F3FF13C0F4FF14C056
:1000D000FAFF15C0F5FF16C0F6FF17C0F7FF045072
:1000E00006C0E0FF05C0D8FF10009EAAFED7AECF25
:1000F00001F1010120A006D0013D03D0466A476A04
:10010000209005D0472C03D0070E0125466E47509E
:10011000472A036A480FE96E000E0320EA6E01C108
:10012000EFFF4650475C01E1208247501D0801E285
:10013000476A9E9A00014EEF00F0D80ECF6EF00E87
:10014000CE6E252AD8B4262A275202E128520BE087
:100150002750D8B42806272E06D0285204E1286A52
:10016000960E276E1F86422AD8B4432A43500608AB
:1001700007E2FF0A03E14250D00802E2819C1F8E91
:10018000292AD8B42A2A2A5203E12950450803E231
:100190002A6A296A1F80212A21500908D8B013D061
:1001A000216A222A22500908D8B00DD0226A232AB7
:1001B00023500908D8B007D0236A242A24503B08CA
:1001C000D8B001D0246A9E904EEF00F0779E4EEF9B
:1001D00000F0819C1F8E769A779A4EEF00F01F8C6C
:1001E00077924EEF00F01F8C77904EEF00F0E339DE
:1001F000700B006ED89000361F0E6F1400106F6EDB
:100200006ECF00F0003A0030070BE35DF9E1120019
:10021000C00E0E0143150309436F3F0E4315436F94
:10022000F80E44150209446FC70E44151809446FAF
:10023000449D448FF80E45150109456F459D000109
:10024000BEEF01F0F5C0FCF0F4C0FBF0FA5352E051
:10025000FBC0E9FFFCC0EAFFF6C0EFFFFB51D8B4DA
:10026000FC07FB07FBC0E9FFFCC0EAFFF7C0EFFF9C
:10027000FB51D8B4FC07FB07FBC0E9FFFCC0EAFF59
:10028000F851030BEF6EFBC0E9FFFCC0EAFFF8C0BA
:1002900000F0003600360036F80E00160050E00B75
:1002A000EF10EF6EFBC0E9FFFCC0EAFFEF5008095A
:1002B000EF6EFB51D8B4FC07FB07FBC0E9FFFCC0A5
:1002C000EAFFF8C000F0003A0032070E00160050B6
:1002D000070BEF6EFBC0E9FFFCC0EAFFF9C000F0BE
:1002E000003600360036F80E00160050F80BEF10FE
:1002F000EF6E3FD0FBC0E9FFFCC0EAFFEF6AFB51A5
:10030000D8B4FC07FB07FBC0E9FFFCC0EAFFEF6ABB
:10031000FB51D8B4FC07FB07FBC0E9FFFCC0EAFFB8
:10032000F6C000F0003A0036E00E00160050E00B78
:10033000EF6EFB51D8B4FC07FB07FBC0E9FFFCC024
:10034000EAFFF6C000F00032003200321F0E001645
:1003500000501F0BEF6EFBC0E9FFFCC0EAFFF7C0C7
:1003600000F0003A0036E00E00160050E00BEF10EF
:10037000EF6E1200040EE36F3ADF4AD7606A9F0EF9
:100380006014606E608460CF10FF709A70980E0EDB
:10039000F56FFB0EF46FF96BF86BF76BF66BFA6B9E
:1003A00051DF0E0EF56FE30EF46FF96BF86BF76B20
:1003B000F66BFA6B47DF0E0EF56FE70EF46FF96B15
:1003C000F86BF76BF66BFA6B3DDF0E0EF56FF469A9
:1003D000F96BF86BF76BF66BFA6B34DF0E0EF56F9B
:1003E000EB0EF46FF96BF86BF76BF66BFA6B2ADFB9
:1003F0000E0EF56FEF0EF46FF96BF86BF76BF66B93
:10040000FA6B20DF0E0EF56FF30EF46FF96BF86BDD
:10041000F76BF66BFA6B16DF0E0EF56FF70EF46FD7
:10042000F96BF86BF76BF66BFA6B0CDF9350FB0B09
:100430000809936EE36BDBDE4CEF02F0266A256A57
:100440002650E55D04E3FCE1E451255CF9E312008C
:10045000D36A400E9B6E646AF29CF29EF2BEFDD798
:100460009D909D9A769A76927690000E926E3B0EB3
:10047000936E800E946E806A816A826A819C819EEE
:100480003E6A3D6A3C6A280E3B6E3F903F92070EE3
:10049000406E010E416E6ED7070ECD6EAA6AD80E61
:1004A000CF6EF00ECE6E1F6A206A3E6A3D6A3C6ACD
:1004B000280E3B6E436A426A456A446A9D8A9D8063
:1004C00076827680768AC00EF212E56BC80EE46FF3
:1004D000B5DF8288818C818E9BEF06F09EA8FED7C7
:1004E000AD6E8BEF02F0819C20802092466A476AB5
:1004F000E66BE4C0E9FFE5C0EAFFEF50E65D0DE220
:10050000010EE625E425E96E000EE521EA6EEFCF47
:10051000E7F0E751E3D7E62BECD71200E7C0EDF0A8
:10052000E6C0ECF0EA5302E1EB5325E0E9C003F04A
:10053000E8C0E9FFE9C0EAFFEF521DE0EDC0EFF0CF
:10054000EC51EC2BD8B4ED2BEE6FE9C003F0E85181
:10055000E82BD8B4E92BE96E03C0EAFFEFCFF0F047
:10056000EFC0EAFFEEC0E9FFF0C0EFFFEA51D8B4F8
:10057000EB07EA07D7D7EA5302E1EB530FE0EDC0F0
:1005800003F0EC51EC2BD8B4ED2BE96E03C0EAFF7D
:10059000EF6AEA51D8B4EB07EA07EDD7E6C001F0FD
:1005A000E7C002F01200266A256A2650000811E210
:1005B000FF0A03E125502C080CE2442AD8B4452A4E
:1005C000455203E14450050801E21F92000E016EFE
:1005D00030D020A2EAD7483C01D003D0000E016EF3
:1005E00028D0030EE425E96E000EE521EA6EEF50F7
:1005F0004A5C03E0000E016E1CD0818C4A50210839
:1006000016E14B5211E14C520FE11F84A10E676FAE
:10061000E76B680EE66FE96B4D0EE86FEB6B060E4D
:10062000EA6F7CDF6E6B03D0010E016E02D0010E0B
:10063000016E12001F92E56B860EE46F54DFE56BCE
:10064000860EE46FB0DF015203E1000E016E44D06C
:10065000E56B910EE46F47DFE56B910EE46FA3DF6E
:10066000015203E1000E016E37D0E56BA70EE46F77
:100670003ADFE56BA70EE46F96DF015203E1000E4F
:10068000016E2AD0E56BB20EE46F2DDFE56BB20E82
:10069000E46F89DF015203E1000E016E1DD0E56BAE
:1006A0009C0EE46F20DFE56B9C0EE46F7CDF015253
:1006B00003E1000E016E10D0E56BBD0EE46F13DF99
:1006C000E56BBD0EE46F6FDF015203E1000E016EBA
:1006D00003D01F82010E016E12001FA215D0E76B1E
:1006E000670EE66FE96BD30EE86FEB6B070EEA6FF0
:1006F00015DFE76B6E0EE66FE96BD30EE86FEB6B01
:10070000070EEA6F0BDF14D0E76B670EE66FE96B3D
:10071000DB0EE86FEB6B070EEA6F00DFE76B6E0E28
:10072000E66FE96BDB0EE86FEB6B070EEA6FF6DE48
:100730002A6A296A1F801200819E7CDF2A6A296A40
:10074000246A24C023F023C022F022C021F0C5DF98
:10075000030E286EE80E276E1F9E1F9A818E04EFEF
:1007600006F01F96E56BC80EE46FBDDEE56BC80EA4
:10077000E46F19DF015204E0010E016E03D002D0D4
:10078000000E016E09EF06F00F0EF26F660EF16FAC
:100790000F0120B708D0F10E6F1408096F6E000129
:1007A000F36B1BD00F0110B709D0F10E6F140609BF
:1007B0006F6E010E0001F36F10D00F0100B709D06A
:1007C000F10E6F1404096F6E020E0001F36F05D075
:1007D0000F01000E016E3BD00001ED51030B006EC6
:1007E000FC0E60140010606E0F0EF56F640EF46F57
:1007F000E9C0F9F0E8C0F8F0E7C0F7F0E6C0F6F0BD
:10080000EEC0FAF01FDDECC065FF659CEFB1658CB2
:10081000F06BEC51F05D14E2EAC0E9FFEBC0EAFFD7
:10082000EFCFF6F0F2C0EAFFF1C0E9FFF6C0EFFF4C
:10083000F12BD8B4F22BEA2BD8B4EB2BF02BE9D761
:100840006086F10E6F146F6E010E016E0F010001D4
:100850004CEF04F00F0120A704D010A702D000B77E
:100860001CD01F90000E3FB2010E0001E46F000E7D
:100870003FB0010EE56FE96BE86BE76B280EE66FA2
:10088000EB6B670EEA6F40C0ECF041C0EDF0E4C0E6
:10089000EEF0E5C0EFF078D70F0100011200E36B36
:1008A0002A6A296A1F90E56BC80EE46FC7DDC2DEB5
:1008B00014DF1FB0CFDF1FB206D0E32BE3510508D2
:1008C00001E2FF00F0D7286A960E276E0BEF06F0C4
:1008D000F56BF46BF36BF26BF0C0F7F0EFC0F6F072
:1008E000F153D8B489D0F6C0E9FFF7C0EAFFF56B41
:1008F000F46BF36BEFCFF2F0F651D8B4F707F607CD
:10090000F6C0E9FFF7C0EAFFEF50FA6BF96BF86F3A
:10091000006A0050F213F851F313F951F413FA512D
:10092000F513F651D8B4F707F607F6C0E9FFF7C09C
:10093000EAFFEF50FB6BFA6BF96BF86F030EF817D9
:10094000F96BFA6BFB6B006A016A0050F2130150FD
:10095000F313F851F413F951F513F6C0E9FFF7C09A
:10096000EAFFEF50FB6BFA6BF96BF86FE00EF817CC
:10097000F96BFA6BFB6B006AF835016EF935026EA4
:10098000FA35036E01360236033601360236033677
:10099000013602360336013602360336E00E011602
:1009A0000050F2130150F3130250F4130350F513E7
:1009B000F651D8B4F707F607F6C0E9FFF7C0EAFF2B
:1009C000EF50F96BF86F006A016AF835026EF9357D
:1009D000036E02360336023603360236033602361B
:1009E0000336E00E02160050F2130150F3130250CA
:1009F000F4130350F51353D0020EF65F000EF75BAD
:100A0000F6C0E9FFF7C0EAFFEF50FB6BFA6BF96B3A
:100A1000F86FE00EF817F96BFA6BFB6BFB31F56FB3
:100A2000FA31F46FF931F36FF831F26FF533F433D3
:100A3000F333F233F533F433F333F233F533F43382
:100A4000F333F233F533F433F333F233070EF517A0
:100A5000F651D8B4F707F607F6C0E9FFF7C0EAFF8A
:100A6000EF50FB6BFA6BF96BF86FF835006EF935E8
:100A7000016EFA35026EFB35036E00360136023622
:100A800003360036013602360336F80E00160050E3
:100A9000F2130150F3130250F4130350F513F2C094
:100AA00000F0F3C001F0F4C002F0F5C003F0A6EFCF
:100AB00005F01F9CE46B320EE36F60AE17D0F10EB1
:100AC0006F146F6E2D98A4902D9071BE2D80719E25
:100AD00060A40BD0000E60B0010E070B006ED89022
:100AE0000036F10E2D1400102D6E1CD00F0110AF2A
:100AF00015D0F10E6F140A096F6E2D88A4922D90F7
:100B000071BC2D80719C1051070B070B006ED890A3
:100B10000036F10E2D1400102D6E03D0000E016E64
:100B20004AD0000165500F0B3A6E2D9A65BC2D8A94
:100B30002D9C62B62D8C000E2DBC010EE86F0F0EA1
:100B4000F06F640EEF6FE8C0F1F0C2D603C031F071
:100B500002C030F001C02FF000C02EF00F0EE76F82
:100B6000660EE66FE56B3A50E55D14E2E6C0E9FF1C
:100B7000E7C0EAFFEFCFEAF0E4C0EAFFE3C0E9FF35
:100B8000EAC0EFFFE32BD8B4E42BE62BD8B4E72B75
:100B9000E52BE9D7F10E6F146F6E2D9EA4BE2D8E3E
:100BA000A49E2DA804D00F01109F03D00001609EC9
:100BB0000F01010E016E015223E0436A426A2E507A
:100BC0000A081EE12F521CE130521AE1315218E19D
:100BD000325053080BE13350590808E134505308A0
:100BE00005E11F8A000179DD0AD00F013250280883
:100BF00007E13350530804E11F8A00016EDD0F0145
:100C000000010FEF06F098D51FA204D01FA601D057
:100C1000A8D501D044D61FB01DDE1FBC4AD71FAED9
:100C200001D0FF00F1D79CEF06F0F86AD09E078E46
:100C30003E0E006E0F0E016E020EE96E000EEA6EA1
:100C4000EE6A002EFDD7012EFBD7A786560EAF6E9B
:100C5000000E7D6EA60EAC6E900EAB6E3E6A3D6AC7
:100C60003C6A280E3B6E3F903F92070E406E030E8B
:100C7000416E0F015C51800B5C6F000E5D6FC19681
:100C8000C198C19A5E6B5F6B34D0020019000012EC
:100C9000008609FF04060001C200A4600006FF01EF
:100CA00097094BB404C000478007FF029208FC4933
:100CB000A500000007FF02930005517D0000000819
:100CC000FF039102010142C500000AFF0522000056
:100CD0001300642A8907FF022100FAD61B000000D6
:100CE000C75354532D4F4B00C75354532D4E4700F9
:100CF0000000000EF86E0C0EF76E8A0EF66E0900FC
:100D0000F550006E000A13E00900F550016EE8BED0
:100D100005D00F0BEA6E0900F5CFE9FF01BC090011
:100D200001AC0900F5CFEEFF004EE9D7F9D7F86A1C
:0A0D3000000128EF02F067D703006E
:020000040030CA
:0E00000015127E7C0009910000800FE00F4079
:00000001FF
;PIC18F26K80
;CRC=7E53 CREATED="27-11-24 15:28"

BIN
Document/Layout.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 61 KiB

Some files were not shown because too many files have changed in this diff Show More