ADLINK cPCI-7252 User Manual

Page 1
PCI-7250/7251, cPCI-7252
NuIPC / NuDAQ
Relay Actuator & Isolated D/I Cards
User’s Manual
Manual Rev. 2.00
Revision Date: January 10, 2005
Part No: 50-11105-103
Advance Technologies; Automate the World.
Page 2
All Rights Reserved.
The information in this document is subject to change without prior notice in order to improve reliability, design, and function and does not represent a commitment on the part of the manufacturer.
In no event will the manufacturer be liable for direct, indirect, spe­cial, incidental, or consequential damages arising out of the use or inability to use the product or documentation, even if advised of the possibility of such damages.
This document contains proprietary information protected by copy­right. All rights are reserved. No part of this manual may be repro­duced by any mechanical, electronic, or other means in any form without prior written permission of the manufacturer.
Trademarks
Product names mentioned herein are used for identification pur­poses only and may be trademarks and/or registered trademarks of their respective companies.
Page 3
Getting Service from ADLINK
Customer Satisfaction is top priority for ADLINK Technology Inc. Please contact us should you require any service or assistance.
ADLINK TECHNOLOGY INC.
Web Site: http://www.adlinktech.com
Sales & Service: Service@adlinktech.com
TEL: +886-2-82265877
FAX: +886-2-82265717
Address: 9F, No. 166, Jian Yi Road, Chungho City,
Taipei, 235 Taiwan
Please email or FAX this completed service form for prompt and satisfactory service.
Company Information
Company/Organization
Contact Person
E-mail Address
Address
Country
TEL FAX:
Web Site
Product Information
Product Model
OS:
Environment
M/B: CPU: Chipset: Bios:
Please give a detailed description of the problem(s):
Page 4
Page 5

Table of Contents

Table of Contents..................................................................... i
List of Tables.......................................................................... iv
List of Figures ......................................................................... v
1 Introduction ........................................................................ 1
1.1 Features............................................................................... 2
1.2 Applications ......................................................................... 2
1.3 Specifications....................................................................... 3
Digital input ..................................................................... 3
Relay Output ................................................................... 3
General Specifications .................................................... 4
Power Consumption ....................................................... 4
1.4 Software Support ................................................................. 5
Programming Library ...................................................... 5
PCIS-LVIEW: LabVIEW® Driver .................................... 6
PCIS-VEE: HP-VEE Driver ............................................. 6
DAQBenchTM: ActiveX Controls .................................... 6
PCIS-DDE: DDE Server and InTouchTM ...................... 6
PCIS-ISG: ISaGRAFTM driver ....................................... 6
PCIS-ICL: InControlTM Driver ........................................ 7
PCIS-OPC: OPC Server ................................................. 7
2 Installation .......................................................................... 9
2.1 Unpacking Checklist ............................................................ 9
2.2 PCB Layout........................................................................ 10
PCI-7250 PCB Layout .................................................. 10
cPCI-7252 PCB Layout ................................................. 11
2.3 Input Signal Jumper Setting............................................... 12
2.4 Hardware Installation Outline............................................. 13
PCI Configuration ......................................................... 13
PCI Slot Selection ......................................................... 13
Installation Procedures ................................................. 13
2.5 Device Installation for Windows Systems .......................... 14
2.6 Connector Pin Assignments .............................................. 14
PCI-7250/51 Pin Assignment ........................................ 14
cPCI-7252 Pin Assignment ........................................... 16
Table of Contents i
Page 6
2.7 PCI-7250 and PCI-7251 Connection ................................. 17
3 Registers............................................................................ 19
3.1 PCI PnP Registers ............................................................. 19
3.2 I/O Address Map ................................................................ 20
3.3 Relay Output and Readback Registers.............................. 20
3.4 Isolation Input Registers .................................................... 21
4 Operation Theory .............................................................. 23
4.1 Using Relay Output............................................................ 23
4.2 Using Isolated Input ........................................................... 25
5 C/C++ Libraries ................................................................. 27
5.1 Libraries Installation ........................................................... 27
5.2 Programming Guide........................................................... 27
Naming Convention ...................................................... 27
Data Types ................................................................... 28
5.3 Running Testing Utility (7250UTIL.EXE)............................ 28
5.4 725X Initialization............................................................... 30
@ Description ............................................................... 30
@ Syntax ...................................................................... 30
@ Arguments ................................................................ 30
@ Return Code ............................................................. 31
5.5 _7250_DI, _7252_DI.......................................................... 32
@ Description ............................................................... 32
@ Syntax ...................................................................... 32
@ Arguments ................................................................ 32
@ Return Code ............................................................. 33
5.6 _7250_DO, _7252_DO ...................................................... 34
@ Description ............................................................... 34
@ Syntax ...................................................................... 34
@ Arguments ................................................................ 34
@ Return Code ............................................................. 35
5.7 _7250_DO_Read_Back, _7252_DO_ReadRelay.............. 35
@ Description ............................................................... 35
@ Syntax ...................................................................... 35
@ Arguments ................................................................ 35
@ Return Code ............................................................. 36
5.8 _7251_Check_Exist ........................................................... 37
@ Description ............................................................... 37
ii Table of Contents
Page 7
@ Syntax ...................................................................... 37
@ Argument ................................................................. 37
@ Return Code ............................................................. 37
Appendix................................................................................ 39
Relay Contact Protection Circuits ...................................... 39
RC Circuit ..................................................................... 39
Diode Circuit ................................................................. 40
Diode & Zener diode Circuit .......................................... 41
Varistor Circuit .............................................................. 41
Warranty Policy..................................................................... 43
Table of Contents iii
Page 8

