コード例 #1
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0x1D,
				DriverType = GKDriverType.RK_SmokeDetector,
				UID = new Guid("2685C3BE-FB9B-4D8E-AA57-C66A135B0D76"),
				Name = "Извещатель пожарный дымовой оптико-электронный радиоканальный",
				ShortName = "ИП-РК",
				HasZone = true,
				IsPlaceable = true
			};
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Service);

			GKDriversHelper.AddRadioChanelProperties(driver);
			GKDriversHelper.AddIntProprety(driver, 3, "Порог срабатывания по дыму, дБ/м", 180, 50, 255).Multiplier = 1000;
			GKDriversHelper.AddIntProprety(driver, 4, "Порог запыленности, дБ/м", 200, 50, 255).Multiplier = 1000;

			driver.MeasureParameters.Add(new GKMeasureParameter() { No = 1, Name = "Задымленность, дБ/м", InternalName = "Smokiness", Multiplier = 1000 });
			driver.MeasureParameters.Add(new GKMeasureParameter() { No = 2, Name = "Запыленность, дБ/м", InternalName = "Dustinness", Multiplier = 1000 });

			return driver;
		}
コード例 #2
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xDD,
				DriverType = GKDriverType.RSR2_SmokeDetector,
				UID = new Guid("A50FFA41-B53E-4B3B-ADDF-CDBBA631FEB2"),
				Name = "Извещатель пожарный дымовой оптико-электронный адресно-аналоговый",
				ShortName = "ИП 212-149",
				HasZone = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.FireDetector
			};
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Service);

			GKDriversHelper.AddIntProprety(driver, 0, "Порог срабатывания по дыму, дБ/м", 180, 50, 255).Multiplier = 1000;
			GKDriversHelper.AddIntProprety(driver, 1, "Порог запыленности, дБ/м", 200, 50, 255).Multiplier = 1000;

			driver.MeasureParameters.Add(new GKMeasureParameter() { No = 1, Name = "Задымленность, дБ/м", InternalName = "Smokiness", Multiplier = 1000 });
			driver.MeasureParameters.Add(new GKMeasureParameter() { No = 2, Name = "Запыленность, дБ/м", InternalName = "Dustinness", Multiplier = 1000 });

			return driver;
		}
コード例 #3
0
ファイル: RSR2_KDKR_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xF3,
				DriverType = GKDriverType.RSR2_KDKR,
				UID = new Guid("CEF793CA-7E3E-446C-82DE-A032445B6CBA"),
				Name = "Контроллер доступа",
				ShortName = "КД",
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.AccessControl
			};

			driver.AutoCreateChildren.Add(GKDriverType.KD_KDZ);
			driver.AutoCreateChildren.Add(GKDriverType.KD_KDK);
			driver.AutoCreateChildren.Add(GKDriverType.KD_KDKV);
			driver.AutoCreateChildren.Add(GKDriverType.KD_KDTD);
			driver.AutoCreateChildren.Add(GKDriverType.RSR2_KDKR_Part);

			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);

			GKDriversHelper.AddIntProprety(driver, 0, "Число АУ на АЛС1 КД", 6, 1, 6).CanNotEdit = true;
			GKDriversHelper.AddIntProprety(driver, 1, "Число АУ на АЛС3 КД", 0, 0, 32).CanNotEdit = true;
			GKDriversHelper.AddIntProprety(driver, 2, "Число АУ на АЛС4 КД", 0, 0, 32).CanNotEdit = true;
			GKDriversHelper.AddIntProprety(driver, 3, "Число ТД", 8, 1, 8).CanNotEdit = true;

			return driver;
		}
