namespace AMWD.Protocols.Modbus.Common { /// /// Represents a discrete input. /// public class DiscreteInput : ModbusObject { /// public override ModbusObjectType Type => ModbusObjectType.DiscreteInput; /// /// Gets or sets a value indicating whether the discrete input is on or off. /// public bool Value => HighByte == 0xFF; /// public override string ToString() => $"Discrete Input #{Address} | {(Value ? "ON" : "OFF")}"; } }