Ejemplo n.º 1
0
        /// <summary>
        /// Open procedure for the instrument.
        /// </summary>
        public override void Open()
        {
            base.Open();

            // Use this to ensure the correct instrument is being connected to.
            if (!IdnString.Contains("Instrument ID"))
            {
                Log.Error("This instrument driver does not support the connected instrument.");
                throw new ArgumentException("Wrong instrument type.");
            }
        }
        /// <summary>
        /// Open procedure for the instrument.
        /// </summary>
        public override void Open()
        {
            base.Open();

            Log.Info("Connection to the Instrument Established");

            if (!IdnString.Contains("Instrument ID"))
            {
                Log.Error("This instrument driver does not support the connected instrument.");
                // throw new ArgumentException("Wrong instrument type.");
            }
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Open procedure for the instrument.
        /// </summary>
        public override void Open()
        {
            base.Open();
            MessageBox.Show($"Connection to {VisaAddress} successful");
            Log.Info(string.Format("Connection to {0} successful", VisaAddress));
            // TODO:  Open the connection to the instrument here

            if (!IdnString.Contains("Instrument ID"))
            {
                Log.Error("This instrument driver does not support the connected instrument.");
                throw new ArgumentException("Wrong instrument type.");
            }
        }