List of Tables

Table 1-1: Digital Input Specifications ........................................ 3
Table 1-2: Relay Output Specifications ...................................... 3
Table 1-3: General Specifications .............................................. 4
Table 1-4: Power Consumption Specifications .......................... 4
Table 2-1: Jumpers and DI Channels ...................................... 12
Table 2-2: Input Signal Selection Jumper Settings .................. 12
Table 2-3: CN1 - PCI-7250/51 Pin Assignment ....................... 15
Table 2-4: CN1 - cPCI-7252 Pin Assignment .......................... 16
Table 3-1: PCI-7250 Address Map with PCI-7251 Installed .... 20
Table 3-2: cPCI-7252 Address Map ......................................... 20
Table 3-3: Data Format of Relay Output and Readback Status Reg-
isters ....................................................................... 21
Table 3-4: Relay Output ........................................................... 21
Table 5-1: Data Types ............................................................. 28
iv List of Tables
Page 9

List of Figures

Figure 2-1: PCI-7250 Layout...................................................... 10
Figure 2-2: cPCI-7252 Layout .................................................... 11
Figure 2-3: CN1 - D Type Connector ......................................... 14
Figure 2-4: Connection between PCI-7250 and PCI-7251 ........ 17
Figure 4-1: Form C Relay .......................................................... 23
Figure 4-2: Form A Relay........................................................... 24
Figure 4-3: PCI-7250 Differential Input Circuit ........................... 25
Figure 4-4: cPCI-7252 Isolated Input Circuit .............................. 25
List of Figures v
Page 10
Page 11

1 Introduction

The PCI-7250/7251 and cPCI-7252 Relay Actuator and Isolated D/I cards are basic Digital I/O cards for PCI bus compliant comput­ers used in industrial applications.
This PCI-7250 and PCI-7251 provides 8 relay actuators and 8 opto-isolated digital inputs. Of the eight relays, four are Form C (R0~R3) and four are Form A (R4~R7). The cPCI-7252 provides 8 relay actuators and 16 opto-isolated digital inputs; all relays are Form C. They are very suited for constant ON/OFF control devices. For convenience the above models will be referred to as PCI-725X in this manual.
All channels are isolated and suitable for collecting digital input signals in a noisy environment. For identical non-polarized opto­isolated digital input channels, switching can be carried out using AC-filtered or non-AC-filtered channels.
A LED reflects the status of each relay output. When a relay is energized, its corresponding LED will turn ON, otherwise it is OFF.
The relay outputs and digital inputs are controlled by two bytes of I/O addresses. When a bit is read or written, its output status will be controlled, or its input status will be monitored. The I/O signals are routed through to a 37-pin D-type connector that protrudes through the computer case at the rear.
Introduction 1
Page 12

1.1 Features

The PCI-725X Relay Actuator and D/I card provides the following advanced features:
X 32-bit PCI-Bus, Plug and Play (PCI-7250)
X 32-bit CompactPCI® Bus, Plug and Play (cPCI-7252)
X 8 relay actuator outputs
X 8 opto-isolated digital inputs (PCI-7250)
X 16 opto-isolated digital inputs (cPCI-7252)
X LED indicators to show energized relays
X Jumper selectable AC-filter/non-AC-filter input signals
X On-board relay driving circuits
X On-board digital input signal conditioning circuits
Note: The PCI-7251 attaches to a PCI-7250 card. Each PCI-7251
card provides an additional 8 relay output and 8 photo isolat­ed input signals. Up to three PCI-7251 cards can be attached to one PCI-7250 card to provide 32 relay output signals and 32 photo isolated inputs signals.

1.2 Applications

X Industrial ON/OFF control
X External high power relay driving signal switching
X Laboratory automation
X Industrial automation
X Switch contact status sensing, limit switch monitoring,
X Useful with A/D and D/A cards to implement a data acquisi-
tion & control system
2Introduction
Page 13

1.3 Specifications

Digital input

Input channels
Photo-coupler PC-814
Input current
Input Voltage
Threshold Voltage 2.4VDC
Input impedance
Input mode Isolation AC-filter/ Non-AC-filter
Isolated voltage 5,000 Vrms channel-to-system
Table 1-1: Digital Input Specifications
8 for PCI-7250 and PCI-7251
16 for cPCI-7252
10mA rated
60mA max for isolated input
Up-to 24VDC or 24V AC 50-1,000Hz
Logic Low: 0-2.4V
Logic High 3-24V

Relay Output

Output channels 8
Relay type
Contact rating
Breakdown voltage 1000V AC/DC min..
Release time 8msec typical
Operate time 8msec typical
Contact resistance Bifurcated
Insulation resistance
Life expectancy > 10 million operations at full load
LED indicators Monitor ON/OFF status of each relay
Coil Voltage +5V, 33mA for each relay, total 0.264A
Power supply of Relay +5V from the PCI-Bus
Table 1-2: Relay Output Specifications
4 SPDT (Form C) 4 SPST (Form A)
120VAC/DC, 0.5A
24VDC, 1A
100M min.
1.2K
Introduction 3
Page 14

General Specifications

X 162mm x 107mm for PCI-7250
Dimensions
Bus 32-bit PCI bus
Operating temperature 0 - 60ºC (Operating)
Storage temperature -20ºC - 80ºC (Operating)
Humidity 5 to 90% non-condensing
Table 1-3: General Specifications
X 141mm x 102mm for PCI-7251
X 160mm x 100mm for cPCI-7252