コード例 #4
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xDF,
				DriverType = GKDriverType.RSR2_CombinedDetector,
				UID = new Guid("1CCE48EB-B60B-4E06-8290-A39591CD3DA2"),
				Name = "Извещатель пожарный комбинированный дымовой оптико-электронный тепловой максимально-дифференциальный",
				ShortName = "ИП 212/101-11-PR",
				HasZone = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.FireDetector
			};
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Service);

			GKDriversHelper.AddIntProprety(driver, 0, "Порог срабатывания по температуре, °C", 70, 54, 85);
			GKDriversHelper.AddIntProprety(driver, 1, "Порог срабатывания по градиенту температуры, °C/мин", 50, 10, 500).Multiplier = 10;
			GKDriversHelper.AddIntProprety(driver, 2, "Порог срабатывания по дыму, дБ/м", 180, 50, 255).Multiplier = 1000;
			GKDriversHelper.AddIntProprety(driver, 3, "Порог запыленности, дБ/м", 200, 50, 255).Multiplier = 1000;

			driver.MeasureParameters.Add(new GKMeasureParameter { No = 1, Name = "Температура, °C", InternalName = "Temperature", HasNegativeValue = true });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 2, Name = "Градиент температуры, °C/мин", InternalName = "TemperatureDelta", HasNegativeValue = true });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 3, Name = "Задымленность, дБ/м", InternalName = "Smokiness", Multiplier = 1000 });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 4, Name = "Запыленность, дБ/м", InternalName = "Dustinness", Multiplier = 1000 });

			return driver;
		}
コード例 #5
0
ファイル: GKDriversHelper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriverProperty AddPlainEnumProprety(GKDriver driver, byte no, byte offset, string propertyName, string parameter1Name, string parameter2Name)
		{
			var property = new GKDriverProperty()
			{
				No = no,
				Name = propertyName,
				Caption = propertyName,
				Default = (ushort)(1 << offset),
				Mask = (short)((1 << offset) + (1 << (offset + 1)))
			};
			var parameter1 = new GKDriverPropertyParameter()
			{
				Name = parameter1Name,
				Value = (ushort)(1 << offset)
			};
			var parameter2 = new GKDriverPropertyParameter()
			{
				Name = parameter2Name,
				Value = (ushort)(2 << offset)
			};
			property.Parameters.Add(parameter1);
			property.Parameters.Add(parameter2);
			driver.Properties.Add(property);
			return property;
		}
コード例 #6
0
ファイル: GKDriversHelper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriverProperty AddPlainEnumProprety2(GKDriver driver, byte no, string propertyName, byte offset, string parameter1Name, string parameter2Name, int mask)
		{
			var property = new GKDriverProperty()
			{
				No = no,
				Name = propertyName,
				Caption = propertyName,
				Default = 0,
				Mask = (byte)mask
			};
			var parameter1 = new GKDriverPropertyParameter()
			{
				Name = parameter1Name,
				Value = (ushort)0
			};
			var parameter2 = new GKDriverPropertyParameter()
			{
				Name = parameter2Name,
				Value = (ushort)mask
			};
			property.Parameters.Add(parameter1);
			property.Parameters.Add(parameter2);
			driver.Properties.Add(property);
			return property;
		}
コード例 #7
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0x10,
				DriverType = GKDriverType.RSR2_GuardDetector,
				UID = new Guid("501AA41F-248B-4A4E-982A-6BC93505C7A9"),
				Name = "Извещатель охранный инфракрасный",
				ShortName = "ИО-ИК",
				HasZone = false,
				HasGuardZone = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.IntruderDetector
			};

			GKDriversHelper.AddControlAvailableStates(driver);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);

			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Fire1);
			driver.AvailableStateBits.Add(GKStateBit.Off);

			driver.AvailableCommandBits.Add(GKStateBit.TurnOn_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOff_InManual);

			GKDriversHelper.AddIntProprety(driver, 0, "Уровень в ед АЦП, с", 128, 16, 384);

			return driver;
		}
