From 59e396f6a6a96e7fa2a2986a471fbe577af73191 Mon Sep 17 00:00:00 2001
From: wxr <464027401@qq.com>
Date: 星期四, 13 七月 2023 17:14:57 +0800
Subject: [PATCH] 安卓优化
---
HDL_ON/DAL/DriverLayer/UdpSocket.cs | 1 -
HDL_ON/DAL/DriverLayer/Control.cs | 2 +-
HDL_ON/DAL/Mqtt/MqttClient.cs | 1 +
3 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/HDL_ON/DAL/DriverLayer/Control.cs b/HDL_ON/DAL/DriverLayer/Control.cs
index a6dcaa1..e60e1ae 100644
--- a/HDL_ON/DAL/DriverLayer/Control.cs
+++ b/HDL_ON/DAL/DriverLayer/Control.cs
@@ -285,6 +285,7 @@
}
else if (MainPage.InternetStatus == 2)
{
+ DAL.Mqtt.MqttClient.InitState();
OpenUdp(DB_ResidenceData.Instance.GatewayType == 0 ? 6000 : 8585);
//閲嶇疆鎼滅储缃戝叧鏍囧織
IsSearchLocalGatewaySuccessful = false;
@@ -311,7 +312,6 @@
System.Threading.Thread.Sleep(500);
}
- DAL.Mqtt.MqttClient.InitState();
})
{ IsBackground = true }.Start();
}
diff --git a/HDL_ON/DAL/DriverLayer/UdpSocket.cs b/HDL_ON/DAL/DriverLayer/UdpSocket.cs
index 6d64a06..36637f9 100644
--- a/HDL_ON/DAL/DriverLayer/UdpSocket.cs
+++ b/HDL_ON/DAL/DriverLayer/UdpSocket.cs
@@ -77,7 +77,6 @@
}
catch { }
busSocket = null;
- HDL_ON.DriverLayer.Control.Ins.GatewayOnline_Cloud = HDL_ON.DriverLayer.Control.Ins.GatewayOnline_Local = false;
MainPage.Log("Socket鍏抽棴");
}
diff --git a/HDL_ON/DAL/Mqtt/MqttClient.cs b/HDL_ON/DAL/Mqtt/MqttClient.cs
index b6be181..a403e13 100644
--- a/HDL_ON/DAL/Mqtt/MqttClient.cs
+++ b/HDL_ON/DAL/Mqtt/MqttClient.cs
@@ -110,6 +110,7 @@
{
MqttInfoConfig.Current.IfGetMqttInfoSuccess = false;
}
+ Control.Ins.GatewayOnline_Cloud = Control.Ins.GatewayOnline_Local = false;
await DisConnectRemoteMqttClient(s);
}
--
Gitblit v1.8.0