| | |
| | | if (Common.Config.Instance.Home.IsVirtually == true) |
| | | { |
| | | //这里特殊,这里是按回路分的 |
| | | return TemplateData.TemplateDeviceDataLogic.Current.GetPanelColorInfo(device.DeviceAddr, device.DeviceEpoint, keyNum); |
| | | return HdlTemplateDeviceDataLogic.Current.GetPanelColorInfo(device.DeviceAddr, device.DeviceEpoint, keyNum); |
| | | } |
| | | //发送数据 keyNum转为16进制 范围:01~10 |
| | | var passData = "0504040101" + Convert.ToString((int)keyNum, 16).ToUpper().PadLeft(2, '0'); |
| | |
| | | if (Common.Config.Instance.Home.IsVirtually == true) |
| | | { |
| | | //这个也是特殊,按回路来分 |
| | | return TemplateData.TemplateDeviceDataLogic.Current.SetPanelColorInfo(device.DeviceAddr, device.DeviceEpoint, keyColorData, keyNumStatus, null); |
| | | return HdlTemplateDeviceDataLogic.Current.SetPanelColorInfo(device.DeviceAddr, device.DeviceEpoint, keyColorData, keyNumStatus, null); |
| | | } |
| | | //获取配置按键指示灯颜色的命令字符 |
| | | var sendData = this.GetPanelColorCommandText(device.DeviceAddr, keyColorData, keyNumStatus); |
| | |
| | | tempD.status = Convert.ToInt32(data[14].ToString() + data[15].ToString(), 16); |
| | | |
| | | //添加缓存 |
| | | TemplateData.TemplateDeviceDataLogic.Current.SetPanelColorInfo(device.DeviceAddr, device.DeviceEpoint, keyColorData, keyNumStatus, result.JsonData[0]); |
| | | HdlTemplateDeviceDataLogic.Current.SetPanelColorInfo(device.DeviceAddr, device.DeviceEpoint, keyColorData, keyNumStatus, result.JsonData[0]); |
| | | |
| | | return new CommonDevice.ResponseAllData { responseData = tempD }; |
| | | } |
| | |
| | | //如果当前是虚拟住宅 |
| | | if (Common.Config.Instance.Home.IsVirtually == true) |
| | | { |
| | | return TemplateData.TemplateDeviceDataLogic.Current.GetDeviceLightSettion(device.DeviceAddr, 200); |
| | | return HdlTemplateDeviceDataLogic.Current.GetDeviceLightSettion(device.DeviceAddr, 200); |
| | | } |
| | | //获取发送的命令字符 |
| | | var passData = "050604010101"; |
| | |
| | | //如果当前是虚拟住宅 |
| | | if (Common.Config.Instance.Home.IsVirtually == true) |
| | | { |
| | | return TemplateData.TemplateDeviceDataLogic.Current.SetDeviceLightSettion(device.DeviceAddr, 200, directionsLevel, backlightLevel, null); |
| | | return HdlTemplateDeviceDataLogic.Current.SetDeviceLightSettion(device.DeviceAddr, 200, directionsLevel, backlightLevel, null); |
| | | } |
| | | //获取修改面板的亮度调节的命令字符 |
| | | var sendData = this.GetPanelLevelCommadText(device.DeviceAddr, directionsLevel, backlightLevel); |
| | |
| | | } |
| | | |
| | | //修改缓存 |
| | | TemplateData.TemplateDeviceDataLogic.Current.SetDeviceLightSettion(device.DeviceAddr, 200, directionsLevel, backlightLevel, result.JsonData[0]); |
| | | HdlTemplateDeviceDataLogic.Current.SetDeviceLightSettion(device.DeviceAddr, 200, directionsLevel, backlightLevel, result.JsonData[0]); |
| | | |
| | | return true; |
| | | } |
| | |
| | | //如果当前住宅是虚拟住宅 |
| | | if (Common.Config.Instance.Home.IsVirtually == true) |
| | | { |
| | | return TemplateData.TemplateDeviceDataLogic.Current.GetDeviceEnergyConservationMode(device.DeviceAddr, 200); |
| | | return HdlTemplateDeviceDataLogic.Current.GetDeviceEnergyConservationMode(device.DeviceAddr, 200); |
| | | } |
| | | //发送命令 |
| | | string passData = "050804010101"; |
| | |
| | | //如果当前是虚拟住宅 |
| | | if (Common.Config.Instance.Home.IsVirtually == true) |
| | | { |
| | | return TemplateData.TemplateDeviceDataLogic.Current.SetDeviceEnergyConservationMode(device.DeviceAddr, 200, modeEnable, modeTime, level, null); |
| | | return HdlTemplateDeviceDataLogic.Current.SetDeviceEnergyConservationMode(device.DeviceAddr, 200, modeEnable, modeTime, level, null); |
| | | } |
| | | //获取设置设备的节能模式的命令字符 |
| | | var sendData = this.GetDeviceEnergyConservationModeCommandText(device.DeviceAddr, modeEnable, modeTime, level); |
| | |
| | | } |
| | | |
| | | //修改缓存 |
| | | TemplateData.TemplateDeviceDataLogic.Current.SetDeviceEnergyConservationMode(device.DeviceAddr, 200, modeEnable, modeTime, level, result.JsonData[0]); |
| | | HdlTemplateDeviceDataLogic.Current.SetDeviceEnergyConservationMode(device.DeviceAddr, 200, modeEnable, modeTime, level, result.JsonData[0]); |
| | | |
| | | return true; |
| | | } |
| | |
| | | //如果是虚拟住宅 |
| | | if (Common.Config.Instance.Home.IsVirtually == true) |
| | | { |
| | | return TemplateData.TemplateDeviceDataLogic.Current.GetPanelVibrationInfo(device.DeviceAddr, 200); |
| | | return HdlTemplateDeviceDataLogic.Current.GetPanelVibrationInfo(device.DeviceAddr, 200); |
| | | } |
| | | //发送数据 |
| | | var jObject = new Newtonsoft.Json.Linq.JObject { { "DeviceAddr", device.DeviceAddr }, { "Epoint", 200 }, { "Cluster_ID", 64513 }, { "Command", 0 } }; |
| | |
| | | //如果是虚拟住宅 |
| | | if (Common.Config.Instance.Home.IsVirtually == true) |
| | | { |
| | | return TemplateData.TemplateDeviceDataLogic.Current.SetPanelVibrationInfo(device.DeviceAddr, 200, datainfo, null); |
| | | return HdlTemplateDeviceDataLogic.Current.SetPanelVibrationInfo(device.DeviceAddr, 200, datainfo, null); |
| | | } |
| | | //获取编辑面板震动功能的命令字符 |
| | | var sendData = this.GetPanelVibrationCommandText(device.DeviceAddr, datainfo); |
| | |
| | | return false; |
| | | } |
| | | //添加缓存 |
| | | TemplateData.TemplateDeviceDataLogic.Current.SetPanelVibrationInfo(device.DeviceAddr, 200, datainfo, result.JsonData[0]); |
| | | HdlTemplateDeviceDataLogic.Current.SetPanelVibrationInfo(device.DeviceAddr, 200, datainfo, result.JsonData[0]); |
| | | |
| | | return true; |
| | | } |