コード例 #8
0
ファイル: KD_KDKV_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xF6,
				DriverType = GKDriverType.KD_KDKV,
				UID = new Guid("AE315D83-ECF5-4E75-801B-CB3F6EDE8FB8"),
				Name = "КВ КД",
				ShortName = "КДКВ",
				IsControlDevice = true,
				HasLogic = true,
				IsPlaceable = true,
				IsAutoCreate = true,
				MinAddress = 4,
				MaxAddress = 5,
			};

			GKDriversHelper.AddControlAvailableStates(driver);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Fire1);
			driver.AvailableStateBits.Add(GKStateBit.Off);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.AutoOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.On);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Off);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Fire1);

			driver.AvailableCommandBits.Add(GKStateBit.TurnOn_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOff_InManual);

			return driver;
		}
コード例 #9
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xDE,
				DriverType = GKDriverType.RSR2_HeatDetector,
				UID = new Guid("C0A93D79-9A7F-46AF-A190-855F32759A05"),
				Name = "Извещатель пожарный тепловой",
				ShortName = "ИП 101-52-PR",
				HasZone = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.FireDetector
			};
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Fire1);

			GKDriversHelper.AddIntProprety(driver, 0, "Порог срабатывания по температуре, °C", 70, 54, 85);
			GKDriversHelper.AddIntProprety(driver, 1, "Порог срабатывания по градиенту температуры, °C/мин", 50, 10, 500).Multiplier = 10;

			driver.MeasureParameters.Add(new GKMeasureParameter() { No = 1, Name = "Температура, °C", InternalName = "Temperature", HasNegativeValue = true });
			driver.MeasureParameters.Add(new GKMeasureParameter() { No = 2, Name = "Градиент температуры, °C/мин", InternalName = "TemperatureDelta", HasNegativeValue = true });

			return driver;
		}
コード例 #10
0
ファイル: KD_KDZ_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xF4,
				DriverType = GKDriverType.KD_KDZ,
				UID = new Guid("2E9F2B6A-D707-4007-842C-664D6BCBE9F1"),
				Name = "Замок КД",
				ShortName = "КДЗ",
				IsControlDevice = true,
				HasLogic = true,
				IsPlaceable = true,
				IsAutoCreate = true,
			};

			GKDriversHelper.AddControlAvailableStates(driver);
			driver.AvailableStateBits.Add(GKStateBit.Off);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.AutoOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.On);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Off);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);

			driver.AvailableCommandBits.Add(GKStateBit.TurnOn_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOff_InManual);

			return driver;
		}
コード例 #11
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0x1E,
				DriverType = GKDriverType.RK_HeatDetector,
				UID = new Guid("5D8010FF-B6B8-4A80-9191-211D008BC86B"),
				Name = "Извещатель пожарный тепловой радиоканальный",
				ShortName = "ИПТ-РК",
				HasZone = true,
				IsPlaceable = true
			};
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Fire1);

			GKDriversHelper.AddRadioChanelProperties(driver);
			GKDriversHelper.AddIntProprety(driver, 3, "Порог срабатывания по температуре, °C", 70, 54, 85);
			GKDriversHelper.AddIntProprety(driver, 4, "Порог срабатывания по градиенту температуры, °C/мин", 50, 10, 500).Multiplier = 10;

			driver.MeasureParameters.Add(new GKMeasureParameter() { No = 1, Name = "Температура, °C", InternalName = "Temperature", HasNegativeValue = true });
			driver.MeasureParameters.Add(new GKMeasureParameter() { No = 2, Name = "Градиент температуры, °C/мин", InternalName = "TemperatureDelta", HasNegativeValue = true });

			return driver;
		}
