Files
ENIG/Cs_HMI/SubProject/AGVControl/Models/MagnetLine.cs
backuppc 4a45ae15d6 ..
2025-07-14 16:32:56 +09:00

86 lines
2.1 KiB
C#

using System.Drawing;
using System;
using System.Collections.Generic;
using System.Windows.Forms;
namespace AGVControl.Models
{
/// <summary>
/// 도로특성정보
/// </summary>
public class RoadInformation
{
/// <summary>
/// 시작지점
/// </summary>
public RFIDPoint P1 { get; set; }
/// <summary>
/// 종료지점
/// </summary>
public RFIDPoint P2 { get; set; }
/// <summary>
/// 도로의 사용여부
/// </summary>
public bool Enable { get; set; }
/// <summary>
/// AGV의 이동방향(리프트방향)
/// 목적지 방향과의 일치를 위해 해당 방향을 설정할 수 있따
/// </summary>
public AgvDir? LiftDirection { get; set; }
/// <summary>
/// AGV이동시 속도 (high, middle, low)
/// </summary>
public AgvSpeed? MoveSpeed { get; set; }
/// <summary>
/// AGV이동시 방향모드(좌분기, 전진, 우분기)
/// </summary>
public AgvSts? MoveDirection { get; set; }
public RoadInformation()
{
P1 = null;
P2 = null;
LiftDirection = null;
MoveSpeed = null;
MoveDirection = null;
Enable = false;
}
/// <summary>
/// 값이 설정되어있는지
/// </summary>
public bool HasValue
{
get
{
if (P1 == null || P2 == null) return false;
if (LiftDirection == null && MoveSpeed == null && MoveDirection == null) return false;
return true;
}
}
}
public class MagnetLine
{
public Point StartPoint { get; set; }
public Point EndPoint { get; set; }
public List<Point> BranchPoints { get; set; }
public Dictionary<Point, BranchDirection> BranchDirections { get; set; }
public MagnetLine()
{
BranchPoints = new List<Point>();
BranchDirections = new Dictionary<Point, BranchDirection>();
}
}
}