
Appendix B
Register-Level Programming
©
National Instruments Corporation
B-7
DAQCard-DIO-24 User Manual
Development Kit (available from Apple through APDA), which
explains how to interface with the Apple PC Card Manager
software that is part of your PC Card expansion interface. Request
a configuration and an I/O window. In the configuration, the
configuration index should be set to 01 hex for normal operation.
After you activate the card, you are ready to configure the
DAQCard-DIO-24 for digital I/O. The following section explains how
to set the registers for different operations.
Programming Considerations for the 82C55A
82C55A Modes of Operation
The three basic modes of operation for the 82C55A are as follows:
•
Mode 0—Basic I/O
•
Mode 1—Strobed I/O
•
Mode 2—Bidirectional bus
The three ports on the 82C55A are arranged into two groups—group A
and group B. Group A contains one 8-bit data port (port A) and the
upper nibble of port C. Group B contains one 8-bit data port (port B)
and the lower nibble of port C.
Note:
When group A is in mode 1 or 2, it uses one port C bit (PC3) of group B as
an interrupt line.
The 82C55A also has a single bit set/reset feature for port C. The 8-bit
control word also programs this function. For additional information,
refer to Appendix C, OKI 82C55A Data Sheet.
Mode 0
Mode 0 can be used for simple input and output operations for each of
the ports. No handshaking is required; data is simply written to or read
from a selected port.