コード例 #12
0
ファイル: RSR2_MRK_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0x15,
				DriverType = GKDriverType.RSR2_MRK,
				UID = new Guid("1EF2C05C-B86A-44E5-8F4C-662AF92DAF20"),
				Name = "Модуль радиоканальный",
				ShortName = "МРК",
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.RadioChannel
			};

			driver.Children.Add(GKDriverType.RK_HandDetector);
			driver.Children.Add(GKDriverType.RK_SmokeDetector);
			driver.Children.Add(GKDriverType.RK_HeatDetector);
			driver.Children.Add(GKDriverType.RK_RM);
			driver.Children.Add(GKDriverType.RK_AM);
			driver.Children.Add(GKDriverType.RK_OPK);
			driver.Children.Add(GKDriverType.RK_OPZ);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);

			GKDriversHelper.AddIntProprety(driver, 0, "Число радиоканальных устройств", 0, 0, 32);
			GKDriversHelper.AddIntProprety(driver, 1, "Период опроса, с", 4, 4, 120);
			GKDriversHelper.AddIntProprety(driver, 2, "Повторы/неответы в количестве периодов", 3, 3, 32);

			var property3 = new GKDriverProperty()
			{
				No = 3,
				Name = "№ Канала",
				Caption = "№ Канала",
				Default = 0,
				Min = 0,
				Max = 15,
				IsLowByte = true,
				DriverPropertyType = GKDriverPropertyTypeEnum.IntType
			};
			driver.Properties.Add(property3);

			var property4 = new GKDriverProperty()
			{
				No = 3,
				Name = "Режим выбора канала",
				Caption = "Режим выбора канала",
				Default = 0,
				IsHieghByte = true,
			};
			GKDriversHelper.AddPropertyParameter(property4, "Ручной", 0);
			GKDriversHelper.AddPropertyParameter(property4, "Автоматический", 1);
			driver.Properties.Add(property4);

			GKDriversHelper.AddIntProprety(driver, 4, "Порог питания, В", 120, 0, 280).Multiplier = 10;
			return driver;
		}
コード例 #13
0
ファイル: GKDriversHelper.cs プロジェクト: xbadcode/Rubezh
		public static void AddBoolProprety(GKDriver driver, byte no, string propertyName)
		{
			var property = new GKDriverProperty()
			{
				No = no,
				Name = propertyName,
				Caption = propertyName,
				DriverPropertyType = GKDriverPropertyTypeEnum.BoolType
			};
			driver.Properties.Add(property);
		}
コード例 #14
0
ファイル: RSR2_SCOPA_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xF2,
				DriverType = GKDriverType.RSR2_SCOPA,
				UID = new Guid("4F9DFCDD-B98B-4D2B-BD7E-635BB5728DCE"),
				Name = "Взрывозащищенный оповещатель - табло",
				ShortName = "СКОПА",
				IsControlDevice = true,
				HasLogic = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.Announcers
			};

			GKDriversHelper.AddControlAvailableStates(driver);
			driver.AvailableStateBits.Add(GKStateBit.Off);
			driver.AvailableStateBits.Add(GKStateBit.TurningOn);
			driver.AvailableStateBits.Add(GKStateBit.TurningOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.AutoOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.On);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.TurningOn);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Off);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.TurningOff);

			driver.AvailableCommandBits.Add(GKStateBit.TurnOn_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOnNow_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOff_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOffNow_InManual);

			GKDriversHelper.AddIntProprety(driver, 0, "Задержка на включение, с", 0, 0, 65535);
			GKDriversHelper.AddIntProprety(driver, 1, "Время удержания, с", 0, 0, 65535);
			GKDriversHelper.AddIntProprety(driver, 2, "Задержка на выключение, с", 0, 0, 65535);

			var property1 = new GKDriverProperty()
			{
				No = 3,
				Name = "Состояние контакта для режима Удержание",
				Caption = "Состояние контакта для режима Удержание",
				Default = 0,
				IsLowByte = true,
				Mask = 0x03
			};
			GKDriversHelper.AddPropertyParameter(property1, "Выключено", 0);
			GKDriversHelper.AddPropertyParameter(property1, "Включено", 1);
			driver.Properties.Add(property1);

			driver.MeasureParameters.Add(new GKMeasureParameter { No = 1, Name = "Отсчет задержки на включение, с", IsDelay = true, IsNotVisible = true });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 2, Name = "Отсчет удержания, с", IsDelay = true, IsNotVisible = true });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 3, Name = "Отсчет задержки на выключение, с", IsDelay = true, IsNotVisible = true });

			return driver;
		}
