/// <summary> /// Initialises a new instance of the <see cref="DigitalIOdata"/> class. /// </summary> /// <param name="direction"> /// Direction of the digital I/O port. true (1) = input, false (0) = output. /// </param> /// <param name="state"> /// State of the digital I/O port. true (1) = logic high, false (0) = logic low. /// </param> internal DigitalIOdata(byte direction, byte state) { Direction = new DigitalPortBits(); Direction.SetBitsFromByte(direction); State = new DigitalPortBits(); State.SetBitsFromByte(state); }
/// <summary> /// Initialises a new instance of the <see cref="DigitalIOdata"/> class. /// </summary> /// <param name="state"> /// State of the digital I/O port. true (1) = logic high, false (0) = logic low. /// </param> public DigitalIOdata(DigitalPortBits state) : this(0, state.ConvertToByte()) { }