The information contained in this manual is believed to be accurate and reliable. However, Keithley
Instruments, Inc., assumes no responsibility for its use or for any infringements of patents or other rights
of third parties that may result from its use. No license is granted by implication or otherwise under any
patent rights of Keithley Instruments, Inc.
KEITHLEY INSTRUMENTS, INC., SHALL NOT BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
OR CONSEQUENTIAL DAMAGES RELATED TO THE USE OF THIS PRODUCT. THIS
PRODUCT IS NOT DESIGNED WITH COMPONENTS OF A LEVEL OF RELIABILITY
SUITABLE FOR USE IN LIFE SUPPORT OR CRITICAL APPLICATIONS.
Refer to your Keithley Instruments license agreement for specific warranty and liability information.
MetraByte, VTX, and Visual Test Extensions are trademarks of Keithley Instruments, Inc. All other
brand and product names are trademarks or registered trademarks of their respective companies.
All rights reserved. Reproduction or adaptation of any part of this documentation beyond that permitted
by Section 117 of the 1976 United States Copyright Act without permission of the Copyright owner is
unlawful.
Keithley MetraByte Division
Keithley Instruments, Inc.
440 Myles Standish Blvd. Taunton, MA 02780
Telephone: (508) 880-3000 ● FAX: (508) 880-0179
Preface
The DASCard-PIO12 User’s Guide describes how to set up, install, and
program the DASCard-PIO12 digital I/O interface card.
This guide serves data acquisition system designers, engineers,
programmers, and other users responsible for setting up, cabling and
wiring signals to a DASCard-PIO12 in a notebook or desktop computer
with a Type II, PCMCIA (Personal Computer Memory Card International
Association) socket. User are assumed to be familiar with data acquisition
principles, with their applications, and with their computers.
The DASCard-PIO12 User’s Guide is organized as follows:
●Chapter 1 provides an overview of the hardware and descriptions of
features, applications, supporting software, and accessories.
●Chapter 2 provides a block diagram and descriptions of major
features.
●Chapter 3 describes how to unpack, install, and start up the card.
●Chapter 4 describes how to connect accessories.
●Chapter 5 describes how to start up and use the Control Panel.
●Chapter 6 describes programming requirements of the card.
●Chapter 7 describes how to isolate common problems, how to
troubleshoot your system, and how to obtain technical support.
●Appendix A contains DASCard-PIO12 specifications.
●Appendix B contains pin assignments for the main I/O connector of
The DASCard-PIO12 is a digital I/O PC Card that you can use with any
notebook or desktop computer that contains a Type II, PCMCIA
(Personal Computer Memory Card International Association) socket. This
chapter describes features and applications of the DASCard-PIO12,
supporting software, and available accessories.
Major features of DASCard-PIO12 are as follows:
●Contains 24 TTL/NMOS/CMOS-compatible digital I/O lines.
●Provides programmable unidirectional, bidirectional, and strobed I/O
(bidirectional and strobed I/O are not supported by the ASO-PIO
software package).
●Provides an interrupt input line.
●Provides direct interface with a wide range of accessory products,
including instruments, displays, and user-assembled systems.
●Is software- and register-compatible with the Keithley MetraByte
PIO-12, the predecessor product for IBM® PC/XT™, PC AT®, or
equivalent computers that use an ISA (Industry Standard
Architecture) bus.
Features1-1
Applications
Typical applications for the DASCard-PIO12 are as follows:
●Contact closure monitoring
●Digital I/O control
●Alarm monitoring
●Display driving
●Relay control
Supporting Software
The DASCard-PIO12 and industry-standard PIO-12 are software- and
register-compatible. The following software is, therefore, available for
operating a DASCard-PIO12 or a PIO-12:
●ASO-PIO package - This package contains the following programs:
–The PIO Series Function Call Driver and DLLs (Dynamic Link
Libraries) that allow you to write custom programs in Microsoft®
and Borland® C/C++ for Windows™and in Microsoft Visual
Basic™ for Windows. This driver is also required if you use
Visual Test Extensions™, described on page 1-3. Refer to the
online help of the PIO Series Function Call Driver for more
information.
–ASO-PIO Control Panel - The Control Panel (CTLPIO.EXE)
runs under Windows and allows you to perform operations on
DASCard-PIO12 cards without programming. This program also
provides a quick way to test your card and monitor your
operation. Refer to Chapter 5 and to the online help for more
information.
–ASO-PIO configuration utility - This utility allows you to create
configuration files for use with the PIO Series Function Call
Driver. Refer to “Using the Configuration Utility” on page 3-4
and to the online help for more information.
1-2Overview
Accessories
●Keithley MetraByte Enabler utility- The Enabler
(KMENABLE.EXE) is a DOS-based program that requests system
resources for your DASCard-PIO12. Refer to “Loading the Keithley
MetraByte Enabler Utility” on page 3-6 for more information
●Keithley MetraByte diagnostics utility- The diagnostics utility
(KMINFO.EXE for DOS, KMINFOW.EXE for Windows) is a
program that allows you to check the status of your DASCard-PIO12;
refer to “Using the Keithley MetraByte Diagnostics Utility” on page
3-10 for more information.
●Visual Test Extensions (VTX) - This optional Visual Basic custom
control software package helps you write Windows application
programs for the DASCard-PIO12. Refer to the Keithley MetraByte
product catalog for more information.
●Data acquisition and analysis application software - Refer to the
Keithley MetraByte product catalog for information on data
acquisition and analysis software available for the DASCard-PIO12.
The following accessories are available for use with your
DASCard-PIO12:
●SSIO-24 - This accessory is a 24-channel mounting panel for up to
24 solid-state, miniature I/O modules with functions of DC input, DC
output, AC input, and AC output. The SSIO-24 connects to the main
I/O connector of the DASCard-PIO12 cable. This accessory requires
external power (+5 VDC) when used with the DASCard-PIO12.
●ERB-24 - This accessory is a relay board that provides 24
electromechanical double-pole, double-throw relays for controlling
and switching up to 3 A at 120 V
. The ERB-24 connects to the
rms
main I/O connector of the DASCard-PIO12 cable. This accessory has
a built-in power supply requiring 115/230 VAC.
●ERA-01 - This accessory is an electrical relay board containing eight
single-pole, double-throw relays that can switch up to 3 A at 120
V
. The ERA-01 requires external power (+5 VDC) when used with
rms
the DASCard-PIO12.
Accessories1-3
●SRA-01 - This accessory is an 8-channel, solid-state, mounting panel
for industry-standard I/O modules used in sensing and controlling AC
and DC circuits. The SRA-01 requires external power (+5 VDC)
when used with the DASCard-PIO12.
●STP-37 - This accessory is a screw-terminal panel for
general-purpose connections in a compact form factor.
●STA-U is a universal screw-terminal accessory that connects to the
main I/O connector of the DASCard-PIO12 to bring the card’s I/O
signals to convenient screw terminals.
Refer to the Keithley MetraByte catalog or contact your local sales office
for information on obtaining these accessories.
1-4Overview
2
Functional Description
This chapter describes the features and operating characteristics of the
DASCard-PIO12. Figure 2-1 is a block diagram of the DASCard-PIO12.
PA7
Port A
PA0
82C55
PPI
Port B
Port C
PB7
PB0
PC7
PC0
Data
Bus
Buffer
Address
Decoder
PCMCIA Interface
IOR
IOW
PC Bus
Figure 2-1. DASCard-PIO12 Block Diagram
Interrupt
+5 V
COM
I/O
2-1
DASCard-PIO12 features and operating characteristics are described as
follows:
●The DASCard-PIO12 has three TTL/NMOS/CMOS-compatible,
digital I/O ports: port A, port B, and port C. Ports A and B are both
byte-wide (8-bits) and can be inputs or outputs. Port C is also
byte-wide but is usable as two separate 4-bit ports (port C Lower and
port C Upper), which can be an inputs or outputs.
●The DASCard-PIO12 has an interrupt input channel. During startup,
the Keithley MetraByte Enabler program can request any one of the
interrupt levels available on the PC bus.
●The Interrupt Controller of the computer handles interrupts and is set
by the computer BIOS to respond to positive-edge-triggered (low to
high) inputs. You must program the Interrupt Controller to respond to
your application by setting up the corresponding interrupt handler.
●The DASCard-PIO12 decodes 2-bit I/O addresses and communicates
with the PC bus as an 8-bit peripheral. The address map uses four
consecutive I/O addresses. You can install multiple DASCard-PIO12
cards in a computer with each at a different base address.
●The +5 V power level from the computer is available through the
main I/O connector of the DASCard-PIO12 cable. If you plan to use
power from the PC Card, you should consider the power draw of all
system devices and observe current-capacity limits of both the
computer and the card.
2-2Functional Description
Setup and Installation
This chapter contains the information you need to install and use your
DASCard-PIO12.
Assembling Your System
For proper operation of a DASCard-PIO12, your system may require the
following items:
●Notebook or desktop computer with a Type II or Type III, PCMCIA
socket.
●Windows, Version 3.1 or higher, running in Enhanced mode.
Plus, or any other PCMCIA Card and Socket Services (PCMCIA
standard 2.10 or higher). Each of these packages allows a
DASCard-PIO12 to work in your computer and is typically a
DOS-based, terminate-and-stay-resident (TSR) program loaded from
your CONFIG.SYS file.
Many notebook computers are shipped with PCMCIA Card and
Socket Services already installed. Check your computer
documentation or software package for the name of the services and
for compliance with PCMCIA standard 2.10 or higher. If you cannot
establish this compliance, you should obtain and install one of the
PCMCIA Card and Socket Services listed above.
●A Keithley MetraByte Enabler utility (KMENABLE.EXE) and a
Keithley MetraByte diagnostics utility (KMINFO.EXE for DOS and
KMINFOW.EXE for Windows).
3-1
Unpacking and Inspecting Your Card
After opening the shipping carton, perform the following steps to unpack
and inspect your DASCard-PIO12:
1. Carefully remove the card from its plastic case. (Keep the plastic case
for future storage or possible shipping needs.)
2. Inspect the card for signs of damage. If any damage is apparent,
arrange to return the card to the factory; refer to page 7-6 for more
information.
3. Check the remaining contents of your package against the packing
list; report any missing items immediately.
4. If the card and remainder of the package are acceptable, set up the
software and the card. Refer to the following sections for information.
Overview of Installation and Startup
To install and start a DASCard-PIO12, perform the following tasks in the
order shown:
1. Install PCMCIA Card and Socket services, if required. Refer to the
manufacturer’s installation instructions.
2. Install the ASO-PIO software package from Windows, if required.
Refer to “Installing the Software” on page 3-3 for information.
3. If the default configuration of your card does not suit your
application, create a new configuration file. Refer to “Using the
Configuration Utility” on page 3-4 for information.
4. If you are working in Windows, exit to DOS, and load the Keithley
MetraByte Enabler. Refer to “Loading the Keithley MetraByte
Enabler Utility” on page 3-6 for information.
Note: After starting up your computer, you must load the Keithley
MetraByte Enabler before you load Windows and before you install
the card.
3-2Setup and Installation
5. Install your card. Refer to “Installing the Card” on page 3-9 for
information.
6. Check the installation of your card using the Keithley MetraByte
diagnostics utility. Refer to “Using the Keithley MetraByte
Diagnostics Utility” on page 3-10 for information.
7. Test the functions of your card using the Control Panel. Refer to
Chapter 5 for information.
8. Write your application program. If you are using the PIO Series
Function Call Driver, refer to the online help for information. If you
are using VTX, refer to the Visual Test Extensions User’s Guide and
the VTX online help for information.
9. Run your application program.
Installing the Software
To install the ASO-PIO software package, perform the following steps:
1. Make copies of the supplied disks. Use the copies as your working
disks, and store the originals as backups.
2. Insert disk 1 into a drive.
3. Start Windows.
4. From the File menu of the Program Manager group, select Run.
5. Choose Browse to locate the SETUP.EXE file on disk 1, and then
select OK for the Browse and Run panels.
The setup program prompts you for your installation preferences and
for additional disks, as necessary. The program responds to your
entries by creating a directory on the specified drive and copying all
files, expanding any compressed files.
6. When the setup program notifies you that the installation is complete,
review the following files:
–FILES.TXT is a text file listing and describing all the files copied
to the hard disk by the installation program.
–README.TXT is a text file containing information that was
unavailable when this manual was printed.
3-3
Using the Configuration Utility
You need a configuration file to use the Function Call Driver or VTX,
provided in your DASCard-PIO12 software package. The CFGPIO.EXE
configuration utility allows you to create a new configuration file or
modify an existing configuration file. CFGPIO.EXE also allows you to
create a configuration file for multiple PIO devices.
Creating or Modifying a Configuration File
Use CFGPIO.EXE to create or modify a configuration file, as follows:
1. In Windows, select the PIO-Configuration icon in the Keithley PIO
program group.
2. To modify an existing configuration file, select the Open option from
the File menu, select the configuration file (for demonstration
purposes, choose the PIO.CFG file from the ASO-PIO software
package), then go to step 3. To create a new configuration file, go to
step 5.
3. In the PIO Configuration panel, select the DASCard-PIO12 from the
Board Type scroll bar. The default configuration options for the
DASCard-PIO12 are as shown in Table 3-1.
Table 3-1. Default Configuration Options for the
DASCard-PIO12
AttributeOptions
Card nameDASCard-PIO12
Base address (hex)—
Interrupt level—
Port A, B, CL, and CH Input
Combine portsNo
4. Use the Save option in the File menu of the PIO Configuration panel
to save these options in the PIO.CFG file, making this file your
default configuration file for the DASCard-PIO12.
3-4Setup and Installation
5. You can create a new configuration file by modifying the default
configuration values in the PIO Configuration panel and using the
Save As selection from the File menu of the PIO Configuration panel
to save the modified values in a file with a new name. For consistency,
any name you assign to a configuration file should have a .CFG
extension (for example, MYFILE.CFG).
Creating a Configuration File for Multiple PIO Devices
In a laptop computer, CFGPIO.EXE can support a maximum of two
DASCard-PIO12 cards in PCMCIA sockets. In an IBM PC AT (or
equivalent), CFGPIO.EXE can support a maximum of 10 PIO devices.
Up to two of these PIO devices can be DASCard-PIO12 cards in
PCMCIA sockets; the remaining devices can be any of the various PIO
boards in the accessory slots of the computer.
When you are working with multiple PIO boards and cards, you use the
configuration utility to assign each board and card a board number from a
range of 0 to 9. You can assign each of two DASCard-PIO12 cards any
number in this range, so long as you assign a card in PCMCIA socket 0 a
lower board number than a card in PCMCIA socket 1 (if you use just one
DASCard-PIO12, you must place the card in socket 0). Use
CFGPIO.EXE to configure a mix of PIO boards and cards as follows:
1. In Windows, select Run from the Program Manager File menu, use
the Browse button to find CFGPIO.EXE, and choose OK in both the
Browse and Run panels.
2. In the Board No. scroll box of the PIO Configuration panel, select
board number 0.
3. In the Board Type scroll box of the PIO Configuration panel, select
the type of board or card you have designated as board number 0.
4. Modify the configuration options for the board or card designated as
board number 0.
Note: Remember that you must set each PIO board for a different
base address and interrupt level, and that you must enter the base
address and interrupt level for each board in the configuration options
for the corresponding board number (the base address and interrupt
level for a DASCard-PIO12 allocated by the Enabler).
3-5
5. When the configuration options for board number 0 are complete,
repeat steps 2 to 4 for each of the remaining boards/cards.
6. When the configuration options for all boards/cards are complete, use
the Save As selection from the File menu of the PIO Configuration
panel to save the options in a new or existing configuration file.
7. To exit the configuration utility, choose the Exit option on the PIO
Configuration panel.
Loading the Keithley MetraByte Enabler Utility
A PC Card enabler is a TSR whose function is to set up compatibility
between the card and the computer bus by requesting PCMCIA Card
Services to allocate certain resources for the card. These resources
include a base address and an interrupt level for the DASCard-PIO12.
Most computers equipped to accept PC Cards contain a generic enabler
that loads automatically upon startup. However, PC Card manufacturers
often provide customized enablers to perform tasks a generic enabler
might be unable to handle. Keithley MetraByte provides
KMENABLE.EXE, a customized enabler designed to recognize and
respond specifically to Keithley MetraByte PC Cards. You must use the
Keithley MetraByte Enabler for your DASCard-PIO12 if you intend to
use VTX, the Control Panel, or the PIO Series Function Call Driver.
To obtain a base address and interrupt level that are not in use by another
device in your system, perform the following steps to load the Keithley
MetraByte Enabler:
1. Turn power to your computer off.
2. If your DASCard-PIO12 is already installed, remove it from its
socket.
Note: To prevent conflicts with the generic enabler or with Windows,
do not install your card or load Windows until after you load the
Keithley MetraByte Enabler.
3. Return power to the computer.
3-6Setup and Installation
4. If your PCMCIA Card Services allow you to exclude resources from
resource allocation, make sure you exclude any base addresses and
interrupt levels in use by other devices in your system.
5. If your PCMCIA Card Services allow you to reserve system
resources, make sure that you reserve a base address and interrupt
level not in use by other devices in your system.
6. Table 3-2 lists the command-line switch options for use with the
Enabler. Use these switch options if the default values for base
address and interrupt level are already assigned to another device.
7. If the default base addresses and interrupt levels shown in Table 3-2
are available, go to step 9.
8. If the default base addresses and interrupt levels shown in Table 3-2
are unavailable, go to step 10.
9. Load the Keithley MetraByte Enabler using the following statement
at the DOS prompt, and then go to step 11:
KMENABLE
Note: If you prefer to start the Keithley MetraByte Enabler
automatically upon power-up, enter the KMENABLE command in
your computer’s AUTOEXEC.BAT file. Remember, though, to
remove your card before power-up.
10. Load the Keithley MetraByte Enabler using one or more of the
command-line switch options listed in Table 3-2.
Table 3-2. Switch Options for the Enabler
Switch SyntaxDescription
/?Displays syntax information.
/BA0:baseaddress Uses the value you enter for baseaddress to specify
a base address for card 0. Make sure that &H
precedes hexadecimal numbers. If you do not use
this switch, the Enabler tries to use a default base
address of 300h.
3-7
Table 3-2. Switch Options for the Enabler (cont.)
Switch SyntaxDescription
/BA1:baseaddressUses the value you enter for baseaddress to specify
a base address for card 1. Make sure that &H
precedes hexadecimal numbers. If you do not use
this switch, the Enabler tries to use a default base
address of 308h.
/I0:intlevelUses the value you enter for intlevel to specify an
interrupt level for card 0. If you do not use this
switch, the Enabler tries to use a default level of 5.
If you use a value of −1, the Enabler does not
allocate any interrupt level.
/I1:intlevelUses the value you enter for intlevel to specify an
interrupt level for card 1. If you do not use this
switch, the Enabler tries to use a default level of 7.
If you use a value of −1, the Enabler does not
allocate any interrupt level.
/MEM0:memaddress Not applicable.
/MEM1:memaddress Not applicable.
/NORETRY
/UUnloads the Enabler from computer memory.
Notes
1
An error detected by the Enabler is displayed when you run the diagnostics
utility (see page 3-10). If the error is displayed in one of the following 4-digit
formats, the error indicates an allocation problem with the named resource:
8xxx indicates base address; 4xxx indicates interrupt level; Cxxx indicates
memory.
The Enabler detects an error1 if the base address or
interrupt level you specify is in use by another
Keithley MetraByte PC Card. If you do not use this
option and specify a resource that is assigned to
another Keithley MetraByte PC Card, the Enabler
automatically selects the next available resource.
For example, if the default assignments for card 0 are appropriate but
you want to change the assignments for card 1, enter a line similar to
the following at the DOS prompt:
KMENABLE /BA1:&H310 /I1:11
3-8Setup and Installation
As another example, if you want to change a base address and/or
interrupt level without restarting your computer, you can remove the
Keithley MetraByte Enabler by entering the following statement at
the DOS prompt:
KMENABLE /U
Then (after removing the card and exiting Windows), you can reload
the Enabler using the command-line switch options to specify a new
base address, and/or interrupt level. Replace the card after you load
the Enabler.
Still another example uses the /NORETRY switch to make sure the
same base address and interrupt level are allocated each and every
time the card is inserted. This switch allows the use of older PIO-12
boards as well as register-level programming. Use this switch with a
command similar to the following:
KMENABLE /BA1:&H310 /I1:11 /NORETRY
Note: If you use the PCMCIA software to reserve system resources
and then use a switch option to specify a base address or interrupt
level that was not reserved, the value you specify is ignored.
11. To determine whether the Enabler recognizes your DASCard-PIO12
and whether suitable resources were allocated, install your card (see
the next section) and run the diagnostics utility (see page 3-10).
Installing the Card
To install a DASCard-PIO12, perform the following steps:
1. Select the appropriate Type II, PCMCIA socket and remove its cover.
2. Insert the card into the selected socket; the card is labeled to show the
direction of insertion and keyed to allow only one way of insertion.
On some computers, one or more beeps indicate that the card is
installed correctly.
If you are using two DASCard-PIO12 cards, the Keithley MetraByte
Enabler recognizes the first card you install as card 0 and the second
as card 1, regardless of socket numbers.
3-9
3. On most notebook computers, you can hot-swap PC Cards; you are
not required to turn computer power off when installing or removing
a card. A computer that does not conform to the ExCA (exchange
card architecture) Specification cannot support hot swapping; you
must turn on the PCMCIA socket with a software utility each time
you insert a card. The socket turn-on utility should be described in
your computer documentation.
4. Make sure the card is ready for proper operation by running the
diagnostics utility; refer to the following section.
When your DASCard-PIO12 is properly installed, you can attach
accessories and wire signals to the card; refer to Chapter 4 for
information.
Using the Keithley MetraByte Diagnostics Utility
The diagnostics utility (KMINFO.EXE for DOS or KMINFOW.EXE for
Windows) allows you to check the status of your DASCard-PIO12 after
startup and during operation. To check the operation of your
DASCard-PIO12 while running in DOS, enter the following command at
the DOS prompt:
KMINFO
To check the operation of your DASCard-PIO12 while running in
Windows, use KMINFOW.EXE as follows:
1. Choose Run from the File menu of the Program Manager panel to
bring up the Run panel.
2. Choose Browse to locate and select KMINFOW.EXE.
3. Choose OK on both the Browse and Run panels to run the utility.
The diagnostics utility displays the following information:
●The PCMCIA Card and Socket Services that are installed
●Whether the Keithley MetraByte Enabler is installed
3-10Setup and Installation
●The following information for each socket:
–The manufacturer of the installed card
–The card type
–Whether the card is enabled
–If the card is enabled, the base address and interrupt level
–If the card is not enabled, Card and Socket Services and the card
identification
Note: The diagnostics utility displays a base address as a number
preceded by 0x. The 0x signifies a hexadecimal number. For example,
0x350 is 350h.
If any of the fields in the diagnostics display are missing or if an error is
displayed, the card is improperly configured. Refer to Chapter 7 for
troubleshooting information.
An error displayed in one of the following 4-digit formats indicates an
allocation problem with the named resource: 8xxx indicates base address;
4xxx indicates interrupt level; Cxxx indicates memory.
3-11
4
Cabling and Wiring
This chapter describes how to wire accessories and signals to your
DASCard-PIO12. The DASCard-PIO12 and I/O cable appear as shown in
Figure 4-1.
To PCMCIA
socket in
desktop or
notebook
computer
37-pin main I/O
connector on
DASCard-PIO12
cable to
accessories
DASCard-PIO12
Figure 4-1. DASCard-PIO12 and Attached I/O Cable
The main I/O connector of the DASCard-PIO12 cable is a female, 37-pin,
D type. Pin assignments for this connector are shown in Appendix B.
4-1
Connecting an SSIO-24, ERB-24, ERA-01, or SRA-01
The following accessories attach directly to the I/O cable of a
DASCard-PIO12, as shown in Figure 4-2:
●SSIO-24
●ERB-24
●ERA-01
●SRA-01
Note: Each of these accessories requires external power when connected
to a DASCard-PIO12.
DASCard-PIO12
SSIO-24, ERB-24,
ERA-01, or
SRA-01
Figure 4-2. Attaching an SSIO-24, an ERB-24, an ERA-01, or an
SRA-01 to a DASCard-PIO12 Cable
4-2Cabling and Wiring
Connecting an STP-37 or STA-U
Note:
Screw terminals
for CJC are not
used with
DASCard-PIO12
The STP-37 and STA-U are screw-terminal panels that attach to the main
I/O connector of a DASCard-PIO12 cable, as shown in Figure 4-3. The
STP-37/C is the STP-37 with a protective bottom cover. While Figure 4-3
shows an STP-37 or STP-37/C, the STA-U attaches to the
DASCard-PIO12 cable in exactly the same manner.
STP-37 or
STP-37/C
Figure 4-3. Connecting an STP-37 or STP-37/C to a DASCard-PIO12
DASCard-PIO12
The STP-37 and STP-37/C appear as shown in Figure 4-4.
Figure 4-4. Panel Layout of STP-37 and STP-37/C
Connecting an STP-37 or STA-U4-3
Connecting Special-Purpose I/O Circuits
The following subsections show commonly used circuits for the inputs or
outputs of a DASCard-PIO12.
Connecting a Contact-Closure Monitor to an Input
Figure 4-5 shows a circuit for monitoring contact closure at a
DASCard-PIO12 input.
+5 V
10 kΩ
Switch
Digital
Common
GND
Digital
Input
Figure 4-5. Contact-Closure Monitor for a DASCard-PIO12 Input
DASCard-PIO12
#n
Note: The circuit in Figure 4-5 does not contain a debounce circuit.
Debounce can be handled by your application program or by the circuit in
the following subsection.
Connecting an Input to a Debounce Circuit
While debounce can be handled by your application program, Figure 4-6
shows a debounce circuit you can use at an input of a DASCard-PIO12.
+5 V
10 kΩ
10 kΩ
&
To Digital Input
of
DASCard-PIO12
&
Digital
Common
GND
Figure 4-6. Debounce Circuit for a DASCard-PIO12 Input
TTL
Compatible
AND Gate
Connecting an Output to Darlington NPN for Relay Control
You can achieve relay control at an output of a DASCard-PIO12 using a
Darlington NPN transistor, as shown in Figure 4-7.
Relay
Digital
Output
DASCard-PIO12
#n
Darlington
NPN
Transistor
1 kΩ
Min.
Digital
Common
GND
Surge
Protection
Diode
+
−
To Relay
DC Power
Supply
Figure 4-7. Darlington NPN Relay Control for an Output of a
DASCard-PIO12
Connecting Special-Purpose I/O Circuits4-5
5
Control Panel
The Control Panel is a utility program for testing the functions of your
DASCard-PIO12; this utility is available for Windows as CTLPIO.EXE.
The Control Panel is a part of the ASO-PIO software package.
To use the Control Panel, perform the following steps:
1. From the Windows Program Manager panel, select the Control Panel
icon in the Keithley PIO program group.
2. After the Control Panel starts, enter the name of a configuration file, a
card type, and a socket number.
The remaining portion of the Control Panel contains the controls that
allow you to transfer and monitor data.
3. To set up and perform an operation, select the appropriate buttons. To
obtain information on the setup and performance of an operation, use
the Help option in the Control Panel menu.
4. When you finish using the Control Panel, select the Exit option from
the File menu to terminate the program.
5-1
6
Programming
Note: You can ignore this chapter if you are using ASO-PIO software. If
you are not using ASO-PIO software (if you are programming in DOS, or
if you are using existing software for the older PIO-12 board, or if you are
doing register-level programming), you must use the /NORETRY switch
(see Table 3-2 on page 3-7) to make sure you get the same base address
and interrupt level each and every time you install your card.
DASCard-PIO12 programmability is provided through the card's 82C55
Programmable Peripheral Interface (PPI) integrated circuit. The 82C55
PPI provides 24 digital I/O lines, which the DASCard-PIO12 uses for the
following three ports:
●Port A (abbreviated PA) consists of one 8-bit data output latch/buffer
and one 8-bit data input latch.
●Port B (PB) consists of one 8-bit data output latch/buffer and one
8-bit data input buffer.
●Port C (PC) consists of one 8-bit data output latch/buffer and one
8-bit data input buffer. This port can also be used as two 4-bit ports:
PC Upper (PC4 to PC7) and PC Lower (PC0 to PC3).
Programming the DASCard-PIO12 involves two fundamental tasks:
1. Setting the port configuration.
2. Reading/writing data from/to the ports.
These tasks are discussed in the sections that follow.
6-1
Note: If you need more detailed information on the functionality of the
82C55 PPI, please contact an Intel® or Toshiba® representative for a
complete data sheet. The contact number for Intel technical support is
(800)628-8686.
Setting the Port Configuration
You configure each port or half-port as an input or an output according to
the value of the control word in the PPI control register. The control word
is a 1-byte word programmed at Base Address +3h. Refer to Table 6-1 for
the complete 82C55 PPI address map.
Table 6-1. 82C55 PPI Address Map
AddressFunctionType
Base Address +0hPort A (PA)Read/Write
Base Address +1hPort B (PB)Read/Write
Base Address +2hPort C (PC)Read/Write
Base Address +3hControl WordWrite only
The control word also specifies one of the following three operating
modes (for a complete description of the PPI operating modes, refer to the
Intel 82C55 data sheet):
●Mode 0 - Basic I/O; all ports are I/O ports.
●Mode 1 - Strobed I/O; part of Port C controls data transfer.
●Mode 2 - Bidirectional I/O on Port A only; part of Port C controls
data transfer.
A power-up or reset automatically configures all ports as inputs. This
configuration remains intact until changed by a write to the control
register. The initialization section of your program should set the port
configuration. Table 6-2 illustrates how the port configuration is derived
from the control word.
6-2Programming
Table 6-2. Derivation of Port Configuration from Control Word
Bit
Bit #
SettingConfiguration
70
1
6 and 500
01
1X
40
1
30
1
20
1
10
1
00
1
Bit set/reset mode for PC0 to PC7
Mode set active for PC0 to PC7
Mode 0 for PA4 to PA7 and PC4 to PC7
Mode 1 for PA4 to PA7 and PC4 to PC7
Mode 2 for PA4 to PA7 and PC4 to PC7
PA output
PA input
PC4 to PC7 output
PC4 to PC7 input
PB0 to PB3 and PC0 to PC3 output
PB0 to PB3 and PC0 to PC3 input
PB output
PB input
PC0 to PC3 output
PC0 to PC3 input
Table 6-3 summarizes information from the Intel peripheral data book on
control words and their port directions for mode 0.
A noteworthy characteristic of the 82C55 PPI is that all port registers are
cleared by a write to the control register. Consequently, if your program
intends to repeatedly change the port configuration, you may need to
make provisions for restoring data to cleared ports.
Reading/Writing Data from/to the Ports
The examples in this section use the QuickBasic programming language
to illustrate some common programming tasks.
Writing to the Control Register
The following code configures all of the ports as outputs:
OUT BADDR +3, &H80’Sets all ports to outputs.
6-4Programming
Performing Fundamental I/O Operations
The following code performs fundamental I/O operations:
OUT BADDR, &H22’Sends 22 Hex to Port A.
OUT BADDR +1, 99’Sends 99 to Port B.
PRINT INP(BADDR +1)’Reads and displays
’Port B data in decimal.
PRINT HEX$(INP(BADDR))’Reads and displays
’Port A data in hex.
Reading BCD Data
The following code reads 2-digit BCD (Binary Coded Decimal) data:
BCD% = INP(BADDR)’Read data.
’Convert to decimal.
BCD% = (BCD% AND &HF0)*10/16 + (BCD% AND &H0F)
Performing Bit Operations
Bit operations use the Boolean operators OR, AND, XOR, EQV, IMP, and
NOT.
The following code sets bit 3 on Port A to 1 without disturbing the other
bits:
A% = INP(BADDR)’Read port A.
OUT BADDR, (A% OR 2^3)’OR bit 3 and write to
’Port A.
The following code clears bit 7:
A% = INP(BADDR)’Read port A.
’AND the inverse of bit 7,
’effectively masking it
’to an OFF state.
OUT BADDR, (A% AND NOT(2^7))
Reading/Writing Data from/to the Ports6-5
The following code illustrates the use of the BASIC WAIT command to
wait for a particular condition on Port C:
WAIT BADDR +2, N%, J%
The result of an XOR on the data read at Port BADDR +2 (Port C in this
example) and J% is ANDed with N%. If the result is 0, the program loops
back and reads the port again; otherwise execution continues with the
next line.
6-6Programming
Troubleshooting
If your DASCard-PIO12 is not operating properly, use the information in
this chapter to isolate the problem. If the problem appears serious enough
to warrant technical support, refer to page 7-6 for information on how to
contact an applications engineer.
Identifying Symptoms and Possible Causes
Table 7-1 lists general symptoms and possible solutions for problems
with a DASCard-PIO12.
7
Table 7-1. Troubleshooting Information
SymptomPossible CausePossible Solution
Data appears to be
invalid
Card does not work
properly
An open connection exists.
Multiple devices in your system
are using the same interrupt level
and base address.
You used CtrlAltDel to restart
your computer. (On some
computers, CtrlAltDel does not
reset the socket controller.)
Check wiring to screw terminals.
Use the diagnostics utility to determine
the system resources used; refer to
page 3-10.
Assign a different system resource to the
other device.
Remove the card and restart your
computer by using the reset button or by
turning power OFF and then back ON.
Reload the Enabler, then replace the
card. Refer to your computer
documentation.
7-1
Table 7-1. Troubleshooting Information (cont.)
SymptomPossible CausePossible Solution
Diagnostics utility
indicates that the
card is not installed
correctly
PCMCIA Card and Socket
Services are not installed.
PCMCIA Card and Socket
Services are not compliant with
PCMCIA standard 2.10 or higher.
The Enabler is not installed.
You loaded the Enabler with a
DASCard-PIO12 already
installed; the Enabler does not
recognize the card.
Refer to the documentation supplied
with your computer for information on
installing PCMCIA Card and Socket
Services. If Card and Socket Services
were not supplied with your computer,
contact your local Keithley MetraByte
sales office for information on obtaining
them.
Contact your computer manufacturer for
information on upgrading to PCMCIA
standard 2.10. If PCMCIA Card and
Socket Services were not supplied with
your computer, contact your local
Keithley MetraByte sales office for
information on obtaining them.
Exit Windows and try loading the
Enabler (KMENABLE.EXE) again from
DOS. Refer to page 3-6.
Remove the DASCard-PIO12 and turn
power OFF. Turn power back ON, load
the Keithley MetraByte Enabler
(KMENABLE.EXE), and then re-install
the card. If your hardware does not
support hot-swapping, you may have to
manually reapply power to the card
using the appropriate PCMCIA Card
Services function.
PCMCIA Card Services
recognizes a DASCard-PIO12 as
another type of device and
allocates resources without
providing the Keithley MetraByte
Enabler with information about
the allocated resources.
7-2Troubleshooting
Remove the DASCard-PIO12 and turn
power OFF. Turn power back ON, load
the Keithley MetraByte Enabler
(KMENABLE.EXE), and then reinstall
the card. If your hardware does not
support hot-swapping, you may have to
manually reapply power to the card
using the appropriate PCMCIA Card
Services function.
Table 7-1. Troubleshooting Information (cont.)
SymptomPossible CausePossible Solution
Card does not
respond
PCMCIA Card Services cannot
check the interrupt level and base
address assigned to non-PCMCIA
devices and may have selected an
interrupt level or base address that
is being used by another device,
such as a network card, a mouse,
or a sound card.
Use the diagnostics utility to determine
the system resources selected by
PCMCIA Card Services; refer to
page 3-10. If the interrupt level or base
address is being used by another device,
load the Enabler again using
command-line options to select another
interrupt level or base address; refer to
page 3-6.
If your PCMCIA Card Services allow
you to reserve system resources when
you install the PCMCIA software, make
sure that you reserve an unused interrupt
level or base address. Refer to the
documentation supplied with your
PCMCIA Card and Socket Services for
information.
Assign another interrupt level or base
address to the other device.
Available interrupt levels depend on the
installed devices. Typically, base
addresses 300h to 377h are available.
The card is not inserted correctly
in the PCMCIA socket.
The card is damaged.
Check installation. Make sure that you
have inserted the card in a Type II
PCMCIA socket (a Type II card also
works in a Type III socket). Remove the
card and insert again. If your hardware
does not support hot-swapping, you may
have to manually re-apply power to the
card using the appropriate PCMCIA
Card Services function.
Contact the Keithley MetraByte for
technical support; refer to page 7-6.
7-3
Table 7-1. Troubleshooting Information (cont.)
SymptomPossible CausePossible Solution
An application
program written
using the
DASCard-PIO12
Function Call
Driver does not run
properly
Mouse does not
work properly or
interferes with other
card operations
Intermittent
operation
System lockupA timing error occurred.Remove the card and restart your
The Keithley MetraByte Enabler
(KMENABLE.EXE) did not
make your card’s base address
and interrupt level available to the
DASCard-PIO12 Function Call
Driver.
PCMCIA Card Services may
have selected an interrupt level or
base address that is being used by
the mouse.
Vibrations or loose connections
exist.
Remove the DASCard-PIO12 and turn
power OFF. Turn power back ON, load
the Keithley MetraByte Enabler
(KMENABLE.EXE), and then reinstall
the card. If your hardware does not
support hot-swapping, you may have to
manually reapply power to the card
using the appropriate PCMCIA Card
Services function.
Use the diagnostics utility
(KMINFO.EXE or KMINFOW.EXE) to
determine the system resources used;
refer to page 3-10.
Assign a different system resource to the
mouse.
Reserve unused system resources when
you install the PCMCIA software, if
possible.
Cushion source of vibration and tighten
connections.
computer . Reload the Enabler, then
replace the card.
If you cannot identify the problem using the information in Table 7-1,
refer to the next section to determine whether the problem is in the
computer or in the DASCard-PIO12.
7-4Troubleshooting
Testing the Card and the Computer
To determine whether the problem is in the computer or in the
DASCard-PIO12, perform the following steps:
1. Remove power connections to the computer.
2. Unplug the accessory cable from the DASCard-PIO12, keeping the
connections intact on the accessory.
3. Remove the DASCard-PIO12 from the computer and visually check
for damage. If a card is obviously damaged, refer to page 7-6 for
information on returning the card.
4. With the DASCard-PIO12 removed from the computer, check the
computer for proper operation. Power up the computer and perform
any necessary diagnostics.
If you have another DASCard-PIO12 that is functional, refer to the next
section to determine whether the problem is in the PCMCIA socket or in
the I/O connections. If you do not have another card, refer to page 7-6 for
information on how to contact an applications engineer.
Testing the PCMCIA Socket and I/O Connections
If the computer is operating properly, perform the following steps to
determine whether the problem is in the socket or in the I/O connections:
1. Install a DASCard-PIO12 that is functional. Do not make any I/O
connections.
2. Apply computer power and check operation of the functional card.
This test checks the socket. If you are using two DASCard-PIO12
cards, check the other socket, also.
3. If the sockets are functional, check the I/O connections. Connect the
accessories, one at a time, and check operation.
4. If operation is normal, the problem is in the DASCard-PIO12
originally in the computer.
5. If you cannot isolate the problem, refer to the next section for
instructions on getting technical support.
7-5
Technical Support
Before returning any equipment for repair, call the Keithley MetraByte
Applications Engineering Department at:
An applications engineer will help you diagnose and resolve your
problem over the telephone. Please have the following information
available before you call:
DASCard-PIO12Serial #_____________________
ComputerManufacturer_____________________
Operating systemDOS version_____________________
PCMCIA Card and Type_____________________
Socket ServicesVersion_____________________
Software packageName_____________________
If a telephone resolution is not possible, the applications engineer will
issue you a Return Material Authorization (RMA) number and ask you to
return the equipment. Include the RMA number with any documentation
regarding the equipment.
When returning equipment for repair, include the following information:
●Your name, address, and telephone number.
●The invoice or order number and date of equipment purchase.
Note: If you are submitting your equipment for repair under warranty,
you must include the invoice number and date of purchase.
7-7
A
Specifications
Inputs and outputs of the DASCard-PIO12 are TTL/DTL-compatible.
Outputs can drive one standard TTL (74 series) load or four LSTTL
(74LS) loads. CMOS compatibility can be achieved by connecting a
10 kΩ pull-up resistor from the DASCard-PIO12 output to +5 V. Table
A-1 and Table A-3 list DASCard-PIO12 specifications.
Table A-1. Input and Output Specifications
Logic Inputs and OutputsMinimumMaximum
Input logic low voltage−0.5 V0.8 V
Input logic high voltage2.2 V5.0 V
Input and interrupt input current
for the PA, PB, and PC ports
(0 < V
Output sink current
(VOL = 0.45 V)
Output high voltage
(IOH = −400 µA)
Output high voltage
((IOH = −100 µA)
Darlington drive current
V
R
Notes
1
Applied for optional eight I/O terminals in port B and port C.
= 1.5 V
EXT
= 1.1 kΩ
EXT
IN
< 5 V)
1
−10 µA10 µA
2.5 mA—
24 V—
4.2 V—
−1.0 mA−5 mA
A-1
Table A-2. Power Requirements
FeatureSpecification
+5 V static21 mA maximum
+5 V operating26 mA maximum
Table A-3. Environmental Specifications
FeatureSpecification
Operating temperature range0 to 50˚C
Storage temperature range−40 to 100˚C
Humidity0 to 90% non-condensing
DimensionsComply with PCMCIA Type
II (5.0 mm), standard 2.1
Weight4 oz. (113 g)
A-2Specifications
B
Connector Pin Assignments
The connection between an external I/O device and the DASCard-PIO12
is made at the main I/O connector on the DASCard cable, which is a
standard 37-pin, D-type female connector. Figure B-1 illustrates pin
assignments of the main I/O connector on the DASCard cable.
STP-37 or STP-37/C 4-3
connector, main I/O 2-2, 4-1, B-1
contact-closure monitor 4-4
control byte 6-2
Control Panel 1-2, 5-1
control word 6-2
creating a configuration file 3-4
D
Darlington NPN relay control 4-5
data input latch 6-1
debounce circuit 4-5
default configuration file 3-4
diagnostics utility 1-3, 3-10
digital I/O ports 2-2
C
cable, DASCard-PIO12 I/O 4-1
cabling and wiring 4-1
card
installation 3-9
task order for installation and startup 3-2
unpacking and inspecting 3-2