Power Consumption

Power Consumption Note: No relay is energized
PCI-7250 +5V @ 140mA
PCI-7251 +5V @ 125mA
cPCI-7252 +5V @ 120mA
Table 1-4: Power Consumption Specifications
4Introduction
Page 15

1.4 Software Support

ADLINK provides versatile software drivers and packages to address different approaches to building a system. We not only provide programming libraries such as DLLs for many Windows systems, but also provide drivers for many software packages such as LabVIEW®, HP VEETM, DASYLabTM, InTouchTM, InControlTM, ISaGRAFTM, etc.
All software options are included in the ADLINK CD. Non-free soft­ware drivers are protected with licensing codes. Without the soft­ware code, you can install and run the demo version for two hours for trial/demonstration purposes. Please contact ADLINK dealers to purchase a formal license.

Programming Library

For customers who are writing their own programs, we provide function libraries for many different operating systems, including:
X DOS Library: For Borland C/C++, and Microsoft C++, the
functions descriptions are included in this user’s guide.
X Windows 95 DLL: For VB, VC++, Delphi, BC5, the functions
descriptions are included in this user’s guide.
X PCIS-DASK: Included device drivers and DLL for Windows
98, Windows NT and Windows 2000. A DLL is a binary compatible across Windows 98, Windows NT and Windows
2000. That means all applications developed with PCIS­DASK are compatible across Windows 98, Windows NT, and Windows 2000. The developing environment can be VB, VC++, Delphi, BC5, or any Windows programming lan­guage that allows calls to a DLL. The user’s guide and func­tion reference manual of PCIS-DASK are in the CD. Please refer the PDF manual files under \\Manual_PDF\Soft­ware\PCIS-DASK
The above software drivers are shipped with the board. Please refer to the “Software Installation Guide” for installation proce­dures.
Introduction 5
Page 16

PCIS-LVIEW: LabVIEW® Driver

PCIS-LVIEW contains VIs that are used to interface with the Lab­VIEW® software package. PCIS-LVIEW supports Windows 95/98/ NT/2000. The LabVIEW® drivers are shipped free with the board. You can install and use them without a license. For more informa­tion about PCIS-LVIEW, please refer to the user’s guide in the CD (\\Manual_PDF\Software\PCIS-LVIEW).

PCIS-VEE: HP-VEE Driver

PCIS-VEE includes user objects, which are used to interface with the HP VEE software package. PCIS-VEE supports Windows 95/ 98/NT. The HP-VEE drivers are shipped free with the board. For more information about PCIS-VEE, please refer to the user’s guide in the CD (\\Manual_PDF\Software\PCIS-VEE).

DAQBenchTM: ActiveX Controls

Customers familiar with ActiveX controls and VB/VC++ program­ming can use the DAQBenchTM ActiveX Control component library for developing applications. DAQBenchTM is designed for Windows NT/98. For more information about DAQBench, please refer to the user’s guide in the CD (\\Manual_PDF\Soft­ware\DAQBench\DAQBench Manual.PDF).

PCIS-DDE: DDE Server and InTouchTM

DDE stands for Dynamic Data Exchange. PCIS-DDE includes the PCI cards’ DDE server. The PCIS-DDE server is included in the ADLINK CD and requires a license. The DDE server can be used in conjunction with any DDE client under Windows NT.

PCIS-ISG: ISaGRAFTM driver

ISaGRAF WorkBench is an IEC1131-3 SoftPLC control program development environment. PCIS-ISG includes ADLINK product drivers for ISaGRAF under the Windows NT environment. PCIS­ISG is included in the ADLINK CD and license is required to use the drivers.
6Introduction
Page 17

PCIS-ICL: InControlTM Driver

PCIS-ICL is the InControl driver which supports Windows NT. PCIS-ICL is included in the ADLINK CD and license is required to use the drivers.

PCIS-OPC: OPC Server

PCIS-OPC is an OPC Server that can link with OPC clients. There are several software packages on the market which can provide OPC clients. PCIS-OPC supports Windows NT and requires a license to operate.
Introduction 7
Page 18
8Introduction
Page 19

2 Installation

This chapter describes how to install and setup the 725X cards. Jumper settings for the digital input channel configurations (AC-fil­ter or Non-AC-filter) and the signal definitions of the 37-pins con­nectors are also specified.

2.1 Unpacking Checklist

Check the shipping carton for any damage. If the shipping carton and contents are damaged, notify the dealer for a replacement. Retain the shipping carton and packing materials for inspection by the dealer. Obtain authorization before returning any product to ADLINK.
Check the following items are included in the package, if there are any items missing, please contact your dealer:
Included Items
X PCI-7250 (or PCI-7251, cPCI-7252) Relay Actuator & Iso-
lated D/I Card
X ADLINK CD (for PCI-7250 and cPCI-7252 only)
X Software Installation Guide
X This User’s Manual
Note: The packaging of OEM versions with non-standard
configuration, functionality, or package may vary according to different configuration requests.
CAUTION: The boards must be protected from static discharge
and physical shock. Never remove any of the socketed parts except at a static-free workstation. Use the anti­static bag shipped with the product to handle the board. Wear a grounded wrist strap when servicing
Installation 9
Page 20

2.2 PCB Layout

PCI-7250 PCB Layout

Figure 2-1: PCI-7250 Layout
10 Installation
Page 21

cPCI-7252 PCB Layout

Figure 2-2: cPCI-7252 Layout
Installation 11
Page 22

2.3 Input Signal Jumper Setting

