diff --git a/.gitignore b/.gitignore
index e9b35cdc..54638263 100644
--- a/.gitignore
+++ b/.gitignore
@@ -9,4 +9,5 @@
*.suo
*.vs
*.csproj.AssemblyReference.cache
-*/obj/
\ No newline at end of file
+*/obj/
+/Aucma.Scada.UI/bin/Debug/Log/2023-12-08
diff --git a/Aucma.Scada.HikRobot/MvCodeHelper.cs b/Aucma.Scada.HikRobot/MvCodeHelper.cs
index 2d37bc85..9d72138a 100644
--- a/Aucma.Scada.HikRobot/MvCodeHelper.cs
+++ b/Aucma.Scada.HikRobot/MvCodeHelper.cs
@@ -38,7 +38,7 @@ namespace Aucma.Core.Scanner
/// 获取不到任务设备即连接失败
///
///
- public bool ConnectionStatus(string ip)
+ public static bool ConnectionStatus(string ip)
{
// 遍历所有已打开相机
foreach (KeyValuePair hashmap in m_cMyDevices)
diff --git a/Aucma.Scada.UI/Aucma.Scada.UI.csproj b/Aucma.Scada.UI/Aucma.Scada.UI.csproj
index 8a5c1f41..05b1cfb1 100644
--- a/Aucma.Scada.UI/Aucma.Scada.UI.csproj
+++ b/Aucma.Scada.UI/Aucma.Scada.UI.csproj
@@ -250,6 +250,12 @@
Settings.settings
True
+
+ Always
+
+
+ Always
+
ResXFileCodeGenerator
Resources.Designer.cs
@@ -294,6 +300,10 @@
{deabc30c-ec6f-472e-bd67-d65702fdaf74}
HighWayIot.Log4net
+
+ {4EE4C3E2-AC45-4275-8017-E99D70FC1F52}
+ HighWayIot.Plc
+
{d0dc3cfb-6748-4d5e-b56a-76fdc72ab4b3}
HighWayIot.Repository
diff --git a/Aucma.Scada.UI/MainWindow.xaml b/Aucma.Scada.UI/MainWindow.xaml
index 0b157f59..f1c26744 100644
--- a/Aucma.Scada.UI/MainWindow.xaml
+++ b/Aucma.Scada.UI/MainWindow.xaml
@@ -59,11 +59,6 @@
-
-
-
-
-
@@ -75,110 +70,38 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Aucma.Scada.UI/templates/image/Green.png b/Aucma.Scada.UI/templates/image/Green.png
new file mode 100644
index 00000000..ed977c4d
Binary files /dev/null and b/Aucma.Scada.UI/templates/image/Green.png differ
diff --git a/Aucma.Scada.UI/templates/image/Red.png b/Aucma.Scada.UI/templates/image/Red.png
new file mode 100644
index 00000000..bf46c31d
Binary files /dev/null and b/Aucma.Scada.UI/templates/image/Red.png differ
diff --git a/Aucma.Scada.UI/viewModel/MainViewModel.cs b/Aucma.Scada.UI/viewModel/MainViewModel.cs
index 81c21dff..28f8ee29 100644
--- a/Aucma.Scada.UI/viewModel/MainViewModel.cs
+++ b/Aucma.Scada.UI/viewModel/MainViewModel.cs
@@ -1,12 +1,16 @@
-using Aucma.Scada.UI.Page.AssemblyPlan;
+using Aucma.Core.Scanner;
+using Aucma.Scada.UI.Page.AssemblyPlan;
using Aucma.Scada.UI.Page.InStoreInfo;
using Aucma.Scada.UI.Page.InventoryInfo;
using Aucma.Scada.UI.Page.OutStoreInfo;
using Aucma.Scada.UI.Page.TaskInfo;
using GalaSoft.MvvmLight;
using GalaSoft.MvvmLight.Command;
+using HighWayIot.Config;
using HighWayIot.Log4net;
+using HighWayIot.Plc;
using System;
+using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Windows;
@@ -15,6 +19,9 @@ namespace Aucma.Scada.UI.viewModel
{
public class MainViewModel : ViewModelBase
{
+ private AppConfig appConfig = AppConfig.Instance;
+ private PlcPool _pool = PlcPool.Instance;
+ private Dictionary _plcDictionary = new Dictionary();
private LogHelper logHelper = LogHelper.Instance;
private readonly LogInfoControl logInfoControl = new LogInfoControl();
private readonly InStoreInfoControl inStoreInfoControl = new InStoreInfoControl();
@@ -22,9 +29,10 @@ namespace Aucma.Scada.UI.viewModel
private readonly TaskInfoControl taskInfoControl = new TaskInfoControl();
private readonly InventoryInfoControl inventoryInfoControl = new InventoryInfoControl();
private readonly AssemblyPlanControl assemblyPlanControl = new AssemblyPlanControl();
-
+
public MainViewModel()
{
+
ControlOnClickCommand = new RelayCommand