Copyright 1997 CONTEC Co., LTD. ALL RIGHTS RESERVED
No part of this document may be copied or reproduced in any form
by any means without prior written consent of CONTEC Co., LTD.
CONTEC Co., LTD. makes no commitment to update or keep
current the information contained in this document. The
information in this document is subject to change without notice.
All relevant issues have been considered in the preparation of this
document. Should you notice an omission or any questionable
item in this document, please feel free to notify CONTEC Co.,
LTD.
Regardless of the foregoing statement, CONTEC assumes no
responsibility for any errors that may appear in this document nor
for results obtained by the user as a result of using this product.
Trademarks
MS, Microsoft, MS-DOS and Windows are trademarks of Microsoft
Corporation. Other brand and product names are trademarks of
their respective holder.
CNT24-4(PCI)
i
Page 3
Product Configuration
- CNT24-4(PCI) Board…1
- CNT24-4(PCI) Setup Disk (3.5inch/1.44MB)…1
- User's Guide (this Booklet)…1
Unpacking:
This card is specially packed in an anti-static bag to prevent damage
in shipping.
Check the contents to make sure that you have everything listed
above. If you do not have all the items, contact your distributor
or CONTEC group office where you purchased.
Note!
Do not remove the board from its protective packaging until the
computer case is open and ready for installation. Electrical static
can cause damage to electrical components.
ii
CNT24-4(PCI)
Page 4
Table of Contents
Copyright........................................................................... i
Trademarks........................................................................ i
Thank you for purchasing the CNT24-4(PCI).
The CNT24-4(PCI) is the PCI bus compatible. This board is
plugged into a PCI bus expansion slot on the motherboard in the
personal computer or into a PCI bus unit. You should read this
manual carefully to construct your system with the board by
creating its application programs and connecting the required
external devices to the board.
Features
- One board enables 24 bit up/down counts for four channels.
- Counts two phase signals from devices like a rotary encoder or a
linear gauge.
- Photocoupler insulated input or TTL level input for each channel.
- Generates interrupts or outputs signals by matching the count
value of each channel with the value set by the user.
- Periodically generates an interrupt using an internal
programmable timer.
- Each channel has a general input signal (including photocoupler
and TTL input).
Introduction
CNT24-4(PCI)
1
Page 11
Introduction
Limited Three-Year Warranty
CONTEC Interface boards are warranted by CONTEC Co., LTD. to
be free from defects in material and workmanship for up to three
years from the date of purchase by the original purchaser.
Repair will be free of charge only when this device is returned
freight prepaid with a copy of the original invoice and a Return
Merchandise Authorization to the distributor or the CONTEC group
office, from which it was purchased.
This warranty is not applicable for scratches or normal wear, but
only for the electronic circuitry and original boards. The warranty
is not applicable if the device has been tampered with or damaged
through abuse, mistreatment, neglect, or unreasonable use, or if the
original invoice is not included, in which case repairs will be
considered beyond the warranty policy.
How to Obtain Service
For replacement or repair, return the device freight prepaid, with a
copy of the original invoice. Please obtain a Return Merchandise
Authorization Number (RMA) from the CONTEC group office
where you purchased before returning any product.
2
* No product will be accepted by CONTEC group without the
RMA number.
Liability
The obligation of the warrantor is solely to repair or replace the
product. In no event will the warrantor be liable for any incidental
or consequential damages due to such defect or consequences that
arise from inexperienced usage, misuse, or malfunction of this
device.
CNT24-4(PCI)
Page 12
About the Manual
This manual consists of the following chapters:
Chapter 1Introduction
Chapter 2Setup
This chapter describes the procedures for setting up
the CNT24-4(PCI) board and setting its switches.
Chapter 3Connecting the External Devices
This chapter explains how to connect external devices
to the board and gives notes on connecting them.
Chapter 4I/O Ports and Registers
This chapter provides the assignment and definitions
of each I/O port bit used the board.
Chapter 5Specifications
This chapter summarizes the hardware specifications
of the board and provides circuit block diagrams.
Chapter 6Index
Introduction
CNT24-4(PCI)
3
Page 13
Introduction
4
CNT24-4(PCI)
Page 14
2. Setup
Component Locations
Figure 2.1. shows the names of major parts on the CNT24-4(PCI)
board.
Note that the switch setting shown below is the factory default.
• Interface connector
for TTL level input (CN2)
• Jumper for interrupt signal
resource settings
JP1
INT
USE
1 2 3
NOT USE
Setup
CNT24-4(PCI)
• Interface connector for
photocoupler resistance input
(CN1)
• BOARD ID Setting Switch
Figure 2.1. Component Locations
8
9
7
A
B
6
5
C
4
D
3
E
2
F
1
0
SW1
BOARD ID
JP1
BOARD ID
SW1
CNT24-4(PCI)
5
Page 15
Setup
Setting the Board ID
If you install two or more CNT24-4(PCI) boards on one personal
computer, set their respective board IDs to distinguish them.
Assign a different value to each of the boards.
The board IDs from 0 to F can be set to identify up to sixteen
boards.
If only one board is used, the original factory setting (Board ID = 0)
should be used.
Setting procedure
To set the board ID, use the rotary switch on the board. Turn the
SW1 knob to set the board ID as shown below.
8
9
7
A
6
B
5
C
4
D
3
E
2
F
1
0
SW1
BOARD ID
( Same for match output :
BOARD ID = 0 )
Figure 2.2. Board ID Settings (SW1)
6
CNT24-4(PCI)
Page 16
Setting the Interrupt Use
If you don't use the Interrupt function, to save the Interrupt
resources of PC, you can let recognize to the PC the CNT24-4(PCI)
as no-Interrupt function boards.
In case of interrupt use, this board is assigned the interrupt level
from PC.
Setup
Setup when interrupt is used
JP1
INT
USE
(Factory setting)
NOT USE
Setup when interrupt is not used
JP1
INT
USE
NOT USE
1 2 31 2 3
Figure 2.3. Setting the Interrupt Use
CNT24-4(PCI)
7
Page 17
Setup
Setting up the Board
(For Use under MS-DOS or Windows 3.1)
The board setup method for the CNT24-4(PCI) is different
depending on each OS. Set up the board using the appropriate
method depending on the OS used. This section describes the
procedure and notes for using the board under MS-DOS or
Windows 3.1.
Procedure
(1) Set the board ID.
(2) Be sure to check that the personal computer is off, then plug
the board into a PCI bus slot in the personal computer.
(3) Turn the personal computer on to start up MS-DOS.
(4) Setting up the board is completed when MS-DOS gets and
running. When setting up the board has been completed,
be sure to check the assigned resources.
Checking resources
Before operating the CNT24-4(PCI) board, be sure to check the
personal computer resources (I/O addresses and interrupt level)
assigned to the board. For PCI compatible (Plug and Play
compliant) boards, free resources among the personal computer
resources are assigned automatically upon activation of the personal
computer. Follow the steps below to check the assigned resources.
(1) Run the resource check program "CNTPCI.EXE" stored in the
DOS directory on the supplied floppy disk (FD).
(2) Check the I/O addresses and interrupt level (IRQ) displayed on
the screen.
Once the CNT24-4(PCI) has been set up correctly, it can be used
under MS-DOS and Windows 3.1.
8
CNT24-4(PCI)
Page 18
Obtaining resource information
You can get information on the personal computer resources
assigned to the CNT24-4(PCI) by accessing the PCI BIOS.
For the precise method, refer to the sample program stored in the
DOS directory on the supplied FD.
Sample programs for MS-DOS
The sample programs for using the CNT24-4(PCI) under MS-DOS
are written in Microsoft C.
Setup
DOS --- Samples --
DOS --- Samples --- 98 or PC ---
(1) CNTPCI.CResource check program
CNTPCI.EXE
(2) CNTPCI01.CCount value of any Channel
CNTPCI01.EXE
(3) CNTPCI02.C4 channel count value at the same time
CNTPCI02.EXE
(4) CNTPCI03.CCount value for every time period by timer interrupt
CNTPCI03.EXE
Figure 2.4. Sample Programs on FD
For details on I/O addresses, see Chapter 4 "I/O Ports and
Registers."
CNT24-4(PCI)
9
Page 19
Setup
Sample's Specification
Table 2.1. Sample's Specification
Using channel0ch0ch - 3ch0ch - 3ch
Operating mode*1*1*1
Input Z-phase/clearoncein validin valid
Digital filter6.5µsec100nsec *2100nsec *2
Initial count value000
Comparison count value100 (64h)100 (64h)100 (64h)
One-shot pulse width
Timer value------1 second
Using connectorCN1CN1CN1
*1 Set an operation mode Set an operation mode for input spcification.
Operation mode data example
8Ch : Photocoupler insulation, 2-phase input
9Bh : Photocoupler insulation, Single-phase input
8Bh : Photocoupler insulation, Gate control input
CCh : TTL level, 2-phase input
DBh : TTL level, Single-phase input
CBh : TTL level, Gate Control input
Other settings (Common) : Asynchronization clear, UP counting direction,
Z-phase positive logic, Single input multiplication.
The Sample program uses the 8C setting.
*2 In the CNTPCI02, CNTPCI03, the digital filter is not set and the default is 100nsec.
*3 To Output the signal to an external peripheral, CN1 must be connected.
ItemSpecification
CNTPCI01.CCNTPCI02.CCNTPCI03.C
104.4msec *3------
≠
10
Note!
Connect a signal appropriate for the input specification of an
external peripheral. To connect a rotary encoder, see Chapter 3.
"Connecting Rotary Encoder".
CNT24-4(PCI)
Page 20
Setup
(1) Display count value of any channel (CNTPCI01.C)
This program displays the count value of the specified channel.
If the program is executed, the count value of the signal connected
to channel 0 is displayed.
The count comparison data is set at 100; matching with the count
value outputs the one-shot pulse to an external peripheral.
Pressing the ESC key terminates the program
CHANNELDATASTATUS
CH007F
Figure 2.5. CRT Display (CNTPCI01.C)
START
Set I/O address
*********
Set channel
Initial setting
• Set operation mode
• Set Z-phase
• Set digital filter
• Reset sense bit
Set count data
(Lower)
(Middle)
(Upper)
Set count match data
(Lower)
(Middle)
(Upper)
1
1
Set one-shot
pulse width
Latch count value
Read count value
(Lower)
(Middle)
(Upper)
Calculate count value
Display
count value
Figure 2.6. Flowchart (CNTPCI01.C)
CNT24-4(PCI)
11
Page 21
Setup
(2) Display 4 channel count values at the same time
(CNTPCI02.C)
This program displays the 4 channel count values at the same time.
When this program is executed, the signal count values (Decimal
and HEX) that are connected to channels 0 - 3 and their input status.
Pressing the ESC key terminates the program.
CHANNELDATASTATUS
CH007F
CH107F000000
CH207F000000
CH307F000000
DATA(HEX)
000000
Figure 2.7. CRT Display (CNTPCI02.C)
(3) Display count value for every time period by timer interrupt
(CNTPCI03.C)
This program generates an interrupt every second using the timer
and displays the count value. If this program is executed, the
count values (HEX and decimal) of the signal that is connected to
channels 0 -3 are displayed. The interrupt level is IRQ5.
Pressing the ESC key terminates the program.
CHANNELDATA
CH00
CH10000000
CH20000000
CH30000000
INTERRUPT COUNT 0TIME
DATA(HEX)
000000
12
Figure 2.8. CRT Display (CNTPCI03.C)
Note!
To terminate the program, press the ESC key. If the program is
terminated by another key, the interrupt routine is aborted and the
process stops.
CNT24-4(PCI)
Page 22
Setup
START
Set segment
*********
base address
Set address
Initial setting
• Set operation mode
• Set Z-phase
• Reset sense bit
Set count data
(Lower)
(Middle)
(Upper)
Set count data
(Lower)
(Middle)
(Upper)
Interrupt process
Set IRQ5
1
1
Clear mask
Set timer data
(Lowest)
(Lower)
(Upper)
(Highest)
Start timer
Check sense port
Latch count value
Read count value
Calculate count value
Display
count value
Reset sense bit
N
END
Y
Set IMR
Stop timer
END
IRQ5
Save registar
*********
Input number of
timer count ups
Interrupt EQI process
Restore register
IRET
Figure 2.9. Flowcharts (CNTPCI03.C)
CNT24-4(PCI)
13
Page 23
Setup
Setting up the Board
(for Use under Windows 95)
The board setup method for the CNT24-4(PCI) is different
depending on each OS. Set up the board using the appropriate
method depending on the OS used. This section describes the
procedure and notes for using the board under Windows 95.
Before the CNT24-4(PCI) can be used under Windows 95, have the
OS recognize the I/O addresses and interrupt level (IRQ) to be used
for the CNT24-4(PCI). Assigning the resources such as I/O
addresses and IRQ for a piece of hardware in Windows 95 is called
"installing the hardware." Use the appropriate procedure to install
the CNT24-4(PCI).
Checking the OS version
Note that the procedure for installing the CNT24-4(PCI) is different
depending on each version of Windows 95.
Check the version of Windows 95 on your system as follows before
installing the CNT24-4(PCI).
14
(1) Open [Control Panel] from [My Computer].
(2) Double-click on the [System] option to open the [System
Properties] property sheet.
(3) Check the "System:" number displayed on the [General] page.
System:
Microsoft Windows 95
4.00.950
The version numbers of Windows 95 include 4.00.950, 4.00,950a,
and 4.00.950B. The CNT24-4(PCI) setup method is different
depending on the version number of Windows 95.
CNT24-4(PCI)
Page 24
Procedure for use under Windows 95 version 4.00.950 or
4.00.950a
(1) Set the board ID.
(2) Be sure to check that the personal computer is off, then plug
the board into a PCI bus slot in the personal computer.
(3) Turn the personal computer on to start up Windows 95.
(4) Windows 95 will come up with the [New Hardware] detection
dialog box. Select [Multimedia Device: Select which driver
you want to install for your new hardware.] and then [Driver
from disk provided by hardware manufacturer].
(5) In the [Install From Disk] dialog box, insert the supplied FD in
a drive, enter the drive name and directory name in the [Copy
Distributed File From] field, then click on [OK].
(6) Follow the instructions on the screen to complete installation
of the CNT24-4(PCI). After finishing installing the board, be
sure to check the assigned resources.
Procedure for use under Windows 95 version 4.00.950B
Setup
(1) Set the board ID.
(2) Be sure to check that the personal computer is off, then plug
the board into a PCI bus slot in the personal computer.
(3) Turn the personal computer on to start up Windows 95.
(4) Windows 95 will come up with the [New Hardware] detection
dialog box. In the [Device Driver Wizard] that appears next,
check that "CONTEC Co., Ltd. - Multimedia Device" has been
listed, then select [Next>].
(5) In the next dialog box, select [Specify Location...].
Insert the supplied FD in a drive, enter the drive name and
directory name (WIN95) in the [Location] field, then click on
[OK].
(6) In the next dialog box, check the "Updated driver found for
this device" message, then select [End]. This completes
installation of the CNT24-4(PCI). After finishing installing
the board, be sure to check the assigned resources.
CNT24-4(PCI)
15
Page 25
Setup
Method of installing two or more CNT24-4(PCI) boards
(for use under Windows 95 version 4.00.950 or
4.00.950a)
Follow the procedure below to install two CNT24-4(PCI) boards for
use under Windows 95 version 4.00.950 or 4.00.950a.
(1) Check the board ID of the fi rst CNT24-4(PCI) board, plug it
into a PCI bus slot, then start up Windows 95 to install the first
board correctly.
(2) Check that the first CNT24-4(PCI) board has been set up
correctly, as described in "Checking resources." Be sure to
complete installation of the first board before trying to install
the second one.
(3) Exit Windows 95 and turn the personal computer off.
(4) Check the board ID of the second CNT24-4(PCI) board, then
plug it into a PCI bus slot. To the second board, assign a
board ID different from that assigned to the first board.
(5) Turn the personal computer on again to start up Windows 95.
(6) Windows 95 will come up with the [New Hardware] detection
dialog box. In [Multimedia Device: Select which driver you
want to install for your new hardware.], select [Select from
List].
16
(7) The [Select Hardware Type] dialog box will then appear.
In [Select Hardware Type to Install], select [Other Devices].
(8) In the [Select Device] dialog box that appears, select
[CONTEC] from [Manufacturers] and select [CONTEC Co.,
Ltd. - CNT24-4(PCI)] from [Models].
(9) The [Change System Settings] dialog box appears. Follow
the messages to restart the computer.
(10) When Windows 95 is restarted, installation of the second
CNT24-4(PCI) board is completed. Check the assigned
resources again.
CNT24-4(PCI)
Page 26
Notes!
Setup
For installing the third board and later, follow the same steps as
those for installing the second one. Before you can install the
third board or later, all of the already installed CNT24-4(PCI)
boards must be in the PCI bus slots.
- The second CNT24-4(PCI) board cannot be installed normally
unless the resources (I/O addresses and interrupt level) to be
used for the board cannot be allocated. Before trying to install
the second board, check free resources on the personal computer.
- The resources used for each CNT24-4(PCI) board do not depend
on the location of the PCI bus slot or the board itself. If you
remove two or more CNT24-4(PCI) boards which have already
been installed and then re-mount one of them on the computer,
therefore, it is unknown which one of the sets of resources
previously assigned to the two boards is assigned to the remounted board. In this case, check the resource settings again.
CNT24-4(PCI)
17
Page 27
Setup
Method of installing two or more CNT24-4(PCI) boards
(for use under Windows 95 version 4.00.950B)
Follow the procedure below to install two CNT24-4(PCI) boards for
use under Windows 95 version 4.00.950B.
(1) Check the board ID of the first CNT24-4(PCI) board, plug it
into a PCI bus slot, then start up Windows 95 to install the first
board correctly.
(2) Check that the first CNT24-4(PCI) board has been set up
correctly, as described in "Checking resources." Be sure to
complete installation of the first board before trying to install
the second one.
(3) Exit Windows 95 and turn the personal computer off.
(4) Check the board ID of the second CNT24-4(PCI) board, then
plug it into a PCI bus slot. To the second board, assign a
board ID different from that assigned to the first board.
(5) Turn the personal computer on again to start up Windows 95.
(6) The OS will then automatically install the second board.
When the installation has been completed, check the assigned
resources again.
18
For installing the third board and later, follow the same steps as
those for installing the second one. Before you can install the
third board or later, all of the already installed CNT24-4(PCI)
boards must be in the PCI bus slots.
CNT24-4(PCI)
Page 28
Notes!
- The second CNT24-4(PCI) board cannot be installed normally
unless the resources (I/O addresses and interrupt level) to be
used for the board cannot be allocated. Before trying to install
the second board, check free resources on the personal computer.
- The resources used for each CNT24-4(PCI) board do not depend
on the location of the PCI bus slot or the board itself. If you
remove two or more CNT24-4(PCI) boards which have already
been installed and then re-mount one of them on the computer,
therefore, it is unknown which one of the sets of resources
previously assigned to the two boards is assigned to the remounted board. In this case, check the resource settings again.
Checking resources
Before operating the CNT24-4(PCI) board, be sure to check the PC
resources (I/O addresses and interrupt level) assigned to the board.
For PCI compatible (Plug and Play compliant) boards, free
resources among the PC resources are assigned automatically upon
activation of the personal computer. Follow the steps below to
check the assigned resources managed by the OS.
(1) Double-click on the [System] option in [Control Panel] to open
the [System Properties] property sheet. Select the [Device
Manager] tab.
Setup
(2) Click on the [Multi function adapter] folder.
(3) Click on the [CONTEC Co., Ltd. - CNT24-4(PCI)] folder to
display its properties.
(4) Select the [Resources] tab to check the device type, resource
settings, and the conflicting device list.
(5) If you want to change a resource setting, uncheck the [Use
automatic settings] option in advance. To change the I/O
address range (Input/Output Range), change the configuration
name in the [Setting based on:] field. Since the interrupt
level (Interrupt Request) cannot be changed, use the assigned
IRQ.
Once the CNT24-4(PCI) has been installed correctly, it can be used
under Windows 95.
CNT24-4(PCI)
19
Page 29
Setup
Support software
CONTEC provides the following driver software for Windows 95:
API-CNT(98/PC)W95 Ver. 2.3 or later
These pieces of driver software support up to four CNT24-4(PCI)
boards.
Note that, when API-CNT(98/PC)W95 is used, development
languages that can be used are only 32-bit versions. Neither driver
can be supported by any language dedicated to 16-bit applications.
20
CNT24-4(PCI)
Page 30
Setting up the Board
(for Use under Windows NT)
The board setup method for the CNT24-4(PCI) is different
depending on each OS. Set up the board using the appropriate
method depending on the OS used. This section describes the
procedure and notes for using the board under Windows NT.
Before the CNT24-4(PCI) can be used under Windows NT, have the
OS recognize the I/O addresses and interrupt level (IRQ) to be used
for the CNT24-4(PCI). Assigning the resources such as I/O
addresses and IRQ for a piece of hardware in Windows NT is called
"installing the hardware."
Installing the CNT24-4(PCI) board requires separately priced
CONTEC driver software "API-CNT(98/PC)NT." Follow the
procedure below to install the board.
Procedure
(1) Set the board ID.
(2) Be sure to check that the personal computer is off, then plug
the board into a PCI bus slot in the personal computer.
Setup
(3) Turn the personal computer on to start up Windows NT .
(4) When Windows NT has been started, run SETUP.EXE for
API-CNT(98/PC)NT. For details on SETUP.EXE, refer to the
API-CNT(98/PC)NT manual.
(5) When SETUP.EXE has been terminated, run CONFIG.EXE
for API-CNT(98/PC)NT. For details on CONFIG.EXE, refer
to the API-CNT(98/PC)NT manual.
You have now finished installing the CNT24-4(PCI) board. When
setting up the board has been completed, be sure to check the
assigned resources.
CNT24-4(PCI)
21
Page 31
Setup
Checking resources
Before operating the CNT24-4(PCI) board, be sure to check the
personal computer resources (I/O addresses and interrupt level)
assigned to the board. For PCI compatible (Plug and Play
compliant) boards, free resources among the personal computer
resources are assigned automatically upon activation of the personal
computer. Follow the steps below to check the assigned resources
managed by the OS.
(1) Open [Windows NT Diagnostic Program] from [Management
(2) Select [Resources] (IRQ/port settings). Check the type and
Once the CNT24-4(PCI) has been installed correctly, it can be used
under Windows NT.
Support software
CONTEC provides the following driver software for Windows NT:
Tools].
settings of resources assigned to the API-CNT(98/PC)NT and
the conflicting device list.
22
API-CNT(98/PC)NT Ver. 2.3 or later
This driver software supports up to four CNT24-4(PCI) boards.
CNT24-4(PCI)
Page 32
3. External Connection
Connecting the Interface Connector
To input external pulse signals, use the interface connector on the
board. Use CN1 for the photocoupler insulated input. For TTL
level input, connect CN2 to an external device by connecting the
optional cable to CN2.
Matched pulse output is output from CN1. (Photocoupler insulated
open collector output)
External Connection
Note!
Figure 3.1. Connecting the Interface Connector
See Chapter 3 "Option cable DT/B2" for further information.
CNT24-4(PCI)
23
Page 33
External Connection
Connector
Connecting the CNT24-4(PCI) board to external devices is via one
37-pin female D-Type connector (CN1) and one 30-pin male
connector (CN2).
37
36
21
20
Figure 3.2. CN1 Connector as Viewed from Back of
Count-equal
Plus Output
19
18
17
3
2
1
Computer
Plus Common
General-purpose Input
OUT Z/CLR
CH3
OUT B/DOWN
OUT A/UP
Not Connected
General-purpose Input
OUT Z/CLR
CH2
OUT B/DOWN
OUT A/UP
Plus Common 2
Not Connected
Minus Common
CH3 Output
CH2 Output
CH1 Output
CH0 Output
Plus Common
You are now ready to connect the I/O cables to the board if you
have not already done so. Connecting the CNT24-4(PCI) to
external devices is via the 37-pin D-SUB I/O connector on the
board. Figure 3.8. shows Digital input circuits. Figure 3.9.
shows an example of connecting this board to open-collector output
device.
2.2k
Ω
Photocoupler
220
BOARD
Ω
Digital output
Plus common
+5V
External Connection
Input Terminal
External Signal Output
Figure 3.8. Digital Input
400Ω
R
Plus common
+12V
External Signal
Output
2.2k
Ω
Photocoupler
220Ω
Input Terminal
Figure 3.9. Connecting to Open-collector Output Device
CNT24-4(PCI)
27
Page 37
External Connection
Notes!
- The general input signal uses the same circuit structure. (the
photocoupler uses TLP 521.)
- To use external power (other than 5V), insert a current limiting
resistor at the R position.
<Calculating R (current limiting resistor)>
Assume external power is PV, then
P - 5P - 5
20
If P=12, use a 350 < R < 470 ohm resistor.
LS244
< Rk Ω <
Vcc
+5V
15
Diode
Diode
BOARD
Input Terminal
GND
Digital output
External Signal
Output
28
Figure 3.10. TTL-Level Input Circuitry
Notes!
- The general input signal uses the same circuit structure.
- The cable should be 1.5m or less.
- To prevent malfunction caused by noise, separate the circuit as
much as possible from other signal cables and noise sources.
CNT24-4(PCI)
Page 38
External Connection
Output Circuit and Connecting Example
When the count value of each channel and the user set value match,
the circuit outputs a matched signal for one shot (1 pulse). The
signal output part uses the open collector method by photocoupler
insulation. As a result, an external power source is needed to run
the board output.
Note!
Vcc
1kΩ
1k
Photocoupler
Photocoupler
Ω
18k
Ω
Plus common
Load
Output pin
Minus common
Load
External Power
Supply
DC5V~12V
Figure 3.11. Output Circuit and Connecting Example
The board's output transistor does not have a surge voltage
protection circuit. As a result, to run inductive loads (for example,
relays and lamps), install surge voltage protection at the loading
side. See "Appendix C: Surge Voltage" for further information.
To use the photocoupler with 12V, 400Ω resistors are needed at R.
For 5V, no resistor is needed.
Figure 3.12. Photocoupler Input
Power
source
(Connector pin number)
CH0 : 9 CH2 : 28
CN2
Encoder
A-phase
B-phase
Z-phase
0V
CH1 : 14 CH3 : 33
CH0 : 10 CH2 : 29
CH1 : 15 CH3 : 34
CH0 : 11 CH2 : 30
CH1 : 16 CH3 : 35
1-7, 13, 32
A-phase
B-phase
Z-phase
GND
CN2
CNT24-4(PCI)
30
Note!
Shield
Option Cable
Convert the connector to a 37 pin connector using the optional
cable. The following shows the pin numbers of the 37 pin
connector.
Figure 3.13. TTL Input
CNT24-4(PCI)
Page 40
Measures Against Voltages
When connecting a load which may generate a surge voltage or
current, for example an inductive load (relay coil) or incandescent
lamp, to one-shot output lines, suitable protection measures are
required to prevent damage to the output stage or a malfunction due
to noise. Instantaneously interrupting current flowing through a
coil including a relay causes the sudden generation of a highvoltage pulse. If its voltage exceeds the withstand voltage of the
transistor, the performance of the transistor may be degraded or it
may be damaged. To prevent this, be sure to connect a surge
absorption element when driving an inductive load including a relay
coil. Examples of measures against surge voltages are as shown in
the Figure 3.14. below.
External Connection
Note!
Figure 3.14. Samples of Surge Voltage Protection
The protection circuit will not be effective unless it is installed less
than 50cm from the load and contact.
CNT24-4(PCI)
31
Page 41
External Connection
32
CNT24-4(PCI)
Page 42
4. I/O Ports and Registers
I/O Port Bit Assignment
This board occupies consecutive I/O addresses for two ports.
Each I/O port has a register; the register is assigned by a command.
To set the register, execute an OUT command for the port (+0) to be
set, and enable the register. Then, execute an OUT command to
load data into the register for output, or to read the +1 port for input.
That is, for either input or output, first execute an OUT command to
enable the register, then output data to the register, or read the
register on the +1 port.
To set a register, execute an OUT command every time for the
output port (+0).
The following Figure 4.1. and Figure 4.2. show the I/O port bit
allocation.
D6D5D4D3D2D1D0
Base Address
D7
+0
+1
+2
+3
Command output (select register)
Setting data output
Not use
Not use
I/O Ports and Registers
Figure 4.1. Output port
D6D5D4D3D2D1D0
Base Address
D7
+0
+1
+2
+3
Impossible
Data / status read
Not use
Not use
Figure 4.2. Input port
Data Setting
To set 8 bit data, execute an OUT command for the +0 port and
output data to the +1 port. To set 24 bit data, execute an OUT
command for the 0 port and output data three times to the + port.
In this case, the data is set from the lower bite, the middle byte and
the upper byte. Data of 24 bits is read from the lower byte, the
middle byte and the upper byte.
Similarly, to set 32 bit data, output data four times to the +1 port.
CNT24-4(PCI)
33
Page 43
I/O Ports and Registers
Count Value Flow
Set count
initial value
Command
CH0 : 00h
CH1 : 05h
CH2 : 0Ah
CH3 : 0Fh
Set comparison
register
Command
CH0 : 03h
CH1 : 08h
CH2 : 0Dh
CH3 : 12h
24bit
up / down
counter
24bit
comparator
Comparison
Register
Latch
count value
(Command 14h)
Count value
coincidence
Figure 4.3. Count Value Flow
Read
Regisster
Coincidence signal
Sense port
(Command 16h)
Interrupt mask
(Command 15h)
Status data
Command
CH0 : 01h
CH1 : 06h
CH2 : 0Bh
CH3 : 10h
Output one-shot pulse
(Command 19h)
Read
Counter value
Command
CH0 : 00h
CH1 : 05h
CH2 : 0Ah
CH3 : 0Fh
34
CNT24-4(PCI)
Page 44
I/O Ports and Registers
Operation Command
Table 4.1. Output Command
Command [h]D7D6D5D4D3D2D1D0Function (bit)
00CH0 Count initial value CH0 Count initial value (24)
01RESETSELZSEL UD/ABDIRSEL2SEL1SEL0 CH0 Operation mode (8)
02No usedZE1ZE00 CH0 Z-phase/CLR input (3)
03CH0 count compare value CH0 Comparison register (24)
04No usedClock data for digital filter CH0 Digital filter (4)
05CH1 Count initial value CH1 Count initial value
06RESETSELZSEL UD/ABDIRSEL2SEL1SEL0 CH1 Operation mode
07No usedZE1ZE00 CH1 Z-phase/CLR input
08CH1 count compare value CH1 Comparison register
09No usedClock data for digital filter CH1 Digital filter
0ACH2 Count initial value CH2 Count initial value
0BRESETSELZSEL UD/ABDIRSEL2SEL1SEL0 CH2 Operation mode
0CNo usedZE1ZE00 CH2 Z-phase/CLR input
0DCH2 count compare value CH2 Comparison register
0ENo usedClock data for digital filter CH2 Digital filter
0FCH3 Count initial value CH3 Count initial value
00CH0 read count value CH0 Read count value (24)
01AIZAB1U/D EQ U CH0 Status data (8)
05CH1 read count value CH1 Read count value (24)
06AIZAB1U/D EQ U CH1 Status data (8)
0ACH2 read count value CH2 Read count value (24)
0BAIZAB1U/D EQ U CH2 Status data (8)
0FCH3 read count value CH2 Read count value (24)
10AIZAB1U/D EQ U CH2 Status data (8)
15000 TIME CH3 CH2 CH1 CH0 Interrupt mask (5)
16000 TIME CH3 CH2 CH1 CH0 Sense port (5)
36
CNT24-4(PCI)
Page 46
I/O Ports and Registers
Output Command
Count initial value
(Commands; CH0:00h, CH1:05h, CH2:0Ah, CH3:0Fh)
To set a count initial value, execute an OUT command for the
output port (+0) and set output port +1. The count data is 24 bit
data. Output the data eight times, eight bits at time. After the
last eight bits have been output, all data (24 bits) is loaded as the
count initial value.
The following sample program shows how to set the count initial
value 100 (64h) in CH0.
OUT Address+0h, 00h (CH0: Select count data)
OUT Address+1h, 64h (Lower bits)
OUT Address+1h, 00h (Middle bits)
OUT Address+1h, 00h (Upper bits)
In the default setting, all of channels are set 00h.
CNT24-4(PCI)
39
Page 49
I/O Ports and Registers
Counter Operation Mode
2-phase input
The 2-phase input inputs two different pulses when there is 90
degree difference between the A-phase (forward signal) and the
B-phase (following signal).
Inputting a Z-phase pulse clears the counter if there is a Z-phase
(base position signal).
A-phase
(A-phase/UP)
B-phase
(B-phase/DOWN)
Z-phase
(Z-phase/CLR)
Counting
Figure 4.4. Counting Example with 2-phase Input
Single-phase input
For a single-phase input, the counter counts up with an UP pulse
and counts down with a DOWN pulse. If UP and DOWN pulses
occur at the same time or both pulses are LOW, the counter will not
count properly.
UP pulse
(A-phase/UP)
DOWN pulse
(B-phase/DOWN)
Counting
Figure 4.5. Single-phase Counting Example
Note!
This is a counting operation when DIR=1. If DIR=0, the counter
counts down with the rising edge of an UP pulse and counts up with
the rising edge of a DOWN pulse.
40
012
5
6
7
8
7
6
CNT24-4(PCI)
Page 50
I/O Ports and Registers
Single-phase input with gate control
Inputting a gate control signal starts/stops the counter and a singlephase pulse. A clear signal clears the counter to zero.
Single pulse
(A-phase/UP)
Gate control
signal
(B-phase/DOWN)
no count
Note!
Couting
7
69
8
Figure 4.6. Example of Single-phase Input with Gate
Control
This is a counting operation when DIR=1. If DIR=0 and the gate
control signal (B-phase/DOWN) is HIGH, the counter counts down
with the rising edge of a single-phase pulse (A-phase/UP).
If DIR=0 and the gate control signal is LOW, the counter stops.
CNT24-4(PCI)
41
Page 51
I/O Ports and Registers
Synchronization clear
If DIR=1, ZSEL=1, the B-phase input is LOW and the Z-phase
input is HIGH, the counter is cleared with the rising edge of an
A-phase input, and the counter starts counting with the rising edge
of an A-phase input after the Z-phase input changes to LOW.
A-phase
(A-phase/UP)
B-phase
(B-phase/DOWN)
Z-phase
(Z-phase/CLR)
Counting
2011
Figure 4.7. Example of Synchronization Clear
DIR=0 and a B-phase is LOW, the counter starts counting down
with a rising edge of an A-phase input. If ZSEL=0, the Z-phase
input is available only when it is LOW.
Asynchronization clear
If DIR=1, ZSEL=1, regardless of the input state of the A-phase and
B-phase inputs, the counter is zero-cleared when a Z-phase input
changes to HIGH, and regardless of the Z-phase input state, the
counter starts counting with the next rising edge of the A-phase
input.
A-phase
(A-phase/UP)
B-phase
(B-phase/DOWN)
Z-phase
(Z-phase/CLR)
Counting
Figure 4.8. Example of Asynchronization Clear
2
3
11
0
42
If DIR=0 and the B-phase is LOW, the counter starts counting down
with the falling edge of the A-phase input. If ZSEL=0, the
Z-phase input is available only when it is LOW.
CNT24-4(PCI)
Page 52
I/O Ports and Registers
Count input multiplication
To set the count input multiplication as double or quadruple, more
precise counting is available.
- Double-phase input
- Single-phase input
For single-phase input, only the single multiplication mode is
available. (There is no double or quadruple multiplication.)
- Single-phase input with gate control
Figure 4.9. Counting Example for Multiplied Count Inputs
CNT24-4(PCI)
43
Page 53
I/O Ports and Registers
Z-phase/CLR input
(Command CH0:02h, CH1:07h, CH2:0Ch, CH3:11h)
02h/07h/0Ch/11h
D7
D6D5
D4
D3 D2D1
D0
ZE00ZE1Not used
Output a command to output port +0 and set the number of Z-phase
inputs on output port +1.
ZE1, ZE0 : Select Z-phase input mode.
Table 4.5. Z-phase Input Mode
ZE1 ZE0State
01Disable Z-phase input if there is no Z-phase input.
* 10Only the next Z-phase input is available.
11Every Z-phase input is available.
* mark is the default setting.
- Disabled Z-phase input
- Only next Z-phase input is available
44
- Every Z-phase input is available
Figure 4.10. Number of Z-phase Inputs Available ZSE=0
(Positive Logic)
CNT24-4(PCI)
Page 54
I/O Ports and Registers
Notes!
- The default is "only the next Z-phase input is available." (04h)
- If ZSEL=1 (negative logic), a LOW Z-phase input is available.
- If the Z-phase/CLR input is not used, set ZE1=0 and ZE0=1
(Disable Z-phase input).
- If "only the next Z-phase input is available" is set and the
counter is zero-cleared with the Z-phase input, and if the counter
is cleared with RESET=0, "only the next Z-phase input is
available" will be set with the RESET=0.
Comparison register
(Command CH0:03h, CH1:08h, CH2:0Dh, CH3:12h)
The counter value of the corresponding channel and the data in the
comparison register are compared. If they match, the status bit
"EQ" is set to 0. (As long as they match, the bit remains 0.) This
register is cleared when the bus is reset.
Output the command on the output port +0 and set the comparison
data on the output port +1. The comparison data is 24 bit data.
Output the data three times, eight bits at a time, from the lower bits,
the middle bits and the upper bits.
The following sample program shows how to set the counting
comparison value 1000 (3E8h) to CH1.
OUT Address+0h, 03h (CH1 : Select comparison register)
OUT Address+1h, E8h (Lower bits)
OUT Address+1h, 03h (Middle bits)
OUT Address+1h, 00h (Upper bits)
In addition, a particular setting can output a one-shot pulse.
(For more details, see "One-shot Pulse" description.)
CNT24-4(PCI)
45
Page 55
I/O Ports and Registers
D
4
D
0
Digital filter
(Command CH0:04h, CH1:09h, CH2:0Eh, CH3:13h)
Note!
04h/09h/0Eh/13h
D7
D6D5
D3 D2D1
Digital filter clock dataNot used
The digital filter filters noise on the counter pulse input (A, B or Zphase signals ). The digital filter clock data determines the
sampling clock frequency of the filter. The filter samples with the
sampling clock; if it detects HIGH (or LOW) signals for four
consecutive clocks, it outputs a HIGH (or LOW) signal and sends
the signal to the counter circuit.
Output a command to output port +0 and set the sampling
frequency on the output port +1. The range is 100nsec -1056.1
usec.
Since external input signals (except the general input signal) are
read into the internal counter through the digital filter, these signals
are read after a four clock delay of the sampling frequency. With
the default setting, external input signal is read with 400nsec delay.
46
CNT24-4(PCI)
Page 56
I/O Ports and Registers
External
input signal
External
input signal
PC
input signal
Digital
Filter
4 clock of the sampling frequency
in valid
valid
PC
input signal
Figure 4.11. Digital Filter
Table 4.6. Digital Filter Clock Data
D3 D2 D1 D0Clock frequency Input frequency numbers
- Some noise causes more than a four clock delay of the set
frequency.
- If the level changes faster than the sampling clock frequency that
has been set, the level change is invalid and there is no count.
Latch count.
CNT24-4(PCI)
47
Page 57
I/O Ports and Registers
Latch Count value (Command 14h)
D4
D3D2D1
CH3 LTNot usedCH2 LTCH1 LT CH0 LT
14h
D7
D6D5
The counter value of the corresponding channel is latched in the
read-out register.
Output 14h to the output port +0 and set the data latch on output
port +1. Data is latched by setting an appropriate bit to "1."
By setting all bits, all channels can be latched at the same time.
Note!
The default is not latched (00h).
Interrupt mask (Command 15h)
D6D5
D7
15hTIMENot usedCH2
Output 15h to output port +0 and set the mask on output port +1.
By setting an appropriate bit to "1," the interrupt is disabled.
TIME :Setting this bit to "1" disables the interrupt that
CH3-CH0 : These bits correspond to the channels. Setting these
D4
D3D2D1
signals that the programmable timer has elapsed for
the predetermined time. Setting this bit to "0",
enables the interrupt.
bit to "1," enables the interrupt that notifies the count
match. Setting these bits "0," enables the interrupt.
CH1
D0
D0
CH0CH3
48
Notes!
- In the default setting, all of the four channels and the timer are
disabled (1Fh).
- However, to mask a channel or the timer will not effect the
function of setting/resetting the related status.
CNT24-4(PCI)
Page 58
Sense Reset (Command 16h)
I/O Ports and Registers
D6D5
D7
Not used
16hTIME
D4
D3D2D1
CH2
CH3
CH1
D0
CH0
When the counts of the channels match or the timer count is up, the
corresponding bit changes "1" If this bit is "1", the interrupt does
not occur with the next count match or the timer count is up.
Outputting 16h to output port +0 and outputting "1" to the
corresponding bit of output port +1 clear the sense bit. The next
interrupt signal can be generated.
TIME :Resets the sense bit when the progr ammable timer
count is up.
CH3-CH0 : Resets the sense bit for count match of the channels.
CNT24-4(PCI)
49
Page 59
I/O Ports and Registers
Programmable time
(Command timer data:17h, Timer start:18h)
D7
17h
D6D5
D4
Programable timer data
D3D2D1
D0
18h
D7
D6D5
D4
D3D2D1
Not usedSTART
D0
The programmable timer generates an interrupt with a frequency
that has been set in the 32 bit data. To generate an interrupt by the
timer, set the 32 bit data, then set the START bit to "1".
To set the programmable timer, output 17h to output port +0 and set
the timer data on output port +1. Since the timer data is 32 bit data,
output the data four times, eight bits at a time, from the lower bits to
the upper bits. The range is 1msec - 200sec.
To start the timer, output the timer start command (18h) and set the
corresponding bit on output port +1. Setting the bit to "0" stops
the timer.
Table 4.8. shows the relationship between the programmable timer
data and the timer interrupt frequency.
Example : The following program sample show how to set the
programmable timer to 1 second.
OUT Address+0h, 17h(Select timer setting)
OUT Address+1h, FFh(Lowest bits)
OUT Address+1h, 2Ch(Lower bits)
OUT Address+1h, 31h(Upper bits)
OUT Address+1h, 01h(Highest bits)
OUT Address+0h, 18h(Select timer start)
OUT Address+1h, 1h(Timer start)
50
Note!
In the default setting, the timer is disabled.
CNT24-4(PCI)
Page 60
Timer interrupt frequency
The timer interrupt frequency is obtained from following
equation :
I/O Ports and Registers
( Timer Data x 50 + 50) x 10 = Timer interrupt frequency (msec)
32 bits (converted to decimal)
-6
Table 4.7. Relationship between programmable timer
When the counter values on the channels and the value in the
comparison register match, a one-shot pulse is output to each
channel. The pulse width is common to all channels and
determined by the data that is set. The range is 0msec -
104.45msec.
To set the pulse width, output the command (19h) to output port +0
and set the pulse width on output port +1. The one-shot width is
obtained from the following equation:
Pulse width data x 409.6 = Pulse width (used)
8 bits (converted to decimal)
Table 4.8. Relationship Between One-shot Pulse Width
Data and Pulse Width
One-shot pulse width data
D7D0[h]Pulse width
0000000000h0
0000000101h
0000001002h About 819.2µsec
0000001103h About 1.23msec
000011000Ch About 4.92msec
0001100119h About 10.24msec
0011000131h About 20.07msec
0100100149h About 29.9msec
0110001062h About 40.14msec
011110107Ah About 49.97msec
1001001193h About 60.2msec
10101011ABh About 70.04msec
11000100C4h About 80.28msec
11011100DCh About 90.11msec
11110101F5h About 100.35msec
11111111FFh About 104.45msec
About 409.6µsec
52
Notes!
- The default is "Pulse width = 0 (00h)" (not output).
- The pulse width may fluctuate depending on the connection load
specification.
CNT24-4(PCI)
Page 62
Input Command
Read count value
(Command CH0:00h, CH1:05h, CH2:0Ah, CH3:0Fh)
By reading the read-out register of the corresponding channel the
count can be read.
To read the count, output the command to output port +0 and read
input port +1 three times (lower, middle, and upper bits).
The default of the read-out register is not determined.
The following sample program shows how to read the CH2 counter
Status data
(Command CH0:01h, CH1:06h, CH2:0Bh, CH3:10h)
D6D5
01h/06h/0Bh/10hAIZAB
D7
D4
D3D2 D1
U/D EQ
1
D0
U
To monitor signal input, counting direction, count match and
invalid input, output a command to output port +0 and read input
port +1.
AI : This bit changes to "1" (pulse invalid input) if A-phase and
B-phase change at the same time for 2-phase input or if the
UP pulse and DOWN pulse change at the same time.
1 : Invalid input
0 : No invalid input
Z :This bit shows the Z-phase input status
<Positive logic>
1 : Z-phase input status "1"
0 : Z-phase input status "0"
<Negative logic>
1 : Z-phase input status "0"
0 : Z-phase input status "1"
A : This bit shows the A-phase input status
1 : A-phase input status "1"
0 : A-phase input status "0"
B : This bit shows the B-phase input status
1 : B-phase input status "1"
0 : B-phase input status "0"
54
U/D : Counting direction status
This status bit shows the counting direction of the current.
0 : Counting up
1 : Counting down
EQ : Detected match
0 : Counter value and register value matched.
1 : Counter value and register value did not match.
CNT24-4(PCI)
Page 64
Notes!
I/O Ports and Registers
U : Shows the general input status
1 : General input status "1"
0 : General input status "0"
- The default changes depending on the external connection status.
- Since the status data of A-phase, B-phase and Z-phase is the data
after the filtering process, it has a 4 clock delay in the frequency
that has been set.
- Z-phase logic is set by the ZSEL of the operation mode setting.
CNT24-4(PCI)
55
Page 65
I/O Ports and Registers
Interrupt mask (Command 15h)
D6D5
D7
15hTIMENot usedCH2
This shows the interrupt mask register status.
TIME and CH3 - CH0 monitor the current interrupt mask status that
has been output to the interrupt mask set port. TIME corresponds
to the programmable timer and CH3-CH0 corresponds to each
channel. If these bits are "1," the interrupt is masked and an
interrupt signal is not output.
To monitor the mask status, output 15h to the output port +0 and
read the input port +1.
0 : Masked
1 : Not masked
Note!
The default is 1Fh.
Sense port (Command 16h)
D6D5
D7
16hTIMENot usedCH2
This shows the channel count match and count-up. To monitor the
sense port, output 16h to output port +0 and read input port +1.
TIME :This bit is set to "1" when the time set in the
program mable timer has elapsed.
CH3-CH0 : For any channel between CH3-CH0, when a value
in the up/down counter and the comparison register
matches, the bit for the channel is set to "1." The
interrupt channel is determined by executing
counting on multiple channels and generating an
interrupt on the "matched" signal.
0 : Count did not match - Timer continues counting
1 : Count matches - Timer stops counting
Notes!
- The default is 00h.
- If an interrupt is e nabled and generated and the TIME bit or one
of the CH3 to CH0 bits changes to "1" reset the corresponding
sense bit to enable the next interrupt. For details on sense bit
resetting, see "Sense Bit Reset" of the output port.
D4
D4
D3D2D1
CH1
D3D2D1
CH1
D0
CH0CH3
D0
CH0CH3
56
CNT24-4(PCI)
Page 66
I/O Ports and Registers
Default Setting
The power on or a reset signal will reset this board to the default
settings.
ItemSpecification
Number of Channels4Channels
Count FormatUp/Down binary count
Max. Count ValueFFFFFFh
Input FormatOpto-isolated or TTL-level
Input SignalOUT A (Up)1 per channel
Timer1msec - 200sec
Number of Channels4
Output FormatPhoto-coupler open-collector output
Output VoltageMax. 35VDC, 50mA (per channel)
Output Signal Width0 - 104.45msec (all channels)
External Power5 - 12VDC
I/O Address8 bits x 4 ports
Dimensions179.0 x 107.0 x 18.5 mm
Power Consumption5VDC, 400mA (Max.)
Operation Temperature0 - 50°C
Relative Humidity20 - 90%
System Reference
OUT B (Down)1 per channel
OUT Z (CLR)1 per channel
Digital Input1 per channel
Ω
TTL. : 1 LEVEL
the comparison value and the counter value of
the corresponding channel watch
(each channel can be set independently)
CNT24-4(PCI)
59
Page 69
System Reference
Block Diagram
The following is a block diagram of the CNT24-4(PCI) interface
board.
PCI Bus
System
clock
20MHz
Sampling clock 16-bit counter
for digital filter
24-bit read register
24-bit counter
Selector
PCI Bus Interface
24-bit comparator
24-bit compare register
One-shot pulse output
Digital filter
CNT24-4(PCI)
Photocoupler
resistance input
(4channels)
TTL level input
Buffer
(4 channels)
One-shot pulse output
(4 channels)
(photocoupler open
collector output)
60
Figure 5.1. Block Diagram
CNT24-4(PCI)
Page 70
6. Troubleshooting
If you are having trouble with your board or program, answer the
following questions to see if you can find the problem.
QUESTIONS:
STEPS TO TAKE
Is the pilot light on?
The system must be turned on and the power supply must be
working. Check the main power switch and the power supply.
Did the system boot up?
If the board has been installed and the system did not boot, check
the following:
- Make sure the board has been inserted firmly. Pull it out and try
to reboot. If your system reboots, then re-insert the board and
try to boot again.
- Check that cables attached to your other boards fit tightly.
Troubleshooting
Does your program work?
If the system booted and your program does not work, check the
following:
- Rotary switches have been set correctly for the desired base
address.
- Selected base address doesn't conflict with another peripheral
device or card installed in the computer.
- Selected interrupt levels don't conflict with interrupts required by
other devices or cards.
- Try one of the sample programs provided on the disk and see if it
works.
Does the sample program work?
Check the following:
- Signals are connected to the correct pins.
CNT24-4(PCI)
61
Page 71
Troubleshooting
- Pin connections on the I/O cables are secure.
- Signals are present at the external connectors.
- Try using the CNT24-4(PCI) board with other non-essential
boards removed. Remove other boards one by one, checking the
CNT24-4(PCI) for successful operation after each board is
removed.
Is the input data accurate?
If you believe something is wrong with either the input data or the
output data, check the following:
- Environmental noise. Move the equipment and cables away
from sources of electrical noise. Try an isolated power source.
- Dirty connector edge. Clean the edge.
- External connectors fit tightly. Separate and reattach external
cables.
Still have a problem?
Contact CONTEC group office where you purchased as shown in
the last page of this manual.
Note!
Before you call, make a list of the following information. Our
technical representatives will need the following information to help
you.
62
1. Your name, company, and phone number.
2. The brand and type of computer you are using (e.g. IBM-AT,
Compaq 386).
CNT24-4(PCI)
Page 72
Troubleshooting
3. DOS Version.
4. Name of the CONTEC board that you are using.
5. Names of other boards in the computer.
6. I/O addresses for the CONTEC board and all other boards.
7. Interrupt levels for the CONTEC board and all other boards.
8. DMA channels for the CONTEC board and all other boards
(if applicable).
9. The programming language that you are using (and the version
number).
CNT24-4(PCI)
63
Page 73
Troubleshooting
10. Different I/O addresses you have tried.
11. Are you using your own program or a CONTEC sample
B-809, Hua Tong Building, No. B19, Che Gong Zhuang West Road,
Hai Dian District, Beijing 100044, China
Tel: +86(10)8801-8228Fax : +86 (10)8801-8209
E-mail: ict@ict.com.cn
SHANGHAI CONTEC MICROELECTRONICS CORPORATION.
No. 481, Gui Ping Road, Cao He Jing,Hi-Tech Park, Shanghai 200233, China
Tel: +86 (21) 6485-1907Fax : +86 (21) 6485-0330
E-mail: contec@contec.com.cn