Note: This section is for PCI-7250 and PCI-7251 only.
There are 8 jumpers (JP1 to JP8) on the PCI-7250 and PCI-7251; each associated with one digital input to configure that channel as either AC-Filtered or Non-AC-Filtered. Digital input channels and corresponding jumpers are listed in the table below
JUMPER INPUT SIGNAL
JP1 DI0
JP2 DI1
JP3 DI2
JP4 DI3
JP5 DI4
JP6 DI5
JP7 DI6
JP8 DI7
Table 2-1: Jumpers and DI Channels
The default setting for the input signal selection is Non-AC-Filter (DC signal input), which is shown as below:
JP1
Input Signal Selection
Jumper JP1 - JP8 2-3 1-2
Table 2-2: Input Signal Selection Jumper Settings
12 Installation
Non-AC-Filter
(DC Signal)
AC-Filter
(AC Signal)
Page 23

2.4 Hardware Installation Outline

PCI Configuration

PCI cards (or CompactPCI cards) are equipped with plug and play PCI controllers which can request base addresses and interrupts according to the PCI standard. The system BIOS will assign the system resources based on the PCI card configuration registers and system parameters (which are set by the system BIOS). Inter­rupt assignment and memory usage (I/O port locations) can only be assigned by the system BIOS. These system resource assign­ments are done on a board-by-board basis. It is not suggested to assign the system resource by any other methods.

PCI Slot Selection

The PCI card can be inserted into any PCI slot without any config­uration of the system resources. The CompactPCI card can also be inserted into any CompactPCI I/O slot.

Installation Procedures

1. Turn off your computer
2. Turn off all accessories (printer, modem, monitor, etc.) connected to your computer.
3. Remove the cover from your computer.
4. Setup jumpers on the PCI or CompactPCI card.
5. Select a 32-bit PCI slot. PCI slot are shorter than ISA or EISA slots, and are usually white or ivory.
6. Before handling the PCI cards, discharge any static buildup on your body by touching the metal case of the computer. Hold the edge and do not touch the compo­nents.
7. Position the board into the PCI slot you selected.
8. Secure the card in place at the rear panel of the system.
Installation 13
Page 24

2.5 Device Installation for Windows Systems

Once Windows 95/98/2000 has started, the Plug and Play func­tions of the Windows system will find and locate the new NuDAQ/ NuIPC card. If this is the first time a NuDAQ/NuIPC card is installed in your Windows system, you will be prompted to input the device information source. Please refer to the “Software Instal­lation Guide” for installation procedures for the device drivers.

2.6 Connector Pin Assignments

PCI-7250/51 Pin Assignment

The PCI-7250 card comes equipped with a 37-pin D type connec­tor (CN1) accessible from the rear of the card. The pin assignment of the D type connector is shown in below.
NO0
COM0
NC0
NO1
COM1
NC1
NO2
COM2
NC2
NO7
COM7
DI0
DI1
DI2
DI3
DI4
DI5
DI6
DI7
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Figure 2-3: CN1 - D Type Connector
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
NO3
COM3
NC3
NO4
COM4
NO5
COM5
NO6
COM6
N/C
DI0
DI1
DI2
DI3
DI4
DI5
DI6
DI7
14 Installation
Page 25
Legend
Din:
NC n: Normal close pin of relay n
NO n: Normal open pin of relay n
COM n: Common pin of relay n
N/C: No connection
Table 2-3: CN1 - PCI-7250/51 Pin Assignment
Digital input low, channel n
(input signal Is not polarity sensitive)
Installation 15
Page 26

cPCI-7252 Pin Assignment

Signal Pin Pin Signal
IGND 1 26 IGND
DI8 2 27 DI12
DI9 3 28 DI13
DI10 4 29 DI14
DI11 5 30 DI15
DI0L 6 31 DI4H
DI0H 7 32 DI4L
DI1L 8 33 DI5H
DI1H 9 34 DI5L
D2IL 10 35 DI6H
DI2H 11 36 DI6L
DI3L 12 37 DI7H
DI3H 13 38 DI7L
NO01439NO5
NO11540NO4
COM0 16 41 COM5
COM1 17 42 COM4
NC0 18 43 NC5
NC1 19 44 NC4
NO22045NO7
NO32146NO6
COM2 22 47 COM7
COM3 23 48 COM6
NC2 24 49 NC7
NC3 25 50 NC6
Table 2-4: CN1 - cPCI-7252 Pin Assignment
16 Installation
Page 27
Legend
Din: Digital input channel n
IGND: Ground of DIn signals
DinH: Digital input channel n with positive polarity
DinL: Digital input channel n with negative polarity
NC n: Normal close pin of relay n
NO n: Normal open pin of relay n
COM n: Common pin of relay n

2.7 PCI-7250 and PCI-7251 Connection

There are 8-relay outputs and 8-isolation inputs on both the PCI­7250 and PCI-7251. The PCI-7251 is used as an expansion for the PCI-7250. The operations of the PCI-7251 are the same as that of the PCI-7250. There can be at most 3 PCI-7251 expansion boards to one PCI-7250. Therefore, the PCI-7250 can control up to 32 relays and detect 32 input signals.
Figure 2-4: Connection between PCI-7250 and PCI-7251
Installation 17
Page 28
18 Installation
Page 29

3Registers

Detailed descriptions of the registers are specified in this chapter. This information is useful for programmers who wish to control the card with low-level programming. However, we suggest users fully understand the PCI interface before starting any low-level pro­gramming. In addition, the contents of this chapter will also help users understand how to use the software drivers to configure this card.

3.1 PCI PnP Registers

