From e22fdb94322e6cec38e5e4a9aec13d431a133fde Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期二, 28 四月 2020 16:32:35 +0800
Subject: [PATCH] 上传合并后的代码

---
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlDeviceAttributeLogic.cs |   50 ++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 50 insertions(+), 0 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlDeviceAttributeLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlDeviceAttributeLogic.cs
index 653e1d9..bc94bb7 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlDeviceAttributeLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlDeviceAttributeLogic.cs
@@ -236,6 +236,56 @@
 
         #endregion
 
+        #region 鈻� 鏂伴_______________________________
+        /// <summary>
+        /// SendFreshAirStatuComand
+        /// </summary>
+        /// <param name="device">璁惧</param>
+        public void SendFreshAirStatuComand(CommonDevice device)
+        {
+            if (device == null)
+            {
+                return;
+            }
+            new System.Threading.Thread(() =>
+            {
+                SendFreshAirFanStatuComand(device);
+                System.Threading.Thread.Sleep(300);
+            })
+            { IsBackground = true }.Start();
+        }
+
+        /// <summary>
+        /// SendFanStatuComand
+        /// </summary>
+        /// <param name="device">璁惧</param>
+        private void SendFreshAirFanStatuComand(CommonDevice device)
+        {
+            if (device == null)
+            {
+                return;
+            }
+            var jObject = new Newtonsoft.Json.Linq.JObject
+            {
+                { "DeviceAddr",device.DeviceAddr },
+                { "Epoint", device.DeviceEpoint },
+                { "Cluster_ID", (int)Cluster_ID.FanControl },
+                { "Command", 108 }
+            };
+            var attriBute = new Newtonsoft.Json.Linq.JArray
+            {
+               new Newtonsoft.Json.Linq.JObject
+               {
+                 { "AttriButeId", (int)AttriButeId.FanMode}
+               }
+            };
+            var data = new Newtonsoft.Json.Linq.JObject { { "AttriBute", attriBute } };
+            jObject.Add("Data", data);
+            device.Gateway?.Send("GetDeviceStatus", jObject.ToString());
+        }
+
+        #endregion
+
         #region 鈻� 绐楀笜_______________________________
         /// <summary>
         /// 鍙戦�佽幏鍙栫獥甯樼姸鎬佸懡浠�

--
Gitblit v1.8.0