Esempio n. 1
0
        public static Object BuildPackage(EverflourishDevice device, bool value)
        {
            Log.Debug("Sending lighting 5 package");

            LIGHTING5 package = new LIGHTING5();
            package.id1 = 0;
            package.id2 = (byte)((device.Address >> 8) & 0x3F);
            package.id3 = (byte)(device.Address & 0xFF);
            package.unitcode = (byte)device.Unit;
            package.cmnd = (byte)(value ? 1 : 0);
            package.level = (byte)(value ? 0xFF : 0x00);

            return package;
        }
Esempio n. 2
0
        public static Object BuildPackage(EverflourishDevice device, bool value)
        {
            Log.Debug("Sending lighting 5 package");

            LIGHTING5 package = new LIGHTING5();

            package.id1      = 0;
            package.id2      = (byte)((device.Address >> 8) & 0x3F);
            package.id3      = (byte)(device.Address & 0xFF);
            package.unitcode = (byte)device.Unit;
            package.cmnd     = (byte)(value ? 1 : 0);
            package.level    = (byte)(value ? 0xFF : 0x00);

            return(package);
        }
Esempio n. 3
0
 public EverflourishEvent(EverflourishDevice device, bool value)
 {
     Device = device;
     Value = value;
 }
Esempio n. 4
0
 public EverflourishEvent(EverflourishDevice device, bool value)
 {
     Device = device;
     Value  = value;
 }