background image

Appendix A

Operation of the GPIB

© National Instruments Corporation

A-7

GPIB-LPT User Manual

Configuration Restrictions

To achieve the high data transfer rate that the GPIB is designed for, the physical distance between
devices and the number of devices on the bus is limited.

The following restrictions are typical:

A maximum separation of 4 m between any two devices and an average separation of less than
2 m over the entire bus.

A maximum total cable length of 20 m.

No more than 15 devices connected to each bus, with at least two-thirds powered-on.

Содержание 180742-01

Страница 1: ... Copyright 1989 1990 National Instruments Corporation All Rights Reserved GPIB LPT User Manual October 1989 Edition Part Number 320161 01 ...

Страница 2: ...National Instruments Corporation 6504 Bridge Point Parkway Austin TX 78730 5039 512 794 0100 800 IEEE 488 Fax 512 794 8411 ...

Страница 3: ...for repair must be clearly marked on the outside of the package with an RMA number Defects caused by misuse abuse or shipment are not covered The GPIB LPT Diagnostic Package software program is provided as is without warranty of any kind either expressed or implied No other warranty is expressed or implied NI shall not be liable or responsible for any kind of damages including special indirect or ...

Страница 4: ...stallation However the chances of interference are much less if the equipment is used according to this instruction manual If the equipment does cause interference to radio or television reception which can be determined by turning the equipment on and off one or more of the following suggestions may reduce or eliminate the problem Operate the equipment and the receiver on different branches of yo...

Страница 5: ...n Four Running Diagnostic Tests describes how to run the diagnostic tests that are shipped with the GPIB LPT Section Five Programming the GPIB LPT contains specific information about the GPIB LPT registers along with software examples Appendix A Operation of the GPIB describes GPIB terminology and protocol for users unfamiliar with the GPIB Appendix B Multiline Interface Messages contains an ASCII...

Страница 6: ...poration Related Documents The following documents are references that cover in greater detail specific topics introduced in this manual ANSI IEEE Standard 488 1978 IEEE Standard Digital Interface for Programmable Instrumentation IBM Options Adapters Manual ...

Страница 7: ...d Control Latches 3 2 Data Transceivers 3 2 Data Wrap Control Wrap and Status Buffers 3 2 External Device Listen Address Switch 3 2 GPIB Handshaking 3 3 GPIB Addressing 3 3 Section Four Running Diagnostic Tests 4 1 The GPIB LPT Test Commands 4 1 1 printer test 4 1 2 plotter test 4 2 c change LPT configuration 4 3 q quit 4 3 Section Five Programming the GPIB LPT 5 1 The GPIB LPT Registers 5 1 Data ...

Страница 8: ...Listeners and Controllers A 1 System Controller and Active Controller A 2 GPIB Signals A 2 Data Lines A 3 Handshake Lines A 3 NRFD not ready for data A 3 NDAC not data accepted A 3 DAV data valid A 3 Interface Management Lines A 4 ATN attention A 4 IFC interface clear A 4 REN remote enable A 4 SRQ service request A 4 EOI end or identify A 4 Physical and Electrical Characteristics A 5 Configuration...

Страница 9: ... SRQ ON and Address 5 2 5 Figure 2 4 Setting for Address 6 hex 2 6 Figure 2 5 Switch Setting for REN ON IFC ON and SRQ OFF 2 7 Figure 3 1 GPIB LPT Block Diagram 3 1 Figure 4 1 Plotter Output 4 2 Figure A 1 GPIB Cable Connector A 3 Figure A 2 Linear Configuration of GPIB Devices A 5 Figure A 3 Star Configuration of GPIB Devices A 6 Tables Table 2 1 IBM PC Parallel Port Adapters 2 2 Table 2 2 Factor...

Страница 10: ... printer and plotter output Features The GPIB LPT has the following hardware features emulates the standard PC parallel printer interface so that no additional software is needed can be configured as either LPT1 PRN LPT2 or LPT3 compatible with any software using the parallel ports on the IBM PC compatibles small dimensions so that it fits into any slot of a personal computer transparent addressin...

Страница 11: ...Corporation Figure 1 1 shows the GPIB LPT interface board Figure 1 1 GPIB LPT Board The GPIB LPT works in most true IBM compatible computers It does not work in the TI Professional Computer because it uses a different Basic Input Output System BIOS than the IBM compatibles ...

