From 2029e64ec0491f7e511dc15bffaf821bfbabe2de Mon Sep 17 00:00:00 2001
From: 黄学彪 <hxb@hdlchina.com.cn>
Date: 星期一, 20 七月 2020 14:10:22 +0800
Subject: [PATCH] 上传一个很特别的新版本

---
 ZigbeeApp/GateWay.Droid/Assets/Language.ini                                                             |  153 -
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs                            |   26 
 ZigbeeApp/Home.Ios/Resources/DeviceName.ini                                                             |  198 ++
 ZigbeeApp/Shared/Phone/Category/Controls/DeviceRow/Base/DeviceRowCommon.cs                              |   50 
 ZigbeeApp/Shared/Phone/UserCenter/Member/AddMemberInfoForm.cs                                           |   16 
 ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs                                     |   14 
 ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionFileContentForm.cs                               |   36 
 ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldPhoneForm.cs                                         |    6 
 ZigbeeApp/Shared/Phone/Category/CategoryMainForm.cs                                                     |   64 
 ZigbeeApp/Shared/Phone/ZigBee/Device/ZbGateway.cs                                                       |   61 
 ZigbeeApp/Shared/Phone/UserCenter/Guide/GuideForm1.cs                                                   |    4 
 ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewPhoneForm.cs                                         |    4 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Resourse/DirectoryFileNameResourse.cs                      |    7 
 ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewaySearchForm.cs                                  |   55 
 ZigbeeApp/Shared/Phone/ZigBee/Common/Config.cs                                                          |   15 
 ZigbeeApp/Shared/Phone/UserCenter/SharedContent/AddNewSharedContentForm.cs                              |   12 
 ZigbeeApp/Shared/DLL/IOS/Shared.IOS.TBL.dll                                                             |    0 
 ZigbeeApp/Shared/Phone/MainPage/Controls/SceneCardControl.cs                                            |    8 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/SafetyMasterControl.cs           |    8 
 ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceManagementForm.cs                                  |    2 
 ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayInfoEditorForm.cs                               |    7 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/DeviceControls/GatewayRowControl.cs               |   39 
 ZigbeeApp/Shared/Phone/CommonForm/CommonFormBase.cs                                                     |    2 
 ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayListForm.cs                                     |    6 
 ZigbeeApp/Shared/Phone/Device/Logic/CurrentDeviceState.cs                                               |    2 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayLogic.cs                                   |  160 -
 ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewaySearchForm.cs                                 |   55 
 ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs                                                     |  487 +++--
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Form/AreaCodeSelectForm.cs                                 |    4 
 ZigbeeApp/Shared/Phone/UserCenter/Abount/AbountForm.cs                                                  |    4 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlWifiLogic.cs                                      |   86 
 ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotSecondaryPasswordForm.cs                               |    6 
 ZigbeeApp/Shared/DLL/IOS/Shared.IOS.xml                                                                 |  163 +
 ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceListMainForm.cs                                          |   61 
 ZigbeeApp/Shared/Phone/UserCenter/UserMain/MessageManagementForm.cs                                     |    6 
 ZigbeeApp/Shared/Phone/UserView/LoginLoading.cs                                                         |    4 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/RoomDeviceGroupMenuControl.cs    |  139 -
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFirmwareUpdateLogic.cs                            |    8 
 ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessApSearchForm.cs                                   |   53 
 ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs                                                 |   14 
 ZigbeeApp/Shared/Phone/UserCenter/Device/Panel/PanelColorSelectForm.cs                                  |   54 
 ZigbeeApp/Shared/Phone/MainPage/UnallocatedRoomForm.cs                                                  |   30 
 ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionSearchAllFile.cs                                 |   16 
 ZigbeeApp/GateWay.Droid/Assets/DeviceName.ini                                                           |  198 ++
 ZigbeeApp/Shared/Phone/Device/CommonForm/SceneCategoryView.cs                                           |    8 
 ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceGeneralInformationForm.cs                                |    2 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Common/UserCenterCommon.cs                                 |   47 
 ZigbeeApp/Shared/Phone/Login/AccountLoginForm.cs                                                        |    6 
 ZigbeeApp/Shared/Phone/UserCenter/Member/MemberManagementForm.cs                                        |    2 
 ZigbeeApp/Shared/DLL/IOS/Shared.IOS.dll                                                                 |    0 
 ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewEmailForm.cs                                         |    6 
 ZigbeeApp/GateWay.Droid/GateWay.Droid.csproj                                                            |    1 
 ZigbeeApp/Shared/Phone/Category/SelectHouseForm.cs                                                      |   18 
 ZigbeeApp/Shared/Common/CommonPage.cs                                                                   |   20 
 ZigbeeApp/Shared/Phone/Device/Logic/Send.cs                                                             |   62 
 ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionMainForm.cs                                      |    2 
 ZigbeeApp/Shared/Phone/CommonForm/EditorCommonForm.cs                                                   |    2 
 ZigbeeApp/GateWay.Droid/Application.cs                                                                  |    6 
 ZigbeeApp/Shared/Phone/MainPage/HomeMainPageForm.cs                                                     |    5 
 ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceSearchForm.cs                                            |    9 
 ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayProductInfoForm.cs                              |    3 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/FrameLayoutControls/FrameLayoutStatuControl.cs    |    2 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlResidenceLogic.cs                                 |  182 ++
 ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotAccountPasswordForm.cs                                 |    6 
 ZigbeeApp/GateWay.Droid/Properties/AndroidManifest.xml                                                  |    4 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFileLogic.cs                                      |   13 
 ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessUdpSearchForm.cs                                  |   53 
 ZigbeeApp/Shared/Phone/UserCenter/Safety/GarrisonAreaDelayedSettionForm.cs                              |    4 
 ZigbeeApp/Shared/Phone/Device/CommonForm/SelectTime.cs                                                  |    2 
 ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldEmailForm.cs                                         |    6 
 ZigbeeApp/Shared/Phone/MainPage/Controls/DeviceCard/Base/DeviceCardCommon.cs                            |   52 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayBackupLogic.cs                             |    2 
 ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddSceneForm.cs                                     |    2 
 ZigbeeApp/Shared/Phone/MainPage/DeviceDetailInfoForm.cs                                                 |    4 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/LoadingControl.cs                  |    4 
 ZigbeeApp/Home.Ios/Resources/Language.ini                                                               |  154 -
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/IconControlCommon.cs     |    4 
 ZigbeeApp/Home.Ios/Home.IOS.csproj                                                                      |    1 
 ZigbeeApp/Shared/Phone/MainPage/Controls/SafetyShortcutControl.cs                                       |   12 
 ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs                                      |   37 
 ZigbeeApp/Shared/R.cs                                                                                   |  274 ---
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/MessageControls/ShowMsgControl.cs                 |   34 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlLogLogic.cs                                       |   33 
 ZigbeeApp/Shared/Phone/Category/AdjustTargetAddDeviceForm.cs                                            |   26 
 ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceHistoryFirmwareVersionForm.cs                            |    2 
 ZigbeeApp/Shared/Common/Device.cs                                                                       |  743 ++++----
 ZigbeeApp/Shared/Phone/UserCenter/HdlBackup/HdlAutoBackupForm.cs                                        |    2 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/UserCenterLogic.cs                                   |   47 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlSceneLogic.cs                                     |  231 +-
 ZigbeeApp/Shared/Phone/UserCenter/SharedContent/LookSharedContentForm.cs                                |   12 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/RowLayoutControls/DeviceFunctionTypeRowControl.cs |   12 
 ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceListForm.cs                                        |   47 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/ClickButtonCommon.cs     |    2 
 ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs                                                    |    8 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/MessageManagementControl.cs        |    4 
 ZigbeeApp/Shared/Phone/UserCenter/Residence/LookRoomSettionForm.cs                                      |  101 
 ZigbeeApp/Shared/Phone/UserCenter/Safety/SafetyManagementMainForm.cs                                    |    6 
 ZigbeeApp/Shared/Phone/Device/Logic/Illumination.cs                                                     |   72 
 ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayUpdateLogic.cs                             |    2 
 99 files changed, 2,777 insertions(+), 1,967 deletions(-)

diff --git a/ZigbeeApp/GateWay.Droid/Application.cs b/ZigbeeApp/GateWay.Droid/Application.cs
index d149de0..d828f44 100755
--- a/ZigbeeApp/GateWay.Droid/Application.cs
+++ b/ZigbeeApp/GateWay.Droid/Application.cs
@@ -159,7 +159,7 @@
                 Shared.Application.FontSize = 12;
                 AppCenter.Start("4802834a-e7e9-4dd8-93f1-c2f88f0bd464", typeof(Analytics), typeof(Crashes));鈥�#if Release鈥�                //淇濆瓨鑾峰彇鐨勬瀬鍏夋湇鍔″櫒涓婄殑娉ㄥ唽ID鍒版湰鍦版枃浠垛��                var registrationId = JPushInterface.GetRegistrationID(activity);
                 System.Console.WriteLine("registrationId-鏋佸厜id=" + registrationId);
-                if (!string.IsNullOrEmpty(registrationId))鈥�                {鈥�                    Shared.Common.Config.Instance.RegistrationID = registrationId;鈥�                    Shared.Common.Config.Instance.Save();鈥�                }鈥�#endif鈥�            };鈥ㄢ��           鈥�            BaseActivity.RefreshUIAction += (activity) => {鈥�                Shared.Language.CurrentLanguage = "Chinese";鈥�                Shared.Common.CommonPage.Instance.Show();鈥�             };鈥ㄢ��            BaseActivity.NetworkStateChanged += (v) =>鈥�            {鈥�            };鈥�            BaseActivity.OnDestroyAction += (activity) => {鈥�            //socket鍋滄杩炴帴鈥�            //ZigBee.Device.ZbGateway.FindGateWaySocket.Stop();鈥�            };鈥ㄢ��            HDLUtils.SetAuthoritiesName("com.hdl.home.fileProvider");鈥�         }鈥ㄢ��        public static bool IsShowTip = true;鈥�        JpushNotificationReceiver myReceiver = new JpushNotificationReceiver { };鈥ㄢ��        /// <summary>鈥�        /// 椤圭洰鍚姩鏃剁綉缁滄煡璇⑩��        /// </summary>鈥�        void checkSomeInfo()鈥�        {鈥�            var status = isNetworkAvailable(this);鈥�            string internetStatus = "Available";鈥�            if (!status)鈥�            {鈥�                internetStatus = "UnaVailable";鈥�            }鈥�            else鈥�            {鈥�                var isWifi = isWifiConnected(this);鈥�                if (isWifi)鈥�                {鈥�                    internetStatus = "WiFiConnect";鈥�                }鈥�                else鈥�                {鈥�                    internetStatus = "MobileConnect";鈥�                }鈥�            }鈥ㄢ��            int connectState = 0;鈥�            if (internetStatus == "UnaVailable")鈥�            {鈥�                connectState = 0;鈥�            }鈥�            else if (internetStatus == "WiFiConnect")鈥�            {鈥�                connectState = 2;鈥�            }鈥�            else鈥�            {鈥�                connectState = 1;鈥�            }鈥�            //ZigBee.Device.ZbGateway.CheckConnection(connectState);鈥�         }鈥ㄢ��        /// <summary>鈥�        /// 缃戠粶鏄惁鍙敤鈥�        /// </summary>鈥�        /// <returns><c>true</c>, if network available was ised, <c>false</c> otherwise.</returns>鈥�        /// <param name="context">Context.</param>鈥�        bool isNetworkAvailable(Context context)鈥�        {鈥�            var cm = (ConnectivityManager)context.GetSystemService(ConnectivityService);鈥ㄢ��            if (cm == null || cm.ActiveNetworkInfo == null)鈥�            {鈥�                //褰撳墠缃戠粶涓嶅彲鐢ㄢ��                return false;鈥�            }鈥�            else鈥�            {鈥�                return cm.ActiveNetworkInfo.IsAvailable;鈥�            }鈥�        }鈥ㄢ��        /// <summary>鈥�        /// 缃戠粶鏄惁杩炴帴鈥�        /// </summary>鈥�        /// <returns><c>true</c>, if wifi connected was ised, <c>false</c> otherwise.</returns>鈥�        /// <param name="context">Context.</param>鈥�        bool isWifiConnected(Context context)鈥�        {鈥�            if (context != null)鈥�            {鈥�                var cm = (ConnectivityManager)context.GetSystemService(ConnectivityService);鈥ㄢ��                var mWiFiNetworkInfo = cm.GetNetworkInfo(ConnectivityType.Wifi);鈥�                if (Android.Net.NetworkInfo.State.Connected == mWiFiNetworkInfo.GetState())鈥�                {鈥�                    //褰撳墠缃戠粶鏄疻i-Fi杩炴帴鈥�                    return true;鈥�                }鈥ㄢ��                var moWiFiNetworkInfo = cm.GetNetworkInfo(ConnectivityType.Mobile);鈥�                if (Android.Net.NetworkInfo.State.Connected == moWiFiNetworkInfo.GetState())鈥�                {鈥�                    //褰撳墠缃戠粶鏄疢obile杩炴帴鈥�                    return false;鈥�                }鈥�            }鈥�            return false;鈥�        }
+                if (!string.IsNullOrEmpty(registrationId))鈥�                {鈥�                    Shared.Common.Config.Instance.RegistrationID = registrationId;鈥�                    Shared.Common.Config.Instance.Save();鈥�                }鈥�                //璋冭瘯:璁板綍鏋佸厜ID鈥�                Shared.Phone.UserCenter.HdlLogLogic.Current.WriteOtherText(Shared.Phone.UserCenter.DirNameResourse.JiguangFile, "receive1:" + registrationId, true, true);鈥�#endif鈥�            };鈥ㄢ��           鈥�            BaseActivity.RefreshUIAction += (activity) => {鈥�                Shared.Language.CurrentLanguage = "Chinese";鈥�                Shared.Common.CommonPage.Instance.Show();鈥�             };鈥ㄢ��            BaseActivity.NetworkStateChanged += (v) =>鈥�            {鈥�            };鈥�            BaseActivity.OnDestroyAction += (activity) => {鈥�            //socket鍋滄杩炴帴鈥�            //ZigBee.Device.ZbGateway.FindGateWaySocket.Stop();鈥�            };鈥ㄢ��            HDLUtils.SetAuthoritiesName("com.hdl.home.fileProvider");鈥�         }鈥ㄢ��        public static bool IsShowTip = true;鈥�        JpushNotificationReceiver myReceiver = new JpushNotificationReceiver { };鈥ㄢ��        /// <summary>鈥�        /// 椤圭洰鍚姩鏃剁綉缁滄煡璇⑩��        /// </summary>鈥�        void checkSomeInfo()鈥�        {鈥�            var status = isNetworkAvailable(this);鈥�            string internetStatus = "Available";鈥�            if (!status)鈥�            {鈥�                internetStatus = "UnaVailable";鈥�            }鈥�            else鈥�            {鈥�                var isWifi = isWifiConnected(this);鈥�                if (isWifi)鈥�                {鈥�                    internetStatus = "WiFiConnect";鈥�                }鈥�                else鈥�                {鈥�                    internetStatus = "MobileConnect";鈥�                }鈥�            }鈥ㄢ��            int connectState = 0;鈥�            if (internetStatus == "UnaVailable")鈥�            {鈥�                connectState = 0;鈥�            }鈥�            else if (internetStatus == "WiFiConnect")鈥�            {鈥�                connectState = 2;鈥�            }鈥�            else鈥�            {鈥�                connectState = 1;鈥�            }鈥�            //ZigBee.Device.ZbGateway.CheckConnection(connectState);鈥�         }鈥ㄢ��        /// <summary>鈥�        /// 缃戠粶鏄惁鍙敤鈥�        /// </summary>鈥�        /// <returns><c>true</c>, if network available was ised, <c>false</c> otherwise.</returns>鈥�        /// <param name="context">Context.</param>鈥�        bool isNetworkAvailable(Context context)鈥�        {鈥�            var cm = (ConnectivityManager)context.GetSystemService(ConnectivityService);鈥ㄢ��            if (cm == null || cm.ActiveNetworkInfo == null)鈥�            {鈥�                //褰撳墠缃戠粶涓嶅彲鐢ㄢ��                return false;鈥�            }鈥�            else鈥�            {鈥�                return cm.ActiveNetworkInfo.IsAvailable;鈥�            }鈥�        }鈥ㄢ��        /// <summary>鈥�        /// 缃戠粶鏄惁杩炴帴鈥�        /// </summary>鈥�        /// <returns><c>true</c>, if wifi connected was ised, <c>false</c> otherwise.</returns>鈥�        /// <param name="context">Context.</param>鈥�        bool isWifiConnected(Context context)鈥�        {鈥�            if (context != null)鈥�            {鈥�                var cm = (ConnectivityManager)context.GetSystemService(ConnectivityService);鈥ㄢ��                var mWiFiNetworkInfo = cm.GetNetworkInfo(ConnectivityType.Wifi);鈥�                if (Android.Net.NetworkInfo.State.Connected == mWiFiNetworkInfo.GetState())鈥�                {鈥�                    //褰撳墠缃戠粶鏄疻i-Fi杩炴帴鈥�                    return true;鈥�                }鈥ㄢ��                var moWiFiNetworkInfo = cm.GetNetworkInfo(ConnectivityType.Mobile);鈥�                if (Android.Net.NetworkInfo.State.Connected == moWiFiNetworkInfo.GetState())鈥�                {鈥�                    //褰撳墠缃戠粶鏄疢obile杩炴帴鈥�                    return false;鈥�                }鈥�            }鈥�            return false;鈥�        }
 
        
     }
@@ -195,6 +195,10 @@
                         Shared.Common.Config.Instance.RegistrationID = regId;
                         Shared.Common.Config.Instance.Save();
                     }
+#if Release
+                    //璋冭瘯:璁板綍鏋佸厜ID
+                    Shared.Phone.UserCenter.HdlLogLogic.Current.WriteOtherText(Shared.Phone.UserCenter.DirNameResourse.JiguangFile, "receive2:" + regId, false, true);
+#endif
                 }
                 //鐢ㄦ埛鐐瑰嚮鎵撳紑浜嗛�氱煡
                 else if (JPushInterface.ActionNotificationOpened == intent.Action)
diff --git a/ZigbeeApp/GateWay.Droid/Assets/DeviceName.ini b/ZigbeeApp/GateWay.Droid/Assets/DeviceName.ini
new file mode 100755
index 0000000..7a871b7
--- /dev/null
+++ b/ZigbeeApp/GateWay.Droid/Assets/DeviceName.ini
@@ -0,0 +1,198 @@
+锘�;鍚勭璁惧鐨勫悕瀛楃殑瀹氫箟鏂囦欢
+;瀹氫箟瑙勫垯:鐢ㄦ枩鏉犻殧寮�
+
+;***************************************************************
+;              缃戝叧璁惧(缃戝叧鍙湁闀滃儚ID,涓嶉渶瑕佹灇涓�)
+;***************************************************************
+;闀滃儚ID=缂虹渷鍙傛暟 / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / 缂虹渷鍙傛暟 /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;澧欒缃戝叧銆�
+1 = 0 / 澧欒缃戝叧 / 澧欒缃戝叧 / 0 / 鏅鸿兘缃戝叧 / 鏅鸿兘缃戝叧
+;鏅鸿兘缃戝叧E7
+6 = 0 / 鏅鸿兘缃戝叧E7 / 鏅鸿兘缃戝叧E7 / 0 / 鏅鸿兘缃戝叧 / 鏅鸿兘缃戝叧
+;Mini缃戝叧銆�
+11 = 0 / Mini缃戝叧 / Mini缃戝叧 / 0 / 鏅鸿兘缃戝叧 / 鏅鸿兘缃戝叧
+;鐜舰缃戝叧銆�
+16 = 0 / 鐜舰缃戝叧 / 鐜舰缃戝叧 / 0 / 鏅鸿兘缃戝叧 / 鏅鸿兘缃戝叧
+
+;***************************************************************
+;                            绐楀笜璁惧
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;鏅鸿兘寮�鍚堝笜鐢垫満銆�
+MWM65B-ZB.20 = 100 / 绐楀笜鐢垫満 / 绐楀笜鐢垫満 / 100 / 閬槼 / 閬槼妯″潡
+;鏅鸿兘绠$姸鐢垫満銆�
+MVSM35B-ZB.20 = 101 / 鍗峰笜鐢垫満 / 鍗峰笜鐢垫満 / 100 / 閬槼 / 閬槼妯″潡
+
+;***************************************************************
+;                            闈㈡澘璁惧
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;4鎸夐敭瑙︽懜闈㈡澘(甯�4璺户鐢靛櫒搴曞骇)
+MPT4/R4-ZB.18 = 200 / 4鎸夐敭瑙︽懜闈㈡澘 / 4鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;3鎸夐敭瑙︽懜闈㈡澘
+MPT3/R3-ZB.18 = 201 / 3鎸夐敭瑙︽懜闈㈡澘 / 3鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;2鎸夐敭瑙︽懜闈㈡澘
+MPT2/R2-ZB.18 = 202 / 2鎸夐敭瑙︽懜闈㈡澘 / 2鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;12鎸夐敭瑙︽懜闈㈡澘
+MPT1/R1-ZB.18 = 203 / 12鎸夐敭瑙︽懜闈㈡澘 / 12鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;4鎸夐敭瑙︽懜闈㈡澘(鍙甫鐢垫簮搴曞骇)
+MPT4-ZB.18 = 210 / 4鎸夐敭瑙︽懜闈㈡澘 / 4鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�4鎸夐敭闈㈡澘銆�
+MPT4R4L/S-ZB.18 = 220 / 绠�绾�4鎸夐敭闈㈡澘 / 绠�绾�4鎸夐敭闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�3鎸夐敭闈㈡澘銆�
+MPT3R3L/S-ZB.18 = 221 / 绠�绾�3鎸夐敭闈㈡澘 / 绠�绾�3鎸夐敭闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�2鎸夐敭闈㈡澘銆�
+MPT2R2L/S-ZB.18 = 222 / 绠�绾�2鎸夐敭闈㈡澘 / 绠�绾�2鎸夐敭闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�4鎸夐敭鍦烘櫙闈㈡澘
+MPT4SC/S-ZB.18 = 224 / 绠�绾�4鎸夐敭鍦烘櫙闈㈡澘 / 绠�绾�4鎸夐敭鍦烘櫙闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�2璺獥甯橀潰鏉�
+MPT2W/S-ZB.18 = 226 / 绠�绾�2璺獥甯橀潰鏉� / 绠�绾�2璺獥甯橀潰鏉� / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鍗曞紑鍙屾帶闈㈡澘
+MP2B/TILE-ZB.18 = 240 / 鏂规偊鍗曞紑鍙屾帶闈㈡澘 / 鏂规偊鍗曞紑鍙屾帶闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鍙屽紑鍥涙帶闈㈡澘
+MP4B/TILE-ZB.18 = 241 / 鏂规偊鍙屽紑鍥涙帶闈㈡澘 / 鏂规偊鍙屽紑鍥涙帶闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鍥涘紑鍏帶闈㈡澘
+MP8B/TILE-ZB.18 = 242 / 鏂规偊鍥涘紑鍏帶闈㈡澘 / 鏂规偊鍥涘紑鍏帶闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鏂伴闈㈡澘
+MPFA/TILE-ZB.18 = 250 / 鏂规偊鏂伴闈㈡澘 / 鏂规偊鏂伴闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鐜闈㈡澘
+MPTE3/TILE-ZB.18 = 253 / 鏂规偊鐜闈㈡澘 / 鏂规偊鐜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绐楀笜闈㈡澘
+MP2W/TILE-ZB.18 = 256 / 绐楀笜闈㈡澘 / 绐楀笜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾﹀鍔熻兘闈㈡澘銆�
+MPTL4C/S-ZB.18 = 212 / 绠�绾﹀鍔熻兘闈㈡澘 / 绠�绾﹀鍔熻兘闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾︾幆澧冮潰鏉裤��
+MPTE3/S-ZB.18 = 230 / 绠�绾︾幆澧冮潰鏉� / 绠�绾︾幆澧冮潰鏉� / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+
+;***************************************************************
+;                           浼犳劅鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;pir浼犳劅鍣�220銆�
+MSPIR01-ZB.10 = 1200 / 鍚搁《寮忎汉浣撲紶鎰熷櫒 / 鍚搁《寮忎汉浣撲紶鎰熷櫒 / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鐞冨瀷绉诲姩浼犳劅鍣�
+MSPIRB-ZB.10 = 1205 / 鐞冨瀷绉诲姩浼犳劅鍣� / 鐞冨瀷绉诲姩浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鐕冩皵浼犳劅鍣�(楹︿箰鍏�)銆�
+MULTI-GASE--EA07 = 1300 / 鐕冩皵浼犳劅鍣�(閫傞厤鍣�) / 鐕冩皵浼犳劅鍣�(閫傞厤鍣�) / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;闂ㄧ獥纾佷紶鎰熷櫒(楹︿箰鍏�)銆�
+MULTI-MECI--EA01 = 1301 / 闂ㄧ獥浼犳劅鍣� / 闂ㄧ獥浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鐑熼浘浼犳劅鍣�(楹︿箰鍏�)銆�
+MULTI-FIRE--EA05 = 1302 / 鐑熼浘浼犳劅鍣� / 鐑熼浘浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;绾㈠浼犳劅鍣�(楹︿箰鍏�)銆�
+MULTI-MOTI--EA04 = 1303 / 浜轰綋浼犳劅鍣� / 浜轰綋浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;姘存蹈浼犳劅鍣�(楹︿箰鍏�)銆�
+MULTI-WATE--EA02 = 1304 / 姘存蹈浼犳劅鍣� / 姘存蹈浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;绱ф�ユ寜閿�(楹︿箰鍏�)
+MULTI-BURO--EA06 = 1305 / 绱ф�ユ寜閿� / 绱ф�ユ寜閿� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+
+;鐕冩皵浼犳劅鍣�(娌充笢)銆�
+MSG01/M-ZB.10 = 1300 / 鐕冩皵浼犳劅鍣�(閫傞厤鍣�) / 鐕冩皵浼犳劅鍣�(閫傞厤鍣�) / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;闂ㄧ獥纾佷紶鎰熷櫒(娌充笢)銆�
+MSDC01/M-ZB.10 = 1301 / 闂ㄧ獥浼犳劅鍣� / 闂ㄧ獥浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鐑熼浘浼犳劅鍣�(娌充笢)銆�
+MSS01/M-ZB.10 = 1302 / 鐑熼浘浼犳劅鍣� / 鐑熼浘浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;绾㈠浼犳劅鍣�(娌充笢)銆�
+MSPIR01/M-ZB.10 = 1303 / 浜轰綋浼犳劅鍣� / 浜轰綋浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;姘存蹈浼犳劅鍣�(娌充笢)銆�
+MSW01/M-ZB.10 = 1304 / 姘存蹈浼犳劅鍣� / 姘存蹈浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;绱ф�ユ寜閿�(娌充笢)
+MBU01/M-ZB.10 = 1305 / 绱ф�ユ寜閿� / 绱ф�ユ寜閿� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鍚搁《鐕冩皵浼犳劅鍣ㄣ��
+MGCD01/M-ZB.10 = 1306 / 鍚搁《寮忕噧姘斾紶鎰熷櫒 / 鍚搁《寮忕噧姘斾紶鎰熷櫒 / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� 
+MSPM25/M-ZB.10 = 1307 / PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� / PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� / 1307 / 绌烘皵璐ㄩ噺 / 浼犳劅鍣�
+
+;***************************************************************
+;                           缁х數鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;3璺户鐢靛櫒灏忔ā鍧椼��
+MPR0310-ZB.10 = 2300 / 3璺紑鍏冲皬妯″潡 / 3璺紑鍏冲皬妯″潡 / 2300 / 缁х數鍣� / 寮�鍏虫ā鍧�
+;鏂规偊鏂伴灏忔ā鍧�
+MFA01-ZB.10 = 2310 / 鏂规偊鏂伴灏忔ā鍧� / 鏂规偊鏂伴灏忔ā鍧� / 2300 / 缁х數鍣� / 鏂伴妯″潡
+
+;***************************************************************
+;                           璋冨厜鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;1璺皟鍏夊櫒灏忔ā鍧椼��
+MPD0101-ZB.10 = 2500 / 1璺皟鍏夊櫒灏忔ā鍧� / 1璺皟鍏夊櫒灏忔ā鍧� / 2500 / 璋冨厜鍣� / 璋冨厜妯″潡
+
+;***************************************************************
+;                           闂ㄩ攣璁惧
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;鏅鸿兘闂ㄩ攣(H06C)銆�
+H06C = 2800 / S-one 鏅鸿兘闂ㄩ攣 / S-one 鏅鸿兘闂ㄩ攣 / 2800 / 闂ㄩ攣 / 鏅鸿兘闂ㄩ攣
+;鏅鸿兘闂ㄩ攣(S-one)銆�
+S-one = 2802 / H06C 鏅鸿兘闂ㄩ攣 / H06C 鏅鸿兘闂ㄩ攣 / 2800 / 闂ㄩ攣 / 鏅鸿兘闂ㄩ攣
+
+;***************************************************************
+;                           绌鸿皟璁惧
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;zigbee绌鸿皟缃戝叧妯″潡銆�
+MAC/GW-ZB.10 = 3600 / CoolBox 涓ぎ绌鸿皟缃戝叧 / CoolBox 涓ぎ绌鸿皟缃戝叧 / 3600 / 绌鸿皟 / 绌鸿皟妯″潡
+
+;***************************************************************
+;                           涓户鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;zigbee涓户鍣ㄣ��
+MSR-ZB.10 = 3900 / 涓户鍣� / 涓户鍣� / 3900 / 涓户鍣� / 绯荤粺璁惧
+
+;***************************************************************
+;                          绌烘皵寮�鍏宠澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� / 璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;绌烘皵寮�鍏�
+MBCI01-ZB.10 = 4100 / 绌烘皵寮�鍏� / 绌烘皵寮�鍏� / 4100 / 鏅鸿兘绌哄紑 / 寮�鍏虫ā鍧�
+
+;***************************************************************
+;                          杞崲鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� / 璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;zigbee杞�485鍗忚杞崲鍣ㄣ��
+M485/GW-ZB.10 = 4200 / Zigbee-RS485 閫氳灏忔ā鍧� / Zigbee-RS485 閫氳灏忔ā鍧� / 4200 / 杞崲鍣� / 杞崲鍣�
+;zigbee杞琤uspro鍗忚杞崲鍣�
+MBUS/GW-ZB.10 = 4201 / zigbee杞琤uspro鍗忚杞崲鍣� / zigbee杞琤uspro鍗忚杞崲鍣� / 4200 / 杞崲鍣� / 杞崲鍣�
+
+
+;***************************************************************
+;                          绗笁鏂硅澶�
+;***************************************************************
+;鑷畾涔夊��=缂虹渷鍙傛暟 / 璁惧鐨勫畼鏂瑰悕瀛� / 缂虹渷鍙傛暟 / 缂虹渷鍙傛暟 / 缂虹渷鍙傛暟 / 璁惧绫诲瀷鍚嶅瓧
+;浠g爜閲岄潰闇�瑕佹參鎱竴涓竴涓猧f鍘诲~鍐�
+
+A400 = 0 / 閬槼 / 0 / 0 / 0 / 閬槼妯″潡
+A401 = 0 / 鎸夐敭闈㈡澘 / 0 / 0 / 0 / 鏅鸿兘闈㈡澘
+A402 = 0 / 浼犳劅鍣� / 0 / 0 / 0 / 浼犳劅鍣�
+A403 = 0 / 缁х數鍣� / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A404 = 0 / 璋冨厜鍣� / 0 / 0 / 0 / 璋冨厜妯″潡
+A405 = 0 / 闂ㄩ攣 / 0 / 0 / 0 / 鏅鸿兘闂ㄩ攣
+A406 = 0 / 绌鸿皟 / 0 / 0 / 0 / 绌鸿皟妯″潡
+A407 = 0 / 涓户鍣� / 0 / 0 / 0 / 绯荤粺璁惧
+A408 = 0 / 绌烘皵寮�鍏� / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A409 = 0 / 杞崲鍣� / 0 / 0 / 0 / 杞崲鍣�
+A410 = 0 / 褰╃伅 / 0 / 0 / 0 / 璋冨厜妯″潡
+A411 = 0 / 娓╂箍搴︿紶鎰熷櫒 / 0 / 0 / 0 / 浼犳劅鍣�
+A412 = 0 / 娓╁害浼犳劅鍣� / 0 / 0 / 0 / 浼犳劅鍣�
+A413 = 0 / 婀垮害浼犳劅鍣� / 0 / 0 / 0 / 浼犳劅鍣�
+A414 = 0 / 鏂伴 / 0 / 0 / 0 / 鏂伴妯″潡
+A415 = 0 / 绌烘皵璐ㄩ噺 / 0 / 0 / 0 / 浼犳劅鍣�
+A416 = 0 / 寮�鍏� / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A417 = 0 / 鎻掑骇 / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A418 = 0 / 鐏厜 / 0 / 0 / 0 / 璋冨厜妯″潡
+A419 = 0 / 骞叉帴鐐� / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A420 = 0 / 鑹叉俯鐏� / 0 / 0 / 0 / 璋冨厜妯″潡
\ No newline at end of file
diff --git a/ZigbeeApp/GateWay.Droid/Assets/Language.ini b/ZigbeeApp/GateWay.Droid/Assets/Language.ini
old mode 100644
new mode 100755
index c9a3528..6c90466
--- a/ZigbeeApp/GateWay.Droid/Assets/Language.ini
+++ b/ZigbeeApp/GateWay.Droid/Assets/Language.ini
@@ -624,8 +624,8 @@
 5408=铚傞福鍣�
 5409=鐜鍏夌収搴�
 5410=鐓у害鍊�<
-5411=鏆梴\r\n} 0lux
-5412=浜畕\r\n} 100lux
+5411=鏆�
+5412=浜�
 5413=鍦ㄥ鍐呮潯浠朵笅,榛戞殫鐓у害鍊肩害涓�0.02lux,榛勬槒鐓у害鍊納\r\n}绾︿负10lux,闃村ぉ鐓у害鍊肩害涓�5~50lux,璇锋牴鎹疄闄厈\r\n}闇�瑕佽繘琛岃皟鑺�
 5414=鍙瀵硅
 5415=鏍�
@@ -634,7 +634,7 @@
 
 
 
-10000=HDL Home
+10000=Evoyo Home
 10001=甯哥敤
 
 10100=鎵嬫満鍙�
@@ -1874,6 +1874,12 @@
 16135=鑾峰彇鍦烘櫙鍒楄〃澶辫触,缃戝叧鍥炲瓒呮椂
 16136=闇�閲嶆柊缁戝畾
 16137=鍑虹幇鎰忓鎯呭喌,鏁版嵁涓㈠け
+16138=鐑熼浘浼犳劅鍣�
+16139=姘翠镜浼犳劅鍣�
+16140=鐕冩皵浼犳劅鍣�
+16141=绱ф�ユ寜閽�
+16142=闂ㄧ獥浼犳劅鍣�
+16143=閽ュ寵鎵�
 
 ;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄帴鍙g殑杩斿洖淇℃伅缈昏瘧,浠�18000寮�濮嬧槄鈽呪槄鈽�
 18004=鎸囧畾缃戝叧宸茬粡琚粦瀹�
@@ -1961,139 +1967,16 @@
 ;鍚搁《鐕冩皵浼犳劅鍣ㄧ殑鍏ョ綉鎿嶄綔鎸囩ず
 21023=闀挎寜鍥剧ず鎸夐敭5绉掍互涓婏紝缁胯壊蹇棯{0}杩涘叆閰嶇綉鐘舵�侊紝缁跨伅甯镐寒鍒欏叆缃戞垚鍔�
 ;鐞冨瀷绉诲姩浼犳劅鍣ㄧ殑鍏ョ綉鎿嶄綔鎸囩ず
-21024=闀挎寜鍥剧ず鎸夐敭5绉掍互涓婏紝鎸囩ず鐏彉缁裤�侀棯鐑亄0}杩涘叆閰嶇綉鐘舵�侊紝缁跨伅鐔勭伃鍒欓厤缃戞垚鍔�
-
-;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄ā鍧桰D鐨勫畼鏂瑰悕瀛�,浠�30000寮�濮嬧槄鈽呪槄鈽�
-30000=绱ф�ユ寜閽�
-30001=鐕冩皵浼犳劅鍣�
-30002=鐑熼浘浼犳劅鍣�
-30003=姘翠镜浼犳劅鍣�
-30004=閽ュ寵鎵�
-30005=闂ㄧ獥浼犳劅鍣�
-30006=鏅鸿兘绌哄紑
-30007=Zigbee鏅鸿兘寮�鍚堝笜鐢垫満
-30008=4鎸夐敭瑙︽懜闈㈡澘(4璺户鐢靛櫒搴曞骇)
-30009=220Pir浼犳劅鍣�
-30010=1浠igbee缃戝叧(146搴曠洅澧欒妯″紡)
-30011=3鎸夐敭瑙︽懜闈㈡澘(3璺户鐢靛櫒搴曞骇)
-30012=2鎸夐敭瑙︽懜闈㈡澘(2璺户鐢靛櫒搴曞骇)
-30013=3璺户鐢靛櫒灏忔ā鍧�
-30014=1浠igbee缃戝叧(楂樼骇缃戝叧妗岄潰妯″紡)
-30015=璋冭瘯璁惧
-30016=Zigbee鏅鸿兘绠$姸鐢垫満
-30017=Zigbee涓户鍣�
-30018=12鎸夐敭瑙︽懜闈㈡澘(1璺户鐢靛櫒搴曞骇)
-30019=4鎸夐敭瑙︽懜闈㈡澘(鍙甫鐢垫簮搴曞骇)
-30020=Zigbee浜轰綋绉诲姩浼犳劅鍣�(鐞冨舰)
-30021=1璺皟鍏夊櫒灏忔ā鍧�
-30022=Zigbee杞珺uspro鍗忚杞崲鍣�
-30023=Zigbee杞�485鍗忚杞崲鍣�
-30024=Zigbee绌鸿皟缃戝叧妯″潡
-30025=H06C
-30026=绠�绾�4鎸夐敭闈㈡澘
-30027=绠�绾�3鎸夐敭闈㈡澘
-30028=绠�绾�2鎸夐敭闈㈡澘
-30029=鏂规偊鍗曞紑鍙屾帶闈㈡澘
-30030=鏂规偊鍙屽紑鍥涙帶闈㈡澘
-30031=鏂规偊鍥涘紑鍏帶闈㈡澘
-30032=鏂规偊鏂伴闈㈡澘
-30033=鏂规偊鐜闈㈡澘
-30034=绠�绾�4鎸夐敭鍦烘櫙闈㈡澘
-30035=绠�绾�2璺獥甯橀潰鏉�
-30036=鏂规偊/2璺獥甯橀潰鏉�-Z
-30037=S-one
-30038=鏂规偊鏂伴灏忔ā鍧�
-30039=Zigbee鍚搁《鐕冩皵浼犳劅鍣�
-30040=PM2.5绌烘皵璐ㄩ噺浼犳劅鍣�
-30041=绠�绾﹀鍔熻兘闈㈡澘
-30042=绠�绾︾幆澧冮潰鏉�
-30043=Mini缃戝叧
-30044=鑹叉俯鐏�
-30045=ZigBee鐞冨瀷绉诲姩浼犳劅鍣�
+21024=闀挎寜鍥剧ず鎸夐敭5绉掍互涓婏紝鎸囩ず鐏彉缁裤�侀棯鐑亄0}杩涘叆閰嶇綉鐘舵�侊紝缁跨伅鐔勭伃鍒欓厤缃戞垚鍔�
 
-;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄澶囨墍灞炵绫荤殑缈昏瘧鍚嶅瓧,浠�40000寮�濮嬧槄鈽呪槄鈽�
+;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄澶囨墍灞炵绫荤殑缈昏瘧鍚嶅瓧,浠�40000寮�濮� 娉細杩欎簺鎵�灞濱D宸茬粡涓嶅啀缁存姢鈽呪槄鈽呪槄
 40000=閬槼
 40001=鎸夐敭闈㈡澘
-40002=浼犳劅鍣�
-40003=缁х數鍣�
-40004=璋冨厜鍣�
-40005=闂ㄩ攣
 40006=绌鸿皟
-40007=涓户鍣�
-40008=鏅鸿兘绌哄紑
-40009=杞崲鍣�
-40010=褰╃伅
-40011=娓╂箍搴︿紶鎰熷櫒
-40012=娓╁害浼犳劅鍣�
-40013=婀垮害浼犳劅鍣�
 40014=寮�鍏�
 40015=鎻掑骇
 40016=鐏厜
-40017=骞叉帴鐐�
 40018=鏂伴
-40019=绌烘皵璐ㄩ噺
-
-;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄ā鍧桰D鐨勮澶囬粯璁ゅ娉ㄥ悕瀛�,浠�50000寮�濮�.娉�:瀹冨苟涓嶉渶瑕佸啀R.cs鏂囦欢涓畾涔夆槄鈽呪槄鈽�
-50000=绱ф�ユ寜閽�
-50001=Zigbee鐕冩皵浼犳劅鍣�
-50002=Zigbee鐑熼浘浼犳劅鍣�
-50003=Zigbee姘存蹈浼犳劅鍣�
-50004=閽ュ寵鎵�
-50005=Zigbee闂ㄧ獥浼犳劅鍣�
-50006=Zigbee鏅鸿兘绌哄紑
-50007=Zigbee寮�鍚堝笜鐢垫満
-50008=Zigbee 4鎸夐敭闈㈡澘
-50009=Zigbee鍚搁《寮忎汉浣撶Щ鍔ㄤ紶鎰熷櫒
-50010=Zigbee澧欒缃戝叧
-50011=Zigbee 3鎸夐敭闈㈡澘
-50012=Zigbee 2鎸夐敭闈㈡澘
-50013=Zigbee 3璺�10A缁х數鍣�
-50014=Zigbee妗岄潰缃戝叧
-50015=璋冭瘯璁惧
-50016=Zigbee鍗峰笜鐢垫満
-50017=Zigbee涓户鍣�
-50018=Zigbee 12鎸夐敭闈㈡澘
-50019=Zigbee 4鎸夐敭闈㈡澘
-50020=Zigbee浜轰綋绉诲姩浼犳劅鍣�(鐞冨舰)
-50021=Zigbee 1璺�1.5A璋冨厜鍣�
-50022=Zigbee杞珺uspro鍗忚杞崲鍣�
-50023=Zigbee杞�485鍗忚杞崲鍣�
-50024=Zigbee绌鸿皟缃戝叧妯″潡
-50025=Zigbee鏅鸿兘闂ㄩ攣
-50026=Zigbee绠�绾�4鎸夐敭闈㈡澘
-50027=Zigbee绠�绾�3鎸夐敭闈㈡澘
-50028=Zigbee绠�绾�2鎸夐敭闈㈡澘
-50029=Zigbee鏂规偊鍗曞紑鍙屾帶闈㈡澘
-50030=Zigbee鏂规偊鍙屽紑鍥涙帶闈㈡澘
-50031=Zigbee鏂规偊鍥涘紑鍏帶闈㈡澘
-50032=Zigbee鏂规偊鏂伴闈㈡澘
-50033=Zigbee鏂规偊鐜闈㈡澘
-50034=Zigbee绠�绾�4鎸夐敭鍦烘櫙闈㈡澘
-50035=Zigbee绠�绾�2璺獥甯橀潰鏉�
-50036=Zigbee鏂规偊2璺獥甯橀潰鏉�
-50037=Zigbee鏅鸿兘闂ㄩ攣
-50038=鏂伴鎺у埗灏忔ā鍧�
-50039=Zigbee鍚搁《鐕冩皵浼犳劅鍣�
-50040=PM2.5绌烘皵璐ㄩ噺浼犳劅鍣�
-50041=绠�绾﹀鍔熻兘闈㈡澘
-50042=绠�绾︾幆澧冮潰鏉�
-50043=Mini缃戝叧
-50044=鑹叉俯鐏�
-50045=鐞冨瀷绉诲姩浼犳劅鍣�
-
-;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄ā鍧桰D鐨勮澶囩被鍨嬪悕瀛�,浠�60000寮�濮�.娉�:瀹冨苟涓嶉渶瑕佸啀R.cs鏂囦欢涓畾涔夆槄鈽呪槄鈽�
-60000=浼犳劅鍣�
-60001=寮�鍏虫ā鍧�
-60002=閬槼妯″潡
-60003=鏅鸿兘闈㈡澘
-60004=鏅鸿兘缃戝叧
-60005=璋冭瘯璁惧
-60006=绯荤粺璁惧
-60007=璋冨厜妯″潡
-60008=杞崲鍣�
-60009=绌鸿皟妯″潡
-60010=鏅鸿兘闂ㄩ攣
-60011=鏂伴妯″潡
 
 ;//鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄坊鍔犳柊璁惧鐣岄潰閭i噷鏄剧ず鐨勫悕瀛�,浠�70000寮�濮嬧槄鈽呪槄鈽�
 70000=2鎸夐敭闈㈡澘
@@ -2106,22 +1989,22 @@
 70007=鏂规偊鏂伴闈㈡澘
 70008=鏂规偊鐜闈㈡澘
 70009=绐楀笜闈㈡澘
-70010=3璺户鐢靛櫒
-70011=1璺皟鍏夊櫒
+70010=3璺紑鍏冲皬妯″潡
+70011=1璺皟鍏夊櫒灏忔ā鍧�
 70012=绐楀笜鐢垫満
 70013=鍗峰笜鐢垫満
-70014=绌鸿皟缃戝叧
+70014=CoolBox 涓ぎ绌鸿皟缃戝叧
 70015=闂ㄩ攣
-70016=PIR浼犳劅鍣�
-70017=绾㈠浼犳劅鍣�
-70018=鐕冩皵浼犳劅鍣�
+70016=鍚搁《寮忎汉浣撲紶鎰熷櫒
+70017=浜轰綋浼犳劅鍣�
+70018=鐕冩皵浼犳劅鍣�(閫傞厤鍣�)
 70019=鐑熼浘浼犳劅鍣�
 70020=姘存蹈浼犳劅鍣�
 70021=闂ㄧ獥浼犳劅鍣�
 70022=娓╂箍搴︿紶鎰熷櫒
 70023=涓户鍣�
 70024=鏅鸿兘绌哄紑
-70025=鍚搁《鐕冩皵浼犳劅鍣�
+70025=鍚搁《寮忕噧姘斾紶鎰熷櫒
 70026=PM2.5绌烘皵璐ㄩ噺浼犳劅鍣�
 70027=绠�绾﹀鍔熻兘闈㈡澘
 70028=绠�绾︾幆澧冮潰鏉�
diff --git a/ZigbeeApp/GateWay.Droid/GateWay.Droid.csproj b/ZigbeeApp/GateWay.Droid/GateWay.Droid.csproj
index d986e89..545eee2 100644
--- a/ZigbeeApp/GateWay.Droid/GateWay.Droid.csproj
+++ b/ZigbeeApp/GateWay.Droid/GateWay.Droid.csproj
@@ -200,6 +200,7 @@
   </ItemGroup>
   <ItemGroup>
     <None Include="app.config" />
+    <AndroidAsset Include="Assets\DeviceName.ini" />
     <None Include="packages.config" />
     <None Include="Resources\AboutResources.txt" />
     <None Include="Properties\AndroidManifest.xml">
diff --git a/ZigbeeApp/GateWay.Droid/Properties/AndroidManifest.xml b/ZigbeeApp/GateWay.Droid/Properties/AndroidManifest.xml
index 76a3a2b..858cdee 100644
--- a/ZigbeeApp/GateWay.Droid/Properties/AndroidManifest.xml
+++ b/ZigbeeApp/GateWay.Droid/Properties/AndroidManifest.xml
@@ -1,5 +1,5 @@
 锘�<?xml version="1.0" encoding="utf-8"?>
-<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.hdl.home" android:versionCode="0120071301" android:installLocation="auto" android:versionName="1.1.0120071301">
+<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.hdl.home" android:versionCode="0120071701" android:installLocation="auto" android:versionName="1.1.0120071701">
 	<uses-sdk android:minSdkVersion="23" android:targetSdkVersion="26" />
 	<permission android:name="com.hdl.home.permission.JPUSH_MESSAGE" android:protectionLevel="signature" />
 	<uses-permission android:name="android.permission.WAKE_LOCK" />
@@ -93,7 +93,7 @@
 	<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
 	<uses-permission android:name="android.permission.GET_TASKS" />
 	<!-- 鏋佸厜鎺ㄩ�佺粨鏉� -->
-	<application android:allowBackup="true" android:largeHeap="true" android:persistent="true" android:label="HDL Home" android:icon="@drawable/Icon">
+	<application android:allowBackup="true" android:largeHeap="true" android:persistent="true" android:label="Evoyo Home" android:icon="@drawable/Icon">
 		<!-- 鑷姩鏇存柊 -->
 		<provider android:name="android.support.v4.content.FileProvider" android:authorities="com.hdl.home.fileProvider" android:grantUriPermissions="true" android:exported="false">
 			<meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/file_paths" />
diff --git a/ZigbeeApp/Home.Ios/Home.IOS.csproj b/ZigbeeApp/Home.Ios/Home.IOS.csproj
index fd53099..8885bc5 100644
--- a/ZigbeeApp/Home.Ios/Home.IOS.csproj
+++ b/ZigbeeApp/Home.Ios/Home.IOS.csproj
@@ -1141,6 +1141,7 @@
       <BundleResource Include="Resources\Phone\Gateway\WiredGateway.png" />
       <BundleResource Include="Resources\Phone\Gateway\WirelessGateway.png" />
       <BundleResource Include="Resources\Phone\Gateway\AddGatewaySuccess.png" />
+      <BundleResource Include="Resources\DeviceName.ini" />
     </ItemGroup>
     <Import Project="..\Shared\Shared.projitems" Label="Shared" Condition="Exists('..\Shared\Shared.projitems')" />
     <Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.CSharp.targets" />
diff --git a/ZigbeeApp/Home.Ios/Resources/DeviceName.ini b/ZigbeeApp/Home.Ios/Resources/DeviceName.ini
new file mode 100755
index 0000000..7a871b7
--- /dev/null
+++ b/ZigbeeApp/Home.Ios/Resources/DeviceName.ini
@@ -0,0 +1,198 @@
+锘�;鍚勭璁惧鐨勫悕瀛楃殑瀹氫箟鏂囦欢
+;瀹氫箟瑙勫垯:鐢ㄦ枩鏉犻殧寮�
+
+;***************************************************************
+;              缃戝叧璁惧(缃戝叧鍙湁闀滃儚ID,涓嶉渶瑕佹灇涓�)
+;***************************************************************
+;闀滃儚ID=缂虹渷鍙傛暟 / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / 缂虹渷鍙傛暟 /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;澧欒缃戝叧銆�
+1 = 0 / 澧欒缃戝叧 / 澧欒缃戝叧 / 0 / 鏅鸿兘缃戝叧 / 鏅鸿兘缃戝叧
+;鏅鸿兘缃戝叧E7
+6 = 0 / 鏅鸿兘缃戝叧E7 / 鏅鸿兘缃戝叧E7 / 0 / 鏅鸿兘缃戝叧 / 鏅鸿兘缃戝叧
+;Mini缃戝叧銆�
+11 = 0 / Mini缃戝叧 / Mini缃戝叧 / 0 / 鏅鸿兘缃戝叧 / 鏅鸿兘缃戝叧
+;鐜舰缃戝叧銆�
+16 = 0 / 鐜舰缃戝叧 / 鐜舰缃戝叧 / 0 / 鏅鸿兘缃戝叧 / 鏅鸿兘缃戝叧
+
+;***************************************************************
+;                            绐楀笜璁惧
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;鏅鸿兘寮�鍚堝笜鐢垫満銆�
+MWM65B-ZB.20 = 100 / 绐楀笜鐢垫満 / 绐楀笜鐢垫満 / 100 / 閬槼 / 閬槼妯″潡
+;鏅鸿兘绠$姸鐢垫満銆�
+MVSM35B-ZB.20 = 101 / 鍗峰笜鐢垫満 / 鍗峰笜鐢垫満 / 100 / 閬槼 / 閬槼妯″潡
+
+;***************************************************************
+;                            闈㈡澘璁惧
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;4鎸夐敭瑙︽懜闈㈡澘(甯�4璺户鐢靛櫒搴曞骇)
+MPT4/R4-ZB.18 = 200 / 4鎸夐敭瑙︽懜闈㈡澘 / 4鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;3鎸夐敭瑙︽懜闈㈡澘
+MPT3/R3-ZB.18 = 201 / 3鎸夐敭瑙︽懜闈㈡澘 / 3鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;2鎸夐敭瑙︽懜闈㈡澘
+MPT2/R2-ZB.18 = 202 / 2鎸夐敭瑙︽懜闈㈡澘 / 2鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;12鎸夐敭瑙︽懜闈㈡澘
+MPT1/R1-ZB.18 = 203 / 12鎸夐敭瑙︽懜闈㈡澘 / 12鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;4鎸夐敭瑙︽懜闈㈡澘(鍙甫鐢垫簮搴曞骇)
+MPT4-ZB.18 = 210 / 4鎸夐敭瑙︽懜闈㈡澘 / 4鎸夐敭瑙︽懜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�4鎸夐敭闈㈡澘銆�
+MPT4R4L/S-ZB.18 = 220 / 绠�绾�4鎸夐敭闈㈡澘 / 绠�绾�4鎸夐敭闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�3鎸夐敭闈㈡澘銆�
+MPT3R3L/S-ZB.18 = 221 / 绠�绾�3鎸夐敭闈㈡澘 / 绠�绾�3鎸夐敭闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�2鎸夐敭闈㈡澘銆�
+MPT2R2L/S-ZB.18 = 222 / 绠�绾�2鎸夐敭闈㈡澘 / 绠�绾�2鎸夐敭闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�4鎸夐敭鍦烘櫙闈㈡澘
+MPT4SC/S-ZB.18 = 224 / 绠�绾�4鎸夐敭鍦烘櫙闈㈡澘 / 绠�绾�4鎸夐敭鍦烘櫙闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾�2璺獥甯橀潰鏉�
+MPT2W/S-ZB.18 = 226 / 绠�绾�2璺獥甯橀潰鏉� / 绠�绾�2璺獥甯橀潰鏉� / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鍗曞紑鍙屾帶闈㈡澘
+MP2B/TILE-ZB.18 = 240 / 鏂规偊鍗曞紑鍙屾帶闈㈡澘 / 鏂规偊鍗曞紑鍙屾帶闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鍙屽紑鍥涙帶闈㈡澘
+MP4B/TILE-ZB.18 = 241 / 鏂规偊鍙屽紑鍥涙帶闈㈡澘 / 鏂规偊鍙屽紑鍥涙帶闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鍥涘紑鍏帶闈㈡澘
+MP8B/TILE-ZB.18 = 242 / 鏂规偊鍥涘紑鍏帶闈㈡澘 / 鏂规偊鍥涘紑鍏帶闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鏂伴闈㈡澘
+MPFA/TILE-ZB.18 = 250 / 鏂规偊鏂伴闈㈡澘 / 鏂规偊鏂伴闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;鏂规偊鐜闈㈡澘
+MPTE3/TILE-ZB.18 = 253 / 鏂规偊鐜闈㈡澘 / 鏂规偊鐜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绐楀笜闈㈡澘
+MP2W/TILE-ZB.18 = 256 / 绐楀笜闈㈡澘 / 绐楀笜闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾﹀鍔熻兘闈㈡澘銆�
+MPTL4C/S-ZB.18 = 212 / 绠�绾﹀鍔熻兘闈㈡澘 / 绠�绾﹀鍔熻兘闈㈡澘 / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+;绠�绾︾幆澧冮潰鏉裤��
+MPTE3/S-ZB.18 = 230 / 绠�绾︾幆澧冮潰鏉� / 绠�绾︾幆澧冮潰鏉� / 200 / 鎸夐敭闈㈡澘 / 鏅鸿兘闈㈡澘
+
+;***************************************************************
+;                           浼犳劅鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;pir浼犳劅鍣�220銆�
+MSPIR01-ZB.10 = 1200 / 鍚搁《寮忎汉浣撲紶鎰熷櫒 / 鍚搁《寮忎汉浣撲紶鎰熷櫒 / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鐞冨瀷绉诲姩浼犳劅鍣�
+MSPIRB-ZB.10 = 1205 / 鐞冨瀷绉诲姩浼犳劅鍣� / 鐞冨瀷绉诲姩浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鐕冩皵浼犳劅鍣�(楹︿箰鍏�)銆�
+MULTI-GASE--EA07 = 1300 / 鐕冩皵浼犳劅鍣�(閫傞厤鍣�) / 鐕冩皵浼犳劅鍣�(閫傞厤鍣�) / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;闂ㄧ獥纾佷紶鎰熷櫒(楹︿箰鍏�)銆�
+MULTI-MECI--EA01 = 1301 / 闂ㄧ獥浼犳劅鍣� / 闂ㄧ獥浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鐑熼浘浼犳劅鍣�(楹︿箰鍏�)銆�
+MULTI-FIRE--EA05 = 1302 / 鐑熼浘浼犳劅鍣� / 鐑熼浘浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;绾㈠浼犳劅鍣�(楹︿箰鍏�)銆�
+MULTI-MOTI--EA04 = 1303 / 浜轰綋浼犳劅鍣� / 浜轰綋浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;姘存蹈浼犳劅鍣�(楹︿箰鍏�)銆�
+MULTI-WATE--EA02 = 1304 / 姘存蹈浼犳劅鍣� / 姘存蹈浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;绱ф�ユ寜閿�(楹︿箰鍏�)
+MULTI-BURO--EA06 = 1305 / 绱ф�ユ寜閿� / 绱ф�ユ寜閿� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+
+;鐕冩皵浼犳劅鍣�(娌充笢)銆�
+MSG01/M-ZB.10 = 1300 / 鐕冩皵浼犳劅鍣�(閫傞厤鍣�) / 鐕冩皵浼犳劅鍣�(閫傞厤鍣�) / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;闂ㄧ獥纾佷紶鎰熷櫒(娌充笢)銆�
+MSDC01/M-ZB.10 = 1301 / 闂ㄧ獥浼犳劅鍣� / 闂ㄧ獥浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鐑熼浘浼犳劅鍣�(娌充笢)銆�
+MSS01/M-ZB.10 = 1302 / 鐑熼浘浼犳劅鍣� / 鐑熼浘浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;绾㈠浼犳劅鍣�(娌充笢)銆�
+MSPIR01/M-ZB.10 = 1303 / 浜轰綋浼犳劅鍣� / 浜轰綋浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;姘存蹈浼犳劅鍣�(娌充笢)銆�
+MSW01/M-ZB.10 = 1304 / 姘存蹈浼犳劅鍣� / 姘存蹈浼犳劅鍣� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;绱ф�ユ寜閿�(娌充笢)
+MBU01/M-ZB.10 = 1305 / 绱ф�ユ寜閿� / 绱ф�ユ寜閿� / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;鍚搁《鐕冩皵浼犳劅鍣ㄣ��
+MGCD01/M-ZB.10 = 1306 / 鍚搁《寮忕噧姘斾紶鎰熷櫒 / 鍚搁《寮忕噧姘斾紶鎰熷櫒 / 1200 / 浼犳劅鍣� / 浼犳劅鍣�
+;PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� 
+MSPM25/M-ZB.10 = 1307 / PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� / PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� / 1307 / 绌烘皵璐ㄩ噺 / 浼犳劅鍣�
+
+;***************************************************************
+;                           缁х數鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;3璺户鐢靛櫒灏忔ā鍧椼��
+MPR0310-ZB.10 = 2300 / 3璺紑鍏冲皬妯″潡 / 3璺紑鍏冲皬妯″潡 / 2300 / 缁х數鍣� / 寮�鍏虫ā鍧�
+;鏂规偊鏂伴灏忔ā鍧�
+MFA01-ZB.10 = 2310 / 鏂规偊鏂伴灏忔ā鍧� / 鏂规偊鏂伴灏忔ā鍧� / 2300 / 缁х數鍣� / 鏂伴妯″潡
+
+;***************************************************************
+;                           璋冨厜鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;1璺皟鍏夊櫒灏忔ā鍧椼��
+MPD0101-ZB.10 = 2500 / 1璺皟鍏夊櫒灏忔ā鍧� / 1璺皟鍏夊櫒灏忔ā鍧� / 2500 / 璋冨厜鍣� / 璋冨厜妯″潡
+
+;***************************************************************
+;                           闂ㄩ攣璁惧
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;鏅鸿兘闂ㄩ攣(H06C)銆�
+H06C = 2800 / S-one 鏅鸿兘闂ㄩ攣 / S-one 鏅鸿兘闂ㄩ攣 / 2800 / 闂ㄩ攣 / 鏅鸿兘闂ㄩ攣
+;鏅鸿兘闂ㄩ攣(S-one)銆�
+S-one = 2802 / H06C 鏅鸿兘闂ㄩ攣 / H06C 鏅鸿兘闂ㄩ攣 / 2800 / 闂ㄩ攣 / 鏅鸿兘闂ㄩ攣
+
+;***************************************************************
+;                           绌鸿皟璁惧
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;zigbee绌鸿皟缃戝叧妯″潡銆�
+MAC/GW-ZB.10 = 3600 / CoolBox 涓ぎ绌鸿皟缃戝叧 / CoolBox 涓ぎ绌鸿皟缃戝叧 / 3600 / 绌鸿皟 / 绌鸿皟妯″潡
+
+;***************************************************************
+;                           涓户鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� /璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;zigbee涓户鍣ㄣ��
+MSR-ZB.10 = 3900 / 涓户鍣� / 涓户鍣� / 3900 / 涓户鍣� / 绯荤粺璁惧
+
+;***************************************************************
+;                          绌烘皵寮�鍏宠澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� / 璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;绌烘皵寮�鍏�
+MBCI01-ZB.10 = 4100 / 绌烘皵寮�鍏� / 绌烘皵寮�鍏� / 4100 / 鏅鸿兘绌哄紑 / 寮�鍏虫ā鍧�
+
+;***************************************************************
+;                          杞崲鍣ㄨ澶�
+;***************************************************************
+;妯″潡ID=DeviceConcreteType鐨勫�� / 璁惧鐨勫畼鏂瑰悕瀛� / 璁惧榛樿澶囨敞鍚嶅瓧 / DeviceBeloneType鐨勫�� / 璁惧鎵�灞炵绫荤殑鍚嶅瓧 / 璁惧绫诲瀷鍚嶅瓧
+
+;zigbee杞�485鍗忚杞崲鍣ㄣ��
+M485/GW-ZB.10 = 4200 / Zigbee-RS485 閫氳灏忔ā鍧� / Zigbee-RS485 閫氳灏忔ā鍧� / 4200 / 杞崲鍣� / 杞崲鍣�
+;zigbee杞琤uspro鍗忚杞崲鍣�
+MBUS/GW-ZB.10 = 4201 / zigbee杞琤uspro鍗忚杞崲鍣� / zigbee杞琤uspro鍗忚杞崲鍣� / 4200 / 杞崲鍣� / 杞崲鍣�
+
+
+;***************************************************************
+;                          绗笁鏂硅澶�
+;***************************************************************
+;鑷畾涔夊��=缂虹渷鍙傛暟 / 璁惧鐨勫畼鏂瑰悕瀛� / 缂虹渷鍙傛暟 / 缂虹渷鍙傛暟 / 缂虹渷鍙傛暟 / 璁惧绫诲瀷鍚嶅瓧
+;浠g爜閲岄潰闇�瑕佹參鎱竴涓竴涓猧f鍘诲~鍐�
+
+A400 = 0 / 閬槼 / 0 / 0 / 0 / 閬槼妯″潡
+A401 = 0 / 鎸夐敭闈㈡澘 / 0 / 0 / 0 / 鏅鸿兘闈㈡澘
+A402 = 0 / 浼犳劅鍣� / 0 / 0 / 0 / 浼犳劅鍣�
+A403 = 0 / 缁х數鍣� / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A404 = 0 / 璋冨厜鍣� / 0 / 0 / 0 / 璋冨厜妯″潡
+A405 = 0 / 闂ㄩ攣 / 0 / 0 / 0 / 鏅鸿兘闂ㄩ攣
+A406 = 0 / 绌鸿皟 / 0 / 0 / 0 / 绌鸿皟妯″潡
+A407 = 0 / 涓户鍣� / 0 / 0 / 0 / 绯荤粺璁惧
+A408 = 0 / 绌烘皵寮�鍏� / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A409 = 0 / 杞崲鍣� / 0 / 0 / 0 / 杞崲鍣�
+A410 = 0 / 褰╃伅 / 0 / 0 / 0 / 璋冨厜妯″潡
+A411 = 0 / 娓╂箍搴︿紶鎰熷櫒 / 0 / 0 / 0 / 浼犳劅鍣�
+A412 = 0 / 娓╁害浼犳劅鍣� / 0 / 0 / 0 / 浼犳劅鍣�
+A413 = 0 / 婀垮害浼犳劅鍣� / 0 / 0 / 0 / 浼犳劅鍣�
+A414 = 0 / 鏂伴 / 0 / 0 / 0 / 鏂伴妯″潡
+A415 = 0 / 绌烘皵璐ㄩ噺 / 0 / 0 / 0 / 浼犳劅鍣�
+A416 = 0 / 寮�鍏� / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A417 = 0 / 鎻掑骇 / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A418 = 0 / 鐏厜 / 0 / 0 / 0 / 璋冨厜妯″潡
+A419 = 0 / 骞叉帴鐐� / 0 / 0 / 0 / 寮�鍏虫ā鍧�
+A420 = 0 / 鑹叉俯鐏� / 0 / 0 / 0 / 璋冨厜妯″潡
\ No newline at end of file
diff --git a/ZigbeeApp/Home.Ios/Resources/Language.ini b/ZigbeeApp/Home.Ios/Resources/Language.ini
index 093e27f..6c90466 100755
--- a/ZigbeeApp/Home.Ios/Resources/Language.ini
+++ b/ZigbeeApp/Home.Ios/Resources/Language.ini
@@ -624,8 +624,8 @@
 5408=铚傞福鍣�
 5409=鐜鍏夌収搴�
 5410=鐓у害鍊�<
-5411=鏆梴\r\n} 0lux
-5412=浜畕\r\n} 100lux
+5411=鏆�
+5412=浜�
 5413=鍦ㄥ鍐呮潯浠朵笅,榛戞殫鐓у害鍊肩害涓�0.02lux,榛勬槒鐓у害鍊納\r\n}绾︿负10lux,闃村ぉ鐓у害鍊肩害涓�5~50lux,璇锋牴鎹疄闄厈\r\n}闇�瑕佽繘琛岃皟鑺�
 5414=鍙瀵硅
 5415=鏍�
@@ -634,7 +634,7 @@
 
 
 
-10000=HDL Home
+10000=Evoyo Home
 10001=甯哥敤
 
 10100=鎵嬫満鍙�
@@ -1873,6 +1873,13 @@
 16134=璁剧疆璁惧鍔熻兘绫诲瀷澶辫触
 16135=鑾峰彇鍦烘櫙鍒楄〃澶辫触,缃戝叧鍥炲瓒呮椂
 16136=闇�閲嶆柊缁戝畾
+16137=鍑虹幇鎰忓鎯呭喌,鏁版嵁涓㈠け
+16138=鐑熼浘浼犳劅鍣�
+16139=姘翠镜浼犳劅鍣�
+16140=鐕冩皵浼犳劅鍣�
+16141=绱ф�ユ寜閽�
+16142=闂ㄧ獥浼犳劅鍣�
+16143=閽ュ寵鎵�
 
 ;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄帴鍙g殑杩斿洖淇℃伅缈昏瘧,浠�18000寮�濮嬧槄鈽呪槄鈽�
 18004=鎸囧畾缃戝叧宸茬粡琚粦瀹�
@@ -1960,139 +1967,16 @@
 ;鍚搁《鐕冩皵浼犳劅鍣ㄧ殑鍏ョ綉鎿嶄綔鎸囩ず
 21023=闀挎寜鍥剧ず鎸夐敭5绉掍互涓婏紝缁胯壊蹇棯{0}杩涘叆閰嶇綉鐘舵�侊紝缁跨伅甯镐寒鍒欏叆缃戞垚鍔�
 ;鐞冨瀷绉诲姩浼犳劅鍣ㄧ殑鍏ョ綉鎿嶄綔鎸囩ず
-21024=闀挎寜鍥剧ず鎸夐敭5绉掍互涓婏紝鎸囩ず鐏彉缁裤�侀棯鐑亄0}杩涘叆閰嶇綉鐘舵�侊紝缁跨伅鐔勭伃鍒欓厤缃戞垚鍔�
-
-;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄ā鍧桰D鐨勫畼鏂瑰悕瀛�,浠�30000寮�濮嬧槄鈽呪槄鈽�
-30000=绱ф�ユ寜閽�
-30001=鐕冩皵浼犳劅鍣�
-30002=鐑熼浘浼犳劅鍣�
-30003=姘翠镜浼犳劅鍣�
-30004=閽ュ寵鎵�
-30005=闂ㄧ獥浼犳劅鍣�
-30006=鏅鸿兘绌哄紑
-30007=Zigbee鏅鸿兘寮�鍚堝笜鐢垫満
-30008=4鎸夐敭瑙︽懜闈㈡澘(4璺户鐢靛櫒搴曞骇)
-30009=220Pir浼犳劅鍣�
-30010=1浠igbee缃戝叧(146搴曠洅澧欒妯″紡)
-30011=3鎸夐敭瑙︽懜闈㈡澘(3璺户鐢靛櫒搴曞骇)
-30012=2鎸夐敭瑙︽懜闈㈡澘(2璺户鐢靛櫒搴曞骇)
-30013=3璺户鐢靛櫒灏忔ā鍧�
-30014=1浠igbee缃戝叧(楂樼骇缃戝叧妗岄潰妯″紡)
-30015=璋冭瘯璁惧
-30016=Zigbee鏅鸿兘绠$姸鐢垫満
-30017=Zigbee涓户鍣�
-30018=12鎸夐敭瑙︽懜闈㈡澘(1璺户鐢靛櫒搴曞骇)
-30019=4鎸夐敭瑙︽懜闈㈡澘(鍙甫鐢垫簮搴曞骇)
-30020=Zigbee浜轰綋绉诲姩浼犳劅鍣�(鐞冨舰)
-30021=1璺皟鍏夊櫒灏忔ā鍧�
-30022=Zigbee杞珺uspro鍗忚杞崲鍣�
-30023=Zigbee杞�485鍗忚杞崲鍣�
-30024=Zigbee绌鸿皟缃戝叧妯″潡
-30025=H06C
-30026=绠�绾�4鎸夐敭闈㈡澘
-30027=绠�绾�3鎸夐敭闈㈡澘
-30028=绠�绾�2鎸夐敭闈㈡澘
-30029=鏂规偊鍗曞紑鍙屾帶闈㈡澘
-30030=鏂规偊鍙屽紑鍥涙帶闈㈡澘
-30031=鏂规偊鍥涘紑鍏帶闈㈡澘
-30032=鏂规偊鏂伴闈㈡澘
-30033=鏂规偊鐜闈㈡澘
-30034=绠�绾�4鎸夐敭鍦烘櫙闈㈡澘
-30035=绠�绾�2璺獥甯橀潰鏉�
-30036=鏂规偊/2璺獥甯橀潰鏉�-Z
-30037=S-one
-30038=鏂规偊鏂伴灏忔ā鍧�
-30039=Zigbee鍚搁《鐕冩皵浼犳劅鍣�
-30040=PM2.5绌烘皵璐ㄩ噺浼犳劅鍣�
-30041=绠�绾﹀鍔熻兘闈㈡澘
-30042=绠�绾︾幆澧冮潰鏉�
-30043=Mini缃戝叧
-30044=鑹叉俯鐏�
-30045=ZigBee鐞冨瀷绉诲姩浼犳劅鍣�
+21024=闀挎寜鍥剧ず鎸夐敭5绉掍互涓婏紝鎸囩ず鐏彉缁裤�侀棯鐑亄0}杩涘叆閰嶇綉鐘舵�侊紝缁跨伅鐔勭伃鍒欓厤缃戞垚鍔�
 
-;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄澶囨墍灞炵绫荤殑缈昏瘧鍚嶅瓧,浠�40000寮�濮嬧槄鈽呪槄鈽�
+;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄澶囨墍灞炵绫荤殑缈昏瘧鍚嶅瓧,浠�40000寮�濮� 娉細杩欎簺鎵�灞濱D宸茬粡涓嶅啀缁存姢鈽呪槄鈽呪槄
 40000=閬槼
 40001=鎸夐敭闈㈡澘
-40002=浼犳劅鍣�
-40003=缁х數鍣�
-40004=璋冨厜鍣�
-40005=闂ㄩ攣
 40006=绌鸿皟
-40007=涓户鍣�
-40008=鏅鸿兘绌哄紑
-40009=杞崲鍣�
-40010=褰╃伅
-40011=娓╂箍搴︿紶鎰熷櫒
-40012=娓╁害浼犳劅鍣�
-40013=婀垮害浼犳劅鍣�
 40014=寮�鍏�
 40015=鎻掑骇
 40016=鐏厜
-40017=骞叉帴鐐�
 40018=鏂伴
-40019=绌烘皵璐ㄩ噺
-
-;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄ā鍧桰D鐨勮澶囬粯璁ゅ娉ㄥ悕瀛�,浠�50000寮�濮�.娉�:瀹冨苟涓嶉渶瑕佸啀R.cs鏂囦欢涓畾涔夆槄鈽呪槄鈽�
-50000=绱ф�ユ寜閽�
-50001=Zigbee鐕冩皵浼犳劅鍣�
-50002=Zigbee鐑熼浘浼犳劅鍣�
-50003=Zigbee姘存蹈浼犳劅鍣�
-50004=閽ュ寵鎵�
-50005=Zigbee闂ㄧ獥浼犳劅鍣�
-50006=Zigbee鏅鸿兘绌哄紑
-50007=Zigbee寮�鍚堝笜鐢垫満
-50008=Zigbee 4鎸夐敭闈㈡澘
-50009=Zigbee鍚搁《寮忎汉浣撶Щ鍔ㄤ紶鎰熷櫒
-50010=Zigbee澧欒缃戝叧
-50011=Zigbee 3鎸夐敭闈㈡澘
-50012=Zigbee 2鎸夐敭闈㈡澘
-50013=Zigbee 3璺�10A缁х數鍣�
-50014=Zigbee妗岄潰缃戝叧
-50015=璋冭瘯璁惧
-50016=Zigbee鍗峰笜鐢垫満
-50017=Zigbee涓户鍣�
-50018=Zigbee 12鎸夐敭闈㈡澘
-50019=Zigbee 4鎸夐敭闈㈡澘
-50020=Zigbee浜轰綋绉诲姩浼犳劅鍣�(鐞冨舰)
-50021=Zigbee 1璺�1.5A璋冨厜鍣�
-50022=Zigbee杞珺uspro鍗忚杞崲鍣�
-50023=Zigbee杞�485鍗忚杞崲鍣�
-50024=Zigbee绌鸿皟缃戝叧妯″潡
-50025=Zigbee鏅鸿兘闂ㄩ攣
-50026=Zigbee绠�绾�4鎸夐敭闈㈡澘
-50027=Zigbee绠�绾�3鎸夐敭闈㈡澘
-50028=Zigbee绠�绾�2鎸夐敭闈㈡澘
-50029=Zigbee鏂规偊鍗曞紑鍙屾帶闈㈡澘
-50030=Zigbee鏂规偊鍙屽紑鍥涙帶闈㈡澘
-50031=Zigbee鏂规偊鍥涘紑鍏帶闈㈡澘
-50032=Zigbee鏂规偊鏂伴闈㈡澘
-50033=Zigbee鏂规偊鐜闈㈡澘
-50034=Zigbee绠�绾�4鎸夐敭鍦烘櫙闈㈡澘
-50035=Zigbee绠�绾�2璺獥甯橀潰鏉�
-50036=Zigbee鏂规偊2璺獥甯橀潰鏉�
-50037=Zigbee鏅鸿兘闂ㄩ攣
-50038=鏂伴鎺у埗灏忔ā鍧�
-50039=Zigbee鍚搁《鐕冩皵浼犳劅鍣�
-50040=PM2.5绌烘皵璐ㄩ噺浼犳劅鍣�
-50041=绠�绾﹀鍔熻兘闈㈡澘
-50042=绠�绾︾幆澧冮潰鏉�
-50043=Mini缃戝叧
-50044=鑹叉俯鐏�
-50045=鐞冨瀷绉诲姩浼犳劅鍣�
-
-;鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄ā鍧桰D鐨勮澶囩被鍨嬪悕瀛�,浠�60000寮�濮�.娉�:瀹冨苟涓嶉渶瑕佸啀R.cs鏂囦欢涓畾涔夆槄鈽呪槄鈽�
-60000=浼犳劅鍣�
-60001=寮�鍏虫ā鍧�
-60002=閬槼妯″潡
-60003=鏅鸿兘闈㈡澘
-60004=鏅鸿兘缃戝叧
-60005=璋冭瘯璁惧
-60006=绯荤粺璁惧
-60007=璋冨厜妯″潡
-60008=杞崲鍣�
-60009=绌鸿皟妯″潡
-60010=鏅鸿兘闂ㄩ攣
-60011=鏂伴妯″潡
 
 ;//鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄坊鍔犳柊璁惧鐣岄潰閭i噷鏄剧ず鐨勫悕瀛�,浠�70000寮�濮嬧槄鈽呪槄鈽�
 70000=2鎸夐敭闈㈡澘
@@ -2105,22 +1989,22 @@
 70007=鏂规偊鏂伴闈㈡澘
 70008=鏂规偊鐜闈㈡澘
 70009=绐楀笜闈㈡澘
-70010=3璺户鐢靛櫒
-70011=1璺皟鍏夊櫒
+70010=3璺紑鍏冲皬妯″潡
+70011=1璺皟鍏夊櫒灏忔ā鍧�
 70012=绐楀笜鐢垫満
 70013=鍗峰笜鐢垫満
-70014=绌鸿皟缃戝叧
+70014=CoolBox 涓ぎ绌鸿皟缃戝叧
 70015=闂ㄩ攣
-70016=PIR浼犳劅鍣�
-70017=绾㈠浼犳劅鍣�
-70018=鐕冩皵浼犳劅鍣�
+70016=鍚搁《寮忎汉浣撲紶鎰熷櫒
+70017=浜轰綋浼犳劅鍣�
+70018=鐕冩皵浼犳劅鍣�(閫傞厤鍣�)
 70019=鐑熼浘浼犳劅鍣�
 70020=姘存蹈浼犳劅鍣�
 70021=闂ㄧ獥浼犳劅鍣�
 70022=娓╂箍搴︿紶鎰熷櫒
 70023=涓户鍣�
 70024=鏅鸿兘绌哄紑
-70025=鍚搁《鐕冩皵浼犳劅鍣�
+70025=鍚搁《寮忕噧姘斾紶鎰熷櫒
 70026=PM2.5绌烘皵璐ㄩ噺浼犳劅鍣�
 70027=绠�绾﹀鍔熻兘闈㈡澘
 70028=绠�绾︾幆澧冮潰鏉�
diff --git a/ZigbeeApp/Shared/Common/CommonPage.cs b/ZigbeeApp/Shared/Common/CommonPage.cs
index 6acd388..5e1036d 100755
--- a/ZigbeeApp/Shared/Common/CommonPage.cs
+++ b/ZigbeeApp/Shared/Common/CommonPage.cs
@@ -42,7 +42,7 @@
         /// <summary>
         /// 鐗堟湰鍙�
         /// </summary>
-        public static string CodeIDString = "1.1.0120071301";
+        public static string CodeIDString = "1.1.0120071701";
         /// <summary>
         /// 娉ㄥ唽鏉ユ簮(0:HDL On 1:Zigbee)
         /// </summary>
@@ -355,6 +355,10 @@
         /// <returns>杩斿洖鐘舵�佺爜</returns>
         public string PushRegID()
         {
+#if DEBUG
+            //璋冭瘯涓嶉渶瑕佸彂閫佽繖涓笢瑗�
+            return null;
+#endif
             try
             {
                 string deviceAlias;
@@ -364,8 +368,9 @@
                 deviceType = "iphone";
 #elif Android
                 deviceAlias = Android.OS.Build.Manufacturer;
-                deviceType = "android";
-#endif
+                deviceType = "android";
+#endif
+
                 var RegIDObj = new SendDataToServer.SignZigbeeNeedPushRegIDObj()
                 {
                     RegID = Shared.Common.Config.Instance.RegistrationID,
@@ -375,9 +380,14 @@
                 var requestJson = Newtonsoft.Json.JsonConvert.SerializeObject(RegIDObj);
                 var reverObj = CommonPage.Instance.RequestHttpsZigbeeAsync("ZigbeeUsers/SignZigbeeNeedPushRegID", System.Text.Encoding.UTF8.GetBytes(requestJson));
                 if (reverObj == null)
-                {
+                {
+                    //璋冭瘯:璁板綍鏋佸厜ID
+                    Phone.UserCenter.HdlLogLogic.Current.WriteOtherText(Shared.Phone.UserCenter.DirNameResourse.JiguangFile, "send:" + RegIDObj.RegID + " fail,receive obj is null", false, true);
                     return null;
-                }
+                }
+                //璋冭瘯:璁板綍鏋佸厜ID
+                Phone.UserCenter.HdlLogLogic.Current.WriteOtherText(Shared.Phone.UserCenter.DirNameResourse.JiguangFile, "send:" + RegIDObj.RegID + " result:" + reverObj.StateCode, false, true);
+
                 return reverObj.StateCode;
             }
             catch
diff --git a/ZigbeeApp/Shared/Common/Device.cs b/ZigbeeApp/Shared/Common/Device.cs
old mode 100755
new mode 100644
index 1435f45..7f12108
--- a/ZigbeeApp/Shared/Common/Device.cs
+++ b/ZigbeeApp/Shared/Common/Device.cs
@@ -58,17 +58,9 @@
         }
 
         /// <summary>
-        /// R鏂囦欢閲岄潰璁惧妯″潡ID鐨勭炕璇戝悕瀛楃殑鍓嶇紑
+        /// 璁惧鐨勬ā鍧桰D鐨勬灇涓� keys:妯″潡ID (Axxx浠h〃鏄涓夋柟璁惧) 
         /// </summary>
-        public const string deviceModelIdName = "uDeviceModelId";
-        /// <summary>
-        /// R鏂囦欢閲岄潰鎵�鏈夎澶囧悕瀛楃殑ID
-        /// </summary>
-        public Dictionary<string, int> dicDeviceAllNameID = null;
-        /// <summary>
-        /// 璁惧鐨勬ā鍧桰D鐨勬灇涓�(keys:妯″潡ID  value:璁惧鍏蜂綋绫诲瀷鍊�-璁惧鎵�灞炵被鍨嬪��(鑷畾涔夌殑鍊�,鍢�,鍙涓嶉噸澶嶅氨鍙互)
-        /// </summary>
-        private Dictionary<string, string> dicDeviceModelIdEnum = null;
+        private Dictionary<string, DeviceNameContent> dicDeviceModelIdEnum = null;
         /// <summary>
         /// 闇�瑕佽浆鎹㈢殑璁惧鐨勬ā鍧桰D(keys:鏃фā鍧桰D,value:鏂版ā鍧桰D)
         /// </summary>
@@ -105,9 +97,9 @@
         {
             this.dicAllDevice.Clear();
             this.dicDeviceEpoint.Clear();
-
-            //鍒濆鍖朢鏂囦欢閲岄潰璁惧榛樿鍚嶅瓧鐨処D
-            this.InitDeviceDefultNameIDList();
+
+            //鍒濆鍖栬澶囨灇涓�
+            this.InitDeviceModelIdEnum();
 
             //鑾峰彇鏈湴鍏ㄩ儴鐨勮澶囨枃浠�
             List<string> listFile = this.GetAllDeviceFile();
@@ -217,12 +209,13 @@
         /// <para>-1:寮傚父 1:姝e父 2:璁惧淇℃伅缂烘崯</para>
         /// </summary>
         /// <param name="zbGateway">缃戝叧瀵硅薄</param>
-        public int SetDeviceToMemmoryByGateway(ZbGateway zbGateway)
+        /// <param name="useLocalConnect">鏄惁寮哄埗浣跨敤鏈湴杩炴帴鍙戦��</param>
+        public int SetDeviceToMemmoryByGateway(ZbGateway zbGateway, bool useLocalConnect)
         {
             //浠庣綉鍏宠幏鍙栧叏閮ㄧ殑璁惧
             int statu = 0;
             List<CommonDevice> listDevice = new List<CommonDevice>();
-            List<CommonDevice> list = this.GetDeviceListFromGateway(zbGateway, ref statu, true);
+            List<CommonDevice> list = this.GetDeviceListFromGateway(zbGateway, ref statu, useLocalConnect);
             if (list == null)
             {
                 return -1;
@@ -344,6 +337,8 @@
                     var tempDevice = this.dicOTADevice[mainKeys];
                     //灏咲eviceInfo鐨勫睘鎬ц缃埌涓诲睘鎬т腑
                     this.SetDeviceInfoToMain(tempDevice, device);
+                    //鍒锋柊璁惧鍔熻兘绫诲瀷(杩欎釜涓滆タ闇�瑕佺嫭绔嬪嚭鏉�)
+                    this.RefreshDeviceFunctionType(tempDevice, device, false);
                     device = tempDevice;
                 }
 
@@ -365,6 +360,8 @@
                     var tempDevice = this.dicAllDevice[mainKeys];
                     //灏咲eviceInfo鐨勫睘鎬ц缃埌涓诲睘鎬т腑
                     this.SetDeviceInfoToMain(tempDevice, device);
+                    //鍒锋柊璁惧鍔熻兘绫诲瀷(杩欎釜涓滆タ闇�瑕佺嫭绔嬪嚭鏉�)
+                    this.RefreshDeviceFunctionType(tempDevice, device, false);
                     device = tempDevice;
                 }
                 else
@@ -822,8 +819,6 @@
             return true;
         }
         #endregion
-
-
 
         #region 鈻� 娴嬭瘯璁惧___________________________
 
@@ -1341,13 +1336,14 @@
                 //鍏朵粬鐨勫共鎺ョ偣鍙共鎺ョ偣
                 else
                 {
-                    return Language.StringByID(R.MyInternationalizationString.uDeviceBelongId16) + epointNo;
+                    var infoContent = this.GetDeviceModelIdNameInfo("A419");
+                    return infoContent != null ? infoContent.A瀹樻柟鍚嶅瓧 : string.Empty;
                 }
             }
             else if (device.Type == DeviceType.FreshAirHumiditySensor)
             {
                 //鏂伴闈㈡澘/绠�绾﹀鍔熻兘/绠�绾︾幆澧冮潰鏉挎箍搴︿紶鎰熷櫒
-                return Language.StringByID(deviceInfoType.DefultNameId) + Language.StringByID(R.MyInternationalizationString.HumiditySensor);
+                return deviceInfoType.DeviceDefultName + Language.StringByID(R.MyInternationalizationString.HumiditySensor);
             }
             else if (device.Type == DeviceType.TemperatureSensor)
             {
@@ -1356,16 +1352,16 @@
                     || deviceInfoType.ConcreteType == DeviceConcreteType.ButtonPanel_SimpleMultifunction)
                 {
                     //鏂伴闈㈡澘/绠�绾﹀鍔熻兘/绠�绾︾幆澧冮潰鏉� 娓╁害浼犳劅鍣�
-                    return Language.StringByID(deviceInfoType.DefultNameId) + Language.StringByID(R.MyInternationalizationString.TemperatureSensor);
+                    return deviceInfoType.DeviceDefultName + Language.StringByID(R.MyInternationalizationString.TemperatureSensor);
                 }
                 else if (deviceInfoType.BeloneType == DeviceBeloneType.A鎸夐敭闈㈡澘)
                 {
                     //闈㈡澘鐨勬俯搴︽帰澶村彨  闈㈡澘鍚嶅瓧+娓╁害
-                    return Language.StringByID(deviceInfoType.DefultNameId) + Language.StringByID(R.MyInternationalizationString.uTemperature);
+                    return deviceInfoType.DeviceDefultName + Language.StringByID(R.MyInternationalizationString.uTemperature);
                 }
             }
             //鍏朵粬鎯呭喌,浣跨敤瀹冪殑榛樿鍚嶇О
-            return Language.StringByID(deviceInfoType.DefultNameId) + epointNo;
+            return deviceInfoType.DeviceDefultName + epointNo;
         }
 
         /// <summary>
@@ -1388,7 +1384,7 @@
 
             //鑾峰彇璁惧绫诲瀷
             var deviceInfoType = this.GetMyDeviceEnumInfo(new List<CommonDevice>() { device });
-            return Language.StringByID(deviceInfoType.DefultNameId);
+            return deviceInfoType.DeviceDefultName;
         }
 
         /// <summary>
@@ -1431,32 +1427,6 @@
         public string GetSimpleEpointName(CommonDevice device)
         {
             return device.DeviceEpointName;
-        }
-
-        /// <summary>
-        /// 鍒濆鍖朢鏂囦欢閲岄潰璁惧榛樿鍚嶅瓧鐨処D
-        /// </summary>
-        private void InitDeviceDefultNameIDList()
-        {
-            if (this.dicDeviceAllNameID != null)
-            {
-                return;
-            }
-            this.dicDeviceAllNameID = new Dictionary<string, int>();
-            Type type = typeof(R.MyInternationalizationString);
-
-            var PropertyList = type.GetFields();
-            foreach (var item in PropertyList)
-            {
-                if (item.Name.StartsWith(deviceModelIdName) == true
-                    || item.Name.StartsWith("uDeviceBelongId") == true)
-                {
-                    this.dicDeviceAllNameID[item.Name] = Convert.ToInt32(item.GetValue(null));
-                }
-            }
-
-            //鍒濆鍖栬澶囨灇涓�
-            this.InitDeviceModelIdEnum();
         }
 
         #endregion
@@ -1776,7 +1746,7 @@
             //鑾峰彇鑷畾涔夎澶囩被鍨�
             var myInfoType = this.GetMyDeviceEnumInfo(listDevice);
             //鑾峰彇璁惧绫诲瀷鐨勭炕璇戝悕瀛�
-            string strName = Language.StringByID(myInfoType.ObjectTypeNameId);
+            string strName = myInfoType.ObjectTypeName;
             if (strName == string.Empty)
             {
                 //鍔犱竴灞備繚闄�,鏈煡璁惧
@@ -1838,32 +1808,25 @@
                 return null;
             }
 
-            string[] strValue = this.dicDeviceModelIdEnum[modelKeys].Split(new string[] { "-" }, StringSplitOptions.RemoveEmptyEntries);
-            int ConcreteValue = Convert.ToInt32(strValue[0]);
-            int BeloneValue = Convert.ToInt32(strValue[1]);
+            var nameContent = this.dicDeviceModelIdEnum[modelKeys];
             //璁剧疆璁惧鐨勩�愯澶囨墍灞炵被鍨嬨��
-            info.BeloneType = (DeviceBeloneType)BeloneValue;
-            if (dicDeviceAllNameID.ContainsKey("uDeviceBelongId" + BeloneValue) == true)
-            {
-                //璁惧鎵�灞炵被鍨嬬殑缈昏瘧鍚嶅瓧
-                info.BeloneTextId = dicDeviceAllNameID["uDeviceBelongId" + BeloneValue];
-            }
+            info.BeloneType = (DeviceBeloneType)nameContent.BeloneTypeValue;
+            info.BeloneText = nameContent.A鎵�灞炲悕瀛�;
 
             //璁惧鍏蜂綋绫诲瀷
-            info.ConcreteType = (DeviceConcreteType)ConcreteValue;
-            if (info.ConcreteType.ToString() == ConcreteValue.ToString())
+            info.ConcreteType = (DeviceConcreteType)nameContent.ConcreteTypeValue;
+            if (info.ConcreteType.ToString() == nameContent.ConcreteTypeValue.ToString())
             {
                 info.ConcreteType = DeviceConcreteType.UnKownDevice;
             }
-            string keyName = deviceModelIdName + ConcreteValue;
-            if (this.dicDeviceAllNameID.ContainsKey(keyName) == true)
-            {
-                //璁惧鐨勫畼鏂瑰悕绉�
-                info.ConcreteTextId = this.dicDeviceAllNameID[keyName];
-            }
+            //璁惧鐨勫畼鏂瑰悕绉�
+            info.ConcreteText = nameContent.A瀹樻柟鍚嶅瓧;
 
             //璁惧鐨勭被鍨嬬炕璇戝悕绉�
-            info.ObjectTypeNameId = Convert.ToInt32(strValue[2]);
+            info.ObjectTypeName = nameContent.A绫诲瀷鍚嶅瓧;
+
+            //璁惧榛樿鍚嶅瓧
+            info.DeviceDefultName = nameContent.A澶囨敞鍚嶅瓧;
 
             return info;
         }
@@ -1884,33 +1847,21 @@
                 || info.BeloneType == DeviceBeloneType.A褰╃伅)
             {
                 //褰掍负鐏厜
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId15;
-                info.BeloneType = DeviceBeloneType.A鐏厜;
                 info.ConcreteType = DeviceConcreteType.Light;
-                info.ObjectTypeNameId = 60007;//璋冨厜妯″潡
-
-                int value = (int)info.BeloneType;
-                if (dicDeviceAllNameID.ContainsKey("uDeviceBelongId" + value) == true)
-                {
-                    //璁惧鎵�灞炵被鍨嬬殑缈昏瘧鍚嶅瓧
-                    info.BeloneTextId = dicDeviceAllNameID["uDeviceBelongId" + value];
-                }
+                info.ConcreteText = this.dicDeviceModelIdEnum["A418"].A瀹樻柟鍚嶅瓧;
+                info.BeloneType = DeviceBeloneType.A鐏厜;
+                info.BeloneText = this.dicDeviceModelIdEnum["A418"].A瀹樻柟鍚嶅瓧;
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A418"].A绫诲瀷鍚嶅瓧;//璋冨厜妯″潡
             }
             else if (info.BeloneType == DeviceBeloneType.A浼犳劅鍣�
                 || device.Type == DeviceType.TemperatureSensor)
             {
                 //浼犳劅鍣ㄥ悎骞�
-                info.BeloneType = DeviceBeloneType.A浼犳劅鍣�;
                 info.ConcreteType = DeviceConcreteType.Sensor;
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId1200;
-                info.ObjectTypeNameId = 60000;//浼犳劅鍣�
-
-                int value = (int)info.BeloneType;
-                if (dicDeviceAllNameID.ContainsKey("uDeviceBelongId" + value) == true)
-                {
-                    //璁惧鎵�灞炵被鍨嬬殑缈昏瘧鍚嶅瓧
-                    info.BeloneTextId = dicDeviceAllNameID["uDeviceBelongId" + value];
-                }
+                info.ConcreteText = this.dicDeviceModelIdEnum["A402"].A瀹樻柟鍚嶅瓧;
+                info.BeloneType = DeviceBeloneType.A浼犳劅鍣�;
+                info.BeloneText = this.dicDeviceModelIdEnum["A402"].A瀹樻柟鍚嶅瓧;
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A402"].A绫诲瀷鍚嶅瓧;//浼犳劅鍣�
             }
 
             return info;
@@ -1938,50 +1889,50 @@
             {
                 if (listdevice.Count > 1)
                 {
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId200;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A401"].A瀹樻柟鍚嶅瓧;
                     info.BeloneType = DeviceBeloneType.A鎸夐敭闈㈡澘;
                     info.ConcreteType = DeviceConcreteType.ButtonPanel;
                 }
                 else
                 {
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId16;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A419"].A瀹樻柟鍚嶅瓧;
                     info.BeloneType = DeviceBeloneType.A骞叉帴鐐�;
                     info.ConcreteType = DeviceConcreteType.DryContact;
                 }
-                info.ObjectTypeNameId = 60003;//鏅鸿兘闈㈡澘
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A401"].A绫诲瀷鍚嶅瓧;//鏅鸿兘闈㈡澘
             }
             //3鍖呭惈绐楀笜鐨勮瘽,褰撶獥甯樺鐞�
             else if (dicType.ContainsKey(DeviceType.WindowCoveringDevice) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId100;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A400"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A绐楀笜;
                 info.ConcreteType = DeviceConcreteType.Curtain;
-                info.ObjectTypeNameId = 60002;//閬槼妯″潡
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A400"].A绫诲瀷鍚嶅瓧;//閬槼妯″潡
             }
             //4绌烘皵寮�鍏�
             else if (dicType.ContainsKey(DeviceType.AirSwitch) == true)
             {
                 //榛樿鍊�
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId4100;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A408"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A寮�鍏�;
                 info.ConcreteType = DeviceConcreteType.AirSwitch;
-                info.ObjectTypeNameId = 60001;//寮�鍏虫ā鍧�
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A408"].A绫诲瀷鍚嶅瓧;//寮�鍏虫ā鍧�
 
                 if (dicType[DeviceType.AirSwitch].DfunctionType == DeviceFunctionType.A寮�鍏�)
                 {
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId13;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A416"].A瀹樻柟鍚嶅瓧;
                     info.BeloneType = DeviceBeloneType.A寮�鍏�;
                     info.ConcreteType = DeviceConcreteType.Switch;
                 }
                 else if (dicType[DeviceType.AirSwitch].DfunctionType == DeviceFunctionType.A鎻掑骇)
                 {
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId14;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A417"].A瀹樻柟鍚嶅瓧;
                     info.BeloneType = DeviceBeloneType.A鎻掑骇;
                     info.ConcreteType = DeviceConcreteType.Socket1;
                 }
                 else if (dicType[DeviceType.AirSwitch].DfunctionType == DeviceFunctionType.A鐏厜)
                 {
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId15;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A418"].A瀹樻柟鍚嶅瓧;
                     info.BeloneType = DeviceBeloneType.A鐏厜;
                     info.ConcreteType = DeviceConcreteType.Light;
                 }
@@ -1990,26 +1941,26 @@
             else if (dicType.ContainsKey(DeviceType.OnOffOutput) == true)
             {
                 //榛樿鍊�
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId2300;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A403"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A缁х數鍣�;
                 info.ConcreteType = DeviceConcreteType.Relay;
-                info.ObjectTypeNameId = 60001;//寮�鍏虫ā鍧�
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A403"].A绫诲瀷鍚嶅瓧;//寮�鍏虫ā鍧�
 
                 if (dicType[DeviceType.OnOffOutput].DfunctionType == DeviceFunctionType.A寮�鍏�)
                 {
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId13;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A416"].A瀹樻柟鍚嶅瓧;
                     info.BeloneType = DeviceBeloneType.A寮�鍏�;
                     info.ConcreteType = DeviceConcreteType.Switch;
                 }
                 else if (dicType[DeviceType.OnOffOutput].DfunctionType == DeviceFunctionType.A鎻掑骇)
                 {
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId14;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A417"].A瀹樻柟鍚嶅瓧;
                     info.BeloneType = DeviceBeloneType.A鎻掑骇;
                     info.ConcreteType = DeviceConcreteType.Socket1;
                 }
                 else if (dicType[DeviceType.OnOffOutput].DfunctionType == DeviceFunctionType.A鐏厜)
                 {
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId15;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A418"].A瀹樻柟鍚嶅瓧;
                     info.BeloneType = DeviceBeloneType.A鐏厜;
                     info.ConcreteType = DeviceConcreteType.Light;
                 }
@@ -2017,58 +1968,58 @@
             //6璋冨厜鍣�
             else if (dicType.ContainsKey(DeviceType.DimmableLight) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId2500;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A404"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A璋冨厜鍣�;
                 info.ConcreteType = DeviceConcreteType.DimmableLight;
-                info.ObjectTypeNameId = 60007;//璋冨厜妯″潡
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A404"].A绫诲瀷鍚嶅瓧;//璋冨厜妯″潡
             }
             //7褰╃伅
             else if (dicType.ContainsKey(DeviceType.ColorDimmableLight) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId9;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A410"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A褰╃伅;
                 info.ConcreteType = DeviceConcreteType.ColorLight;
-                info.ObjectTypeNameId = 60007;//璋冨厜妯″潡
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A410"].A绫诲瀷鍚嶅瓧;//璋冨厜妯″潡
             }
             //8绌鸿皟
             else if (dicType.ContainsKey(DeviceType.Thermostat) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId3600;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A406"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A绌鸿皟;
                 info.ConcreteType = DeviceConcreteType.AirConditioner;
-                info.ObjectTypeNameId = 60009;//绌鸿皟妯″潡
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A406"].A绫诲瀷鍚嶅瓧;//绌鸿皟妯″潡
             }
             //9涓户鍣�
             else if (dicType.ContainsKey(DeviceType.Repeater) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId3900;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A407"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A涓户鍣�;
                 info.ConcreteType = DeviceConcreteType.Repeater;
-                info.ObjectTypeNameId = 60006;//绯荤粺璁惧
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A407"].A绫诲瀷鍚嶅瓧;//绯荤粺璁惧
             }
             //10杞崲鍣�
             else if (dicType.ContainsKey(DeviceType.Transverter) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId4200;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A409"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A杞崲鍣�;
                 info.ConcreteType = DeviceConcreteType.Converter;
-                info.ObjectTypeNameId = 60008;//杞崲鍣�
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A409"].A绫诲瀷鍚嶅瓧;//杞崲鍣�
             }
             //11鏅鸿兘闂ㄩ攣
             else if (dicType.ContainsKey(DeviceType.DoorLock) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId2800;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A405"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A鏅鸿兘闂ㄩ攣;
                 info.ConcreteType = DeviceConcreteType.IntelligentLocks;
-                info.ObjectTypeNameId = 60010;//鏅鸿兘闂ㄩ攣
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A405"].A绫诲瀷鍚嶅瓧;//鏅鸿兘闂ㄩ攣
             }
             //12鍖呭惈浼犳劅鍣ㄧ殑璇�,褰撲紶鎰熷櫒澶勭悊
             else if (dicType.ContainsKey(DeviceType.IASZone) == true)
             {
                 info.BeloneType = DeviceBeloneType.A浼犳劅鍣�;
                 info.ConcreteType = DeviceConcreteType.Sensor;
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId1200;
-                info.ObjectTypeNameId = 60000;//浼犳劅鍣�
+                info.ConcreteText = this.dicDeviceModelIdEnum["A402"].A瀹樻柟鍚嶅瓧;
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A402"].A绫诲瀷鍚嶅瓧;//浼犳劅鍣�
                 //璁剧疆浼犳劅鍣ㄥ叿浣撶殑绫诲瀷
                 this.SetSensorDeviceSpecificType(ref info, listdevice);
             }
@@ -2099,56 +2050,53 @@
                 {
                     //璁剧疆浼犳劅鍣ㄥ叿浣撶殑绫诲瀷
                     info.BeloneType = DeviceBeloneType.A娓╂箍搴︿紶鎰熷櫒;
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId10;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A411"].A瀹樻柟鍚嶅瓧;
                     info.ConcreteType = DeviceConcreteType.Sensor_TemperatureHumidity;
                 }
                 else if (temperatrue == true && humidity == false)
                 {
                     //璁剧疆浼犳劅鍣ㄥ叿浣撶殑绫诲瀷
                     info.BeloneType = DeviceBeloneType.A娓╁害浼犳劅鍣�;
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId11;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A412"].A瀹樻柟鍚嶅瓧;
                     info.ConcreteType = DeviceConcreteType.Sensor_Temperature;
                 }
                 else if (temperatrue == false && humidity == true)
                 {
                     //璁剧疆浼犳劅鍣ㄥ叿浣撶殑绫诲瀷
                     info.BeloneType = DeviceBeloneType.A婀垮害浼犳劅鍣�;
-                    info.ConcreteTextId = R.MyInternationalizationString.uDeviceBelongId12;
+                    info.ConcreteText = this.dicDeviceModelIdEnum["A413"].A瀹樻柟鍚嶅瓧;
                     info.ConcreteType = DeviceConcreteType.Sensor_Humidity;
                 }
-                info.ObjectTypeNameId = 60000;//浼犳劅鍣�
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A411"].A绫诲瀷鍚嶅瓧;//浼犳劅鍣�
             }
             //14鏂伴璁惧
             else if (dicType.ContainsKey(DeviceType.FreshAir) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId2310;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A414"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A鏂伴;
                 info.ConcreteType = DeviceConcreteType.Relay_FangyueFreshAirModul;
-                info.ObjectTypeNameId = 60011;//鏂伴
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A414"].A绫诲瀷鍚嶅瓧;//鏂伴
             }
             //15 PM2.5浼犳劅鍣ㄨ澶�
             else if (dicType.ContainsKey(DeviceType.PMSensor) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId1307;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A415"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.APM2鐐�5绌烘皵璐ㄩ噺浼犳劅鍣�;
                 info.ConcreteType = DeviceConcreteType.Sensor_PMTwoPointFive;
-                info.ObjectTypeNameId = 60000;//浼犳劅鍣�
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A415"].A绫诲瀷鍚嶅瓧;//浼犳劅鍣�
             }
             //16鑹叉俯鐏�
             else if (dicType.ContainsKey(DeviceType.ColorTemperatureLight) == true)
             {
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId20000;
+                info.ConcreteText = this.dicDeviceModelIdEnum["A420"].A瀹樻柟鍚嶅瓧;
                 info.BeloneType = DeviceBeloneType.A褰╃伅;
                 info.ConcreteType = DeviceConcreteType.ColorLight_Temperature;
-                info.ObjectTypeNameId = 60007;//璋冨厜妯″潡
+                info.ObjectTypeName = this.dicDeviceModelIdEnum["A420"].A绫诲瀷鍚嶅瓧;//璋冨厜妯″潡
             }
 
-            int value = (int)info.BeloneType;
-            if (dicDeviceAllNameID.ContainsKey("uDeviceBelongId" + value) == true)
-            {
-                //璁惧鎵�灞炵被鍨嬬殑缈昏瘧鍚嶅瓧
-                info.BeloneTextId = dicDeviceAllNameID["uDeviceBelongId" + value];
-            }
+            //璁惧鎵�灞炵被鍨嬬殑缈昏瘧鍚嶅瓧
+            info.BeloneText = info.ConcreteText;
+            info.DeviceDefultName = info.ConcreteText;
 
             return info;
         }
@@ -2174,49 +2122,49 @@
             {
                 //杩愬姩浼犳劅鍣�
                 info.ConcreteType = DeviceConcreteType.Sensor_Motion;
-                info.ConcreteTextId = R.MyInternationalizationString.uMotionSensor;
+                info.ConcreteText = Language.StringByID(R.MyInternationalizationString.uMotionSensor);
             }
             else if (iasZone.IasDeviceType == 40)
             {
                 //鐑熼浘浼犳劅鍣�
                 info.ConcreteType = DeviceConcreteType.Sensor_Fire;
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId1302;
+                info.ConcreteText = Language.StringByID(R.MyInternationalizationString.uSensorFire);
             }
             else if (iasZone.IasDeviceType == 42)
             {
                 //姘翠镜浼犳劅鍣�
                 info.ConcreteType = DeviceConcreteType.Sensor_Water;
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId1304;
+                info.ConcreteText = Language.StringByID(R.MyInternationalizationString.uSensorWater);
             }
             else if (iasZone.IasDeviceType == 43)
             {
                 //鐕冩皵浼犳劅鍣�
                 info.ConcreteType = DeviceConcreteType.Sensor_CarbonMonoxide;
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId1300;
+                info.ConcreteText = Language.StringByID(R.MyInternationalizationString.uSensorCarbonMonoxide);
             }
             else if (iasZone.IasDeviceType == 44)
             {
                 //绱ф�ユ寜閽�
                 info.ConcreteType = DeviceConcreteType.Sensor_EmergencyButton;
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId1305;
+                info.ConcreteText = Language.StringByID(R.MyInternationalizationString.uSensorEmergencyButton);
             }
             else if (iasZone.IasDeviceType == 277)
             {
                 //閽ュ寵鎵�
                 info.ConcreteType = DeviceConcreteType.Sensor_Keyfob;
-                info.ConcreteTextId = R.MyInternationalizationString.uKeyfob;
+                info.ConcreteText = Language.StringByID(R.MyInternationalizationString.uKeyfob);
             }
             else if (iasZone.IasDeviceType == 21 || iasZone.IasDeviceType == 22)
             {
                 //闂ㄧ獥浼犳劅鍣�
                 info.ConcreteType = DeviceConcreteType.Sensor_DoorWindow;
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId1301;
+                info.ConcreteText = Language.StringByID(R.MyInternationalizationString.uSensorDoorWindow);
             }
             else if (iasZone.IasDeviceType == 541)
             {
                 //鐞冨瀷绉诲姩浼犳劅鍣�
                 info.ConcreteType = DeviceConcreteType.Sensor_SphericalMotion;
-                info.ConcreteTextId = R.MyInternationalizationString.uDeviceModelId1205;
+                info.ConcreteText = this.dicDeviceModelIdEnum["MSPIRB-ZB.10"].A瀹樻柟鍚嶅瓧;
             }
         }
 
@@ -2474,9 +2422,15 @@
         /// 浠庣紦瀛樺彉閲忔娴嬭澶囨槸鍚﹀湪绾�
         /// </summary>
         /// <param name="i_device"></param>
+        /// <param name="checkAll">鏄惁妫�娴嬪叏閮ㄥ洖璺�</param>
         /// <returns></returns>
-        public bool CheckDeviceIsOnline(CommonDevice i_device)
+        public bool CheckDeviceIsOnline(CommonDevice i_device, bool checkAll = true)
         {
+            if (checkAll == false)
+            {
+                //涓嶆娴嬪叏閮ㄥ洖璺�
+                return i_device.IsOnline == 1 || i_device.IsOnline == 2;
+            }
             var listDevice = this.GetDevicesByMac(i_device.DeviceAddr, false);
             foreach (var device in listDevice)
             {
@@ -2601,6 +2555,20 @@
         }
 
         /// <summary>
+        /// 鑾峰彇妯″潡ID鎵�鎸囧悜鐨勫悇绉嶅悕瀛椾俊鎭�
+        /// </summary>
+        /// <param name="strKey"></param>
+        /// <returns></returns>
+        public DeviceNameContent GetDeviceModelIdNameInfo(string strKey)
+        {
+            if (this.dicDeviceModelIdEnum.ContainsKey(strKey) == false)
+            {
+                return null;
+            }
+            return this.dicDeviceModelIdEnum[strKey];
+        }
+
+        /// <summary>
         /// 闄勫姞璁惧鐨勭増鏈唬鍙�(杩斿洖Ver.XXX)
         /// </summary>
         /// <param name="versionValue">鐗堟湰鍙�</param>
@@ -2631,7 +2599,7 @@
         /// <param name="msg"></param>
         private void ShowErrorMsg(string msg)
         {
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 var contr = new ShowMsgControl(ShowMsgType.Error, msg);
                 contr.Show();
@@ -2644,7 +2612,7 @@
         /// <param name="msg"></param>
         private void ShowTipMsg(string msg)
         {
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 var contr = new ShowMsgControl(ShowMsgType.Tip, msg);
                 contr.Show();
@@ -2663,22 +2631,11 @@
         /// </summary>
         /// <param name="zbGateway">缃戝叧瀵硅薄</param>
         /// <param name="statu">鐘舵��-> -1:寮傚父,浼氳繑鍥瀗ull, 1锛氭病鏈夊紓甯�, 2:鏁版嵁鎺ユ敹涓嶅叏</param>
-        /// <param name="ignoreTime">鏄惁鏃犺鏃堕棿(姝ゅ彉閲忔槸缁欒幏鍙栧湪绾跨姸鎬佺敤鐨�),true:姣忔璋冪敤閮藉幓缃戝叧鑾峰彇,false:3鍒嗛挓鍐呰繑鍥炵殑鏄湰鍦扮殑璁惧</param>
+        /// <param name="useLocalConnect">鏄惁浣跨敤鏈湴杩炴帴鍙戦��</param>
         /// <param name="mode">鏄惁鏄剧ず閿欒</param>
         /// <returns></returns>
-        public List<CommonDevice> GetDeviceListFromGateway(ZbGateway zbGateway, ref int statu, bool ignoreTime, ShowErrorMode mode = ShowErrorMode.YES)
+        public List<CommonDevice> GetDeviceListFromGateway(ZbGateway zbGateway, ref int statu, bool useLocalConnect, ShowErrorMode mode = ShowErrorMode.YES)
         {
-            if (ignoreTime == false)
-            {
-                if ((DateTime.Now - zbGateway.LastDateTime).TotalMilliseconds < 3 * 60 * 1000)
-                {
-                    //涓嶆棤瑙嗘椂闂�,杩斿洖鏈湴璁惧鍒楄〃
-                    statu = 1;
-                    return this.GetDeviceByGatewayID(zbGateway.GwId);
-                }
-            }
-            zbGateway.LastDateTime = DateTime.Now;
-
             //濡傛灉鍒囨崲鍒颁簡鍒殑鐣岄潰锛屽垯涓嶆樉绀洪敊璇俊鎭�
             string nowFormId = UserCenterResourse.NowActionFormID;
 
@@ -2694,6 +2651,8 @@
                 statu = -1;
                 return null;
             }
+            //闇�瑕佸彉鏇村姛鑳界被鍨嬬殑鍥炶矾
+            var listFucDevice = new List<CommonDevice>();
 
             //鏄惁杈炬垚涓柇鐨勬椂鏈�
             bool canBreak = false;
@@ -2752,6 +2711,11 @@
                                     {
                                         //鍒锋柊灞炴��
                                         this.SetDeviceInfoToMain(localDevice, device);
+                                        if (this.RefreshDeviceFunctionType(localDevice, device, false) == true)
+                                        {
+                                            //闇�瑕佸彂閫佸姛鑳界被鍨嬬粰缃戝叧
+                                            listFucDevice.Add(localDevice);
+                                        }
                                     }
                                 }
                             }
@@ -2775,7 +2739,15 @@
             try
             {
                 var jObject = new Newtonsoft.Json.Linq.JObject { { "Cluster_ID", 0 }, { "Command", 93 } };
-                realWay.Send("GetDeviceInfo", jObject.ToString());
+                if (useLocalConnect == false)
+                {
+                    realWay.Send("GetDeviceInfo", jObject.ToString());
+                }
+                else
+                {
+                    //寮哄埗浣跨敤鏈湴杩炴帴
+                    realWay.SendLocation("GetDeviceInfo", Encoding.UTF8.GetBytes(jObject.ToString()));
+                }
             }
             catch { canBreak = true; }
 
@@ -2819,6 +2791,19 @@
             {
                 statu = 1;
             }
+            if (listFucDevice.Count > 0)
+            {
+                //濡傛灉瀛樺湪闇�瑕佸彉鏇寸殑鍔熻兘绫诲瀷
+                HdlThreadLogic.Current.RunThread(() =>
+                {
+                    for (int i = 0; i < listFucDevice.Count; i++)
+                    {
+                        this.SendDeviceFunctionTypeToGateway(listFucDevice[i], listFucDevice[i].DfunctionType);
+                        System.Threading.Thread.Sleep(100);
+                    }
+                });
+            }
+
             return listDevice;
         }
 
@@ -2827,7 +2812,7 @@
         #region 鈻� 鍒涘缓鏂拌澶囧璞$浉鍏砡________________
 
         /// <summary>
-        /// 鏍规嵁璁惧绫诲瀷鍒涘缓璁惧瀵硅薄鐨勫疄渚�
+        /// 鏍规嵁璁惧绫诲瀷鍒涘缓璁惧瀵硅薄鐨勫疄渚�(鏁版嵁鍦―eviceInfo涓�)
         /// </summary>
         /// <param name="deviceType">璁惧绫诲瀷</param>
         /// <param name="jobject">涓婚Data</param>
@@ -2850,15 +2835,10 @@
             {
                 return null;
             }
-            this.SetMacName(device, string.Empty);
-            this.SetEpointName(device, string.Empty);
 
             //璁剧疆璁惧涓婚敭绫�
             this.SetNewDeviceMainKeys(device, jobject);
             device.CurrentGateWayId = gwId;
-
-            //灏咲eviceInfo鐨勫睘鎬ц缃埌涓诲睘鎬т腑
-            this.SetDeviceInfoToMain(device, device);
 
             return device;
         }
@@ -2900,6 +2880,11 @@
             mainDevice.SerialNumber = device.DeviceInfo.ProductCode;
             //璁惧鍔熻兘绫诲瀷
             mainDevice.DfunctionType = (DeviceFunctionType)device.DeviceInfo.FunctionType;
+            if (mainDevice.DfunctionType == DeviceFunctionType.A涓嶆寚瀹�)
+            {
+                //寮忔牱鍙樻洿:鍔熻兘绫诲瀷涓嶅厑璁搁�夋嫨涓虹┖ 缃戝叧榛樿鐨凢unctionType涓�0
+                mainDevice.DfunctionType = DeviceFunctionType.A鏈畾涔�;
+            }
 
             mainDevice.InClusterList.Clear();
             mainDevice.InClusterList.AddRange(device.DeviceInfo.InClusterList);
@@ -2921,104 +2906,6 @@
                         ((TemperatureSensor)mainDevice).SensorDiv = 1;
                     }
                 }
-            }
-            //濡傛灉鏄皟鍏夊櫒
-            else if (mainDevice.Type == DeviceType.DimmableLight)
-            {
-                mainDevice.DfunctionType = DeviceFunctionType.A鐏厜;
-                if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A鐏厜)
-                {
-                    //璋冨厜鍣ㄥ浐瀹氱伅鍏�
-                    this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A鐏厜);
-                }
-                if (mainDevice.IsCustomizeImage == false)
-                {
-                    mainDevice.IconPath = "Device/Light.png";
-                }
-            }
-            //濡傛灉鏄壊娓╃伅
-            else if (mainDevice.Type == DeviceType.ColorTemperatureLight)
-            {
-                mainDevice.DfunctionType = DeviceFunctionType.A鐏厜;
-                if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A鐏厜)
-                {
-                    //鑹叉俯鐏浐瀹氱伅鍏�
-                    this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A鐏厜);
-                }
-                if (mainDevice.IsCustomizeImage == false)
-                {
-                    mainDevice.IconPath = "Device/ColorLightTemperature.png";
-                }
-            }
-            //濡傛灉鏄笁璺户鐢靛櫒鐨勫洖璺殑璇�,榛樿涓虹伅鍏�
-            else if (mainDevice.Type == DeviceType.OnOffOutput)
-            {
-                //2020.05.13鍙樻洿:缁х數鍣ㄩ兘榛樿涓虹伅鍏�
-                if (mainDevice.DfunctionType == DeviceFunctionType.A鏈畾涔�)
-                {
-                    mainDevice.DfunctionType = DeviceFunctionType.A鐏厜;
-                    if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A鐏厜)
-                    {
-                        //缁х數鍣ㄩ粯璁や负鐏厜
-                        this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A鐏厜);
-                    }
-                }
-                //鏍规嵁鍔熻兘绫诲瀷,閲嶆柊璁剧疆璁惧鍥炶矾鍥炬爣
-                this.ResetIconPathByDeviceFunctionType(mainDevice);
-            }
-            //濡傛灉鏄┖姘斿紑鍏崇殑璇�
-            else if (mainDevice.Type == DeviceType.AirSwitch)
-            {
-                //绌烘皵寮�鍏抽粯璁や负寮�鍏�
-                if (mainDevice.DfunctionType == DeviceFunctionType.A鏈畾涔�)
-                {
-                    mainDevice.DfunctionType = DeviceFunctionType.A寮�鍏�;
-                    if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A寮�鍏�)
-                    {
-                        //绌烘皵寮�鍏抽粯璁や负寮�鍏�
-                        this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A寮�鍏�);
-                    }
-                }
-                //鏍规嵁鍔熻兘绫诲瀷,閲嶆柊璁剧疆璁惧鍥炶矾鍥炬爣
-                this.ResetIconPathByDeviceFunctionType(mainDevice);
-            }
-            //濡傛灉鏄僵鐏殑璇�
-            else if (mainDevice.Type == DeviceType.ColorDimmableLight)
-            {
-                mainDevice.DfunctionType = DeviceFunctionType.A鐏厜;
-                if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A鐏厜)
-                {
-                    //褰╃伅榛樿涓哄紑鍏�
-                    this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A鐏厜);
-                }
-                if (mainDevice.IsCustomizeImage == false)
-                {
-                    mainDevice.IconPath = "Device/ColorLight.png";
-                }
-            }
-        }
-
-        /// <summary>
-        /// 鏍规嵁鍔熻兘绫诲瀷,閲嶆柊璁剧疆璁惧鍥炶矾鍥炬爣
-        /// </summary>
-        /// <param name="device"></param>
-        private void ResetIconPathByDeviceFunctionType(CommonDevice device)
-        {
-            if (device.IsCustomizeImage == true)
-            {
-                return;
-            }
-            if (device.DfunctionType == DeviceFunctionType.A寮�鍏�)
-            {
-                device.IconPath = "Device/Switch.png";
-            }
-            else if (device.DfunctionType == DeviceFunctionType.A鎻掑骇)
-            {
-                device.IconPath = "Device/Socket1.png";
-            }
-            else
-            {
-                device.IconPath = "Device/Light.png";
             }
         }
 
@@ -3075,6 +2962,139 @@
 
         #endregion
 
+        #region 鈻� 鍒锋柊璁惧鍔熻兘绫诲瀷___________________
+
+        /// <summary>
+        /// 鍒锋柊璁惧鐨勫姛鑳界被鍨�,濡傛灉杩斿洖true,浠h〃闇�瑕佸彟澶栬皟鐢ㄣ�怱endDeviceFunctionTypeToGateway銆戝嚱鏁�,sendFucType涓簍rue鏃惰嚜鍔ㄨ皟鐢�
+        /// </summary>
+        /// <param name="mainDevice">涓昏澶囧璞�</param>
+        /// <param name="device">璁剧疆婧愯澶囧璞�</param>
+        /// <param name="sendFucType">褰撻渶瑕佸彉鏇存椂,鏄惁鍙戦�佸姛鑳界被鍨嬪埌缃戝叧(姝ゅ彉閲忕粰鑾峰彇璁惧鍒楄〃鏈夌壒娈婂惈涔�)</param>
+        public bool RefreshDeviceFunctionType(CommonDevice mainDevice, CommonDevice device, bool sendFucType)
+        {
+            //濡傛灉鏄皟鍏夊櫒
+            if (mainDevice.Type == DeviceType.DimmableLight)
+            {
+                if (mainDevice.IsCustomizeImage == false)
+                {
+                    mainDevice.IconPath = "Device/Light.png";
+                }
+                mainDevice.DfunctionType = DeviceFunctionType.A鐏厜;
+                if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A鐏厜)
+                {
+                    //璋冨厜鍣ㄥ浐瀹氱伅鍏�
+                    if (sendFucType == true)
+                    {
+                        this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A鐏厜);
+                    }
+                    return true;
+                }
+            }
+            //濡傛灉鏄壊娓╃伅
+            else if (mainDevice.Type == DeviceType.ColorTemperatureLight)
+            {
+                if (mainDevice.IsCustomizeImage == false)
+                {
+                    mainDevice.IconPath = "Device/ColorLightTemperature.png";
+                }
+                mainDevice.DfunctionType = DeviceFunctionType.A鐏厜;
+                if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A鐏厜)
+                {
+                    //鑹叉俯鐏浐瀹氱伅鍏�
+                    if (sendFucType == true)
+                    {
+                        this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A鐏厜);
+                    }
+                    return true;
+                }
+            }
+            //濡傛灉鏄笁璺户鐢靛櫒鐨勫洖璺殑璇�,榛樿涓虹伅鍏�
+            else if (mainDevice.Type == DeviceType.OnOffOutput)
+            {
+                //鏍规嵁鍔熻兘绫诲瀷,閲嶆柊璁剧疆璁惧鍥炶矾鍥炬爣
+                this.ResetIconPathByDeviceFunctionType(mainDevice);
+                //2020.05.13鍙樻洿:缁х數鍣ㄩ兘榛樿涓虹伅鍏�
+                if (mainDevice.DfunctionType == DeviceFunctionType.A鏈畾涔�)
+                {
+                    mainDevice.DfunctionType = DeviceFunctionType.A鐏厜;
+                    if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A鐏厜)
+                    {
+                        //缁х數鍣ㄩ粯璁や负鐏厜
+                        if (sendFucType == true)
+                        {
+                            this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A鐏厜);
+                        }
+                        return true;
+                    }
+                }
+            }
+            //濡傛灉鏄┖姘斿紑鍏崇殑璇�
+            else if (mainDevice.Type == DeviceType.AirSwitch)
+            {
+                //鏍规嵁鍔熻兘绫诲瀷,閲嶆柊璁剧疆璁惧鍥炶矾鍥炬爣
+                this.ResetIconPathByDeviceFunctionType(mainDevice);
+                //绌烘皵寮�鍏抽粯璁や负寮�鍏�
+                if (mainDevice.DfunctionType == DeviceFunctionType.A鏈畾涔�)
+                {
+                    mainDevice.DfunctionType = DeviceFunctionType.A寮�鍏�;
+                    if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A寮�鍏�)
+                    {
+                        //绌烘皵寮�鍏抽粯璁や负寮�鍏�
+                        if (sendFucType == true)
+                        {
+                            this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A寮�鍏�);
+                        }
+                        return true;
+                    }
+                }
+            }
+            //濡傛灉鏄僵鐏殑璇�
+            else if (mainDevice.Type == DeviceType.ColorDimmableLight)
+            {
+                if (mainDevice.IsCustomizeImage == false)
+                {
+                    mainDevice.IconPath = "Device/ColorLight.png";
+                }
+                mainDevice.DfunctionType = DeviceFunctionType.A鐏厜;
+                if (device.DeviceInfo.FunctionType != (int)DeviceFunctionType.A鐏厜)
+                {
+                    //褰╃伅榛樿涓哄紑鍏�
+                    if (sendFucType == true)
+                    {
+                        this.SendDeviceFunctionTypeToGateway(mainDevice, DeviceFunctionType.A寮�鍏�);
+                    }
+                    return true;
+                }
+            }
+            return false;
+        }
+
+        /// <summary>
+        /// 鏍规嵁鍔熻兘绫诲瀷,閲嶆柊璁剧疆璁惧鍥炶矾鍥炬爣
+        /// </summary>
+        /// <param name="device"></param>
+        private void ResetIconPathByDeviceFunctionType(CommonDevice device)
+        {
+            if (device.IsCustomizeImage == true)
+            {
+                return;
+            }
+            if (device.DfunctionType == DeviceFunctionType.A寮�鍏�)
+            {
+                device.IconPath = "Device/Switch.png";
+            }
+            else if (device.DfunctionType == DeviceFunctionType.A鎻掑骇)
+            {
+                device.IconPath = "Device/Socket1.png";
+            }
+            else
+            {
+                device.IconPath = "Device/Light.png";
+            }
+        }
+
+        #endregion
+
         //----------------------------------鍒嗗壊绾�(璁惧妯″潡ID)---------------------------------------------
 
         #region 鈻� 鑷畾涔夎澶囨ā鍧桰D___________________
@@ -3084,108 +3104,49 @@
         /// </summary>
         private void InitDeviceModelIdEnum()
         {
+            //*********************************************************************
+            //鏂拌澶囨坊鍔犳柟娉曪細
+            //1銆佸湪鏈�涓嬮潰娣诲姞 DeviceConcreteType 锛岀劧鍚庢槸 DeviceBeloneType
+            //2銆佷互璁惧鐨勫叿浣撶被鍨嬩负鍚嶅瓧DeviceConcreteType(鍘绘帀銆�-銆�)娣诲姞璁惧鐨勩�愭墍灞炲浘鐗囥�戯紝銆愮湡瀹炵墿鐞嗗浘鐗囥�戙�傚洖璺浘鐗囬渶瑕佺壒娈婂鐞�
+            //3銆佸鏋滈渶瑕佸叡鏈夊浘鐗�,鍒欏湪杩欎釜鍑芥暟鐨勬渶搴曚笅娣诲姞
+            //4銆佹樉绀虹殑妯″潡ID闇�瑕佷氦鎹㈢殑璇�,鍒欏湪杩欎釜鍑芥暟鐨勬渶搴曚笅娣诲姞
+            //*********************************************************************
+
             if (this.dicDeviceModelIdEnum != null)
             {
                 return;
             }
-            this.dicDeviceModelIdEnum = new Dictionary<string, string>();
+            this.dicDeviceModelIdEnum = new Dictionary<string, DeviceNameContent>();
 
-            //*********************************************************************
-            //鏂拌澶囨坊鍔犳柟娉曪細
-            //1銆佸湪杩欓噷濉啓涓婃ā鍧桰D锛岀劧鍚庢槸 DeviceConcreteType 锛岀劧鍚庢槸 DeviceBeloneType , 鐒跺悗鏄� 璁惧绫诲瀷鐨勭炕璇慖D
-            //2銆佺劧鍚庡湪鏈�涓嬮潰鐨勩�愯嚜瀹氫箟璁惧绫诲瀷銆戞姌鍙犳爮閲屾坊鍔犮�愯澶囩殑鍏蜂綋绫诲瀷銆戯紝銆愯澶囩殑鎵�灞炵被鍨嬨��
-            //3銆佷互璁惧鐨勫叿浣撶被鍨嬩负鍚嶅瓧(鍘绘帀銆�-銆�)娣诲姞璁惧鐨勩�愭墍灞炲浘鐗囥�戯紝銆愮湡瀹炵墿鐞嗗浘鐗囥�戙�傚洖璺浘鐗囬渶瑕佺壒娈婂鐞�
-            //4銆佹坊鍔燫鏂囦欢(uDeviceModelId),娣诲姞Language鏂囦欢
-            //5銆佸鏋滈渶瑕佸叡鏈夊浘鐗�,鍒欏湪杩欎釜鍑芥暟鐨勬渶搴曚笅娣诲姞
-            //*********************************************************************
-
-            //鍓嶈█锛氬洜涓簔igbeehome鐨勮澶囨嫢鏈夊洓绉嶅悕瀛楋細
-            //1銆佽澶囧畼鏂瑰悕绉�            ----瀹冪敱DeviceConcreteType鐨勬暟鍊兼墍鍐冲畾(涓汉涓績涓撶敤)
-            //2銆佽澶囧叆缃戝悗鐨勯粯璁ゅ悕绉�    ----瀹冧笉闇�瑕佸湪浠g爜閲岄潰瀹氫箟,瀹冪洿鎺ュ湪Language鏂囦欢閲岄潰瀹氫箟
-            //                               鑼冨洿锛�50000寮�濮�,瀹冪殑瑙勫垯鏄疍eviceConcreteType瀵瑰簲鐨凴鏂囦欢閲岄潰鐨処D鐨勬暟鍊�+20000,
-            //3銆佽澶囨墍灞炲悕绉�            ----瀹冩湁DeviceBeloneType鐨勬暟鍊兼墍鍐冲畾
-            //4銆佽澶囩被鍨嬪悕绉�            ----瀹冪敱銆愯澶囩被鍨嬬殑缈昏瘧ID銆戞墍鍐冲畾,杩欎釜鍊兼槸涓汉涓績涓撶敤,
-            //                               瀹冩槸Language鏂囦欢閲岄潰鐨� 60000涔嬪悗鐨勯偅浜涘��
-
-            //瀹氫箟瑙勫垯锛氭ā鍧桰D(宸茬炕璇�) = 璁惧鍏蜂綋绫诲瀷鍊� - 璁惧鎵�灞炵被鍨嬪�� - 璁惧绫诲瀷鐨勭炕璇慖D
-            //璁惧鍏蜂綋绫诲瀷鍊硷細DeviceConcreteType(鍦ㄨ繖涓枃浠舵渶涓嬮潰杩涜瀹氫箟)
-            //璁惧鎵�灞炵被鍨嬪��: DeviceBeloneType(鑷畾涔夌殑鍊�,鍢�,鍙涓嶉噸澶嶅氨鍙互,鍦ㄨ繖涓枃浠舵渶涓嬮潰杩涜瀹氫箟)
-            //璁惧绫诲瀷鐨勭炕璇慖D:杩欎釜鍊兼槸涓汉涓績涓撶敤,瀹冩槸Language鏂囦欢閲岄潰鐨� 60000涔嬪悗鐨勯偅浜涘��
-
-            //=========鈽呪槄寮�鍚堝笜绫�(100-199)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MWM65B-ZB.20"] = "100-100-60002";//鏅鸿兘寮�鍚堝笜鐢垫満
-            this.dicDeviceModelIdEnum["MVSM35B-ZB.20"] = "101-100-60002";//鏅鸿兘绠$姸鐢垫満
-
-            //=========鈽呪槄鎸夐敭闈㈡澘绫�(200-1199)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MPT4/R4-ZB.18"] = "200-200-60003";//4鎸夐敭瑙︽懜闈㈡澘(甯�4璺户鐢靛櫒搴曞骇)
-            this.dicDeviceModelIdEnum["MPT3/R3-ZB.18"] = "201-200-60003";//3鎸夐敭瑙︽懜闈㈡澘
-            this.dicDeviceModelIdEnum["MPT2/R2-ZB.18"] = "202-200-60003";//2鎸夐敭瑙︽懜闈㈡澘
-            this.dicDeviceModelIdEnum["MPT1/R1-ZB.18"] = "203-200-60003";//12鎸夐敭瑙︽懜闈㈡澘
-            this.dicDeviceModelIdEnum["MPT4-ZB.18"] = "210-200-60003";//4鎸夐敭瑙︽懜闈㈡澘(鍙甫鐢垫簮搴曞骇)
-            this.dicDeviceModelIdEnum["MPT4R4L/S-ZB.18"] = "220-200-60003";//绠�绾�4鎸夐敭闈㈡澘
-            this.dicDeviceModelIdEnum["MPT3R3L/S-ZB.18"] = "221-200-60003";//绠�绾�3鎸夐敭闈㈡澘
-            this.dicDeviceModelIdEnum["MPT2R2L/S-ZB.18"] = "222-200-60003";//绠�绾�2鎸夐敭闈㈡澘
-            this.dicDeviceModelIdEnum["MPT4SC/S-ZB.18"] = "224-200-60003";//绠�绾�4鎸夐敭鍦烘櫙闈㈡澘
-            this.dicDeviceModelIdEnum["MPT2W/S-ZB.18"] = "226-200-60003";//绠�绾�2璺獥甯橀潰鏉�
-            this.dicDeviceModelIdEnum["MP2B/TILE-ZB.18"] = "240-200-60003";//鏂规偊鍗曞紑鍙屾帶闈㈡澘
-            this.dicDeviceModelIdEnum["MP4B/TILE-ZB.18"] = "241-200-60003";//鏂规偊鍙屽紑鍥涙帶闈㈡澘
-            this.dicDeviceModelIdEnum["MP8B/TILE-ZB.18"] = "242-200-60003";//鏂规偊鍥涘紑鍏帶闈㈡澘
-            this.dicDeviceModelIdEnum["MPFA/TILE-ZB.18"] = "250-200-60003";//鏂规偊鏂伴闈㈡澘
-            this.dicDeviceModelIdEnum["MPTE3/TILE-ZB.18"] = "253-200-60003";//鏂规偊鐜闈㈡澘
-            this.dicDeviceModelIdEnum["MP2W/TILE-ZB.18"] = "256-200-60003";//绐楀笜闈㈡澘
-            this.dicDeviceModelIdEnum["MPTL4C/S-ZB.18"] = "212-200-60003";//绠�绾﹀鍔熻兘闈㈡澘
-            this.dicDeviceModelIdEnum["MPTE3/S-ZB.18"] = "230-200-60003";//绠�绾︾幆澧冮潰鏉�
-
-
-            //=========鈽呪槄PIR浼犳劅鍣ㄧ被(1200-1299)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MSPIR01-ZB.10"] = "1200-1200-60000";//pir浼犳劅鍣�220
-            this.dicDeviceModelIdEnum["MSPIRB-ZB.10"] = "1205-1200-60000";//鐞冨瀷绉诲姩浼犳劅鍣�
-
-            //=========鈽呪槄瀹夐槻绫讳紶鎰熷櫒绫�(1300-2299)鈽呪槄=========
-            //杩欓噷鏄害涔愬厠鐨�
-            this.dicDeviceModelIdEnum["MULTI-GASE--EA07"] = "1300-1200-60000";//鐕冩皵浼犳劅鍣�
-            this.dicDeviceModelIdEnum["MULTI-MECI--EA01"] = "1301-1200-60000";//闂ㄧ獥纾佷紶鎰熷櫒
-            this.dicDeviceModelIdEnum["MULTI-FIRE--EA05"] = "1302-1200-60000";//鐑熼浘浼犳劅鍣�
-            this.dicDeviceModelIdEnum["MULTI-MOTI--EA04"] = "1303-1200-60000";//绾㈠浼犳劅鍣�
-            this.dicDeviceModelIdEnum["MULTI-WATE--EA02"] = "1304-1200-60000";//姘存蹈浼犳劅鍣�
-            this.dicDeviceModelIdEnum["MULTI-BURO--EA06"] = "1305-1200-60000";//绱ф�ユ寜閿�
-            //杩欓噷鏄渤涓滅殑
-            this.dicDeviceModelIdEnum["MSG01/M-ZB.10"] = "1300-1200-60000";//鐕冩皵浼犳劅鍣�
-            this.dicDeviceModelIdEnum["MSDC01/M-ZB.10"] = "1301-1200-60000";//闂ㄧ獥纾佷紶鎰熷櫒
-            this.dicDeviceModelIdEnum["MSS01/M-ZB.10"] = "1302-1200-60000";//鐑熼浘浼犳劅鍣�
-            this.dicDeviceModelIdEnum["MSPIR01/M-ZB.10"] = "1303-1200-60000";//绾㈠浼犳劅鍣�
-            this.dicDeviceModelIdEnum["MSW01/M-ZB.10"] = "1304-1200-60000";//姘存蹈浼犳劅鍣�
-            this.dicDeviceModelIdEnum["MBU01/M-ZB.10"] = "1305-1200-60000";//绱ф�ユ寜閿�
-            this.dicDeviceModelIdEnum["MGCD01/M-ZB.10"] = "1306-1200-60000";//鍚搁《鐕冩皵浼犳劅鍣�
-
-            //PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� 銆愯璁惧灞炰簬绗笁鏂硅澶囷紝娌℃湁闀滃儚ID銆�
-            this.dicDeviceModelIdEnum["MSPM25/M-ZB.10"] = "1307-1200-60000";//PM2.5绌烘皵璐ㄩ噺浼犳劅鍣� 
-
-            //=========鈽呪槄缁х數鍣ㄧ被(2300-2499)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MPR0310-ZB.10"] = "2300-2300-60001";//3璺户鐢靛櫒灏忔ā鍧�
-            this.dicDeviceModelIdEnum["MFA01-ZB.10"] = "2310-2300-60011";//鏂规偊鏂伴灏忔ā鍧�
-
-            //=========鈽呪槄璋冨厜鍣ㄧ被(2500-2799)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MPD0101-ZB.10"] = "2500-2500-60007";//1璺皟鍏夊櫒灏忔ā鍧�
-
-            //=========鈽呪槄鏅鸿兘闂ㄩ攣绫�(2800-????)鈽呪槄=========
-            this.dicDeviceModelIdEnum["H06C"] = "2800-2800-60010";//鏅鸿兘闂ㄩ攣(H06C)
-            this.dicDeviceModelIdEnum["S-one"] = "2802-2800-60010";//鏅鸿兘闂ㄩ攣(S-one)
-
-            //=========鈽呪槄绌鸿皟绫�(3600-3899)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MAC/GW-ZB.10"] = "3600-3600-60009";//zigbee绌鸿皟缃戝叧妯″潡
-
-            //=========鈽呪槄涓户鍣ㄧ被(3900-3999)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MSR-ZB.10"] = "3900-3900-60006"; //zigbee涓户鍣�
-
-            //=========鈽呪槄绌烘皵寮�鍏崇被(4100-4199)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MBCI01-ZB.10"] = "4100-4100-60001";//zigbee寰柇浜戞帶鍒跺櫒
-
-            //=========鈽呪槄杞崲鍣ㄧ被(4200-4699)鈽呪槄=========
-            this.dicDeviceModelIdEnum["MBUS/GW-ZB.10"] = "4200-4200-60008";//zigbee杞琤uspro鍗忚杞崲鍣�
-            this.dicDeviceModelIdEnum["M485/GW-ZB.10"] = "4201-4200-60008";//zigbee杞�485鍗忚杞崲鍣�
-
-
+            var listText = this.GetDeviceNameFileContent();
+            foreach (var dataText in listText)
+            {
+                if (dataText == string.Empty || dataText.StartsWith(";") == true)
+                {
+                    //杩欐槸娉ㄩ噴
+                    continue;
+                }
+                string[] strArry1 = dataText.Split(new string[] { "=" }, StringSplitOptions.RemoveEmptyEntries);
+                if (strArry1.Length != 2)
+                {
+                    //闈炴硶璁剧疆
+                    continue;
+                }
+                string[] strArry2 = strArry1[1].Split(new string[] { "/" }, StringSplitOptions.RemoveEmptyEntries);
+                if (strArry2.Length < 6)
+                {
+                    //闈炴硶璁剧疆
+                    continue;
+                }
+                var content = new DeviceNameContent();
+                content.ConcreteTypeValue = Convert.ToInt32(strArry2[0].Trim());
+                content.A瀹樻柟鍚嶅瓧 = strArry2[1].Trim();
+                content.A澶囨敞鍚嶅瓧 = strArry2[2].Trim();
+                content.BeloneTypeValue= Convert.ToInt32(strArry2[3].Trim());
+                content.A鎵�灞炲悕瀛� = strArry2[4].Trim();
+                content.A绫诲瀷鍚嶅瓧 = strArry2[5].Trim();
+                this.dicDeviceModelIdEnum[strArry1[0].Trim()] = content;
+            }
 
             //鉁┾湬鉁┾湬鉁╅渶瑕佷氦鎹㈢殑妯″潡ID鉁┾湬鉁┾湬鉁�
             this.dicDeviceModelIdChanged = new Dictionary<string, string>();
@@ -3196,8 +3157,6 @@
             this.dicDeviceModelIdChanged["MULTI-MOTI--EA04"] = "MSPIR01/M-ZB.10";//绾㈠浼犳劅鍣�
             this.dicDeviceModelIdChanged["MULTI-WATE--EA02"] = "MSW01/M-ZB.10";//姘存蹈浼犳劅鍣�
             this.dicDeviceModelIdChanged["MULTI-BURO--EA06"] = "MBU01/M-ZB.10";//绱ф�ユ寜閿�
-
-
 
             //鉁┾湬鉁┾湬鉁╅渶瑕佸叡鏈夌殑鍥剧墖瀵硅薄鉁┾湬鉁┾湬鉁�
             //涓よ�呴兘鏄疍eviceConcreteType
@@ -3210,19 +3169,64 @@
             this.dicPictrueShard["Relay_FangyueFreshAirModul"] = "Relay_ThreeLoad";//鏂规偊鏂伴灏忔ā鍧楀浘鐗� 娌跨敤 3璺户鐢靛櫒鐨勫浘鏍�
         }
 
-        #endregion
+        /// <summary>
+        /// 鑾峰彇璁惧鍚嶅瓧鏂囦欢鐨勫唴瀹�
+        /// </summary>
+        /// <returns></returns>
+        private List<string> GetDeviceNameFileContent()
+        {
+            System.IO.StreamReader streamReader = null;
+            var listText = new List<string>();
+            try
+            {
+#if iOS
+                string textFile = Foundation.NSBundle.MainBundle.PathForResource("DeviceName.ini", null);
+                streamReader = new System.IO.StreamReader(textFile, Encoding.UTF8);
+                string text;
+                while ((text = streamReader.ReadLine()) != null)
+                {
+                    listText.Add(text.Trim());
+                }
+                return listText;
+#endif
+#if Android
+                var stream = Application.Activity.Assets.Open("DeviceName.ini");
+                streamReader = new System.IO.StreamReader(stream, Encoding.UTF8);
+                string text;
+                while ((text = streamReader.ReadLine()) != null)
+                {
+                    listText.Add(text.Trim());
+                }
+                stream.Close();
+                return listText;
+#endif
+            }
+            catch
+            {
+                return listText;
+            }
+            finally
+            {
+                try
+                {
+                    streamReader?.Close();
+                }
+                catch
+                {
+                }
+            }
+        }
+
+#endregion
     }
 
-    #region 鈻� 鑷畾涔夎澶囩被鍨媉________________________
+#region 鈻� 鑷畾涔夎澶囩被鍨媉________________________
 
     /// <summary>
-    /// <para>浠呴檺搴曞眰浣跨敤锛氳澶囩殑鍏蜂綋銆愯澶囩被鍨嬨��,鑷畾涔変笌妯″潡id鍏宠仈鐨勬灇涓�(鍊间负LocalDevice閲岄潰dicDeviceModelIdEnum鎵�鎸囧畾鐨凞eviceConcreteType鍊�)</para>
-    /// <para>鍙橀噺鍚嶅彲浠ヤ綔涓恒�愯澶囩被鍨嬨�戝浘鐗�,杩欎釜鍊兼槸鐬庡啓鐨�,娌′粈涔堢壒娈婃剰涔�</para>
+    /// <para>璁惧鐨勫叿浣撱�愯澶囩被鍨嬨��,鍙橀噺鍚嶅彲浠ヤ綔涓恒�愯澶囩被鍨嬨�戝浘鐗�,杩欎釜鍊兼槸鐬庡啓鐨�,娌′粈涔堢壒娈婃剰涔�</para>
     /// </summary>
     public enum DeviceConcreteType
     {
-        //瀹氫箟瑙勫垯锛氥�愯澶囩被鍨嬨�戝浘鐗囧悕瀛�=LocalDevice閲岄潰dicDeviceModelIdEnum鎵�鎸囧畾鐨凞eviceConcreteType鍊�
-
         /// <summary>
         /// 鏈煡璁惧
         /// </summary>
@@ -3501,8 +3505,7 @@
     }
 
     /// <summary>
-    /// <para>浠呴檺搴曞眰浣跨敤锛氳澶囨墍灞炵殑銆愯澶囩绫汇��,鑷畾涔変笌妯″潡id鍏宠仈鐨勬灇涓�(鍊间负LocalDevice閲岄潰dicDeviceModelIdEnum鎵�鎸囧畾鐨凞eviceBeloneType鍊�)</para>
-    /// <para>杩欎釜鍊兼槸鐬庡啓鐨�,娌′粈涔堢壒娈婃剰涔�</para>
+    /// <para>璁惧鎵�灞炴灇涓�,杩欎釜鍊兼槸鐬庡啓鐨�,娌′粈涔堢壒娈婃剰涔�</para>
     /// </summary>
     public enum DeviceBeloneType
     {
@@ -3592,5 +3595,5 @@
         A骞叉帴鐐� = 16,
     }
 
-    #endregion
+#endregion
 }
diff --git a/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.TBL.dll b/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.TBL.dll
index 4c39958..c633993 100755
--- a/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.TBL.dll
+++ b/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.TBL.dll
Binary files differ
diff --git a/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.dll b/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.dll
index 4fb86e4..c063a30 100755
--- a/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.dll
+++ b/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.dll
Binary files differ
diff --git a/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.xml b/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.xml
index 5aa77c7..a0d1634 100755
--- a/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.xml
+++ b/ZigbeeApp/Shared/DLL/IOS/Shared.IOS.xml
@@ -4903,28 +4903,173 @@
             
             </summary>
         </member>
+        <member name="F:Shared.MyEchartsViewOn.optionJsonString">
+            <summary>
+             option鐨勯厤缃甹son
+            </summary>
+        </member>
+        <member name="F:Shared.MyEchartsViewOn.uIWebView">
+            <summary>
+            WKWebView鎺т欢
+            </summary>
+        </member>
+        <member name="M:Shared.MyEchartsViewOn.ShowWithOptionJsonString(System.String)">
+            <summary>
+            鍔犺浇Option閰嶇疆jsonString
+            </summary>
+            <param name="jsonString"></param>
+        </member>
         <member name="M:Shared.MyEchartsViewOn.LoadFileUrl">
             <summary>
             鍔犺浇鏈湴HTML
             </summary>
         </member>
-        <member name="P:Shared.MyEchartsViewOn.JsonData.Title">
+        <member name="T:Shared.WaveSeekBarOn">
             <summary>
-            鏍囬鍐呭
+            HDLOnWaveSeekbar 鎺т欢
+            榛樿鍦嗚20 鎷栧姩鎸夐挳榛樿楂樺害10 鐧借壊
             </summary>
-            <value>The title.</value>
         </member>
-        <member name="P:Shared.MyEchartsViewOn.JsonData.XArray">
+        <member name="P:Shared.WaveSeekBarOn.mHDLOnWaveSeekbar">
             <summary>
-            X杞村潗鏍囩偣
+             褰撳墠瑙嗗浘
             </summary>
-            <value>The XA rray.</value>
+            <value>The HDLOnWaveSeekbar.</value>
         </member>
-        <member name="P:Shared.MyEchartsViewOn.JsonData.YArray">
+        <member name="M:Shared.WaveSeekBarOn.#ctor">
             <summary>
-            Y杞村潗鏍囩偣
+            鏋勯�犲嚱鏁�
             </summary>
-            <value>The YA rray.</value>
+        </member>
+        <member name="M:Shared.WaveSeekBarOn.RefreshFrame">
+            <summary>
+            鍒锋柊甯冨眬
+            </summary>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.Width">
+            <summary>
+            鎺т欢瀹藉害
+            </summary>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.Height">
+            <summary>
+            鎺т欢鐨勯珮搴�
+            </summary>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.X">
+            <summary>
+            鎺т欢鐨刋鍧愭爣
+            </summary>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.Y">
+            <summary>
+            鎺т欢鐨刋鍧愭爣
+            </summary>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.ProgressBarUnitSring">
+            <summary>
+            杩涘害鍊兼樉绀哄崟浣�
+            </summary>
+            <value>鍗曚綅瀛楃</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.MaxValue">
+            <summary>
+            杩涘害鍊兼渶澶у��
+            </summary>
+            <value>鏈�澶у��</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.MinValue">
+            <summary>
+            杩涘害鍊兼渶灏忓��
+            </summary>
+            <value>鏈�灏忓��</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.Progress">
+            <summary>
+            褰撳墠杩涘害鍊�
+            </summary>
+            <value>杩涘害鍊�</value>
+        </member>
+        <member name="M:Shared.WaveSeekBarOn.SetProgressBarColors(System.UInt32,System.UInt32)">
+            <summary>
+            璁剧疆杩涘害鏉� 娓愬彉棰滆壊鐨勫紑濮嬮鑹插拰缁撴潫棰滆壊
+            </summary>
+            <value>寮�濮嬮鑹层�佺粨鏉熼鑹�</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.CornerRadius">
+            <summary>
+            鍦嗚
+            </summary>
+            <value>鍦嗚</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.ProgressTextColor">
+            <summary>
+            褰撳墠杩涘害鍊兼樉绀虹殑鏂囧瓧棰滆壊
+            </summary>
+            <value>鏂囧瓧棰滆壊</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.ProgressTextSize">
+            <summary>
+            褰撳墠杩涘害鍊兼樉绀虹殑鏂囧瓧澶у皬
+            </summary>
+            <value>鏂囧瓧澶у皬</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.IsClickable">
+            <summary>
+            鏄惁鍙互婊戝姩
+            </summary>
+            <value>鏄惁鍙互婊戝姩</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.IsProgressTextShow">
+            <summary>
+            鏄惁鏄剧ず杩涘害鏂囧瓧
+            </summary>
+            <value>鏄惁鏄剧ず杩涘害鏂囧瓧</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.NowProgressY">
+            <summary>
+            褰撳墠杩涘害鍊� Y鍧愭爣
+            </summary>
+            <value>Y鍧愭爣</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.IsOffline">
+            <summary>
+            鏄惁绂荤嚎 绂荤嚎鐨勮瘽绂佹婊戝姩骞剁粯鍒剁伆鑹茶儗鏅�
+            </summary>
+            <value>鏄惁绂荤嚎</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.OfflineProgressBarColor">
+            <summary>
+            绂荤嚎鏁堟灉鏃� 杩涘害鏉¢鑹� 鍗曚竴棰滆壊涓嶆笎鍙�
+            </summary>
+            <value>鍗曚竴杩涘害鏉¢鑹�</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.IsThumbBtnShow">
+            <summary>
+            鏄惁鏄剧ず鎷栧姩鎸夐挳 鐩寸嚎鍥惧舰
+            </summary>
+            <value>鏄惁绂荤嚎</value>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.ThumbBtnHeight">
+            <summary>
+            鎷栧姩鎸夐挳楂樺害
+            </summary>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.ThumbBtnColor">
+            <summary>
+            鎷栧姩鎸夐挳棰滆壊
+            </summary>
+        </member>
+        <member name="P:Shared.WaveSeekBarOn.WaveBackgroundColor">
+            <summary>
+            鐭╁舰鐨勮儗鏅鑹�
+            </summary>
+            <value>鑳屾櫙棰滆壊</value>
+        </member>
+        <member name="F:Shared.WaveSeekBarOn.OnProgressChangedEvent">
+            <summary>
+            EventHandler
+            </summary>
         </member>
         <member name="F:com.hdl.on.Volume.VolumeChange">
             <summary>
diff --git a/ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs b/ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs
index 9655afe..ca045b2 100755
--- a/ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs
+++ b/ZigbeeApp/Shared/Phone/Category/AddOrEditorSceneForm.cs
@@ -291,10 +291,10 @@
                 this.ShowAddTargetMenu();
             };
 
-            HdlThreadLogic.Current.RunThread(async () =>
+            HdlThreadLogic.Current.RunThread(() =>
             {
                 //浠庣綉鍏宠幏鍙栧満鏅殑鎵ц鐩爣
-                var result = await this.GetSceneTargetList();
+                var result = this.GetSceneTargetList();
                 if (result == true)
                 {
                     //娣诲姞銆愭墽琛岀洰鏍囪銆�
@@ -633,7 +633,7 @@
         /// 浠庣綉鍏宠幏鍙栧満鏅殑鎵ц鐩爣
         /// </summary>
         /// <returns></returns>
-        private async System.Threading.Tasks.Task<bool> GetSceneTargetList()
+        private bool GetSceneTargetList()
         {
             if (this.editorScene == null || this.listAdjustTarget != null)
             {
@@ -643,7 +643,7 @@
             //鎵撳紑杩涘害鏉�
             this.ShowProgressBar();
             //鑾峰彇鎵ц鐩爣鍒楄〃
-            var listData = await HdlSceneLogic.Current.GetAdjustTargetList(this.editorScene);
+            var listData = HdlSceneLogic.Current.GetAdjustTargetList(this.editorScene);
             if (listData == null)
             {
                 this.CloseProgressBar(ShowReLoadMode.YES);
@@ -789,10 +789,10 @@
         /// <summary>
         /// 淇濆瓨鏂板缓鐨勫満鏅�
         /// </summary>
-        private async void SaveSceneDataByNewMode()
+        private void SaveSceneDataByNewMode()
         {
             //娣诲姞鍦烘櫙
-            this.editorScene = await HdlSceneLogic.Current.AddNewSceneToGateway(this.cloneScene.Name, this.listAdjustTarget);
+            this.editorScene = HdlSceneLogic.Current.AddNewSceneToGateway(this.cloneScene.Name, this.listAdjustTarget);
             //鍏抽棴杩涘害鏉�
             this.CloseProgressBar();
 
@@ -880,7 +880,7 @@
                 if (this.editorScene.IconPathType != 0)
                 {
                     //鍒犻櫎鑷畾涔夊浘鐗�
-                    Shared.IO.FileUtils.DeleteFile(System.IO.Path.Combine(Config.Instance.FullPath, this.editorScene.IconPath));
+                    HdlFileLogic.Current.DeleteFile(System.IO.Path.Combine(Config.Instance.FullPath, this.editorScene.IconPath));
                     HdlAutoBackupLogic.DeleteFile(this.editorScene.IconPath);
                 }
                 if (this.cloneScene.IconPathType != 0)
diff --git a/ZigbeeApp/Shared/Phone/Category/AdjustTargetAddDeviceForm.cs b/ZigbeeApp/Shared/Phone/Category/AdjustTargetAddDeviceForm.cs
index 540e15e..b4ffa56 100755
--- a/ZigbeeApp/Shared/Phone/Category/AdjustTargetAddDeviceForm.cs
+++ b/ZigbeeApp/Shared/Phone/Category/AdjustTargetAddDeviceForm.cs
@@ -295,9 +295,9 @@
             //涓婁竴娆¢�夋嫨鐨勮彍鍗曞拰鏁版嵁
             DeviceRowInfo nowSelectDeviceInfo = null;
             MainPage.Controls.DeviceFunctionUnallocatedControl oldSelectContr = null;
-            foreach (int Textid in dicGroupDevice.Keys)
+            foreach (string strText in dicGroupDevice.Keys)
             {
-                var rowInfo = dicGroupDevice[Textid];
+                var rowInfo = dicGroupDevice[strText];
 
                 //璁惧绫诲瀷鐨勫鍣�
                 var devieFrame = new FrameLayout();
@@ -307,7 +307,7 @@
                 //鑿滃崟鍥剧墖鎺т欢
                 var deviceObjContr = new MainPage.Controls.DeviceFunctionUnallocatedControl();
                 devieFrame.AddChidren(deviceObjContr);
-                deviceObjContr.InitControl(Language.StringByID(Textid), rowInfo.IconPath, rowInfo.IconPathSelected, rowInfo.listDeviceKeys);
+                deviceObjContr.InitControl(strText, rowInfo.IconPath, rowInfo.IconPathSelected, rowInfo.listDeviceKeys);
                 deviceObjContr.ButtonClickEvent += (sender, e) =>
                 {
                     //閫夋嫨鐨勬槸鍚屼竴涓笢瑗跨殑璇�,涓嶅鐞�
@@ -556,7 +556,7 @@
         /// 鑾峰彇鍒嗙粍鍚庣殑璁惧
         /// </summary>
         /// <returns></returns>
-        private Dictionary<int, DeviceRowInfo> GetAllGroupDevice(Common.Room room)
+        private Dictionary<string, DeviceRowInfo> GetAllGroupDevice(Common.Room room)
         {
             //鍏ㄩ儴鐨勮澶�
             var listDeviceTemp = HdlRoomLogic.Current.GetRoomListDevice(room);
@@ -572,23 +572,23 @@
 
             //鏍规嵁璁惧鎵�灞炵被鍨嬫帓搴�
             listDevice = LocalDevice.Current.SortDeviceByBelongType(listDevice);
-            var dic = new Dictionary<int, DeviceRowInfo>();
+            var dic = new Dictionary<string, DeviceRowInfo>();
             foreach (var device in listDevice)
             {
                 var typeInfo = LocalDevice.Current.GetDeviceBelongEnumInfo(device);
                 //鎸夋墍灞濱D鍒嗙粍
-                if (dic.ContainsKey(typeInfo.BeloneTextId) == false)
+                if (dic.ContainsKey(typeInfo.BeloneText) == false)
                 {
-                    dic[typeInfo.BeloneTextId] = new DeviceRowInfo();
+                    dic[typeInfo.BeloneText] = new DeviceRowInfo();
                     string path1 = string.Empty;
                     string path2 = string.Empty;
                     //鑾峰彇鍥剧墖
                     LocalDevice.Current.GetDeviceFunctionTypeMenuIcon(typeInfo.ConcreteType, ref path1, ref path2);
-                    dic[typeInfo.BeloneTextId].IconPath = path1;
-                    dic[typeInfo.BeloneTextId].IconPathSelected = path2;
-                    dic[typeInfo.BeloneTextId].TextId = typeInfo.BeloneTextId;
+                    dic[typeInfo.BeloneText].IconPath = path1;
+                    dic[typeInfo.BeloneText].IconPathSelected = path2;
+                    dic[typeInfo.BeloneText].TextId = typeInfo.BeloneText;
                 }
-                dic[typeInfo.BeloneTextId].listDeviceKeys.Add(LocalDevice.Current.GetDeviceMainKeys(device));
+                dic[typeInfo.BeloneText].listDeviceKeys.Add(LocalDevice.Current.GetDeviceMainKeys(device));
             }
             return dic;
         }
@@ -641,9 +641,9 @@
         private class DeviceRowInfo
         {
             /// <summary>
-            /// 鏂囨湰ID,鐩墠鐢ㄦ潵鍋氫富閿�
+            /// 鏂囨湰,鐩墠鐢ㄦ潵鍋氫富閿�
             /// </summary>
-            public int TextId = 0;
+            public string TextId = string.Empty;
             /// <summary>
             /// 鍥炬爣
             /// </summary>
diff --git a/ZigbeeApp/Shared/Phone/Category/CategoryMainForm.cs b/ZigbeeApp/Shared/Phone/Category/CategoryMainForm.cs
index 7451d5d..d30d6cd 100755
--- a/ZigbeeApp/Shared/Phone/Category/CategoryMainForm.cs
+++ b/ZigbeeApp/Shared/Phone/Category/CategoryMainForm.cs
@@ -66,6 +66,10 @@
         {
             //鍏堟竻闄ゅ惂
             this.RemoveAll();
+
+            //鍒濆鍖栭粯璁ゆゼ灞侷D
+            this.InitDefultFloorId();
+
             //鍒濆鍖栧ご閮ㄦ帶浠�
             this.InitTopControl();
             //鍒濆鍖栦腑闂存帶浠�
@@ -395,9 +399,9 @@
             //涓婁竴娆¢�夋嫨鐨勮彍鍗�
             MainPage.Controls.DeviceFunctionUnallocatedControl oldSelectContr = null;
             DeviceRowInfo nowSelectDeviceInfo = null;
-            foreach (int Textid in dicGroupDevice.Keys)
+            foreach (string strText in dicGroupDevice.Keys)
             {
-                var rowInfo = dicGroupDevice[Textid];
+                var rowInfo = dicGroupDevice[strText];
 
                 //璁惧绫诲瀷鐨勫鍣�
                 var devieFrame = new FrameLayout();
@@ -407,11 +411,11 @@
                 //鑿滃崟鍥剧墖鎺т欢
                 var deviceObjContr = new MainPage.Controls.DeviceFunctionUnallocatedControl();
                 devieFrame.AddChidren(deviceObjContr);
-                deviceObjContr.InitControl(Language.StringByID(Textid), rowInfo.IconPath, rowInfo.IconPathSelected, rowInfo.listDeviceKeys);
+                deviceObjContr.InitControl(strText, rowInfo.IconPath, rowInfo.IconPathSelected, rowInfo.listDeviceKeys);
                 deviceObjContr.ButtonClickEvent += (sender, e) =>
                 {
                     //閫夋嫨鐨勬槸鍚屼竴涓笢瑗跨殑璇�,涓嶅鐞�
-                    if (nowSelectDeviceInfo.TextId != rowInfo.TextId)
+                    if (nowSelectDeviceInfo.Text != rowInfo.Text)
                     {
                         //涓婁竴娆$殑鑿滃崟鍙栨秷,鏈鑿滃崟閫夋嫨
                         oldSelectContr.SetSelectStatu(false);
@@ -632,7 +636,7 @@
                     HdlThreadLogic.Current.RunThread(() =>
                     {
                         //浠庣綉鍏冲埛鏂板満鏅垪琛�
-                        bool result = HdlSceneLogic.Current.RefreshSceneUIList();
+                        bool result = HdlSceneLogic.Current.RefreshSceneUIList(false);
                         HdlThreadLogic.Current.RunMain(() =>
                         {
                             listview1.EndHeaderRefreshing();
@@ -783,13 +787,13 @@
                 while (remainTime > 0 && this.Parent != null)
                 {
                     System.Threading.Thread.Sleep(1000);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         sceneContr.SetTimeText(this.GetTimeString(remainTime, hourText, minuText, secondText));
-                    });
+                    }, ShowErrorMode.NO);
                     remainTime--;
                 }
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     if (listview.Parent != null)
                     {
@@ -797,7 +801,7 @@
                         //寮�鍚疞oading鐗规晥
                         sceneContr.StartLoadingApreal();
                     }
-                });
+                }, ShowErrorMode.NO);
             });
         }
 
@@ -828,6 +832,11 @@
                         {
                             //浼犳劅鍣ㄤ笉闇�瑕佸睘鎬т笂鎶�(浣嗘槸閭d釜鐞冨瀷浼犳劅鍣ㄥ眳鐒朵細灞炴�т笂鎶�)
                             this.dicDeviceRowControl[mainKeys].RefreshControlInfo(locadevice);
+                        }
+                        else if (report.DeviceStatusReport.CluterID == 1)
+                        {
+                            //杩欎釜鏄數閲忔帹閫�
+                            this.dicDeviceRowControl[mainKeys].RefreshBatteryStatu();
                         }
                     }
                 }, ShowErrorMode.NO);
@@ -885,7 +894,7 @@
         /// 鑾峰彇鍒嗙粍鍚庣殑璁惧
         /// </summary>
         /// <returns></returns>
-        private Dictionary<int, DeviceRowInfo> GetAllGroupDevice(Common.Room room)
+        private Dictionary<string, DeviceRowInfo> GetAllGroupDevice(Common.Room room)
         {
             //鍏ㄩ儴鐨勮澶�
             var listDeviceTemp = HdlRoomLogic.Current.GetRoomListDevice(room);
@@ -902,23 +911,23 @@
 
             //鏍规嵁璁惧鎵�灞炵被鍨嬫帓搴�
             listDevice = LocalDevice.Current.SortDeviceByBelongType(listDevice);
-            var dic = new Dictionary<int, DeviceRowInfo>();
+            var dic = new Dictionary<string, DeviceRowInfo>();
             foreach (var device in listDevice)
             {
                 var typeInfo = LocalDevice.Current.GetDeviceBelongEnumInfo(device);
                 //鎸夋墍灞濱D鍒嗙粍
-                if (dic.ContainsKey(typeInfo.BeloneTextId) == false)
+                if (dic.ContainsKey(typeInfo.BeloneText) == false)
                 {
-                    dic[typeInfo.BeloneTextId] = new DeviceRowInfo();
+                    dic[typeInfo.BeloneText] = new DeviceRowInfo();
                     string path1 = string.Empty;
                     string path2 = string.Empty;
                     //鑾峰彇鍥剧墖
                     LocalDevice.Current.GetDeviceFunctionTypeMenuIcon(typeInfo.ConcreteType, ref path1, ref path2);
-                    dic[typeInfo.BeloneTextId].IconPath = path1;
-                    dic[typeInfo.BeloneTextId].IconPathSelected = path2;
-                    dic[typeInfo.BeloneTextId].TextId = typeInfo.BeloneTextId;
+                    dic[typeInfo.BeloneText].IconPath = path1;
+                    dic[typeInfo.BeloneText].IconPathSelected = path2;
+                    dic[typeInfo.BeloneText].Text = typeInfo.BeloneText;
                 }
-                dic[typeInfo.BeloneTextId].listDeviceKeys.Add(LocalDevice.Current.GetDeviceMainKeys(device));
+                dic[typeInfo.BeloneText].listDeviceKeys.Add(LocalDevice.Current.GetDeviceMainKeys(device));
             }
             return dic;
         }
@@ -974,6 +983,23 @@
             return timeStr;
         }
 
+        /// <summary>
+        /// 鍒濆鍖栭粯璁ゆゼ灞侷D
+        /// </summary>
+        private void InitDefultFloorId()
+        {
+            if (Config.Instance.Home.CurrentFloorId != string.Empty)
+            {
+                return;
+            }
+            var dicFloor = HdlRoomLogic.Current.GetFloorSortList();
+            foreach (var floorId in dicFloor.Keys)
+            {
+                Config.Instance.Home.CurrentFloorId = floorId;
+                break;
+            }
+        }
+
         #endregion
 
         #region 鈻� 缁撴瀯浣揰____________________________
@@ -984,9 +1010,9 @@
         private class DeviceRowInfo
         {
             /// <summary>
-            /// 鏂囨湰ID,鐩墠鐢ㄦ潵鍋氫富閿�
+            /// 鏂囨湰,鐩墠鐢ㄦ潵鍋氫富閿�
             /// </summary>
-            public int TextId = 0;
+            public string Text = string.Empty;
             /// <summary>
             /// 鍥炬爣
             /// </summary>
diff --git a/ZigbeeApp/Shared/Phone/Category/Controls/DeviceRow/Base/DeviceRowCommon.cs b/ZigbeeApp/Shared/Phone/Category/Controls/DeviceRow/Base/DeviceRowCommon.cs
index 38c1f5b..69f42ef 100755
--- a/ZigbeeApp/Shared/Phone/Category/Controls/DeviceRow/Base/DeviceRowCommon.cs
+++ b/ZigbeeApp/Shared/Phone/Category/Controls/DeviceRow/Base/DeviceRowCommon.cs
@@ -46,6 +46,10 @@
         /// </summary>
         private MostRightIconControl btnSwitch = null;
         /// <summary>
+        /// 鐢垫睜鎺т欢
+        /// </summary>
+        private IconViewControl btnBattery = null;
+        /// <summary>
         /// 鏄惁鑾峰彇缃戝叧鍙嶉鐨勭粨鏋�  0:娌℃湁鑾峰彇寰楀埌  1:宸茬粡鑾峰彇寰楀埌
         /// </summary>
         private int ResponeResult = 0;
@@ -146,6 +150,24 @@
             this.btnSwitch = new MostRightIconControl(69, 69);
             btnSwitch.UnSelectedImagePath = "Item/Switch.png";
             btnSwitch.SelectedImagePath = "Item/SwitchSelected.png";
+
+            //鐢垫睜鎺т欢
+            if (this.device.Type == DeviceType.IASZone)
+            {
+                this.btnBattery = new IconViewControl(69);
+                btnBattery.X = this.Width - Application.GetRealWidth(69 + 29);
+                btnBattery.UnSelectedImagePath = "Item/Battery.png";
+                btnBattery.Gravity = Gravity.CenterVertical;
+                this.frameTable.AddChidren(btnBattery, ChidrenBindMode.BindEvent);
+                if (chidrenYaxis != 0)
+                {
+                    btnBattery.Y += chidrenYaxis;
+                }
+                if (this.device.IsBatteryDown == false)
+                {
+                    btnBattery.Visible = false;
+                }
+            }
 
             //鍒嗕韩鐨勬埧闂�,鍒欎笉鑳界紪杈戝拰鍒犻櫎
             if (this.nowSelectRoom.IsSharedRoom == false)
@@ -423,6 +445,34 @@
 
         #endregion
 
+        #region 鈻� 鏄剧ず浣庣數閲廮________________________
+
+        /// <summary>
+        /// 鍒锋柊鐢垫睜鐢甸噺鐘舵��
+        /// </summary>
+        public void RefreshBatteryStatu()
+        {
+            if (this.btnBattery == null) { return; }
+            if (this.device.IsBatteryDown == true)
+            {
+                //鐢甸噺浣�,鏄剧ず鍥炬爣
+                if (this.btnBattery.Visible == false)
+                {
+                    this.btnBattery.Visible = true;
+                }
+            }
+            else
+            {
+                //鐢甸噺瓒冲,闅愯棌鍥炬爣
+                if (this.btnBattery.Visible == true)
+                {
+                    this.btnBattery.Visible = false;
+                }
+            }
+        }
+
+        #endregion
+
         #region 鈻� 涓�鑸柟娉昣__________________________
 
         /// <summary>
diff --git a/ZigbeeApp/Shared/Phone/Category/SelectHouseForm.cs b/ZigbeeApp/Shared/Phone/Category/SelectHouseForm.cs
index 5d2d1bc..3e0cb2a 100755
--- a/ZigbeeApp/Shared/Phone/Category/SelectHouseForm.cs
+++ b/ZigbeeApp/Shared/Phone/Category/SelectHouseForm.cs
@@ -70,8 +70,10 @@
             };
             changeHomeFL.AddChidren(scrolView);
 
-            var houseCount = Config.Instance.HomeFilePathList.Count;
-            if (Config.Instance.HomeFilePathList.Count > 0)
+            //鑾峰彇鏈湴鍏ㄩ儴鐨勪綇瀹呭璞�
+            var listHouse = UserCenter.HdlResidenceLogic.Current.GetLocalResidenceList();
+            var houseCount = listHouse.Count;
+            if (houseCount > 0)
             {
                 if (houseCount > 5)
                 {
@@ -87,15 +89,9 @@
                     changeHomeFL.Height = this.GetPictrueRealSize(150 * (houseCount + 1));
                     scrolView.Height = this.GetPictrueRealSize(150 * houseCount);
                 }
-
-                foreach (var housePath in Config.Instance.HomeFilePathList)
-                {
-                    var home = UserCenter.HdlResidenceLogic.Current.GetHouseByFilePath(housePath);
-                    if (home == null)
-                    {
-                        continue;
-                    }
-                    AddFloor(scrolView, home);
+                foreach (var house in listHouse)
+                {
+                    AddFloor(scrolView, house);
                 }
             }
         }
diff --git a/ZigbeeApp/Shared/Phone/CommonForm/CommonFormBase.cs b/ZigbeeApp/Shared/Phone/CommonForm/CommonFormBase.cs
index 346da1c..3089a89 100755
--- a/ZigbeeApp/Shared/Phone/CommonForm/CommonFormBase.cs
+++ b/ZigbeeApp/Shared/Phone/CommonForm/CommonFormBase.cs
@@ -235,7 +235,7 @@
             {
                 return;
             }
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 var alert = new ShowMsgControl(msgType, msg, buttonText);
                 if (action != null)
diff --git a/ZigbeeApp/Shared/Phone/CommonForm/EditorCommonForm.cs b/ZigbeeApp/Shared/Phone/CommonForm/EditorCommonForm.cs
index b384af6..0cbedac 100755
--- a/ZigbeeApp/Shared/Phone/CommonForm/EditorCommonForm.cs
+++ b/ZigbeeApp/Shared/Phone/CommonForm/EditorCommonForm.cs
@@ -272,7 +272,7 @@
         /// </summary>
         public override void ShowReLoadView()
         {
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 if (bodyFrameLayout == null || bodyFrameLayout.Parent == null)
                 {
diff --git a/ZigbeeApp/Shared/Phone/Device/CommonForm/SceneCategoryView.cs b/ZigbeeApp/Shared/Phone/Device/CommonForm/SceneCategoryView.cs
index 6c053c7..aab6fc4 100755
--- a/ZigbeeApp/Shared/Phone/Device/CommonForm/SceneCategoryView.cs
+++ b/ZigbeeApp/Shared/Phone/Device/CommonForm/SceneCategoryView.cs
@@ -296,13 +296,13 @@
                 while (myRemainTime > 0 && this.Parent != null)
                 {
                     System.Threading.Thread.Sleep(1000);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         SetTimeText(CommonFormResouce.GetTimeString(scene.RemainTime));
-                    });
+                    }, ShowErrorMode.NO);
                     myRemainTime--;
                 }
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     if (this.Parent != null)
                     {
@@ -311,7 +311,7 @@
                         this.StartLoadingApreal();
                         sceneContr.CanClick = true;
                     }
-                });
+                }, ShowErrorMode.NO);
             })
             { IsBackground = true }.Start();
         }
diff --git a/ZigbeeApp/Shared/Phone/Device/CommonForm/SelectTime.cs b/ZigbeeApp/Shared/Phone/Device/CommonForm/SelectTime.cs
index 5530536..3a601d5 100755
--- a/ZigbeeApp/Shared/Phone/Device/CommonForm/SelectTime.cs
+++ b/ZigbeeApp/Shared/Phone/Device/CommonForm/SelectTime.cs
@@ -102,7 +102,7 @@
             {
                 X = Application.GetRealWidth(80),
                 Y=Application.GetRealHeight(1200),
-                Width=Application.GetRealWidth(400),
+                Width=Application.GetRealWidth(800),
                 Height=Application.GetRealHeight(80),
                 TextColor = ZigbeeColor.Current.GXCTextGrayColor4,
                 TextID = R.MyInternationalizationString.NotOpen,
diff --git a/ZigbeeApp/Shared/Phone/Device/Logic/CurrentDeviceState.cs b/ZigbeeApp/Shared/Phone/Device/Logic/CurrentDeviceState.cs
index cb02f21..426b615 100755
--- a/ZigbeeApp/Shared/Phone/Device/Logic/CurrentDeviceState.cs
+++ b/ZigbeeApp/Shared/Phone/Device/Logic/CurrentDeviceState.cs
@@ -543,7 +543,7 @@
                         Send.dictionary(deviceConditionsInfo, "AttriButeData2", "0");
 
                         completeView.Show(l).AddChidren(openView.Show());
-                        openView.titleBtn.Text = Language.StringByID(MyInternationalizationString.OnOffSwitch) + common.DeviceEpoint.ToString();
+                        openView.titleBtn.Text = LocalDevice.Current.GetDeviceEpointName(common);
                         openView.lineBtn.BackgroundColor = ZigbeeColor.Current.LogicBackgroundColor;
                         openView.clickviewBtn.MouseUpEventHandler += (sender, e) =>
                         {
diff --git a/ZigbeeApp/Shared/Phone/Device/Logic/Illumination.cs b/ZigbeeApp/Shared/Phone/Device/Logic/Illumination.cs
index 77a0925..3990419 100755
--- a/ZigbeeApp/Shared/Phone/Device/Logic/Illumination.cs
+++ b/ZigbeeApp/Shared/Phone/Device/Logic/Illumination.cs
@@ -22,7 +22,7 @@
             {
                 RemoveFromParent();
             };
-            FrameLayout middle = new FrameLayout
+            FrameLayout middle= new FrameLayout
             {
                 Y = view.topRowLayout.Bottom,
                 Height = Application.GetRealHeight(Method.H - 184),
@@ -47,8 +47,9 @@
                 //TextID = MyInternationalizationString.Save,
                 TextColor = ZigbeeColor.Current.LogicBtnCancelColor,
                 TextSize = 12,
+                TextAlignment=TextAlignment.CenterLeft,
             };
-            middle.AddChidren(illuminationBtn);
+            blankFraLayout.AddChidren(illuminationBtn);
             //-鍥炬爣鎺т欢
             Button lessBtn = new Button
             {
@@ -58,7 +59,7 @@
                 Width = Application.GetMinRealAverage(104),
                 UnSelectedImagePath = "ZigeeLogic/lesLuminositys.png",
             };
-            middle.AddChidren(lessBtn);
+            blankFraLayout.AddChidren(lessBtn);
             //+鍥炬爣鎺т欢
             Button addBtn = new Button
             {
@@ -68,13 +69,13 @@
                 Width = Application.GetMinRealAverage(104),
                 UnSelectedImagePath = "ZigeeLogic/addLuminosity.png",
             };
-            middle.AddChidren(addBtn);
+            blankFraLayout.AddChidren(addBtn);
             //杩涘害鏉℃帶浠�
             var horizontalSeekBarVol = new DiyImageSeekBar
             {
                 Y = Application.GetRealHeight(173),//杩涘害鏉$埗鎺т欢Y鍧愭爣
-                X = Application.GetRealWidth(104),//杩涘害鏉鍧愭爣
-                Width = Application.GetRealWidth(873),//杩涘害鏉$殑闀垮害
+                X = Application.GetRealWidth(104-20),//杩涘害鏉鍧愭爣
+                Width = Application.GetRealWidth(873+40),//杩涘害鏉$殑闀垮害
                 Height = Application.GetRealHeight(56),//杩涘害鏉$埗鎺т欢楂樺害
                 IsProgressTextShow = false,//鏄剧ず鐧惧垎姣�
                 IsClickable = true,//杩涘害鏉℃槸鍚︽粦鍔�
@@ -89,7 +90,7 @@
                 MinValue = 0,
                 Progress = progresValue,
             };
-            middle.AddChidren(horizontalSeekBarVol);
+            blankFraLayout.AddChidren(horizontalSeekBarVol);
             lessBtn.MouseUpEventHandler += (sender, e) =>
             {
                 horizontalSeekBarVol.Progress = horizontalSeekBarVol.Progress - 1;
@@ -109,32 +110,57 @@
 
             Button text1Btn = new Button()
             {
-                X = Application.GetRealWidth(81),
+                X = Application.GetRealWidth(95),
                 Y = Application.GetRealHeight(426 - 184),
-                Height = Application.GetRealHeight(100),
-                Width = Application.GetRealWidth(63+15),
-                Text = Language.StringByID(MyInternationalizationString.dark).Replace("{\\r\\n}", "\r\n"),
+                Height = Application.GetRealHeight(50),
+                Width = Application.GetRealWidth(100),
+                Text = Language.StringByID(MyInternationalizationString.dark),
                 TextColor = ZigbeeColor.Current.LogicBtnNotSelectedColor,
                 TextSize = 12,
-                TextAlignment = TextAlignment.Center,
-                IsMoreLines = true,
+                TextAlignment = TextAlignment.CenterLeft,
             };
-            middle.AddChidren(text1Btn);
+            blankFraLayout.AddChidren(text1Btn);
+
+            Button text0Btn = new Button()
+            {
+                X = Application.GetRealWidth(81),
+                Y = text1Btn.Bottom,
+                Height = Application.GetRealHeight(50),
+                Width = Application.GetRealWidth(100),
+                Text = "0lux",
+                TextColor = ZigbeeColor.Current.LogicBtnNotSelectedColor,
+                TextSize = 12,
+                TextAlignment = TextAlignment.CenterLeft,
+            };
+            blankFraLayout.AddChidren(text0Btn);
 
             Button text2Btn = new Button()
             {
-                X = Application.GetRealWidth(913-20),
+                X = Application.GetRealWidth(950),
                 Y = Application.GetRealHeight(426 - 184),
-                Height = Application.GetRealHeight(100),
-                Width = Application.GetRealWidth(109+20),
-                Text = Language.StringByID(MyInternationalizationString.bright).Replace("{\\r\\n}", "\r\n"),
+                Height = Application.GetRealHeight(50),
+                Width = Application.GetRealWidth(100),
+                Text = Language.StringByID(MyInternationalizationString.bright),
                 TextColor = ZigbeeColor.Current.LogicBtnNotSelectedColor,
                 TextSize = 12,
-                TextAlignment = TextAlignment.Center,
-                IsMoreLines = true,
+                TextAlignment = TextAlignment.CenterLeft,
 
             };
-            middle.AddChidren(text2Btn);
+            blankFraLayout.AddChidren(text2Btn);
+
+            Button text100Btn = new Button()
+            {
+                X = Application.GetRealWidth(913),
+                Y = text2Btn.Bottom,
+                Height = Application.GetRealHeight(50),
+                Width = Application.GetRealWidth(109+17),
+                Text = "100lux",
+                TextColor = ZigbeeColor.Current.LogicBtnNotSelectedColor,
+                TextSize = 12,
+                TextAlignment = TextAlignment.CenterLeft,
+            };
+            blankFraLayout.AddChidren(text100Btn);
+         
             //鎻愮ず鍥炬爣
             Button tipIconBtn = new Button
             {
@@ -144,7 +170,7 @@
                 Width = Application.GetMinRealAverage(58),
                 UnSelectedImagePath = "ZigeeLogic/tipIcon.png",
             };
-            middle.AddChidren(tipIconBtn);
+            blankFraLayout.AddChidren(tipIconBtn);
 
             //鎻愮ず鏂囧瓧
             Button tipTextBtn = new Button()
@@ -160,7 +186,7 @@
                 IsMoreLines = true,
 
             };
-            middle.AddChidren(tipTextBtn);
+            blankFraLayout.AddChidren(tipTextBtn);
 
             //淇濆瓨鎺т欢
             LogicView.SaveView saveView = new LogicView.SaveView();
diff --git a/ZigbeeApp/Shared/Phone/Device/Logic/Send.cs b/ZigbeeApp/Shared/Phone/Device/Logic/Send.cs
index 26c0e85..7502d06 100755
--- a/ZigbeeApp/Shared/Phone/Device/Logic/Send.cs
+++ b/ZigbeeApp/Shared/Phone/Device/Logic/Send.cs
@@ -1238,35 +1238,43 @@
         /// <returns></returns>
         public static async System.Threading.Tasks.Task<string> HttpWebRequest(string getUrl, string str, string method, int second = 3, bool _bool = false)
         {
-            HttpWebRequest request = WebRequest.Create(getUrl) as HttpWebRequest; //鍒涘缓璇锋眰
-            request.Method = method; //璇锋眰鏂瑰紡涓篜OST/GET
-            request.ContentType = "application/json"; 
-            request.Timeout = second * 1000;//瓒呮椂鏃堕棿
-            if (_bool) {
-                //鐢ㄤ簬楂樿儨鍙瀵硅鎺ュ彛
-                request.Headers.Add("Authorization", Config.Instance.Token);
+            try
+            {
+                HttpWebRequest request = WebRequest.Create(getUrl) as HttpWebRequest; //鍒涘缓璇锋眰
+                request.Method = method; //璇锋眰鏂瑰紡涓篜OST/GET
+                request.ContentType = "application/json";
+                request.Timeout = second * 1000;//瓒呮椂鏃堕棿
+                if (_bool)
+                {
+                    //鐢ㄤ簬楂樿儨鍙瀵硅鎺ュ彛
+                    request.Headers.Add("Authorization", Config.Instance.Token);
+                }
+                if (method == "POST")
+                {
+                    byte[] jsonbyte = System.Text.Encoding.UTF8.GetBytes(str);
+                    request.ContentLength = jsonbyte.Length;
+                    Stream postStream = request.GetRequestStream();
+                    postStream.Write(jsonbyte, 0, jsonbyte.Length);
+                    postStream.Close();
+                }
+                //鍙戦�佽姹傚苟鑾峰彇鐩稿簲鍥炲簲鏁版嵁       
+                HttpWebResponse res;
+                try
+                {
+                    res = (HttpWebResponse)request.GetResponse();
+                }
+                catch (WebException ex)
+                {
+                    res = (HttpWebResponse)ex.Response;
+                }
+                StreamReader sr = new StreamReader(res.GetResponseStream(), System.Text.Encoding.UTF8);
+                string content = sr.ReadToEnd(); //鑾峰緱鍝嶅簲瀛楃涓�
+                return content;
             }
-            if (method == "POST")
-            {
-                byte[] jsonbyte = System.Text.Encoding.UTF8.GetBytes(str);
-                request.ContentLength = jsonbyte.Length;
-                Stream postStream = request.GetRequestStream();
-                postStream.Write(jsonbyte, 0, jsonbyte.Length);
-                postStream.Close();
+            catch
+            {
+                return null;
             }
-            //鍙戦�佽姹傚苟鑾峰彇鐩稿簲鍥炲簲鏁版嵁       
-            HttpWebResponse res;
-            try
-            {
-                res = (HttpWebResponse)request.GetResponse();
-            }
-            catch (WebException ex)
-            {
-                res = (HttpWebResponse)ex.Response;
-            }
-            StreamReader sr = new StreamReader(res.GetResponseStream(), System.Text.Encoding.UTF8);
-            string content = sr.ReadToEnd(); //鑾峰緱鍝嶅簲瀛楃涓�
-            return content;
         }
         /// <summary>
         /// 璇锋眰鏈嶅姟鍣ㄧ殑鏂规硶
diff --git a/ZigbeeApp/Shared/Phone/Login/AccountLoginForm.cs b/ZigbeeApp/Shared/Phone/Login/AccountLoginForm.cs
index a70a48b..2189dc5 100755
--- a/ZigbeeApp/Shared/Phone/Login/AccountLoginForm.cs
+++ b/ZigbeeApp/Shared/Phone/Login/AccountLoginForm.cs
@@ -52,13 +52,13 @@
             frameMidBack.BackgroundColor = ZigbeeColor.Current.GXCGrayBackgroundColor;
             this.AddChidren(frameMidBack);
 
-            //HdlHome鐨勫浘鏍�
+            //Evoyo Home鐨勫浘鏍�
             var btnLogoIcon = new PicViewControl(184, 184);
             btnLogoIcon.Y = Application.GetRealHeight(230);
             btnLogoIcon.UnSelectedImagePath = "Account/Logo_White.png";
             btnLogoIcon.Gravity = Gravity.CenterHorizontal;
             this.AddChidren(btnLogoIcon);
-            //Hdl Home
+            //Evoyo Home
             var btnLogoName = new NormalViewControl(300, 69, true);
             btnLogoName.Y = btnLogoIcon.Bottom;
             btnLogoName.Gravity = Gravity.CenterHorizontal;
@@ -836,7 +836,7 @@
                     var re = isBindAuthAsync(authStr);
                     if (re)
                     {
-                        Application.RunOnMainThread(() =>
+                        HdlThreadLogic.Current.RunMain(() =>
                         {
                             //鐩存帴鐧诲綍
                             HomePage.Instance.ShowLoginLoadView();
diff --git a/ZigbeeApp/Shared/Phone/MainPage/Controls/DeviceCard/Base/DeviceCardCommon.cs b/ZigbeeApp/Shared/Phone/MainPage/Controls/DeviceCard/Base/DeviceCardCommon.cs
index 921cc7c..5c9d0eb 100755
--- a/ZigbeeApp/Shared/Phone/MainPage/Controls/DeviceCard/Base/DeviceCardCommon.cs
+++ b/ZigbeeApp/Shared/Phone/MainPage/Controls/DeviceCard/Base/DeviceCardCommon.cs
@@ -50,6 +50,10 @@
         /// </summary>
         private IconViewControl btnCollect = null;
         /// <summary>
+        /// 鐢垫睜鎺т欢
+        /// </summary>
+        private IconViewControl btnBattery = null;
+        /// <summary>
         /// 鏄惁鑾峰彇缃戝叧鍙嶉鐨勭粨鏋�  0:娌℃湁鑾峰彇寰楀埌  1:宸茬粡鑾峰彇寰楀埌
         /// </summary>
         private int ResponeResult = 0;
@@ -165,6 +169,21 @@
             btnSwitch.Y = HdlControlLogic.Current.GetPictrueRealSize(202);
             btnSwitch.UnSelectedImagePath = "Item/Switch1.png";
             btnSwitch.SelectedImagePath = "Item/SwitchSelected1.png";
+
+            //鐢垫睜鎺т欢
+            if (this.device.Type == DeviceType.IASZone)
+            {
+                this.btnBattery = new IconViewControl(69);
+                btnBattery.X = HdlControlLogic.Current.GetPictrueRealSize(348);
+                btnBattery.Y = HdlControlLogic.Current.GetPictrueRealSize(236);
+                btnBattery.UnSelectedImagePath = "Item/Battery.png";
+                btnBattery.SelectedImagePath = "Item/BatterySelected.png";
+                this.AddChidren(btnBattery, ChidrenBindMode.BindEvent);
+                if (this.device.IsBatteryDown == false)
+                {
+                    btnBattery.Visible = false;
+                }
+            }
 
             //鍒锋柊淇℃伅
             this.RefreshControlInfo(i_device);
@@ -384,6 +403,34 @@
 
         #endregion
 
+        #region 鈻� 鏄剧ず浣庣數閲廮________________________
+
+        /// <summary>
+        /// 鍒锋柊鐢垫睜鐢甸噺鐘舵��
+        /// </summary>
+        public void RefreshBatteryStatu()
+        {
+            if (this.btnBattery == null) { return; }
+            if (this.device.IsBatteryDown == true)
+            {
+                //鐢甸噺浣�,鏄剧ず鍥炬爣
+                if (this.btnBattery.Visible == false)
+                {
+                    this.btnBattery.Visible = true;
+                }
+            }
+            else
+            {
+                //鐢甸噺瓒冲,闅愯棌鍥炬爣
+                if (this.btnBattery.Visible == true)
+                {
+                    this.btnBattery.Visible = false;
+                }
+            }
+        }
+
+        #endregion
+
         #region 鈻� 涓�鑸柟娉昣__________________________
 
         /// <summary>
@@ -481,6 +528,11 @@
             this.btnDeviceIcon.IsSelected = isOpen;
             //鐘舵�佹枃鏈帶浠�
             this.btnStatu.IsSelected = isOpen;
+            //鐢垫睜鎺т欢
+            if (this.btnBattery != null && this.btnBattery.Visible == true)
+            {
+                this.btnBattery.IsSelected = isOpen;
+            }
         }
 
         #endregion
diff --git a/ZigbeeApp/Shared/Phone/MainPage/Controls/SafetyShortcutControl.cs b/ZigbeeApp/Shared/Phone/MainPage/Controls/SafetyShortcutControl.cs
index b8df966..48e8efd 100755
--- a/ZigbeeApp/Shared/Phone/MainPage/Controls/SafetyShortcutControl.cs
+++ b/ZigbeeApp/Shared/Phone/MainPage/Controls/SafetyShortcutControl.cs
@@ -75,7 +75,7 @@
                     return;
                 }
                 //鏄惁璁剧疆鏈夊唴閮ㄩ槻鍖�
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     RefreshSafeZone(bg1, HdlSafeguardLogic.Current.IsHadInternalDefenseArea());
                 });
@@ -127,7 +127,7 @@
                 new System.Threading.Thread(async () =>
                 {
                     var result = await HdlSafeguardLogic.Current.SetSafetyGarrisonByModel(GarrisonMode.AtHome);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         CommonPage.Loading.Hide();
                         if (result == GarrisonMode.AtHome)
@@ -166,7 +166,7 @@
                 new System.Threading.Thread(async () =>
                 {
                     var result = await HdlSafeguardLogic.Current.RemoveSafetyGarrison(GarrisonMode.RemoveGarrison, true);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         CommonPage.Loading.Hide();
                         if (result == 1)
@@ -208,7 +208,7 @@
                 new System.Threading.Thread(async () =>
                 {
                     var result = await HdlSafeguardLogic.Current.SetSafetyGarrisonByModel(GarrisonMode.AtHome);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         CommonPage.Loading.Hide();
                         if (result == GarrisonMode.AtHome)
@@ -244,7 +244,7 @@
                 new System.Threading.Thread(async () =>
                 {
                     var result = await HdlSafeguardLogic.Current.SetSafetyGarrisonByModel(GarrisonMode.RemoveHome);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         CommonPage.Loading.Hide();
                         if (result == GarrisonMode.RemoveHome)
@@ -280,7 +280,7 @@
                 new System.Threading.Thread(async () =>
                 {
                     var result = await HdlSafeguardLogic.Current.RemoveSafetyGarrison(GarrisonMode.RemoveGarrison, true);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         CommonPage.Loading.Hide();
                         if (result == 1)
diff --git a/ZigbeeApp/Shared/Phone/MainPage/Controls/SceneCardControl.cs b/ZigbeeApp/Shared/Phone/MainPage/Controls/SceneCardControl.cs
index 1e95885..c674940 100755
--- a/ZigbeeApp/Shared/Phone/MainPage/Controls/SceneCardControl.cs
+++ b/ZigbeeApp/Shared/Phone/MainPage/Controls/SceneCardControl.cs
@@ -285,13 +285,13 @@
                 while (remainTine > 0 && this.Parent != null)
                 {
                     System.Threading.Thread.Sleep(1000);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         this.btnTimeView.Text = this.GetTimeString(remainTine, hourText, minuText, secondText);
-                    });
+                    }, ShowErrorMode.NO);
                     remainTine--;
                 }
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     //鍊掕鏃剁粨鏉熸椂锛屾椂闂村浘鏍囨樉绀�
                     this.btnTimeIcon.Visible = true;
@@ -299,7 +299,7 @@
                     //鐩存帴寮�鍚疞oading鐗规晥
                     this.StartLoadingApreal();
                     this.CanClick = true;
-                });
+                }, ShowErrorMode.NO);
             })
             { IsBackground = true }.Start();
         }
diff --git a/ZigbeeApp/Shared/Phone/MainPage/DeviceDetailInfoForm.cs b/ZigbeeApp/Shared/Phone/MainPage/DeviceDetailInfoForm.cs
index 8ae60cd..bb903da 100755
--- a/ZigbeeApp/Shared/Phone/MainPage/DeviceDetailInfoForm.cs
+++ b/ZigbeeApp/Shared/Phone/MainPage/DeviceDetailInfoForm.cs
@@ -104,7 +104,7 @@
             var btnBelongType = new NormalViewControl(700, 62, true);
             btnBelongType.Y = btnPic.Bottom + Application.GetRealHeight(35);
             btnBelongType.Gravity = Gravity.CenterHorizontal;
-            btnBelongType.TextID = infoType.BeloneTextId;
+            btnBelongType.Text = infoType.BeloneText;
             btnBelongType.TextSize = 15;
             btnBelongType.TextAlignment = TextAlignment.Center;
             listBackControl.frameTable.AddChidren(btnBelongType);
@@ -216,7 +216,7 @@
             var btnBelongType = new NormalViewControl(700, 62, true);
             btnBelongType.Y = btnPic.Bottom + Application.GetRealHeight(35);
             btnBelongType.Gravity = Gravity.CenterHorizontal;
-            btnBelongType.TextID = infoType.BeloneTextId;
+            btnBelongType.Text = infoType.BeloneText;
             btnBelongType.TextSize = 15;
             btnBelongType.TextAlignment = TextAlignment.Center;
             listBackControl.frameTable.AddChidren(btnBelongType);
diff --git a/ZigbeeApp/Shared/Phone/MainPage/HomeMainPageForm.cs b/ZigbeeApp/Shared/Phone/MainPage/HomeMainPageForm.cs
index b6f5a1b..910c837 100755
--- a/ZigbeeApp/Shared/Phone/MainPage/HomeMainPageForm.cs
+++ b/ZigbeeApp/Shared/Phone/MainPage/HomeMainPageForm.cs
@@ -1106,6 +1106,11 @@
                             //浼犳劅鍣ㄤ笉闇�瑕佸睘鎬т笂鎶�(浣嗘槸閭d釜鐞冨瀷浼犳劅鍣ㄥ眳鐒朵細灞炴�т笂鎶�)
                             this.dicDeviceCardControl[mainKeys].RefreshControlInfo(locadevice);
                         }
+                        else if (report.DeviceStatusReport.CluterID == 1)
+                        {
+                            //杩欎釜鏄數閲忔帹閫�
+                            this.dicDeviceCardControl[mainKeys].RefreshBatteryStatu();
+                        }
                     }
                 }, ShowErrorMode.NO);
             });
diff --git a/ZigbeeApp/Shared/Phone/MainPage/UnallocatedRoomForm.cs b/ZigbeeApp/Shared/Phone/MainPage/UnallocatedRoomForm.cs
index 520287b..2d477e4 100755
--- a/ZigbeeApp/Shared/Phone/MainPage/UnallocatedRoomForm.cs
+++ b/ZigbeeApp/Shared/Phone/MainPage/UnallocatedRoomForm.cs
@@ -58,7 +58,7 @@
         /// <summary>
         /// 鍏ㄩ儴鍒嗙粍鐨勮澶囦俊鎭�
         /// </summary>
-        private Dictionary<int, DeviceRowInfo> dicGroupDevice = null;
+        private Dictionary<string, DeviceRowInfo> dicGroupDevice = null;
         /// <summary>
         /// 鏄惁宸茬粡鏀瑰彉浜嗘暟鎹�
         /// </summary>
@@ -326,9 +326,9 @@
 
             //涓婁竴娆¢�夋嫨鐨勮彍鍗�
             Controls.DeviceFunctionUnallocatedControl oldSelectContr = null;
-            foreach (int Textid in this.dicGroupDevice.Keys)
+            foreach (string strText in this.dicGroupDevice.Keys)
             {
-                var rowInfo = dicGroupDevice[Textid];
+                var rowInfo = dicGroupDevice[strText];
 
                 //璁惧绫诲瀷鐨勫鍣�
                 var devieFrame = new FrameLayout();
@@ -338,11 +338,11 @@
                 //鑿滃崟鍥剧墖鎺т欢
                 var deviceObjContr = new Controls.DeviceFunctionUnallocatedControl();
                 devieFrame.AddChidren(deviceObjContr);
-                deviceObjContr.InitControl(Language.StringByID(Textid), rowInfo.IconPath, rowInfo.IconPathSelected, rowInfo.listDeviceKeys);
+                deviceObjContr.InitControl(strText, rowInfo.IconPath, rowInfo.IconPathSelected, rowInfo.listDeviceKeys);
                 deviceObjContr.ButtonClickEvent += (sender, e) =>
                 {
                     //閫夋嫨鐨勬槸鍚屼竴涓笢瑗跨殑璇�,涓嶅鐞�
-                    if (this.nowSelectDeviceInfo.TextId != rowInfo.TextId)
+                    if (this.nowSelectDeviceInfo.Text != rowInfo.Text)
                     {
                         //涓婁竴娆$殑鑿滃崟鍙栨秷,鏈鑿滃崟閫夋嫨
                         oldSelectContr.SetSelectStatu(false);
@@ -627,29 +627,29 @@
         /// 鑾峰彇鍒嗙粍鍚庣殑璁惧
         /// </summary>
         /// <returns></returns>
-        private Dictionary<int, DeviceRowInfo> GetAllGroupDevice()
+        private Dictionary<string, DeviceRowInfo> GetAllGroupDevice()
         {
             //鍏ㄩ儴鐨勮澶�
             var listDevice = HdlRoomLogic.Current.GetUnalloctedDevice();
             //鏍规嵁璁惧鎵�灞炵被鍨嬫帓搴�
             listDevice = LocalDevice.Current.SortDeviceByBelongType(listDevice);
-            var dic = new Dictionary<int, DeviceRowInfo>();
+            var dic = new Dictionary<string, DeviceRowInfo>();
             foreach (var device in listDevice)
             {
                 var typeInfo = LocalDevice.Current.GetDeviceBelongEnumInfo(device);
                 //鎸夋墍灞濱D鍒嗙粍
-                if (dic.ContainsKey(typeInfo.BeloneTextId) == false)
+                if (dic.ContainsKey(typeInfo.BeloneText) == false)
                 {
-                    dic[typeInfo.BeloneTextId] = new DeviceRowInfo();
+                    dic[typeInfo.BeloneText] = new DeviceRowInfo();
                     string path1 = string.Empty;
                     string path2 = string.Empty;
                     //鑾峰彇鍥剧墖
                     Common.LocalDevice.Current.GetDeviceFunctionTypeMenuIcon(typeInfo.ConcreteType, ref path1, ref path2);
-                    dic[typeInfo.BeloneTextId].IconPath = path1;
-                    dic[typeInfo.BeloneTextId].IconPathSelected = path2;
-                    dic[typeInfo.BeloneTextId].TextId = typeInfo.BeloneTextId;
+                    dic[typeInfo.BeloneText].IconPath = path1;
+                    dic[typeInfo.BeloneText].IconPathSelected = path2;
+                    dic[typeInfo.BeloneText].Text = typeInfo.BeloneText;
                 }
-                dic[typeInfo.BeloneTextId].listDeviceKeys.Add(LocalDevice.Current.GetDeviceMainKeys(device));
+                dic[typeInfo.BeloneText].listDeviceKeys.Add(LocalDevice.Current.GetDeviceMainKeys(device));
             }
             return dic;
         }
@@ -755,9 +755,9 @@
         private class DeviceRowInfo
         {
             /// <summary>
-            /// 鏂囨湰ID,鐩墠鐢ㄦ潵鍋氫富閿�
+            /// 鏂囨湰,鐩墠鐢ㄦ潵鍋氫富閿�
             /// </summary>
-            public int TextId = 0;
+            public string Text = string.Empty;
             /// <summary>
             /// 鍥炬爣
             /// </summary>
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Abount/AbountForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Abount/AbountForm.cs
index 6d9e61b..d261ffd 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Abount/AbountForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Abount/AbountForm.cs
@@ -86,11 +86,11 @@
             btnLogo.UnSelectedImagePath = "Account/Logo_White.png";
             btnLogo.Gravity = Gravity.Center;
             frameLogoBackground.AddChidren(btnLogo);
-            //HDL Home
+            //Evoyo Home
             var btnName = new NormalViewControl(700, 60, true);
             btnName.Y = Application.GetRealHeight(294);
             btnName.Gravity = Gravity.CenterHorizontal;
-            btnName.Text = "HDL Home";
+            btnName.Text = "Evoyo Home";
             btnName.TextSize = 15;
             btnName.TextColor = ZigbeeColor.Current.GXCTextDeepBlackColor;
             btnName.TextAlignment = TextAlignment.Center;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Common/UserCenterCommon.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Common/UserCenterCommon.cs
index e35c611..e99ab65 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Common/UserCenterCommon.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Common/UserCenterCommon.cs
@@ -231,6 +231,19 @@
         public ZigBee.Device.CommonDevice Device = null;
     }
 
+    /// <summary>
+    /// 璁惧鍚嶅瓧鍐呭
+    /// </summary>
+    public class DeviceNameContent
+    {
+        public string A瀹樻柟鍚嶅瓧 = string.Empty;
+        public string A鎵�灞炲悕瀛� = string.Empty;
+        public string A澶囨敞鍚嶅瓧 = string.Empty;
+        public string A绫诲瀷鍚嶅瓧 = string.Empty;
+        public int ConcreteTypeValue = 0;
+        public int BeloneTypeValue = 0;
+    }
+
     #endregion
 
     #region 鈻� 缃戝叧淇℃伅绫籣_________________________
@@ -934,41 +947,29 @@
         /// </summary>
         public bool IsHdlDevice = true;
         /// <summary>
-        /// 璁惧鐨勫叿浣撶被鍨嬬殑缈昏瘧鍚嶅瓧ID,涔熷彨瀹樻柟鍚嶅瓧锛圧鏂囦欢閲岄潰鐨勶級
+        /// 璁惧鐨勫畼鏂瑰悕瀛�
         /// </summary>
-        public int ConcreteTextId = R.MyInternationalizationString.UnknowDevice;
+        public string ConcreteText = string.Empty;
         /// <summary>
-        /// 璁惧鐨勫叿浣撶被鍨�,涔熷彨瀹樻柟绫诲瀷(鍊间负鑷畾涔夌殑鍊�,濂藉儚鍙互鏄暅鍍廔D)
+        /// 璁惧鐨勫叿浣撶被鍨�
         /// </summary>
         public DeviceConcreteType ConcreteType = DeviceConcreteType.UnKownDevice;
+        /// <summary>
+        /// 璁惧鎵�灞炵被鍨嬬殑缈昏瘧鍚嶅瓧
+        /// </summary>
+        public string BeloneText = string.Empty;
         /// <summary>
         /// 璁惧鎵�灞炵被鍨�
         /// </summary>
         public DeviceBeloneType BeloneType = DeviceBeloneType.A鏈煡璁惧;
         /// <summary>
-        /// 璁惧鎵�灞炵被鍨嬬殑缈昏瘧鍚嶅瓧ID锛圧鏂囦欢閲岄潰鐨勶級
+        /// 璁惧鐨勯粯璁ゅ娉ㄧ炕璇戝悕瀛�
         /// </summary>
-        public int BeloneTextId = R.MyInternationalizationString.UnknowDevice;
+        public string DeviceDefultName = string.Empty;
         /// <summary>
-        /// 璁惧鐨勯粯璁ゅ娉ㄧ炕璇戝悕瀛桰D(涓汉涓績涓撶敤,Language鏂囦欢閲岄潰鐨�)
+        /// 璁惧鐨勭被鍨嬬炕璇戝悕瀛�
         /// </summary>
-        public int DefultNameId
-        {
-            get
-            {
-                int value = ConcreteTextId + 20000;
-                //榛樿澶囨敞鍚嶇О鏄湪50000~59999
-                if (50000 <= value && value <= 59999)
-                {
-                    return value;
-                }
-                return ConcreteTextId;
-            }
-        }
-        /// <summary>
-        /// 璁惧鐨勭被鍨嬬炕璇戝悕瀛桰D(涓汉涓績涓撶敤,Language鏂囦欢閲岄潰鐨�)
-        /// </summary>
-        public int ObjectTypeNameId = R.MyInternationalizationString.UnknowDevice;
+        public string ObjectTypeName = string.Empty;
     }
 
     #endregion
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/ClickButtonCommon.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/ClickButtonCommon.cs
index 1b53982..6f8eb29 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/ClickButtonCommon.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/ClickButtonCommon.cs
@@ -76,7 +76,7 @@
             HdlThreadLogic.Current.RunThread(() =>
             {
                 System.Threading.Thread.Sleep(ControlCommonResourse.StatuChangedWaitTime);
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     if (base.CanClick == false || isSelcetStatu == false)
                     {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/IconControlCommon.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/IconControlCommon.cs
index f93af7e..e1e38b3 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/IconControlCommon.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/BaseCommonControl/Common/IconControlCommon.cs
@@ -74,7 +74,7 @@
         {
             if (waitTime == false)
             {
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     //璁剧疆涓嶉�夋嫨鐘舵��
                     this.IsSelected = false;
@@ -85,7 +85,7 @@
                 HdlThreadLogic.Current.RunThread(() =>
                 {
                     System.Threading.Thread.Sleep(ControlCommonResourse.StatuChangedWaitTime);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         //璁剧疆涓嶉�夋嫨鐘舵��
                         this.IsSelected = false;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/RoomDeviceGroupMenuControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/RoomDeviceGroupMenuControl.cs
index 79a91eb..f4e0c58 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/RoomDeviceGroupMenuControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/RoomDeviceGroupMenuControl.cs
@@ -21,7 +21,7 @@
         /// </summary>
         public Action<List<CommonDevice>> SelectDeviceEvent = null;
         /// <summary>
-        /// 褰撳墠閫夋嫨鐨勪富閿�(鎴块棿绫诲瀷鏃讹細鎴块棿ID    璁惧绫诲瀷鏃讹細R鏂囦欢閲岄潰鐨処D)
+        /// 褰撳墠閫夋嫨鐨勪富閿�(鎴块棿绫诲瀷鏃讹細鎴块棿ID   璁惧绫诲瀷鏃讹細鏂囨湰淇℃伅)
         /// </summary>
         public string nowSelectKeys
         {
@@ -36,6 +36,7 @@
                         {
                             return rId.ToString();
                         }
+                        index++;
                     }
                     return string.Empty;
                 }
@@ -54,7 +55,7 @@
         /// <summary>
         /// 璁惧瀵硅薄
         /// </summary>
-        private Dictionary<int, List<CommonDevice>> dicDevice = null;
+        private Dictionary<string, List<CommonDevice>> dicDevice = null;
         /// <summary>
         /// 鍓嶅洖閫夋嫨鐨勬帶浠�
         /// </summary>
@@ -81,8 +82,8 @@
         /// <summary>
         /// 璁惧缁勫悎鐨勮彍鍗曟帶浠�
         /// </summary>
-        /// <param name="i_dicDevice">璁惧鍒楄〃,keys:R鏂囦欢閲岄潰鐨勬暟瀛楃紪鍙�</param>
-        public RoomDeviceGroupMenuControl(Dictionary<int, List<CommonDevice>> i_dicDevice)
+        /// <param name="i_dicDevice">璁惧鍒楄〃,keys:鏂囨湰</param>
+        public RoomDeviceGroupMenuControl(Dictionary<string, List<CommonDevice>> i_dicDevice)
         {
             this.dicDevice = i_dicDevice;
             this.Height = Application.GetRealHeight(204);
@@ -119,14 +120,14 @@
 
                     //璁$畻瀛楃鐨勭湡瀹炲搴�
                     btnTempWidth.Text = listRoom[i].Name;
-                    this.DoInitControl(scrolContr, i, i, listRoom[i].Name, btnTempWidth.GetRealWidthByText());
+                    this.DoInitControl(scrolContr, i.ToString(), i, listRoom[i].Name, btnTempWidth.GetRealWidthByText());
                 }
             }
             else
             {
                 //鍒濆鍖栬澶囨ā寮忕殑鎺т欢
                 int index = 0;
-                foreach (int keys in dicDevice.Keys)
+                foreach (string strKeys in dicDevice.Keys)
                 {
                     if (oldSelectIndex == -1)
                     {
@@ -134,8 +135,8 @@
                         oldSelectIndex = index;
                     }
                     //璁$畻瀛楃鐨勭湡瀹炲搴�
-                    btnTempWidth.Text = Language.StringByID(keys);
-                    this.DoInitControl(scrolContr, keys, index, btnTempWidth.Text, btnTempWidth.GetRealWidthByText());
+                    btnTempWidth.Text = strKeys;
+                    this.DoInitControl(scrolContr, strKeys, index, btnTempWidth.Text, btnTempWidth.GetRealWidthByText());
                     index++;
                 }
             }
@@ -147,11 +148,11 @@
         /// 鍒濆鍖栨帶浠�
         /// </summary>
         /// <param name="scrolContr">鍒楄〃鎺т欢</param>
-        /// <param name="keys">瀛楀吀鐨勪富閿�</param>
+        /// <param name="strKey">瀛楀吀鐨勪富閿�</param>
         /// <param name="index">绱㈠紩</param>
         /// <param name="text">鏄剧ず鏂囨湰</param>
         /// <param name="textWidth">鏂囨湰鐪熷疄瀹藉害</param>
-        private void DoInitControl(HorizontalScrolViewLayout scrolContr, int keys, int index, string text, int textWidth)
+        private void DoInitControl(HorizontalScrolViewLayout scrolContr, string strKey, int index, string text, int textWidth)
         {
             //甯﹀簳鍥炬帶浠剁殑鏈�灏忓搴�
             int minWidth = Application.GetRealWidth(255);
@@ -215,11 +216,11 @@
                 //璋冪敤鍥炶皟鍑芥暟
                 if (this.dicDevice != null)
                 {
-                    this.SelectDeviceEvent?.Invoke(this.dicDevice[keys]);
+                    this.SelectDeviceEvent?.Invoke(this.dicDevice[strKey]);
                 }
                 else if (this.listRoom != null)
                 {
-                    this.SelectRoomEvent?.Invoke(this.listRoom[keys]);
+                    this.SelectRoomEvent?.Invoke(this.listRoom[Convert.ToInt32(strKey)]);
                 }
             };
 
@@ -228,111 +229,14 @@
             {
                 if (this.dicDevice != null)
                 {
-                    this.SelectDeviceEvent?.Invoke(this.dicDevice[keys]);
+                    this.SelectDeviceEvent?.Invoke(this.dicDevice[strKey]);
                 }
                 else if (this.listRoom != null)
                 {
-                    this.SelectRoomEvent?.Invoke(this.listRoom[keys]);
+                    this.SelectRoomEvent?.Invoke(this.listRoom[Convert.ToInt32(strKey)]);
                 }
             }
         }
-
-        /// <summary>
-        /// 鍒濆鍖栨帶浠�
-        /// </summary>
-        /// <param name="scrolContr">鍒楄〃鎺т欢</param>
-        /// <param name="keys">瀛楀吀鐨勪富閿�</param>
-        /// <param name="index">绱㈠紩</param>
-        /// <param name="text">鏄剧ず鏂囨湰</param>
-        /// <param name="textWidth">鏂囨湰鐪熷疄瀹藉害</param>
-        private void DoInitControl2(HorizontalScrolViewLayout scrolContr, int keys, int index, string text, int textWidth)
-        {
-            //甯﹀簳鍥炬帶浠剁殑鏈�灏忓搴�
-            int minWidth = Application.GetRealWidth(255);
-            //甯﹀簳鍥炬帶浠剁殑鐪熷疄瀹藉害   <鏂囧瓧鐨勫搴︾殑璁$畻 frameBack.Width - (int)(frameBack.Height * 0.47)>
-            int realWidth = textWidth + (int)(Application.GetRealHeight(159) * 0.47);
-            if (realWidth < minWidth)
-            {
-                realWidth = minWidth;
-            }
-
-            //甯﹀浘鐗囩殑
-            var frameBack = new FrameLayoutStatuControl();
-            frameBack.UseClickStatu = false;
-            frameBack.Gravity = Gravity.Center;
-            frameBack.Height = Application.GetRealHeight(159);
-            frameBack.Width = realWidth;
-            frameBack.BorderWidth = 1;
-            frameBack.BorderColor = UserCenterColor.Current.TextColor1;
-            scrolContr.AddChidren(frameBack);
-            if (oldSelectIndex == index)
-            {
-                frameBack.SetViewShadow(true);
-                frameBack.BackgroundColor = UserCenterColor.Current.TextColor1;
-                oldFrameBack = frameBack;
-            }
-
-            //鏂囧瓧
-            var btnText = new NormalViewControl(textWidth, frameBack.Height, false);
-            btnText.Gravity = Gravity.CenterHorizontal;
-            btnText.Text = text;
-            btnText.TextSize = 12;
-            btnText.TextAlignment = TextAlignment.Center;
-            if (oldSelectIndex == index)
-            {
-                btnText.TextColor = UserCenterColor.Current.White;
-                oldBtnText = btnText;
-            }
-            else
-            {
-                btnText.TextColor = UserCenterColor.Current.TextGrayColor1;
-            }
-            frameBack.AddChidren(btnText, ChidrenBindMode.BindEvent);
-
-            frameBack.ButtonClickEvent += (sender, e) =>
-            {
-                if (oldSelectIndex == index)
-                {
-                    //鍚屼竴涓笢瑗�
-                    return;
-                }
-                oldSelectIndex = index;
-
-                //鐘舵�佸彉鏇�
-                frameBack.SetViewShadow(true);
-                frameBack.BackgroundColor = UserCenterColor.Current.TextColor1;
-                btnText.TextColor = UserCenterColor.Current.White;
-
-                oldFrameBack.SetViewShadow(false);
-                oldFrameBack.BackgroundColor = UserCenterColor.Current.Transparent;
-                oldBtnText.TextColor = UserCenterColor.Current.TextGrayColor1;
-                oldFrameBack = frameBack;
-                oldBtnText = btnText;
-                //璋冪敤鍥炶皟鍑芥暟
-                if (this.dicDevice != null)
-                {
-                    this.SelectDeviceEvent?.Invoke(this.dicDevice[keys]);
-                }
-                else if (this.listRoom != null)
-                {
-                    this.SelectRoomEvent?.Invoke(this.listRoom[keys]);
-                }
-            };
-
-            //璋冪敤鍥炶皟鍑芥暟
-            if (oldSelectIndex == index)
-            {
-                if (this.dicDevice != null)
-                {
-                    this.SelectDeviceEvent?.Invoke(this.dicDevice[keys]);
-                }
-                else if (this.listRoom != null)
-                {
-                    this.SelectRoomEvent?.Invoke(this.listRoom[keys]);
-                }
-            }
-        }
-
 
         #endregion
 
@@ -356,27 +260,26 @@
         /// <summary>
         /// 璁剧疆鍒濆閫夋嫨(璇峰湪鍒濆鍖栧畬鎴愪箣鍓嶈皟鐢�)
         /// </summary>
-        /// <param name="keys">鎴块棿ID 鎴栬�� R鏂囦欢閲岄潰鐨勬暟鍊肩紪鍙�(杞负瀛楃涓茬被鍨�)</param>
-        public void SetDefultIndex(string keys)
+        /// <param name="strKey">鎴块棿ID 鎴栬�� 鏂囨湰淇℃伅</param>
+        public void SetDefultIndex(string strKey)
         {
             if (listRoom != null)
             {
                 for (int index = 0; index < listRoom.Count; index++)
                 {
-                    if (listRoom[index].Id == keys)
+                    if (listRoom[index].Id == strKey)
                     {
                         oldSelectIndex = index;
                         break;
                     }
                 }
             }
-            else if (keys != string.Empty)
+            else if (strKey != string.Empty)
             {
                 int i = 0;
-                int textId = Convert.ToInt32(keys);
-                foreach (int rId in dicDevice.Keys)
+                foreach (string rId in dicDevice.Keys)
                 {
-                    if (rId == textId)
+                    if (rId == strKey)
                     {
                         oldSelectIndex = i;
                         break;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/SafetyMasterControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/SafetyMasterControl.cs
index 651a4ed..97758ed 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/SafetyMasterControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/CompoundControls/SafetyMasterControl.cs
@@ -156,7 +156,7 @@
                 return;
             }
 
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 //鏍规嵁甯冮槻妯″紡锛岃缃浘鏍囩殑閫夋嫨鐘舵��
                 this.SetIconStatuByGarrisonMode(mode);
@@ -199,7 +199,7 @@
                 return;
             }
 
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 //鏍规嵁甯冮槻妯″紡锛岃缃浘鏍囩殑閫夋嫨鐘舵��
                 this.SetIconStatuByGarrisonMode(mode);
@@ -230,7 +230,7 @@
             {
                 return;
             }
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 //鏍规嵁甯冮槻妯″紡锛岃缃浘鏍囩殑閫夋嫨鐘舵��
                 this.SetIconStatuByGarrisonMode(GarrisonMode.RemoveGarrison);
@@ -287,7 +287,7 @@
                 //娌″繀瑕佸啀鍒濆鍖栫晫闈�
                 return;
             }
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 //娓呯┖鍏ㄩ儴鎺т欢
                 this.RemoveAll();
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/DeviceControls/GatewayRowControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/DeviceControls/GatewayRowControl.cs
index 414fc0d..2091089 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/DeviceControls/GatewayRowControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/DeviceControls/GatewayRowControl.cs
@@ -116,28 +116,31 @@
                     wayName += "(" + Language.StringByID(R.MyInternationalizationString.uChidrenGateway) + ")";
                 }
             }
+            this.btnName = frameTable.AddTopView(wayName, 700);
 
-            this.btnName = frameTable.AddLeftCaption(wayName, 700, 60);
-            btnName.TextSize = 15;
-            //杩欎釜鍧愭爣鏈夌偣鐗规畩
-            btnName.Y = Application.GetRealHeight(12) + this.chidrenYaxis;
-            frameTable.AddChidren(btnName, ChidrenBindMode.BindEvent);
-
-            //鎴块棿
-            string strIp = string.Empty;
-            if (tempWay != null)
-            {
-                strIp = tempWay.GwIP;
-            }
-            this.btnIp = frameTable.AddLeftCaption(strIp, 600, 50, true);
-            //杩欎釜鍧愭爣鏈夌偣鐗规畩
-            btnIp.Y = Application.GetRealHeight(72) + this.chidrenYaxis;
-            btnIp.TextSize = 12;
-            btnIp.TextColor = UserCenterColor.Current.TextGrayColor1;
-            frameTable.AddChidren(btnIp, ChidrenBindMode.BindEvent);
+            //IP
+            this.btnIp = frameTable.AddBottomView(tempWay != null ? tempWay.GwIP : string.Empty, 600);
 
             //鍒濆鍊煎湪绾�
             this.IsOnline = true;
+
+            if (tempWay != null)
+            {
+                //鍒锋柊缃戝叧淇℃伅
+                HdlThreadLogic.Current.RunThread(() =>
+                {
+                    var result = HdlGatewayLogic.Current.GetGatewayInfo(tempWay, false, ShowErrorMode.NO);
+                    if (result != null)
+                    {
+                        HdlThreadLogic.Current.RunMain(() =>
+                        {
+                            //鍒锋柊鎺т欢
+                            tempWay.GatewayOnlineFlage = true;
+                            this.RefreshControl(tempWay);
+                        });
+                    }
+                });
+            }
         }
 
         #endregion
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/FrameLayoutControls/FrameLayoutStatuControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/FrameLayoutControls/FrameLayoutStatuControl.cs
index 8c482c3..7126c4d 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/FrameLayoutControls/FrameLayoutStatuControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/FrameLayoutControls/FrameLayoutStatuControl.cs
@@ -304,7 +304,7 @@
             HdlThreadLogic.Current.RunThread(() =>
             {
                 System.Threading.Thread.Sleep(waiTime);
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     //璁剧疆涓嶉�夋嫨鐘舵��
                     this.SetClickNotSelectStatu();
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/MessageControls/ShowMsgControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/MessageControls/ShowMsgControl.cs
index f2a9145..af99766 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/MessageControls/ShowMsgControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/MessageControls/ShowMsgControl.cs
@@ -104,7 +104,8 @@
         private void InitMsgControl()
         {
             //涓绘帶浠�
-            var frameMain = new FrameLayout();
+            var frameMain = new NormalFrameLayout();
+            frameMain.MainKey = "ShowMsg";
             frameMain.BackgroundColor = UserCenterColor.Current.DialogBackColor;
             Common.CommonPage.Instance.AddChidren(frameMain);
             frameMain.MouseUpEventHandler += (sender, e) =>
@@ -177,7 +178,7 @@
         /// </summary>
         /// <param name="frameMain"></param>
         /// <param name="frameBack"></param>
-        private void InitBottomConfirmButton(FrameLayout frameMain, FrameLayout frameBack)
+        private void InitBottomConfirmButton(NormalFrameLayout frameMain, FrameLayout frameBack)
         {
             //鍙栨秷鎸夐挳
             var btnCancel = new BottomLeftClickButton(Application.GetRealWidth(396), Application.GetRealHeight(127));
@@ -213,7 +214,7 @@
         /// </summary>
         /// <param name="frameMain"></param>
         /// <param name="frameBack"></param>
-        private void InitBottomNormalButton(FrameLayout frameMain, FrameLayout frameBack)
+        private void InitBottomNormalButton(NormalFrameLayout frameMain, FrameLayout frameBack)
         {
 #if Android
             //纭
@@ -282,5 +283,32 @@
         }
 
         #endregion
+
+        #region 鈻� 鍏抽棴寮圭獥(澶栭儴璋冪敤)_________________
+
+        /// <summary>
+        /// 鍏抽棴鍏ㄩ儴鐨勫脊绐�
+        /// </summary>
+        public static void CloseAllMsgDialog()
+        {
+            while (true)
+            {
+                var myView = Common.CommonPage.Instance.GetChildren(Common.CommonPage.Instance.ChildrenCount - 1);
+                if (myView == null) { return; }
+                if (myView is NormalFrameLayout)
+                {
+                    if (((NormalFrameLayout)myView).MainKey != "ShowMsg")
+                    {
+                        return;
+                    }
+                    //绉婚櫎
+                    myView.RemoveFromParent();
+                    continue;
+                }
+                return;
+            }
+        }
+
+        #endregion
     }
 }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/LoadingControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/LoadingControl.cs
index 9ba0531..3622c12 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/LoadingControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/LoadingControl.cs
@@ -29,10 +29,10 @@
                 while (this.Parent != null)
                 {
                     System.Threading.Thread.Sleep(50);
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         this.UnSelectedImagePath = "Loading/" + index + ".png";
-                    });
+                    }, ShowErrorMode.NO);
                     index++;
                     if (index > 32)
                     {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/MessageManagementControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/MessageManagementControl.cs
index d3beaca..342b670 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/MessageManagementControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/NormalControls/MessageManagementControl.cs
@@ -92,11 +92,11 @@
                             continue;
                         }
                         ControlCommonResourse.HadNewMessage = true;
-                        Application.RunOnMainThread(() =>
+                        HdlThreadLogic.Current.RunMain(() =>
                         {
                             //鏈夋柊娑堟伅
                             this.IsSelected = true;
-                        });
+                        }, ShowErrorMode.NO);
                         break;
                     }
                 }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/RowLayoutControls/DeviceFunctionTypeRowControl.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/RowLayoutControls/DeviceFunctionTypeRowControl.cs
index ee4a454..1e70492 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/RowLayoutControls/DeviceFunctionTypeRowControl.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Controls/RowLayoutControls/DeviceFunctionTypeRowControl.cs
@@ -194,25 +194,29 @@
                 || this.device.Type == DeviceType.DimmableLight)
             {
                 //鐏厜绫诲浐瀹氫负 鐏厜
-                strType = Language.StringByID(R.MyInternationalizationString.uLight);
+                var infoContent = Common.LocalDevice.Current.GetDeviceModelIdNameInfo("A418");
+                strType = infoContent != null ? infoContent.A瀹樻柟鍚嶅瓧 : string.Empty;
                 nowSelectNo = 2;
             }
             else if (this.device.Type == DeviceType.WindowCoveringDevice)
             {
                 //绐楀笜鍥哄畾涓� 閬槼
-                strType = Language.StringByID(R.MyInternationalizationString.uDeviceBelongId100);
+                var infoContent = Common.LocalDevice.Current.GetDeviceModelIdNameInfo("A400");
+                strType = infoContent != null ? infoContent.A瀹樻柟鍚嶅瓧 : string.Empty;
                 nowSelectNo = -1;
             }
             else if (this.device.Type == DeviceType.Thermostat)
             {
                 //绌鸿皟鍥哄畾涓� 绌鸿皟
-                strType = Language.StringByID(R.MyInternationalizationString.uDeviceBelongId3600);
+                var infoContent = Common.LocalDevice.Current.GetDeviceModelIdNameInfo("A406");
+                strType = infoContent != null ? infoContent.A瀹樻柟鍚嶅瓧 : string.Empty;
                 nowSelectNo = -1;
             }
             else if (this.device.Type == DeviceType.DoorLock)
             {
                 //闂ㄩ攣鍥哄畾涓� 闂ㄩ攣
-                strType = Language.StringByID(R.MyInternationalizationString.uDeviceBelongId2800);
+                var infoContent = Common.LocalDevice.Current.GetDeviceModelIdNameInfo("A405");
+                strType = infoContent != null ? infoContent.A瀹樻柟鍚嶅瓧 : string.Empty;
                 nowSelectNo = -1;
             }
             else if (this.device.Type == DeviceType.FreshAir)
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Form/AreaCodeSelectForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Form/AreaCodeSelectForm.cs
index 2b6a909..0b1c22c 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Form/AreaCodeSelectForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Form/AreaCodeSelectForm.cs
@@ -140,7 +140,7 @@
                     return obj1.First.CompareTo(obj2.First);
                 });
             }
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 //娣诲姞鍏ㄩ儴鏄庣粏琛�
                 this.AddAllDetailRow(listAreaCode);
@@ -253,7 +253,7 @@
                         listData.Add(listAreaCode[i]);
                     }
                 }
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     //娣诲姞鍏ㄩ儴鏄庣粏琛�
                     this.AddAllDetailRow(listData);
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFileLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFileLogic.cs
index ecaf58d..640cb70 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFileLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFileLogic.cs
@@ -86,10 +86,21 @@
         /// 鏂囦欢淇濆瓨(鏁村ぉ蹇樿,鎵�浠ュ缓涓�涓嚱鏁版潵鐜╃帺)
         /// </summary>
         /// <param name="fullName">鍏ㄨ矾寰�</param>
-        /// <param name="obj">闇�瑕佸簭鍒楀寲鐨勪笢瑗�</param>
+        /// <param name="textValue">鏂囨湰</param>
         public void SaveTextToFile(string fullName, string textValue)
         {
             var byteData = Encoding.UTF8.GetBytes(textValue);
+            this.SaveByteToFile(fullName, byteData);
+        }
+
+        /// <summary>
+        /// 鏂囦欢淇濆瓨(鏁村ぉ蹇樿,鎵�浠ュ缓涓�涓嚱鏁版潵鐜╃帺)
+        /// </summary>
+        /// <param name="fullName">鍏ㄨ矾寰�</param>
+        /// <param name="byteData">byte鏁版嵁</param>
+        public void SaveByteToFile(string fullName, byte[] byteData)
+        {
+            if (byteData == null) { return; }
             //鍐欏叆鍐呭
             System.IO.FileStream fileStream = null;
             try
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFirmwareUpdateLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFirmwareUpdateLogic.cs
index 0f70087..285c6f6 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFirmwareUpdateLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlFirmwareUpdateLogic.cs
@@ -145,8 +145,12 @@
             }
 
             //纭欢鐗堟湰
-            Dictionary<string, FirmwareHardInfo> dicHardData = new Dictionary<string, FirmwareHardInfo>();
-            FirmwareUpdateResourse.dicFirmwareInfo[levelType] = dicHardData;
+            Dictionary<string, FirmwareHardInfo> dicHardData = null;
+            if (FirmwareUpdateResourse.dicFirmwareInfo.ContainsKey(levelType) == false)
+            {
+                FirmwareUpdateResourse.dicFirmwareInfo[levelType] = new Dictionary<string, FirmwareHardInfo>();
+            }
+            dicHardData = FirmwareUpdateResourse.dicFirmwareInfo[levelType];
 
             foreach (var data in verResult.PageData)
             {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayBackupLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayBackupLogic.cs
index c39db25..12770b5 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayBackupLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayBackupLogic.cs
@@ -662,7 +662,7 @@
                     if (timeOut >= 65 && timeOut % 5 == 0)
                     {
                         //5绉掍竴娆�,鍘昏幏鍙栫増鏈�
-                        var data = HdlGatewayLogic.Current.GetGatewayInfo(realGateway, ShowErrorMode.NO);
+                        var data = HdlGatewayLogic.Current.GetGatewayInfo(realGateway, false, ShowErrorMode.NO);
                         if (data != null)
                         {
                             gatewatAction = true;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayLogic.cs
index 22eced4..fc831b0 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayLogic.cs
@@ -263,18 +263,7 @@
                 return -1;
             }
             //鑾峰彇缃戝叧鐨勪俊鎭�
-            var result = await zbGateway.GetZbGwInfoAsync();
-            //妫�娴嬬綉鍏宠繑鍥炵殑鍏遍�氶敊璇姸鎬佺爜
-            string error = HdlCheckLogic.Current.CheckCommonErrorCode(result);
-            if (error != null)
-            {
-                if (mode == ShowErrorMode.YES)
-                {
-                    this.ShowTipMsg(error);
-                }
-                return -1;
-            }
-
+            var result = this.GetGatewayInfo(zbGateway, true, mode);
             if (result == null)
             {
                 if (mode == ShowErrorMode.YES)
@@ -286,28 +275,20 @@
                 return -1;
             }
 
-            if (result.getGwData == null)
-            {
-                if (mode == ShowErrorMode.YES)
-                {
-                    //鑾峰彇缃戝叧淇℃伅澶辫触
-                    string msg = Language.StringByID(R.MyInternationalizationString.uGetGatewayInfoFail);
-                    this.ShowTipMsg(msg);
-                }
-                return -1;
-            }
-
             //璁剧疆浣忓畢ID鍒扮綉鍏�
-            bool flage2 = await this.SetHomeIdToGateway(zbGateway, Common.Config.Instance.HomeId, mode);
-            if (flage2 == false)
+            if (result.HomeId != Common.Config.Instance.HomeId)
             {
-                if (mode == ShowErrorMode.YES)
+                bool flage2 = await this.SetHomeIdToGateway(zbGateway, Common.Config.Instance.HomeId, mode);
+                if (flage2 == false)
                 {
-                    //鍚戠綉鍏宠缃綇瀹匢D澶辫触
-                    string msg = Language.StringByID(R.MyInternationalizationString.uSetHomeIdToGatewayFail);
-                    this.ShowTipMsg(msg);
+                    if (mode == ShowErrorMode.YES)
+                    {
+                        //鍚戠綉鍏宠缃綇瀹匢D澶辫触
+                        string msg = Language.StringByID(R.MyInternationalizationString.uSetHomeIdToGatewayFail);
+                        this.ShowTipMsg(msg);
+                    }
+                    return -1;
                 }
-                return -1;
             }
 
             //鏇存柊浜戠鏁版嵁搴�
@@ -337,9 +318,9 @@
             //鍒锋柊鐨勬槸缂撳瓨,涓嶅埛鏂扮湡瀹炵墿鐞嗙綉鍏�
             this.dicGateway[gwID].GatewayOnlineFlage = zbGateway.GatewayOnlineFlage;
             //灏嗙綉鍏崇殑鏁版嵁璁剧疆鍒版湰鍦扮紦瀛樹腑
-            this.SetGatewayDataToLocalMemmory(this.dicGateway[gwID], result.getGwData);
+            this.SetGatewayDataToLocalMemmory(this.dicGateway[gwID], result);
             //椤轰究杩欎釜鍙橀噺涔熻缃竴涓�
-            this.SetGatewayDataToLocalMemmory(zbGateway, result.getGwData, false);
+            this.SetGatewayDataToLocalMemmory(zbGateway, result, false);
 
             if (isEsist == false)
             {
@@ -492,12 +473,12 @@
             await Task.Delay(8000);
 
             //鑾峰彇缃戝叧鐨勪俊鎭�
-            ZbGatewayData.GetGwAllData result = null;
+            ZbGatewayData.GetGwData result = null;
             int count = 5;
             while (count >= 0)
             {
-                result = await zbGateway.GetZbGwInfoAsync();
-                if (result != null && result.getGwData != null)
+                result = this.GetGatewayInfo(zbGateway, true, ShowErrorMode.NO);
+                if (result != null)
                 {
                     break;
                 }
@@ -505,15 +486,7 @@
                 //鏈�澶氬啀绛�20绉�
                 await Task.Delay(4000);
             }
-            //妫�娴嬬綉鍏宠繑鍥炵殑鍏遍�氶敊璇姸鎬佺爜
-            string error = HdlCheckLogic.Current.CheckCommonErrorCode(result);
-            if (error != null)
-            {
-                this.ShowTipMsg(error);
-                return -1;
-            }
-
-            if (result == null || result.getGwData == null)
+            if (result == null)
             {
                 //鑾峰彇缃戝叧淇℃伅澶辫触
                 string msg = Language.StringByID(R.MyInternationalizationString.uGetGatewayInfoFail);
@@ -535,9 +508,9 @@
             //鍒锋柊鐨勬槸缂撳瓨,涓嶅埛鏂扮湡瀹炵墿鐞嗙綉鍏�
             this.dicGateway[gwID].GatewayOnlineFlage = zbGateway.GatewayOnlineFlage;
             //灏嗙綉鍏崇殑鏁版嵁璁剧疆鍒版湰鍦扮紦瀛樹腑
-            this.SetGatewayDataToLocalMemmory(this.dicGateway[gwID], result.getGwData);
+            this.SetGatewayDataToLocalMemmory(this.dicGateway[gwID], result);
             //椤轰究杩欎釜鍙橀噺涔熻缃竴涓�
-            this.SetGatewayDataToLocalMemmory(zbGateway, result.getGwData, false);
+            this.SetGatewayDataToLocalMemmory(zbGateway, result, false);
 
             if (isEsist == false)
             {
@@ -609,15 +582,14 @@
         public async Task<bool> DoSwitchGateway(string gatewayId)
         {
             var zbGateway = this.GetLocalGateway(gatewayId);
-            if (this.CheckGatewayOnlineByFlag(zbGateway) == true)
+
+            //閲嶆柊鑾峰彇鍦ㄧ嚎缃戝叧鐨勪俊鎭�
+            var result = await this.GetOnlineGatewayInfo(gatewayId);
+            if (result == false)
             {
-                //閲嶆柊鑾峰彇鍦ㄧ嚎缃戝叧鐨勪俊鎭�
-                var result = await this.GetOnlineGatewayInfo(gatewayId);
-                if (result == false)
-                {
-                    return false;
-                }
+                return false;
             }
+
             //鍒囨崲缃戝叧,淇濆瓨缂撳瓨
             this.SaveGatewayIdToLocation(gatewayId);
             //鍒囨崲缃戝叧鐨勮瘽,涓婚〉闇�瑕侀噸鏂板埛鏂�
@@ -666,7 +638,7 @@
             if (getGatewayInfo == true)
             {
                 //鑾峰彇缃戝叧淇℃伅
-                var info = this.GetGatewayInfo(realWay);
+                var info = this.GetGatewayInfo(realWay, false);
                 if (info == null)
                 {
                     //鍏抽棴杩涘害鏉�
@@ -676,7 +648,7 @@
             }
 
             //鑾峰彇鍏ㄩ儴璁惧
-            int result = LocalDevice.Current.SetDeviceToMemmoryByGateway(realWay);
+            int result = LocalDevice.Current.SetDeviceToMemmoryByGateway(realWay, false);
             //鍏抽棴杩涘害鏉�
             ProgressBar.Close();
             if (result == -1)
@@ -717,20 +689,11 @@
         public async Task<bool> DeleteGateway(string zbGatewayID)
         {
             ZbGateway realWay = null;
-            bool hadReal = this.GetRealGateway(ref realWay, zbGatewayID);
-
-            //鏆備笉鏀寔鍒嗕韩
-            if (hadReal == true && realWay.GatewayOnlineFlage == true)
+            this.GetRealGateway(ref realWay, zbGatewayID);
+            //娓呯┖缃戝叧鐨勪綇瀹匢D 缃戝叧瑙g粦澶辫触  涓嶇悊瀹�,鍥犱负缃戝叧鍙互鎸夋寜閿己鍒舵悳绱㈠緱鍒�
+            if (realWay != null)
             {
-                //娓呯┖缃戝叧鐨勪綇瀹匢D
-                bool result = await this.SetHomeIdToGateway(realWay, string.Empty, ShowErrorMode.YES);
-                if (result == false)
-                {
-                    //缃戝叧瑙g粦澶辫触  涓嶇悊瀹�,鍥犱负缃戝叧鍙互鎸夋寜閿己鍒舵悳绱㈠緱鍒�
-                    string msg = Language.StringByID(R.MyInternationalizationString.uGatewayUnBindFail);
-                    //this.ShowErrorMsg(msg);
-                    //return false;
-                }
+                await this.SetHomeIdToGateway(realWay, string.Empty, ShowErrorMode.NO);
             }
 
             //鍒犻櫎浜戠鐨勭綉鍏�
@@ -742,7 +705,10 @@
             //绉婚櫎
             ZbGateway.GateWayList.RemoveAll((obj) => obj.GwId == zbGatewayID);
             //鏂紑mqtt杩炴帴
-            realWay.DisConnectLocalMqttClient("GD");
+            if (realWay != null)
+            {
+                realWay.DisConnectLocalMqttClient("GD");
+            }
 
             return true;
         }
@@ -1308,6 +1274,8 @@
         /// <returns></returns>
         public string GetGatewayName(ZbGateway zbGateway)
         {
+            if (zbGateway == null) { return string.Empty; }
+
             string gwId = zbGateway.GwId;
             if (this.dicGateway.ContainsKey(gwId) == false)
             {
@@ -1321,11 +1289,10 @@
                 return name;
             }
 
-            string keyName = Common.LocalDevice.deviceModelIdName + localWay.LinuxImageType;
-            if (LocalDevice.Current.dicDeviceAllNameID.ContainsKey(keyName) == true)
+            var nameContent = LocalDevice.Current.GetDeviceModelIdNameInfo(localWay.LinuxImageType.ToString());
+            if (nameContent != null)
             {
-                //娌℃湁鍚嶇О鏃讹紝鍒欎娇鐢≧鏂囦欢閲岄潰璁剧疆鐨勯粯璁よ澶囧悕绉�
-                return Language.StringByID(LocalDevice.Current.dicDeviceAllNameID[keyName] + 20000);
+                return nameContent.A澶囨敞鍚嶅瓧;
             }
 
             return string.Empty;
@@ -1362,11 +1329,10 @@
                 //濡傛灉杩欎釜缃戝叧娌℃湁淇℃伅锛屽垯浠庢柊鑾峰彇
                 if (zbGateway.LinuxImageType != -1)
                 {
-                    string keyName = Common.LocalDevice.deviceModelIdName + zbGateway.LinuxImageType;
-                    if (Common.LocalDevice.Current.dicDeviceAllNameID.ContainsKey(keyName) == true)
+                    var nameContent = LocalDevice.Current.GetDeviceModelIdNameInfo(zbGateway.LinuxImageType.ToString());
+                    if (nameContent != null)
                     {
-                        //浣跨敤R鏂囦欢閲岄潰璁剧疆鐨勪笢瑗�
-                        button.TextID = LocalDevice.Current.dicDeviceAllNameID[keyName];
+                        button.Text = nameContent.A瀹樻柟鍚嶅瓧;
                     }
                 }
                 else
@@ -1374,7 +1340,7 @@
                     //缁欎竴涓嚎绋嬪幓鑾峰彇瀹冪殑闀滃儚绫诲瀷
                     HdlThreadLogic.Current.RunThread(() =>
                     {
-                        var result = this.GetGatewayInfo(zbGateway, ShowErrorMode.NO);
+                        var result = this.GetGatewayInfo(zbGateway, false, ShowErrorMode.NO);
                         if (result != null)
                         {
                             //灏嗙綉鍏崇殑鏁版嵁璁剧疆鍒版湰鍦扮紦瀛樹腑
@@ -1382,11 +1348,10 @@
 
                             HdlThreadLogic.Current.RunMain(() =>
                             {
-                                string keyName = Common.LocalDevice.deviceModelIdName + zbGateway.LinuxImageType;
-                                if (Common.LocalDevice.Current.dicDeviceAllNameID.ContainsKey(keyName) == true)
+                                var nameContent = LocalDevice.Current.GetDeviceModelIdNameInfo(zbGateway.LinuxImageType.ToString());
+                                if (nameContent != null)
                                 {
-                                    //浣跨敤R鏂囦欢閲岄潰璁剧疆鐨勪笢瑗�
-                                    button.TextID = LocalDevice.Current.dicDeviceAllNameID[keyName];
+                                    button.Text = nameContent.A瀹樻柟鍚嶅瓧;
                                 }
                             });
                         }
@@ -1395,11 +1360,10 @@
             }
             else
             {
-                string keyName = Common.LocalDevice.deviceModelIdName + this.dicGateway[gwId].LinuxImageType;
-                if (Common.LocalDevice.Current.dicDeviceAllNameID.ContainsKey(keyName) == true)
+                var nameContent = LocalDevice.Current.GetDeviceModelIdNameInfo(zbGateway.LinuxImageType.ToString());
+                if (nameContent != null)
                 {
-                    //浣跨敤R鏂囦欢閲岄潰璁剧疆鐨勪笢瑗�
-                    button.TextID = Common.LocalDevice.Current.dicDeviceAllNameID[keyName];
+                    button.Text = nameContent.A瀹樻柟鍚嶅瓧;
                 }
             }
         }
@@ -1412,13 +1376,14 @@
         /// 鑾峰彇缃戝叧淇℃伅(鐗堟湰淇℃伅,闀滃儚绫诲瀷,鍩烘湰淇℃伅绛夈�傚彧鍒锋柊鏈湴缃戝叧鐨勭紦瀛�)
         /// </summary>
         /// <param name="zbGateway"></param>
+        /// <param name="useLocalConnect">鏄惁寮哄埗浣跨敤鏈湴杩炴帴鍙戦��</param>
         /// <param name="mode"></param>
         /// <returns></returns>
-        public ZbGatewayData.GetGwData GetGatewayInfo(ZbGateway zbGateway, ShowErrorMode mode = ShowErrorMode.YES)
+        public ZbGatewayData.GetGwData GetGatewayInfo(ZbGateway zbGateway, bool useLocalConnect, ShowErrorMode mode = ShowErrorMode.YES)
         {
             //鑾峰彇缃戝叧鐗堟湰淇℃伅
             var jObject = new Newtonsoft.Json.Linq.JObject { { "Cluster_ID", 0 }, { "Command", 95 } };
-            var result = this.SendJobjectDataToGateway(zbGateway, "GetZbGwInfo", jObject.ToString(), "GetZbGwInfo_Respon");
+            var result = this.SendJobjectDataToGateway(zbGateway, "GetZbGwInfo", jObject.ToString(), "GetZbGwInfo_Respon", 5, useLocalConnect);
 
             if (result.ErrorMsgDiv != 1)
             {
@@ -1467,6 +1432,7 @@
             localWay.CoordinatorFirmwareVersion = data.ZbFWVersion;
             localWay.CoordinatorImageId = data.ZbImageType;
             localWay.DriveCodeList = data.DriveCodeList;
+            localWay.GwVersionDate = data.AppVersion;
             if (saveFile == true)
             {
                 localWay.ReSave();
@@ -1554,7 +1520,7 @@
         public List<FirmwareVersionInfo> GetGatewayAllNewVersion(ZbGateway zbGateway, ShowErrorMode mode = ShowErrorMode.YES)
         {
             //鑾峰彇缃戝叧鐗堟湰淇℃伅
-            var result = this.GetGatewayInfo(zbGateway, mode);
+            var result = this.GetGatewayInfo(zbGateway, false, mode);
             if (result == null)
             {
                 return null;
@@ -1704,7 +1670,7 @@
                     //缁欎竴涓嚎绋嬪幓鑾峰彇瀹冪殑闀滃儚绫诲瀷
                     HdlThreadLogic.Current.RunThread(() =>
                     {
-                        var result = this.GetGatewayInfo(zbGateway, ShowErrorMode.NO);
+                        var result = this.GetGatewayInfo(zbGateway, true, ShowErrorMode.NO);
                         if (result != null)
                         {
                             //灏嗙綉鍏崇殑鏁版嵁璁剧疆鍒版湰鍦扮紦瀛樹腑
@@ -1742,7 +1708,7 @@
                     //缁欎竴涓嚎绋嬪幓鑾峰彇瀹冪殑闀滃儚绫诲瀷
                     HdlThreadLogic.Current.RunThread(() =>
                     {
-                        var result = this.GetGatewayInfo(zbGateway, ShowErrorMode.NO);
+                        var result = this.GetGatewayInfo(zbGateway, true, ShowErrorMode.NO);
                         if (result != null)
                         {
                             //灏嗙綉鍏崇殑鏁版嵁璁剧疆鍒版湰鍦扮紦瀛樹腑
@@ -2070,8 +2036,9 @@
         /// <param name="sendData">闇�瑕佸彂閫佺殑鏁版嵁  JObject.ToString()鐨勪笢瑗�</param>
         /// <param name="receiptTopic">鎸囧畾鎺ユ敹鍝釜涓婚</param>
         /// <param name="waitTime">瓒呮椂鏃堕棿(绉�)</param>
+        /// <param name="useLocalConnect">鏄惁寮哄埗浣跨敤鏈湴杩炴帴鍙戦��</param>
         /// <returns>缃戝叧杩斿洖鐨勬暟鎹�</returns>
-        public ReceiptGatewayResult SendJobjectDataToGateway(ZbGateway gateway, string sendTopic, string sendData, string receiptTopic, int waitTime = 5)
+        public ReceiptGatewayResult SendJobjectDataToGateway(ZbGateway gateway, string sendTopic, string sendData, string receiptTopic, int waitTime = 5, bool useLocalConnect = false)
         {
             var reResult = new ReceiptGatewayResult();
 
@@ -2108,7 +2075,14 @@
             };
             myGateway.Actions += receiptAction;
             //鍙戦�佹暟鎹�
-            myGateway.Send(sendTopic, sendData);
+            if (useLocalConnect == false)
+            {
+                myGateway.Send(sendTopic, sendData);
+            }
+            else
+            {
+                myGateway.SendLocation(sendTopic, System.Text.Encoding.UTF8.GetBytes(sendData));
+            }
 
             //瓒呮椂鏃堕棿
             int TimeOut = 0;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs
index 71bc66b..dcd3593 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayReceiveLogic.cs
@@ -251,6 +251,32 @@
                 }
                 #endregion
 
+                #region 鈻� 鐢甸噺鎺ㄩ��
+                //鐢甸噺鎺ㄩ��
+                if (report.DeviceStatusReport.CluterID == 1)
+                {
+                    foreach (var attData in report.DeviceStatusReport.AttriBute)
+                    {
+                        //鐢甸噺
+                        if (attData.AttributeId == 33)
+                        {
+                            string receiptData = string.Empty;
+                            //涓や釜涓や釜浣嶇疆鏇挎崲
+                            for (int i = attData.AttriButeDataHex.Length - 1; i >= 0; i = i - 2)
+                            {
+                                receiptData += attData.AttriButeDataHex[i - 1].ToString() + attData.AttriButeDataHex[i].ToString();
+                            }
+                            int batteryValue = Convert.ToInt32(receiptData, 16);
+                            //浣庝簬20%,鍒欎唬琛ㄧ數閲忎綆
+                            locadevice.IsBatteryDown = batteryValue < 20;
+                        }
+                        //宸茬粡鎺ユ敹鍒扮姸鎬�
+                        locadevice.HadReadDeviceStatu = true;
+                    }
+                }
+
+                #endregion
+
                 #region 鈻� 绐楀笜鏁版嵁
                 //绐楀笜鏁版嵁
                 else if (report.DeviceStatusReport.CluterID == 258)
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayUpdateLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayUpdateLogic.cs
index 9b65233..ea27785 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayUpdateLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlGatewayUpdateLogic.cs
@@ -996,7 +996,7 @@
                 while (this.IsFinishUpdate == false)
                 {
                     //鑾峰彇鐗堟湰
-                    var result = HdlGatewayLogic.Current.GetGatewayInfo(this.upDatezbGateway, ShowErrorMode.NO);
+                    var result = HdlGatewayLogic.Current.GetGatewayInfo(this.upDatezbGateway, false, ShowErrorMode.NO);
                     if (result != null)
                     {
                         break;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlLogLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlLogLogic.cs
index 21fed47..4aa704a 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlLogLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlLogLogic.cs
@@ -40,6 +40,39 @@
         #region 鈻� Log鍑哄姏____________________________
 
         /// <summary>
+        /// 璋冭瘯鐢�,杩藉姞鍐欏叆鍏朵粬Log
+        /// </summary>
+        /// <param name="fullName">鍏ㄨ矾寰�</param>
+        /// <param name="i_text">瑕佸啓鍏ョ殑鍐呭</param>
+        /// <param name="deleteFile">鏄惁鍏堝垹闄ゆ枃浠�</param>
+        /// <param name="encrypt">鍐欏叆鐨勫唴瀹规槸鍚﹀姞瀵�</param>
+        public void WriteOtherText(string fullName, string i_text, bool deleteFile, bool encrypt)
+        {
+            if (deleteFile == true)
+            {
+                HdlFileLogic.Current.DeleteFile(fullName);
+            }
+            System.IO.StreamWriter sw = null;
+            try
+            {
+                string strLog = "[" + DateTime.Now.ToString("yyyyMMdd HH:mm:ss") + "] " + i_text;
+                if (encrypt == true)
+                {
+                    strLog = UserCenterLogic.EncryptPassword(UserCenterResourse.FileEncryptKey, strLog);
+                }
+                strLog = "\r\n" + strLog + "\r\n";
+                sw = new System.IO.StreamWriter(fullName, true, Encoding.UTF8);
+                sw.WriteLine(strLog);
+            }
+            catch { }
+            finally
+            {
+                sw?.Close();
+                sw = null;
+            }
+        }
+
+        /// <summary>
         /// Log鍑哄姏
         /// </summary>
         /// <param name="ex"></param>
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlResidenceLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlResidenceLogic.cs
index 64b64c5..6187c50 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlResidenceLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlResidenceLogic.cs
@@ -131,7 +131,7 @@
             Pra.LoginAccessToken = Config.Instance.Token;
 
             //缂栬緫浣忓畢
-            bool flage = UserCenterLogic.GetResultStatuByRequestHttps("App/EditHome", false, Pra, new List<string> { "NotCheck" });
+            bool flage = UserCenterLogic.GetResultStatuByRequestHttps("App/EditHome", false, Pra);
             if (flage == true)
             {
                 //鍒锋柊鍐呭瓨鐨勪綇瀹呭悕
@@ -323,7 +323,7 @@
                 }
                 listHome.Add(home);
             }
-            return listHome;
+            return this.SortHouse(listHome);
         }
 
         /// <summary>
@@ -359,7 +359,183 @@
                     listHome.Add(myHouse);
                 }
             }
-            return listHome;
+            return this.SortHouse(listHome);
+        }
+
+        #endregion
+
+        #region 鈻� 浣忓畢鎺掑簭___________________________
+
+        /// <summary>
+        /// 浣忓畢鎺掑簭
+        /// </summary>
+        /// <param name="i_listHouse"></param>
+        /// <returns></returns>
+        public List<House> SortHouse(List<House> i_listHouse)
+        {
+            //浠庝竴鍫嗘枃瀛椾腑,鑾峰彇杩欎竴鍫嗘枃瀛楅噷闈㈡暟瀛楀瓧绗︿覆鐨勬渶闀块暱搴�
+            var listName = new List<string>();
+            foreach (var house in i_listHouse)
+            {
+                listName.Add(house.Name);
+            }
+            int numberLength = this.GetNumberMaxLength(listName);
+
+            var listSort = new List<string[]>();
+            var dicHouse = new Dictionary<string, House>();
+            foreach (var house in i_listHouse)
+            {
+                //涓存椂缂撳瓨
+                dicHouse[house.Id] = house;
+
+                var strArry = new string[2];
+                strArry[0] = house.Id;
+                strArry[1] = string.Empty;
+
+                string value = string.Empty;
+                foreach (var c in house.Name)
+                {
+                    if (char.IsNumber(c) == true)
+                    {
+                        //鏁板瓧
+                        value += c.ToString();
+                        continue;
+                    }
+                    else if (value != string.Empty)
+                    {
+                        //濡傛灉鎴块棿鍚嶅瓧甯︽湁鏁板瓧鐨勮瘽,鍒欏乏杈瑰姞闆�,鍥犱负杩欓噷鏈変釜鎺掑簭鐨勯棶棰�
+                        strArry[1] += value.PadLeft(numberLength, '0');
+                        value = string.Empty;
+                    }
+                    strArry[1] += c.ToString();
+                }
+                if (value != string.Empty)
+                {
+                    //浠ユ暟瀛楃粨灏剧殑璇�
+                    strArry[1] += value.PadLeft(numberLength, '0');
+                }
+                listSort.Add(strArry);
+            }
+            //鎺掑簭
+            listSort.Sort((obj1, obj2) =>
+            {
+                if (obj1[1].CompareTo(obj2[1]) > 0)
+                {
+                    return 1;
+                }
+                return -1;
+            });
+            var listSortHouse = new List<House>();
+            foreach (var strArry in listSort)
+            {
+                listSortHouse.Add(dicHouse[strArry[0]]);
+            }
+            return listSortHouse;
+        }
+
+        /// <summary>
+        /// 浜戠浣忓畢鎺掑簭
+        /// </summary>
+        /// <param name="i_listData"></param>
+        /// <returns></returns>
+        public List<Common.ResponseEntity.ResidenceObj> SortHouse(List<Common.ResponseEntity.ResidenceObj> i_listData)
+        {
+            //浠庝竴鍫嗘枃瀛椾腑,鑾峰彇杩欎竴鍫嗘枃瀛楅噷闈㈡暟瀛楀瓧绗︿覆鐨勬渶闀块暱搴�
+            var listName = new List<string>();
+            foreach (var house in i_listData)
+            {
+                listName.Add(house.Name);
+            }
+            int numberLength = this.GetNumberMaxLength(listName);
+
+            var listSort = new List<string[]>();
+            var dicHouse = new Dictionary<string, Common.ResponseEntity.ResidenceObj>();
+            foreach (var house in i_listData)
+            {
+                //涓存椂缂撳瓨
+                dicHouse[house.Id] = house;
+
+                var strArry = new string[2];
+                strArry[0] = house.Id;
+                strArry[1] = string.Empty;
+
+                string value = string.Empty;
+                foreach (var c in house.Name)
+                {
+                    if (char.IsNumber(c) == true)
+                    {
+                        //鏁板瓧
+                        value += c.ToString();
+                        continue;
+                    }
+                    else if (value != string.Empty)
+                    {
+                        //濡傛灉鎴块棿鍚嶅瓧甯︽湁鏁板瓧鐨勮瘽,鍒欏乏杈瑰姞闆�,鍥犱负杩欓噷鏈変釜鎺掑簭鐨勯棶棰�
+                        strArry[1] += value.PadLeft(numberLength, '0');
+                        value = string.Empty;
+                    }
+                    strArry[1] += c.ToString();
+                }
+                if (value != string.Empty)
+                {
+                    //浠ユ暟瀛楃粨灏剧殑璇�
+                    strArry[1] += value.PadLeft(numberLength, '0');
+                }
+                listSort.Add(strArry);
+            }
+            //鎺掑簭
+            listSort.Sort((obj1, obj2) =>
+            {
+                if (obj1[1].CompareTo(obj2[1]) > 0)
+                {
+                    return 1;
+                }
+                return -1;
+            });
+            var listSortHouse = new List<Common.ResponseEntity.ResidenceObj>();
+            foreach (var strArry in listSort)
+            {
+                listSortHouse.Add(dicHouse[strArry[0]]);
+            }
+            return listSortHouse;
+        }
+
+        /// <summary>
+        /// 浠庝竴鍫嗘枃瀛椾腑,鑾峰彇杩欎竴鍫嗘枃瀛楅噷闈㈡暟瀛楀瓧绗︿覆鐨勬渶闀块暱搴�
+        /// </summary>
+        /// <param name="listText"></param>
+        /// <returns></returns>
+        private int GetNumberMaxLength(List<string> listText)
+        {
+            int maxLength = 0;
+            foreach (var text in listText)
+            {
+                string value = string.Empty;
+                foreach (var c in text)
+                {
+                    if (char.IsNumber(c) == true)
+                    {
+                        //鏁板瓧
+                        value += c.ToString();
+                        continue;
+                    }
+                    else if (value != string.Empty)
+                    {
+                        //鍒ゆ柇鏁板瓧闀垮害
+                        if (maxLength <= value.Length)
+                        {
+                            maxLength = value.Length;
+                        }
+                        value = string.Empty;
+                    }
+                }
+                //鍒ゆ柇鏁板瓧闀垮害
+                if (maxLength <= value.Length)
+                {
+                    maxLength = value.Length;
+                }
+            }
+            return maxLength;
         }
 
         #endregion
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlSceneLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlSceneLogic.cs
index 402cf70..d087a84 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlSceneLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlSceneLogic.cs
@@ -77,12 +77,13 @@
         }
 
         /// <summary>
-        /// 鍒锋柊鏈湴鐨勫叏閮ㄥ満鏅�
+        /// 鍒锋柊浠庣綉鍏冲埛鏂板叏閮ㄧ殑鍦烘櫙
         /// </summary>
-        public bool RefreshSceneUIList()
+        /// <param name="useLocalConnect">鏄惁寮哄埗浣跨敤鏈湴杩炴帴鍙戦��</param>
+        public bool RefreshSceneUIList(bool useLocalConnect)
         {
             //鑾峰彇缃戝叧瀛樺湪鐨勫満鏅�
-            var sceneList = this.RefreshSceneListFromGateway();
+            var sceneList = this.RefreshSceneListFromGateway(useLocalConnect);
             if (sceneList == null)
             {
                 return false;
@@ -152,8 +153,8 @@
         /// <summary>
         /// 浠庣綉鍏抽噸鏂板埛鏂板満鏅垪琛�
         /// </summary>
-        /// <returns></returns>
-        private List<Scene.GetSceneAllInfo> RefreshSceneListFromGateway()
+        /// <param name="useLocalConnect">鏄惁寮哄埗浣跨敤鏈湴杩炴帴鍙戦��</param>
+        private List<Scene.GetSceneAllInfo> RefreshSceneListFromGateway(bool useLocalConnect)
         {
             var mainGateway = ZbGateway.MainGateWay;
             if (mainGateway == null)
@@ -192,7 +193,14 @@
             mainGateway.Actions += action;
 
             var jObject = new Newtonsoft.Json.Linq.JObject { { "Cluster_ID", 0 }, { "Command", 807 } };
-            mainGateway.Send(("Scene/GetAllInfo"), System.Text.Encoding.UTF8.GetBytes(jObject.ToString()));
+            if (useLocalConnect == false)
+            {
+                mainGateway.Send(("Scene/GetAllInfo"), System.Text.Encoding.UTF8.GetBytes(jObject.ToString()));
+            }
+            else
+            {
+                mainGateway.SendLocation(("Scene/GetAllInfo"), System.Text.Encoding.UTF8.GetBytes(jObject.ToString()));
+            }
 
             int waitTime = 20 * 6;
             while (receiptAll == false && TimeOut < waitTime)
@@ -229,30 +237,31 @@
         /// <param name="sceneName">鍦烘櫙鍚嶇О</param>
         /// <param name="listAdjustTarget">鎵ц鐩爣</param>
         /// <returns></returns>
-        public async Task<SceneUI> AddNewSceneToGateway(string sceneName, List<Scene.DeviceListData> listAdjustTarget)
+        public SceneUI AddNewSceneToGateway(string sceneName, List<Scene.DeviceListData> listAdjustTarget)
         {
             int NewScenesId = -1;
             //濡傛灉褰撳墠浣忓畢涓嶆槸铏氭嫙浣忓畢
-            if (Common.Config.Instance.Home.IsVirtually == false)
+            if (Config.Instance.Home.IsVirtually == false)
             {
-                var result1 = await Scene.GetSceneNewIdAsync(sceneName);
-                //鍏遍�氶敊璇娴�
-                string error = HdlCheckLogic.Current.CheckCommonErrorCode(result1);
-                if (error != null)
+                //鑾峰彇鏂板缓涓�涓満鏅殑鍛戒护瀛楃
+                var strCommand = this.GetAddNewSceneCommand(sceneName);
+                var result = HdlGatewayLogic.Current.SendJobjectDataToGateway(ZbGateway.MainGateWay, "Scene/GetNewId", strCommand, "Scene/GetNewId_Respon");
+                if (result.ErrorMsg != null)
                 {
-                    this.ShowErrorMsg(error);
+                    this.ShowTipMsg(result.ErrorMsg);
                     return null;
                 }
-                if (result1 == null || result1.getSceneIdData == null)
+                if (result.ErrorMsgDiv == 0)
                 {
                     //娣诲姞鍦烘櫙澶辫触
                     string msg1 = Language.StringByID(R.MyInternationalizationString.AddSceneFail);
                     //鎷兼帴涓娿�愮綉鍏冲洖澶嶈秴鏃躲�戠殑Msg
-                    msg1 = UserCenterLogic.CombineGatewayTimeOutMsg(msg1, result1);
+                    msg1 = UserCenterLogic.CombineGatewayTimeOutMsg(msg1, result);
                     this.ShowTipMsg(msg1);
                     return null;
                 }
-                NewScenesId = result1.getSceneIdData.NewScenesId;
+                var getSceneIdData = Newtonsoft.Json.JsonConvert.DeserializeObject<Scene.GetSceneIdData>(result.ReceiptData);
+                NewScenesId = getSceneIdData.NewScenesId;
             }
             else
             {
@@ -260,7 +269,7 @@
                 NewScenesId = Convert.ToInt32(DateTime.Now.ToString("HHmmss"));
             }
             //娣诲姞鎵ц鐩爣
-            var listSuccess = await this.AddTargetToScene(NewScenesId, listAdjustTarget);
+            var listSuccess = this.AddTargetToScene(NewScenesId, listAdjustTarget);
             if (listSuccess == null)
             {
                 return null;
@@ -280,12 +289,31 @@
         }
 
         /// <summary>
+        /// 鑾峰彇鏂板缓涓�涓満鏅殑鍛戒护瀛楃
+        /// </summary>
+        /// <param name="sceneName">鍦烘櫙鍚嶇О</param>
+        /// <returns></returns>
+        public string GetAddNewSceneCommand(string sceneName)
+        {
+            var bytes = new byte[32];
+            var reamarkGwBytes = Encoding.UTF8.GetBytes(sceneName);
+            Array.Copy(reamarkGwBytes, 0, bytes, 0, 32 < reamarkGwBytes.Length ? 32 : reamarkGwBytes.Length);
+            sceneName = Encoding.UTF8.GetString(bytes);
+
+            var jObject = new Newtonsoft.Json.Linq.JObject() { { "Cluster_ID", 0 }, { "Command", 800 } };
+            var data = new Newtonsoft.Json.Linq.JObject { { "ScenesName", sceneName } };
+            jObject.Add("Data", data);
+
+            return jObject.ToString();
+        }
+
+        /// <summary>
         /// 娣诲姞鎵ц鐩爣鍒版寚瀹氱殑鍦烘櫙(杩斿洖鎴愬姛娣诲姞鐨勬墽琛岀洰鏍�)
         /// </summary>
         /// <param name="sceneId">鍦烘櫙Id</param>
         /// <param name="listAdjustTarget">鎵ц鐩爣</param>
         /// <returns></returns>
-        private async Task<List<Scene.DeviceListData>> AddTargetToScene(int sceneId, List<Scene.DeviceListData> listAdjustTarget)
+        private List<Scene.DeviceListData> AddTargetToScene(int sceneId, List<Scene.DeviceListData> listAdjustTarget)
         {
             //濡傛灉褰撳墠浣忓畢鏄櫄鎷熶綇瀹呯殑璇�
             if (Common.Config.Instance.Home.IsVirtually == true)
@@ -294,48 +322,22 @@
                 return listAdjustTarget;
             }
             var listSuccess = new List<Scene.DeviceListData>();
-            for (int i = 0; i < listAdjustTarget.Count; i++)
-            {
-                var data = listAdjustTarget[i];
-                var addData = new Scene.AddSceneMemberData();
-                if (data.Type == 0)
-                {
-                    //璁惧
-                    addData.Type = 0;
-                    addData.ScenesId = sceneId;
-                    addData.DeviceAddr = data.DeviceAddr;
-                    addData.Epoint = data.Epoint;
-                    addData.TaskList = data.TaskList;
-                    addData.DelayTime = 0;
-                    addData.MemberNumber = i + 1;
-                }
-                else if (data.Type == 1)
-                {
-                    //鍦烘櫙
-                    addData.Type = 1;
-                    addData.ScenesId = sceneId;
-                    addData.ElseScenesId = data.ElseScenesId;
-                    addData.DelayTime = 0;
-                    addData.MemberNumber = i + 1;
-                }
-                else
-                {
-                    //寤舵椂
-                    addData.Type = 2;
-                    addData.ScenesId = sceneId;
-                    addData.DelayTime = data.DelayTime;
-                    addData.MemberNumber = i + 1;
-                }
 
-                //娣诲姞鏂版垚鍛� 杩斿洖缁撴灉
-                var result2 = await Scene.AddSceneMemberAsync(addData);
-                if (result2 == null || result2.addSceneMemberResponseData == null
-                    || result2.addSceneMemberResponseData.Result != 1)
+            //鑾峰彇娣诲姞鎵ц鐩爣鍒板満鏅殑鍛戒护
+            var listCommand = this.GetAddTargetToSceneCommand(sceneId, listAdjustTarget);
+            for (int i = 0; i < listCommand.Count; i++)
+            {
+                var result = HdlGatewayLogic.Current.SendJobjectDataToGateway(ZbGateway.MainGateWay, "Scene/AddMember", listCommand[i], "Scene/AddMember_Respon");
+                if (result.ErrorMsg != null || result.ErrorMsgDiv == 0)
                 {
+                    //鍑虹幇閿欒
                     continue;
                 }
-                //鎷ユ湁鎴愬姛鐨�
-                listSuccess.Add(data);
+                var addSceneMemberData = Newtonsoft.Json.JsonConvert.DeserializeObject<Scene.AddSceneMemberResponseData>(result.ReceiptData);
+                if (addSceneMemberData.Result == 1)
+                {
+                    listSuccess.Add(listAdjustTarget[i]);
+                }
             }
             if (listSuccess.Count == 0)
             {
@@ -355,6 +357,53 @@
         }
 
         /// <summary>
+        /// 鑾峰彇娣诲姞鎵ц鐩爣鍒板満鏅殑鍛戒护
+        /// </summary>
+        /// <param name="sceneId"></param>
+        /// <param name="listAdjustTarget"></param>
+        /// <returns></returns>
+        public List<string> GetAddTargetToSceneCommand(int sceneId, List<Scene.DeviceListData> listAdjustTarget)
+        {
+            var listCommand = new List<string>();
+            for (int i = 0; i < listAdjustTarget.Count; i++)
+            {
+                var jObject = new Newtonsoft.Json.Linq.JObject { { "Cluster_ID", 0 }, { "Command", 820 } };
+                var data = listAdjustTarget[i];
+                //璁惧
+                if (data.Type == 0)
+                {
+                    var taskList = new Newtonsoft.Json.Linq.JArray { };
+                    foreach (var taskInfo in data.TaskList)
+                    {
+                        var tInfo = new Newtonsoft.Json.Linq.JObject{{ "TaskType", taskInfo.TaskType},
+                            { "Data1", taskInfo.Data1},{ "Data2",taskInfo.Data2}};
+                        taskList.Add(tInfo);
+                    }
+                    var data2 = new Newtonsoft.Json.Linq.JObject {{ "ScenesId",sceneId},{ "Type", 0} ,{ "DeviceAddr",data.DeviceAddr} ,
+                         { "Epoint", data.Epoint} ,{ "TaskList", taskList },{ "DelayTime", 0} ,{ "MemberNumber",i + 1}};
+                    jObject.Add("Data", data2);
+                }
+                //鍦烘櫙
+                else if (data.Type == 1)
+                {
+                    var data2 = new Newtonsoft.Json.Linq.JObject {{ "ScenesId",sceneId},{ "Type", 1} ,
+                         { "ElseScenesId", data.ElseScenesId },{ "DelayTime", 0} ,{ "MemberNumber",i + 1} };
+                    jObject.Add("Data", data2);
+                }
+                //寤舵椂
+                else
+                {
+                    var data2 = new Newtonsoft.Json.Linq.JObject {{ "Type", 2} ,{ "ScenesId",sceneId},
+                         { "DelayTime", data.DelayTime} ,{ "MemberNumber",i + 1}};
+                    jObject.Add("Data", data2);
+                }
+                listCommand.Add(jObject.ToString());
+            }
+            return listCommand;
+        }
+
+
+        /// <summary>
         /// 娣诲姞鍦烘櫙(杩欎釜鍗曠函鍙敼鎴块棿)
         /// </summary>
         /// <param name="scene">Scene.</param>
@@ -366,29 +415,6 @@
                 i_room.ListSceneId.Add(scene.Id);
                 i_room.Save();
             }
-        }
-
-        /// <summary>
-        /// 鏀瑰彉鍦烘櫙鎴块棿
-        /// </summary>
-        /// <param name="scene">鍦烘櫙瀵硅薄</param>
-        /// <param name="newRoomId">鏂扮殑鎴块棿鐨処D</param>
-        public void ChangedSceneRoom(SceneUI scene, string newRoomId)
-        {
-            var room = HdlRoomLogic.Current.GetRoomBySceneId(scene.Id);
-            if (room != null)
-            {
-                //鎴块棿娌℃湁鏀瑰彉
-                if (room.Id == newRoomId)
-                {
-                    return;
-                }
-                //浠庢埧闂翠腑绉婚櫎缂撳瓨
-                this.DeleteSceneFromRoom(room, scene);
-            }
-            //娣诲姞杩涙柊鎴块棿
-            var newRoom = HdlRoomLogic.Current.GetRoomById(newRoomId);
-            this.AddSceneToRoom(newRoom, scene);
         }
 
         /// <summary>
@@ -517,7 +543,7 @@
             sceneUI.AdjustTargetList.Clear();
 
             //鐒跺悗閲嶆柊娣诲姞
-            var listSuccess = await this.AddTargetToScene(sceneUI.Id, listAdjustTarget);
+            var listSuccess = this.AddTargetToScene(sceneUI.Id, listAdjustTarget);
             if (listSuccess == null)
             {
                 return false;
@@ -891,7 +917,7 @@
         /// </summary>
         /// <param name="i_scene">鍦烘櫙瀵硅薄</param>
         /// <returns></returns>
-        public async Task<List<Scene.DeviceListData>> GetAdjustTargetList(SceneUI i_scene)
+        public List<Scene.DeviceListData> GetAdjustTargetList(SceneUI i_scene)
         {
             //濡傛灉浣忓畢涓鸿櫄鎷熶綇瀹�
             if (Common.Config.Instance.Home.IsVirtually == true)
@@ -900,16 +926,18 @@
                 listAdjustTarget.AddRange(i_scene.AdjustTargetList);
                 return listAdjustTarget;
             }
+            var jObject = new Newtonsoft.Json.Linq.JObject { { "Cluster_ID", 0 }, { "Command", 806 } };
+            var data = new Newtonsoft.Json.Linq.JObject { { "ScenesId", i_scene.Id } };
+            jObject.Add("Data", data);
+            //鍙戦�佸懡浠�
+            var result = HdlGatewayLogic.Current.SendJobjectDataToGateway(ZbGateway.MainGateWay, "Scene/GetDeviceList", jObject.ToString(), "Scene/GetDeviceList_Respon");
 
-            var result = await Scene.GetSceneDeviceListAsync(i_scene.Id);
-            //鍏遍�氶敊璇娴�
-            string error = HdlCheckLogic.Current.CheckCommonErrorCode(result);
-            if (error != null)
+            if (result.ErrorMsg != null)
             {
-                this.ShowErrorMsg(error);
+                this.ShowTipMsg(result.ErrorMsg);
                 return null;
             }
-            if (result == null || result.getSceneDeviceListInfo == null)
+            if (result.ErrorMsgDiv == 0)
             {
                 //鑾峰彇鎵ц鐩爣澶辫触
                 string msg = Language.StringByID(R.MyInternationalizationString.uGetAdjustTargetFail);
@@ -919,12 +947,14 @@
                 this.ShowTipMsg(msg);
                 return null;
             }
-            i_scene.AdjustTargetList = result.getSceneDeviceListInfo.DeviceList;
+            var sceneGetDeviceListObj = Newtonsoft.Json.JsonConvert.DeserializeObject<Scene.GetSceneDeviceListInfo>(result.ReceiptData);
+
+            i_scene.AdjustTargetList = sceneGetDeviceListObj.DeviceList;
             //淇濆瓨缂撳瓨
             i_scene.Save(false);
 
             var listData = new List<Scene.DeviceListData>();
-            listData.AddRange(result.getSceneDeviceListInfo.DeviceList);
+            listData.AddRange(sceneGetDeviceListObj.DeviceList);
 
             return listData;
         }
@@ -960,6 +990,29 @@
         #region 鈻� 涓�鑸柟娉昣__________________________
 
         /// <summary>
+        /// 鏀瑰彉鍦烘櫙鎴块棿
+        /// </summary>
+        /// <param name="scene">鍦烘櫙瀵硅薄</param>
+        /// <param name="newRoomId">鏂扮殑鎴块棿鐨処D</param>
+        public void ChangedSceneRoom(SceneUI scene, string newRoomId)
+        {
+            var room = HdlRoomLogic.Current.GetRoomBySceneId(scene.Id);
+            if (room != null)
+            {
+                //鎴块棿娌℃湁鏀瑰彉
+                if (room.Id == newRoomId)
+                {
+                    return;
+                }
+                //浠庢埧闂翠腑绉婚櫎缂撳瓨
+                this.DeleteSceneFromRoom(room, scene);
+            }
+            //娣诲姞杩涙柊鎴块棿
+            var newRoom = HdlRoomLogic.Current.GetRoomById(newRoomId);
+            this.AddSceneToRoom(newRoom, scene);
+        }
+
+        /// <summary>
         /// 鑾峰彇鏈湴鍏ㄩ儴鐨勫満鏅枃浠�
         /// </summary>
         /// <returns></returns>
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlWifiLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlWifiLogic.cs
index ce24a39..37fe00a 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlWifiLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/HdlWifiLogic.cs
@@ -160,6 +160,10 @@
                 return false;
             }
         }
+        /// <summary>
+        /// 鍙樻洿缃戠粶鏃剁殑浜嬩欢
+        /// </summary>
+        private string changedNetworkTime = string.Empty;
 
         #endregion
 
@@ -383,28 +387,78 @@
             {
                 //鍏佽鑱旂綉
                 this.CanAccessHttp = true;
+                this.changedNetworkTime = DateTime.Now.ToString("yyyyMMdd HH.mm.ss");
+                //褰撳墠鎵ц姝ょ嚎绋嬬殑鏃堕棿
+                string thisThreadTime = this.changedNetworkTime;
 
-                //妫�娴嬫槸鍚﹀凡缁忓畬鎴愯处鍙蜂俊鎭垵濮嬪寲
-                if (UserCenterResourse.UserInfo.InitUserInfoSuccess == false
-                   && Common.Config.Instance.HomeId != string.Empty)
+                HdlThreadLogic.Current.RunThread(() =>
                 {
-                    HdlThreadLogic.Current.RunThread(() =>
+                    //涓嶇濡備綍,閮借鏄剧ず杞湀
+                    ProgressBar.Show();
+
+                    //妫�娴嬫槸鍚﹀凡缁忓畬鎴愯处鍙蜂俊鎭垵濮嬪寲
+                    if (UserCenterResourse.UserInfo.InitUserInfoSuccess == false
+                       && Common.Config.Instance.HomeId != string.Empty)
                     {
-                        ProgressBar.Show();
                         //閲嶆柊鍒濆鍖栬处鍙蜂俊鎭�
                         UserCenterLogic.ReInitUserAccoutInfo();
-                        ProgressBar.Close();
+                        //鍥犱负涓婇潰杩欎釜涓滆タ鑰楁椂铔箙鐨�,鎵�浠ュ鐞嗗畬涔嬪悗杩涜鍒ゆ柇
+                        if (thisThreadTime != this.changedNetworkTime)
+                        {
+                            //鍦ㄥ鐞嗙殑杩囩▼涓�,鍒囨崲浜嗙綉缁�,鎶婁笅闈㈢殑澶勭悊浜ょ粰鍙﹀鐨勭嚎绋�
+                            return;
+                        }
+                    }
+                    //閲嶆柊鍒濆鍖朣ocket
+                    ZigBee.Common.Application.FindGateWaySocket.Stop();
+                    //鏂帀鏈湴杩炴帴
+                    HdlGatewayLogic.Current.ClearAllRealGateway();
+                    //鏂帀杩滅▼
+                    ZigBee.Device.ZbGateway.DisConnectRemoteMqttClient();
 
-                    }, ShowErrorMode.NO);
-                }
-                //閲嶆柊鍒濆鍖朣ocket
-                ZigBee.Common.Application.FindGateWaySocket.Stop();
-                if (value == 2)
-                {
-                    ZigBee.Common.Application.FindGateWaySocket.Start();
-                }
-                //鏂帀鏈湴杩炴帴
-                HdlGatewayLogic.Current.ClearAllRealGateway();
+                    if (value == 2)
+                    {
+                        ZigBee.Common.Application.FindGateWaySocket.Start();
+                        //鍊熺敤涓�涓嬭繖涓彉閲�(妫�娴嬭兘鍚﹀箍鎾埌缃戝叧)
+                        UserCenterResourse.DicReceiveGatewayTest = new Dictionary<string, ZigBee.Device.ZbGateway>();
+                        UserCenterResourse.HideOption.CheckCanReceiveGateway = 1;
+                        //鍥哄畾绛変釜3绉掑惂
+                        System.Threading.Thread.Sleep(2500);
+                        if (thisThreadTime != this.changedNetworkTime)
+                        {
+                            //鍙樻洿浜嗙綉缁�,浜ょ敱鍏朵粬绾跨▼澶勭悊
+                            return;
+                        }
+                        UserCenterResourse.HideOption.CheckCanReceiveGateway = 0;
+                        System.Threading.Thread.Sleep(500);
+
+                        bool canReceiveGw = false;
+                        foreach (var gateway in UserCenterResourse.DicReceiveGatewayTest.Values)
+                        {
+                            if (gateway.HomeId == Common.Config.Instance.Home.Id)
+                            {
+                                //鑳藉鎼滅储寰楀埌缃戝叧
+                                canReceiveGw = true;
+                                break;
+                            }
+                        }
+                        UserCenterResourse.DicReceiveGatewayTest = null;
+                        //璁剧疆杩滅▼杩炴帴鐨勫垵濮嬪��
+                        ZigBee.Device.ZbGateway.IsRemote = canReceiveGw == false;
+                        if (canReceiveGw == false)
+                        {
+                            //濡傛灉鏄繙绋嬬殑璇�,杩藉姞绛夊緟鏃堕棿(鎬诲叡5绉�)
+                            System.Threading.Thread.Sleep(2000);
+                        }
+                    }
+                    else if (value == 1)
+                    {
+                        //濡傛灉鏄�4G鐨勮瘽,鐩存帴绛夊緟
+                        System.Threading.Thread.Sleep(4500);
+                    }
+                    ProgressBar.Close();
+
+                }, ShowErrorMode.NO);
             }
         }
 
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/UserCenterLogic.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/UserCenterLogic.cs
index bf5c4b9..fb1ca0a 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/UserCenterLogic.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Logic/UserCenterLogic.cs
@@ -582,11 +582,11 @@
                 {
                     //璁惧畾涓�涓椂闂�
                     Config.Instance.LoginDateTime = new DateTime(1970, 1, 1);
-                    //娓呯┖褰撳墠浣忓畢id
-                    Config.Instance.HomeId = string.Empty;
                     Config.Instance.Save();
                     //鏀惰捣宸﹁彍鍗�
                     CommonPage.Instance.CloseLeftMenu();
+                    //鍏抽棴鍏ㄩ儴寮圭獥
+                    ShowMsgControl.CloseAllMsgDialog();
                     //鍏抽棴鎵�鏈夋墦寮�浜嗙殑鐣岄潰
                     CloseAllOpenForm();
 
@@ -792,6 +792,10 @@
             if (Common.Config.Instance.HomeId != UserCenterResourse.AccountOption.OldHomeStringId
                 || Common.Config.Instance.Account != UserCenterResourse.AccountOption.OldAccountId)
             {
+                //鍊熺敤涓�涓嬭繖涓彉閲�(妫�娴嬭兘鍚﹀箍鎾埌缃戝叧)
+                UserCenterResourse.DicReceiveGatewayTest = new Dictionary<string, ZigBee.Device.ZbGateway>();
+                UserCenterResourse.HideOption.CheckCanReceiveGateway = 1;
+
                 //娓呯┖鎵�鏈夋垚鍛樼紦瀛�
                 ClearAllMemberMemory();
 
@@ -804,6 +808,9 @@
                 //鍔犺浇浣忓畢閰嶇疆淇℃伅
                 UserCenterResourse.ResidenceOption = UserCenterResourse.ResidenceOption.Load();
 
+                //棰勫垱寤轰釜浜轰腑蹇冨叏閮ㄧ殑鏂囦欢澶�
+                HdlFileLogic.Current.CreatAllUserCenterDirectory();
+
                 //鍒濆鍖栫櫥闄嗚处鍙风殑淇℃伅
                 var hadNet = InitUserAccoutInfo(true);
                 //濡傛灉鏈夌綉缁滅殑璇�
@@ -814,8 +821,6 @@
                     //璇诲彇闅愬尶閰嶇疆
                     HdlBackupLogic.Current.LoadHideOption();
                 }
-                //棰勫垱寤轰釜浜轰腑蹇冨叏閮ㄧ殑鏂囦欢澶�
-                HdlFileLogic.Current.CreatAllUserCenterDirectory();
 
                 //鍏抽棴鎵�鏈夋帴鏀�
                 HdlGatewayReceiveLogic.Current.RemoveAllEvent();
@@ -867,6 +872,36 @@
                 }
                 //鏄剧ず寮曞鐣岄潰
                 ShowGuideForm(result);
+
+                //鍏抽棴debug骞挎挱
+                UserCenterResourse.HideOption.CheckCanReceiveGateway = 0;
+                System.Threading.Thread.Sleep(30);
+                if (hadNet == 1)
+                {
+                    try
+                    {
+                        bool canReceiveGw = false;
+                        foreach (var gateway in UserCenterResourse.DicReceiveGatewayTest.Values)
+                        {
+                            if (gateway.HomeId == Config.Instance.Home.Id)
+                            {
+                                //鑳藉鎼滅储寰楀埌缃戝叧
+                                canReceiveGw = true;
+                                break;
+                            }
+                        }
+                        UserCenterResourse.DicReceiveGatewayTest = null;
+                        //璁剧疆杩滅▼杩炴帴鐨勫垵濮嬪��
+                        ZigBee.Device.ZbGateway.IsRemote = canReceiveGw == false;
+                        if (canReceiveGw == false)
+                        {
+                            //濡傛灉鏄繙绋嬬殑璇�,杩藉姞绛夊緟鏃堕棿
+                            System.Threading.Thread.Sleep(1500);
+                        }
+                    }
+                    catch { }
+                }
+                UserCenterResourse.DicReceiveGatewayTest = null;
             }
             //APP缂撳瓨鍔犺浇瀹屾垚
             UserCenterResourse.AccountOption.AppCanSignout = true;
@@ -1022,7 +1057,7 @@
             if (UserCenterResourse.UserInfo.HeadImage != null)
             {
                 //鍐欏叆澶村儚鍐呭
-                Shared.IO.FileUtils.WriteFileByBytes(UserCenterResourse.UserInfo.UserIconFile, UserCenterResourse.UserInfo.HeadImage);
+                HdlFileLogic.Current.SaveByteToFile(UserCenterResourse.UserInfo.UserIconFile, UserCenterResourse.UserInfo.HeadImage);
             }
             UserCenterResourse.UserInfo.HeadImage = null;
             //鎵嬪娍瀵嗙爜
@@ -1246,7 +1281,7 @@
         {
             try
             {
-                if (strPsw == string.Empty)
+                if (string.IsNullOrEmpty(strPsw) == true)
                 {
                     return strPsw;
                 }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Resourse/DirectoryFileNameResourse.cs b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Resourse/DirectoryFileNameResourse.cs
index b1d5862..4771a28 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Resourse/DirectoryFileNameResourse.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/CommonBase/Resourse/DirectoryFileNameResourse.cs
@@ -165,6 +165,13 @@
             get { return System.IO.Path.Combine(Shared.IO.FileUtils.RootPath, "cad1afb384fb482de753fc37ebe84f9e"); }
         }
         /// <summary>
+        /// 璋冭瘯鏋佸厜鍙戦�両D鐨勩�愭枃浠躲��
+        /// </summary>
+        public static string JiguangFile
+        {
+            get { return System.IO.Path.Combine(Shared.IO.FileUtils.RootPath, "e509ddd21100cb994f509fb28c2e4dd6"); }
+        }
+        /// <summary>
         /// 璁板綍鍙戦�佸拰鎺ユ敹鐨勬暟鎹甃og
         /// </summary>
         public static string SendAndReceveDataLog
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceGeneralInformationForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceGeneralInformationForm.cs
index 86eabac..0276008 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceGeneralInformationForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceGeneralInformationForm.cs
@@ -63,7 +63,7 @@
             }
             else
             {
-                rowName.AddMostRightView(Language.StringByID(myInfoType.ConcreteTextId), 600);
+                rowName.AddMostRightView(myInfoType.ConcreteText, 600);
             }
             rowName.AddBottomLine();
 
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceHistoryFirmwareVersionForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceHistoryFirmwareVersionForm.cs
index 3883568..b63e4ef 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceHistoryFirmwareVersionForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceHistoryFirmwareVersionForm.cs
@@ -70,7 +70,7 @@
             HdlThreadLogic.Current.RunThread(() =>
             {
                 string ImagType = oTADevice.ImgTypeId.ToString();
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     foreach (var data in listData)
                     {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceListMainForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceListMainForm.cs
index 1c30f0e..568ce9c 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceListMainForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceListMainForm.cs
@@ -625,7 +625,7 @@
         {
             lock (dicRowInfo)
             {
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     if (this.listView == null)
                     {
@@ -717,7 +717,7 @@
             }
 
             //鑾峰彇鍏ㄩ儴璁惧
-            int result = LocalDevice.Current.SetDeviceToMemmoryByGateway(nowGateway);
+            int result = LocalDevice.Current.SetDeviceToMemmoryByGateway(nowGateway, false);
             if (this.Parent == null)
             {
                 return;
@@ -754,7 +754,7 @@
                 //鍒锋柊缃戝叧鍦ㄧ嚎鐘舵��
                 HdlGatewayLogic.Current.RefreshGatewayOnlineStatu(new List<ZbGateway>() { zbGateway });
 
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     if (this.gatewayViewRow != null && this.gatewayViewRow.zbGatewayId == selectGwId)
                     {
@@ -782,7 +782,7 @@
             }
             if (gateWay.GwId == this.gatewayViewRow.zbGatewayId)
             {
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     //鐩稿悓鐨勭姸鎬�,涓嶉渶瑕佸啀娆″埛鏂�
                     if (this.gatewayViewRow.isOnline != online)
@@ -848,7 +848,7 @@
                                 this.ReceiveDeviceStatu(device);
                             }, ShowErrorMode.NO);
                         }
-                        System.Threading.Thread.Sleep(30);
+                        System.Threading.Thread.Sleep(50);
                     }
                 }
             });
@@ -1034,14 +1034,27 @@
         {
             if (this.dicRowInfo.ContainsKey(deviceAddr) == true)
             {
-                var row = this.dicRowInfo[deviceAddr];
-                row.MenuRow?.RefreshControlInfo(true);
-                //鏄庣粏
-                if (row.dicDetailRow != null)
+                var rowInfo = this.dicRowInfo[deviceAddr];
+                //妫�娴嬭繖涓澶囨槸鍚﹁鍒犻櫎 2020.01.13鍙樻洿:杩藉姞Ota璁惧鐨勫垽鏂�
+                if (LocalDevice.Current.GetDevicesByMac(deviceAddr).Count == 0
+                    && LocalDevice.Current.GetOTADevice(deviceAddr) == null)
                 {
-                    foreach (var detailRow in row.dicDetailRow.Values)
+                    //绉婚櫎鎺т欢
+                    rowInfo.dicDetailRow = null;
+                    rowInfo.frameTable.RemoveFromParent();
+
+                    this.dicRowInfo.Remove(deviceAddr);
+                }
+                else
+                {
+                    //鍒锋柊璁惧淇℃伅
+                    rowInfo.MenuRow?.RefreshControlInfo(true);
+                    if (rowInfo.dicDetailRow != null)
                     {
-                        detailRow.RefreshControlInfo();
+                        foreach (var contr in rowInfo.dicDetailRow.Values)
+                        {
+                            contr?.RefreshControlInfo();
+                        }
                     }
                 }
             }
@@ -1107,30 +1120,8 @@
         {
             if (this.nowActionDeviceMac != null)
             {
-                var rowInfo = this.dicRowInfo[nowActionDeviceMac];
-                //妫�娴嬭繖涓澶囨槸鍚﹁鍒犻櫎 2020.01.13鍙樻洿:杩藉姞Ota璁惧鐨勫垽鏂�
-                if (Common.LocalDevice.Current.GetDevicesByMac(nowActionDeviceMac).Count == 0
-                    && Common.LocalDevice.Current.GetOTADevice(nowActionDeviceMac) == null)
-                {
-                    //绉婚櫎鎺т欢
-                    rowInfo.dicDetailRow = null;
-                    rowInfo.frameTable.RemoveFromParent();
-
-                    this.dicRowInfo.Remove(nowActionDeviceMac);
-                    rowInfo = null;
-                }
-                else
-                {
-                    //鍒锋柊璁惧淇℃伅
-                    rowInfo.MenuRow?.RefreshControlInfo(true);
-                    if (rowInfo.dicDetailRow != null)
-                    {
-                        foreach (var contr in rowInfo.dicDetailRow.Values)
-                        {
-                            contr?.RefreshControlInfo();
-                        }
-                    }
-                }
+                //鍒锋柊鎸囧畾璁惧琛岀殑淇℃伅
+                this.RefreshDeviceRow(this.nowActionDeviceMac);
             }
             //娓呯┖璁板綍
             this.nowActionDeviceMac = null;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs
index 1bd57b2..6d3c85d 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceMacInfoEditorForm.cs
@@ -713,8 +713,7 @@
         private void AddPirSensorWorkModeRow()
         {
             if (this.deviceEnumInfo.ConcreteType != DeviceConcreteType.Sensor_Pir
-                || deviceEnumInfo.IsHdlDevice == false
-                || this.listNewDevice.Count != 2)
+                || deviceEnumInfo.IsHdlDevice == false)
             {
                 return;
             }
@@ -743,8 +742,7 @@
         /// </summary>
         private void AddPirSensorBindRow()
         {
-            if (this.deviceEnumInfo.ConcreteType != DeviceConcreteType.Sensor_Pir
-                || this.listNewDevice.Count != 2)
+            if (this.deviceEnumInfo.ConcreteType != DeviceConcreteType.Sensor_Pir)
             {
                 return;
             }
@@ -1078,7 +1076,7 @@
                 paneTargetsBaseFormp.Show();
                 paneTargetsBaseFormp.actionHumidityTarget += (bindName) =>
                 {
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (string.IsNullOrEmpty(bindName))
                         {
@@ -1129,7 +1127,7 @@
                 paneTargetsBaseFormp.Show();
                 paneTargetsBaseFormp.actionTemperatureTarget += (bindName) =>
                 {
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (string.IsNullOrEmpty(bindName))
                         {
@@ -1439,13 +1437,13 @@
 
                 if (deviceFirmware != null && deviceFirmware.FirmwareVersion > oTADevice.ImgVersion)
                 {
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (btnNewVersion != null)
                         {
                             btnNewVersion.Visible = true;
                         }
-                    });
+                    }, ShowErrorMode.NO);
                 }
             });
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceSearchForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceSearchForm.cs
index d456bd7..b428f18 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceSearchForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/DeviceSearchForm.cs
@@ -141,7 +141,7 @@
                 //鍋滄鎺ユ敹
                 this.realGateway.GwResDataAction -= this.AdjustGatewayResultData;
 
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     this.CloseForm();
                 });
@@ -175,6 +175,7 @@
             device.CurrentGateWayId = this.realGateway.GwId;
             //灏咲eviceInfo鐨勫睘鎬ц缃埌涓诲睘鎬т腑
             Common.LocalDevice.Current.SetDeviceInfoToMain(device, device);
+            Common.LocalDevice.Current.RefreshDeviceFunctionType(device, device, true);
 
             //娣诲姞璁惧鐨勭紦瀛�
             device.IsOnline = 1;
@@ -222,7 +223,7 @@
                 System.Threading.Thread.Sleep(200);
 
                 //鐩墠灏卞紕涓�涓�
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     var listDevice = new List<CommonDevice>();
                     for (int i = 0; i < this.listNewDevice.Count; i++)
@@ -315,7 +316,7 @@
                             timeCount = 0;
                         }
                     }
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (btnRound != null)
                         {
@@ -468,7 +469,7 @@
                 {
                     //鍝嶅簲瓒呮椂,璇烽噸鏂板叆缃�
                     this.ShowMassage(ShowMsgType.Tip, Language.StringByID(R.MyInternationalizationString.uResponseTimeoutsAndReAccessNetwork));
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         //鍏抽棴鐣岄潰
                         this.CloseForm();
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Device/Panel/PanelColorSelectForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Device/Panel/PanelColorSelectForm.cs
index 304bd26..85c4f68 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Device/Panel/PanelColorSelectForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Device/Panel/PanelColorSelectForm.cs
@@ -45,6 +45,8 @@
         /// <param name="i_B">B</param>
         public void ShowForm(int i_R,int i_G,int i_B)
         {
+            this.ScrollEnabled = false;
+
             //璁剧疆澶撮儴淇℃伅
             base.SetTitleText(Language.StringByID(R.MyInternationalizationString.uSelectColor));
 
@@ -119,8 +121,16 @@
             btnWhiteView.Radius = (uint)this.GetPictrueRealSize(30) / 2;
             framePic.AddChidren(btnWhiteView);
 
+            bool pointIsRight = false;
+            //鍦嗙殑鍗婂緞
+            int circleR = framePic.Width / 2 - this.GetPictrueRealSize(35);
             colorPic.ColorChaged += (sender, eColor) =>
             {
+                if (pointIsRight == false)
+                {
+                    //鐐圭殑鍖哄煙涓嶆槸鍦嗙洏鍐�
+                    return;
+                }
                 listRGB = new List<int>();
                 listRGB.Add(Convert.ToInt32(Convert.ToString(eColor[0])));
                 listRGB.Add(Convert.ToInt32(Convert.ToString(eColor[1])));
@@ -138,13 +148,24 @@
             };
             colorPic.MouseDownEventHandler += (sender, e) =>
             {
+                pointIsRight = this.CheckPoint(circleR, framePic.Width / 2, framePic.Height / 2, (int)e.X, (int)e.Y);
+                if (pointIsRight == false)
+                {
+                    //鐐圭殑鍖哄煙涓嶆槸鍦嗙洏鍐�
+                    return;
+                }
                 //鏄剧ず鐧界偣
-                btnWhiteView.X = (int)e.X;
-                btnWhiteView.Y = (int)e.Y;
+                btnWhiteView.X = (int)e.X - btnWhiteView.Width / 2;
+                btnWhiteView.Y = (int)e.Y - btnWhiteView.Height / 2;
                 if (btnWhiteView.Visible == false)
                 {
                     btnWhiteView.Visible = true;
                 }
+            };
+            colorPic.MouseMoveEventHandler += (sender, e) =>
+            {
+                //褰撻紶鏍囩偣涓嬩簨浠跺鐞�
+                colorPic.MouseDownEventHandler(sender, e);
             };
         }
 
@@ -229,6 +250,35 @@
         #region 鈻� 涓�鑸柟娉昣__________________________
 
         /// <summary>
+        /// 妫�娴嬬偣鍑荤偣
+        /// </summary>
+        /// <param name="circleR">鍦嗙殑鍗婂緞</param>
+        /// <param name="circleX">鍦嗗績X杞�</param>
+        /// <param name="circleY">鍦嗗績Y杞�</param>
+        /// <param name="pointX">鐐瑰嚮鐐圭殑X杞�</param>
+        /// <param name="pointY">鐐瑰嚮鐐圭殑Y杞�</param>
+        /// <returns></returns>
+        private bool CheckPoint(int circleR, int circleX, int circleY, int pointX, int pointY)
+        {
+            int dwidth = circleX - pointX;
+            if (dwidth < 0) { dwidth *= -1; }
+
+            int dHeight = circleY - pointY;
+            if (dHeight < 0) { dHeight *= -1; }
+
+            //鏍规嵁涓夎鍑芥暟,姹備笁瑙掑舰鐨勬枩杈归暱
+            int dlength = dwidth * dwidth + dHeight * dHeight;
+            //鍗婂緞闀垮害(涓嶅紑鏂�,鎵�浠ユ槸鎸夊钩鏂圭畻)
+            circleR *= circleR;
+            if (dlength < circleR)
+            {
+                //濡傛灉缁勬垚鐨勪笁瑙掑舰骞舵病鏈夐暱杩囧崐寰�,鍒欎唬琛ㄨ繕鍦ㄥ渾鍐�(涓嶅厑璁哥偣杈圭晫)
+                return true;
+            }
+            return false;
+        }
+
+        /// <summary>
         /// 鍒濆鍖栧鐢ㄩ鑹茬殑榛樿鍊�
         /// </summary>
         /// <returns></returns>
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewaySearchForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewaySearchForm.cs
index a2268ae..f19425c 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewaySearchForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/MiniGatewaySearchForm.cs
@@ -266,7 +266,7 @@
                         break;
                     }
 
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         btnRound.X = listPoint[index];
                         index++;
@@ -276,14 +276,15 @@
                         }
                         //姝e湪鎼滅储缃戝叧鈥Xs
                         btnMsg.Text = strMsg + timeOut + "s";
-                    });
+                    }, ShowErrorMode.NO);
 
                     System.Threading.Thread.Sleep(500);
                 }
                 //鎼滅储缁撴潫
                 this.isGatewaySearching = false;
 
-                if (timeOut <= 0)
+                //2020.07.14杩藉姞:鍊掕鏃剁粨鏉熸椂,鍝�曟槸宸茬粡缁戝畾浜嗙殑缃戝叧,涔熸樉绀哄嚭鏉�
+                if (timeOut <= 0 && listZbGateway.Count == 0)
                 {
                     HdlThreadLogic.Current.RunMain(() =>
                     {
@@ -291,7 +292,7 @@
                         this.InitFailMiddleFrame();
                     });
                 }
-                else if (newGatewayGetting == true)
+                else if (newGatewayGetting == true || listZbGateway.Count > 0)
                 {
                     HdlThreadLogic.Current.RunMain(() =>
                     {
@@ -357,21 +358,30 @@
                 }
 
                 //缃戝叧缁戝畾妯″紡
-                GatewayBindMode mode = GatewayBindMode.BindAgain;
-                //濡傛灉鏄涓�娆$粦瀹�,鎴栬�呮槸浠ュ墠宸茬粡缁戝畾杩囦簡鐨�
-                if (HdlGatewayLogic.Current.HomeIdIsEmpty(way) == true
-                    || way.HomeId == Common.Config.Instance.HomeId)
+                var mode = GatewayBindMode.BindAgain;
+                //浣忓畢ID涓虹┖ 绗竴娆$粦瀹�
+                if (HdlGatewayLogic.Current.HomeIdIsEmpty(way) == true)
                 {
-                    if (way.HomeId != Common.Config.Instance.HomeId)
-                    {
-                        //绗竴娆$粦瀹�,涔熷氨鏄綉鍏充綇瀹匢D涓虹┖
-                        mode = GatewayBindMode.First;
-                    }
-                    else
-                    {
-                        //宸茬粡缁戝畾杩囦簡
-                        mode = GatewayBindMode.Binded;
-                    }
+                    mode = GatewayBindMode.First;
+                }
+                //浣忓畢ID涓嶇浉绛� 闇�瑕侀噸鏂扮粦瀹�
+                else if (way.HomeId != Common.Config.Instance.HomeId)
+                {
+                    mode = GatewayBindMode.BindAgain;
+                }
+                //濡傛灉鏈湴涓嶅瓨鍦ㄧ殑璇�,褰撳仛绗竴娆$粦瀹氬鐞�
+                else if (HdlGatewayLogic.Current.IsGatewayExist(way) == false)
+                {
+                    mode = GatewayBindMode.First;
+                }
+                //浣忓畢ID涓�鏍�,鍒欐槸宸茬粡缁戝畾杩囦簡
+                else
+                {
+                    mode = GatewayBindMode.Binded;
+                }
+                //杩欎袱绉嶆儏鍐甸兘鏄渶瑕侀噸鏂版坊鍔�(宸茬粡缁戝畾杩囦簡鐨�,鏈夊彲鑳戒綇瀹匢D娌″啓杩涘幓,瀹冩湁鍙兘鏄汉涓虹殑娓呯┖浣忓畢ID)
+                if (mode == GatewayBindMode.First || mode == GatewayBindMode.Binded)
+                {
                     //娣诲姞鎼滅储鍒扮殑缃戝叧鍒扮紦瀛�(鎵ц缃戝叧淇濆瓨鎿嶄綔)
                     var result = await HdlGatewayLogic.Current.AddNewGateway(way, ShowErrorMode.NO);
                     if (result == false)
@@ -403,10 +413,15 @@
                     this.newGatewayGetting = true;
                 }
 
-                if (mode == GatewayBindMode.First|| mode == GatewayBindMode.Binded)
+                if (mode == GatewayBindMode.First || mode == GatewayBindMode.Binded)
                 {
                     //鎴戣寰楄繖閲岄渶瑕佽幏鍙栦竴涓嬫柊缃戝叧鐨勮澶囧垪琛�
-                    Common.LocalDevice.Current.SetDeviceToMemmoryByGateway(way);
+                    Common.LocalDevice.Current.SetDeviceToMemmoryByGateway(way, true);
+                    if (way.IsMainGateWay == true)
+                    {
+                        //濡傛灉瀹冩槸涓荤綉鍏�,鍒欏埛鏂板満鏅垪琛�
+                        HdlSceneLogic.Current.RefreshSceneUIList(true);
+                    }
                 }
             }
             return true;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewaySearchForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewaySearchForm.cs
index 448ff57..726b27a 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewaySearchForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WiredGatewaySearchForm.cs
@@ -244,7 +244,7 @@
                         //鑾峰彇寰楀埌鏂扮綉鍏�,鍒欎腑鏂嚎绋�
                         break;
                     }
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         btnRound.X = listPoint[index];
                         index++;
@@ -254,12 +254,13 @@
                         }
                         //姝e湪鎼滅储缃戝叧鈥Xs
                         btnMsg.Text = strMsg + timeCount + "s";
-                    });
+                    }, ShowErrorMode.NO);
                 }
                 //鎼滅储缁撴潫
                 this.isGatewaySearching = false;
 
-                if (maxCount <= 0)
+                //2020.07.14杩藉姞:鍊掕鏃剁粨鏉熸椂,鍝�曟槸宸茬粡缁戝畾浜嗙殑缃戝叧,涔熸樉绀哄嚭鏉�
+                if (maxCount <= 0 && listZbGateway.Count == 0)
                 {
                     HdlThreadLogic.Current.RunMain(() =>
                     {
@@ -267,7 +268,7 @@
                         this.InitFailMiddleFrame();
                     });
                 }
-                else if (newGatewayGetting == true)
+                else if (newGatewayGetting == true || listZbGateway.Count > 0)
                 {
                     HdlThreadLogic.Current.RunMain(() =>
                     {
@@ -363,24 +364,31 @@
                 }
 
                 //缃戝叧缁戝畾妯″紡
-                GatewayBindMode mode = GatewayBindMode.BindAgain;
-                //濡傛灉鏄涓�娆$粦瀹�,鎴栬�呮槸浠ュ墠宸茬粡缁戝畾杩囦簡鐨�
-                if (HdlGatewayLogic.Current.HomeIdIsEmpty(way) == true
-                    || way.HomeId == Common.Config.Instance.HomeId)
+                var mode = GatewayBindMode.BindAgain;
+                //浣忓畢ID涓虹┖ 绗竴娆$粦瀹�
+                if (HdlGatewayLogic.Current.HomeIdIsEmpty(way) == true)
                 {
-                    if (way.HomeId != Common.Config.Instance.HomeId)
-                    {
-                        //绗竴娆$粦瀹�,涔熷氨鏄綉鍏充綇瀹匢D涓虹┖
-                        mode = GatewayBindMode.First;
-                    }
-                    else
-                    {
-                        //宸茬粡缁戝畾杩囦簡
-                        mode = GatewayBindMode.Binded;
-                    }
-
+                    mode = GatewayBindMode.First;
+                }
+                //浣忓畢ID涓嶇浉绛� 闇�瑕侀噸鏂扮粦瀹�
+                else if (way.HomeId != Common.Config.Instance.HomeId)
+                {
+                    mode = GatewayBindMode.BindAgain;
+                }
+                //濡傛灉鏈湴涓嶅瓨鍦ㄧ殑璇�,褰撳仛绗竴娆$粦瀹氬鐞�
+                else if (HdlGatewayLogic.Current.IsGatewayExist(way) == false)
+                {
+                    mode = GatewayBindMode.First;
+                }
+                //浣忓畢ID涓�鏍�,鍒欐槸宸茬粡缁戝畾杩囦簡
+                else
+                {
+                    mode = GatewayBindMode.Binded;
+                }
+                //杩欎袱绉嶆儏鍐甸兘鏄渶瑕侀噸鏂版坊鍔�(宸茬粡缁戝畾杩囦簡鐨�,鏈夊彲鑳戒綇瀹匢D娌″啓杩涘幓,瀹冩湁鍙兘鏄汉涓虹殑娓呯┖浣忓畢ID)
+                if (mode == GatewayBindMode.First || mode == GatewayBindMode.Binded)
+                {
                     //娣诲姞鎼滅储鍒扮殑缃戝叧鍒扮紦瀛�(鎵ц缃戝叧淇濆瓨鎿嶄綔)
-                    ShowErrorMode showMode = this.dicIdCheckCount[listId[i]] == 0 ? ShowErrorMode.YES : ShowErrorMode.NO;
                     var result = await HdlGatewayLogic.Current.AddNewGateway(way, ShowErrorMode.NO);
                     if (result == false)
                     {
@@ -416,7 +424,12 @@
                 if (mode == GatewayBindMode.First || mode == GatewayBindMode.Binded)
                 {
                     //鎴戣寰楄繖閲岄渶瑕佽幏鍙栦竴涓嬫柊缃戝叧鐨勮澶囧垪琛�
-                    Common.LocalDevice.Current.SetDeviceToMemmoryByGateway(way);
+                    Common.LocalDevice.Current.SetDeviceToMemmoryByGateway(way, true);
+                    if (way.IsMainGateWay == true)
+                    {
+                        //濡傛灉瀹冩槸涓荤綉鍏�,鍒欏埛鏂板満鏅垪琛�
+                        HdlSceneLogic.Current.RefreshSceneUIList(true);
+                    }
                 }
             }
             return true;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessApSearchForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessApSearchForm.cs
index 6e36d1d..3b35e26 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessApSearchForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessApSearchForm.cs
@@ -262,7 +262,7 @@
                         break;
                     }
 
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         btnRound.X = listPoint[index];
                         index++;
@@ -272,14 +272,15 @@
                         }
                         //姝e湪鎼滅储缃戝叧鈥Xs
                         btnMsg.Text = strMsg + timeOut + "s";
-                    });
+                    }, ShowErrorMode.NO);
 
                     System.Threading.Thread.Sleep(500);
                 }
                 //鎼滅储缁撴潫
                 this.isGatewaySearching = false;
 
-                if (timeOut <= 0)
+                //2020.07.14杩藉姞:鍊掕鏃剁粨鏉熸椂,鍝�曟槸宸茬粡缁戝畾浜嗙殑缃戝叧,涔熸樉绀哄嚭鏉�
+                if (timeOut <= 0 && listZbGateway.Count == 0)
                 {
                     HdlThreadLogic.Current.RunMain(() =>
                     {
@@ -287,7 +288,7 @@
                         this.InitFailMiddleFrame();
                     });
                 }
-                else if (newGatewayGetting == true)
+                else if (newGatewayGetting == true || listZbGateway.Count > 0)
                 {
                     HdlThreadLogic.Current.RunMain(() =>
                     {
@@ -353,21 +354,30 @@
                 }
 
                 //缃戝叧缁戝畾妯″紡
-                GatewayBindMode mode = GatewayBindMode.BindAgain;
-                //濡傛灉鏄涓�娆$粦瀹�,鎴栬�呮槸浠ュ墠宸茬粡缁戝畾杩囦簡鐨�
-                if (HdlGatewayLogic.Current.HomeIdIsEmpty(way) == true
-                    || way.HomeId == Common.Config.Instance.HomeId)
+                var mode = GatewayBindMode.BindAgain;
+                //浣忓畢ID涓虹┖ 绗竴娆$粦瀹�
+                if (HdlGatewayLogic.Current.HomeIdIsEmpty(way) == true)
                 {
-                    if (way.HomeId != Common.Config.Instance.HomeId)
-                    {
-                        //绗竴娆$粦瀹�,涔熷氨鏄綉鍏充綇瀹匢D涓虹┖
-                        mode = GatewayBindMode.First;
-                    }
-                    else
-                    {
-                        //宸茬粡缁戝畾杩囦簡
-                        mode = GatewayBindMode.Binded;
-                    }
+                    mode = GatewayBindMode.First;
+                }
+                //浣忓畢ID涓嶇浉绛� 闇�瑕侀噸鏂扮粦瀹�
+                else if (way.HomeId != Common.Config.Instance.HomeId)
+                {
+                    mode = GatewayBindMode.BindAgain;
+                }
+                //濡傛灉鏈湴涓嶅瓨鍦ㄧ殑璇�,褰撳仛绗竴娆$粦瀹氬鐞�
+                else if (HdlGatewayLogic.Current.IsGatewayExist(way) == false)
+                {
+                    mode = GatewayBindMode.First;
+                }
+                //浣忓畢ID涓�鏍�,鍒欐槸宸茬粡缁戝畾杩囦簡
+                else
+                {
+                    mode = GatewayBindMode.Binded;
+                }
+                //杩欎袱绉嶆儏鍐甸兘鏄渶瑕侀噸鏂版坊鍔�(宸茬粡缁戝畾杩囦簡鐨�,鏈夊彲鑳戒綇瀹匢D娌″啓杩涘幓,瀹冩湁鍙兘鏄汉涓虹殑娓呯┖浣忓畢ID)
+                if (mode == GatewayBindMode.First || mode == GatewayBindMode.Binded)
+                {
                     //娣诲姞鎼滅储鍒扮殑缃戝叧鍒扮紦瀛�(鎵ц缃戝叧淇濆瓨鎿嶄綔)
                     var result = await HdlGatewayLogic.Current.AddNewGateway(way, ShowErrorMode.NO);
                     if (result == false)
@@ -402,7 +412,12 @@
                 if (mode == GatewayBindMode.First || mode == GatewayBindMode.Binded)
                 {
                     //鎴戣寰楄繖閲岄渶瑕佽幏鍙栦竴涓嬫柊缃戝叧鐨勮澶囧垪琛�
-                    Common.LocalDevice.Current.SetDeviceToMemmoryByGateway(way);
+                    Common.LocalDevice.Current.SetDeviceToMemmoryByGateway(way, true);
+                    if (way.IsMainGateWay == true)
+                    {
+                        //濡傛灉瀹冩槸涓荤綉鍏�,鍒欏埛鏂板満鏅垪琛�
+                        HdlSceneLogic.Current.RefreshSceneUIList(true);
+                    }
                 }
             }
             return true;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessUdpSearchForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessUdpSearchForm.cs
index bb2cbff..73e09d6 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessUdpSearchForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Add/WirelessUdpSearchForm.cs
@@ -262,7 +262,7 @@
                         break;
                     }
 
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         btnRound.X = listPoint[index];
                         index++;
@@ -272,14 +272,15 @@
                         }
                         //姝e湪鎼滅储缃戝叧鈥Xs
                         btnMsg.Text = strMsg + timeOut + "s";
-                    });
+                    }, ShowErrorMode.NO);
 
                     System.Threading.Thread.Sleep(500);
                 }
                 //鎼滅储缁撴潫
                 this.isGatewaySearching = false;
 
-                if (timeOut <= 0)
+                //2020.07.14杩藉姞:鍊掕鏃剁粨鏉熸椂,鍝�曟槸宸茬粡缁戝畾浜嗙殑缃戝叧,涔熸樉绀哄嚭鏉�
+                if (timeOut <= 0 && listZbGateway.Count == 0)
                 {
                     HdlThreadLogic.Current.RunMain(() =>
                     {
@@ -287,7 +288,7 @@
                         this.InitFailMiddleFrame();
                     });
                 }
-                else if (newGatewayGetting == true)
+                else if (newGatewayGetting == true || listZbGateway.Count > 0)
                 {
                     HdlThreadLogic.Current.RunMain(() =>
                     {
@@ -353,21 +354,30 @@
                 }
 
                 //缃戝叧缁戝畾妯″紡
-                GatewayBindMode mode = GatewayBindMode.BindAgain;
-                //濡傛灉鏄涓�娆$粦瀹�,鎴栬�呮槸浠ュ墠宸茬粡缁戝畾杩囦簡鐨�
-                if (HdlGatewayLogic.Current.HomeIdIsEmpty(way) == true
-                    || way.HomeId == Common.Config.Instance.HomeId)
+                var mode = GatewayBindMode.BindAgain;
+                //浣忓畢ID涓虹┖ 绗竴娆$粦瀹�
+                if (HdlGatewayLogic.Current.HomeIdIsEmpty(way) == true)
                 {
-                    if (way.HomeId != Common.Config.Instance.HomeId)
-                    {
-                        //绗竴娆$粦瀹�,涔熷氨鏄綉鍏充綇瀹匢D涓虹┖
-                        mode = GatewayBindMode.First;
-                    }
-                    else
-                    {
-                        //宸茬粡缁戝畾杩囦簡
-                        mode = GatewayBindMode.Binded;
-                    }
+                    mode = GatewayBindMode.First;
+                }
+                //浣忓畢ID涓嶇浉绛� 闇�瑕侀噸鏂扮粦瀹�
+                else if (way.HomeId != Common.Config.Instance.HomeId)
+                {
+                    mode = GatewayBindMode.BindAgain;
+                }
+                //濡傛灉鏈湴涓嶅瓨鍦ㄧ殑璇�,褰撳仛绗竴娆$粦瀹氬鐞�
+                else if (HdlGatewayLogic.Current.IsGatewayExist(way) == false)
+                {
+                    mode = GatewayBindMode.First;
+                }
+                //浣忓畢ID涓�鏍�,鍒欐槸宸茬粡缁戝畾杩囦簡
+                else
+                {
+                    mode = GatewayBindMode.Binded;
+                }
+                //杩欎袱绉嶆儏鍐甸兘鏄渶瑕侀噸鏂版坊鍔�(宸茬粡缁戝畾杩囦簡鐨�,鏈夊彲鑳戒綇瀹匢D娌″啓杩涘幓,瀹冩湁鍙兘鏄汉涓虹殑娓呯┖浣忓畢ID)
+                if (mode == GatewayBindMode.First || mode == GatewayBindMode.Binded)
+                {
                     //娣诲姞鎼滅储鍒扮殑缃戝叧鍒扮紦瀛�(鎵ц缃戝叧淇濆瓨鎿嶄綔)
                     var result = await HdlGatewayLogic.Current.AddNewGateway(way, ShowErrorMode.NO);
                     if (result == false)
@@ -402,7 +412,12 @@
                 if (mode == GatewayBindMode.First || mode == GatewayBindMode.Binded)
                 {
                     //鎴戣寰楄繖閲岄渶瑕佽幏鍙栦竴涓嬫柊缃戝叧鐨勮澶囧垪琛�
-                    Common.LocalDevice.Current.SetDeviceToMemmoryByGateway(way);
+                    Common.LocalDevice.Current.SetDeviceToMemmoryByGateway(way, true);
+                    if (way.IsMainGateWay == true)
+                    {
+                        //濡傛灉瀹冩槸涓荤綉鍏�,鍒欏埛鏂板満鏅垪琛�
+                        HdlSceneLogic.Current.RefreshSceneUIList(true);
+                    }
                 }
             }
             return true;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayInfoEditorForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayInfoEditorForm.cs
index ce4b49b..58fdae5 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayInfoEditorForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayInfoEditorForm.cs
@@ -90,7 +90,8 @@
 
             //璁惧绫诲瀷 (鍥哄畾鏅鸿兘缃戝叧)
             caption = Language.StringByID(R.MyInternationalizationString.uDeviceType);
-            var btnType = new FrameCaptionViewControl(caption, Language.StringByID(60004), listview.rowSpace / 2);
+            var infoContent = Common.LocalDevice.Current.GetDeviceModelIdNameInfo("1");
+            var btnType = new FrameCaptionViewControl(caption, infoContent != null ? infoContent.A绫诲瀷鍚嶅瓧 : string.Empty, listview.rowSpace / 2);
             btnType.UseClickStatu = false;
             listview.AddChidren(btnType);
             btnType.InitControl();
@@ -334,7 +335,7 @@
             {
                 return;
             }
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 if (this.Parent != null)
                 {
@@ -344,7 +345,7 @@
                         btnNewVersion.Visible = true;
                     }
                 }
-            });
+            }, ShowErrorMode.NO);
         }
 
         #endregion
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayListForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayListForm.cs
index 1548f15..8b60ed8 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayListForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayListForm.cs
@@ -354,7 +354,7 @@
         /// <param name="hadGwOnline">2020.05.25杩藉姞:姝や綇瀹呮槸鍚︽嫢鏈夌綉鍏冲湪绾�</param>
         public override void GatewayOnlinePush(ZbGateway gateWay, bool online, bool hadGwOnline)
         {
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 if (this.Parent == null)
                 {
@@ -365,7 +365,7 @@
                 {
                     this.dicRowContr[gwid].IsOnline = online;
                 }
-            });
+            }, ShowErrorMode.NO);
         }
 
         #endregion
@@ -376,7 +376,7 @@
         /// 缃戝叧鏂扮増鏈娴�
         /// </summary>
         /// <param name="listWays"></param>
-        private async void CheckGatewayNewVersion(List<ZbGateway> listWays)
+        private void CheckGatewayNewVersion(List<ZbGateway> listWays)
         {
             foreach (var way in listWays)
             {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayProductInfoForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayProductInfoForm.cs
index ef5a516..408c6e2 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayProductInfoForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Gateway/Manage/GatewayProductInfoForm.cs
@@ -124,7 +124,8 @@
 
             //璁惧绫诲瀷 (鍥哄畾鏅鸿兘缃戝叧)
             caption = Language.StringByID(R.MyInternationalizationString.uDeviceType);
-            var btnType = new FrameCaptionViewControl(caption, Language.StringByID(60004), listview.rowSpace / 2);
+            var infoContent = Common.LocalDevice.Current.GetDeviceModelIdNameInfo("1");
+            var btnType = new FrameCaptionViewControl(caption, infoContent != null ? infoContent.A绫诲瀷鍚嶅瓧 : string.Empty, listview.rowSpace / 2);
             btnType.UseClickStatu = false;
             listview.AddChidren(btnType);
             btnType.InitControl();
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Guide/GuideForm1.cs b/ZigbeeApp/Shared/Phone/UserCenter/Guide/GuideForm1.cs
index 49bc1b2..6151e7f 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Guide/GuideForm1.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Guide/GuideForm1.cs
@@ -70,7 +70,7 @@
                 while (this.Parent != null)
                 {
                     index++;
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (index >= 10)
                         {
@@ -81,7 +81,7 @@
                         {
                             btnFinger.X += moveValue;
                         }
-                    });
+                    }, ShowErrorMode.NO);
                     System.Threading.Thread.Sleep(300);
                 }
             });
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/HdlBackup/HdlAutoBackupForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/HdlBackup/HdlAutoBackupForm.cs
index e828557..7ee799c 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/HdlBackup/HdlAutoBackupForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/HdlBackup/HdlAutoBackupForm.cs
@@ -127,7 +127,7 @@
             string msg2 = Language.StringByID(R.MyInternationalizationString.uSynchronizeDataToServiceSuccessMsg);
             this.ShowMassage(ShowMsgType.Tip, msg2);
 
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 this.CloseForm();
             });
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionFileContentForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionFileContentForm.cs
index a05bea7..d44f2d0 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionFileContentForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionFileContentForm.cs
@@ -11,6 +11,11 @@
     {
         #region 鈻� 鍙橀噺澹版槑___________________________
 
+        /// <summary>
+        /// 瑙e瘑
+        /// </summary>
+        private bool decryptPassword = false;
+
         #endregion
 
         #region 鈻� 鍒濆鍖朹____________________________
@@ -26,6 +31,24 @@
 
             //鍒濆鍖栦腑閮ㄤ俊鎭�
             this.InitMiddleFrame(i_file);
+
+            var btnButton = new NormalViewControl(200, 69, true);
+            btnButton.Gravity = Gravity.CenterVertical;
+            btnButton.X = bodyFrameLayout.Width - Application.GetRealWidth(200) - ControlCommonResourse.XXLeft;
+            btnButton.TextColor = UserCenterColor.Current.TopLayoutTitleText;
+            btnButton.TextAlignment = TextAlignment.BottomRight;
+            btnButton.TextSize = 17;
+            btnButton.Text = "缈昏瘧";
+            topFrameLayout.AddChidren(btnButton);
+            btnButton.ButtonClickEvent += (sender, e) =>
+            {
+                if (this.decryptPassword == false)
+                {
+                    this.decryptPassword = true;
+                    //鍒濆鍖栦腑閮ㄤ俊鎭�
+                    this.InitMiddleFrame(i_file);
+                }
+            };
         }
 
         /// <summary>
@@ -34,6 +57,8 @@
         private void InitMiddleFrame(string i_file)
         {
             if (i_file == string.Empty) { return; }
+
+            this.ClearBodyFrame();
 
             if (i_file.EndsWith(".png") == true || i_file.EndsWith(".jpg") == true || i_file.EndsWith(".JPG") == true)
             {
@@ -59,6 +84,17 @@
         /// <param name="i_text"></param>
         public void SetTextContent(string textValue)
         {
+            if (this.decryptPassword == true)
+            {
+                var strArry = textValue.Split(new string[] { "\r\n" }, StringSplitOptions.RemoveEmptyEntries);
+
+                textValue = string.Empty;
+                foreach (var strtext in strArry)
+                {
+                    string value = UserCenterLogic.DecryptPassword(UserCenterResourse.FileEncryptKey, strtext);
+                    textValue += value + "\r\n";
+                }
+            }
             textValue = textValue.Replace(",", "\r\n");
             if (textValue.StartsWith("{") == true)
             {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionMainForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionMainForm.cs
index 40234dc..5cc33dd 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionMainForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionMainForm.cs
@@ -67,6 +67,8 @@
 
             this.AddNormalRowControl("WIFI鍙橀噺", 400, Shared.Application.IsWifi == true ? "true" : "false", 400);
 
+            this.AddNormalRowControl("鎵嬫満鑾峰彇鐨処P", 600, new Shared.Net.NetWiFi().BroadcastIpAddress.ToString(), 600);
+
             if (ZigBee.Common.Application.FindGateWaySocket.busSocket == null)
             {
                 this.AddNormalRowControl("Socket閾炬帴", 400, "鏈垵濮嬪寲", 400);
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionSearchAllFile.cs b/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionSearchAllFile.cs
index 9d711f8..401554a 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionSearchAllFile.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/HideOption/HideOptionSearchAllFile.cs
@@ -80,14 +80,14 @@
             var listDirectory = new List<string>();
             var listAllFile = new List<string>();
 
-            string rootPath = Shared.IO.FileUtils.RootPath.Trim('/');
-            if (this.nowDirectory.Trim('/') == rootPath)
-            {
-                //鏍圭洰褰曞彧瑕佷袱涓氨鍙互浜�
-                listDirectory.Add(Common.Config.Instance.Guid);
-                listDirectory.Add(Application.Skin != null ? Application.Skin : "Phone");
-            }
-            else
+            //string rootPath = Shared.IO.FileUtils.RootPath.Trim('/');
+            //if (this.nowDirectory.Trim('/') == rootPath)
+            //{
+            //    //鏍圭洰褰曞彧瑕佷袱涓氨鍙互浜�
+            //    listDirectory.Add(Common.Config.Instance.Guid);
+            //    listDirectory.Add(Application.Skin != null ? Application.Skin : "Phone");
+            //}
+            //else
             {
                 var files = System.IO.Directory.GetDirectories(directory);
                 foreach (var file in files)
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Member/AddMemberInfoForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Member/AddMemberInfoForm.cs
old mode 100644
new mode 100755
index 5805a8c..1ed7e3a
--- a/ZigbeeApp/Shared/Phone/UserCenter/Member/AddMemberInfoForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Member/AddMemberInfoForm.cs
@@ -150,18 +150,20 @@
             MemberInfoRes memberInfoRes = null;
             foreach (var info in listInfo)
             {
-                if (info.Account == memberResult.Account)
+                //褰撹处鍙风粦瀹氫簡閭鏃�,瀹冭繑鍥炵殑鏄偖绠辫处鍙�
+                if (info.Account == memberResult.Account
+                    || info.Account == memberResult.Email)
                 {
                     memberInfoRes = info;
                     break;
                 }
             }
-            if (memberInfoRes == null)
-            {
-                //鍑虹幇鎰忓鎯呭喌,鏁版嵁涓㈠け
-                string msg = Language.StringByID(R.MyInternationalizationString.uUnKnownErrorAndLostData);
-                this.ShowMassage(ShowMsgType.Tip, msg);
-                return;
+            if (memberInfoRes == null)
+            {
+                //鍑虹幇鎰忓鎯呭喌,鏁版嵁涓㈠け
+                string msg = Language.StringByID(R.MyInternationalizationString.uUnKnownErrorAndLostData);
+                this.ShowMassage(ShowMsgType.Tip, msg);
+                return;
             }
 
             string iconPath = System.IO.Path.Combine(UserCenterResourse.AccountOption.UserPictruePath, memberInfoRes.DistributedMark + ".png");
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Member/MemberManagementForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Member/MemberManagementForm.cs
index 27ccb52..2f15977 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Member/MemberManagementForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Member/MemberManagementForm.cs
@@ -275,7 +275,7 @@
                     }
                     this.memberInfo.IsAllowRemoteCtrl = !btnSwitch.IsSelected;
 
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         btnSwitch.CanClick = true;
                         btnSwitch.IsSelected = !btnSwitch.IsSelected;
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewEmailForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewEmailForm.cs
index 36253de..97311db 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewEmailForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewEmailForm.cs
@@ -182,7 +182,7 @@
                     System.Threading.Thread.Sleep(1000);
                     if (waitime == 0)
                     {
-                        Application.RunOnMainThread(() =>
+                        HdlThreadLogic.Current.RunMain(() =>
                         {
                             if (btnNext != null)
                             {
@@ -194,13 +194,13 @@
                         });
                         break;
                     }
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (btnNext != null)
                         {
                             btnNext.Text = waitime + "s" + repeat;
                         }
-                    });
+                    }, ShowErrorMode.NO);
                 }
             });
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewPhoneForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewPhoneForm.cs
index fa5caea..96ab103 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewPhoneForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckNewPhoneForm.cs
@@ -215,13 +215,13 @@
                         });
                         break;
                     }
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (btnNext != null)
                         {
                             btnNext.Text = waitime + "s" + repeat;
                         }
-                    });
+                    }, ShowErrorMode.NO);
                 }
             });
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldEmailForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldEmailForm.cs
index 16ba490..67f4ab0 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldEmailForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldEmailForm.cs
@@ -148,7 +148,7 @@
                     System.Threading.Thread.Sleep(1000);
                     if (waitime == 0)
                     {
-                        Application.RunOnMainThread(() =>
+                        HdlThreadLogic.Current.RunMain(() =>
                         {
                             if (btnNext != null)
                             {
@@ -160,13 +160,13 @@
                         });
                         break;
                     }
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (btnNext != null)
                         {
                             btnNext.Text = waitime + "s" + repeat;
                         }
-                    });
+                    }, ShowErrorMode.NO);
                 }
             });
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldPhoneForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldPhoneForm.cs
index 0243f21..f316058 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldPhoneForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Password/CheckOldPhoneForm.cs
@@ -161,7 +161,7 @@
                     System.Threading.Thread.Sleep(1000);
                     if (waitime == 0)
                     {
-                        Application.RunOnMainThread(() =>
+                        HdlThreadLogic.Current.RunMain(() =>
                         {
                             if (btnNext != null)
                             {
@@ -173,13 +173,13 @@
                         });
                         break;
                     }
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (btnNext != null)
                         {
                             btnNext.Text = waitime + "s" + repeat;
                         }
-                    });
+                    }, ShowErrorMode.NO);
                 }
             });
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotAccountPasswordForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotAccountPasswordForm.cs
index 3d503c4..e526f3d 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotAccountPasswordForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotAccountPasswordForm.cs
@@ -197,7 +197,7 @@
                     System.Threading.Thread.Sleep(1000);
                     if (waitime == 0)
                     {
-                        Application.RunOnMainThread(() =>
+                        HdlThreadLogic.Current.RunMain(() =>
                         {
                             if (btnCode != null)
                             {
@@ -210,13 +210,13 @@
                         });
                         break;
                     }
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (btnCode != null)
                         {
                             btnCode.Text = waitime + "s" + repeat;
                         }
-                    });
+                    }, ShowErrorMode.NO);
                 }
             });
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotSecondaryPasswordForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotSecondaryPasswordForm.cs
index 21528a3..6481e69 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotSecondaryPasswordForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Password/ForgotSecondaryPasswordForm.cs
@@ -197,7 +197,7 @@
                     System.Threading.Thread.Sleep(1000);
                     if (waitime == 0)
                     {
-                        Application.RunOnMainThread(() =>
+                        HdlThreadLogic.Current.RunMain(() =>
                         {
                             if (btnCode != null)
                             {
@@ -210,13 +210,13 @@
                         });
                         break;
                     }
-                    Application.RunOnMainThread(() =>
+                    HdlThreadLogic.Current.RunMain(() =>
                     {
                         if (btnCode != null)
                         {
                             btnCode.Text = waitime + "s" + repeat;
                         }
-                    });
+                    }, ShowErrorMode.NO);
                 }
             });
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Residence/LookRoomSettionForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Residence/LookRoomSettionForm.cs
index 2aadc19..973a50d 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Residence/LookRoomSettionForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Residence/LookRoomSettionForm.cs
@@ -20,6 +20,10 @@
         /// 妗屽竷鎺т欢
         /// </summary>
         private NormalFrameLayout frameTable = null;
+        /// <summary>
+        /// 璁惧鍒楄〃
+        /// </summary>
+        private List<CommonDevice> listDevice = new List<CommonDevice>();
 
         #endregion
 
@@ -161,21 +165,15 @@
                 frameBack.AddChidren(listView);
 
                 var dicData = new Dictionary<string, DeviceRowInfo>();
-                var listGwId = new List<string>();
-                foreach (var textId in dicGroupDevice.Keys)
+                foreach (var strText in dicGroupDevice.Keys)
                 {
                     //娣诲姞璁惧琛�
-                    this.AddDeviceRow(dicGroupDevice[textId], textId, listView);
-                    foreach (var deviceKey in dicGroupDevice[textId].listDeviceKeys)
+                    this.AddDeviceRow(dicGroupDevice[strText], strText, listView);
+                    foreach (var deviceKey in dicGroupDevice[strText].listDeviceKeys)
                     {
                         var device = Common.LocalDevice.Current.GetDevice(deviceKey);
-                        if (listGwId.Contains(device.CurrentGateWayId) == false)
-                        {
-                            //缃戝叧ID
-                            listGwId.Add(device.CurrentGateWayId);
-                        }
                         //浠ュ洖璺綔涓虹储寮曞幓鎸囧畾瀵硅薄
-                        dicData[deviceKey] = dicGroupDevice[textId];
+                        dicData[deviceKey] = dicGroupDevice[strText];
                     }
                 }
                 listView.AdjustRealHeight(Application.GetRealHeight(23));
@@ -183,7 +181,7 @@
                 if (Common.Config.Instance.Home.IsVirtually == false)
                 {
                     //寮�鍚澶囧湪绾跨洃娴�
-                    this.StartCheckDeviceOnline(listView, listGwId, dicData);
+                    this.StartCheckDeviceOnline(listView, dicData);
                 }
             });
         }
@@ -196,9 +194,9 @@
         /// 娣诲姞璁惧琛�
         /// </summary>
         /// <param name="rowInfo"></param>
-        /// <param name="TextId"></param>
+        /// <param name="strText"></param>
         /// <param name="listView"></param>
-        private void AddDeviceRow(DeviceRowInfo rowInfo, int TextId, VerticalListControl listView)
+        private void AddDeviceRow(DeviceRowInfo rowInfo, string strText, VerticalListControl listView)
         {
             var frameRow = new FrameRowControl(listView.rowSpace / 2);
             frameRow.LeftOffset = Application.GetRealWidth(46) - ControlCommonResourse.XXLeft;
@@ -209,7 +207,7 @@
             btnIcon.UnSelectedImagePath = rowInfo.IconPath;
             //鍚嶇О
             var btnView = frameRow.AddLeftCaption(string.Empty, 600);
-            btnView.TextID = TextId;
+            btnView.Text = strText;
             btnView.TextSize = 15;
             //鍙崇澶�
             frameRow.AddRightArrow();
@@ -221,7 +219,7 @@
             frameRow.ButtonClickEvent += (sender, e) =>
             {
                 var form = new LookRoomDeviceListForm();
-                form.AddForm(lookRoom.Name, Language.StringByID(TextId), rowInfo.listDeviceKeys);
+                form.AddForm(lookRoom.Name, strText, rowInfo.listDeviceKeys);
             };
         }
 
@@ -233,25 +231,25 @@
         /// 鑾峰彇鍒嗙粍鍚庣殑璁惧
         /// </summary>
         /// <returns></returns>
-        private Dictionary<int, DeviceRowInfo> GetAllGroupDevice()
+        private Dictionary<string, DeviceRowInfo> GetAllGroupDevice()
         {
             //鍏ㄩ儴鐨勮澶�
-            var listDevice = HdlRoomLogic.Current.GetRoomListDevice(lookRoom);
-            var dic = new Dictionary<int, DeviceRowInfo>();
+            this.listDevice = HdlRoomLogic.Current.GetRoomListDevice(lookRoom);
+            var dic = new Dictionary<string, DeviceRowInfo>();
             foreach (var device in listDevice)
             {
                 var typeInfo = Common.LocalDevice.Current.GetDeviceBelongEnumInfo(device);
                 //鎸夋墍灞濱D鍒嗙粍
-                if (dic.ContainsKey(typeInfo.BeloneTextId) == false)
+                if (dic.ContainsKey(typeInfo.BeloneText) == false)
                 {
-                    dic[typeInfo.BeloneTextId] = new DeviceRowInfo();
+                    dic[typeInfo.BeloneText] = new DeviceRowInfo();
                     string path1 = string.Empty;
                     string path2 = string.Empty;
                     //鑾峰彇鍥剧墖
                     Common.LocalDevice.Current.GetDeviceFunctionTypeMenuIcon(typeInfo.ConcreteType, ref path1, ref path2);
-                    dic[typeInfo.BeloneTextId].IconPath = path1;
+                    dic[typeInfo.BeloneText].IconPath = path1;
                 }
-                dic[typeInfo.BeloneTextId].listDeviceKeys.Add(Common.LocalDevice.Current.GetDeviceMainKeys(device));
+                dic[typeInfo.BeloneText].listDeviceKeys.Add(Common.LocalDevice.Current.GetDeviceMainKeys(device));
             }
             return dic;
         }
@@ -264,53 +262,48 @@
         /// 寮�鍚澶囧湪绾跨洃娴�
         /// </summary>
         /// <param name="listView">鍒ゆ柇閫�鍑烘椂浣跨敤</param>
-        /// <param name="listGwId">缃戝叧ID</param>
         /// <param name="dicData">浠ュ洖璺綔涓虹储寮曞幓鎸囧畾瀵硅薄</param>
-        private void StartCheckDeviceOnline(VerticalListControl listView, List<string> listGwId, Dictionary<string, DeviceRowInfo> dicData)
+        private void StartCheckDeviceOnline(VerticalListControl listView, Dictionary<string, DeviceRowInfo> dicData)
         {
             HdlThreadLogic.Current.RunThread(() =>
             {
-                var listCheck = new HashSet<string>();
-                for (int i = 0; i < listGwId.Count; i++)
+                var dicCheck = new Dictionary<string, bool>();
+                for (int i = 0; i < this.listDevice.Count; i++)
                 {
                     if (listView.Parent == null)
                     {
                         return;
                     }
-                    //杩欓噷涓昏鍙槸鑾峰彇鍦ㄧ嚎鐘舵��
-                    var zbway = HdlGatewayLogic.Current.GetLocalGateway(listGwId[i]);
-                    int statu = 0;
-                    var list = Common.LocalDevice.Current.GetDeviceListFromGateway(zbway, ref statu, false, ShowErrorMode.NO);
-                    if (statu != -1)
+                    var localDevice = this.listDevice[i];
+                    if (dicCheck.ContainsKey(localDevice.DeviceAddr) == false)
+                    {
+                        //鍙渶瑕佹娴嬩竴璺�
+                        var deviceInfo = Common.LocalDevice.Current.ReadDeviceEpointDeviceInfo(localDevice);
+                        if (deviceInfo != null)
+                        {
+                            localDevice.IsOnline = deviceInfo.IsOnline;
+                            dicCheck[localDevice.DeviceAddr] = Common.LocalDevice.Current.CheckDeviceIsOnline(localDevice, false);
+                        }
+                    }
+                    if (dicCheck.ContainsKey(localDevice.DeviceAddr) == false
+                      || dicCheck[localDevice.DeviceAddr] == false)
+                    {
+                        //缃戝叧娌℃湁鍥炲,鎴栬�呬笉鍦ㄧ嚎
+                        continue;
+                    }
+                    string mainkeys = Common.LocalDevice.Current.GetDeviceMainKeys(localDevice);
+                    if (dicData.ContainsKey(mainkeys) == true)
                     {
                         HdlThreadLogic.Current.RunMain(() =>
                         {
-                            for (int j = 0; j < list.Count; j++)
-                            {
-                                string mainkeys = Common.LocalDevice.Current.GetDeviceMainKeys(list[j]);
-                                if (listView.Parent == null || dicData.ContainsKey(mainkeys) == false || listCheck.Contains(mainkeys) == true)
-                                {
-                                    return;
-                                }
-                                listCheck.Add(mainkeys);
+                            dicData[mainkeys].OnlineCount += 1;
+                            dicData[mainkeys].btnOnline.Text = dicData[mainkeys].OnlineCount + "/" + dicData[mainkeys].listDeviceKeys.Count;
 
-                                var localDevice = Common.LocalDevice.Current.GetDevice(mainkeys);
-                                if (localDevice != null && localDevice.IsOnline != list[j].IsOnline)
-                                {
-                                    //鍦ㄧ嚎鐘舵�佷竴鏍风殑璇濓紝涓嶉渶瑕佸埛鏂�
-                                    localDevice.IsOnline = list[j].IsOnline;
-                                    localDevice.ReSave();
-                                }
-                                if (Common.LocalDevice.Current.CheckDeviceIsOnline(list[j]) == true)
-                                {
-                                    dicData[mainkeys].OnlineCount += 1;
-                                    dicData[mainkeys].btnOnline.Text = dicData[mainkeys].OnlineCount + "/" + dicData[mainkeys].listDeviceKeys.Count;
-                                }
-                            }
-                        });
+                        }, ShowErrorMode.NO);
                     }
+                    System.Threading.Thread.Sleep(30);
                 }
-            });
+            }, ShowErrorMode.NO);
         }
 
         #endregion
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceListForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceListForm.cs
index 3300808..c384d1e 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceListForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceListForm.cs
@@ -130,15 +130,8 @@
                 return false;
             }
             var pageData = Newtonsoft.Json.JsonConvert.DeserializeObject<Common.ResponseEntity.ResidenceRes>(resultData);
-
-            //鏆傛椂瀛樺偍鏁版嵁
-            var dicData = new Dictionary<string, Common.ResponseEntity.ResidenceObj>();
-            var listResidenceSort = new List<string>();
-            for (int i = 0; i < pageData.PageData.Count; i++)
-            {
-                dicData[pageData.PageData[i].Id] = pageData.PageData[i];
-                listResidenceSort.Add(pageData.PageData[i].Id);
-            }
+            //鎺掑簭浣忓畢
+            var listHouse = HdlResidenceLogic.Current.SortHouse(pageData.PageData);
 
             HdlThreadLogic.Current.RunMain(() =>
             {
@@ -149,18 +142,14 @@
                 listView.Height = bodyFrameLayout.Height;
 
                 this.dicResidenceData = new Dictionary<string, Common.ResponseEntity.ResidenceObj>();
-                for (int i = 0; i < listResidenceSort.Count; i++)
+                for (int i = 0; i < listHouse.Count; i++)
                 {
-                    if (dicData.ContainsKey(listResidenceSort[i]) == false)
-                    {
-                        continue;
-                    }
-                    var info = dicData[listResidenceSort[i]];
+                    var info = listHouse[i];
 
                     //鏀堕泦璇ヨ处鍙蜂綇瀹呯殑鏁版嵁
                     this.dicResidenceData[info.Id] = info;
                     //娣诲姞浣忓畢鐨勮(鏈夌綉鎯呭喌)
-                    this.AddRowLayoutByOnline(info, i != listResidenceSort.Count - 1);
+                    this.AddRowLayoutByOnline(info, i != listHouse.Count - 1);
                 }
                 //璋冩暣鍒楄〃鎺т欢鐨勯珮搴�
                 this.listView.AdjustRealHeight(Application.GetRealHeight(23));
@@ -376,14 +365,14 @@
                     form.AddForm(flage);
                 }
             };
-            //鏇存敼
-            var btnChanged = rowLayout.AddEditorControl();
-            btnChanged.TextID = R.MyInternationalizationString.uChanged1;
-            btnChanged.ButtonClickEvent += (sender, e) =>
-            {
-                //鏄剧ず缂栬緫鍚嶇О鐣岄潰
-                this.ShowEditorNameForm(null, i_home, btnHome);
-            };
+            ////鏇存敼
+            //var btnChanged = rowLayout.AddEditorControl();
+            //btnChanged.TextID = R.MyInternationalizationString.uChanged1;
+            //btnChanged.ButtonClickEvent += (sender, e) =>
+            //{
+            //    //鏄剧ず缂栬緫鍚嶇О鐣岄潰
+            //    this.ShowEditorNameForm(null, i_home, btnHome);
+            //};
         }
 
         #endregion
@@ -460,18 +449,12 @@
             //寮�鍚繘搴︽潯
             this.ShowProgressBar();
 
-            var Pra = new EditorResidencePra();
-            Pra.HomeId = info.Id;
-            Pra.Name = ResidenceName;
-            Pra.IsOtherAccountCtrl = false;
-            Pra.LoginAccessToken = Config.Instance.Token;
+            var result = HdlResidenceLogic.Current.EditorResidenceName(info.Id, ResidenceName);
 
-            //缂栬緫浣忓畢
-            bool flage = UserCenterLogic.GetResultStatuByRequestHttps("App/EditHome", false, Pra, new List<string> { "NotCheck" });
             //鍏抽棴杩涘害鏉�
             this.CloseProgressBar();
 
-            if (flage == true)
+            if (result == true)
             {
                 HdlThreadLogic.Current.RunMain(() =>
                 {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceManagementForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceManagementForm.cs
index 948b78c..f0438a2 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceManagementForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Residence/ResidenceManagementForm.cs
@@ -702,7 +702,7 @@
             //鍒犻櫎浣忓畢
             HdlResidenceLogic.Current.DeleteHouseMemmory(deleteId);
 
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 //鍏抽棴鐣岄潰
                 this.CloseForm();
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs
index c80a36f..0874a89 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddMenuForm.cs
@@ -22,7 +22,7 @@
         /// <summary>
         /// 鍏ㄩ儴鐨勬暟鎹�(keys1:鎴块棿ID   Keys2:R鏂囦欢鐨勬暟鍊�)
         /// </summary>
-        private Dictionary<string, Dictionary<int, uRowInformation>> dicAllData = new Dictionary<string, Dictionary<int, uRowInformation>>();
+        private Dictionary<string, Dictionary<string, uRowInformation>> dicAllData = new Dictionary<string, Dictionary<string, uRowInformation>>();
         /// <summary>
         /// 褰撳墠閫夋嫨鐨勬ゼ灞侷D
         /// </summary>
@@ -180,16 +180,16 @@
         /// 鍒濆鍖栬鎺т欢
         /// </summary>
         /// <param name="dicRowData"></param>
-        private void InitRowControl(Dictionary<int, uRowInformation> dicRowData)
+        private void InitRowControl(Dictionary<string, uRowInformation> dicRowData)
         {
             this.listView.RemoveAll();
             HdlThreadLogic.Current.RunMainInThread(() =>
             {
                 int count = 0;
-                foreach (var textId in dicRowData.Keys)
+                foreach (var strText in dicRowData.Keys)
                 {
                     count++;
-                    var rowData = dicRowData[textId];
+                    var rowData = dicRowData[strText];
 
                     var rowlayout = new FrameRowControl(listView.rowSpace / 2);
                     listView.AddChidren(rowlayout);
@@ -198,7 +198,7 @@
                     btnIcon.UnSelectedImagePath = rowData.IconPath;
 
                     //璁惧鍚�
-                    var txtDevice = rowlayout.AddLeftCaption(Language.StringByID(textId), 750);
+                    var txtDevice = rowlayout.AddLeftCaption(strText, 750);
                     txtDevice.TextSize = 15;
                     //鍚戝彸鍥炬爣
                     rowlayout.AddRightArrow();
@@ -238,9 +238,9 @@
         /// 鑾峰彇璁惧鐨勬墍鏈夌被鍨嬶紝骞舵暣鐞嗘垚姣忎竴琛岀殑鏁版嵁(keys1:鎴块棿ID   Keys2:R鏂囦欢鐨勬暟鍊�)
         /// </summary>
         /// <returns></returns>
-        private Dictionary<string, Dictionary<int, uRowInformation>> GetAllListData()
+        private Dictionary<string, Dictionary<string, uRowInformation>> GetAllListData()
         {
-            var dicData = new Dictionary<string, Dictionary<int, uRowInformation>>();
+            var dicData = new Dictionary<string, Dictionary<string, uRowInformation>>();
             //鑾峰彇鏈湴瀹夐槻鐨勫満鏅�
             Dictionary<int, string> dicScene = HdlSafeguardLogic.Current.GetLocalSceneByZoneID(this.zoonID);
             var listRoom = HdlRoomLogic.Current.GetFloorSortRoom(this.nowSelectFloorId);
@@ -263,14 +263,14 @@
         /// <param name="i_room"></param>
         /// <param name="dicScene"></param>
         /// <returns></returns>
-        private Dictionary<int, uRowInformation> GetRoomDeviceAndSceneData(Common.Room i_room, Dictionary<int, string> dicScene)
+        private Dictionary<string, uRowInformation> GetRoomDeviceAndSceneData(Common.Room i_room, Dictionary<int, string> dicScene)
         {
             if (dicScene == null)
             {
                 //鑾峰彇鏈湴瀹夐槻鐨勫満鏅�
                 dicScene = HdlSafeguardLogic.Current.GetLocalSceneByZoneID(this.zoonID);
             }
-            var dicRoomData = new Dictionary<int, uRowInformation>();
+            var dicRoomData = new Dictionary<string, uRowInformation>();
 
             for (int j = 0; j < i_room.ListDevice.Count; j++)
             {
@@ -292,14 +292,15 @@
                     var typeInfo = Common.LocalDevice.Current.GetDeviceBelongEnumInfo(device);
                     //鑾峰彇鍥剧墖
                     Common.LocalDevice.Current.GetDeviceFunctionTypeMenuIcon(typeInfo.ConcreteType, ref unSelectPath, ref selectPath);
-                    if (dicRoomData.ContainsKey(typeInfo.BeloneTextId) == false)
+                    if (dicRoomData.ContainsKey(typeInfo.BeloneText) == false)
                     {
-                        dicRoomData[typeInfo.BeloneTextId] = new uRowInformation();
-                        dicRoomData[typeInfo.BeloneTextId].IconPath = unSelectPath;
+                        dicRoomData[typeInfo.BeloneText] = new uRowInformation();
+                        dicRoomData[typeInfo.BeloneText].IconPath = unSelectPath;
                     }
-                    dicRoomData[typeInfo.BeloneTextId].listDevice.Add(device);
+                    dicRoomData[typeInfo.BeloneText].listDevice.Add(device);
                 }
             }
+            string strSceneText = Language.StringByID(R.MyInternationalizationString.uScence);
             for (int j = 0; j < i_room.ListSceneId.Count; j++)
             {
                 //濡傛灉閭d釜鍦烘櫙宸茬粡娣诲姞浜嗭紝鍒欎笉鍐嶆樉绀�
@@ -312,13 +313,13 @@
                 {
                     continue;
                 }
-                if (dicRoomData.ContainsKey(R.MyInternationalizationString.uScence) == false)
+                if (dicRoomData.ContainsKey(strSceneText) == false)
                 {
-                    dicRoomData[R.MyInternationalizationString.uScence] = new uRowInformation();
-                    dicRoomData[R.MyInternationalizationString.uScence].IconPath = "Scene/SceneIcon.png";
-                    dicRoomData[R.MyInternationalizationString.uScence].listScene = new List<Common.SceneUI>();
+                    dicRoomData[strSceneText] = new uRowInformation();
+                    dicRoomData[strSceneText].IconPath = "Scene/SceneIcon.png";
+                    dicRoomData[strSceneText].listScene = new List<Common.SceneUI>();
                 }
-                dicRoomData[R.MyInternationalizationString.uScence].listScene.Add(sceneUi);
+                dicRoomData[strSceneText].listScene.Add(sceneUi);
             }
             return dicRoomData;
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddSceneForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddSceneForm.cs
index 4858ea3..f4d01db 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddSceneForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Safety/AlarmTargetAddSceneForm.cs
@@ -64,7 +64,7 @@
             {
                 //鑾峰彇鏈湴瀹夐槻鐨勫満鏅�
                 Dictionary<int, string> dicScene = HdlSafeguardLogic.Current.GetLocalSceneByZoneID(this.zoonID);
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     int count = listScene.Count - 1;
                     for (int i = 0; i < listScene.Count; i++)
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Safety/GarrisonAreaDelayedSettionForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Safety/GarrisonAreaDelayedSettionForm.cs
index 089fab7..2675dde 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Safety/GarrisonAreaDelayedSettionForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Safety/GarrisonAreaDelayedSettionForm.cs
@@ -97,7 +97,7 @@
             //鍏抽棴杩涘害鏉�
             this.CloseProgressBar();
 
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 //鍒濆鍖栥�愯繘鍏ュ欢鏃躲�戣
                 this.InitInDelayedRow(listView);
@@ -190,7 +190,7 @@
                 //淇敼缂撳瓨
                 this.timeResponseData.EntranceDelayTime = inDelayTime;
                 this.timeResponseData.GoOutDelayTime = OutDelayTime;
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     if (this.inDelayTimeControl != null)
                     {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Safety/SafetyManagementMainForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Safety/SafetyManagementMainForm.cs
index 7be9dbd..7f5192c 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Safety/SafetyManagementMainForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Safety/SafetyManagementMainForm.cs
@@ -315,7 +315,7 @@
             this.CloseProgressBar();
 
             //鏁版嵁鍒濆鍖栧畬鎴愬悗
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 //鍒濆鍖栧ご閮ㄧ殑閭d笁涓浘鏍�
                 garrisonControl = new SafetyMasterControl();
@@ -652,7 +652,7 @@
                 }
                 dicAlarm = null;
 
-                Application.RunOnMainThread(() =>
+                HdlThreadLogic.Current.RunMain(() =>
                 {
                     if (this.Parent == null)
                     {
@@ -723,7 +723,7 @@
                 }
             }
 
-            Application.RunOnMainThread(() =>
+            HdlThreadLogic.Current.RunMain(() =>
             {
                 if (this.TodaySafeguardFrame != null)
                 {
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/SharedContent/AddNewSharedContentForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/SharedContent/AddNewSharedContentForm.cs
index 79e9e3b..84b790a 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/SharedContent/AddNewSharedContentForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/SharedContent/AddNewSharedContentForm.cs
@@ -297,7 +297,7 @@
         /// </summary>
         /// <param name="dicData"></param>
         /// <param name="listView"></param>
-        private void InitDeviceObjectRow(Dictionary<int, List<CommonDevice>> dicData, VerticalListControl listView)
+        private void InitDeviceObjectRow(Dictionary<string, List<CommonDevice>> dicData, VerticalListControl listView)
         {
             var scrolContr = new RoomDeviceGroupMenuControl(dicData);
             this.frameDeviceTable.AddChidren(scrolContr);
@@ -385,11 +385,11 @@
         /// 鑾峰彇鍒嗙粍鍚庣殑璁惧
         /// </summary>
         /// <returns></returns>
-        private Dictionary<int, List<CommonDevice>> GetAllGroupDevice()
+        private Dictionary<string, List<CommonDevice>> GetAllGroupDevice()
         {
             //鍏ㄩ儴鐨勮澶�
             var listDevice = HdlRoomLogic.Current.GetRoomListDevice(lookRoom);
-            var dic = new Dictionary<int, List<CommonDevice>>();
+            var dic = new Dictionary<string, List<CommonDevice>>();
             foreach (var device in listDevice)
             {
                 if (memberShardInfo.dicAllShardKeys.ContainsKey(device.FilePath) == true)
@@ -398,11 +398,11 @@
                     continue;
                 }
                 var typeInfo = Common.LocalDevice.Current.GetDeviceBelongEnumInfo(device);
-                if (dic.ContainsKey(typeInfo.BeloneTextId) == false)
+                if (dic.ContainsKey(typeInfo.BeloneText) == false)
                 {
-                    dic[typeInfo.BeloneTextId] = new List<CommonDevice>();
+                    dic[typeInfo.BeloneText] = new List<CommonDevice>();
                 }
-                dic[typeInfo.BeloneTextId].Add(device);
+                dic[typeInfo.BeloneText].Add(device);
             }
             return dic;
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/SharedContent/LookSharedContentForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/SharedContent/LookSharedContentForm.cs
index 419cc54..7309565 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/SharedContent/LookSharedContentForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/SharedContent/LookSharedContentForm.cs
@@ -282,7 +282,7 @@
         /// </summary>
         /// <param name="dicData"></param>
         /// <param name="listView"></param>
-        private void InitDeviceObjectRow(Dictionary<int, List<CommonDevice>> dicData, VerticalListControl listView)
+        private void InitDeviceObjectRow(Dictionary<string, List<CommonDevice>> dicData, VerticalListControl listView)
         {
             var scrolContr = new RoomDeviceGroupMenuControl(dicData);
             this.frameDeviceTable.AddChidren(scrolContr);
@@ -371,19 +371,19 @@
         /// 鑾峰彇鍒嗙粍鍚庣殑璁惧
         /// </summary>
         /// <returns></returns>
-        private Dictionary<int, List<CommonDevice>> GetAllGroupDevice()
+        private Dictionary<string, List<CommonDevice>> GetAllGroupDevice()
         {
             //鍏ㄩ儴鐨勮澶�
             var listDevice = this.GetShardListDevice();
-            var dic = new Dictionary<int, List<CommonDevice>>();
+            var dic = new Dictionary<string, List<CommonDevice>>();
             foreach (var device in listDevice)
             {
                 var typeInfo = Common.LocalDevice.Current.GetDeviceBelongEnumInfo(device);
-                if (dic.ContainsKey(typeInfo.BeloneTextId) == false)
+                if (dic.ContainsKey(typeInfo.BeloneText) == false)
                 {
-                    dic[typeInfo.BeloneTextId] = new List<CommonDevice>();
+                    dic[typeInfo.BeloneText] = new List<CommonDevice>();
                 }
-                dic[typeInfo.BeloneTextId].Add(device);
+                dic[typeInfo.BeloneText].Add(device);
             }
             return dic;
         }
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/UserMain/MessageManagementForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/UserMain/MessageManagementForm.cs
index 637ea33..b071030 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/UserMain/MessageManagementForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/UserMain/MessageManagementForm.cs
@@ -768,7 +768,8 @@
             {
                 recordInfo.IconPath = "Device/Sensor.png";
                 //娑堟伅绫诲瀷:浼犳劅鍣�
-                recordInfo.MsgObjectText = Language.StringByID(R.MyInternationalizationString.uDeviceBelongId1200);
+                var infoContent = Common.LocalDevice.Current.GetDeviceModelIdNameInfo("A402");
+                recordInfo.MsgObjectText = infoContent != null ? infoContent.A瀹樻柟鍚嶅瓧 : string.Empty;
             }
             else
             {
@@ -826,7 +827,8 @@
             {
                 recordInfo.IconPath = "Device/IntelligentLocks.png";
                 //娑堟伅绫诲瀷:鏅鸿兘闂ㄩ攣
-                recordInfo.MsgObjectText = Language.StringByID(R.MyInternationalizationString.uDeviceBelongId2800);
+                var infoContent = Common.LocalDevice.Current.GetDeviceModelIdNameInfo("A405");
+                recordInfo.MsgObjectText = infoContent != null ? infoContent.A瀹樻柟鍚嶅瓧 : string.Empty;
             }
             else
             {
diff --git a/ZigbeeApp/Shared/Phone/UserView/LoginLoading.cs b/ZigbeeApp/Shared/Phone/UserView/LoginLoading.cs
index 5843073..f88457d 100755
--- a/ZigbeeApp/Shared/Phone/UserView/LoginLoading.cs
+++ b/ZigbeeApp/Shared/Phone/UserView/LoginLoading.cs
@@ -27,12 +27,12 @@
             btnIcon.Gravity = Gravity.CenterHorizontal;
             this.AddChidren(btnIcon);
 
-            //Hdl Home
+            //Evoyo Home
             var btnText = new Button();
             btnText.Height = Application.GetRealHeight(70);
             btnText.Y = btnIcon.Bottom;
             btnText.TextAlignment = TextAlignment.Center;
-            btnText.Text = "HDL Home";
+            btnText.Text = "Evoyo Home";
             btnText.TextColor = UserCenter.UserCenterColor.Current.White;
             btnText.TextSize = 16;
             this.AddChidren(btnText);
diff --git a/ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs b/ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs
index 002e5a4..91553e0 100755
--- a/ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs
+++ b/ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs
@@ -12,19 +12,25 @@
 {
     public static class Application
     {
+        #region 鈻� 鍙橀噺澹版槑___________________________
+
         public static bool isInited;
         /// <summary>
         /// 鏄惁姝e湪鎼滅储缃戝叧
         /// </summary>
         public static bool IsSearchingGateway = false;
         /// <summary>
-        /// 鏂板彂鐜扮殑缃戝叧閫氱煡
-        /// </summary>
-        public static Action<ZigBee.Device.ZbGateway> NewGateWayAction;
-        /// <summary>
         /// 涓婁竴娆$殑浣忓畢ID
         /// </summary>
         private static string oldHomeID = string.Empty;
+        /// <summary>
+        /// 鎺ユ敹鐨処P
+        /// </summary>
+        private static List<string> listReceiveIP = new List<string>();
+
+        #endregion
+
+        #region 鈻� 鍒濆鍖朹____________________________
 
         public static void Init()
         {
@@ -37,10 +43,28 @@
             //鍒濆鍖朣ocket
             FindGateWaySocket.Start();
 
-            new System.Threading.Thread(async () =>
+            //鍙戦�佸箍鎾暟鎹�
+            StartSendBroadcastData();
+
+            //鎺ユ敹骞挎挱鏁版嵁
+            StartReceiveBroadcastData();
+
+            ///寮�鍚繙绋嬭繛鎺�
+            StartRemoteMqtt();
+        }
+
+        #endregion
+
+        #region 鈻� 鍙戦�佸箍鎾暟鎹甠______________________
+
+        /// <summary>
+        /// 鍙戦�佸箍鎾暟鎹�
+        /// </summary>
+        private static void StartSendBroadcastData()
+        {
+            new System.Threading.Thread(() =>
             {
-                var gateWayList = new List<ZbGateway> { };
-                var searchCount = 6;
+                var searchCount = 3;
                 var broadBytes = new byte[44];// byteHomeId[0] ,//H
                 broadBytes[0] = 0xfe;
                 broadBytes[1] = 0x29;
@@ -54,56 +78,18 @@
                 {
                     try
                     {
-                        if (string.IsNullOrEmpty(Shared.Common.Config.Instance.HomeId))
-                        {
-                            //浣忓畢ID涓虹┖鍙湁涓�绉嶅彲鑳藉氨鏄��鍑轰簡鐧诲綍锛岃繖閲岀殑涓婁竴娆′綇瀹匢D瑕佹竻绌�
-                            oldHomeID = "?";
-                            System.Threading.Thread.Sleep(1000);
-                            continue;
-                        }
-                        //棣栨杩涘叆缃戝叧锛屽拰鍒囨崲浣忓畢浼氭竻闄ょ綉鍏冲垪琛紝閲嶆柊鎼滅储瀛樺偍
-                        if (Shared.Common.Config.Instance.HomeId != oldHomeID)
+                        //妫�娴嬭兘鍚﹀彂閫佸箍鎾�
+                        if (CheckCanSendBroadcast(broadBytes) == false)
                         {
-                            //鍥犱负閭d竴鐬棿锛屾湁鍙兘mqtt浼氬姞鍥炴潵,鎵�浠ュ厛鍔犵紦瀛�
-                            var list = new List<ZbGateway>();
-                            list.AddRange(ZbGateway.GateWayList);
-                            //鐒跺悗娓呯┖鎺�
-                            ZbGateway.GateWayList.Clear();
-                            //鏈�鍚庡啀鏂紑mqtt杩炴帴
-                            for (int i = 0; i < list.Count; i++)
-                            {
-                                list[i].DisConnectLocalMqttClient("1");
-                            }
-                            list.Clear();
-                            oldHomeID = Shared.Common.Config.Instance.HomeId;
-                            var tempBytes = System.Text.Encoding.UTF8.GetBytes(Shared.Common.Config.Instance.HomeId);
-                            System.Array.Copy(tempBytes, 0, broadBytes, 7, 36 < tempBytes.Length ? 36 : tempBytes.Length);
-                            //浣忓畢涓凡缁忓瓨鍦ㄧ殑缃戝叧濡傛灉灞�鍩熺綉涓嶅瓨鍦紝闇�瑕佸湪褰撳墠浣忓畢涓櫄鎷熶竴涓綉鍏矷D鐩稿悓鐨勭綉鍏�
-                            var gateWayFileList = Global.FileListByHomeId().FindAll(obj => obj.StartsWith("Gateway_"));
-                            foreach (var filePath in gateWayFileList)
-                            {
-                                var paths = filePath.Split('_');
-                                if (paths.Length < 3)
-                                    continue;
-
-                                var gateWay = ZbGateway.GateWayList.Find(obj => (obj != null) && (obj.GwId == paths[2]));
-                                if (gateWay == null)
-                                {
-                                    gateWay = new ZbGateway { IsVirtual = true };
-                                    gateWay.GwId = paths[2];
-                                    gateWay.HomeId = Shared.Common.Config.Instance.HomeId;
-                                    ZbGateway.GateWayList.Add(gateWay);
-                                }
-                            }
+                            continue;
                         }
 
                         var broadcastIpAddress = new Shared.Net.NetWiFi().BroadcastIpAddress;
-
                         if (Shared.Application.IsWifi)
                         {
-                            if (0 < gateWayList.Count)
+                            if (0 < listReceiveIP.Count)
                             {
-                                searchCount = 6;
+                                searchCount = 3;
                                 ZbGateway.IsRemote = false;
                                 //褰撶綉鍏崇殑杩炴帴鏂瑰紡鏀瑰彉鏃�,璁板綍褰撳墠鐨勮繛鎺ユ柟寮�
                                 Shared.Phone.UserCenter.HdlGatewayLogic.Current.CheckGatewayByConnectChanged(Shared.Phone.UserCenter.GatewayConnectMode.WIFI);
@@ -128,177 +114,191 @@
                             {
                                 ZbGateway.GateWayList[i].DisConnectLocalMqttClient("1");
                             }
+                            //闈瀢ifi鎯呭喌涓�,涓嶉渶瑕佸箍鎾�
+                            System.Threading.Thread.Sleep(1000);
+                            continue;
                         }
-
                         searchCount--;
 
-                        #region 1绉掓悳绱竴娆$綉鍏�
-                        //姣�0.5绉掑箍鎾彂鐜颁竴娆$綉鍏筹紝鍏�1s
+                        //姣忕骞挎挱鍙戠幇涓�娆$綉鍏�
                         int count = 2;
-                        new System.Threading.Thread(() =>
-                        {
-                            gateWayList.Clear();
-                            while (0 < count--)
-                            {
-                                try
-                                {
-                                    //鐐瑰鐐瑰彂閫�(鍏堝彂涓�鏉″凡鏈夌殑鐐规挱锛屽洖澶嶅嚑鐜囬珮涓�鐐癸級
-                                    for (int i = 0; i < gateWayList.Count; i++)
-                                    {
-                                        FindGateWaySocket.BeginSend(new System.Net.IPEndPoint(System.Net.IPAddress.Parse(gateWayList[i].GwIP), 7624), broadBytes);
-                                    }
-                                    //骞挎挱鍙戦��
-                                    if (broadcastIpAddress.ToString() != "0.0.0.0")
-                                    {
-                                        FindGateWaySocket.BeginSend(new System.Net.IPEndPoint(broadcastIpAddress, 7624), broadBytes);
-                                    }
-                                }
-                                catch{}
-                                System.Threading.Thread.Sleep(500);
-                            }
-                        })
-                        { IsBackground = true }.Start();
-
-                        while (0 < count)
+                        listReceiveIP.Clear();
+                        while (0 < count--)
                         {
-                            try
+                            //鐐瑰鐐瑰彂閫�(鍏堝彂涓�鏉″凡鏈夌殑鐐规挱锛屽洖澶嶅嚑鐜囬珮涓�鐐癸級
+                            for (int i = 0; i < listReceiveIP.Count; i++)
                             {
-                                if (FindGateWaySocket.busSocket == null)
-                                {
-                                    System.Threading.Thread.Sleep(100);
-                                    continue;
-                                }
-                                var bytes = new byte[1024];
-
-                                var len = FindGateWaySocket.busSocket.Receive(bytes, bytes.Length, System.Net.Sockets.SocketFlags.None);
-                                if (bytes[43] == 0xA2)
-                                {
-                                    //骞挎挱鍥炲缃戝叧鐨勫熀鏈俊鎭鐞�
-                                    var ipAddress = $"{bytes[3]}.{bytes[4]}.{bytes[5]}.{bytes[6]}";
-                                    var homeID = System.Text.Encoding.UTF8.GetString(bytes, 7, 36);
-                                    homeID = homeID.Replace('\0', ' ').Trim();
-                                    var isMainGateWay = bytes[44] == 1;
-                                    var time = (bytes[48] & 0xff) << 24 | (bytes[47] & 0xff) << 16 | (bytes[46] & 0xff) << 8 | (bytes[45] & 0xff);
-                                    var gwNameLength = bytes[49];
-                                    var gwName = System.Text.Encoding.UTF8.GetString(bytes, 50, gwNameLength);
-                                    var gwIdLength = bytes[49 + gwNameLength + 1];
-                                    var id = Encoding.UTF8.GetString(bytes, 49 + gwNameLength + 2, gwIdLength);
-                                    var pubKeyLengthByte0 = bytes[49 + gwNameLength + 1 + gwIdLength + 1];
-                                    var pubKeyLengthByte1 = bytes[49 + gwNameLength + 1 + gwIdLength + 2];
-                                    int pubKeyLength = ((pubKeyLengthByte1 & 0xff) << 8 | (pubKeyLengthByte0 & 0xff));
-                                    var pubKey = Encoding.UTF8.GetString(bytes, 49 + gwNameLength + 1 + gwIdLength + 2 + 1, pubKeyLength);
-                                    var zbGateWay = new ZbGateway
-                                    {
-                                        GwIP = ipAddress,
-                                        GwName = gwName,
-                                        HomeId = homeID,
-                                        IsMainGateWay = isMainGateWay,
-                                        GwId = id,
-                                        GatewayOnlineFlage = true,
-                                        PubKey = pubKey
-                                    };
-                                    //閫氳鍒扮綉鍏冲垪琛�
-                                    if (gateWayList.Find(obj => obj.GwId == zbGateWay.GwId) == null)
-                                    {
-                                        //缃戝叧鍖归厤褰撳墠浣忓畢涓埌缃戝叧
-                                        if (Shared.Common.Config.Instance.HomeId == homeID)
-                                        {
-                                            gateWayList.Add(zbGateWay);
-                                        }
-                                        //UI鐣岄潰姝e湪鎼滅储锛屼笉蹇呴厤褰撳墠浣忓畢鍒板埌缃戝叧姝ゆ椂涔熼�氳
-                                        else if (IsSearchingGateway)
-                                        {
-                                            gateWayList.Add(zbGateWay);
-                                        }
-                                        //缃戝叧涓埌浣忓畢ID涓虹┖姝ゆ椂涔熼�氳 2020.01.14鍙樻洿锛氭病杩欎釜蹇呰,涓婇潰閭d釜鍙橀噺灏辫兘澶勭悊
-                                        //else if (homeID == string.Empty)
-                                        //{
-                                        //    gateWayList.Add(zbGateWay);
-                                        //}
-                                    }
-                                    //缃戝叧鍒楄〃瀛樺偍澶勭悊
-                                    var gateWay = ZbGateway.GateWayList.Find(obj => obj.GwId == zbGateWay.GwId);
-                                    if (gateWay == null)
-                                    {
-                                        ZbGateway.GateWayList.Add(zbGateWay);
-                                        await zbGateWay.StartLocalMqtt(ipAddress);
-                                        NewGateWayAction?.Invoke(zbGateWay);
-                                    }
-                                    else
-                                    {
-                                        gateWay.IsVirtual = false;
-                                        //灏嗚缃戝叧鏍囪瘑涓恒�愬彲鎼滅储鍒帮紝鍗筹細鍦ㄧ嚎銆�
-                                        gateWay.GatewayOnlineFlage = true;
-                                        if (gateWay.GwIP != ipAddress)
-                                        {
-                                            await gateWay.DisConnectLocalMqttClient("2");
-                                            ZbGateway.GateWayList.Remove(gateWay);
-                                            gateWay = zbGateWay;
-                                            ZbGateway.GateWayList.Add(gateWay);
-                                            await zbGateWay.StartLocalMqtt(ipAddress);
-                                        }
-                                        else
-                                        {
-                                            gateWay.PubKey = pubKey;
-                                            gateWay.GwName = gwName;
-                                            gateWay.HomeId = homeID;
-                                            await gateWay.StartLocalMqtt(ipAddress);
-                                        }
-
-                                        //涓荤綉鍏宠缃�
-                                        if (isMainGateWay && oldHomeID == gateWay.HomeId)
-                                        {
-                                            for (int i = 0; i < ZbGateway.GateWayList.Count; i++)
-                                            {
-                                                var gw = ZbGateway.GateWayList[i];
-                                                //缃戝叧ID涓嶆槸褰撳墠鐨勭綉鍏筹紝鍒欐妸缃戝叧鍒楄〃涓叾浠栫綉鍏虫爣璁颁负涓嶆槸涓荤綉鍏�
-                                                if (gw.GwId != id && oldHomeID == gw.HomeId)
-                                                {
-                                                    gw.IsMainGateWay = false;
-                                                }
-                                            }
-                                            //鏍囪褰撳墠缃戝叧鏄富缃戝叧
-                                            gateWay.IsMainGateWay = true;
-                                        }
-                                    }
-
-                                    //娴嬭瘯鑳藉惁骞挎挱寰楀埌缃戝叧,閫氬父鎯呭喌涓嬩笉妫�娴�
-                                    if (Shared.Phone.UserCenter.UserCenterResourse.HideOption.CheckCanReceiveGateway == 1)
-                                    {
-                                        if (Shared.Phone.UserCenter.UserCenterResourse.DicReceiveGatewayTest.ContainsKey(id) == false)
-                                        {
-                                            if (gateWay == null)
-                                            {
-                                                Shared.Phone.UserCenter.UserCenterResourse.DicReceiveGatewayTest[id] = zbGateWay;
-                                            }
-                                            else
-                                            {
-                                                Shared.Phone.UserCenter.UserCenterResourse.DicReceiveGatewayTest[id] = gateWay;
-                                            }
-                                        }
-                                    }
-                                }
-                                else
-                                {
-                                    //璋冭瘯鐢�
-                                    if (Shared.Phone.UserCenter.UserCenterResourse.HideOption.WriteSocketReceiveDataToFile == 1)
-                                    {
-                                        var data33 = Encoding.UTF8.GetString(bytes).Replace("锟�)", string.Empty).TrimStart('\0').TrimEnd('\0');
-                                        Shared.Phone.UserCenter.HdlLogLogic.Current.WriteLog(3, data33);
-                                    }
-                                }
+                                FindGateWaySocket.BeginSend(new System.Net.IPEndPoint(System.Net.IPAddress.Parse(listReceiveIP[i]), 7624), broadBytes);
                             }
-                            catch{}
+                            //骞挎挱鍙戦��
+                            if (broadcastIpAddress.ToString() != "0.0.0.0")
+                            {
+                                FindGateWaySocket.BeginSend(new System.Net.IPEndPoint(broadcastIpAddress, 7624), broadBytes);
+                            }
+                            System.Threading.Thread.Sleep(1000);
                         }
-                        #endregion
                     }
                     catch { }
-                    System.Threading.Thread.Sleep(500);
                 }
             })
             { IsBackground = true }.Start();
+        }
 
-            ///杩滅▼涓荤綉鍏虫洿鏂�
+        #endregion
+
+        #region 鈻� 鎺ユ敹骞挎挱鏁版嵁_______________________
+
+        /// <summary>
+        /// 鎺ユ敹骞挎挱鏁版嵁
+        /// </summary>
+        private static void StartReceiveBroadcastData()
+        {
+            //鏁版嵁鎺ユ敹
+            new System.Threading.Thread(async () =>
+            {
+                while (true)
+                {
+                    try
+                    {
+                        if (FindGateWaySocket.busSocket == null || FindGateWaySocket.busSocket.Available <= 0)
+                        {
+                            System.Threading.Thread.Sleep(500);
+                            continue;
+                        }
+                        var bytes = new byte[1024];
+                        var len = FindGateWaySocket.busSocket.Receive(bytes, bytes.Length, System.Net.Sockets.SocketFlags.None);
+                        if (bytes[43] == 0xA2)
+                        {
+                            //骞挎挱鍥炲缃戝叧鐨勫熀鏈俊鎭鐞�
+                            var ipAddress = $"{bytes[3]}.{bytes[4]}.{bytes[5]}.{bytes[6]}";
+                            var homeID = System.Text.Encoding.UTF8.GetString(bytes, 7, 36);
+                            homeID = homeID.Replace('\0', ' ').Trim();
+                            var isMainGateWay = bytes[44] == 1;
+                            var time = (bytes[48] & 0xff) << 24 | (bytes[47] & 0xff) << 16 | (bytes[46] & 0xff) << 8 | (bytes[45] & 0xff);
+                            var gwNameLength = bytes[49];
+                            var gwName = System.Text.Encoding.UTF8.GetString(bytes, 50, gwNameLength);
+                            var gwIdLength = bytes[49 + gwNameLength + 1];
+                            var id = Encoding.UTF8.GetString(bytes, 49 + gwNameLength + 2, gwIdLength);
+                            var pubKeyLengthByte0 = bytes[49 + gwNameLength + 1 + gwIdLength + 1];
+                            var pubKeyLengthByte1 = bytes[49 + gwNameLength + 1 + gwIdLength + 2];
+                            int pubKeyLength = ((pubKeyLengthByte1 & 0xff) << 8 | (pubKeyLengthByte0 & 0xff));
+                            var pubKey = Encoding.UTF8.GetString(bytes, 49 + gwNameLength + 1 + gwIdLength + 2 + 1, pubKeyLength);
+                            var zbGateWay = new ZbGateway
+                            {
+                                GwIP = ipAddress,
+                                GwName = gwName,
+                                HomeId = homeID,
+                                IsMainGateWay = isMainGateWay,
+                                GwId = id,
+                                GatewayOnlineFlage = true,
+                                PubKey = pubKey
+                            };
+                            //閫氳鍒扮綉鍏冲垪琛�
+                            if (listReceiveIP.Find(obj => obj == zbGateWay.GwId) == null)
+                            {
+                                //缃戝叧鍖归厤褰撳墠浣忓畢涓埌缃戝叧
+                                if (Shared.Common.Config.Instance.HomeId == homeID)
+                                {
+                                    listReceiveIP.Add(ipAddress);
+                                }
+                                //UI鐣岄潰姝e湪鎼滅储锛屼笉蹇呴厤褰撳墠浣忓畢鍒板埌缃戝叧姝ゆ椂涔熼�氳
+                                else if (IsSearchingGateway)
+                                {
+                                    listReceiveIP.Add(ipAddress);
+                                }
+                            }
+                            //缃戝叧鍒楄〃瀛樺偍澶勭悊
+                            var gateWay = ZbGateway.GateWayList.Find(obj => obj.GwId == zbGateWay.GwId);
+                            if (gateWay == null)
+                            {
+                                ZbGateway.GateWayList.Add(zbGateWay);
+                                await zbGateWay.StartLocalMqtt(ipAddress);
+                            }
+                            else
+                            {
+                                gateWay.IsVirtual = false;
+                                //灏嗚缃戝叧鏍囪瘑涓恒�愬彲鎼滅储鍒帮紝鍗筹細鍦ㄧ嚎銆�
+                                gateWay.GatewayOnlineFlage = true;
+                                if (gateWay.GwIP != ipAddress)
+                                {
+                                    await gateWay.DisConnectLocalMqttClient("2");
+                                    ZbGateway.GateWayList.Remove(gateWay);
+                                    gateWay = zbGateWay;
+                                    ZbGateway.GateWayList.Add(gateWay);
+                                    await zbGateWay.StartLocalMqtt(ipAddress);
+                                }
+                                else
+                                {
+                                    gateWay.PubKey = pubKey;
+                                    gateWay.GwName = gwName;
+                                    gateWay.HomeId = homeID;
+                                    await gateWay.StartLocalMqtt(ipAddress);
+                                }
+
+                                //涓荤綉鍏宠缃�
+                                if (isMainGateWay && oldHomeID == gateWay.HomeId)
+                                {
+                                    for (int i = 0; i < ZbGateway.GateWayList.Count; i++)
+                                    {
+                                        var gw = ZbGateway.GateWayList[i];
+                                        //缃戝叧ID涓嶆槸褰撳墠鐨勭綉鍏筹紝鍒欐妸缃戝叧鍒楄〃涓叾浠栫綉鍏虫爣璁颁负涓嶆槸涓荤綉鍏�
+                                        if (gw.GwId != id && oldHomeID == gw.HomeId)
+                                        {
+                                            gw.IsMainGateWay = false;
+                                        }
+                                    }
+                                    //鏍囪褰撳墠缃戝叧鏄富缃戝叧
+                                    gateWay.IsMainGateWay = true;
+                                }
+                            }
+
+                            //娴嬭瘯鑳藉惁骞挎挱寰楀埌缃戝叧,閫氬父鎯呭喌涓嬩笉妫�娴�
+                            if (Shared.Phone.UserCenter.UserCenterResourse.HideOption.CheckCanReceiveGateway == 1)
+                            {
+                                if (Shared.Phone.UserCenter.UserCenterResourse.DicReceiveGatewayTest == null)
+                                {
+                                    //闃叉寮傚父,铏界劧鍑犵巼寰堜綆
+                                    Shared.Phone.UserCenter.UserCenterResourse.HideOption.CheckCanReceiveGateway = 0;
+                                    continue;
+                                }
+                                if (Shared.Phone.UserCenter.UserCenterResourse.DicReceiveGatewayTest.ContainsKey(id) == false)
+                                {
+                                    if (gateWay == null)
+                                    {
+                                        Shared.Phone.UserCenter.UserCenterResourse.DicReceiveGatewayTest[id] = zbGateWay;
+                                    }
+                                    else
+                                    {
+                                        Shared.Phone.UserCenter.UserCenterResourse.DicReceiveGatewayTest[id] = gateWay;
+                                    }
+                                }
+                            }
+                        }
+                        else
+                        {
+                            //璋冭瘯鐢�
+                            if (Shared.Phone.UserCenter.UserCenterResourse.HideOption.WriteSocketReceiveDataToFile == 1)
+                            {
+                                var data33 = Encoding.UTF8.GetString(bytes).Replace("锟�)", string.Empty).TrimStart('\0').TrimEnd('\0');
+                                Shared.Phone.UserCenter.HdlLogLogic.Current.WriteLog(3, data33);
+                            }
+                        }
+                    }
+                    catch { }
+                }
+            })
+            { IsBackground = true }.Start();
+        }
+
+        #endregion
+
+        #region 鈻� 寮�鍚繙绋嬭繛鎺______________________
+
+        /// <summary>
+        /// 寮�鍚繙绋嬭繛鎺�
+        /// </summary>
+        private static void StartRemoteMqtt()
+        {
             new System.Threading.Thread(async () =>
             {
                 while (true)
@@ -315,6 +315,10 @@
             { IsBackground = true }.Start();
         }
 
+        #endregion
+
+        #region 鈻� 涓�鑸柟娉昣__________________________
+
         /// <summary>
         /// 閲嶆柊鎼滅储,娉ㄦ剰锛氳皟鐢ㄨ鏂规硶,鍒欎績浣垮叏閮ㄧ綉鍏崇殑mqtt鍏ㄩ儴鏂紑,鐒跺悗閲嶆柊鎼滅储(鍙兘浼氭湁1绉掑欢杩�)
         /// </summary>
@@ -323,6 +327,61 @@
             //涓轰簡閭d箞澶氬皯涓囧垎涔嬩竴鐨勫嚑鐜�,杩欓噷璁剧疆鎴愬埆鐨勫彟涓�绫荤殑鍊�
             oldHomeID = "**";
         }
+
+        /// <summary>
+        /// 妫�娴嬭兘鍚﹀彂閫佸箍鎾�
+        /// </summary>
+        /// <returns></returns>
+        private static bool CheckCanSendBroadcast(byte[] broadBytes)
+        {
+            if (string.IsNullOrEmpty(Config.Instance.HomeId))
+            {
+                //浣忓畢ID涓虹┖鍙湁涓�绉嶅彲鑳藉氨鏄��鍑轰簡鐧诲綍锛岃繖閲岀殑涓婁竴娆′綇瀹匢D瑕佹竻绌�
+                oldHomeID = "?";
+                System.Threading.Thread.Sleep(1000);
+                return false;
+            }
+            //棣栨杩涘叆缃戝叧锛屽拰鍒囨崲浣忓畢浼氭竻闄ょ綉鍏冲垪琛紝閲嶆柊鎼滅储瀛樺偍
+            if (Config.Instance.HomeId != oldHomeID)
+            {
+                //鍥犱负閭d竴鐬棿锛屾湁鍙兘mqtt浼氬姞鍥炴潵,鎵�浠ュ厛鍔犵紦瀛�
+                var list = new List<ZbGateway>();
+                list.AddRange(ZbGateway.GateWayList);
+                //鐒跺悗娓呯┖鎺�
+                ZbGateway.GateWayList.Clear();
+                //鏈�鍚庡啀鏂紑mqtt杩炴帴
+                for (int i = 0; i < list.Count; i++)
+                {
+                    list[i].DisConnectLocalMqttClient("1");
+                }
+                list.Clear();
+                oldHomeID = Shared.Common.Config.Instance.HomeId;
+                var tempBytes = System.Text.Encoding.UTF8.GetBytes(Shared.Common.Config.Instance.HomeId);
+                System.Array.Copy(tempBytes, 0, broadBytes, 7, 36 < tempBytes.Length ? 36 : tempBytes.Length);
+                //浣忓畢涓凡缁忓瓨鍦ㄧ殑缃戝叧濡傛灉灞�鍩熺綉涓嶅瓨鍦紝闇�瑕佸湪褰撳墠浣忓畢涓櫄鎷熶竴涓綉鍏矷D鐩稿悓鐨勭綉鍏�
+                var gateWayFileList = Global.FileListByHomeId().FindAll(obj => obj.StartsWith("Gateway_"));
+                foreach (var filePath in gateWayFileList)
+                {
+                    var paths = filePath.Split('_');
+                    if (paths.Length < 3)
+                        continue;
+
+                    var gateWay = ZbGateway.GateWayList.Find(obj => (obj != null) && (obj.GwId == paths[2]));
+                    if (gateWay == null)
+                    {
+                        gateWay = new ZbGateway { IsVirtual = true };
+                        gateWay.GwId = paths[2];
+                        gateWay.HomeId = Config.Instance.HomeId;
+                        ZbGateway.GateWayList.Add(gateWay);
+                    }
+                }
+            }
+            return true;
+        }
+
+        #endregion
+
+        #region 鈻� Socket_____________________________
 
         /// <summary>
         /// 鎺ユ敹澶勭悊UDP鏁版嵁鍖�
@@ -356,13 +415,9 @@
             /// </summary>
             public static void Stop()
             {
-                if (!IsRunning)
-                {
-                    return;
-                }
                 try
                 {
-                    busSocket.Close();
+                    busSocket?.Close();
                 }
                 catch { }
                 busSocket = null;
@@ -392,8 +447,8 @@
                     if (IsRunning)
                     {
                         busSocket.BeginSendTo(bytes, 0, bytes.Length, SocketFlags.None, iPEndPoint, new AsyncCallback(asyncEndSend), null);
-                    }
-                    
+                    }
+
                 }
                 catch (Exception ex)
                 {
@@ -415,7 +470,7 @@
                 {
                     int bytesSent = busSocket.EndSendTo(iar);
                 }
-                catch(Exception ex) 
+                catch (Exception ex)
                 {
                     //璋冭瘯鐢�
                     if (Shared.Phone.UserCenter.UserCenterResourse.HideOption.WriteSocketReceiveDataToFile == 1)
@@ -425,5 +480,7 @@
                 }
             }
         }
+
+        #endregion
     }
 }
diff --git a/ZigbeeApp/Shared/Phone/ZigBee/Common/Config.cs b/ZigbeeApp/Shared/Phone/ZigBee/Common/Config.cs
index 973d822..b609fbf 100755
--- a/ZigbeeApp/Shared/Phone/ZigBee/Common/Config.cs
+++ b/ZigbeeApp/Shared/Phone/ZigBee/Common/Config.cs
@@ -56,6 +56,11 @@
                 //瑙e瘑
                 config.Password = Phone.UserCenter.UserCenterLogic.DecryptPassword("hD1(La3o", config.PasswordEncrypt);
             }
+            if (config.Md5pwdEncrypt != string.Empty)
+            {
+                //瑙e瘑
+                config.MD5PWD = Phone.UserCenter.UserCenterLogic.DecryptPassword("hD1(La3o", config.Md5pwdEncrypt);
+            }
         }
 
         /// <summary>
@@ -79,7 +84,12 @@
         /// <summary>
         /// 鐭俊鐧诲綍杩斿洖鐨刴d5鍚庣殑瀵嗙爜
         /// </summary>
+        [Newtonsoft.Json.JsonIgnore]
         public string MD5PWD = string.Empty;
+        /// <summary>
+        /// 鐭俊鐧诲綍杩斿洖鐨刴d5鍚庣殑鍔犲瘑瀵嗙爜
+        /// </summary>
+        public string Md5pwdEncrypt = string.Empty;
         /// <summary>
         /// 鐧婚檰璐﹀彿鐨凣uid
         /// </summary>
@@ -87,10 +97,12 @@
         /// <summary>
         /// 鎴愬憳璇锋眰鎺у埗涓诲笎鍙锋浣忓畢鏃惰姹傚熀鍦板潃
         /// </summary>
+        [Newtonsoft.Json.JsonIgnore]
         public string AdminRequestBaseUrl = string.Empty;
         /// <summary>
         /// 鎴愬憳璇锋眰鎺у埗涓诲笎鍙锋浣忓畢鏃惰姹傚熀鍦板潃鐨凩oginAccessToken鐨勫��
         /// </summary>
+        [Newtonsoft.Json.JsonIgnore]
         public string AdminRequestToken = string.Empty;
         /// <summary>
         /// 杩滅▼杩炴帴鐨凪qtt鐨勫鎴风ID
@@ -193,9 +205,10 @@
         {
             //鍔犲瘑,涓嶈兘淇濆瓨鏄庣爜
             this.PasswordEncrypt = Phone.UserCenter.UserCenterLogic.EncryptPassword("hD1(La3o", this.Password);
+            this.Md5pwdEncrypt = Phone.UserCenter.UserCenterLogic.EncryptPassword("hD1(La3o", this.MD5PWD);
+
             var bytes = System.Text.Encoding.UTF8.GetBytes(Newtonsoft.Json.JsonConvert.SerializeObject(this));
             Shared.IO.FileUtils.WriteFileByBytes(fileName, bytes);
-            ReFresh();
         }
     }
 }
diff --git a/ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs b/ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs
index 0ae3f20..fa16d90 100755
--- a/ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs
+++ b/ZigbeeApp/Shared/Phone/ZigBee/Device/CommonDevice.cs
@@ -166,7 +166,13 @@
         /// 鏄惁宸茬粡璇诲彇浜嗚澶囩姸鎬�(姝ゅ睘鎬ф槸缁欎富椤典娇鐢ㄧ殑)
         /// </summary>
         [Newtonsoft.Json.JsonIgnore]
-        public bool HadReadDeviceStatu = false;
+        public bool HadReadDeviceStatu = false;
+
+        /// <summary>
+        /// 鏄惁鏄綆鐢甸噺(杩欎釜鍙橀噺鐩墠鏄粰浼犳劅鍣ㄧ敤鐨�)
+        /// </summary>
+        [Newtonsoft.Json.JsonIgnore]
+        public bool IsBatteryDown = false;
 
         /// <summary>
         /// 绛夊緟浠庣綉鍏虫帴鏀舵暟鎹殑鏃堕棿
diff --git a/ZigbeeApp/Shared/Phone/ZigBee/Device/ZbGateway.cs b/ZigbeeApp/Shared/Phone/ZigBee/Device/ZbGateway.cs
index 9ff57e4..88a2389 100755
--- a/ZigbeeApp/Shared/Phone/ZigBee/Device/ZbGateway.cs
+++ b/ZigbeeApp/Shared/Phone/ZigBee/Device/ZbGateway.cs
@@ -30,8 +30,22 @@
         public static ZbGateway MainGateWay
         {
             get
-            {
-                return GateWayList.Find((obj) => { return obj.HomeId == Shared.Common.Config.Instance.HomeId && obj.IsMainGateWay; });
+            {
+                ZbGateway mainWay = null;
+                for (int i = 0; i < GateWayList.Count; i++)
+                {
+                    if (GateWayList[i].HomeId == Config.Instance.HomeId)
+                    {
+                        //2020.07.16鍙樻洿:鍒閭d箞澶�,濡傛灉浣忓畢ID涓�鏍�,鍏堢‘瀹氬氨鏄畠浜�(涓嶇劧鏈夋椂鍊欑粡甯歌繑鍥瀗ull,鏈夊彲鑳芥槸鍒锋柊涓嶅埌)
+                        mainWay = GateWayList[i];
+                        if (mainWay.IsMainGateWay == true)
+                        {
+                            //鐒跺悗濡傛灉瀹冪‘瀹炴槸涓荤綉鍏�,鐩存帴break
+                            break;
+                        }
+                    }
+                }
+                return mainWay;
             }
         }
 
@@ -2335,7 +2349,7 @@
         /// </summary>
         static Guid currentGuid = Guid.NewGuid();
 
-        public async System.Threading.Tasks.Task SendAesKey()
+        public async Task SendAesKey()
         {
             if (PubKey != null)
             {
@@ -2354,12 +2368,11 @@
             }
         }
 
-        public async System.Threading.Tasks.Task StartLocalMqtt(string brokerName)
+        public async Task StartLocalMqtt(string brokerName)
         {
             if (localMqttIsConnecting
-                       || !Shared.Common.Config.Instance.IsLogin
-                       || Shared.Common.Config.Instance.HomeId == ""
-                       || localIsConnected)
+                || Shared.Common.Config.Instance.HomeId == ""
+                || localIsConnected)
             {
                 return;
             }
@@ -2467,7 +2480,7 @@
         /// 鑾峰彇褰撳墠甯愬彿鎵�鏈夌殑缃戝叧淇℃伅
         /// </summary>
         /// <returns></returns>
-        static async System.Threading.Tasks.Task initGateWayBaseInfomation()
+        static async Task initGateWayBaseInfomation()
         {
             if (AllowRemoteCtrl == false)
             {
@@ -2558,23 +2571,37 @@
         public static IMqttClient RemoteMqttClient = new MqttFactory().CreateMqttClient();
         static bool remoteIsConnected;
 
+        /// <summary>
+        /// 杩滅▼寮�濮嬭繛鎺ョ殑鏃堕棿鐐�
+        /// </summary>
+        private static DateTime RemoteConnectTime = DateTime.Now;
         /// <summary>
         /// 鍚姩杩滅▼Mqtt
         /// </summary>
         /// <returns>The start.</returns>
         /// <param name="brokerName">Broker name.</param>
-        public static async System.Threading.Tasks.Task StartRemoteMqtt()
+        public static async Task StartRemoteMqtt()
         {
             //杩藉姞锛氭病鏈夎繙绋嬭繛鎺ョ殑鏉冮檺
             if (AllowRemoteCtrl == false
-               || remoteMqttIsConnecting
-               || !Shared.Common.Config.Instance.IsLogin
                || Shared.Common.Config.Instance.HomeId == ""
                || remoteIsConnected)
             {
                 return;
             }
-            await System.Threading.Tasks.Task.Factory.StartNew(async () =>
+            //濡傛灉杩滅▼杩樺湪杩炴帴涓�
+            if (remoteMqttIsConnecting == true)
+            {
+                //濡傛灉杩欎釜鍙橀噺涓�鐩村浜庤繛鎺ヤ腑鐨勭姸鎬�,浣嗘槸宸茬粡杩囧幓浜�10绉掍簡,杩樻槸true鐨勮瘽,璇存槑杩欓噷鏄湁鐐归棶棰樼殑,闇�瑕侀噸鏂板垱寤�
+                if ((DateTime.Now - RemoteConnectTime).TotalMilliseconds < 10 * 1000)
+                {
+                    return;
+                }
+            }
+            //璁板綍璧疯繖娆¤繙绋嬭繛鎺ョ殑鏃堕棿鐐�
+            RemoteConnectTime = DateTime.Now;
+
+            await Task.Factory.StartNew(async () =>
             {
                 try
                 {
@@ -2724,8 +2751,6 @@
                                 AllowRemoteCtrl = false;
                                 return;
                             }
-                            //铏界劧涓嶇煡閬撳鎸や笅绾块偅涓�鍧楁湁娌℃湁鐢�,涓嶈繃鍏堣繖涔堝紕
-                            await System.Threading.Tasks.Task.Delay(1500);
 
                             var responseData = jobject["ResponseData"];
                             if (responseData != null)
@@ -2773,13 +2798,15 @@
         /// <summary>
         /// 鏂紑鏈嶅姟鍣ㄨ繛鎺�
         /// </summary>
-        public async System.Threading.Tasks.Task DisConnectLocalMqttClient(string s)
+        public async Task DisConnectLocalMqttClient(string s)
         {
             try
             {
                 if (localIsConnected)
                 {
                     localIsConnected = false;
+                    //杩欎釜涓滆タ涔熻寮�
+                    localMqttIsConnecting = false;
                     DebugPrintLog($"Local涓诲姩鏂紑_{s}");
                     //await localMqttClient.DisconnectAsync(new MQTTnet.Client.Disconnecting.MqttClientDisconnectOptions {  }, CancellationToken.None);
                     await localMqttClient.DisconnectAsync();
@@ -2794,13 +2821,15 @@
         /// <summary>
         /// 鏂紑杩滅▼Mqtt鐨勯摼鎺�
         /// </summary>
-        public static async System.Threading.Tasks.Task DisConnectRemoteMqttClient(string s = "")
+        public static async Task DisConnectRemoteMqttClient(string s = "")
         {
             try
             {
                 if (remoteIsConnected)
                 {
                     remoteIsConnected = false;
+                    //杩欎釜涓滆タ涔熻寮�
+                    remoteMqttIsConnecting = false;
                     DebugPrintLog($"Remote涓诲姩鏂紑_{s}");
                     //await RemoteMqttClient.DisconnectAsync(new MQTTnet.Client.Disconnecting.MqttClientDisconnectOptions { }, CancellationToken.None);
                     await RemoteMqttClient.DisconnectAsync();
diff --git a/ZigbeeApp/Shared/R.cs b/ZigbeeApp/Shared/R.cs
old mode 100644
new mode 100755
index 646002c..aef72af
--- a/ZigbeeApp/Shared/R.cs
+++ b/ZigbeeApp/Shared/R.cs
@@ -958,7 +958,7 @@
 
 
         /// <summary>
-        /// HDL Home
+        /// Evoyo Home
         /// </summary>
         public const int AppName = 10000;
         /// <summary>
@@ -5817,12 +5817,35 @@
         /// <summary>
         /// 闇�閲嶆柊缁戝畾
         /// </summary>
-        public const int uNeedToRebind = 16136;
-        /// <summary>
-        /// 鍑虹幇鎰忓鎯呭喌,鏁版嵁涓㈠け
+        public const int uNeedToRebind = 16136;
+        /// <summary>
+        /// 鍑虹幇鎰忓鎯呭喌,鏁版嵁涓㈠け
         /// </summary>
         public const int uUnKnownErrorAndLostData = 16137;
-
+        /// <summary>
+        /// 鐑熼浘浼犳劅鍣�
+        /// </summary>
+        public const int uSensorFire = 16138;
+        /// <summary>
+        /// 姘翠镜浼犳劅鍣�
+        /// </summary>
+        public const int uSensorWater = 16139;
+        /// <summary>
+        /// 鐕冩皵浼犳劅鍣�
+        /// </summary>
+        public const int uSensorCarbonMonoxide = 16140;
+        /// <summary>
+        /// 绱ф�ユ寜閽�
+        /// </summary>
+        public const int uSensorEmergencyButton = 16141;
+        /// <summary>
+        /// 闂ㄧ獥浼犳劅鍣�
+        /// </summary>
+        public const int uSensorDoorWindow = 16142;
+        /// <summary>
+        /// 閽ュ寵鎵�
+        /// </summary>
+        public const int uKeyfob = 16143;
 
 
         //鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄帴鍙g殑杩斿洖淇℃伅缈昏瘧,浠�18000寮�濮嬧槄鈽呪槄鈽�
@@ -6063,193 +6086,8 @@
         /// </summary>
         public const int uAddSensorSphericalMotionMsg = 21024;
 
-        //鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄ā鍧桰D鐨勫畼鏂瑰悕瀛�,浠�30000寮�濮嬧槄鈽呪槄鈽�
-        /// <summary>
-        /// 闀滃儚ID涓�1305(鏆傚畾)鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱揣鎬ユ寜閽�
-        /// </summary>
-        public const int uDeviceModelId1305 = 30000;
-        /// <summary>
-        /// 闀滃儚ID涓�1300(鏆傚畾)鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱噧姘斾紶鎰熷櫒
-        /// </summary>
-        public const int uDeviceModelId1300 = 30001;
-        /// <summary>
-        /// 闀滃儚ID涓�1302(鏆傚畾)鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱儫闆句紶鎰熷櫒
-        /// </summary>
-        public const int uDeviceModelId1302 = 30002;
-        /// <summary>
-        /// 闀滃儚ID涓�1304(鏆傚畾)鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氭按娴镐紶鎰熷櫒
-        /// </summary>
-        public const int uDeviceModelId1304 = 30003;
-        /// <summary>
-        /// 閽ュ寵鎵�
-        /// </summary>
-        public const int uKeyfob = 30004;
-        /// <summary>
-        /// 闀滃儚ID涓�1301(鏆傚畾)鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氶棬绐椾紶鎰熷櫒
-        /// </summary>
-        public const int uDeviceModelId1301 = 30005;
-        /// <summary>
-        /// 闀滃儚ID涓�4100鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氭櫤鑳界┖寮�
-        /// </summary>
-        public const int uDeviceModelId4100 = 30006;
-        /// <summary>
-        /// 闀滃儚ID涓�100鐨勮澶囩殑瀹樻柟鍚嶅瓧锛歓igbee鏅鸿兘寮�鍚堝笜鐢垫満
-        /// </summary>
-        public const int uDeviceModelId100 = 30007;
-        /// <summary>
-        /// 闀滃儚ID涓�200鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�4鎸夐敭澶氬姛鑳借Е鎽搁潰鏉�(甯�4璺户鐢靛櫒搴曞骇)
-        /// </summary>
-        public const int uDeviceModelId200 = 30008;
-        /// <summary>
-        /// 闀滃儚ID涓�1200鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�220Pir浼犳劅鍣�
-        /// </summary>
-        public const int uDeviceModelId1200 = 30009;
-        /// <summary>
-        /// 闀滃儚ID涓�1鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�1浠igbee缃戝叧(146搴曠洅澧欒妯″紡)
-        /// </summary>
-        public const int uDeviceModelId1 = 30010;
-        /// <summary>
-        /// 闀滃儚ID涓�201鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�3鎸夐敭澶氬姛鑳借Е鎽搁潰鏉�(甯�3璺户鐢靛櫒搴曞骇)
-        /// </summary>
-        public const int uDeviceModelId201 = 30011;
-        /// <summary>
-        /// 闀滃儚ID涓�202鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�2鎸夐敭澶氬姛鑳借Е鎽搁潰鏉�(甯�2璺户鐢靛櫒搴曞骇)
-        /// </summary>
-        public const int uDeviceModelId202 = 30012;
-        /// <summary>
-        /// 闀滃儚ID涓�2300鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�3璺户鐢靛櫒灏忔ā鍧�
-        /// </summary>
-        public const int uDeviceModelId2300 = 30013;
-        /// <summary>
-        /// 闀滃儚ID涓�6鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�1浠igbee缃戝叧(楂樼骇缃戝叧妗岄潰妯″紡)
-        /// </summary>
-        public const int uDeviceModelId6 = 30014;
-        /// <summary>
-        /// 闀滃儚ID涓�0鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氳皟璇曡澶�
-        /// </summary>
-        public const int uDeviceModelId0 = 30015;
-        /// <summary>
-        /// 闀滃儚ID涓�101鐨勮澶囩殑瀹樻柟鍚嶅瓧锛歓igbee鏅鸿兘绠$姸鐢垫満
-        /// </summary>
-        public const int uDeviceModelId101 = 30016;
-        /// <summary>
-        /// 闀滃儚ID涓�3900鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氫腑缁у櫒
-        /// </summary>
-        public const int uDeviceModelId3900 = 30017;
-        /// <summary>
-        /// 闀滃儚ID涓�203鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�12鎸夐敭澶氬姛鑳借Е鎽搁潰鏉�(甯�1璺户鐢靛櫒搴曞骇)
-        /// </summary>
-        public const int uDeviceModelId203 = 30018;
-        /// <summary>
-        /// 闀滃儚ID涓�210鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�4鎸夐敭澶氬姛鑳借Е鎽搁潰鏉�(鍙甫鐢垫簮搴曞骇)
-        /// </summary>
-        public const int uDeviceModelId210 = 30019;
-        /// <summary>
-        /// 闀滃儚ID涓�1303(鏆傚畾)鐨勫畼鏂圭殑榛樿鍚嶅瓧锛氱孩澶栦紶鎰熷櫒
-        /// </summary>
-        public const int uDeviceModelId1303 = 30020;
-        /// <summary>
-        /// 闀滃儚ID涓�2500鐨勮澶囩殑瀹樻柟鍚嶅瓧锛�1璺皟鍏夊櫒灏忔ā鍧�
-        /// </summary>
-        public const int uDeviceModelId2500 = 30021;
-        /// <summary>
-        /// 闀滃儚ID涓�4200鐨勮澶囩殑瀹樻柟鍚嶅瓧锛歾igbee杞琤uspro鍗忚杞崲鍣�
-        /// </summary>
-        public const int uDeviceModelId4200 = 30022;
-        /// <summary>
-        /// 闀滃儚ID涓�4201鐨勮澶囩殑瀹樻柟鍚嶅瓧锛歾igbee杞�485鍗忚杞崲鍣�
-        /// </summary>
-        public const int uDeviceModelId4201 = 30023;
-        /// <summary>
-        /// 闀滃儚ID涓�3600鐨勮澶囩殑瀹樻柟鍚嶅瓧锛歾igbee绌鸿皟缃戝叧妯″潡
-        /// </summary>
-        public const int uDeviceModelId3600 = 30024;
-        /// <summary>
-        /// 闀滃儚ID涓�2800鐨勮澶囩殑瀹樻柟鍚嶅瓧锛欻06C
-        /// </summary>
-        public const int uDeviceModelId2800 = 30025;
-        /// <summary>
-        /// 闀滃儚ID涓�220鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱畝绾�4鎸夐敭闈㈡澘
-        /// </summary>
-        public const int uDeviceModelId220 = 30026;
-        /// <summary>
-        /// 闀滃儚ID涓�221鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱畝绾�3鎸夐敭闈㈡澘
-        /// </summary>
-        public const int uDeviceModelId221 = 30027;
-        /// <summary>
-        /// 闀滃儚ID涓�222鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱畝绾�2鎸夐敭闈㈡澘
-        /// </summary>
-        public const int uDeviceModelId222 = 30028;
-        /// <summary>
-        /// 闀滃儚ID涓�240鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氭柟鎮�2鎸夐敭杞昏Е寮忛潰鏉�
-        /// </summary>
-        public const int uDeviceModelId240 = 30029;
-        /// <summary>
-        /// 闀滃儚ID涓�241鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氭柟鎮�4鎸夐敭杞昏Е寮忛潰鏉�
-        /// </summary>
-        public const int uDeviceModelId241 = 30030;
-        /// <summary>
-        /// 闀滃儚ID涓�242鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氭柟鎮�8鎸夐敭杞昏Е寮忛潰鏉�
-        /// </summary>
-        public const int uDeviceModelId242 = 30031;
-        /// <summary>
-        /// 闀滃儚ID涓�250鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氭柟鎮︽柊椋庨潰鏉�
-        /// </summary>
-        public const int uDeviceModelId250 = 30032;
-        /// <summary>
-        /// 闀滃儚ID涓�253鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氭柟鎮︾幆澧冮潰鏉�
-        /// </summary>
-        public const int uDeviceModelId253 = 30033;
-        /// <summary>
-        /// 闀滃儚ID涓�224鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱畝绾�4鎸夐敭鍦烘櫙闈㈡澘
-        /// </summary>
-        public const int uDeviceModelId224 = 30034;
-        /// <summary>
-        /// 闀滃儚ID涓�226鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱畝绾�2璺獥甯橀潰鏉�
-        /// </summary>
-        public const int uDeviceModelId226 = 30035;
-        /// <summary>
-        /// 闀滃儚ID涓�256鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氭柟鎮�/2璺獥甯橀潰鏉�-Z
-        /// </summary>
-        public const int uDeviceModelId256 = 30036;
-        /// <summary>
-        /// 闀滃儚ID涓�2802鐨勮澶囩殑瀹樻柟鍚嶅瓧锛歋-one
-        /// </summary>
-        public const int uDeviceModelId2802 = 30037;
-        /// <summary>
-        /// 闀滃儚ID涓�2310鐨勮澶囩殑榛樿鍚嶅瓧锛氭柟鎮︽柊椋庡皬妯″潡
-        /// </summary>
-        public const int uDeviceModelId2310 = 30038;
-        /// <summary>
-        /// 闀滃儚ID涓�1306鐨勮澶囩殑榛樿鍚嶅瓧锛歓igbee鍚搁《鐕冩皵浼犳劅鍣�
-        /// </summary>
-        public const int uDeviceModelId1306 = 30039;
-        /// <summary>
-        /// 闀滃儚ID涓�1307鐨勮澶囩殑榛樿鍚嶅瓧锛歅M2.5绌烘皵璐ㄩ噺浼犳劅鍣�
-        /// </summary>
-        public const int uDeviceModelId1307 = 30040;
-        /// <summary>
-        /// 闀滃儚ID涓�212鐨勮澶囩殑榛樿鍚嶅瓧锛氱畝绾﹀鍔熻兘闈㈡澘
-        /// </summary>
-        public const int uDeviceModelId212 = 30041;
-        /// <summary>
-        /// 闀滃儚ID涓�230鐨勮澶囩殑榛樿鍚嶅瓧锛氱畝绾︾幆澧冮潰鏉�
-        /// </summary>
-        public const int uDeviceModelId230 = 30042;
-        /// <summary>
-        /// 闀滃儚ID涓�11鐨勮澶囩殑瀹樻柟鍚嶅瓧锛歁ini缃戝叧
-        /// </summary>
-        public const int uDeviceModelId11 = 30043;
-        /// <summary>
-        /// 闀滃儚ID涓�20000鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氳壊娓╃伅
-        /// </summary>
-        public const int uDeviceModelId20000 = 30044;
-        /// <summary>
-        /// 闀滃儚ID涓�1205鐨勮澶囩殑瀹樻柟鍚嶅瓧锛氱悆鍨嬬Щ鍔ㄤ紶鎰熷櫒
-        /// </summary>
-        public const int uDeviceModelId1205 = 30045;
 
-        //鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄澶囨墍灞炵绫荤殑缈昏瘧鍚嶅瓧,浠�40000寮�濮嬧槄鈽呪槄鈽�
+        //鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄澶囨墍灞炵绫荤殑缈昏瘧鍚嶅瓧,浠�40000寮�濮� 娉細杩欎簺鎵�灞濱D宸茬粡涓嶅啀缁存姢鈽呪槄鈽呪槄
         /// <summary>
         /// 鑷畾涔夎澶囨墍灞濱D涓�100鐨勭炕璇戝悕瀛楋細閬槼
         /// </summary>
@@ -6259,53 +6097,9 @@
         /// </summary>
         public const int uDeviceBelongId200 = 40001;
         /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�1200鐨勭炕璇戝悕瀛楋細浼犳劅鍣�
-        /// </summary>
-        public const int uDeviceBelongId1200 = 40002;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�2300鐨勭炕璇戝悕瀛楋細缁х數鍣�
-        /// </summary>
-        public const int uDeviceBelongId2300 = 40003;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�2500鐨勭炕璇戝悕瀛楋細璋冨厜鍣�
-        /// </summary>
-        public const int uDeviceBelongId2500 = 40004;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�2800鐨勭炕璇戝悕瀛楋細闂ㄩ攣
-        /// </summary>
-        public const int uDeviceBelongId2800 = 40005;
-        /// <summary>
         /// 鑷畾涔夎澶囨墍灞濱D涓�3600鐨勭炕璇戝悕瀛楋細绌鸿皟
         /// </summary>
         public const int uDeviceBelongId3600 = 40006;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�3900鐨勭炕璇戝悕瀛楋細涓户鍣�
-        /// </summary>
-        public const int uDeviceBelongId3900 = 40007;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�4100鐨勭炕璇戝悕瀛楋細鏅鸿兘绌哄紑
-        /// </summary>
-        public const int uDeviceBelongId4100 = 40008;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�4200鐨勭炕璇戝悕瀛楋細杞崲鍣�
-        /// </summary>
-        public const int uDeviceBelongId4200 = 40009;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�9鐨勭炕璇戝悕瀛楋細褰╃伅
-        /// </summary>
-        public const int uDeviceBelongId9 = 40010;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�10鐨勭炕璇戝悕瀛楋細娓╂箍搴︿紶鎰熷櫒
-        /// </summary>
-        public const int uDeviceBelongId10 = 40011;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�11鐨勭炕璇戝悕瀛楋細娓╁害浼犳劅鍣�
-        /// </summary>
-        public const int uDeviceBelongId11 = 40012;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�12鐨勭炕璇戝悕瀛楋細婀垮害浼犳劅鍣�
-        /// </summary>
-        public const int uDeviceBelongId12 = 40013;
         /// <summary>
         /// 鑷畾涔夎澶囨墍灞濱D涓�13鐨勭炕璇戝悕瀛楋細寮�鍏�
         /// </summary>
@@ -6318,21 +6112,11 @@
         /// 鑷畾涔夎澶囨墍灞濱D涓�15鐨勭炕璇戝悕瀛楋細鐏厜
         /// </summary>
         public const int uDeviceBelongId15 = 40016;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�16鐨勭炕璇戝悕瀛楋細骞叉帴鐐�
-        /// </summary>
-        public const int uDeviceBelongId16 = 40017;
         /// <summary>
         /// 鑷畾涔夎澶囨墍灞濱D涓�2310鐨勭炕璇戝悕瀛楋細鏂伴
         /// </summary>
         public const int uDeviceBelongId2310 = 40018;
-        /// <summary>
-        /// 鑷畾涔夎澶囨墍灞濱D涓�1307鐨勭炕璇戝悕瀛楋細绌烘皵璐ㄩ噺
-        /// </summary>
-        public const int uDeviceBelongId1307 = 40019;
 
-        //鈽呪槄鈽呪槄妯″潡ID鐨勮澶囬粯璁ゅ娉ㄥ悕瀛�,浠�50000寮�濮�,杩欓噷涓嶉渶瑕佸畾涔�,鍙啓鍦↙anguage.ini鏂囦欢閲岄潰鈽呪槄鈽呪槄
-        //鈽呪槄鈽呪槄妯″潡ID鐨勮澶囩被鍨嬪悕瀛�,浠�60000寮�濮�,杩欓噷涓嶉渶瑕佸畾涔�,鍙啓鍦↙anguage.ini鏂囦欢閲岄潰鈽呪槄鈽呪槄
 
         //鈽呪槄鈽呪槄涓嬮潰杩欎簺鏄坊鍔犳柊璁惧鐣岄潰閭i噷鏄剧ず鐨勫悕瀛�,浠�70000寮�濮嬧槄鈽呪槄鈽�
         /// <summary>

--
Gitblit v1.8.0