one of the resistors in a circuit is proportional to the voltage across the total resistance
in the circuit.
The trick to using a voltage divider is to choose two resistors with the proper proportions relative to the full scale of the digital input and the maximum signal voltage.
The phenomena of dropping the voltage proportionally is often called attenuation.
The formula for attenuation is:
Attenuation = R1+R2
R2
The variable
Attenuation
tional difference between the signal
voltage max and the full scale of the
is the propor-
analog input.
For example, if the signal varies
2 = 10K+10K
10K
between 0 and 10 volts and you wish to
measure that with an PCI-DIO24 board
with a full scale range of 0 to 5 volts,
the
Attenuation
is 2:1 or just 2.
For a given attenuation, pick a handy
R1=(A-1)*R2
resistor and call it R2, then use this formula to calculate R1.
Digital inputs can readily use voltage dividers. For example, if you wish to measure a
digital signal that is at 0 volts when off and 24 volts when on, you cannot connect that
directly to the PCI-DIO24 digital inputs. The voltage must be dropped to 5 volts max
when on. The Attenuation is 24:5 or 4.8. Use the equation above to find an appropriate R1 if R2 is 1K. Remember that a TTL input is 'on' when the input voltage is
greater than 2.5 volts.
IMPORTANT NOTE
The resistors, R1 and R2, are going to dissipate all the power in the
divider circuit according to the equation Current = Voltage /
Resistance. The higher the value of the resistance (R1 + R2) the
less power dissipated by the divider circuit. Here is a simple rule:
For Attenuation of 5:1 or less, no resistor should be less than 10K.
For Attenuation of greater than 5:1, no resistor should be < 1K.
The CIO-TERMINAL is a 16" by 4" screw terminal board with two 37 pin D type
connectors and 56 screw terminals (12 - 22 AWG). Designed for table top, wall or
rack mounting, the board provides prototype, divider circuit, filter circuit and pull-up
resistor positions which you may complete with the proper value components for your
application.
23
Page 3
7.2 TTL TO SOLID STATE RELAYS
TABLE OF CONTENTS
Many applications require digital outputs to switch AC and DC voltage motors on and
off and to monitor AC and DC voltages. The se AC and high DC volt ages cannot be
controlled or read directly by the TTL digital lines of a PCI-DIO24.
Solid State Relays
and monitoring of AC and high DC voltages and provide 750V isolation. Solid State
Relays (SSRs) are the recommended method of interfacing to AC and high DC signals.
The most convenient way to use solid state relays and a PCI-DIO24 board is to purchase a Solid State Relay Rack. A SSR Rack is a circuit board with output buffer
chips which are powerful enough to swit ch the SSR and sockets to plug SSRs into.
SSR Racks are available from Computer Boards and most manufacturers of SSRs. If
you have only a few outputs to cont rol, you may also wish to consider the DR-OAC
or DR-ODC, single point, DIN mountable SSRs.
The high current outputs of the PCI-DIO24H and PCI-DIO24H/CTR3 boards are
suitable to drive SSR’ directly but the CMOS outputs of the PCI-DIO24 do not have
sufficient drive to connect directly to most SSRs. If you only want to drive one or two
SSRs with CMOS outputs, all you need is a 74LS244 output buffer chip between the
82C55 output and the SSR. Of course the SSR will need 5 volt power as well.
, such as those available from Omega, allow control
7.3 VOLTAGE DIVIDERS
If you wish to measure a signal which varies over a range greater than the input range
of a digital input, a voltage divider can drop the voltage of the input signal to the level
the digital input can measure.
A voltage divider takes advantage of Ohm's law, which states,
1 INTRODUCTION
.................................
2 QUICK START & INSTALLATION
2.1 WINDOWS 95, 98 & NT
2.2 DOS and/or Windows 3.1
2.3 InstaCal
.....................................
2.3 RUN InstaCAL
2.4 Testing The Installation
3 I/O CONNECTIONS
................................
...............................
.........................
........................
.........................
3.1 CABLES AND SCREW TERMINAL BOARDS
3.2 CONNECTOR DIAGRAM - PCI-DIO24, -24H &
-24H/CTR3
......................................
3.3 SIGNAL CONNECTION CONSIDERATIONS
3.4 COUNTER CONNECTIONS & SETUP
4 SOFTWARE
5 I/O REGISTER MAPS
......................................
................................
5.1 BOARD CONTROL REGISTERS
5.1 82C55 CONTROL & DATA REGISTERS
5.2 82C55 DIGITAL I/O REGISTERS
5.3 OUTPUT PORTS
5.4 INPUT PORTS
5.5 82C54 COUNTER CHIP
.............................
...............................
.......................
..................
.........
.........
.............
.................
...........
................
1
2
2
3
3
3
4
5
5
5
6
7
8
8
10
11
12
13
14
15
Voltage = Current * Resistance
Implied in the above is that any
variation in the voltage drop for the
circuit as a whole will have a
portional
age drops in the circuit.
A voltage divider takes advantage
of the fact that the voltage across
variation in all the volt-
pro-
Signal
High
Signal
Vin
Volts
Signal
Low
SIMPLE VOLTAGE DIVIDER - Vin = R1+R2
22
R1
R2
Vout R2
V1
V2
Vout
CIO-DIO24
Input
Groundt
6 SPECIFICATIONS
6.1 PCI-DIO24
6.2 PCI-DIO24H
6.3 PCI-DIO24H/CTR3
...............................
..................................
.................................
...........................
7 ELECTRONICS AND INTERFACING
7.1 PULL UP & PULL DOWN RESISTORS
7.2 TTL TO SOLID STATE RELAYS
7.3 VOLTAGE DIVIDERS
.........................
..................
...............
............
16
16
17
18
20
20
22
22
Page 4
The pull-up resistor provides a reference to +5V while its value of 2200 ohms
requires only 2.3 mA of drive current
If the 82C55 is reset and enters high impedance input, the line is pulled high. At that
point, both the 82C55 AND the device being controlled will sense a high signal.
If the 82C55 i s in output mode, the 82C55 has mor e than enough power (2 .5mA) to
over ride the pull-up/down resistor's high signal and drive the line to 0 volts. If the
82C55 asserts a high signal, the pull up resistor guaranties that the line goes to +5V.
Of course, a pull-down resistor accomplishes the same task except that the line is
pulled low when the 82C55 is reset. The 82C55 has more than enough power to drive
the line high.
The PCI-DIO24 series boar ds are equipped with positions for pull-up/down resistors
Single Inline Packages (SIPs). The positions are marked A, B and C and are located
beside the 82C55 or output chips.
A 2.2K, 8 resistor SIP is made of 8, 2.2K resistors all connected one side to a single
common point and the other, each to a pin protruding from the SIP. The common line
to which all resistor are connected also protrudes from the SIP. The common line is
marked with a dot and is at one end of the SIP.
The SIP may be installed as pull-up or pull-down. At each location, A, B & C on the
PCI-DIO24 series boards, there are 10 holes in a line. One end of the line is +5V, the
other end is GND. They are so marked. The 8 holes in the middle are connected to
the 8 lines of the port, A, B, or C.
A resistor value of 2.2K is recommended. Use other values only if you have calculated the necessity of doing so.
UNCONNECTED INPUTS FLOAT!
Keep in mind that unconnected inputs float. If you are using the DIO24 board for
input, and have unconnected inputs, ignore the data from those lines.
In other words, if you connect bit A0 and not bit A1, do not be surp rised if A1 stays
low, stays high or tracks A0... It is unconnected and so unspecified. The 82C55 is
not malfunctioning. In the absence of a pull-up/down, any input to a PCI-DIO24
which is unconnected, is unspecified!
You do not have to tie input lines, and unconnected lines will not affect the performance of connected lines. Just make sure that you mask out any unconnected bits in
software!
21
Page 5
7 ELECTRONICS AND INTERFACING
This short, simple introduction to the electronics most often needed by digital I/O
board users covers a few key concepts.
IMPORTANT NOTE
It cannot be stated often enough to those unfamiliar with the
82C55, WHENEVER THE 82C55 IS POWERED ON OR RESET,
ALL PINS ARE SET TO HIGH IMPEDANCE INPUT.
The implications of this fact is that if you have output devices such as solid state
relays, they may be switched on whenever the computer is powered on or reset. To
prevent unwanted switching and to drive all outputs to a known state after power on
or reset, pull all pins either high or low through a 2.2K resistor.
7.1 PULL UP & PULL DOWN RESISTORS
Whenever the 82C55 is powered on or reset, the control register is set to a known
state. That state is mode 0, all ports input.
When used as an output device to control other TTL input devices, the 82C55 applies
a voltage level of 0V for low and 2.5V-5V for high. It is the output voltage level of
the 82C55 that the device being controlled responds to.
The concept of output voltage for an 82C55 in input mode is meaningless. Do not
connect a volt meter to the floating input of an 82C55. It will show you nothing of
meaning. In input mode the 82C55 is in 'high Z' or high impedance. If your 82C55
was connected to another input chip (the device you were controlling), the inputs of
that chip are left floating whenever the 82C55 is in input mode.
1 INTRODUCTION
This manual provides information on PCI-DIO24, PCI-DIO24H and
PCI-DIO24H/CTR3 digital I/O boards and accessories. The manual is organized into
separate sections for those aspects of a product which are unique. Some issues, such
as simple programming and electronic interfacing are applicable to all of the digital
boards.
The PCI-DIO24 is a single 82C55 digital I/O chip interfaced to the PCI bus, with all
its I/O lines accessible through the board's 37 pin connector. The I/O pins of an
82C55 are CMOS TTL level.
PCI-DIO24H is a high drive, 24 line digital I/O board. The control register which
sets the direction of the I/O ports is identical to an 82C55 in mode 0 (see 82C55 data
sheet). The I/O pins are high drive TTL capable of sourcing 15mA and sinking
64mA.
PCI-DIO24H/CTR3 is a PCI-DIO24H with an 82C54 counter added. The 82C54 is a
10MHz down-counter chip with three 16 bit counters. The functions of the counter
(Input, Gate and Output) a re brought o ut to those pins which ar e used for b us power
access on the PCI-DIO24 and PCI-DIO24H. The PCI-DIO24H/CTR3 uses 8 I/O
addresses. The lower four are occupied by the 82C55 digital I/O chip emulation and
the upper four are occupied by the 82C54 counter timer chip.
This manual provides information on programming the 82C55 in mode 0. Those
wishing to use the 82C55 in modes 1 or 2, or who wish to program the 82C54 counter
on the PCI-DIO24H/CTR3, must procure a data book from Intel Corporation Literature Department.
If the inputs of the device you are controlling are left to float, they may float up or
down. Which way they float is
dependent on the characteristics
of the circuit and the electrical
environment; and may be unpre dictable! This is why it often
appears that the 82C55 has gone
'high' after power up. The result
is that your controlled device
gets turned on! That is why you
need pull up/down resistors.
Shown here is one 82C55 digital
output with a pull-up resistor
attached.
20
All these products are supported by Universal Library programming library. As an
owner of this product, you are entitled to the latest revision of the manual and software. Just call with your cur rent revision numbers ha ndy, and request an upd ate be
sent to you.
1
Page 6
2 QUICK START & INSTALLATION
The installation and operation of all three of the PCI-DIO24 series boards is very
similar. Thro ughout this manual we use PCI-DI O24 as a generi c designation for t he
PCI-DIO24, PCI-DIO24H, PCI-DIO24H/CTR3. When required due to the differences in the boards, the specific board name is used.
The PCI-DIO24 boards are easy to use. This quick start procedure will help you
quickly and easily setup, install and test your board. We assume you already know
how to open the PC and install expansion boards. If you are unfamiliar or uncomfortable with board installation, please refer to your computer’s documentation.
2.1 WINDOWS 95, 98 & NT
The PCI-DIO24 board is completely plug and play. Simply follow the steps shown
below to install your PCI-DIO24 hardware
1. Turn your computer off, unplug it, open it up and insert the PCI-DIO24
into any available PCI slot.
2. Close your computer up, plug it back in and turn it on.
3. Windows 95 will automatically detect the board as it starts up. I f the board’s
configuration file is already on the system, it will load without user interaction. If the
configuration file is not detected, you will be prompted to insert the disk containing it.
The required file is on the InstaCal disk or CD you received with your board. The
required file(s) will then be automatically loaded and the PCI board will appear in the
Device Manager under DAS components.
Logic Levels
Input low voltage0.8V max
Input high voltage2.0V min
Output low voltage0.4V max
Output high voltage3.0V min
Power consumption
+5V Operating 635 mA typical, 990 mA max
Environmental
Operating temperature range0 to 50°C
Storage temperature range-20 to 70°C
Humidity0 to 90% non-condensing
4. Insert the InstaCal disk or CD (if it’s not already in an appropriate drive) and
run the SETUP.EXE program.
You will then be prompted for additional information. Follow the instructions and if
possible accept the defaults. If this is your first installation, we urge you to accept the
defaults. It will be easier to assist you in the event of trouble with default settings.
If you have purchased the Universal Library programmers library, the SETUP.EXE
program will install all the software required to run the PCI-DIO24 as well as UniversalLibrary programming language support. Please be sure to select the 32-bit version
of the library when prompted.
When you have completed this part of the installation, please proceed to section “2.3,
Run InstaCal”.
2
19
Page 7
6.3 PCI-DIO24H/CTR3
2.2 DOS and/or WINDOWS 3.1
Digital Input / Output
Digital Type 8255 emulation, Mode 0
Output: 74S244
Input: 74LS373
Configuration2 banks of 8, 2 banks of 4, programma-
Number of channels24 I/O
Output High2.4 volts min @ -15mA
Output Low0.5 volts max @ 64 mA
Input High2.0 volts min, 7 volts absolute max
Input Low0.8 volts max, -0.5 volts absolute min
Power-up / reset stateInput mode (high impedance)
InterruptsINTA# - mapped to IRQn via PCI BIOS
Interrupt enableExternal source - active low and pro-
Counter type82C54
Configuration3 down counters per 82C54, 16 bits each
82C54A:
Clock input frequency10Mhz max
High pulse width (clock input)30ns min
Low pulse width (clock input)50ns min
Gate width high50ns min
Gate width low50ns min
ble by bank as input or output
at boot-time
grammable through PCI9050-1.
through PCI9050-1; 1 = active high,
0 = active low
Counter 0 - User counter.
Source: Available at user connector.
Gate:Available at user connector.
Output: Available at user connector.
Counter 1 - User counter.
Source: Available at user connector.
Gate:Available at user connector.
Output: Available at user connector.
Counter 2 - User counter.
Source: Available at user connector.
Gate:Available at user connector.
Output: Available at user connector.
Most users are now installing PCI Bus boards in systems with 32-bit operating systems (e.g. Windows 95, 98 or NT). The PCI-DIO24, PCI-DIO24H and
PCI-DIO24H/CTR3 are not currently supplied with the 16-bit drivers required to run
under DOS or Windows 3.x.
Please contact us if your application is running under DOS or Windows 3.x.
2.3 RUN InstaCAL
Prior to starting InstaCAL, reboot your computer so the various changes made to your
start up files are active.
From Win95, use “Start: Run” , type
InstaCal is the Installation, Calibration and Test software supplied with all ComputerBoards I/O boards. If you have a PCI board installed in a PCI slot in your computer,
the first message InstaCal displays is
A PCI-DIO24 has been detected in Slot #
A dialog bo x opens a sking you if you wish to install the software configur ation fo r a
PCI-DIO24. You should choose yes.
InstaCAL will then perform the remainder of the initial installation of your PCI board
selecting addresses and other system resource settings which are not your choice to
select. In PCI systems, these settings are assigned by the plug & play system soft-
ware.
InstaCal help
tively obvious and for that reason there is no user's manual for InstaCal.
The PCI-DIO24 and PCI-DIO24H require four standard I/O addresses as well as the
addresses required for Plug-and-Play operation. The PCI-DIO24H/CTR3 requires
four additional addresses for the 8254 counter, or a total of eight. The addresses are
allocated by the PCI plug & play procedure and may not be modified. If you have
installed ISA bus boards in the past you are familiar with the need to select a base
address and interrupt level. On PCI systems this is not of concern to you. It is not up
to you to select a base address and ensure that it does not conflict with an installed
port. In PCI systems, the operating software and installation software do the selection
and checking for you.
is available by pressing the F1 function key. Most of InstaCal is intui-
instacal
PCI BoardType Detected
at the prompt and click OK.
18
3
Page 8
InstaCal selects and sets the I/O address from the range of available addresses. The
address and other information is stored in the configuration file CB.CFG. This file is
accessed by the Universal Library for programmers. Note also that the Universal
Library is the I/O board interface for packaged applications such as Labtech Notebook and HP-VEE, therefore the InstaCal settings must be made in order for these
and other applications to run.
The board’s base address is also stored in the system software. Once InstaCal installation software is run, other programming methods such as direct IN and OUT statements can write and read the PCI-DIO24 registers by reference to the base address
and the offset from base address corresponding to the chart of registers located elsewhere in this manual.
But a word of warning is in order here. Direct writes to the addresses simply by reference to the base address of the PCI-DIO24 I/O registers is not advised. Since the
addresses assigned by the PCI plug & play software are not under your control, there
is no way to guarantee that your program will run in any other computer.
Not only that, but if you install another PCI board in a computer after the PCI-DIO24
addresses have been assigned, those addresses may be moved by the plug & play software when the second board is installed. It is best to use a library such as Universal
Library or a program such as HP-VEE to make measurements with your PCI-DIO24.
2.4 TESTING THE INSTALLATION
After you have run the install program and set your base address with InstaCal, it is
time to test the installation. The following section describes the InstaCal procedure to
test that your board is properly installed.
6.2 PCI-DIO24H
Digital Input / Output
Digital Type 8255 emulation
Output: 74S244
Input: 74LS373
Configuration2 banks of 8, 2 banks of 4, program-
mable by bank as input or output
Number of channels24 I/O
Output High2.4 volts min @ -15mA
Output Low0.5 volts max @ 64 mA
Input High2.0 volts min, 7 volts absolute max
Input Low0.8 volts max, -0.5 volts absolute
min
Power-up / reset stateInput mode (high impedance)
+5V Operating625 mA typical, 960 mA max
+12V and -12VNot used, but provided to the user
at the I/O connector
With InstaCal running, choose the TEST item on the main menu.
a. Select the board you just installed
b. Select Internal Test
c. The internal control registers of the board will then be tested. If this test
is successful, your board is installed correctly.
d. If the Internal Test is completed successfully, you may want to check
that the I/O pins are working correctly. To check this select
External Test and follow the instruction provided.
4
Environmental
Operating temperature range0 to 50°C
Storage temperature range-20 to 70°C
Humidity0 to 90% non-condensing
17
Page 9
6 SPECIFICATIONS
6.1 PCI-DIO24
Digital Input / Output
Digital Type (Digital I/O connector)82C55
Configuration2 banks of 8, 2 banks of 4, program-
mable by bank as input or output
Number of channels24 I/O
Output High3.7 volts min @ -2.5mA
Output Low0.4 volts max @ 2.5mA
Input High2.2 volts min, VCC + .3 volts abso-
lute max
Input Low0.8 volts max, -0.3 volts absolute
min
Power-up / reset stateInput mode (high impedance)
+5V Operating240 typical, 350 max
+12V and -12VNot used, but provided to the user
at the I/O connector
Environmental
Operating temperature range0 to 50 °C
Storage temperature range-20 to 70 °C
Humidity0 to 90% non-condensing
3 I/O CONNECTIONS
3.1 CABLES AND SCREW TERMINAL BOARDS
The PCI-DIO24 connector is accessible through the computer’s expansion bracket.
The connector is a standard 37 pin male connector. The I/O connections can be
brought out to easy to use scr ew terminals by purchasi ng a CFF37-series cable a nd a
CIO-MINI37 screw terminal accessory board.
A mating female connector may be purchased from Radio Shack and most other electronic supply outlets.
The PCI-DIO24 I/O connector is a 37
pin D type connector accessible from
the rear of the PC through the expansion backplate. The signals available
are direct connections to an 82C55
digital I/O chip as well as the PC’s
internal power supplies. The pin-out is
identical to the CIO-DIO24 except
that -5VDC is not brought out.
The PCI-DIO24H/CTR3 adds the signals for an 82C55 counter chip in
place of the PC power connections.
The connector accepts female 37 D
type connectors, such as those on the
C37FF-2, 2 foot cable.
If frequent changes to signal connections or signal conditioning is
required, please refer to the information on the PCI-MINI37 or PCISPADE50 screw terminal boards.
24/CTR3 24 & 24H
C L K 0
GATE 0
OUT 0
CLK 1
GATE 1
OUT 1
CLK 2
GATE 2
OUT 2
GND 19
+5 V 1 8
GND 17
+12V 16
GND 15
-12V 14
GND 13
NC 12
G N D 11
PORT B 0 10
PORT B 1 9
PORT B 2 8
PORT B 3 7
PORT B 4 6
PORT B 5 5
PORT B 6 4
PORT B 7 3
IR E N ABL E 2
IR IN P UT 1
NC - NO CONNECTION
37 PORT A 0
36 PORT A 1
35 PORT A 2
34 PORT A 3
33 PORT A 4
32 PORT A 5
31 PORT A 6
30 PORT A 7
29 PORT C 0
28 PORT C 1
27 PORT C 2
26 PORT C 3
25 PORT C 4
24 PORT C 5
23 PORT C 6
22 PORT C 7
21 GND
20 +5V
16
5
Page 10
3.3 SIGNAL CONNECTION CONSIDERATIONS
All the digital outputs and inputs on the PCI-DIO24 as well as the counter/timer signals of the PCI-DIO24H/CTR3 connector are CMOS TTL. The PCI-DIO24H signals
are buffered (high output drive) TTL. TTL is an electronics industry term, short for
Transistor Tr ansistor Logic, which describes a standard for digital signals which are
either at 0V or 5V.
The voltages and currents associated with external devices range from less than a
hundred mA at a few volts fo r a small flash light bulb to 5 0 Amps at 220 volts for a
large electric range. Attempting to connect either of these devices directly to the PCIDIO24 could damage the I/O chip.
We offer a wide variety of digital signal conditioning products that provide an ideal
interface between high voltage or high current real world signals and PCI-DIO24
family. If you are trying to control or monitor non-TTL level signals with your board,
we highly recommend you look in our catalog or on our web site for the following
products.
CIO-ERB series, electromechanical relay output boards
CIO-SERB series, 10A electromechanical relay output boards
SSR-RACK series solid state I/O module racks
DR-Series, DIN rail mountable solid state I/O modules.
In addition to voltage and load matching, digital signal sources often need to be debounced. A complete discussion of digital interfacing will be found in the section on
Interface Electronics in this manual.
IMPORTANT NOTE
The 82C55 digital I/O chip initializes all ports as inputs on power
up and reset. A TTL input is a high impedance input. If you connect another TTL input device to the 82C55 it will probably be
turned ON every time the 82C55 is reset, or, it might be turned
OFF instead. Remember, the 82C55 which is reset is in INPUT
mode.
To safeguard against unwanted signal levels, all devices being controlled by an
82C55 should be tied low (or high, as required) by a 2.2K ohm resistor.
The two groups of ports, group A and group B, may be independently programmed in
one of several modes. The most commonly used mode is mode 0, input / output
mode. The codes for programming the 82C55 in this mode are shown below. D7 is
always 1 and D6, D5 & D2 are always 0.
CLBCUADECHEXD0D1D3D4
OUTOUTOUTOUT128800000
INOUTOUTOUT129811000
OUTINOUTOUT130820100
ININOUTOUT131831100
OUTOUTINOUT136880010
INOUTINOUT137891010
OUTININOUT1388A0110
INININOUT1398B1110
OUTOUTOUTIN144900001
INOUTOUTIN145911001
OUTINOUTIN146920101
ININOUTIN147931101
OUTOUTININ152980011
INOUTININ153991011
OUTINININ1549A0111
ININININ1559B1111
8255 Mode 0 configurations
(D7=1, D6=D5=D2=0)
5.5 82C54 COUNTER CHIP
The 82C54 counter chip is quite complex. The data sheet for the part contains programming information, input and output timing diagrams and interfacing specifications.
We are sorry, but it is beyond the scope of this manual to reproduce the information,
all of which is contained in the chip manufacturers data book. For that information
check out Intel ’s web site at www.intel.com. A variety of information is available and
can be found by “searching” on keyword 8254.
You will find positions for pull up and pull down resistor packs on your PCI-DIO24
series board. To implement these, please turn to the application note on pull up/down
resistors.
6
15
Page 11
5.4 INPUT PORTS
3.4 COUNTER CONNECTIONS & SETUP
In 82C55 mode 0 configuration, ports configured for input read the state of the input
lines at the moment the read is executed, transitions are not latched.
For information on modes 1 (strobed I/O) and 2 (bi-directional strobed I/O), you will
need to acquire an Intel or AMD data book and see the 82C55 data sheet.
01234567
CLBM1CUAM2M3MS
Group BGroup A
The 82C55 may be programmed to operate in Input/ Output (mode 0), Strobed Input/
Output (mode 1) or Bi-Directional Bus (mode 2).
NOTE!
Only 82C55 mode 0 is available on the PCI-DIO24H &
24H/CTR3.
Included here is information on programming the 82C55 in mode 0. Those wishing
to use the 82C55 in modes 1 or 2, or who wish to program the 82C54 counter on the
PCI-DIO24H/CTR3, must procure a data book from Intel Corporation Literature
Department.
When the PC is powered up or RESET, the 82C55 is reset. This places all 24 lines in
Input mode and no further programming is needed to use the 24 lines as TTL inputs.
3.4.1 1 or 10 MHz Time Base
The user has the option of setting the onboard crystal time base to 1 MHz or 10 MHz.
This selection is made during the InstaCAL board setup. The time base defaults to 10
MHz.
3.4.2 Onboard counter interconnect jumpers
For the convenience of those users who wish to make (pseudo) permanent connections among the counter channels, the board has been configured with three jumper
locations. When installed, these jumpers can make the connections shown below:
Please note, that all of these connections can be made via the standard 37-Pin I/O
connector, and the jumpers have been included as a convenience only.
Jumper positions are provided to connect:
• Timebase
• Counter 0
• Counter 1
output
and Counter 0
output
and Counter 1
output
and Counter 2
Clk
Clk
Clk
To program the 82C55 for other modes, the following control code byte must be
assembled into an 8 bit byte.
Output0000
M1 = 0 is mode 0 for group B.Input / Output
M1 = 1 is mode 1 for group B.Strobed Input / Output
The Ports A, B, C High and C Low may be independently programmed for input or
output.
14
7
Page 12
4 SOFTWARE
Due to the complex and somewhat unpredictable nature of WINDOWS 95 control of
Plug-and-Play addresses, we highly recommend that users take advantage of our Universal Library package's easy to use programming interfaces. However, if you are an
experienced programmer, and wish to read and write directly to the board, we have
provided a detailed register map in the next chapter.
4.1 Universal Library
The UniversalLibrary provides complete access to the DIO24 functions from a range
of programming langua ges. If you are planning to write programs, or would like to
run the example pr ograms fo r Visual Basic o r any othe r language, ple ase turn no w to
the UniversalLibrary manual.
VIX Components is a set of programming tools based on a DLL interface to Windows languages. A set of VBX, OCX or ActiveX interfaces allows point and click
construction of graphical displays, analysis and control structures. Please see the
catalog for a complete description of the package.
Port C Data
Base Address +2
01234567
C0C1C2C3C4C5C6C7
CL0CL1CL2CL3CH0CH1CH2CH3
Pin 29Pin 28Pin 27Pin 26Pin 25Pin 24Pin 23Pin 22
Port C may be used as one 8 bit port of either input or output, or it may be split into
two 4 bit ports which may be independently input or output. The notation for the
upper 4 bit port is PCH3 - PCH0, and for the lower, PCL3 - PCL0.
Although it may be split, every read and write to port C carries 8 bits of data so
unwanted information must be ANDed out of reads, and writes must be ORed with
the current status of the other port.
5.3 OUTPUT PORTS
In 82C55 mode 0 configuration, ports configured for output hold the output data written to them. This output byte may be read back by reading a port configured for
output.
4.2 Packaged Applications Programs
Most packaged application programs, such as DAS Wizard, Labtech Notebook and
HP-VEE have drivers for the DIO24 series. If the package you own does not appear
to have drivers for the boards, please fax or e-mail the package name and the revision
number from the install disks. We will research the package for you and advise how
to utilize the PCI-DIO24 boards with the driver available.
Some application drivers are included with the Universal Library package, but not
with the Application package. If you have purchased an application package directly
from the software vendor, you may need to purchase our Universal Library and drivers. Please contact us for more information on this topic.
8
13
Page 13
The registers and their function are summarized in the following table. A more
detailed description of each register is included in subsequent sections. Within each
register are 8 bits which may constitute a byte of data or 8 individual bit set/read
functions.
5 I/O REGISTER MAPS
5.2 82C55 DIGITAL I/O REGISTERS
Port A Data
Base Address +0
Port B Data
Base Address +1
PCI-DIO24H/CTR3 ADDITIONAL
REGISTERS
WRITE FUNCTIONREAD FUNCTIONADDRESS
Port A OutputPort A Input of 82C55BASE +0
Port B OutputPort B InputBASE +1
Port C OutputPort C inputBASE +2
Configure 82C55None. No read back on 82C55.BASE +3
The Table below shows the I/O register map of the PCI-DIO24, DIO24H and
DIO24H/CTR3. Any differences between versions of the boards are noted. Sections
5.1 through 5.6 provide add itional information on each of these addresses and their
functions.
WRITE FUNCTIONREAD FUNCTIONREGISTER
Interrupt ControlInterrupt StatusBADR1+4C h
BADR1+50 h
User I/O Status (/CTR3 board
only)
8255 REGISTERS
(for all boards)
8254 Counter REGISTERS
(For /CTR3 boards only)
User I/O Control (/CTR3
board only
Output Port A DataInput Port A DataBADR2 + 0
Output Port B DataInput Port B DataBADR2 + 1
Output Port C DataInput Port C DataBADR2 + 2
Control RegisterControl register readbackBADR2 + 3
Ports A & B may be programmed as input or output. Each is written to and read from
in Bytes, although fo r control and monitoring p urposes the individua l bits are more
interesting.
Bit set/reset and bit read functions require that unwanted bits be masked out of reads
and ORed into writes.
12
9
Page 14
5.1 BOARD CONTROL REGISTERS
5.1.2 USER I/O STATUS/CONTROL (PCI-DIO24H/CTR3 only)
BADR1 + 50 (hex)
5.1.1 INTERRUPT STATUS/CONTROL
BADR1 + 4C (hex)
READ/WRITE
0123456731:8
INTxxxPCIINTxx
POL
This register is 32-bits in length. Please note that the remainder of the register's bits
have specific control functions. If you write the Interrupt Status register, please be
sure to read the current status, change only the desired bits and then write the new
status word.
INTE is the Interrupt Enable:
0 = disabled,
1 = enabled (default).
INTPOL is the Interrupt Polarity:
0 = active low (default),
1 = active high.
INT is the Interrupt Status:
0 = interrupt is not active,
1 = interrupt is active.
PCIINT is the PCI Interrupt Enable:
0 = disabled,
1 = enabled (default).
INTEINT-
READ/WRITE
0123456731:8
01OUT0xxxxxx
Though the onbo ard crystal oscillato r output is not brought to the I /O connector, it
may be connected to the clock input of counter 0 by installing a jumper on the board
(between OSC and CLK0 on P2). The on boar d oscillator may be set to 10 MHz or
1 MHz. The OUT0 bit selects which frequency is brought to the jumper pin.
OUT0 = 0, input = 10Mhz
OUT0 = 1, input = 1Mhz.
Bit 0 and one should remain 0 and 1 respectively.
This register is 32-bits in length. Please note that the remainder of the register's bits
have specific control functions. If you write the User I/O Status/Control register,
please be sure to read the current status, change only the desired bits and then write
the new status word.
5.1 82C55 CONTROL & DATA REGISTERS
Each PCI-DIO24 is composed of an 82C55 parallel I/O chip (or a TTL implementation of 8255 mode 0). Each board uses 3 data and one control register and occupies 4
consecutive I/O locations. The PCI-DIO24H/CTR3 uses 4 additional I/O registers to
read and write to the 82C54.
The PCI-DIO24 series boards are easy to program with direct I/O register reads and
writes. A tutorial describing how to go about register I/O is beyond the scope of this
manual. However, it will be covered in most Introduction To Programming books,
available from a bookstore.
10
As alternatives to register level programming, the PCI-DIO24 series of boards is fully
supported by optional Universal Library software as well as most high level data
acquisition and control application packages (e.g. HP Vee or Labtech Notebook).
11
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.