This PCI card functions as a 32-bit PCI target device to any mas­ter on the PCI bus. There are three types of registers: PCI Config­uration Registers (PCR), Local Configuration Registers (LCR) and 725X registers.
The PCR, which is PCI-bus specification compliant, is initialized and controlled by the Plug and Play (PnP) PCI BIOS. Users may obtain more information on the PCI BIOS specification to better understand the operation of the PCR. Please contact PCISIG to acquire PCI interface specifications.
The PCI bus controller PCI-9050 is provided by PLX Technology Inc. (www.plxtech.com). For more information about the LCR, please visit PLX Technology’s web site to download relative infor­mation. It is not necessary for users to fully understand the details of the LCR if the software library provided is used. The PCI PnP BIOS assigns the base address of the LCR. The assigned address is located at an offset of 14h from the PCR.
The 725X registers are discussed in the next section. The base address, which is also assigned by the PCI PnP BIOS, is located at an offset of 18h from the PCR. Therefore, users can read the address 18h from the PCR to obtain its base address by using the BIOS function call. Do not attempt to modify the base address and interrupt that have been assigned by the PCI PnP BIOS, it may cause resource conflicts with your system.
Registers 19
Page 30

3.2 I/O Address Map

All 725X registers are 8 bits long. Users can access these regis­ters using 8-bit I/O instructions. Using these registers will allow the relays and status of the inputs to be controlled. The following table shows the registers address map, including descriptions and their offset addresses relative to the base address. If the PCI-7251 expansion boards are not installed, corresponding registers have no significance.
Offset Write Read Board
0 Relay Output Output readback
1 Not used Isolation Input
2 Relay Output Output readback
3 Not used Isolation Input
4 Relay Output Output readback
5 Not used Isolation Input
6 Relay Output Output readback
7 Not used Isolation Input
Table 3-1: PCI-7250 Address Map with PCI-7251 Installed
Offset Write Read Board
0 Relay Output Isolation Input
2 Not used Output readback
Table 3-2: cPCI-7252 Address Map
PCI-7250
PCI-7251 #1
PCI-7251 #2
PCI-7251 #3
cPCI-72521 Not used Not used

3.3 Relay Output and Readback Registers

There are 8 relays on each PCI-7250 / 7251 and cPCI-7252 board. Each relay is controlled by one bit in the control register. Bit value ‘0’ means the relay is not energized. The normal open signal line is ‘open’. Bit value ‘1’ means the relay is energized and the normal open signal line is now closed.
The initial bit values of the control register are all ‘0’ and the status of the relay can be readback from the readback register. If the
20 Registers
Page 31
relay is open, the corresponding bit value read is ‘0’. If the relay is closed, the bit value read is ‘1’.
Bit 7 6 5 4 3 2 1 0
Relay Output DO7 DO6 DO5 DO4 DO3 DO2 DO1 DO0
Output Readback RB7 RB6 RB5 RB4 RB3 RB2 RB1 RB0
Table 3-3: Data Format of Relay Output and Readback Status Registers

3.4 Isolation Input Registers

There are 8 isolated input channels on the PCI-7250 / 7251 board. The status of the 8 channels can be read from the isolation input register. Each bit corresponds to each channel. Bit value “1” means input voltage is high and “0” means input voltage is low.
Bit 76543210
Iso. Input DI7 DI6 DI5 DI4 DI3 DI2 DI1 DI0
Bit 15141312111098
Iso. Input DI15 DI14 DI13 DI12 DI11 DI10 DI9 DI8
Table 3-4: Relay Output
Note: Bits 8-15 are for cPCI-7252 only
Registers 21
Page 32
22 Registers
Page 33

4 Operation Theory

4.1 Using Relay Output

The PCI-7250 contains two types of relays: Form C and Form A. Relays R0 - R3 are form C relays, and R4 - R7 are plain form A type. Note that the cPCI-7252 contains Form C relays only. The differences between these two types of relays are:
1. Form C Relay: (R0 - R3)
NO
COM
NC
Control Bit = High (1)
Figure 4-1: Form C Relay
Form C type relays have three contacts: NC (Normal Close), NO (Normal Open), and COM (Common). The COM post, located at the middle, must make contact with either the NO post or NC post. When the control bit is high (1), there is contact between the COM post and NO post. If the control bit is low (0), there is contact between the COM post and NC post.
In normal power-up and reset, the relay is in low status.
NO
COM
NC
Control Bit = Low (0)
Operation Theory 23
Page 34
2. Form A Relay: (R4 - R7)
NO
NO
COM
Control Bit = High(1)
COM
Control Bit = Low(0)
Figure 4-2: Form A Relay
Form A relay only has two contacts: NO (Normal Open) and COM (Common). The COM post can make contact either with the NO post or not. When the control bit is high (1), the COM post and NO post are contacted. If the control bit is low (0), the COM post and NO post does not make contact.
In normal power-up and reset, the relay is in low status.
The relay output contacts are rated at a maximum of 0.5A at 120VAC (resistive), 1A 24VDC, or 0.3A 60VDC. You should reduce these ratings for inductive loads. For more information on relay contact, please refer to the Appendix.
24 Operation Theory
Page 35

4.2 Using Isolated Input