コード例 #15
0
ファイル: RSR2_ZOV_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xF1,
				DriverType = GKDriverType.RSR2_ZOV,
				UID = new Guid("58795922-F023-4A90-BCEC-ACDB3CD0725F"),
				Name = "Оповещатель свето-звуковой взрывозащищенный",
				ShortName = "ЗОВ",
				IsControlDevice = true,
				HasLogic = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.Announcers
			};

			GKDriversHelper.AddControlAvailableStates(driver);
			driver.AvailableStateBits.Add(GKStateBit.Off);
			driver.AvailableStateBits.Add(GKStateBit.TurningOn);
			driver.AvailableStateBits.Add(GKStateBit.TurningOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.AutoOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.On);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.TurningOn);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Off);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.TurningOff);

			driver.AvailableCommandBits.Add(GKStateBit.TurnOn_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOnNow_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOff_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOffNow_InManual);

			GKDriversHelper.AddIntProprety(driver, 0, "Задержка на включение, с", 0, 0, 65535);
			GKDriversHelper.AddIntProprety(driver, 1, "Время удержания, с", 0, 0, 65535);
			GKDriversHelper.AddIntProprety(driver, 2, "Задержка на выключение, с", 0, 0, 65535);

			var property1 = new GKDriverProperty()
			{
				No = 3,
				Name = "Состояние контакта для режима Удержание",
				Caption = "Состояние контакта для режима Удержание",
				Default = 0,
				IsLowByte = true,
				Mask = 0x03
			};
			GKDriversHelper.AddPropertyParameter(property1, "Выключено", 0);
			GKDriversHelper.AddPropertyParameter(property1, "Включено", 1);
			driver.Properties.Add(property1);

			driver.MeasureParameters.Add(new GKMeasureParameter { No = 1, Name = "Отсчет задержки на включение, с", IsDelay = true, IsNotVisible = true });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 2, Name = "Отсчет удержания, с", IsDelay = true, IsNotVisible = true });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 3, Name = "Отсчет задержки на выключение, с", IsDelay = true, IsNotVisible = true });

			return driver;
		}
コード例 #16
0
ファイル: RSR2_ABPC_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0x12,
				DriverType = GKDriverType.RSR2_ABPC,
				UID = new Guid("6260F52C-D047-4F64-BFE8-B9D0547A39B4"),
				Name = "Адресный барьер пусковой цепи",
				ShortName = "АБПЦ",
				IsControlDevice = true,
				HasLogic = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.ActuatingDevice
			};

			GKDriversHelper.AddControlAvailableStates(driver);
			driver.AvailableStateBits.Add(GKStateBit.Off);
			driver.AvailableStateBits.Add(GKStateBit.TurningOn);
			driver.AvailableStateBits.Add(GKStateBit.TurningOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.AutoOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.On);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.TurningOn);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Off);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.TurningOff);

			driver.AvailableCommandBits.Add(GKStateBit.TurnOn_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOnNow_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOff_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOffNow_InManual);

			GKDriversHelper.AddIntProprety(driver, 0, "Задержка на включение, с", 0, 0, 65535);
			GKDriversHelper.AddIntProprety(driver, 1, "Время удержания, с", 0, 0, 65535);
			GKDriversHelper.AddIntProprety(driver, 2, "Задержка на выключение, с", 0, 0, 65535);

			var property1 = new GKDriverProperty()
			{
				No = 3,
				Name = "Состояние контакта для режима Удержание",
				Caption = "Состояние контакта для режима Удержание",
				Default = 0,
				IsLowByte = true,
				Mask = 0x03
			};
			GKDriversHelper.AddPropertyParameter(property1, "Выключено", 0);
			GKDriversHelper.AddPropertyParameter(property1, "Включено", 1);
			driver.Properties.Add(property1);

			driver.MeasureParameters.Add(new GKMeasureParameter { No = 1, Name = "Отсчет задержки на включение, с", IsDelay = true, IsNotVisible = true });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 2, Name = "Отсчет удержания, с", IsDelay = true, IsNotVisible = true });
			driver.MeasureParameters.Add(new GKMeasureParameter { No = 3, Name = "Отсчет задержки на выключение, с", IsDelay = true, IsNotVisible = true });

			return driver;
		}
