From 5bfb959c47017825c8cf7dc8570c55b04dab694c Mon Sep 17 00:00:00 2001 From: wxr <464027401@qq.com> Date: 星期三, 09 六月 2021 16:42:11 +0800 Subject: [PATCH] Merge branch 'dev-tzy' into wxr6 --- HDL_ON/DAL/Mqtt/MqttClient.cs | 12 ++++-------- 1 files changed, 4 insertions(+), 8 deletions(-) diff --git a/HDL_ON/DAL/Mqtt/MqttClient.cs b/HDL_ON/DAL/Mqtt/MqttClient.cs index f1b92dd..90cc0da 100644 --- a/HDL_ON/DAL/Mqtt/MqttClient.cs +++ b/HDL_ON/DAL/Mqtt/MqttClient.cs @@ -133,7 +133,7 @@ { try { - System.Threading.Thread.Sleep(2000); + System.Threading.Thread.Sleep(500); //杩涘叆鍚庡彴涓嶅鐞� if (MainPage.IsEnterBackground) continue; if (MqttInfoConfig.Current.HomeGatewayInfo == null) @@ -330,14 +330,14 @@ { var bytes = Securitys.EncryptionService.AesDecryptPayload(e.ApplicationMessage.Payload, tuyaEncryptKey); var revString = Encoding.UTF8.GetString(bytes); - HDL_ON.UI.UI2.PersonalCenter.PirDevice.PirMethod.controldata = revString; + HDL_ON.UI.UI2.PersonalCenter.PirDevice.Method.controldata = revString; } //App璁㈤槄閬ユ帶鍣ㄨ嚜瀛︽寜閿涔犳垚鍔熼�氱煡 else if (topic == $"/user/{DB_ResidenceData.Instance.CurrentRegion.id}/app/thing/event/irCodeStudyDone/up") { var bytes = Securitys.EncryptionService.AesDecryptPayload(e.ApplicationMessage.Payload, tuyaEncryptKey); var revString = Encoding.UTF8.GetString(bytes); - UI.UI2.PersonalCenter.PirDevice.PirMethod.buttondata = revString; + UI.UI2.PersonalCenter.PirDevice.Method.buttondata = revString; } #region 鏁版嵁鏇存柊鎺ㄩ�佷富棰� //appHomeRefresh锛氫綇瀹呮暟鎹埛鏂伴�氱煡 @@ -485,8 +485,6 @@ catch (Exception ex) { Utlis.WriteLine($"error:" + ex.Message); - //mqtt杩炴帴寮傚父锛屾竻绌烘湰鍦癿qtt淇℃伅锛屽彲鑳介渶瑕侀噸鏂拌幏鍙栵細wxr - MqttInfoConfig.Current.Refresh(); } finally { @@ -628,8 +626,6 @@ //閲嶆柊涓績鏈嶅姟鍣ㄨ幏鍙栧弬鏁版爣璁� MqttInfoConfig.Current.IfGetMqttInfoSuccess = false; Console.WriteLine("Connect error: " + ex.Message); - //mqtt杩炴帴寮傚父锛屾竻绌烘湰鍦癿qtt淇℃伅锛屽彲鑳介渶瑕侀噸鏂拌幏鍙栵細wxr - MqttInfoConfig.Current.Refresh(); } finally { @@ -821,7 +817,7 @@ /// <returns></returns> static async Task GetMqttInfoAndMQTTConnectAsync() { - var mqttInfoRequestResult_Obj = new HttpServerRequest().GetMqttRemoteInfo(GetRandomKey()); + var mqttInfoRequestResult_Obj = new Server.HttpServerRequest().GetMqttRemoteInfo(GetRandomKey()); if (mqttInfoRequestResult_Obj != null) { MqttInfoConfig.Current.mMqttInfo = mqttInfoRequestResult_Obj; -- Gitblit v1.8.0