The PCI-7250 (or PCI-7251) contains 8 identical opto-isolated control input channels. The circuit diagram of the differential input channel is shown below.
DInH
IN
V
1.2k
F
I
Ri
DInL
Figure 4-3: PCI-7250 Differential Input Circuit
The digital input is first routed through a photo-coupler (PC-814), which is shown in the following diagram.
The cPCI-7252 contains 16 identical opto-isolated control input channels. The circuit diagram of the differential input signals of channel number 0-7 are the same as of the PCI-7250. While the input signals for channel numbers 8-15 are isolated inputs, the connection is not polarity sensitive whether AC or DC voltage is used.
DInH
IN
V
1.2k
Ri
F
I
IGND
PC-814 (opto-isolator)
PC-814 (opto-isolator)
Figure 4-4: cPCI-7252 Isolated Input Circuit
Operation Theory 25
Page 36
In addition, a single-pole filter with a time constant of about 5ms is used to filter AC inputs passing through.
The normal input voltage range for an active high state is 3 to 24VAC or DC. The normal input range can be extended by chang­ing the resister (Ri) to limit the current (IF) through the PC-814 (opto-isolator to about 10mA). The exact resister value to replace the original resister Ri (1.2K
) can be calculated by the following
formula.
Vin = IF x Ri Pw = Vin x IF
For example, if the input voltage is 110V, then the Ri should be replace by
Ri = 110 (V) / 0.01 (A) = 11 K Pw = 110 (V) X 0.01 (A) = 1.1 W
26 Operation Theory
Page 37

5 C/C++ Libraries

This chapter describes the software libraries for operating this card. Only functions in the DOS library and Windows 95 DLL are described. Refer to the PCIS-DASK function reference manual, which is included in the ADLINK CD, for descriptions of Windows 98/NT/2000 DLL functions.
The function prototypes and useful constants are defined in the header files located in the LIB directory (DOS) and INCLUDE directory (Windows 95). For the Windows 95 DLL, the developing environment can be Visual Basic 4.0 or above, Visual C/C++ 4.0 or above, Borland C++ 5.0 or above, Borland Delphi 2.x (32-bit) or above, or any Windows programming language that allows calls to a DLL.

5.1 Libraries Installation

Refer to the “Software Installation Guide” for information regarding software installation of libraries for DOS, Windows 95 DLL, or PCIS-DASK for Windows 98/NT/2000.
The device drivers and DLL functions for Windows 98/NT/2000 are included in the PCIS-DASK. Refer to the PCIS-DASK user’s guide and function reference, which is included in the ADLINK CD, for programming information.

5.2 Programming Guide

Naming Convention

The functions of the NuDAQ PCI or NuIPC CompactPCI card soft­ware drivers uses full-names to represent the functions' real meaning. The naming convention rules are:
In a DOS Environment:
_{hardware_model}_{action_name}.
e.g. _7250_Initial().
All functions in the PCI-7250 driver start with 7250 as {hardware_model}. All functions in cPCI-7252 driver start with 7252 as {hardware_model}.
C/C++ Libraries 27
Page 38
In order to recognize the difference between the DOS library and Windows 95 library, a capital "W" is placed at the start of each function name for Windows 95 DLL drivers. e.g. W_7252_Initial().

Data Types

We have defined some data types in the Pci_7250.h (DOS) and Acl_pci.h (Windows 95) header files. These data types are used by the NuDAQ card library. We recommend you use these data types in your application programs. The following table shows the
data type names and their range.
Typ e N ame Description Range
U8 8-bit ASCII character 0 to 255
I16 16-bit signed integer -32768 to 32767
U16 16-bit unsigned integer 0 to 65535
I32 32-bit signed long integer -2147483648 to 2147483647
U32 32-bit unsigned long integer 0 to 4294967295
F32 32-bit single-precision floating-point
F64 64-bit double-precision floating-point
Boolean Boolean logic value TRUE, FALSE
Table 5-1: Data Types
-3.402823E38 to
3.402823E38
-1.797683134862315E308 to
1.797683134862315E309

5.3 Running Testing Utility (7250UTIL.EXE)

After finishing the DOS installation, you can execute the utility by typing the following command:
The following:
C> cd\ADLINK\7252\DOS\UTIL (“cd\ADLINK\7250\DOS\util” for PCI-7250) C> 7252UTIL
The following interface will be displayed on the screen.
28 C/C++ Libraries
Page 39
You can use this program to test the functionality of the digital inputs and outputs.
A detailed description of each function is specified in the proceed­ing sections.
C/C++ Libraries 29
Page 40

5.4 725X Initialization

@ Description

The PCI-7250 and cPCI-7252 cards are initialized according to the card number. Because the PCI-7250 has a PCI bus architecture and meets the plug and play design specification, the IRQ and base_address (pass-through address) are assigned by the system BIOS directly. Every PCI-7250 card has to be initialized by this function before calling any other functions.
Note: Because the configuration of PCI card is handled by the sys­tem, there are no jumpers or IRQ selection on the PCI board that needs to be set up by the users.

@ Syntax

C/C++ (DOS)
U16 _7250_Initial (U16 *existCards, PCI_INFO
*pciInfo)
U16 _7252_Initial (U16 *existCards, PCI_INFO
*pciInfo)
C/C++ (Windows 95)
U16 W_7250_Initial (U16 *existCards, PCI_INFO
*pciInfo)
U16 W_7252_Initial (U16 *existCards, PCI_INFO
*pciInfo)
Visual Basic (Windows 95)
W_7250_Initial (existCards As Integer, pciInfo As
PCI_INFO) As Integer
W_7252_Initial (existCards As Integer, pciInfo As
PCI_INFO) As Integer

@ Arguments

existCards: The number of installed PCI-7250 cards. The returned value shows how many PCI-7250 cards are installed in your system.
pciinfo: It is a structure to memorize the PCI bus plug and play initialization information, which is decided by the P&P BIOS. The PCI_INFO structure is defined in ACL_PCI.H. The base I/O
30 C/C++ Libraries
Page 41
addresses and the interrupt channel number are stored in pciinfo, which is for reference.

@ Return Code

ERR_NoError, ERR_PCIBiosNotExist
C/C++ Libraries 31
Page 42

5.5 _7250_DI, _7252_DI

@ Description

This function is used to read data from the digital input port. There are eight 8-bit digital inputs on the PCI-7250 or PCI-7251 extended board. You can obtain all 32 input data from using the _7250_DI function.

@ Syntax

C/C++ (DOS)
U16 _7250_DI (U16 cardNo, U16 diPortNo, U16
*diData)
U16 _7252_DI (U16 cardNo, U16 *diData)
C/C++ (Windows 95)
U16 W_7250_DI (U16 cardNo, U16 diPortNo, U16
*diData)
U16 W_7252_DI (U16 cardNo, U16 *diData)
Visual Basic (Windows 95)
W_7250_DI (ByVal cardNo As Integer, ByVal
diPortNo As Integer, diData As Integer) As Integer
W_7252_DI (ByVal cardNo As Integer, diData As
Integer) As Integer

@ Arguments

cardNo: card number selected
diPortNo: Digital Input Channel No, the constant is:.
DI_PORT0 0x00 Access the 8 Digital Input of PCI-7250
DI_PORT1 0x01 Access the 8 Digital Input of Expansion Board PCI-7251#1
DI_PORT2 0x02 Access the 8 Digital Input of Expansion Board PCI-7251#2
DI_PORT3 0x03 Access the 8 Digital Input of Expansion Board PCI-7251#3
Note: This argument is not necessary for cPCI-7252
diData: return 8-bit value from digital port.
32 C/C++ Libraries
Page 43

@ Return Code

ERR_NoError ERR_BoardNoInit
C/C++ Libraries 33
Page 44

5.6 _7250_DO, _7252_DO

@ Description

This function is used to write data to the digital output port. This energizes or de-energizes the RELAY. There are 8 digital outputs on the PCI-7250 or PCI-7251 extended board. You can control all 32 RELAY’s through using the _7250_DO function.

@ Syntax

C/C++ (DOS)
U16 _7250_DO (U16 cardNo, U16 doPortNo, U16
doData)
U16 _7252_DO (U16 cardNo, U16 doData)
C/C++ (Windows 95)
U16 W_7250_DO (U16 cardNo, U16 doPortNo, U16
doData)
U16 W_7252_DO (U16 cardNo, U16 doData)
Visual Basic (Windows 95)
W_7250_DO (ByVal cardNo As Integer, ByVal
doPortNo As Integer, ByVal doData As Integer) As Integer
W_7252_DO (ByVal cardNo As Integer, ByVal doData
As Integer) As Integer

@ Arguments

cardNo: card number selected
doChannelNo: Digital Output Channel No, the constant is:.
DI_PORT0 0x00 Access the 8 Digital Input of PCI-7250
DI_PORT1 0x01 Access the 8 Digital Input of Expansion Board PCI-7251#1
DI_PORT2 0x02 Access the 8 Digital Input of Expansion Board PCI-7251#2
DI_PORT3 0x03 Access the 8 Digital Input of Expansion Board PCI-7251#3
Note: This argument is not necessary for cPCI-7252
doData: value will be written to digital output port
34 C/C++ Libraries
Page 45

@ Return Code

ERR_NoError, ERR_BoardNoInit

5.7 _7250_DO_Read_Back, _7252_DO_ReadRelay

@ Description

This function is used to read-back data from the digital output port which is control by the 725X_DO function. There are 8-bit digital outputs on the PCI-7250, cPCI-7252, or PCI-7251 extended board. You can readback all RELAY status (High or Low) by using this function.

@ Syntax

C/C++ (DOS)
U16 _7250_DO_Read_Back (U16 cardNo, U16
doChannelNo, U8 *doReadBackData)
U16 _7252_DO_ReadRelay (U16 cardNo, U16
doReadBackData)
C/C++ (Windows 95)
U16 W_7250_DO_Read_Back (U16 cardNo, U16
doChannelNo, U16 *doReadBackData)
U16 W_7252_DO_ReadRelay (U16 cardNo, U16
*doReadBackData)
Visual Basic (Windows 95)
W_7250_DO_Read_Back (ByVal cardNo As Integer,
ByVal doChannelNo As Integer, doReadBackData As Integer) As Integer
W_7252_DO_ReadRelay (ByVal cardNo As Integer,
doReadBackData As Integer) As Integer

@ Arguments

cardNo: card number selected
doChannelNo: Digital Output Channel No, the constant is:
DI_PORT0 0x00 Access the 8 Digital Input of PCI-7250
DI_PORT1 0x01 Access the 8 Digital Input of Expansion Board PCI-7251#1
DI_PORT2 0x02 Access the 8 Digital Input of Expansion Board PCI-7251#2
C/C++ Libraries 35
Page 46
DI_PORT3 0x03 Access the 8 Digital Input of Expansion Board PCI-7251#3
Note: This argument is not necessary for cPCI-7252
diReadBackData: value read back from digital output port

@ Return Code

ERR_NoError, ERR_BoardNoInit
36 C/C++ Libraries
Page 47

5.8 _7251_Check_Exist

@ Description

This function is used to check the existence of the PCI-7251 expanded board. For normal configuration, each PCI-7250 can be connected with up to three PCI-7251 boards. This function is used to detect the presence of the PCI-7251.

@ Syntax

C/C++ (DOS)
U16 _7251_Check_Exist (U16 cardNo, U16 extnesionBoardNo)
C/C++ (Windows 95)
U16 _7251_Check_Exist (U16 cardNo, U16 extnesionBoardNo)
Visual Basic (Windows 95)
W_7251_Check_Exist (ByVal cardNo As Integer,
ByVal extensionBoardNo As Integer) As Integer

@ Argument

cardNo: card number to select borad
existBoardNo: Extension PCI-7251 No.
PCI_7251_EX1 0x01 PCI-7251 Board #1
PCI_7251_EX2 0x02 PCI-7251 Board #2
PCI_7251_EX3 0x03 PCI-7251 Board #3

@ Return Code

PCI_7251_EXIST 1 PCI_7251_NOT_EXIST 0
C/C++ Libraries 37
Page 48
38 C/C++ Libraries
Page 49

Appendix

Relay Contact Protection Circuits

The contacts are the most important elements of a relay construc­tion, Contact performance conspicuously influenced by contact material, and voltage and current values applied to the contacts.
Another important issue is contact protection; the right contact pro­tection circuit can suppress the counter EMF to a low level. How­ever, note that incorrect use will result in an adverse effect. Typical contact protection circuits are given below:

RC Circuit

This circuit is suitable for DC applications. If the load is a timer, leakage current flow through the RC circuit may cause faulty oper­ation.
Contact
R C
Inductive
Load
The circuit below is suitable for both DC and AC applications. If the load is a relay or solenoid, the release time is lengthened. Effective when connected to both contacts if the power supply volt­age is 24V or 48V and the voltage cross the load is 100 to 200V.
Contact
R C
Inductive
Load
Appendix 39
Page 50
Device Selection:
As a guide in selecting R and C,
X R: 0.5 to 1 per 1V contact voltage
X C: 0.5 to 1µF per 1A contact current
Values vary depending on the properties of the capacitor C acting to suppress the discharge the moment the contacts open. Resistor R acts to limit the current when the power is turned on. Test to confirm. Use a capacitor with a breakdown voltage of 200 to 300V. Use AC type capacitors (non-polarized) for AC circuits.

Diode Circuit

This circuit is suitable for DC applications. The diode connected in parallel causes the energy stored in the coil to flow to the coil in the form of current and dissipates it as joule heat at the resistive component of the inductive load. This circuit further delays the release time compared to the RC circuit.
Contact
Diode
Inductive
Load
Device Selection:
Use a diode with a reverse breakdown voltage of at least 10 times the circuit voltage and a forward current at least as large as the load current.
40 Appendix
Page 51

Diode & Zener diode Circuit

This circuit is also suitable for DC application. Effective when the release time i in the diode circuit is too long.
Contact
Diode
Inductive
Load
Device Selection:
Use a zener diode with a zener voltage about the same as the power supply voltage.

Varistor Circuit

This circuit is also suitable for both AC & DC applications. Using the stable voltage characteristics of the varistor, this circuit pre­vents excessively high voltages from being applied across the contacts. This circuit also slightly delays the release time. Effective when connected to both contacts if the power supply voltage is 24V or 48V and the voltage cross the load is 100 to 200V.
Contact
Diode
Inductive
Load
Appendix 41
Page 52
42 Appendix
Page 53

Warranty Policy

Thank you for choosing ADLINK. To understand your rights and enjoy all the after-sales services we offer, please read the follow­ing carefully.
1. Before using ADLINK’s products please read the user man­ual and follow the instructions exactly. When sending in damaged products for repair, please attach an RMA appli­cation form which can be downloaded from: http:// rma.adlinktech.com/policy/.
2. All ADLINK products come with a two-year guarantee:
X The warranty period starts from the product’s shipment
date from ADLINK’s factory.
X Peripherals and third-party products not manufactured
by ADLINK will be covered by the original manufactur­ers' warranty.
X For products containing storage devices (hard drives,
flash cards, etc.), please back up your data before send­ing them for repair. ADLINK is not responsible for loss of data.
X Please ensure the use of properly licensed software with
our systems. ADLINK does not condone the use of pirated software and will not service systems using such software. ADLINK will not be held legally responsible for products shipped with unlicensed software installed by the user.
X For general repairs, please do not include peripheral
accessories. If peripherals need to be included, be cer­tain to specify which items you sent on the RMA Request & Confirmation Form. ADLINK is not responsible for items not listed on the RMA Request & Confirmation Form.
Warranty Policy 43
Page 54
3. Our repair service is not covered by ADLINK's two-year guarantee in the following situations:
X Damage caused by not following instructions in the
user's manual.
X Damage caused by carelessness on the user's part dur-
ing product transportation.
X Damage caused by fire, earthquakes, floods, lightening,
pollution, other acts of God, and/or incorrect usage of voltage transformers.
X Damage caused by unsuitable storage environments
(i.e. high temperatures, high humidity, or volatile chemi­cals).
X Damage caused by leakage of battery fluid during or
after change of batteries by customer/user.
X Damage from improper repair by unauthorized techni-
cians.
X Products with altered and/or damaged serial numbers
are not entitled to our service.
X Other categories not protected under our warranty.
4. Customers are responsible for shipping costs to transport damaged products to our company or sales office.
5. To ensure the speed and quality of product repair, please download an RMA application form from our company web­site: http://rma.adlinktech.com/policy. Damaged products with attached RMA forms receive priority.
If you have any further questions, please email our FAE staff: service@adlinktech.com.
44 Warranty Policy
Loading...