
Chapter 6 Programming
©
National Instruments Corporation 6-13 PCI-DIO-96 User Manual
At the digital I/O connector, port C has the pin assignments shown in
Figure 6-3 when in mode 1 input. Notice that the status of STBA* and
the status of STBB* are not included in the port C status word.
Figure 6-3. Port C Pin Assignments on I/O Connector when Port C Configured
for Mode 1 Input
Mode 1 Strobed Input Programming ExampleThe following example shows how to configure PPI A for mode 1
input.
Write (8255Cnfg, 0xB0) Set mode 1—port A is an input.
Loop until IBFA (PC5) is set, indicating that data is
available in port A to be read
Read (PortA) Now, read the data from port A
Mode 1–Strobed OutputNote: For mode 1 examples, you must configure the don’t care bits appropriately
in the control word if you want to use the other ports in combination with
the example.
The control word written to the Configuration Register to configure
port A for output in mode 1 is shown in Figure 6-4. You can use bits
PC4 and PC5 of port C as extra input or output lines.
PC7 I/O
PC6 I/O
PC5 IBFA
PC4 STBA*
PC3 INTRA
PC2 STBB*
PC1 IBFB
PC0 INTRB
Group A
Group B