using System;
|
namespace Shared
|
{
|
/// <summary>
|
/// 逻辑灯
|
/// </summary>
|
[System.Serializable]
|
public class LightLogic : Common
|
{
|
public LightLogic ()
|
{
|
this.Type = DeviceType.LightLogic;
|
DeviceTextID = 3; //SimpleControl.R.MyInternationalizationString.Lights;
|
}
|
/// <summary>
|
/// 上一次打开的亮度
|
/// </summary>
|
public byte LastOpenBrightness = 0;
|
/// <summary>
|
/// 当前亮度值
|
/// </summary>
|
public byte CurrentBrightness = 0;
|
|
/// <summary>
|
/// 自定义延迟开时间
|
/// </summary>
|
public byte CustomDelayTimeOpen = 0;
|
/// <summary>
|
/// 自定义延迟关时间
|
/// </summary>
|
public byte CustomDelayTimeClose = 0;
|
/// <summary>
|
/// 延迟时间高位
|
/// </summary>
|
public byte DelayTimeHeigh = 0;
|
/// <summary>
|
/// 延迟时间低位
|
/// </summary>
|
public byte DelayTimeLow = 0;
|
/// <summary>
|
/// R颜色值
|
/// </summary>
|
public byte RStatus = 254;
|
/// <summary>
|
/// G颜色值
|
/// </summary>
|
public byte GStatus = 254;
|
/// <summary>
|
/// B颜色值
|
/// </summary>
|
public byte BStatus = 254;
|
/// <summary>
|
/// W颜色值
|
/// </summary>
|
public byte WStatus = 254;
|
/// <summary>
|
/// CCT高位
|
/// </summary>
|
public byte CTHStatus = 0;
|
/// <summary>
|
/// CCT低位
|
/// </summary>
|
public byte CTLStatus = 0;
|
|
public bool DimmingFunction {
|
get {
|
return !UserConfig.Instance.UnEnableDimmingLight.Contains (LightDimmingID);
|
}
|
}
|
|
public string LightDimmingID {
|
get {
|
return this.SubnetID.ToString () + "_" + this.DeviceID.ToString () + "_" + LoopID.ToString ();
|
}
|
}
|
|
}
|
}
|