コード例 #17
0
ファイル: RSR2_IOLIT_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0x20,
				DriverType = GKDriverType.RSR2_IOLIT,
				UID = new Guid("10DCA010-257E-4D81-B090-72903E0CB029"),
				Name = "ИОЛИТ",
				ShortName = "ИОЛИТ",
				HasZone = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.FireDetector
			};
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Fire1);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Fire1);

			var property1 = new GKDriverProperty()
			{
				No = 0,
				Name = "Чуствительность",
				Caption = "Чуствительность",
				Default = 0,
				IsLowByte = true,
				Mask = 0x0F
			};
			GKDriversHelper.AddPropertyParameter(property1, "100%", 0);
			GKDriversHelper.AddPropertyParameter(property1, "75%", 1);
			GKDriversHelper.AddPropertyParameter(property1, "50%", 2);
			GKDriversHelper.AddPropertyParameter(property1, "25%", 3);
			driver.Properties.Add(property1);

			var property11 = new GKDriverProperty()
			{
				No = 0,
				Name = "Режим",
				Caption = "Режим",
				Default = 0,
				IsLowByte = true,
				Mask = 0xF0
			};
			GKDriversHelper.AddPropertyParameter(property11, "Основной Т1 с фиксац. тревоги", 0);
			GKDriversHelper.AddPropertyParameter(property11, "Основной Т1 без фиксац. тревоги", 16);
			GKDriversHelper.AddPropertyParameter(property11, "Основной Т2 с фиксац. тревоги", 32);
			GKDriversHelper.AddPropertyParameter(property11, "Основной Т2 без фиксац. тревоги", 48);
			GKDriversHelper.AddPropertyParameter(property11, "Вспышка с интер. 0.1 с", 64);
			GKDriversHelper.AddPropertyParameter(property11, "Вспышка с интер. 0.5 с", 80);
			driver.Properties.Add(property11);

			return driver;
		}
コード例 #18
0
ファイル: StateViewModel.cs プロジェクト: xbadcode/Rubezh
		public StateViewModel(GKLibraryState libraryState, GKDriver driver)
		{
			AddFrameCommand = new RelayCommand(OnAddFrame);
			RemoveFrameCommand = new RelayCommand(OnRemoveFrame, CanRemoveFrame);

			State = libraryState;
			Driver = driver;

			Frames = new ObservableCollection<FrameViewModel>(
				State.Frames.Select(frame => new FrameViewModel(frame))
			);
			SelectedFrame = Frames.FirstOrDefault();
		}
コード例 #19
0
ファイル: RK_OPZ_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0x26,
				DriverType = GKDriverType.RK_OPZ,
				UID = new Guid("A816B11B-67B9-450D-814E-C5DA393F41C6"),
				Name = "Оповещатель охранно-пожарный звуковой радиоканальный",
				ShortName = "ОПЗ-РК",
				IsControlDevice = true,
				HasLogic = true,
				IsPlaceable = true
			};

			driver.AvailableStateBits.Add(GKStateBit.Norm);
			driver.AvailableStateBits.Add(GKStateBit.Off);
			driver.AvailableStateBits.Add(GKStateBit.TurningOn);
			driver.AvailableStateBits.Add(GKStateBit.TurningOff);
			GKDriversHelper.AddControlAvailableStates(driver);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Failure);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.AutoOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.On);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.TurningOn);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Failure);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Off);

			driver.AvailableCommandBits.Add(GKStateBit.TurnOn_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOnNow_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOff_InManual);

			GKDriversHelper.AddRadioChanelProperties(driver);
			GKDriversHelper.AddIntProprety(driver, 3, "Задержка на включение, с", 0, 0, 65535);
			GKDriversHelper.AddIntProprety(driver, 4, "Время удержания, с", 0, 0, 65535);

			var property1 = new GKDriverProperty()
			{
				No = 5,
				Name = "Режим после удержания",
				Caption = "Режим после удержания",
				Default = 1,
				IsLowByte = true,
				Mask = 0x01
			};
			GKDriversHelper.AddPropertyParameter(property1, "Выключается", 0);
			GKDriversHelper.AddPropertyParameter(property1, "Остаётся включённым", 1);
			driver.Properties.Add(property1);

			return driver;
		}
