/// <summary> /// Creates a new <see cref="LogixTag"/> with the specified TagAddress and adds it to the <see cref="T:LogixProcessor"/>. /// </summary> /// <param name="TagAddress">Address (Tag Name) of the item on the Processor.</param> /// <param name="Processor">Processor to add this <c>LogixTag</c> to.</param> internal LogixTag(string TagAddress, LogixProcessor Processor) : this(TagAddress) { _parent = Processor; //Processor.AddTag(this); //Everything else is automatically set by the processor }
/// <summary> /// Creates a new LogixTagGroup on the specified processor. It is /// recommended that you use <see cref="LogixProcessor.CreateTagGroup"/> /// to create tag groups instead of this constructor so the processor /// can manage the group. /// </summary> /// <param name="Processor">Processor that the group belongs to</param> /// <param name="GroupName">Name of the group, must be unique on the processor</param> public LogixTagGroup(LogixProcessor Processor, string GroupName) { _parent = Processor; _groupName = GroupName; _enabled = true; _tags = new List <LogixTag>(); _readPackets = new List <PacketMap>(); _msrPackets = new List <MultiServiceRequest>(); }
/// <summary> /// Creates a new <see cref="LogixTag"/> with the specified TagAddress and adds it to the <see cref="T:LogixProcessor"/>. /// </summary> /// <param name="TagAddress">Address (Tag Name) of the item on the Processor.</param> /// <param name="Processor">Processor to add this <c>LogixTag</c> to.</param> /// <param name="ElementCount"></param> internal LogixTag(string TagAddress, LogixProcessor Processor, ushort ElementCount, object InitData = null) #endif { _enabled = true; _parent = Processor; _dataType = 0x00; _address = TagAddress; _lastError = string.Empty; _lastErrorNumber = 0; _tagQuality = TagQuality.Unknown; _timeStamp = DateTime.MinValue; _elements = ElementCount; Initialize(InitData); //Processor.AddTag(this); }
internal LogixTag(string TagAddress, LogixProcessor Processor, ushort ElementCount, object InitData)
internal LogixTag(string TagAddress, LogixProcessor Processor, ushort ElementCount) : this(TagAddress, Processor, ElementCount, null) { }