HDL Home App 第二版本 旧平台金堂用 正在使用
黄学彪
2019-10-28 8b4d79ca03495e522a1953e04ca17527f33c853a
ZigbeeApp/Shared/Common/Device.cs
@@ -223,11 +223,11 @@
        /// <param name="zbGateway">网关对象</param>
        /// <param name="deviceComingAction">接收到设备时的事件,设备对象为null时,代表接收完成</param>
        /// <returns>一直返回true</returns>
        public async Task<bool> SetDeviceToMemmoryByGateway(ZbGateway zbGateway, Action<CommonDevice> deviceComingAction = null)
        public bool SetDeviceToMemmoryByGateway(ZbGateway zbGateway, Action<CommonDevice> deviceComingAction = null)
        {
            //从网关获取全部的设备
            List<CommonDevice> listDevice = new List<CommonDevice>();
            List<CommonDevice> list = await this.GetDeviceListFromGateway(zbGateway, true, deviceComingAction);
            List<CommonDevice> list = this.GetDeviceListFromGateway(zbGateway, true, deviceComingAction);
            if (list == null)
            {
@@ -1007,6 +1007,7 @@
            this.GetDeviceIcon(device, ref unSelectFilePath, ref selectFilePath);
            btnIcon.UnSelectedImagePath = unSelectFilePath;
            btnIcon.SelectedImagePath = selectFilePath;
        }
        /// <summary>
@@ -1706,7 +1707,7 @@
        /// <param name="deviceComingAction">接收到设备时的事件</param>
        /// <param name="mode">是否显示错误</param>
        /// <returns></returns>
        public async Task<List<CommonDevice>> GetDeviceListFromGateway(ZbGateway zbGateway, bool ignoreTime, Action<CommonDevice> deviceComingAction = null, ShowErrorMode mode = ShowErrorMode.YES)
        public List<CommonDevice> GetDeviceListFromGateway(ZbGateway zbGateway, bool ignoreTime, Action<CommonDevice> deviceComingAction = null, ShowErrorMode mode = ShowErrorMode.YES)
        {
            if (ignoreTime == false)
            {
@@ -1813,13 +1814,13 @@
            try
            {
                var jObject = new Newtonsoft.Json.Linq.JObject { { "Cluster_ID", 0 }, { "Command", 93 } };
                await realWay.Send("GetDeviceInfo", jObject.ToString());
                realWay.Send("GetDeviceInfo", jObject.ToString());
            }
            catch { canBreak = true; }
            while (canBreak == false && TimeOut < 60)
            {
                await Task.Delay(100);
                System.Threading.Thread.Sleep(100);
                TimeOut++;
            }
@@ -2074,7 +2075,7 @@
            this.dicDeviceModelIdEnum["H06C"] = "2800-2800";//智能门锁(H06C)
            //=========★★空调类(3600-3899)★★=========
            this.dicDeviceModelIdEnum["MAC/GW-ZB.431"] = "3600-3600";//zigbee空调网关模块
            this.dicDeviceModelIdEnum["MAC/GW-ZB.10"] = "3600-3600";//zigbee空调网关模块
            //=========★★中继器类(3900-3999)★★=========
            this.dicDeviceModelIdEnum["MSR-ZB.10"] = "3900-3900"; //zigbee中继器