コード例 #20
0
ファイル: RSR2_OPZ_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverTypeNo = 0xE6,
				DriverType = GKDriverType.RSR2_OPZ,
				UID = new Guid("24A6FC19-0428-43A9-8B1C-35B748BD202B"),
				Name = "Оповещатель охранно-пожарный звуковой адресный",
				ShortName = "ОПЗ",
				IsControlDevice = true,
				HasLogic = true,
				IsPlaceable = true,
				DriverClassification = GKDriver.DriverClassifications.Announcers
			};

			driver.AvailableStateBits.Add(GKStateBit.Norm);
			driver.AvailableStateBits.Add(GKStateBit.Off);
			driver.AvailableStateBits.Add(GKStateBit.TurningOn);
			driver.AvailableStateBits.Add(GKStateBit.TurningOff);
			GKDriversHelper.AddControlAvailableStates(driver);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Test);
			GKDriversHelper.AddAvailableStateBits(driver, GKStateBit.Failure);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.AutoOff);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.On);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.TurningOn);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Test);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Failure);
			GKDriversHelper.AddAvailableStateClasses(driver, XStateClass.Off);

			driver.AvailableCommandBits.Add(GKStateBit.TurnOn_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOnNow_InManual);
			driver.AvailableCommandBits.Add(GKStateBit.TurnOff_InManual);

			GKDriversHelper.AddIntProprety(driver, 0, "Задержка на включение, с", 0, 0, 65535);
			GKDriversHelper.AddIntProprety(driver, 1, "Время удержания, с", 0, 0, 65535);

			var property1 = new GKDriverProperty()
			{
				No = 2,
				Name = "Режим после удержания",
				Caption = "Режим после удержания",
				Default = 1,
				IsLowByte = true,
				Mask = 0x01
			};
			GKDriversHelper.AddPropertyParameter(property1, "Выключается", 0);
			GKDriversHelper.AddPropertyParameter(property1, "Остаётся включённым", 1);
			driver.Properties.Add(property1);

			return driver;
		}
コード例 #21
0
ファイル: RSR2_RM_4_Helper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverType = GKDriverType.RSR2_RM_4,
				UID = new Guid("E3001BBB-18DA-437D-AB73-56C701F070D4"),
				Name = "Модуль релейный групповой",
				ShortName = "РМ4",
				IsGroupDevice = true,
				GroupDeviceChildType = GKDriverType.RSR2_RM_1,
				GroupDeviceChildrenCount = 4,
				DriverClassification = GKDriver.DriverClassifications.ActuatingDevice
			};
			return driver;
		}
コード例 #22
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverType = GKDriverType.RSR2_MVK2_Group,
				UID = new Guid("2ABAF6C0-6B9B-4658-8AB6-7FF15914B06F"),
				Name = "Модуль выходов с контролем групповой",
				ShortName = "МВК2",
				IsGroupDevice = true,
				GroupDeviceChildType = GKDriverType.RSR2_MVK8,
				GroupDeviceChildrenCount = 2,
				DriverClassification = GKDriver.DriverClassifications.ActuatingDevice
			};
			return driver;
		}
コード例 #23
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverType = GKDriverType.RSR2_MAP4_Group,
				UID = new Guid("FE44E469-55FB-4079-A50D-A0E4C098F0AC"),
				Name = "Метка адресная пожарная групповая",
				ShortName = "АМП4",
				IsGroupDevice = true,
				GroupDeviceChildType = GKDriverType.RSR2_MAP4,
				GroupDeviceChildrenCount = 4,
				DriverClassification = GKDriver.DriverClassifications.Other
			};
			return driver;
		}
