pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user...

24
Issue D February 2014 User Manual Command Line Control of Pickering LXI Instruments pickeringtest.com pickering PRELIMINARY

Transcript of pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user...

Page 1: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page 1

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

Issue D February 2014

User Manual

Command Line Control ofPickering LXI Instruments

pickeringtest.com pickering

PRELIMINARY

Page 2: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page ii

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

© COPYRIGHT (2014) PICKERING INTERFACES. ALL RIGHTS RESERVED.

No part of this publication may be reproduced, transmitted, transcribed, translated or stored in any form, or by any means without the written permission of Pickering Interfaces.

Technical details contained within this publication are subject to change without notice.

ISO 9001Reg No. FM38792

Page 3: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page iii

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

TECHNICAL SUPPORT

For Technical Support please contact Pickering Interfaces either by phone, fax, the website or via e-mail.

WARRANTY

All products manufactured by Pickering Interfaces are warranted against defective materials and workmanship for a period of three years, excluding programmable power supplies, from the date of delivery to the original purchaser. Any product found to be defective within this period will, at the discretion of Pickering Interfaces be repaired or replaced.

Warranty is on a return to factory basis, however, for most systems, the module may be replaced on a module exchange basis. A module will be delivered to the user and the faulty part returned to Pickering Interfaces on receipt.

Products serviced and repaired outside of the warranty period are warranted for ninety days.

Extended warranty and service are available. Please contact Pickering Interfaces by phone, fax, the website or via e-mail.

ENVIRONMENTAL POLICY

Pickering Interfaces operates under an environmental management system similar to ISO 14001.

Pickering Interfaces strives to fulfil all relevant environmental laws and regulations and reduce wastes and releases to the environment. Pickering Interfaces aims to design and operate products in a way that protects the environment and the health and safety of its employees, customers and the public. Pickering Interfaces endeavours to develop and manufacture products that can be produced, distributed, used and recycled, or disposed of, in a safe and

environmentally friendly manner.

Worldwide Technical Support and Product Informationhttp://www.pickeringtest.com

Pickering Interfaces HeadquartersStephenson Road Clacton-on-Sea CO15 4NL United KingdomTel: +44 (0)1255-687900Fax: +44 (0)1255-475058E-Mail: [email protected]

Pickering Interfaces GmbHJohann-Karg-Straße 30D-85540Haar-SalmdorfGermany

Tel: +49 89 125 953 160Fax: +49 89 125 953 189E-Mail: [email protected]

Pickering Interfaces ABKarl Nordströmsväg 31432 53 VarbergSweden

Tel: +46 340-69 06 69Fax: +46 340-69 06 68E-Mail: [email protected]

Pickering Interfaces Inc.2900 Northwest Vine StreetGrants PassOregon 97526USA

Tel: +1 541 471 0700Fax: +1 541 471 8828E-Mail: [email protected]

Pickering Interfaces Inc. (East Coast Regional Office) 221 Chelmsford Street, Suite 5, Chelmsford, Massachusetts 01824 USA Tel: +1 781 229 5882 Fax: +1 781 272 0558 E-mail: [email protected]

Pickering Interfaces s.r.o.Smetanova 525Trinec739 61Czech Republic

Tel: +420 558 339 168Fax: +420 558 340 888E-mail: [email protected]

ˇ

Pickering Interfaces SARL6 Rue De La Mare Blanche77186 NoisielMarne Le ValleeFrance

Tel +33 1 60 53 55 50Fax +33 1 60 53 55 99email [email protected]

Page 4: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page iv

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

THIS PAGE INTENTIONALLY BLANK

Page 5: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page v

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

Section 1Command Line Control of Pickering LXI Instruments .... 1.1 Overview........................................................................1.1 Enabling The Command Line Utility ........................... 1.1 Step 1 - Enable Security............................................... 1.1 Step 2 - Enable The SSH Server .................................. 1.2 Notes..............................................................................1.3 Instrument Control From an SSH Client ..................... 1.4 Using Expect with SSH on an LXI Device .................. 1.7

Appendix AOriginal Version PILMon Command Set ...........................A.1 Example Commands ....................................................A.2

Appendix BNew Version PILMon Extended Command Set ................B.1 Example Commands ....................................................B.7

CONTENTS

Page 6: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page vi

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

THIS PAGE INTENTIONALLY BLANK

Page 7: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

SECTION 1

Page 1.1COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

COMMAND LINE CONTROL OF PICKERING LXI INSTRUMENTS

OverviewCommand line control of the Pickering LXI device range was added in firmware release 2.11. The utility provided was ported to the LXI instrument from the Windows utility PILMon and provides identical functionality.

Enabling the Command Line Control UtilityPickering LXI devices do not provide an SSH server in the normal configuration state, the service must be explicitly enabled.

To do this the user must first enable security, this helps to prevent inadvertent access by limiting the accessibility of instrument services, principally by requiring password access to control functions. Once security is enabled, the SSH server may be started.

All the following assumes that the user knows the IP address of the LXI device. If this is not known, a number of tools are available, many on the Pickering distribution disk, to allow the IP address to be discovered.

Step 1 - Enable SecuritySelect the Security Page from the main menu list

Page 8: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page 1.2

SECTION 1

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

Step 2 - Enable the SSH serverSelect the Instruments Control page from the main menu and find the SSH Server Control Section.

Enter the username (‘admin’) and your password and confirm with the Submit button. The page should change to show that security is enabled

Page 9: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

SECTION 1

Page 1.3COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

Click on Start SSH server, the page should change to show the service running.

The SSH server is now operative and instrument control access is available from an external SSH client application (for example PuTTY).

NOTES:The password and state of the SSH server are stored in non-volatile memory within the LXI device and so will remain in effect even after a power cycle. It is important to remember the password applied. Should the password be forgotten, the device may be reset to initial conditions by operating the LAN Reset button located at the front/rear of the chassis in the appropriate manner. Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process.

Disabling security will stop the SSH service.

Page 10: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page 1.4

SECTION 1

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

Instrument Control from an SSH ClientIn the following examples the SSH client PuTTY is used, the user will have to adapt the instructions for any other client.

First start up the SSH client and enter the IP address of the LXI device. Press Open for launch.

Page 11: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

SECTION 1

Page 1.5COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

The user will be prompted for a login name and password.

The username for instrument control is ‘admin’, the password is that defined by the user when setting security.

Once the username and password have been supplied, the LXI device will enter an application providing a command line interface to the switch cards within the device.

Page 12: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page 1.6

SECTION 1

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

When the application is expecting input, the prompt pilmon> will be displayed. Card control is achieved using a set of mnemonics plus optional data. These mnemonics are based on the Direct IO driver pilpxi.dll.

Brief details of operation is given here, full documentation instruction set may be obtained by referring to the documentation for the pilpxi or pipx40 drivers and is available in a separate document.

By default, the application will not open any card. For control of a specific card you should open it first using the command: CO [busNumber] [slotNumber]. This access is exclusive and prevents other users from accessing the cards thus preventing inadvertent operation switching functions from another location.

Typing HE in response to the prompt will list the entire command set avalailable.

The command set for the original version of PILMon is listed in Appendix A and the extended commannd set for the new version of PILMon is listed in Appendix B at the end of this document.

For any specific operation the appropriate command must be chosen, a few of the more commonly used commands are listed at the end of the appendices:

Before attempting to control a card it is important to understand the switch architecture of that card and to know how to address the required switch. Each Pickering switch card is represented as a set of one or more sub-units, each sub-unit containing one or more switches. A sub-unit represents a collection of switches of similar type, it may represent an entire matrix, or a row of simple switches, or a power supply voltage setting.

In the case of a switch sub-unit, each switch is represented by a single bit of data and may be toggled between 0 and 1, 0 representing the off state of the switch relay and 1 representing the on state.

The precise relationship between bit positions and switch location is provided in the card manual, or by use of the LS command inside the utility program PILMon in Windows, or by the LXI SSH service application.

Page 13: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

SECTION 1

Page 1.7COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

Using Expect with SSH on an LXI DeviceSecure Shell (SSH) is typically used to allow users to remotely login to an account using an interactive command line terminal, Pickering LXI devices offer an SSH service. This is normally of little use as programming interface, however software products exist which allow the user to convert such an interactive interface into a programming interface, one such product is Expect. Expect allows the user to create a program, written in Tcl, the native language of Expect, to handle interactive command line interfaces.

Expect may be obtained from: http://expect.nist.gov/

Expect on Windows

Prerequisites:

1. ActiveTcl package (8.6.1.0 32-bit version)1.1 Additional package ‘Expect’ for ActiveTcl

2. Plink (command-line ssh client)

Instructions:

1. Download and install ActiveTcl1.1 Start Tcl command prompt (TclshNN/WishNN) and install Expect package using command

‘teacup install Expect’2. Download Plink ssh client and copy it to ‘bin’ subfolder into ActiveTcl location (Usually ‘C:\Tcl\bin’)3. Make script from following source code and start it in Tcl command prompt using command

‘tclsh <your_script_name>’

Here is a simple Expect script which gains access to a Pickering LXI device, opens a specific card, clears the card, then sets some switches and obtains the current switch settings.

NOTE: The LXI device was set up with SSH enabled, and a password of “lxi”.

#!/bin/sh # \ exec tclsh “$0” ${1+”$@”} package require Expect # Setting some usefull variables set hdr “##” set pilmon_prompt “pilmon>” set host “192.168.10.160” set user “admin” set pass “lxi” set switches_list {1 2 3 4} puts stdout “$hdr Connecting to $host. . .” # Start SSH session on device $host with username $user spawn plink $user@$host # We do not want to add fingerprint of the $host to ‘known hosts’ cache expect -re “Update cached key?.*” { exp_send “n\r” exp_send_user “\n$hdr Do not update the cache.\n” }

Page 14: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page 1.8

SECTION 1

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

# wait until the text ‘password:’ is returned from the session, then reply with the password $pass expect -re “.*password: “ { exp_send “$pass\r” exp_send_user “\n$hdr Password sended\n” } eof { exp_send_user “\n$hdr Could not connect.\n” } # Open the specific card on <bus> <device> expect $pilmon_prompt { exp_send “co 2 11\r” } # Clear the opened card expect $pilmon_prompt { exp_send “cc\r” } # Close some switches foreach sw $switches_list { expect $pilmon_prompt { exp_send “sc $sw\r” } }

# Get switch settings expect $pilmon_prompt { exp_send “uv\r” } # Close session expect $pilmon_prompt { exp_send “q\r” } puts stdout “\n$hdr All done.\n”

The output of the above script is shown on the following page.

Page 15: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

SECTION 1

Page 1.9COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

NOTE: The example above uses a Pickering switch card with a 26 bit wide subunit representing a group of 26 switches, the returned results are in hexadecimal format with the least significant bit representing bit 1 of the switch group.

The source code was tested on Windows 7 SP1 (32/64 bit) with ActiveTcl 32bit (8.4.20.0/8.6.1.0) + Expect package 5.43, Plink 0.63

Page 16: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page 1.10

SECTION 1

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

Expect on Linux

Prerequisites:

1. Expect package2. SSH client

Instructions:

1. Download and install expect package if needed (check with command ‘which expect’)’2. Download and install ssh client if needed3. Make script from following source code and exec it

Here is a simple Expect script which gains access to a Pickering LXI device, opens a specific card, clears the card, then sets some switches and obtains the current switch settings.

NOTE: The LXI device was set up with SSH enabled, and a password of “lxi”.

#!/usr/bin/expect -f # Setting some usefull variables set hdr “##” set pilmon_prompt “pilmon>” set host “192.168.10.160” set user “admin” set pass “lxi” set switches_list {1 2 3 4} puts stdout “$hdr Connecting to $host. . .” # Start SSH session on device $host with username $user spawn ssh -oStrictHostKeyChecking=no -oCheckHostIP=no $user@$host # wait until the text ‘password:’ is returned from the session, then reply with the password $pass expect “*password:” { exp_send “$pass\r” exp_send_user “\n$hdr Password sended\n” } eof { exp_send_user “\n$hdr Could not connect.\n” } # Open the specific card on <bus> <device> expect $pilmon_prompt { exp_send “co 2 11\r” } # Clear the opened card expect $pilmon_prompt { exp_send “cc\r” }

Page 17: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

SECTION 1

Page 1.11COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

# Close some switches foreach sw $switches_list { expect -re $pilmon_prompt { exp_send “sc $sw\r” } } # Get switch settings expect $pilmon_prompt { exp_send “uv\r” } # Close session expect $pilmon_prompt { exp_send “q\r” } puts stdout “\n$hdr All done.\n”

The output of the above script is shown on the following page.

Page 18: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page 1.12

SECTION 1

COMMAND LINE CONTROL OF LXI INSTRUMENTS

pickering

NOTE: The example above uses a Pickering switch card with a 26 bit wide subunit representing a group of 26 switches, the returned results are in hexadecimal format with the least significant bit representing bit 1 of the switch group.

The source code was tested on GNU/Linux 2.6.36 with expect package 5.44.1.15, OpenSSH_5.5p1

Page 19: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

APPENDIX A

Page A.1

pickering

COMMAND LINE CONTROL OF LXI INSTRUMENTS

APPENDIX A - Original Version PILMon

Original Version PILMon Command Set

Command DescriptionAD <card(int)> <subunit(int)> [input(int)] Select active card and subunitSC <bit(int)> Close switchSO <bit(int)> Open switchSB <pattern(hex string)> Write states of switches on subunitCS <no parameters> Clear subunitRS <no parameters> Clear all cardsST <no parameters> Get card status codeBV <no parameters> View states of switches on subunitBR <no parameters> Read state of whole input subunitLS <no parameters> List all cardsWC <index(int)> <value(int)> Write int calibration valueRC <index(int)> Read int calibration valueDM <no parameters> Set mode of driverAC <no parameters> Not supportedCM <no parameters> Clear mask on whole subunitSM <no parameters> Not supportedMB <pattern(hex string)> Write mask states to whole subunitMV <no parameters> View state of mask on whole subunitOC [access(int)] Open all cards in LXICC <no parameters> Close all cardsVO <bus(int> <device(int)> [access(int)] Open card with specified bus and slotVC <no parameters> Close current cardHE <no parameters> Show this helpHL <no parameters> Show this helpSV <bit(int)> Get state of a switchMS <bit(int)> Get state of mask of a switchIS <bit(int)> Read bit state of input subunitAR <no parameters> Clear current cardXC <column(int)> <row(int)> Close crosspointXO <column(int)> <row(int)> Open crosspointXV <column(int)> <row(int)> View state of a crosspointXM <no parameters> Not supportedXS <column(int)> <row(int)> Get state of mask of a crosspointDI <no parameters> Get card diagnosticSE <no parameters> Get settling time of relaysCL <no parameters> Get closure limit of subunitSS <no parameters> Status code of subunitPT <no parameters> Info about PSU in string formPI <no parameters> Info about PSUPS <voltage(float)> Set voltage of PSUPV <no parameters> Get current voltage of PSUPE <state(int)> Set enable state of PSUCF <no parameters> Count free cardsLF <no parameters> Find free cardsQ Quit pilmon

Page 20: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page A.2

APPENDIX A pickering

COMMAND LINE CONTROL OF LXI INSTRUMENTS

Example Commands - Original Version of PILMon

AD 1 2 Selects card 1, sub-unit 2

SC 3 Closes switch 3 on current sub-unit

AD 1 3 Selects card 1, sub-unit 3

BV Obtains state of the active subunit

Page 21: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

APPENDIX B

Page B.1

pickering

COMMAND LINE CONTROL OF LXI INSTRUMENTS

APPENDIX B- New Version PILMon

New Version PILMon Extended Command SetCommands are accepted in long and short form. Commands are not case sensitive. For more detailed description of commands, use: Help <command>

CommandsDescription

Short Long

AAG AttenuatorAttenuationGet <no parameters> Get current attenuation of selected subunit. Returns float value.

AAS AttenuatorAttenuationSet <attenuation(float)> Set attenuation of selected subunit to <attenuation>.

AI AttenuatorInfo <no parameters> Get information about selected attenuator subunit. Returns values: <type>;<number of steps>;<size of each step>

AP AttenuatorPadValue <index(int)> Get value of attenuator pad at <index>. Returns float value.

AT AttenuatorType <no parameters> Get information about selected attenuator subunit in text form. Returns string in form: ATTEN(<number of steps><step size in dB>)

BCG BatteryCurrentGet <no parameters> Get current setting of battery simulator subunit current leak. Returns float value.

BCS BatteryCurrentSet <current(float)> Set battery simulator subunit current leak.

BEG BatteryEnableGet <no parameters> Get current setting of battery simulator subunit output states. Returns binary pattern characterizing states.

BES BatteryEnableSet <pattern(int)> Set battery simulator subunit output states according to pattern.

BIG BatteryInterlockGet <no parameters> Get interlock state of battery simulator subunit. Returns 1 if all interlocks are up or 0 if one or more interlocks are down.

BVG BatteryVoltageGet <no parameters> Get current setting of battery simulator subunit voltage. Returns float value.

BVS BatteryVoltageSet <voltage(float)> Set battery simulator subunit votage.

LRI CalibrationReadInt <index(int)> Read integer calibration value of pad <index>. Returns integer value.

LRD CalibrationReadDate <store(int)> Read calibration date of subunit. <store> can be 0-for user store or 1-for factory store. Returns date in form: <year>;<day>;<interval>.

LRF CalibrationReadFp <store(int)> <offset(int)> Read float calibration value of <store> on position <offset>. Returns float value.

LWI CalibrationWriteInt <index(int)> <value(int)> Write integer calibration value <value> of pad <index>.

LWD CalibrationWriteDate<store(int)> <interval(int)> Write calibration date of subunit. <store> can be 0-for user store or 1-for factory store. Date written is current system date <interval> is number of days for cards to be recalibrated.

LWF CalibrationWriteFp <store(int)> <offset(int)> <value(float)> Write float calibration value <value> of <store> on position <offset>.

CC CardClear <no parameters> Clear all switches on all subunits on selected card.CCA CardClearAll <no parameters> Clear all switches on all subunits on all cards.

CL CardClose <no parameters> Close selected card. Card cannot be used until opened again.

CLA CardCloseAll <no parameters> Close all opened cards.

CD CardDiagnostic<no parameters> Get text diagnostic of selected card. When card is faulty diagnostics shows details about faults. Returns diagnostic text. It does not diagnose the relays, only communication.

Page 22: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page B.2

APPENDIX B pickering

COMMAND LINE CONTROL OF LXI INSTRUMENTS

CommandsDescription

Short Long

CI CardId <no parameters> Get card id string in form: <card model>;<serial number>;<card revision>

CLO CardLoc <no parameters> Get card physical location. Returns location in form: <bus>;<device>;

CO CardOpen

<bus(int)> <device(int)> [access(int)] Open card on physical position <bus> <device>. Optional parameter [access] modifies access setting. 1-exclusive access 0-nonexclusive access. Card is opened with exclusive access implicitly.

COA CardOpenAll

[access(int)] Open all cards in LXI if possible. Optional parameter [access] modifies access setting. 1-exclusive access 0-nonexclusive access. Cards are opened with exclusive access implicitly.

CS CardStatus<no parameters> Get status of selected card. Status consists of binary flags detecting various problems with the card. Result: hex integer containing status flags.

FCC FindCountCards <no parameters> Get number of available cards in LXI. Returns integer value.

FFC FindFreeCards <no parameters> Get location of all unopened cards. Returns locations of cards in form: <bus1> <device1>;<bus2> <device2>;...

IBR InputBitRead <bit(int)> Read state of individual <bit> of selected input subunit. Returns state of bit= 1-active 0-inactive.

IUR InputSubunitRead <no parameters> Read states of all bits of selected input subunit. Returns hex string representing all states of bits.

PES PSUEnableSet <state(int)> Set output state of PSU subunit.

PI PSUInfo<no parameters> Get info about selected PSU subunit. Returns info in form: <type>;<rated voltage>; <rated current>;<precision>;<capabilities(hex flags)>

PT PSUType <no parameters> Get info about selected PSU subunit in string form. Returns info in form: PSUDC(<rated voltage><rated current>).

PVG PSUVoltageGet <no parameters> Get current setting of voltage of selected PSU subunit. Returns float value.

PVS PSUVoltageSet <voltage(float)> Set voltage setting of selected PSU subunit.

RI ResistorInfo<no parameters> Get info about selected programmable precision resistor subunit. Returns: <minres>;<maxres>;<referenceres>;<precisionpc>; <precisiondelta>;<reserved>;<reserved>;<capabilities(hex flags)>

RRG ResistorResistanceGet <no parameters> Get output resistance of selected programmable precision resistor subunit. Returns float value.

RRS ResistorResistanceSet <resistance(float)> Set output resistance of selected programmable precision resistor subunit to <resistance>.

SC SwitchClose <bit(int)> Close switch (energize relay coil) on selected subunit of index <bit>.

SO SwitchOpen <bit(int)> Open switch (disengage relay coil) on selected subunit of index <bit>.

SV SwitchView <bit(int)> Get state of switch on selected subunit of index <bit>. Returns 1 if coil is energized 0 otherwise.

SM SwitchMask <bit(int)> Mask switch on selected subunit of index <bit>. Switch cannot be operated until unmasked.

SU SwitchUnmask <bit(int)> Clear mask of switch on selected subunit of index <bit>.

Page 23: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

APPENDIX B

Page B.3

pickering

COMMAND LINE CONTROL OF LXI INSTRUMENTS

CommandsDescription

Short Long

SMV SwitchMaskView <bit(int)> Get state of mask of switch on selected subunit of index <bit>. Returns 1 if mask is active 0 otherwise.

UC SubunitClear <no parameters> Clear all switches (disengage relays) on selected subunit.

UCL SubunitClosureLimit<no parameters> Get closure limit of selected subunit. Closure limit is maximum number of switches that can be simultaneously closed on a subunit. Returns integer value.

UE SubunitEnumerate <no parameters> Get number of input and output subunits on selected card. Returns: <number of input subunits>;<number of output subunits>

UI SubunitInfo

[input(int)] Get information about subunit. Optional parameter <input> states whether to get information about input-0 or output-1 subunit. Implicitly its output. Returns information in form: <type>;<number of rows>;<number of columns>”

USE SubunitSettleTime <no parameters> Get time in ms that is required for relay contanct to settle down after switch operation. Returns integer value.

UST SubunitStatus<no parameters> Get status of selected subunit. Status consists of binary flags detecting various problems of subunit. Result: hex integer containing status flags.

UT SubunitType

[input(int)] Get string info about selected subunit. Return string contains description of the subunit. Optional parameter <input> states whether to get information about input-0 or output-1 subunit. Implicitly its output. For example: MATRIX(<columns>X<rows>)”

UMC SubunitMaskClear <no parameters> Clears all mask bits on selected subunit.

UMV SubunitMaskView <no parameters> View states of all mask bits on selected subunit. Returns hex string describing mask. Each bit in hex string represents 1 bit of mask.

UMW SubunitMaskWrite <pattern(hex string)> Writes hex string converted to bit array into subunit mask bits. Note that hex string must be started with “0x” notation.

UV SubunitView<no parameters> View states of all switches on selected subunit. Returns hex string describing states of switches. Each bit in hex string represents 1 switch.

UW SubunitWrite <pattern(hex string)> Writes hex string converted to bit array into subunit. Note that hex string must be started with \0x\”notation”.

VEG VsourceEnableGet<no parameters> Get enabled states of selected voltage source subunit as pattern. Returns integer pattern where each bit represents one voltage source output.

VES VsourceEnableSet <pattern(int)> Set enabled states of selected voltage source subunit. Each bit in <pattern> represents one voltage source output.

VRG VsourceRangeGet <no parameters> Get settings of range of selected voltage source subunit. Returns float value.

VRS VsourceRangeSet <range(float)> Set <range> of selected voltage source subunit.

VVG VsourceVoltageGet <no parameters> Get voltage settings of selected voltage source subunit. Returns float value.

VVS VsourceVoltageSet <voltage(float)> Set <voltage> of selected voltage source subunit.

XC XpointClose <column(int)> <row(int)> Close switch (energize relay coil) on selected matrix subunit on position <column> <row>.

XO XpointOpen <column(int)> <row(int)> Open switch (disengage relay coil) on selected matrix subunit in position <column> <row>.

Page 24: pickering User Manual · 2014. 5. 6. · Refer to Section 6 “Troubleshooting” of the user manual for your LXI device for details of this process. Disabling security will stop

Page B.4

APPENDIX B pickering

COMMAND LINE CONTROL OF LXI INSTRUMENTS

CommandsDescription

Short Long

XV XpointView <column(int)> <row(int)> Get state of switch on selected matrix subunit in position <column> <row>. Returns 1 if coil is energized 0 otherwise.”

XM XpointMask <column(int)> <row(int)> Mask switch on selected matrix subunit in position <column> <row>. Switch can’t be operated until unmasked.”

XU XpointUnmask <column(int)> <row(int)> Clear mask of switch on selected matrix subunit in position <column> <row>.

XMV XpointMaskView <column(int)> <row(int)> Get state of mask of switch on selected matrix subunit in position <column> <row>. Returns 1 if mask is active 0 otherwise.

MS ModeSet <no parameters> Set driver in different working mode. This feature is to be used only by experts!

MAS MultiAccessSet<access(int)> [card(int)] Modify access rights for selected card. <access> is 1 for exclusive access 0 for multiaccess. Optional parameter [card] can be used to change access rights for unopened card.

MAG MultiAccessGet[card(int)] Query access rights for selected card. Optional parameter [card] can be used to query access rights for unopened card. Return string describing access rights.

USL SubunitSelect

<card(int)> <subunit(int)> [input(int)] Selects active <subunit> on card number <card>. Optional parameter <input> states whether to get information about input-0 or output-1 subunit. Implicitly it’s output. When called without any parameters returns actual settings.

LS List <no parameters> List all cards and shows their location. For opened cards more details will be displayed.

HE Help [command(string)] Show help about all commands. Help <command> shows more detailed explanation of syntax and meaning of commands.

Q Quit Ends work with pilmon. All resources will be freed but states of cards remain unchanged.

Example Commands - New Version of PILMon

COA Open All Cards

LS List all cards

USL 2 3 1 Selects card 2, sub-unit 3, 1=output of sub-unit 3

SC 3 Closes switch 3 on current sub-unit

USL 1 4 0 Selects card 1, sub-unit 4, 0=input of sub-unit 4

UV View states of switch on current sub-unit