From b0505adb3ea1ba3f1812ee1046499410c8ea57f5 Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期一, 18 五月 2020 16:09:46 +0800
Subject: [PATCH] 225552552525

---
 ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs |   16 +++++++++++++++-
 1 files changed, 15 insertions(+), 1 deletions(-)

diff --git a/ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs b/ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs
index a572e70..4c6de8a 100755
--- a/ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs
+++ b/ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs
@@ -108,7 +108,12 @@
         /// 0锛氳澶囦笉鍦ㄧ嚎
         /// <para>1锛氳澶囧湪绾�</para>
         /// </summary>
-        public int IsOnline;
+        public int IsOnline;
+        /// <summary>
+        /// 1锛氳矾鐢辫澶�
+        /// <para>2锛氱粓绔澶囷紝鐢垫睜璁惧</para>
+        /// </summary>
+        public int ZigbeeType;
         /// <summary>
         /// 褰撳墠杩愯绋嬪簭鐗堟湰淇℃伅銆� 鏈�澶�64瀛楄妭
         /// </summary>
@@ -291,6 +296,10 @@
             {
                 device = Newtonsoft.Json.JsonConvert.DeserializeObject<FreshAir>(strDeviceByte);
             }
+            else if (strDeviceType == ZigBee.Device.DeviceType.PMSensor.ToString())
+            {
+                return Newtonsoft.Json.JsonConvert.DeserializeObject<PMSensor>(strDeviceByte);
+            }
             else { return null; }
             //鑳藉皯瀛樹竴涓彉閲忓氨灏戝瓨涓�涓�
             device.Type = (DeviceType)device.DeviceID;
@@ -376,6 +385,11 @@
                     //鏂伴 
                     IconPath = "Device/FreshAirEpoint.png";
                 }
+                else if (this.Type == DeviceType.PMSensor)
+                {
+                    //PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� 
+                    IconPath = "Device/AirQualitySensorEpoint.png";
+                }
                 else if (this.Type == DeviceType.FreshAirHumiditySensor)
                 {
                     //婀垮害浼犳劅鍣�

--
Gitblit v1.8.0