コード例 #24
0
		private void AddDrivers(GKDriver driver, DataTable table)
		{
			var count = 0;
			foreach (var device in GKManager.Devices)
			{
				if (device.DriverType == driver.DriverType)
				{
					if (device.Parent.Driver.IsGroupDevice)
						continue;
					count++;
				}
			}
			if (count > 0)
				table.Rows.Add(driver.ShortName, count);
		}
コード例 #25
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverType = GKDriverType.RSR2_ABTK_Group,
				UID = new Guid("D59115A5-B3A6-4D76-A744-0B719F81B15D"),
				Name = "Адресный барьер термокабеля на 2 входа",
				ShortName = "АБТК2",
				IsGroupDevice = true,
				GroupDeviceChildType = GKDriverType.RSR2_ABTK,
				GroupDeviceChildrenCount = 2,
				DriverClassification = GKDriver.DriverClassifications.FireDetector
			};
			return driver;
		}
コード例 #26
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverType = GKDriverType.RSR2_MVK4_Group,
				UID = new Guid("D3FD9DE2-D2E8-4DAC-B44E-82B202BE3534"),
				Name = "Модуль выходов с контролем групповой",
				ShortName = "МВК4",
				IsGroupDevice = true,
				GroupDeviceChildType = GKDriverType.RSR2_MVK8,
				GroupDeviceChildrenCount = 4,
				DriverClassification = GKDriver.DriverClassifications.ActuatingDevice
			};
			return driver;
		}
コード例 #27
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverType = GKDriverType.RSR2_AM_4,
				UID = new Guid("79EAC50A-D534-4775-A102-BE4872877400"),
				Name = "Метка адресная групповая",
				ShortName = "АМ4",
				IsGroupDevice = true,
				GroupDeviceChildType = GKDriverType.RSR2_AM_1,
				GroupDeviceChildrenCount = 4,
				DriverClassification = GKDriver.DriverClassifications.Other
			};
			return driver;
		}
コード例 #28
0
		public static GKDriver Create()
		{
			var driver = new GKDriver()
			{
				DriverType = GKDriverType.RSR2_ABShS_Group,
				UID = new Guid("71B8E463-4927-4ECD-823E-D59179C9ED29"),
				Name = "Адресный барьер шлейфа сигнализации на 2 входа",
				ShortName = "АБШС2",
				IsGroupDevice = true,
				GroupDeviceChildType = GKDriverType.RSR2_ABShS,
				GroupDeviceChildrenCount = 2,
				DriverClassification = GKDriver.DriverClassifications.Other
			};
			return driver;
		}
コード例 #29
0
ファイル: GKDriversHelper.cs プロジェクト: xbadcode/Rubezh
		public static GKDriverProperty AddIntProprety(GKDriver driver, byte no, string propertyName, int defaultValue, int min, int max)
		{
			var property = new GKDriverProperty()
			{
				No = no,
				Name = propertyName,
				Caption = propertyName,
				DriverPropertyType = GKDriverPropertyTypeEnum.IntType,
				Default = (ushort)defaultValue,
				Min = (ushort)min,
				Max = (ushort)max,
			};
			driver.Properties.Add(property);
			return property;
		}
コード例 #30
0
		public static GKDriver Create()
		{
			var driver = new GKDriver
			{
				DriverType = GKDriverType.RSR2_AM_2,
				UID = new Guid("F8496E34-8F48-436F-954C-79B6BA918BBB"),
				Name = "Метка адресная групповая",
				ShortName = "АМ2",
				IsGroupDevice = true,
				GroupDeviceChildType = GKDriverType.RSR2_AM_1,
				GroupDeviceChildrenCount = 2,
				DriverClassification = GKDriver.DriverClassifications.Other
			};
			return driver;
		}