Page 5 - Contents; About This Manual
© National Instruments Corporation v Lab-NB User Manual Contents About This Manual ............................................................................................................ xi Organization of This Manual ................................................................................
Page 6 - of
Contents Lab-NB User Manual vi © National Instruments Corporation Chapter 3Theory of Operation ........................................................................................................... 3-1 Functional Overview.............................................................................
Page 8 - Glossary
Contents Lab-NB User Manual viii © National Instruments Corporation Chapter 5Calibration ............................................................................................................................. 5-1 Calibration Equipment Requirements .................................................
Page 9 - Figures
Contents © National Instruments Corporation ix Lab-NB User Manual Figures Figure 1-1. The Relationship between the Programming Environment, NI-DAQ, and Your Hardware ............................................................................................................ 1-3 Figure 2-1. Parts Loc...
Page 10 - Control
Contents Lab-NB User Manual x © National Instruments Corporation Table 4-4. Bipolar Input Mode A/D Conversion Values (Two’s Complement Coding) .... 4-38Table 4-5. Analog Output Voltage Versus Digital Code .................................................... 4-53Table 4-6. Analog Output Voltage Versu...
Page 11 - Organization of This Manual; The Lab-NB User Manual is organized as follows.
© National Instruments Corporation xi Lab-NB User Manual About This Manual This manual describes the mechanical and electrical aspects of the Lab-NB and containsinformation concerning its installation and operation. The Lab-NB is a low-cost multifunctionanalog, digital, and timing I/O board for Maci...
Page 12 - Conventions Used in This Manual; The following conventions are used in this manual.; bold; bold italic; National Instruments Documentation
About This Manual Lab-NB User Manual xii © National Instruments Corporations • The Glossary contains an alphabetical list and description of terms used in this manual,including abbreviations, acronyms, metric prefixes, mnemonics, symbols, and terms. • The Index alphabetically lists topics covered in...
Page 13 - Related Documentation; Inside Macintosh–Volume 5; Customer Communication
About This Manual © National Instruments Corporation xiii Lab-NB User Manual • Your DAQ hardware user manuals—These manuals have detailed information about theDAQ hardware that plugs into or is connected to your computer. Use these manuals forhardware installation and configuration instructions, spe...
Page 14 - Detailed Lab-NB specifications are in Appendix A, Specifications.
© National Instruments Corporation 1-1 Lab-NB User Manual Chapter 1Introduction This chapter describes the Lab-NB, lists what you need to get started, software programmingchoices, optional equipment, and explains how to unpack the Lab-NB. About the Lab-NB Thank you for buying the National Instrument...
Page 15 - What You Need to Get Started; To set up and use your Lab-NB board, you will need the following:; Software Programming Choices; LabVIEW and LabWindows/CVI Application Software
Introduction Chapter 1 Lab-NB User Manual 1-2 © National Instruments Corporation What You Need to Get Started To set up and use your Lab-NB board, you will need the following: Lab-NB board Lab-NB User Manual One of the following software packages and documentation: NI-DAQ software for MacintoshLabVI...
Page 16 - NI-DAQ Driver Software; Figure 1-1. The Relationship between the Programming Environment,
Chapter 1 Introduction © National Instruments Corporation 1-3 Lab-NB User Manual NI-DAQ Driver Software The NI-DAQ driver software is included at no charge with all National Instruments DAQhardware. NI-DAQ is not packaged with SCXI or accessory products, except for the SCXI-1200.NI-DAQ has an extens...
Page 17 - Register-Level Programming; Optional Equipment; Cables and cable assemblies, shielded and ribbon; Cabling
Introduction Chapter 1 Lab-NB User Manual 1-4 © National Instruments Corporation Register-Level Programming The final option for programming any National Instruments DAQ hardware is to write register-level software. Writing register-level programming software can be very time-consuming andinefficien...
Page 18 - Unpacking; Never touch the exposed pins of connectors.
Chapter 1 Introduction © National Instruments Corporation 1-5 Lab-NB User Manual The Lab-NB I/O connector is a 50-pin male ribbon cable header. The manufacturer partnumbers used by National Instruments for this header are as follows: • Electronic Products Division/3M (part number 3596-5002) • T&...
Page 19 - Board Configuration
© National Instruments Corporation 2-1 Lab-NB User Manual Chapter 2Configuration and Installation This chapter describes how to configure and install the Lab-NB into your Macintosh computer,and also includes signal connections to the Lab-NB and cable wiring. Board Configuration The Lab-NB contains t...
Page 21 - Factory Default Jumper Settings; Jumpers W1 and W2–bipolar analog output; Configuration; Analog Output Configuration; Bipolar Output Selection; Analog Output Channel 0
Chapter 2 Configuration and Installation © National Instruments Corporation 2-3 Lab-NB User Manual Factory Default Jumper Settings The Lab-NB is shipped from the factory with the following configuration: • Jumpers W1 and W2–bipolar analog output • Jumper W3–bipolar analog input Table 2-1 lists all t...
Page 22 - Unipolar Output Selection; Analog Input Configuration; Bipolar Input Selection
Configuration and Installation Chapter 2 Lab-NB User Manual 2-4 © National Instruments Corporation W2 A B C W1 Channel 1 Channel 0 A B C Figure 2-2. Bipolar Output Jumper Configuration Unipolar Output Selection You can select the unipolar (0 to 10 V) output configuration for either analog output cha...
Page 23 - Figure 2-4. Bipolar Input Jumper Configuration; Unipolar Input Selection; Analog Input; Installation; I/O Connector Pin Description
Chapter 2 Configuration and Installation © National Instruments Corporation 2-5 Lab-NB User Manual W3 A B C Figure 2-4. Bipolar Input Jumper Configuration Unipolar Input Selection You can select the unipolar (0 to 10 V) input configuration by setting the following jumper: Analog Input W3 B-C This co...
Page 24 - liable for any damages resulting from any such
Configuration and Installation Chapter 2 Lab-NB User Manual 2-6 © National Instruments Corporation Warning: Connections that exceed any of the maximum ratings of input or output signals on the Lab-NB may result in damage to the Lab-NB board and to the Macintoshcomputer. This includes connecting any ...
Page 25 - Signal Connection Descriptions; Analog Input Signal Connections
Chapter 2 Configuration and Installation © National Instruments Corporation 2-7 Lab-NB User Manual Signal Connection Descriptions Pin Signal Name Description 1-8 ACH<0..7> Analog input channels 0 through 7 (single-ended). 9 AIGND Analog input ground. 10 DAC0 OUT Voltage output signal for analo...
Page 26 - liable for any damages
Configuration and Installation Chapter 2 Lab-NB User Manual 2-8 © National Instruments Corporation cause conversions to occur; it cannot be used as a monitor to detect conversions caused by theonboard sample-interval timer. The following input ranges and maximum ratings apply to inputs ACH<0..7&g...
Page 27 - Analog Output Signal Connections
Chapter 2 Configuration and Installation © National Instruments Corporation 2-9 Lab-NB User Manual Analog Output Signal Connections Pins 10 through 12 of the I/O connector are analog output signal pins. Pins 10 and 12 are the DAC0 OUT and DAC1 OUT signal pins. DAC0 OUT is the voltageoutput signal fo...
Page 28 - Digital I/O Signal Connections
Configuration and Installation Chapter 2 Lab-NB User Manual 2-10 © National Instruments Corporation Digital I/O Signal Connections Pins 13 through 37 of the I/O connector are digital I/O signal pins. Digital I/O on the Lab-NB isdesigned around the 82C55A integrated circuit. The 82C55A is a general-p...
Page 29 - Port C Pin Connections
Chapter 2 Configuration and Installation © National Instruments Corporation 2-11 Lab-NB User Manual Figure 2-9 illustrates signal connections for three typical digital I/O applications. 14 PA0 22 PB0 30 PC0 13 DGND Lab-NB Board Switch I/O Connector +5 V +5 V LED TTL Signal Port B PB<7..0> Port...
Page 30 - Timing Specifications
Configuration and Installation Chapter 2 Lab-NB User Manual 2-12 © National Instruments Corporation Table 2-2. Port C Signal Assignments Programming Mode Group A Group B PC7 PC6 PC5 PC4 PC3 PC2 PC1 PC0 Mode 0 I/O I/O I/O I/O I/O I/O I/O I/O Mode 1 Input I/O I/O IBF A STB A * INTR A STB B * IBFB B IN...
Page 32 - Mode 1 Input Timing; Name; All timing values are in nanoseconds.
Configuration and Installation Chapter 2 © National Instruments Corporation 2-14 Lab-NB User Manual Mode 1 Input Timing The following figure illustrates the timing specifications for an input transfer in mode 1. DATA RD * INTR IBF STB * T1 T2 T4 T7 T6 T3 T5 Name Description Minimum Maximum T1 STB* p...
Page 33 - Mode 1 Output Timing
Chapter 2 Configuration and Installation © National Instruments Corporation 2-15 Lab-NB User Manual Mode 1 Output Timing The following figure illustrates the timing specifications for an output transfer in mode 1. WR* OBF* INTR ACK* DATA T1 T2 T3 T4 T5 T6 Name Description Minimum Maximum T1 WR* = 0 ...
Page 34 - Mode 2 Bidirectional Timing
Configuration and Installation Chapter 2 Lab-NB User Manual 2-16 © National Instruments Corporation Mode 2 Bidirectional Timing The following figure illustrates the timing specifications for bidirectional transfers in mode 2. T1 T6 T7 T3 T4 T10 T2 T5 T8 T9 WR * OBF * INTR ACK * STB * IBF RD * DATA N...
Page 35 - Timing Connections; DAQ Timing Connections
Chapter 2 Configuration and Installation © National Instruments Corporation 2-17 Lab-NB User Manual Timing Connections Pins 38 through 48 of the I/O connector are connections for timing I/O signals. The timing I/O ofthe Lab-NB is designed around the 8253 Counter/Timer integrated circuit. Two of thes...
Page 38 - Figure 2-14. Waveform Generation Timing with the EXTUPDATE* Signal
Configuration and Installation Chapter 2 Lab-NB User Manual 2-20 © National Instruments Corporation text Minimum 50 nsec EXTUPDATE* DAC OUTPUT UPDATE TMRINTUP DACWRT text Figure 2-14. Waveform Generation Timing with the EXTUPDATE* Signal Since a rising edge on the EXTUPDATE* signal always sets the T...
Page 43 - Functional Overview
© National Instruments Corporation 3-1 Lab-NB User Manual Chapter 3Theory of Operation This chapter contains a functional overview of the Lab-NB and explains the operation of eachfunctional unit making up the Lab-NB. Functional Overview The block diagram in Figure 3-1 shows a functional overview of ...
Page 44 - NuBus Interface Circuitry
Theory of Operation Chapter 3 Lab-NB User Manual 3-2 © National Instruments Corporation The following are the major components making up the Lab-NB board: • NuBus interface circuitry • Analog input and DAQ circuitry • Analog output circuitry • Digital I/O circuitry • Timing I/O circuitry DAQ functio...
Page 45 - Analog Input and DAQ Circuitry; Figure 3-3. Analog Input and DAQ Circuitry Block Diagram
Chapter 3 Theory of Operation © National Instruments Corporation 3-3 Lab-NB User Manual The starting-address-detecting circuitry on the Lab-NB matches address lines 23 through 21 tothe starting address specified by the slot in which the Lab-NB board is installed. The remainingaddress lines (19 throu...
Page 46 - Analog Input Circuitry
Theory of Operation Chapter 3 Lab-NB User Manual 3-4 © National Instruments Corporation Analog Input Circuitry The analog input circuitry consists of an input multiplexer, a software-programmable gainamplifier, a 12-bit ADC, and a 12-bit FIFO memory that is sign-extended to 16 bits. The input multip...
Page 47 - Single-Channel Data Acquisition
Chapter 3 Theory of Operation © National Instruments Corporation 3-5 Lab-NB User Manual multichannel (scanned) data acquisition. Scanned data acquisition uses a counter toautomatically switch between analog input channels during data acquisition. DAQ timing consists of signals that initiate a DAQ op...
Page 48 - DAQ Rates; Table 3-1. Analog Input Settling Time Versus Gain; Gain Setting; Any Gain Setting; Multichannel Data Acquisition:
Theory of Operation Chapter 3 Lab-NB User Manual 3-6 © National Instruments Corporation DAQ Rates Maximum DAQ rates (number of samples per second) are determined by the conversion periodof the ADC plus the sample-and-hold acquisition time. During multichannel scanning, the DAQrates are further limit...
Page 49 - Table 3-3. Bipolar Analog Input Signal Range Versus Gain; Table 3-4. Unipolar Analog Input Signal Range Versus Gain; Analog Output Circuitry
Chapter 3 Theory of Operation © National Instruments Corporation 3-7 Lab-NB User Manual The recommended DAQ rates given in Table 3-2 assume that voltage levels on all the channelsincluded in the scan sequence are within range for the given gain and are driven by low-impedance sources. The signal ran...
Page 50 - Figure 3-4. Analog Output Circuitry Block Diagram; ) multiplied by the digital
Theory of Operation Chapter 3 Lab-NB User Manual 3-8 © National Instruments Corporation DAC0 DAC1 DAC Configuration Register Ref Coding Coding Ref DAC0 OUT AGND DAC1 OUT EXTUPDATE* 5 V Internal Reference DAC0WR Data DAC1WR Counter A2 CNFGWR TWOSDA0 TMRWGN1 TWOSDA1 TMRWGN0 TWOSDA0 TWOSDA1 12 I/O Conn...
Page 51 - Digital I/O Circuitry
Chapter 3 Theory of Operation © National Instruments Corporation 3-9 Lab-NB User Manual corresponding to an LSB change in the digital code word. For both unipolar and bipolar output,one LSB corresponds to the following formula: 10 V 4, 096 Digital I/O Circuitry The digital I/O circuitry is designed ...
Page 54 - Register Access; Slot Address Space
© National Instruments Corporation 4-1 Lab-NB User Manual Chapter 4Register-Level Programming This chapter describes in detail the address and function of each of the Lab-NB control and statusregisters. This chapter also includes important information about register-level programming theLab-NB. Note...
Page 55 - Slot Number; Register Map
Register-Level Programming Chapter 4 Lab-NB User Manual 4-2 © National Instruments Corporation Table 4-1. Macintosh Slot Addresses Slot Number Starting Address (Hex) Ending Address (Hex) 24-Bit Mode 9 0090 0000 009F FFFF A 00A0 0000 00AF FFFF B 00B0 0000 00BF FFFF C 00C0 0000 00CF FFFF D 00D0 0000 0...
Page 56 - Offset
Chapter 4 Register-Level Programming © National Instruments Corporation 4-3 Lab-NB User Manual Table 4-2. Lab-NB Register Map Offset Register Name Address (Hex) Type Size Analog Input Register Group A/D Configuration Register 0 8000 Write-only 16-bit Status Register 0 8000 Read-only 8-bit A/D FIFO R...
Page 57 - Register Sizes; Register Descriptions; Register Description Format
Register-Level Programming Chapter 4 Lab-NB User Manual 4-4 © National Instruments Corporation Register Sizes The Macintosh permits three different memory word sizes for memory read and writeoperations–byte (8-bit), half-word (16-bit), and word (32-bit). Table 4-2 shows the word sizes ofthe Lab-NB r...
Page 58 - Analog Input Register Group
Chapter 4 Register-Level Programming © National Instruments Corporation 4-5 Lab-NB User Manual Analog Input Register Group The four registers making up the Analog Input Register Group control the analog input circuitryand are used for reading from the A/D FIFO. The A/D Configuration Register selects...
Page 59 - A/D Configuration Register; Bit; TBSEL
Register-Level Programming Chapter 4 Lab-NB User Manual 4-6 © National Instruments Corporation A/D Configuration Register The A/D Configuration Register indicates the input channel to be read and the gain for theanalog input circuitry. Address: Base address + 0 8000 (hex) Type: Write-only Word Size:...
Page 60 - PRETRIG; Selected Channel
Chapter 4 Register-Level Programming © National Instruments Corporation 4-7 Lab-NB User Manual Bit Name Description (continued) 8 PRETRIG Pretrigger Bit—This bit is used to set the pretriggering feature onthe Lab-NB. It also supersedes any setting in the EXTTRIGEN bitdescribed earlier. If PRETRIG is...
Page 61 - Gain Bit—These three bits select the gain setting as follows:; Selected Gain; TWOSCMP
Register-Level Programming Chapter 4 Lab-NB User Manual 4-8 © National Instruments Corporation Bit Name Description (continued) Channel Scanning later in this chapter for the correct sequenceinvolved in setting the SCANEN bit. 3–1 GAIN<2..0> Gain Bit—These three bits select the gain setting as...
Page 62 - Status Register; OVERRUN
Chapter 4 Register-Level Programming © National Instruments Corporation 4-9 Lab-NB User Manual Status Register The Status Register indicates the status of the current A/D conversion. The bits in this registerdetermine if a conversion is being performed or if data is available and any errors have bee...
Page 63 - Straight binary mode
Register-Level Programming Chapter 4 Lab-NB User Manual 4-10 © National Instruments Corporation A/D FIFO Register Reading the A/D FIFO Register returns the next A/D conversion value stored in the A/D FIFO.Whenever the A/D FIFO Register is read, the value read is removed from the A/D FIFO, therebyfre...
Page 64 - Two’s complement binary mode
Chapter 4 Register-Level Programming © National Instruments Corporation 4-11 Lab-NB User Manual A/D FIFO Register (continued) Bit Map: Two’s complement binary mode 15 14 13 12 11 10 9 8 Sign Extension Bits D11 D10 D9 D8 7 6 5 4 3 2 1 0 D7 D6 D5 D4 D3 D2 D1 D0 Bit Name Description 15– 0 D<15..0>...
Page 65 - Not applicable, no bits used
Register-Level Programming Chapter 4 Lab-NB User Manual 4-12 © National Instruments Corporation A/D Clear Register The ADC can be reset by writing to this register. This operation clears the FIFO and loads thelast conversion value into the FIFO. All error bits in the Status Register are cleared as w...
Page 66 - Analog Output Register Group
Chapter 4 Register-Level Programming © National Instruments Corporation 4-13 Lab-NB User Manual Analog Output Register Group The four registers making up the Analog Output Register Group are used for loading the two12-bit DACs in the two analog output channels. DAC0 controls analog output channel 0....
Page 67 - DAC Configuration Register; TMRWGN1
Register-Level Programming Chapter 4 Lab-NB User Manual 4-14 © National Instruments Corporation DAC Configuration Register This register determines if data written to the DACs is in straight binary or two’s complementform. It also configures the DACs to output data automatically at a rate controlled...
Page 68 - DAC0 and DAC1 Data Registers
Chapter 4 Register-Level Programming © National Instruments Corporation 4-15 Lab-NB User Manual DAC0 and DAC1 Data Registers Writing to these registers loads the corresponding analog output channel DAC, thereby updatingthe voltages generated by the analog output channels. The voltage is updated imme...
Page 69 - 253 Counter/Timer Register Groups
Register-Level Programming Chapter 4 Lab-NB User Manual 4-16 © National Instruments Corporation 8253 Counter/Timer Register Groups The eight registers making up the two Counter/Timer Register Groups access the two onboard8253 Counter/Timers. Each 8253 has three counters. For convenience, the two Cou...
Page 70 - Counter A0 Data Register
Chapter 4 Register-Level Programming © National Instruments Corporation 4-17 Lab-NB User Manual Counter A0 Data Register The Counter A0 Data Register is used for loading and reading back contents of 8253(A)counter 0. Address: Base address + 4 0000 (hex) Type: Read-and-write Word Size: 8-bit Bit Map:...
Page 71 - Counter A1 Data Register
Register-Level Programming Chapter 4 Lab-NB User Manual 4-18 © National Instruments Corporation Counter A1 Data Register The Counter A1 Data Register is used for loading and reading back contents of 8253(A)counter 1. Address: Base address + 4 0010 (hex) Type: Read-and-write Word Size: 8-bit Bit Map:...
Page 72 - Counter A2 Data Register
Chapter 4 Register-Level Programming © National Instruments Corporation 4-19 Lab-NB User Manual Counter A2 Data Register The Counter A2 Data Register is used for loading and reading back contents of 8253(A)counter A2. Address: Base address + 4 0020 (hex) Type: Read-and-write Word Size: 8-bit Bit Map...
Page 73 - Counter A Mode Register
Register-Level Programming Chapter 4 Lab-NB User Manual 4-20 © National Instruments Corporation Counter A Mode Register The Counter A Mode Register determines the operation mode for each of the three counters onthe 8253(A) chip. The Counter A Mode Register selects the counter involved, its read/load...
Page 74 - Counter B0 Data Register
Chapter 4 Register-Level Programming © National Instruments Corporation 4-21 Lab-NB User Manual Counter B0 Data Register The Counter B0 Data Register is used for loading and reading back the contents of 8253(B)counter 0. Address: Base address + 4 8000 (hex) Type: Read-and-write Word Size: 8-bit Bit ...
Page 75 - Counter B1 Data Register
Register-Level Programming Chapter 4 Lab-NB User Manual 4-22 © National Instruments Corporation Counter B1 Data Register The Counter B1 Data Register is used for loading and reading back the contents of 8253(B)counter 1. Address: Base address + 4 8010 (hex) Type: Read-and-write Word Size: 8-bit Bit ...
Page 76 - Counter B2 Data Register
Chapter 4 Register-Level Programming © National Instruments Corporation 4-23 Lab-NB User Manual Counter B2 Data Register The Counter B2 Data Register is used for loading and reading back the contents of 8253(B)counter 2. Address: Base address + 4 8020 (hex) Type: Read-and-write Word Size: 8-bit Bit ...
Page 77 - Counter B Mode Register
Register-Level Programming Chapter 4 Lab-NB User Manual 4-24 © National Instruments Corporation Counter B Mode Register The Counter B Mode Register determines the operation mode for each of the three counters onthe 8253(B) chip. The Counter B Mode Register selects the counter involved, its read/load...
Page 78 - 2C55A Digital I/O Register Group
Chapter 4 Register-Level Programming © National Instruments Corporation 4-25 Lab-NB User Manual 82C55A Digital I/O Register Group Digital I/O on the Lab-NB uses an 82C55A integrated circuit. The 82C55A is a general-purposePPI containing 24 programmable I/O pins. These pins represent the three 8-bit ...
Page 79 - Port A Register
Register-Level Programming Chapter 4 Lab-NB User Manual 4-26 © National Instruments Corporation Port A Register Reading the Port A Register returns the logic state of the eight digital I/O lines constitutingport A, that is, PA<0..7>. If port A is configured for output, the Port A Register can ...
Page 80 - Port B Register
Chapter 4 Register-Level Programming © National Instruments Corporation 4-27 Lab-NB User Manual Port B Register Reading the Port B Register returns the logic state of the eight digital I/O lines constituting portB, that is, PB<0..7>. If port B is configured for output, the Port B Register can ...
Page 81 - Port C Register
Register-Level Programming Chapter 4 Lab-NB User Manual 4-28 © National Instruments Corporation Port C Register Port C is special in the sense that it can be used as an 8-bit I/O port like port A and port B ifneither port A nor port B is used in handshaking (latched) mode. If either port A or port B...
Page 82 - Digital Control Register
Chapter 4 Register-Level Programming © National Instruments Corporation 4-29 Lab-NB User Manual Digital Control Register The Digital Control Register can be used to configure port A, port B, and port C as inputs oroutputs as well as selecting simple mode (basic I/O) or handshaking mode (strobed I/O)...
Page 83 - Interrupt Control Register Group
Register-Level Programming Chapter 4 Lab-NB User Manual 4-30 © National Instruments Corporation Interrupt Control Register Group This group is made up of two registers. Writing to the Interrupt Control Register enables theinterrupt facility on the Lab-NB. The Interrupt Status Register contains infor...
Page 84 - Interrupt Control Register; PAINTEN
Chapter 4 Register-Level Programming © National Instruments Corporation 4-31 Lab-NB User Manual Interrupt Control Register Setting bits of this register causes an interrupt to occur when the current process is complete. Address: Base address + 1 0000 (hex) Type: Write-only Word Size: 8-bit Bit Map: ...
Page 85 - ADCINTEN
Register-Level Programming Chapter 4 Lab-NB User Manual 4-32 © National Instruments Corporation Bit Name Description (continued) the Timer Interrupt Clear Register. This interrupt allows waveformgeneration on the analog output because the same signal that setsthe interrupt also updates the DAC outpu...
Page 86 - Interrupt Status Register; INT
Chapter 4 Register-Level Programming © National Instruments Corporation 4-33 Lab-NB User Manual Interrupt Status Register The Interrupt Status Register indicates the status of the Interrupt Control Register bits and theinterrupt lines. Address: Base address + 1 0000 (hex) Type: Read-only Word Size: ...
Page 87 - Timer Interrupt Clear Register
Register-Level Programming Chapter 4 Lab-NB User Manual 4-34 © National Instruments Corporation Timer Interrupt Clear Register Writing to the Timer Interrupt Clear Register clears the TIMERUP bit in the Interrupt StatusRegister. The Timer Interrupt Clear Register can be used to service any timer-rel...
Page 88 - Configuration EPROM; Register Programming Considerations
Chapter 4 Register-Level Programming © National Instruments Corporation 4-35 Lab-NB User Manual Configuration EPROM The Configuration EPROM is an onboard read-only memory that contains information requiredby the Macintosh operating system. The Macintosh system Slot Manager reads theConfiguration EPR...
Page 89 - This sequence leaves the Lab-NB circuitry in the following state:; Programming the Analog Input Circuitry; Analog Input Circuitry Programming Sequence; Each of these steps is discussed in detail as follows.
Register-Level Programming Chapter 4 Lab-NB User Manual 4-36 © National Instruments Corporation 4. Write 0000 (hex) to the A/D Configuration Register (16-bit write). 5. Write 00 (hex) to the A/D Clear Register (8-bit write). 6. Read the data from the A/D FIFO Register (16-bit read). Ignore the data....
Page 90 - Select analog input channel and gain.
Chapter 4 Register-Level Programming © National Instruments Corporation 4-37 Lab-NB User Manual 1. Select analog input channel and gain. The analog input channel and gain are selected by writing to the A/D Configuration Register.See the A/D Configuration Register bit description earlier in this chap...
Page 91 - A/D FIFO Output Binary Modes
Register-Level Programming Chapter 4 Lab-NB User Manual 4-38 © National Instruments Corporation used for A/D timing, the DAVAIL bit should be set after 12 msec or after a rising edge inEXTCONV*, whichever occurs later. An A/D FIFO overflow condition occurs if more than 16 conversions are initiated a...
Page 92 - Clearing the Analog Input Circuitry; Analog input error flags OVERFLOW and OVERRUN are cleared.; Programming Multiple A/D Conversions on a Single Input Channel; Controlled acquisition mode
Chapter 4 Register-Level Programming © National Instruments Corporation 4-39 Lab-NB User Manual Clearing the Analog Input Circuitry The analog input circuitry can be cleared by writing to the A/D Clear Register, which leaves theanalog input circuitry in the following state: • Analog input error flag...
Page 93 - Programming in Controlled Acquisition Mode; Each of these programming steps is explained below.
Register-Level Programming Chapter 4 Lab-NB User Manual 4-40 © National Instruments Corporation Programming in Controlled Acquisition Mode The following programming steps are required for a DAQ operation in controlled acquisitionmode: 1. Select analog input channel, gain, and timebase source for cou...
Page 94 - Program counters A0 and A1.
Chapter 4 Register-Level Programming © National Instruments Corporation 4-41 Lab-NB User Manual 3. Program counters A0 and A1. This step involves programming counter A0 to generate periodic conversion pulses andprogramming counter A1 to interrupt on terminal count mode (mode 0). Counter A0 of the 82...
Page 95 - Service the DAQ operation.
Register-Level Programming Chapter 4 Lab-NB User Manual 4-42 © National Instruments Corporation Use the following programming sequence to program the sample-interval counter. All writes are8-bit write operations. All values given are hexadecimal. a. Write 34 to the Counter A Mode Register (select co...
Page 96 - Programming in Freerun Acquisition Mode; Program counter A0 to force OUT0 high.
Chapter 4 Register-Level Programming © National Instruments Corporation 4-43 Lab-NB User Manual Programming in Freerun Acquisition Mode Freerun acquisition mode uses only counter A0 as the sample-interval counter. The number ofA/D conversions that have occurred (that is, the sample count) is maintai...
Page 97 - Program count
Register-Level Programming Chapter 4 Lab-NB User Manual 4-44 © National Instruments Corporation c. Write the most significant byte of the timebase count to the Counter B Data Register. For example, programming a timebase of 10 µsec requires a timebase count of 10 µsec 0.5 µsec = 20 µsec 3. Program c...
Page 98 - External Timing Considerations for Multiple A/D Conversions
Chapter 4 Register-Level Programming © National Instruments Corporation 4-45 Lab-NB User Manual 7. Service the DAQ operation. Once the DAQ operation is started by writing the most significant byte of the sample interval tothe Counter A0 Data Register, the operation must be serviced by reading the A/...
Page 99 - Using the EXTCONV* Signal to Initiate A/D Conversions; Programming Multiple A/D Conversions Using External Timing; Posttrigger Mode
Register-Level Programming Chapter 4 Lab-NB User Manual 4-46 © National Instruments Corporation Using the EXTTRIG Signal to Terminate a Multiple A/D Conversion DAQ Operation(Pretrigger Mode) If the PRETRIG bit is set in the ADC Command Register, EXTTRIG functions as a stop triggerfor a multiple A/D ...
Page 100 - Each of these programming steps is explained as follows.
Chapter 4 Register-Level Programming © National Instruments Corporation 4-47 Lab-NB User Manual 4. Clear the A/D circuitry. 5. Program counter A1 and enable EXTCONV* and EXTTRIG input. 6. Service the DAQ operation. Each of these programming steps is explained as follows. 1. Disable EXTCONV* and EXTT...
Page 101 - To program the counters, use the following programming sequence:
Register-Level Programming Chapter 4 Lab-NB User Manual 4-48 © National Instruments Corporation To program the counters, use the following programming sequence: a. Write 70 (hex) to the Counter A Mode Register (select counter A1, mode 0). This step sets the output of counter A1 (OUTA1) low, which in...
Page 102 - Pretrigger Mode
Chapter 4 Register-Level Programming © National Instruments Corporation 4-49 Lab-NB User Manual Pretrigger Mode The following programming steps are required for a DAQ operation in controlled acquisitionmode using EXTCONV*. In the following programming sequence, EXTTRIG is used as apretrigger signal;...
Page 103 - Program counter A1 and enable EXTCONV* input.
Register-Level Programming Chapter 4 Lab-NB User Manual 4-50 © National Instruments Corporation 4. Clear the A/D circuitry. Before the DAQ operation is started, the A/D FIFO must be emptied in order to clear any oldA/D conversion results. Empty the A/D FIFO after the counters are programmed becausep...
Page 104 - Programming Multiple A/D Conversions with Channel Scanning
Chapter 4 Register-Level Programming © National Instruments Corporation 4-51 Lab-NB User Manual Two error conditions may occur during a DAQ operation: an overflow error or an overrun error.These error conditions are reported through the Status Register and should be checked every timethe Status Regi...
Page 105 - Interrupt Programming for the Analog Input Circuitry
Register-Level Programming Chapter 4 Lab-NB User Manual 4-52 © National Instruments Corporation channel 3, channel 2, channel 1, channel 0, channel 3, channel 2, channel 1, channel 0,channel 3, and so on. Note: Select the analog input channel and gain in the following order: 1. Write the configurati...
Page 106 - Digital Code; digital code
Chapter 4 Register-Level Programming © National Instruments Corporation 4-53 Lab-NB User Manual by jumper settings described in Chapter 2, Configuration and Installation. Table 4-5 shows theoutput voltage versus digital code for a unipolar analog output configuration. Table 4-6 showsthe voltage vers...
Page 107 - Table 4-6. Analog Output Voltage Versus Digital Code; Interrupt Programming for the Analog Output Circuitry; Set up the DAC Configuration Register.
Register-Level Programming Chapter 4 Lab-NB User Manual 4-54 © National Instruments Corporation Table 4-6. Analog Output Voltage Versus Digital Code (Bipolar Mode, Two’s Complement Coding) Digital Code Voltage Output (Decimal) (Hex) (V ref = 10 V) -2,048 F800 -5.0 V -1,024 FC00 -2.5 V 0 0000 0.0 V 1...
Page 108 - Install an interrupt service routine.; Programming the Digital I/O Circuitry; The three basic modes of operation for the 82C55A are as follows:
Chapter 4 Register-Level Programming © National Instruments Corporation 4-55 Lab-NB User Manual 3. Install an interrupt service routine. You must install an interrupt service routine for the slot containing the Lab-NB. Consult theInside Macintosh manual for information regarding the installation of ...
Page 110 - Register Descriptions and Programming Examples
Chapter 4 Register-Level Programming © National Instruments Corporation 4-57 Lab-NB User Manual Register Descriptions and Programming Examples The following figures show the two control-word formats used to completely program the82C55A. The control-word flag determines which control-word format is b...
Page 112 - Example 2. Configure port A for input, port B and port C for output:
Chapter 4 Register-Level Programming © National Instruments Corporation 4-59 Lab-NB User Manual Example 2. Configure port A for input, port B and port C for output: • Write 90 (hex) to the Digital Control Register. • Write 8-bit data to port B or port C. Read 8-bit data from port A as appropriate. E...
Page 115 - INTEA
Register-Level Programming Chapter 4 Lab-NB User Manual 4-62 © National Instruments Corporation Port C status-word bit definitions for output (port A and port B): 7 6 5 4 3 2 1 0 OBFA* INTEA I/O I/O INTRA INTEB* OBFB INTRB Bit Name Description 7 OBFA* Output Buffer Full for Port A—Low indicates that...
Page 117 - IBFA
Register-Level Programming Chapter 4 Lab-NB User Manual 4-64 © National Instruments Corporation Port C status-word bit definitions for bidirectional data path (port A only): 7 6 5 4 3 2 1 0 OBFA* INTE1 IBFA INTE2 INTRA I/O I/O I/O Bit Name Description 7 OBFA* Output Buffer Full—Low indicates that th...
Page 118 - Interrupt Programming for the Digital I/O Circuitry
Chapter 4 Register-Level Programming © National Instruments Corporation 4-65 Lab-NB User Manual Mode 2 Programming Example Example 1. Configure port A in mode 2: • Write C0 (hex) to the Digital Control Register. • Wait for bit 7 of port C (OBFA*) to be cleared, indicating that the data last written ...
Page 119 - Calibration Equipment Requirements
© National Instruments Corporation 5-1 Lab-NB User Manual Chapter 5Calibration This chapter discusses the calibration procedures for the Lab-NB analog input and analog outputcircuitry. The Lab-NB is calibrated at the factory before shipment. To maintain the 12-bit accuracy of theLab-NB analog input ...
Page 120 - Calibration Trimpots
Calibration Chapter 5 Lab-NB User Manual 5-2 © National Instruments Corporation Calibration Trimpots The Lab-NB has six trimpots for calibration. The location of these trimpots on the Lab-NBboard is shown in the partial diagram of the board in Figure 5-1. 1 2 3 4 5 1 R6 2 R7 3 R8 4 R9 5 R10 6 R1 Fig...
Page 121 - Analog Input Calibration; Offset errors
Chapter 5 Calibration © National Instruments Corporation 5-3 Lab-NB User Manual Analog Input Calibration To null out error sources that compromise the quality of measurements, you must calibrate theanalog input circuitry by adjusting the following potential sources of error: • Offset errors • Gain e...
Page 122 - Input Range; Offset Calibration; To adjust the amplifier input offset:
Calibration Chapter 5 Lab-NB User Manual 5-4 © National Instruments Corporation Input Range V -fs V +fs - 1 1 LSB 0.5 LSB -5 to +5 V -5 V +4.99756 V 2.44 mV 1.22 mV 0 to 10 V 0 V +9.99756 V 2.44 mV 1.22 mV Board Configuration The calibration procedure differs if you select either bipolar or unipolar...
Page 123 - Unipolar Input Calibration Procedure; Analog Output Calibration; Analog output offset error
Chapter 5 Calibration © National Instruments Corporation 5-5 Lab-NB User Manual b. Take analog input readings from channel 0 at a gain of 1, and adjust trimpot R10 until the ADC readings flicker evenly between 2,046 and 2,047. Alternatively, you can average anumber of readings (approximately 100) an...
Page 124 - Adjust the Analog Output Offset; For analog output channel 0:
Calibration Chapter 5 Lab-NB User Manual 5-6 © National Instruments Corporation Offset error in the analog output circuitry is the total of the voltage offsets contributed by eachcomponent in the circuitry. This error appears as a voltage difference between the desiredvoltage and the actual output v...
Page 125 - Unipolar Output Calibration Procedure
Chapter 5 Calibration © National Instruments Corporation 5-7 Lab-NB User Manual c. Adjust trimpot R9 until the output voltage read is -5 V.2. Adjust the Analog Output Gain Adjust the analog output gain by measuring the output voltage generated with the DAC set atpositive full-scale (4,095). This out...
Page 126 - For analog output channel 1:; Adjust the Analog Output Gain
Calibration Chapter 5 Lab-NB User Manual 5-8 © National Instruments Corporation For analog output channel 1: a. Connect the voltmeter between DAC1 OUT (pin 12 on the I/O connector) and AOGND (pin 11). b. Set the analog output channel to 0 V by writing 0 to the DAC. c. Adjust trimpot R9 until the out...
Page 127 - Explanation of Analog Input Specifications
© National Instruments Corporation A-1 Lab-NB User Manual Appendix ASpecifications This appendix lists the specifications of the Lab-NB. These specifications are typical at 25° C unless otherwisestated. The operating temperature range is 0° to 70° C. Analog Input Number of input channels...............
Page 128 - Analog Data Acquisition
Specifications Appendix A Lab-NB User Manual A-2 © National Instruments Corporation normally called nonlinearity, because relative accuracy ensures that the sum of quantization uncertainty and A/Dconversion error does not exceed a given amount. Integral nonlinearity in an ADC is an often ill-defined...
Page 129 - Explanation of Analog Output Specifications; Power Requirements (from Macintosh NuBus)
Appendix A Specifications © National Instruments Corporation A-3 Lab-NB User Manual Voltage offset ......................................................................±60 µV/° C Explanation of Analog Output Specifications Relative accuracy in a D/A system is the same as nonlinearity, because no un...
Page 130 - Physical
Specifications Appendix A Lab-NB User Manual A-4 © National Instruments Corporation Physical Board dimensions........................................................................27.62 by 10.16 cm (10.875 by 4.0 in.)I/O connector .......................................................................
Page 162 - Branch Offices
© National Instruments Corporation E-1 Lab-NB User Manual Appendix ECustomer Communication ___________________________________________________ For your convenience, this appendix contains forms to help you gather the information necessaryto help us solve technical problems you might have as well as ...
Page 163 - Technical Support Form
Technical Support Form ___________________________________________________ Photocopy this form and update it each time you make changes to your software or hardware, and use the completedcopy of this form as a reference for your current configuration. Completing this form accurately before contactin...
Page 165 - Documentation Comment Form
Documentation Comment Form ___________________________________________________ National Instruments encourages you to comment on the documentation supplied with our products. Thisinformation helps us provide quality products to meet your needs. Title: Lab-NB User Manual Edition Date: September 1995 ...
Page 166 - Prefix
© National Instruments Corporation Glossary-1 Lab-NB User Manual Glossary ___________________________________________________ Prefix Meaning Value p- pico- 10 -12 n- nano- 10 -9 µ- micro- 10 -6 m- milli- 10 -3 k- kilo- 10 3 M- mega- 10 6 G- giga- 10 9 ° degrees Ω ohms % percent A amperes A/D analog-...
Page 168 - Index
© National Instruments Corporation Index- 1 Lab-NB User Manual Index Numbers/Symbols +5 V signal (table), 2-782C55A Digital I/O Register group, 4-25 to 4-29 control words. See control words.Digital Control Register, 4-29digital I/O circuitry block diagram, 3-9OKI 82C55A data sheet, D-1 to D-17overvi...