Страница 12: ...c test that is described in Section Four Running Diagnostic Tests Make sure each of these items is in your kit If any item is missing contact National Instruments Optional Equipment Item Part Number Double Shielded Cables GPIB Type X2 Cable 1 m 763061 01 GPIB Type X2 Cable 2 m 763061 02 GPIB Type X2 Cable 4 m 763061 03 In order to meet FCC emission limits for a Class B device you must use a double...

Страница 13: ...struments Corporation 2 1 GPIB LPT User Manual Section Two Configuration and Installation Figure 2 1 shows the locations of the GPIB LPT configuration jumpers and switches Figure 2 1 GPIB LPT Parts Locator Diagram ...

Страница 14: ...then 278 LPT3 If only one device is installed that device is named LPT1 regardless of what its I O address is If there is more than one parallel device installed the first one found is assigned LPT1 the second one found is assigned LPT2 and so on The GPIB LPT may need to be reconfigured if its interrupt level conflicts with another device If the base I O address of the GPIB LPT does not conflict w...

Страница 15: ...rations GPIB LPT Default Optional Base I O Address 278 27C 3BC and 378 37C Interrupt Level 5 7 If you need to change the factory settings continue on If you do not need to change the factory settings skip to Installation later in this section Base I O Address and Interrupt Selection The base I O address and interrupt line used by the GPIB LPT are determined by the jumpers located at positions W1 a...

Страница 16: ...onochrome Adapter W2 I5 P2 I7 P1 W1 PA MA a Jumpers Set to Base I O Address 3BC hex and Interrupt Level 7 Monochrome Display and Printer Adapter W2 I5 P2 I7 P1 W1 PA MA b Jumpers Set to Base I O Address 378 37C hex and Interrupt Level 7 Parallel Port 1 W2 I5 P2 I7 P1 W1 PA MA c Jumpers Set to Default Setting Base I O Address 278 27C hex and Interrupt Level 5 Parallel Port 2 Figure 2 2 Possible Set...

Страница 17: ...ON position enables REN The OFF position disables REN IFC Enables disables the Interface Clear IFC option on the GPIB LPT If enabled the GPIB LPT issues an IFC when it is initialized The ON position enables IFC on initialization The OFF position holds IFC unasserted SRQ Enables disables the Service Request SRQ option If enabled the GPIB LPT monitors the SRQ line through the Paper Error PE bit in t...

Страница 18: ...device with address 6 hex The address varies with each device so check the address of your device and set these lower five bits O F F O N This side down for logic 0 This side down for logic 1 REN IFC SRQ 1 2 4 8 16 U18 Key side you must press down for Listen Address 6 Off 1 On 0 used for setting REN IFC and SRQ Options Figure 2 4 Setting for Address 6 hex ...

Страница 19: ... for logic 0 This side down for logic 1 REN IFC SRQ 1 2 4 8 16 U18 Key side you must press down for REN ON IFC ON used for setting Listen Address and SRQ OFF Off 1 On 0 Figure 2 5 Switch Setting for REN ON IFC ON and SRQ OFF In the space provided here record the new settings for your GPIB LPT so that you will have them handy for future reference GPIB LPT New Setting Base I O Address Interrupt Leve...

Страница 20: ...r for specific instructions and warnings 1 Turn off your computer 2 Remove the plug from its power source 3 Remove the top cover or access port to the I O channel 4 Remove the expansion slot cover on the back panel of your computer 5 Insert the GPIB LPT in an unused slot with the IEEE 488 receptacle sticking out of the opening of the back panel It may be a tight fit but do not force the board into...

Страница 21: ...shows a block diagram of the GPIB LPT PC I O Channel Address Decoding Config Jumpers Data Bus Address Bus Data Wrap Buffers Data Latch Control Latch GPIB GPIB Handshaking GPIB Addressing External Device Listen Address Switches Control Buffers Wrap Status Data Transceivers Figure 3 1 GPIB LPT Block Diagram ...

Страница 22: ...and control latches emulate the data and control registers of the standard IBM PC parallel port adapter Writing to these latches controls output to the printer plotter Data Transceivers Data transceivers interface the GPIB LPT local data bus to the IBM PC data bus Data Wrap Control Wrap and Status Buffers Data wrap control wrap and status buffers and the data and control latches make the GPIB LPT ...

Страница 23: ...aking converts PC parallel port handshaking into GPIB handshaking protocol This process is transparent to you GPIB Addressing On printer plotter initialization the GPIB LPT checks to see if the printer plotter is listening if not the GPIB LPT addresses it as a listener using the GPIB listen address on the onboard switches ...

Страница 24: ...S GPIB LPT DIAGNOSTIC TESTS This program assumes the GPIB LPT is configured at base address 278 Parallel adapter 2 If you reconfigured your GPIB LPT you must change the address that this program uses To do this enter command c from the menu Enter one of the following commands 1 printer test 2 plotter test c change LPT configuration q quit A short explanation of each command is given in the followi...

Страница 25: ...KLMNOPQRSTUVWXYZ _ abcdefghi jklmnopqrstuvwxyz 0123456789 ABCDEFG HIJKLMNOPQRSTUVWXYZ _ abcdefghijklmnopqrstuvwxyz If the printer does not respond an error message appears on the screen along with a message telling you to recheck all of your connections and jumper settings If the test still fails after everything has been checked write down the error message if any and call National Instruments 2 ...

Страница 26: ... configuration This command is used to change the base address of the GPIB LPT to match the actual board settings If you have changed the jumper settings to something different than the default settings you must run this command When this command is selected the following menu appears This program assumes the GPIB LPT is configured at base address 278 Parallel adapter 2 Enter the number of the cor...

Страница 27: ...LPT This section presents specific information about the GPIB LPT Parallel Port Emulator registers along with software examples The GPIB LPT Registers The GPIB LPT has three onboard registers that are required for parallel port adapters The DATA register the STAT register and the CTRL register ...

Страница 28: ...ress Base I O Address 0 hex Attributes Read Write 7 6 5 4 3 2 1 0 D6 D5 D7 D4 D3 D2 D1 D0 R W Writing to this address causes data to be latched in the GPIB LPT DATA register Reading this address sends the contents of the DATA register to the system microprocessor Bit Mnemonic Description 7 0r w D 7 0 Data Bits 7 through 0 ...

Страница 29: ...iggered when the Not Data Accepted NDAC GPIB handshake line is unasserted by the external GPIB device 5r PE Paper Error Bit This bit indicates to the parallel port adapter that a paper error has occurred a logical 1 means end of paper has been detected The GPIB LPT can be configured to use this bit to monitor the current state of the GPIB SRQ line If the GPIB LPT switch is set to enable the Servic...

Страница 30: ...s Corporation Bit Mnemonic Description 3r ERROR Error Bit This bit indicates Paper End state Off line state and Error state a logical 0 indicates one of these states This bit is not used by the GPIB LPT and is held logical 1 2 0r X Don t Care Bits 2 through 0 Can be read as a 0 or 1 ...

Страница 31: ...nges from active to inactive 3w SLCTIN Select In Bit When this bit is set the GPIB LPT can source data onto the GPIB data lines 2w INIT Initialize Bit Setting and then clearing this bit initializes the GPIB LPT 1w AUTOFD Automatic Linefeed Bit When this bit is set to one a linefeed is automatically set after each line is sent to the printer This bit is not used by the GPIB LPT because there is no ...

Страница 32: ...rating System The following DOS command sends the file example txt to the GPIB device connected to the GPIB LPT type example txt lpt2 Note You press your RETURN or ENTER key to execute these commands Similarly the following DOS command sends the string Hello world along with a carriage return 0Dh followed by a line feed 0Ah to the GPIB device connected to the GPIB LPT echo Hello world lpt2 The DOS...

Страница 33: ... adapter in the system LPT1 these will only send data to the GPIB device if the GPIB LPT is LPT1 Writing a GPIB LPT Driver When you use an IBM BIOS driver it performs the following steps to send a character out to the parallel port 1 Writes the character to the DATA Register 2 Waits for the signal BUSY to equal 1 if the timeout period expires exits the routine If the timeout period does not expire...

Страница 34: ...tine The interrupt handler routine is called every time an ACK pulse interrupt is seen by the processor It disables the GPIB LPT interrupt calls the PRINT subroutine and re arms the 8259A Interrupt Controller chip You must complete the following steps for the interrupt handler routine a Set the bit IRQEN equal 0 b Call the PRINT routine the steps of the PRINT routine follow this routine c Write th...

Страница 35: ...s The only constraint for the GPIB LPT is the length of the STROBE pulse The following sequence guarantees a pulse width between 1 and 5 µsec mov al 0Dh STROBE mask mov dx CTRL dx points to the CTRL register cli disable interrupts to prevent stretching of the pulse out dx al set STROBE 1 jmp 2 delay to meet timing jmp 2 requirement mov al 0Ch normal mask out dx al set STROBE 0 sti interrupts back ...

Страница 36: ...ssing and unaddressing devices and setting devices for remote or local programming Note The term command as used here should not be confused with some device instructions which are also called commands Such device specific instructions are actually data messages Talkers Listeners and Controllers There are three types of GPIB communicators A Talker sends data messages to one or more Listeners The C...

