This commit is contained in:
chi
2025-05-26 17:19:36 +09:00
parent 8d0f0f8c8f
commit d6e7c118fb
40 changed files with 1550 additions and 3133 deletions

View File

@@ -10,12 +10,13 @@ using System.Windows.Forms;
using Project.StateMachine;
using COMM;
using AR;
using System.Security.Cryptography.X509Certificates;
namespace Project.ViewForm
{
public partial class fAuto : Form
{
AGVControl.MapControl mapctl;
public fAuto()
{
InitializeComponent();
@@ -26,12 +27,12 @@ namespace Project.ViewForm
this.ctlAuto1.Scean = CtlAuto.eScean.Progress;
else
this.ctlAuto1.Scean = CtlAuto.eScean.Normal;
this.mapctl = new AGVControl.MapControl();
this.mapctl.Dock = DockStyle.Fill;
this.mapctl.Visible = true;
this.mapctl.Font = this.panel1.Font;
this.mapctl.BackColor = Color.FromArgb(32, 32, 32);
this.panel1.Controls.Add(mapctl);
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 fAuto_Load(object sender, EventArgs e)
{
@@ -41,7 +42,8 @@ namespace Project.ViewForm
ctlAuto1.dev_xbe = PUB.XBE;
this.timer1.Start();
PUB.AGV.DataReceive += AGV_DataReceive;
//auto load
var path = new System.IO.DirectoryInfo("route");
if (path.Exists == false) path.Create();
@@ -61,7 +63,8 @@ namespace Project.ViewForm
if (fi.Exists)
{
PUB.log.Add($"autoload : {fi.FullName}");
this.mapctl.LoadFromFile(fi.FullName);
var errmsg = PUB.mapctl.LoadFromFile(fi.FullName);
if (errmsg.isEmpty() == false) AR.UTIL.MsgE(errmsg);
}
}
}
@@ -72,7 +75,8 @@ namespace Project.ViewForm
{
case arDev.Narumi.DataType.TAG:
var tagno = PUB.AGV.data.TagNo;
this.mapctl.AGVMoveToRFID(tagno.ToString());
PUB.log.Add($"[auto] recv tag : {tagno}");
PUB.mapctl.SetCurrentPosition(tagno);
break;
}
}