how to use "gpib close" command to close all devices

Help
2014-02-04
2014-02-04
  • Willy Cabaluna

    Willy Cabaluna - 2014-02-04

    Hello,

    I have the following codes below. When I use the "gpib close [-device all]" command, I get
    invalid command name "-device". Need help. Thanks in advance.

    Wil

    package require gpib
    set agilent_supply 4
    set keithley_isrc 20

    proc config_supply {} {
    global agilent_supply
    gpib open -address $agilent_supply
    gpib write -message "VOLT:RANG P20V"
    gpib write -message "CURR 5.0"
    gpib write -message "OUTP ON"
    }

    proc config_keithley_isrc {} {
    global keithley_isrc
    gpib open -address $keithley_isrc
    gpib write -message "SOUR:FUNC CURR"
    gpib write -message "SENS:VOLT:PROT 21"
    gpib write -message "OUTP ON"
    }

    config_supply
    config_keithley_isrc
    gpib close [-device all]

     
  • Ian Dees

    Ian Dees - 2014-02-04

    Hello, Wil.

    If you remove the square brackets, the command should work:

    gpib close -device all
    

    Hope this helps.

    Sincerely,

    Ian

     
    Last edit: Ian Dees 2014-02-04

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks