Text preview for : Keithley 220 Programming Manual.pdf part of Keithley Modell 220 Programming Manual



Back to : Keithley 220 Programming | Home

Model 220,230
Programming Manual

Contains IEEE Programming

Information

WARRANTY
Keithley Instruments, Inc. warrants this product to be free from defects in material and workmanship from date of shipment. for a period of I year

Keithley Instruments, Inc. warrants the following batteries, diskettes, and documentation.

items for 90 days from the date of shipment:

probes, cables, rechargeable

During the warranty period, we will, at our option, either repair or replace any product that proves to be defective.

To exercise this warranty, write or call your local Keithley representative, or contact Keithley headquarters in Cleveland, Ohio. You will be given prompt assistance and return instructions. Send the product, transportation prepaid, to the indicated service facility. Repairs will be made and the product returned, transportation prepaid. Repaired or replaced products are warranted for the balance of the original warranty period, or at least 90 days.

LIMITATION OF WARRANTY
This warranty does not apply to defects resulting from product modification without Keithley's express written consent, or misuse of any product or part. This warranty also does not apply to fuses, software, non-rechargeable batteries, damage from battery leakage, or problems arising from normal wear or failure to follow instructions.

THIS WARRANTY IS IN LIEU OF ALL OTHER WARRANTIES, EXPRESSED OR IMPLIED, INCLUDING IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. THE REMEDIES VIDED HEREIN ARE BUYER'S SOLE AND EXCLUSIVE REMEDIES.

ANY PRO-

NEITHER KEITHLEY INSTRUMENTS, INC. NOR ANY OF ITS EMPLOYEES SHALL BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OF ITS INSTRUMENTS AND SOFTWARE EVEN IF KEITHLEY INSTRUMENTS, INC., HAS BEEN ADVISED IN ADVANCE OF THE POSSIBILITY OF SUCH DAMAGES. SUCH EXCLUDED DAMAGES SHALL INCLUDE, BUT ARE NOT LIMITED TO: COSTS OF REMOVAL AND INSTALLATION, LOSSES SUSTAINED AS THE RESULT OF INJURY TO ANY PERSON, OR DAMAGE TO PROPERTY.

Keithley Instruments,
BELGIUM: CHINA: FRANCE: GERMANY: GREAT BRITAIN: INDIA: ITALY NETHERLANDS: SWITZERLAND: TAIWAN:

Inc.

l

28775 Aurora Road Cleveland, OH 44139 440-248-0400
l l l

l

Fax: 440-248-6168
l l

l

http:Nwww.keithley.com
l

Keithley Instruments B.V. Keithley Instruments China Keithley Instruments Sari Keithlev Instruments GmbH Keith& Instruments Ltd Keithley Instruments GmbH Keithley Instruments s.r.1. Keithley Instruments B.V. Keithley Instruments SA Keithley Instruments Taiwan

Bergensesteenweg 709 * B-1600 Sint-Pieters-Leeuw* 02/363 00 40. Fax: 02/363 00 64 Yuan Chen Xin Building, Room 705 12Yumin Road, Dewi, Madian Beijing loo029 861@62022886 Fax.: 861@62022892 B.P. 60.3, alICe des Garays 91122 Palaiseau C&x * 01 64 53 20 20 * Fax: 01 60 I 1 77 26 Lundsberger Strwe 65 D-821 10 Germering * 089/84 93 07-40 - Fax: 089/84 93 07-34 The Minster 58 Portman Road * Reading, Berkshire RG30 IEA * 01 IS-9 57 56 66 * Fax: 01 IS-9 59 64 69 Flat 28. WILOCRISSA 14. Rest House Crescent * Bangalore S60001 91-EO-509-1320121 -Fax: 91-80-509-1322 Viale S. Gimignano. 38 * 20146 Milano 02/48 30 30 08 * Rx: 02/48 30 22 74 Postbus 559 4200AN Gorinchem * 0183-635333 *Fax: 0183-630821 Kriesbachsvasse 4 * 8600 Diibendorf*OI-821 94 44 Fax: 01-820 3081 1 FI. 85 PO Ai Street * Hsinchu, Taiwan, R.O.C. - 886-3572-9077 * Fax: 886-3572-903 1 o/99
l l l l l l l l

Model 220 Programmable Current Source Model 230 Programmable Current Source Programming Manual

01982,

Keithley

Instruments, Ohio, U.S.A.

Inc.

All rights reserved. Cleveland, Third Document Number: Printing, May 2000 220-900-01 Rev. C

SPECIFICATIONS
IEEE-488 BUS IMPLEMENTATION:
Multiline Commands: DCL, LLO, SDC, GET, GTL, UNT, UNL, SPE, SPD. Uniline Commands: IFC, REN, EOI, SRQ, ATN. Interface Functions: SHl, AHl, T6, TE6, L4, LH), SRl, RLl, PW, DCl, DTl, CO, El. Internal Programmable Parameters: DISPLAY MODE, OUTPUT, Prefix (Data Format), EOl, SRQ (including mask for over limit), PROGRAM MODE, Range, Trigger Mode, Terminator Character, Inputs (SOURCE, LIMIT, DWELL TIME, 106Point Memory Locations), Output Status, Digital Self Test. Digital l/O Port: A separate I/O port consisting of four input and four output lines as well as common (IEEE4881 and + 5VDC. Outputs will drive one TTL load. Inputs represent one TTL load. The 220/230 can be programmed to generate a "SRQ" upon any change in the four bit input data. Mating connector supplied.

IEEE COMMAND
ADDRESS LISTEN: COMMAND GROUP LAG = LISTEN ADDRESS GROUP MLA = MY LISTEN ADDRESS UNL= UNLISTEN TAG =TALK ADDRESS GROUP MTA = MY TALK ADDRESS UNT = UNTALK OTA=OTHER TALK ADDRESS COMMAND GROUP ACG = ADDRESSED COMMAND GROUP GET= GROUP EXECUTE TRIGGER GTL = GO TO LOCAL SDC = SELECTIVE DEVICE CLEAR STATUS COMMAND GROUP RQS = REQUEST SERVICE SRQ= SERIAL POLL REQUEST STB = STATUS BYTE

GROUPS
HANDSHAKE COMMAND GROUP DAC = DATA ACCEPTED RFD=READY FOR DATA DAV = DATA VALID UNIVERSAL COMMAND GROUP ATN = ATTENTION DCL= DEVICE CLEAR IFC = INTERFACE CLEAR LLO = LOCAL LOCKOUT REN = REMOTE ENABLE SPD = SERIAL POLL DISABLE SPE = SERIAL POLL ENABLE END = EOI

TALK:

ADDRESSED

DEVICE

DEPENDENT

COMMAND

GROUP

Display:

DO Dl D2 D3 Fo Fl GO Gl G2 G3 G4 G5 KO Kl M(O-31)

Source Limit Dwell Time Memory Location Standby Operate Location With Prefix Location Without Prefix Buffer Address With Prefix Buffer Address Without Prefix Full Buffer With Prefix Full Buffer Without Prefix Send EOI Send No EOI Disabled: IDDC or IDDCO: Over Limit: End of Buffer;`End of Dwell Time; No Remote; Input Port Change Single Continuous Step Auto 1nA (220); 100mV (230) 1OnA (220): 1V (230) 100nA (220); 1OV (230) 14 (220); 1OOV (230) 1ofi f220) 100&A (220) I/O Port: status: Digital Self Test: Execute: Terminator: Trigger:

R7 R8 R9 TO Tl

1mA (220) 1OmS (220) lOOmA (220) Start On Stop On Start On Stop On StartOnX Stop On Start On Stop On Talk Talk GET GET X External Trigger External Trigger + - /,.e

Function: Prefix: (Data Format)

T4 T5 T6 3-7 YIASCII) YILF) YfCR) Y(DEL) V W B 0015) uo Ul JO X

EOI: SRQ:

Any ASCII except capitals, numbers, CR LF LF CR None

Inputs:

Program:

PO Pl P2 RO Rl R2 I?3 R4 R5 R6

Current Source (220); Current Limit (230) Vottage Limit (220); Voltage Source (230) Dwell Time Buffer Address Memory Location Set Output Control Status Word I/O Port status Bits

Range:

Execute Command

Safety Precautions
Users of this product must bc protcctcd from electric shock at all times. The responsible body must ensure that users arc prevented access and/or insulated from every connection point. In some cases, connections must be exposed to potential human contact. Product users in these circumstances must bc trained to protect thcmsclves from the risk of electric shock. If the circuit is capable ofopcrating at or above 1000 volts. no conductive part of the circuit may be exposed. As described in the Intcmational Electrotechnical Commission (IEC) Standard IEC 664, digital multimctcr measuring circuits (e.g., Keithley Models I75A, 199,2000,2001, 2002. and 2010) arc Installation Category II. All other instruments' signal terminals arc Installation Category I and must not bc connected to mains. Do not connect switching cards directly to unlimited power circuits. They are intended to bc used with impedance limited sources. NEVER connect switching cards directly to AC mains. When connecting sources to switching cards, install protective devices to limit fault current and voltage to the card. Before operating an instrument, make sure the line cord is connccted to a properly grounded power receptacle. Inspect the connecting cables, test leads, and jumpers for possible wear. cracks, or breaks before each use. For maximum safety, do not touch the product, test cables. or any other instruments while power is applied to the circuit under test. ALWAYS remove power from the cntirc test system and discharge any capacitors before: connecting or disconnecting cables or jumpers, installing or removing switching cards, or making internal changes, such as installing or removing jumpers. Do not touch common side Always make dry, insulated measured. any object that could provide a current path to the of the circuit under test or power line (earth) ground. measurements with dry hands while standing on a surface capable of withstanding the voltage being

The following safety precautions should be observed before using this product and any associated instrumentation. Although some instruments and accessories would normally be used with non-hazardous voltages, there are situations where hazardous conditions may be present. This product is intended for use by qualified personnel who recognize shock hazards and are familiar with the safety precautions required to avoid possible injury. Read the operating information carefully before using the product. The types of product users are: Responsible body is the individual or group responsible for the use and maintenance of equipment, for ensuring that the equipment is operated within its specifications and operating limits, and for ensuring that operators are adequately trained. Operators use the product for its intended function. They must be trained in electrical safety procedures and proper use of the instrument. They must be protected from electric shock and contact with hazardous live circuits. Maintenance personnel perform routine procedures on the product to keep it operating, for example, setting the line voltage or replacing consumable materials. Maintenance procedures are described in the manual. The procedures explicitly state if the operator may perform them. Otherwise, they should be performed only by service personnel. Service personnel are trained to work on live circuits, and perform safe installations and repairs of products. Only properly trained service personnel may perform installation and service procedures. Exercise extreme caution when a shock hazard is present. Lethal voltage may be present on cable connectorjacks or test fixtures. The American National Standards Institute (ANSI) states that a shock hazard exists when voltage levels greater than 30V RMS, 42.4V peak, or 60VDC are present. A good safety practice is to expect that hazardous voltage is present in any unknown circuit before measuring.

The instrument and accessories must be used in accordance with its specifications and operating instructions or the safety of the equipment may be impaired. Do not exceed the maximum signal levels of the instruments and accessories, as defined in the specifications and operating information, and as shown on the instrument or test fixture panels, or switching card. When fuses are used in a product, replace with same type and rating for continued protection against fire hazard. Chassis connections must only be used as shield connections measuring circuits, NOT as safety earth ground connections. fat

The WARNING heading in a manual explains dangers that might result in personal injury or death. Always read the associated information very carefully before performing the indicated procedure. The CAUTION heading in a manual explains hazards that could damage the instrument. Such damage may invalidate the warranty. Instrumentation and accessories shall not bc conncctcd to humans. disconnect the line cord and

Before performing all test cables.

any maintenance,

If you are using a test fixture, keep the lid closed while power is applied to the device under test. Safe operation requires the use of a lid interlock. screw is present, connect it to safety earth ground using the Ifa@ wire recommended in the user documentation. The a ! symbol on an instrument indicates that the user should refer to the operating instructions located in the manual. symbol on an instrument shows that it can source or meaThe A sure 1000 volts or more, including the combined effect of normal and common mode voltages. Use standard safety precautions to avoid personal contact with these voltages.

To maintain protection from electric shock and fire, replacement components in mains circuits, including the power transformer, test Icads. and input jacks, must be purchased from Keithlcy Instruments. Standard fuses, with applicable national safety approvals, may be used if the rating and type are the same. Other components that are not safety related may bc purchased from other suppliers as long as they are equivalent to the original component. (Note that selectcd parts should be purchased only through Keithley Instruments to maintain accuracy and functionality of the product.) If you arc unsure about the applicability of a replacement component, call a Keithley Instruments office for information. To clean an instrument, use a damp cloth or mild. water based cleaner. Clean the exterior of the instrument only. Do not apply cleaner directly to the instrument or allow liquids to enter or spill on the instrument. Products that consist of a circuit board with no case or chassis (e.g., data acquisition board for installation into a computer) should never require cleaning if handled according to instructions. If the board becomes contaminated and operation is affected, the board should be returned to the factory for proper cleaning/servicing.

Rev. IO/99

TABLE OF CONTENTS
Paragraph Title Page

1 .I 1.2 1.3 1.4 1.5 1.6 1.7

SECTION 1 - GENERAL INFORMATlON introduction ................................................................................................................................................................................................... Model 220 and 230 IEEE Interface Features.. .............................................................................................................................................. Warranty Information.. ................................................................................................................................................................................... Manual Addenda.. ......................................................................................................................................................................................... Safety Symbols and Terms ........................................................................................................................................................................... Using the Model 220/230 Programming Manual. .......................................................................................................................................... IEEE Specifications ....................................................................................................................................................................................... SECTION 2 - AN OVERVIEW OF THE IEEE-488 BUS Introduction ............................................................................................ . ...................................................................................................... Bus Description.. ........................................................................................................................................................................................... IEEE-488 Bus Lines.. .................................................................................................................................................................................... Bus Management Lines ........................................................................................................................................................................ Handshake Lines .................................................................................................................................................................................. Data Lines ............................................................................................................................................................................................. Bus Commands.. ........................................................................................................................................................................................... Uniline Commands.. .............................................................................................................................................................................. Universal Commands.. ......................................................................................................................................................................... Addressed Commands ......................................................................................................................................................................... Unaddressed Commands ..................................................................................................................................................................... Device-Dependent Commands.. ........................................................................................................................................................... Command Codes .......................................................................................................................................................................................... Command Sequences .................................................................................................................................................................................. Addressed Command Sequence.. ........................................................................................................................................................ Universal Command Sequence ............................................................................................................................................................ Device-Dependent Command Sequence ............................................................................................................................................. SECTION 3 - SYSTEM CONFIGURATION Introduction ................................................................................................................................................................................................... Hardware Considerations.. ............................................................................................................................................................................ Typical Systems .................................................................................................................................................................................... Bus Connections .................................................................................................................................................................................. Primary Address Selection ................................................................................................................................................................... Digital I/O Port.. ..................................................................................................................................................................................... Software Considerations.. ............................................................................................................................................................................. Controller Interface Routines ................................................................................................................................................................ HP-85 BASIC Statements.. ................................................................................................................................................................... Interface Function Codes ...................................................................................................................................................................... Model 220/230 Interface Commands. ................................................................................................................................................... SECTION 4 - OPERATION Introduction ................................................................................................................................................................................................... General Bus Commands.. ............................................................................................................................................................................. REN (Remote Enable) .......................................................................................................................................................................... IFC (Interface Clear). ............................................................................................................................................................................. LLO (Local Lockout). ............................................................................................................................................................................. GTL (Go To Local). ................................................................................................................................................................................ DCL (Device Clear). .............................................................................................................................................................................. SDC (Selective Device Clear). .............................................................................................................................................................. GET (Group Execute Trigger) ............................................................................................................................................................... Serial Polling (SPE, SPD) ..................................................................................................................................................................... Device-Dependent Command Programming ................................................................................................................................................ Execute (X) ........................................................................................................................................................................................... Display Mode (D) .................................................................................................................................................................................. Inputs (I, V, W, L, B). .............................................................................................................................................................................. I/O Port (0) ........................................................................................................................................................................................... Function (F). .......................................................................................................................................................................................... Data Format (G). ................................................................................................................................................................................... EOI Programming (K) ...........................................................................................................................................................................

1-l l-l l-l l-l l-1 l-l 1-l

2.1 2.2 2.3 2.3.1 2.3.2 2.3.3 2.4 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.5 2.6 2.6.1 2.6.2 2.6.3

2-l 2-l 2-l 2-l 2-2 2-2 2-3 2-3 2-3 2-3 2-3 2-3 2-4 2-4 2-6 2-6 2-6

3.1 3.2 3.2.1 3.2.2 3.2.3 3.2.4 3.3 3.3.1 3.3.2 3.3.3 3.3.4

3-1 3-1 3-l 3-l 3-3 3-4 3-4 3-4 3-5 3-5 3-6

4.1 4.2 4.2.1 4.2.2 4.2.3 4.2.4 4.2.5 4.2.6 4.2.7 4.2.8 4.3 4.3.1 4.3.2 4.3.3 4.3.4 4.3.5 4.3.6 4.3.7

4-l 4-l 4-l 4-l 4-2 4-2 4-2 4-3 4-3 4-3 4-4 4-6 4-6 4-6 4-8 4-8 4-8 4-10

TABLE OF CONTENTS
Paragraph
4.3.8 4.3.9 4.3.10 4.3.11 4.3.12 4.3.13 4.3.14 4.4 4.4.1 4.4.2 4.4.3 4.5 4.5.1 4.5.2

(CONT.)
Page
4-10 4-13 4-13 4-14 4-15 4-15 4-17 4-17 4-18 4-18 4-18 4-18 4-18 4-19

Title

SRQ Mode (M) and Status Byte Format.. ............................................................................................................................................. Program Mode (P) ................................................................................................................................................................................ Range (R) ............................................................................................................................................................................................. Trigger Mode (T) ................................................................................................................................................................................... Programmable Terminator (Y). .............................................................................................................................................................. Status Word (U) .................................................................................................................................................................................... Digital Self-Test (J). ............................................................................................................................................................................... Front Panel Error Messages ......................................................................................................................................................................... IDDC Error.. .......................................................................................................................................................................................... IDDCO Error ......................................................................................................................................................................................... No Remote Error.. ................................................................................................................................................................................. Waveform Programs ...................................................................................................................................................................................... Sine Wave Approximation ..................................................................................................................................................................... Ramp Simulation.. ................................................................................................................................................................................. SECTION 5 - IEEE COMMAND FLOW CHARTS Introduction ................................................................................................................................................................................................... DCL (Device Clear). ...................................................................................................................................................................................... IFC (Interface Clear) ..................................................................................................................................................................................... REN (Remote Enable) .................................................................................................................................................................................. Serial Polling (SPE, SPD) ............................................................................................................................................................................. UNL (Unlisten). .............................................................................................................................................................................................. UNT (Untalk) ................................................................................................................................................................................................. GET (Group Execute Trigger). ....................................................................................................................................................................... GTL (Go To Local). ........................................................................................................................................................................................ SPC (Selective Device Clear) ....................................................................................................................................................................... Device-Dependent Commands.. ...................................................................................................................................................................

5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 5.10 5.11

5-1 5-1 5-1 5-1 5-2 5-2 5-3 5-3 5-4 5-4 5-4

ii

LIST OF TABLES
Table
2-l 2-2 2-3 2-4 3-l 3-2 3-3 3-4 3-5 3-6 4-1 4-2 4-3 4-4 4-5 4-6 4-7 4-8 4-9 4-10

Title
IEEE-488 Bus Command Summary ............................................................................................................................................................. Hexadecimal and Decimal Command Codes ............................................................................................................................................... Typical Addressed Command Sequence ...................................................................................................................................................... Typical Device-Dependent Command Sequence.. ........................................................................................................................................ IEEE Contact Designations.. ......................................................................................................................................................................... Primary Address Switch Positions ................................................................................................................................................................ Digital I/O Port Pin Assignments ................................................................................................................................................................... HP-85 IEEE-488 Basic Statements .............................................................................................................................................................. Model 220/230 Interface Function Codes ..................................................................................................................................................... IEEE Command Groups ............................................................................................................................................................................... General Bus Command.. ............................................................................................................................................................................... Default Values (Status on Power Up and After SDC or DCL) ....................................................................................................................... Device-Dependent Command Summary ...................................................................................................................................................... Model 220 and 230 Display Mode Commands ............................................................................................................................................. Input Command Summary ............................................................................................................................................................................ l/O Port Command Parameters ..................................................................................................................................................................... SRQ Commands and Conditions .................................................................................................................................................................. Status Byte Data and Error Conditions. ........................................................................................................................................................ Range Commands ........................................................................................................................................................................................ I/O Port Status Values.. .................................................................................................................................................................................

Page
2-4 2-4 2-6 2-6 3-2 3-3 3-4 3-5 3-6 3-6 4-l 4-3 4-5 4-6 4-7 4-8 4-11 4-12 4-13 4-16

LIST OF FIGURES
Figure
2-l 2-2 2-3 3-1 3.2 3-3 3-4 3-5 3-6 3-7 3-8 4-1 4-2 4-3 4-4 4-5 4-6 5-1 5-2 5-3 5-4 5-5 5-6 5-7 5-8 5-9 5-10

Title
IEEE Bus Configuration ................................................................................................................................................................................ IEEE Handshake Sequence.. ........................................................................................................................................................................ Command Codes ......................................................................................................................................................................................... System Types ................................................................................................................................................................................................ IEEE-488 Connector.. ................................................................................................................................................................................... IEEE-488 Connections.. ................................................................................................................................................................................ Rear Panel of Model 220 or 230 Showing IEEE Connectors and Switches ................................................................................................. Contact Assignments.. .................................................................................................................................................................................. Typical IEEE-488 Bus Driver (One of 16). ..................................................................................................................................................... Primary Address Switches (Address = 12 Shown) ....................................................................................................................................... Digital I/O Port Pin Assignments.. ................................................................................................................................................................. Model 220 and 230 Data Formats.. ............................................................................................................................................................... SRQ Mask Format ........................................................................................................................................................................................ Status Byte Format ....................................................................................................................................................................................... Status Word Format (Default Values Shown) ................................................................................................................................................ I/O Status Format (Default Values Shown). ................................................................................................................................................... Front Panel Error Messages ......................................................................................................................................................................... DCL Command Flow Chart ........................................................................................................................................................................... IFC Command Flow Chart ............................................................................................................................................................................ REN Command Flow Chart .......................................................................................................................................................................... Serial Poll Flow Chart.. .................................................................................................................................................................................. UNL Command Flow Chart.. ......................................................................................................................................................................... UNT Command Flow Chart.. ......................................................................................................................................................................... GET Command Flow Chart. .......................................................................................................................................................................... GTL Command Flow Chart.. ......................................................................................................................................................................... SDC Command Flow Chart .......................................................................................................................................................................... Device-Dependent Command Flow Chart ....................................................................................................................................................

Page
2-2 2-2 2-5 3-l 3-l 3-2 3-2 3-2 3-3 3-3 3-4 4-9 4-12 4-12 4-l 6 4-16 4-l 8 5-l 5-l 5-2 5-2 5-3 5-3 5-4 5-4 5-5 5-5

iii/iv

SECTION 1 GENERAL INFORMATION
1.1 INTRODUCTION The Model 220 programmable current source, and the Model 230 programmable voltage source are each supplied with a standard IEEE-488 interface. This interface adds an extra measure of versatility by allowing the transmission of data and commands over the IEEE-488 bus. The built-in IEEE interface provides all the logic necessary to interface the Models 220 and 230 to the bus using standard IEEE-488-1978 protocol. Additionally, the interface board incorporates a separate digital I/O port that may be used to interface the Models 220 and 230 to other digital instrumentation. 1.2 MODEL 220 AND 230 IEEE INTERFACE FEATURES may be found on an addendum included with this manual. Be sure to review these changes before attempting to program the instrument. 1.5 SAFETY SYMBOLS AND TERMS

The following safety symbols and terms are used in this manual and may be found on the Model 220 and 230: on the instrument indicates that the The symbol Q' user should refer to the operating instructions. on the instrument indicates that a The symbol potential of 1OOOV or more may be present on the terminal(s). Standard safety precautions should be observed when such dangerous voltages are encountered. information associated with the WARNING heading explains dangers that could result in personal injury or death. Information following the CAUTION heading explains hazards that could damage the instrument. 1.6 USING THE MANUAL MODEL 220/230 PROGRAMMING

Important IEEE-488 interface features include: 1. IEEE-4881978 Standard. The Model 220 or 230 communicates with other instrumentation using the same IEEE488-1978 standards. 2. Standard IEEE Connector. A standard IEEE-488 connector is available on the rear panel of the instrument for easy connection to the IEEE bus. 3. Simple Primary Address Selection. The primary address of the Model 220 or 230 may be easily changed by using the five address switches on the rear panel of the instrument. 4. Digital I/O port. The interface also includes a digital I/O port which has separate 4-bit input and output connections. Port status may be read and controlled through commands given over the IEEE bus. 5. Programming Versatility. All Model 220/230 operation is supported by IEEE programming. In addition, numerous other IEEE commands add operating features not available from the front panel. 1.3 WARRANTY INFORMATION

This manual contains all the information necessary to connect the Model 220 or 230 to the IEEE488 bus and program the instrument from a separate bus controller. Not included in this manual is information concerning front panel operation, servicing, or maintenance of the instrument {including the interface board itself). For those aspects, refer to the Model 220 or 230 Instruction Manual. This programming manual is divided into the following sections: 1. Section 2 contains a general description of the IEEE-488 bus and its commands. 2. information necessary to connect the instrument to the bus and set the primary address is contained in Section 3. Also, digital I/O port information can be found in this section. 3. The bulk of the programming information may be found in Section 4. General bus commands as well as commands unique to the Models 220 and 230 are covered in detail. 4. Section 5 contains IEEE command flow charts, which could be helpful in some applications. 1.7 IEEE SPECIFICATIONS

Warranty information may be found inside the front cover of this manual. Should it become necessary to exercise the warranty, contact your nearest Keithley representative or the factory to determine the proper course of action. Keithley Instruments, Inc. maintains service facilities in the United States, United Kingdom, and throughout Europe. Addresses for these facilities may be found inside the front cover of this manual. Information concerning the application, operation, or service of your instrument may be directed to the applications engineer at any of these locations. 1.4 MANUAL ADDENDA

Information concerning improvements or changes to the instrument which occur after the printing of this manual

A complete list of IEEE specifications is presented immediately preceding this section.

l-1/1-2

SECTION 2 AN OVERVIEW OF THE IEEE-488 BUS
2.1 INTRODUCTDON The IEEE-488 bus is an instrumentation data bus adopted by the IEEE WWitute of Electrical and Electronic Engineers) in 1975 and given the IEEE488 designation. The most recent revision of bus standards was made in 1978; hence the complete description for current bus standards is the IEEE-488-1978 designation. This section gives a brief description of the general bus structure along with an outline of bus commands. The information presented here is not intended to be an in-depth description of what is truly a very complex set of standards. More complete information on the IEEE-488 bus, which is also frequently referred to as the GPIB (General Purpose Interface Bus), is available from the IEEE and a variety of other sources. 2.2 BUS DESCRIPTION The IEEE-488 bus was designed as a parallel data transfer medium to optimize data transfer without using an excessive number of bus lines. In keeping with this goal, the bus has only eight data lines that are used for both data and some commands. Five bus management lines and three handshake lines round out the complement of signal lines. Since the bus is of parallel design, all devices connected to the bus have the same information available simultaneously. Exactly what is done with the information by each device depends on many factors, including device capabilities. A typical bus configuration for controlled operation is shown in Figure 2-1. The typical system will have one controller and one or more instruments to which commands are given and, in most cases, from which data is received. Generally, there are three categories that describe device operation. These designations include: controller; talker: listener. The controller does what its name implies: it controls other devices on the bus. A talker sends data, while a listener receives data. Depending on the instrument, a particular device may be a talker only, a listener only, or both a talker and a listener. Any given system can have only one controller (control may be passed to an appropriate device through a special command), but any number of talkers or listeners may be present up to the hardware constraints of the bus. Generally, the bus is limited to 15 devices, but this number may be reduced if higher than normal data transfer rates are required or if longer than normal cables are used. Several devices may be commanded to listen at once, but only one device may be a talker at any given time. Otherwise, communications would be scrambled much like an individual's trying to pick out a single conversation out of a large crowd. Before a device can talk or listen, it must be appropriately addressed. Devices are selected on the basis of their primary address; the addressed device is sent a talk or listen command derived from its primary address. Normally, each device on the bus has a unique primary address so that each may be addressed individually. Once the device is addressed to talk or listen, appropriate bus transactions are set to take place. For example, if an instrument is addressed to talk, it will usually place its data on the bus one byte at a time. The listening device will then read this information, and the appropriate software can then be used to channel the information to the desired location. 2.3 IEEE-488 BUS LINES The signal lines on the IEEE-488 bus are grouped into three general categories. The data lines handle bus information, while the handshake and bus management lines ensure that proper data transfer and bus operation takes place. Each of the bus lines is active low so that approximately zero volts is a logic one. The following paragraphs describe the purpose of these lines, which are shown in Figure 2-l. 2.3.1 Bus Management Lines

The bus management group is made up of five signal-lines that help ensure an orderly transfer of data. These lines are used to send the uniline commands described in paragraph 2.4. 1. ATN (Attention)-The ATN line is one of the more important management lines. The state of the ATN line determines whether controller information on the data bus is to be considered data or a multiline command as described in paragraph 2.4. 2. IFC (Interface Clear)-Setting the IFC line true (low) causes the bus to go to a known state by sending the IFC command. 3. REN (Remote Enable)-Setting the REN line low sends the REN command. This sets up instruments on the bus for remote operation. 4. EOI (End Or Identify)-The EOI line is used to send the EOI command that usually terminates a multi-byte transfer sequence. 5. SRQ (Service Request)-The SRQ line is set low by a device when it requires service from the controller.

2-1

TO OTHER DEVICES

I
l

TALK.LISTEN. AN0 dt5NTR0~ (COMPUTER)

E
DATA BUS )

4

DEVICE 2 ABLE TO TALK AND

The complete handshake sequence for one data byte is shown in Figure 2-2. Once data is on the bus, the source checks to see that NRFD is high, indicating that all devices on the bus are ready for data. At the same time NDAC should be low from the previous byte transfer. If these conditions are not met, the source must then wait until the NRFD and NDAC lines have the correct status. If the source is a controller, NRFD and NDAC must remain stable for at least 100ns after ATN is set low. Because of the possibility of bus hang up, some controllers have time-out routines to display error messages if the handshake sequence stops for any reason. Once the NRFD and NDAC lines are properly set, the source sets the DAV line low, indicating that data on the bus is now valid. The NRFD line then goes low; the NDAC line goes high once all devices on the bus have accepted the data. Each device will release the NDAC line at its own rate, but the NDAC line will not go high until the slowest device has accepted the data byte. After the NDAC line goes high, the source then sets the DAV line high to indicate that the data on the bus is no longer valid. At this point, the NDAC line returns to its low state. Finally, the NFRD line is released by each of the devices at their own rates, until the NFRD line finally goes high when the slowest device is ready, and the bus is set to repeat the sequence with the next data byte. The sequence just described is used to transfer both data and multiline commands. The state of the ATN line determines whether the data bus contains data or commands as described in paragraph 2.4. 2.3.3 Data Lines

lllll E DATA BYTE TRANSFER CONTROL --

I

DEVICE 3

GENERAL INTERFACE MANAGEMENT

DEVICE 4 ONLY AELti TO TALK

I

1 I =E) EOI 1

BUS MANAGEMENT

1.220/230

Figure 2-1. IEEE Bus Configuration

The IEEE-488 bus uses the eight data lines that allow data to be transmitted and received in a bit-parallel, byte-serial manner. These eight lines use the convention DIOI through D108 instead of the more common DO through D7 binary terminology, The data lines are bidirectional and, as with the remaining bus signal lines, low is true.

2.3.2 Handshake

Lines
OAV VALID I NRFO I I I I ACCEPTOR --SOURCE

The bus uses three handshake lines that operate in an interlocked sequence. This method ensures reliable data transfer regardless of the transfer rate. Generally, data transfer will occur at a rate determined by the slowest active device on the bus. One of the handshake lines is controlled by the data source, while the remaining two lines are controlled by accepting devices. The three bus handshake lines are: 1. DAV (Data Valid)-The source controls the state of the DAV line. 2. NRFD (Not Ready For Data)-The acceptor controls the state of the NRFD line. 3. NDAC (Not Data Accepted)-The acceptor also controls the NDAC line.

NoAC

/

'

j/j

'

ACCEPTOR

I DATA TRANSFER BEGIN DATA TRANSFER END

2.210~233

Figure 2-2. IEEE Handshake

Sequence

2-2

2.4 BUS COMMANDS While the hardware aspects of bus is essential, the interface would be essentially worthless without appropriate commands to control communications between the various instruments on the bus. This section briefly describes the purpose of the bus commands, which are grouped into the following three general catagories: 1. Uniline commands: Sent by setting the associated bus line low. 2. Multiline commands: General bus commands which are sent over the data lines with the ATN line low. 3. Device-dependent commands: Special commands that depend on device configuration; sent over the data lines with ATN high. These commands are summarized in Table 2-l. 2.4.1 Uniline Commands

2. DCL (Device Clear)-After a DCL is sent, instrumentation equipped to implement the command will revert to a known state. Usually, instruments return to their powerup conditions. 3. SPE (Serial Poll Enable)-The SPE command is the first step in the serial polling sequence, which is used to determine which instrument has requested service with the SRQ command. 4. SPD (Serial Poll Disable)-The SPD command is sent by the controller to remove all instrumentation on the bus from the serial poll mode. 2.4.3 Addressed Commands

Addressed commands are multiline commands that must be preceded by a listen command derived from the device's primary address before the instrument will respond. Only the addressed device will respond to each of these commands: 1. SDC (Selective Device Clear)-The SDC command performs essentially the same function as the DCL command except that only the addressed device will respond. Instruments usually return to their default conditions when the SDC command is sent. 2. GTL(Go To Local)-The GTL command is used to remove instruments from the remote mode of operation. Also, front panel control operation will usually be restored if the LLO command was previously sent. 3. GET (Group Execute Trigger)-The GET command is used to trigger devices to perform a specific action that depends on device configuration. Although GET is considered to be an addressed command, many devices respond to GET without being addressed. 2.4.4 Unaddressed Commands

Uniline commands are sent by setting the associated bus line low. The ATN, IFC, and REN commands are asserted only by the system controller. The SRQ command is sent by an external device. The EOI command may be sent by either the controller or an'external device depending on the direction of data transfer. The following is a brief description of each command. 1. REN (Remote Enable)-When the controller sends the REN command,the instrument will be set up for remote operation. Generally, the REN command should be sent before attempting to program instruments over the bus. 2. EOI (End Or Identify)-The EOI command is used to positively identify the last byte in a multi-byte transfer sequence. This allows variable length data words to be transmitted easily. 3. IFC (Interface Clear)-The IFC command is sent to clear the bus and set devices to a known state. Although device configurations differ, the IFC command usually places instruments in the talk and listen idle states. 4. ATN (Attention)-The controller sends ATN while transmitting addresses or multiline commands. Devicedependent commands are sent with the ATN line high (false). 5. SRQ (Service Request)-The SRQ command is asserted by an external device when it requires service from the controller. If more than one device is present, a serial polling sequence, as described in Section 4, must be used to determine which device has requested service. 2.4.2 Universal Commands

The two unaddressed commands are used by the controller to remove all talkers and listeners from the bus simultaneously. ATN is low when these multiline commands are asserted. 1. UNL (Unlistenj-All listeners are removed from the bus at once when the UNL command is placed on the bus. 2. UNT (Untalkj-The controller sends the UNT command to clear the bus of any talkers. 2.4.5 Device-Dependent Commands

Universal commands are multiline commands that require no addressing. All instrumentation equipped to implement the command will do so simultaneously when the command is transmitted over the bus. As with all multiline commands, the universal commands are sent over the data lines with ATN low. 1. LLO (Local Lockout)-The LLO command is used to lock out front panel controls on devices so equipped.

The meaning of the device-dependent commands is determined by instrument configuration. Generally, these commands are sent as one or more ASCII characters that tell the device to perform a specific function. For example, FO is sent to the Model 220 or 230 to place the instrument in the standby mode. For complete information on using these commands with the Model 220 or 230, refer to Section 4. The IEEE-488 bus treats device-dependent commands as data in that ATN is high (false) when the commands are transmitted.

2-3

Table 2-1. IEEE488 Command Tvoe Jniline 1 Command REN (Remote Enable) EOI IFC (Interface Clear) ATN (Attention) SRQ (Service Request) LLO (Local Lockout) DCL (Device Clear) SPE' (Serial Poll Enable) SPD (Serial Poll Disable) SDC (Selective Device Clear) GTL (Go to Local) GET (Group Execute TriggerIt UNL KInlisten) UNT (Untalk) I
I -.

Bus Command

Summary Comments Set up for remote operation. Sent by setting EOI low. Clears Interface Defines data bus contents. Controlled bv external device. /Locks out front panel controls. `Returns device to default conditions. Enables serial polling. Disables serial polling. Returns unit to default conditions. Returns to local control. Triggers device. Removes all listeners from bus. Removes any talkers from bus. Programs Model 220 or 230 for various modes.

1 State of ATN Line X X X Low X

Aultiline Universal

Addressed

Unaddress

C Device-dependent** 1
_

`t Some devices respond to GET without addressing. *X = Don't Care **See Section 4 for complete description. 2.5 COMMAND CODES tant, as shown by the "Don't Care" indication in the table. Some devices, however, may require that 07 assumes a specific logic state before the commands are recognized. Hexadecimal and decimal values for each of the commands or command groups are listed in Table 2-2. Each value in the table assumes that D7 is set to 0. Table 2-2. Hexadecimal Command GTL SDC GET LLO DCL SPE SPD LAG TAG UNL UNT and Decimal Hex Value* 01 04 08 11 14 18 19 20-3F 40-5F 3F 5F Command Decimal Codes Value

Each multiline command is given a unique code that is transmitted over the bus as 7-bit ASCII data. This section briefly explains the code groups which are summarized in Figure 2-3. Every command is sent with ATN low. 1. Addressed Command Group (ACGI-Addressed commands are listed in column ,0(B) in Figure 2-3. Column O(A) lists the corresponding ASCII codes. 2. Universal Command Group WCGI-Columns l(A) and 1(BI list the Universal commands and the corresponding ASCII codes. 3. Listen Address Group (LAGKolumns 2(A) and 3(A) list the ASCII codes corresponding to the primary addresses listed in columns 2(B) and 3(B). For example, if the primary address of the instrument is set to 12, the LAG byte will correspond to an ASCII comma. 4. Talk Address Group (TAG)-TAG primary address values and the corresponding ASCII characters are listed in columns 4(A) through 5(B). The preceding address groups are combined together to form the Primary Command Group (PCG). The bus also has another group of commands, called the Secondary Command Group (SCG). These are listed in Figure 2-3 for informational purposes only; the Models 220 and 230 do not respond to these commands, but other devices may have secondary addressing capability. NOTE Commands are normally transmitted with the 7-bit code listed in Figure 2-3. For most devices, the condition of 07 (Dl08) is unimpor-

1 4 8 17 20 24 25 32-63 64-95 63 95

*Values shown with D, = 0. 2.6 COMMAND SEQUENCES The proper command sequence must be sent by the controller before an instrument will respond as intended. The universal commands, such as LLO and DCL, require only that ATN be set low before the command is sent. Other commands require that the device be addressed to listen first. This section briefly describes the bus sequence for several types of commands.

24

a" k

2-5

2.6.1 Addressed

Command

Sequence

Note that both the ATN and LLO commands are on the bus simultaneously. Also, addressing is not necessary. 2.6.3 Device-Dependent Command Sequence

Before a device will respond to one of these commands, it must receive a LAG command derived from its primary address. Table 2-3 shows a typical sequence for the SDC command. The LAG command assumes that the instrument is set at a primary address of 12. Note that an UNL command is transmitted before the LAG, SDC sequence. This is generally done to remove all other listeners from the bus first so that only the addressed device responds. 2.6.2 Universal Command Sequence

Device-dependent commands are transmitted with ATN high. However, the device must be addressed to listen first before the commands are transmitted. Table 24 shows the sequence for the following command: FOX This command, which sets the Model 220 or 230 to the standby mode, is described in detail in Section 4.

The universal commands are sent by setting ATN low and then placing the command byte on the bus. For example, the following gives the LLO command: ATN*LLO

Table 2-3. Typical Step 1 2 3 4 Command UNL LAG" SDC

Addressed ATN State

Command

Sequence

Data Bus ASCII Hex ? EbT 3F 2c 04

Decimal 63 44 4

set low stays low stays low Returns high

*Assumes primary address= 12.

Table 24. Typical 1 Step 1 Command

Device-Dependent 1 ATN State

Command

Sequence

Data Bus ASCII Hex

11 1g pi&w;
*Assumes primary address= 12.

r

Decimal 63 44 70 48 88

2-6

SECTION 3 SYSTEM CONFIGURATION
3.1 INTRODUCTION There are two operating aspects to almost any digital interface. The IEEE488 standard is no exception to this rule. Not only must the hardware meet certain standards, but all devices, including the controller, must have appropriate software. This section deals with important hardware and software aspects of bus operation. Also included is information pertaining to the Model 220/230 digital I/O port. 3.2 HARDWARE CONSIDERATIONS The Model 220 or 230 is connected to the bus through an IEEE488 connector which is shown in Figure 3-2. This connector is designed to be stacked to allow a number of parallel connections on one instrument. f 3.2.1 Typical Systems The IEEE488 bus is a parallel interface system. As a result, adding more devices is simply a matter of using more cables to make the desired connections. Because of this flexibility, system complexity can range from the very simple to extremely complex. Figure 3-l shows two typical system configurations. Figure 3-l(a) shows the simplest possible controlled system. The controller is used to send commands to the instrument, which sends data back to the controller. \ The system becomes more complex in Figure 3-l(b), where additional instrumentation is added. Depending on programming, all data may be routed through the controller, or it may be transmitted directly from one instrument to another. For very complex applications, a much larger computer can be used. Tape drives or disks can then be used to store data. 3.2.2 Bus Connections Before the Model 220 or 230 can be used .with the IEEE488 bus, the instrument must be connected to the bus with a suitable connector. Also, the primary address must be properly selected as described in this section.

S-220/230

220 OR 230

CONTROLLER

Figure 3-2. IEEE488 NOTE

Connector

(Al SIMPLE

SYSTEM

CONTROLLER

To avoid possible mechanical damage, it is recommended that no more than three connectors be stacked on any one instrument. Otherwise, the resulting strain may cause internal damage. A typical connecting scheme for the bus is shown in Figure 3-3. Each cable normally has the standard IEEE connector on each end. The Keithley Model 7008 cable, which is six feet in length, is ideal for this purpose. Once the connections are made, the screws should be tightened securely. For the location of the connector on the rear panel of the Model 220 or 230, refer to Figure 34.

(El ADDITIONAL

INSTRUMENTATION 4-220/230

Figure 3-l. System Types

3-1

Instrument

Instrument

Table 3-1. IEEE Contact Designations Contact Number 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
l

IEEE-488 Designation DlOl D102 D103 0104 EOI (24)* DAV NRFD NDAC IFC SRQ ATN SHIELD** Dl05 D106 D107 D108 REN (24)* Gnd, (6)* Gnd, (7)* Gnd, (8)* Gnd, (9)* Gnd, (lo)* Gnd, (1 l)* Gnd, LOGIC

Type Data Data Data Data Management Handshake Handshake Handshake Management Management Management Ground Data Data Data Data Management Ground Ground Ground Ground Ground Ground Ground

Figure 3-3. IEEE-488 Connections

1
A2 A4 Al A3 a

01

DIGITAL

l/O

Figure 3-4. Rear Panel of Model 220 or 230 Showing IEEE Connectors and Switches NOTE The IEEE-488 bus is limited to a maximum of 15 devices, including the controller. Also, the maximum cable length is 20 meters. Failure to observe these limits will probably result in erratic bus operation. Custom cables may be constructed using the information in Table 3-l and Figure 3-5. Table 3-l lists the contact assignments for the various bus lines, while Figure 3-5 shows contact designations. Contacts 18 through 24 are return lines for the indicated signal lines, and the cable shield is connected to contact 12. Each ground line is connected to digital common in the Model 220 or 230, but contact 12 within the instrument is left unconnected to avoid ground loops. NOTE The connector supplied with the HewlettPackard 85 HP-B interface will require the use of the Keithley Model 7010 IEEE cable adapter. The HP-B cable connector has an unusually large shoulder that prevents the cable connector from seating properly on the IEEE connector on the rear panel of the Model 220 or 230. Connectors on other cables, including those on the Keithley Model 7008, should seat properly without this adapter.

Numbers in parentheses refer to signal ground return of referenced contact number. EOI and REN signal lines return on contact 24.

** The cable shield is normally connected to contact 12. This shield should be connected to ground only at the controller end to avoid ground loop p