Страница 37: ...the active or addressed Talker or Listener must be changed The Controller function is usually handled by a computer System Controller and Active Controller Although there can be multiple Controllers on the GPIB only one Controller at a time is Active Controller or Controller in Charge CIC Active control can be passed from the current Active Controller to an idle Controller Only one device on the b...

Страница 38: ... and most data use the 7 bit ASCII or ISO code set in which case the eighth bit DIO8 is unused or used for parity Handshake Lines Three lines asynchronously control the transfer of message bytes among devices The process is called a three wire interlocked handshake and it guarantees that message bytes on the data lines are sent and received without transmission error NRFD not ready for data NRFD i...

Страница 39: ...tion across the interface ATN attention The Controller drives ATN true when it uses the data lines to send commands and false when it allows a Talker to send data messages IFC interface clear The System Controller drives the IFC line to initialize the bus to become Controller In Charge REN remote enable The System Controller drives the REN line which is used to place devices in remote or local pro...

Страница 40: ...ics Devices are usually connected with a cable assembly consisting of a shielded 24 conductor cable with both a plug and receptacle at each end This design allows devices to be connected in either a linear or a star configuration or a combination of the two See Figures A 2 and A 3 Figure A 2 Linear Configuration of GPIB Devices ...

Страница 41: ...d connector is the Amphenol or Cinch Series 57 MICRORIBBON or AMP CHAMP type An adapter cable using non standard cable and or connector is used for special interconnect applications The GPIB uses negative logic with standard TTL logic levels When DAV is true for example it is a TTL low level 0 8 V and when DAV is false it is a TTL high level 2 0 V ...

Страница 42: ...s designed for the physical distance between devices and the number of devices on the bus is limited The following restrictions are typical A maximum separation of 4 m between any two devices and an average separation of less than 2 m over the entire bus A maximum total cable length of 20 m No more than 15 devices connected to each bus with at least two thirds powered on ...

Страница 43: ... National Instruments Corporation B 1 GPIB LPT User Manual Appendix B Multiline Interface Messages The following tables are multiline interface messages sent and received with ATN TRUE ...

Страница 44: ...F 017 15 SI 2F 057 47 MLA15 10 020 16 DLE 30 060 48 0 MLA16 11 021 17 DC1 LLO 31 061 49 1 MLA17 12 022 18 DC2 32 062 50 2 MLA18 13 023 19 DC3 33 063 51 3 MLA19 14 024 20 DC4 DCL 34 064 52 4 MLA20 15 025 21 NAK PPU 35 065 53 5 MLA21 16 026 22 SYN 36 066 54 6 MLA22 17 027 23 ETB 37 067 55 7 MLA23 18 030 24 CAN SPE 38 070 56 8 MLA24 19 031 25 EM SPD 39 071 57 9 MLA25 1A 032 26 SUB 3A 072 58 MLA26 1B ...

Страница 45: ...MTA13 6D 155 109 m MSA13 PPE 4E 116 78 N MTA14 6E 156 110 n MSA14 PPE 4F 117 79 O MTA15 6F 157 111 o MSA15 PPE 50 120 80 P MTA16 70 160 112 p MSA16 PPD 51 121 81 Q MTA17 71 161 113 q MSA17 PPD 52 122 82 R MTA18 72 162 114 r MSA18 PPD 53 123 83 S MTA19 73 163 115 s MSA19 PPD 54 124 84 T MTA20 74 164 116 t MSA20 PPD 55 125 85 U MTA21 75 165 117 u MSA21 PPD 56 126 86 V MTA22 76 166 118 v MSA22 PPD 57...

Страница 46: ... GPIB LPT board Power Requirement 5 VDC 5 0 40 A typical Physical Dimensions 4 2 in x 5 5 in I O Connector IEEE 488 Standard 24 pin Operation Environment Component Temperature 0 to 70 C Relative humidity 5 to 90 noncondensing Emissions FCC Class B Storage Environment Temperature 55 to 125 C Relative humidity 5 to 90 noncondensing ...

Страница 47: ... User Manual Edition Date October 1989 Part Number 320161 01 Please comment on the completeness clarity and organization of the manual If you find errors in the manual please record the page numbers and describe the errors Thank you for your help Name Title Company Address Phone Mail to Technical Publications National Instruments Corporation 6504 Bridge Point Parkway MS 53 02 Austin TX 78730 5039 ...

Отзывы: