ACLS-LVIEW1 VIs

for LabVIEWâ for Windows

 

@Copyright 1996

All Rights Reserved.

Manual edition 15, March 1996

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, special, 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 copyright. All rights are reserved. No part of this manual may be reproduced by any mechanical, electronic, or other means in any form without prior written permission of the manufacturer.

 

Trademarks

IBM PC is a registered trademark of International Business Machines Corporation. Intel is a registered trademark of Intel Corporation. Other product names mentioned herein are used for identification purposes only and may be trademarks and/or registered trademarks of their respective companies.

 

Contents 

About This Manual

Organization of This Manual

LabVIEW Data Types

1. Installation

2. Function Descriptions

48DIO Config

7120 Config

7122 Config

7124 Config

7125 Config

7225 Config

Config Digital Port

Read from Digital Line

Read from Digital Port

Readback from Digital Line

Readback from Digital Port

Write to Digital Line

Write to Digital Port

Release Card

Appendix A: Error Codes

 

 

About This Manual

This manual describes the ACLS-LVIEW1 VIs that support the ADLink‘s digital I/O cards ACL-7120, ACL-7122, ACL-7124, ACL-7125, ACL-7225, and PET-48DIO. It helps you to know how to install and use the VIs to meet your requirements.

Organization of This Manual

This manual is divided into two chapters:

· Chapter 1, "Installation" describes how to install the software.

· Chapter 2, "Function Descriptions" contains the reference descriptions of the VIs.

LabVIEW Data Types

Each VI description gives a data type picture for each input and output parameter, as shown in the following table.

 

Control

Indicator

Data Type

Signed 8-bit integer

Signed 16-bit integer

Unsigned 16-bit integer

 

1

 

Installation

step 1. Place the diskette in the appropriate 3.5" floppy drive

( A: or B:). Suppose this drive is <src_drv>.

 

step 2. Typing

 

<src_drv>\install <src_drv> <labview_dir>

 

in DOS or Windows DOS Prompt.

 

where the <src_drv> is the floppy drive you place the diskette, <labview_dir> is the LabVIEW directory. For example, if you place diskette in A: and LabVIEW directory is c:\labview, then you have to type the command:

 

a:\install a: c:\labview

 

 

When you have completed the installation process, the following files and subdirectories will be added in your LabVIEW directory:

 

 

 

File/Subdirectory

Description

7225_DIO.VI

This is a sample program for using ACL-7225 VIs.

7124_DIO.VI

This is a sample program for using ACL-7124 VIs.

ACL.LIB\ADLINK\ACL_LV1.LLB

ACLS-LVIEW1 VIs

DASK.DLL

Windows dynamic linked library (DLL) that is called by ACLS-LVIEW1 VIs

 

 

 

When you restart LabVIEW, select Functions menu in Diagram window, you can see a new entry ADLINK.

 

 

 

 

 

 

Click on ADLINK, you can see there is a set of VIs named ACLS-LVIEW1 VIs under ADLINK.

 

 

 

 

 

ACLS-LVIEW1 VIs contains 14 functions.

 

 

 

When you select a function of this VIs, LabVIEW may prompt you the following dialog box for you to make sure the DLL it called. Just select the DASK.DLL in LabVIEW directory.

 

 

2

Function Descriptions

The functionality of ACLS-LVIEW1 VIs can be classified to the following capabilities,

 

1. Configuration : setup the hardware base I/O address

2. Release : release the hardware

3. Digital I/O : input or output digital signals

 

In addition, one sample program is also included in this disk. It will help you to understand how to use the library more quickly.

 

The detailed description of each VI is specified in the following sections.

 

48DIO Config

 

An PET-48DIO card is configured according the corresponding base address. Every PET-48DIO digital I/O card have to be configured by this VI before using other VI.

 

 

 

 

base address : the I/O port base address of the card . See PET-48DIO manual for details.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. The 48DIO Config VI is often the first sub VI called in your diagram, and you may not need to wire this input. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : A numeric card id for the card configured. The range of cardID out is between 0 and 31. The value of this output terminal is used as the value of input terminal cardID in of other ACLS-LVIEW1 VIs.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

PET-48DIO

 

7120 Config

 

An ACL-7120 card is configured according the corresponding base address. Every ACL-7120 digital I/O card have to be configured by this VI before using other VI.

 

 

 

 

base address : the I/O port base address of the card . See ACL-7120 manual for details.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. The 7120 Config VI is often the first sub VI called in your diagram, and you may not need to wire this input. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : A numeric card id for the card configured. The range of cardID out is between 0 and 31. The value of this output terminal is used as the value of input terminal cardID in of other ACLS-LVIEW1 VIs.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-7120, ACL-720, PCL-720

 

 

7122 Config

 

An ACL-7122 card is configured according the corresponding base address. Every ACL-7122 digital I/O card have to be configured by this VI before using other VI.

 

 

 

 

base address : the I/O port base address of the card . See ACL-7122 manual for details.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. The 7122 Config VI is often the first sub VI called in your diagram, and you may not need to wire this input. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : A numeric card id for the card configured. The range of cardID out is between 0 and 31. The value of this output terminal is used as the value of input terminal cardID in of other ACLS-LVIEW1 VIs.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-7122, ACL-722, PCL-722

 

 

7124 Config

 

An ACL-7124 card is configured according the corresponding base address. Every ACL-7124 digital I/O card have to be configured by this VI before using other VI.

 

 

 

 

base address : the I/O port base address of the card. See ACL-7124 manual for details.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. The 7124 Config VI is often the first sub VI called in your diagram, and you may not need to wire this input. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : A numeric card id for the card configured. The range of cardID out is between 0 and 31. The value of this output terminal is used as the value of input terminal cardID in of other ACLS-LVIEW1 VIs.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-7124, ACL-724, PCL-724

 

7125 Config

 

An ACL-7125 card is configured according the corresponding base address. Every ACL-7125 digital I/O card have to be configured by this VI before using other VI.

 

 

 

 

base address : the I/O port base address of the card. See ACL-7125 manual for details.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. The 7125 Config VI is often the first sub VI called in your diagram, and you may not need to wire this input. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : A numeric card id for the card configured. The range of cardID out is between 0 and 31. The value of this output terminal is used as the value of input terminal cardID in of other ACLS-LVIEW1 VIs.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-7125, ACL-725, PCL-725

 

 

7225 Config

 

An ACL-7225 card is configured according the corresponding base address. Every ACL-7225 digital I/O card have to be configured by this VI before using other VI.

 

 

 

 

base address : the I/O port base address of the card. See ACL-7225 manual for details.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. The 7225 Config VI is often the first sub VI called in your diagram, and you may not need to wire this input. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : A numeric card id for the card configured. The range of cardID out is between 0 and 31. The value of this output terminal is used as the value of input terminal cardID in of other ACLS-LVIEW1 VIs.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-7225, ACL-725B

 

Config Digital Port

This function is used to configure the specified port for direction (input or output). For those types of cards that do not emulate MODE 0 of 8255 PPI, this function is not needed.

 

 

 

cardID in : The card to be used for analog input. This terminal should be wired from an output terminal cardID out of a VI of ACLS-LVIEW1 VIs.

port : To indicate which port to configure. Valid value:

48DIO: 0 through 5

7122: 0 through 17

7124: 0 through 2

direction : The direction, input or output, to which the port is to be configured. A value of 0 means input, 1 means output.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : Has the same value as cardID in.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

PET-48DIO, ACL-7122, ACL-7124, ACL-722, ACL-724,

PCL-722, PCL-724.

 

Read from Digital Line

 

This function is used to read the digital logic state of the specified digital line in the specified port.

 

 

 

 

cardID in : The card to be used for digital input. This terminal should be wired from an output terminal cardID out of a VI of ACLS-LVIEW1 VIs.

port : To indicate which port is read.

Valid value:

48DIO: 0 through 5

7120: 0 through 3

7122: 0 through 17

7124: 0 through 2

7125: 0

7225: 0 through 1

The default input is port 0.

line : The digital line to be read. The valid value of line is 0 through 7. The default input is line 0.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : Has the same value as cardID in.

DI data : Returns the digital logic state, 0 or 1, of the specified line.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

Cards Support

ACL-48DIO, ACL-7120, ACL-7122, ACL-7124, ACL-7125, ACL-7225, ACL-720, ACL-722, ACL-724, ACL-725, ACL-725B, PCL-722, PCL-725, PCL-720.

 

 

Read from Digital Port

 

This function is used to read data from digital input port.

 

 

 

 

cardID in : The card to be used for digital input. This terminal should be wired from an output terminal cardID out of a VI of ACLS-LVIEW1 VIs.

port : To indicate which port is read.

Valid value:

48DIO: 0 through 5

7120: 0 through 3

7122: 0 through 17

7124: 0 through 2

7125: 0

7225: 0 through 1

The default input is port 0.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : Has the same value as cardID in.

DI data : The 8-bit digital data read from digital port.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-48DIO, ACL-7120, ACL-7122, ACL-7124, ACL-7125, ACL-7225, ACL-720, ACL-722, ACL-724, ACL-725,

ACL-725B, PCL-722, PCL-725, PCL-720.

 

 

 

 

Readback from Digital Line

 

This function is used to read back the last digital logic state that set to the specified digital line in the specified port. For those types of cards that emulates 8255 PPI, the port must be configured as a output port.

 

 

 

 

cardID in : The card to be used for digital input. This terminal should be wired from an output terminal cardID out of a VI of ACLS-LVIEW1 VIs.

port : To indicate which port is read.

Valid value:

48DIO: 0 through 5

7120: 0 through 3

7122: 0 through 17

7124: 0 through 2

7125: 0

7225: 0 through 1

The default input is port 0.

line : The digital line to be read. The valid value of line is 0 through 7. The default input is line 0.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : Has the same value as cardID in.

DI data : Returns the digital logic state, 0 or 1, of the specified line.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

Cards Support

ACL-48DIO, ACL-7120, ACL-7122, ACL-7124, ACL-7125, ACL-7225, ACL-720, ACL-722, ACL-724, ACL-725,

ACL-725B, PCL-722, PCL-725, PCL-720.

 

 

Readback from Digital Port

 

This function is used to read back the last digital data written to the specified digital I/O port. For those types of cards that emulate 8255 PPI, the port must be configured as a output port.

 

 

 

 

cardID in : The card to be used for digital input. This terminal should be wired from an output terminal cardID out of a VI of ACLS-LVIEW1 VIs.

port : To indicate which port is read.

Valid value:

48DIO: 0 through 5

7120: 0 through 3

7122: 0 through 17

7124: 0 through 2

7125: 0

7225: 0 through 1

The default input is port 0.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : Has the same value as cardID in.

DI data : The 8-bit digital data read from digital port.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-48DIO, ACL-7120, ACL-7122, ACL-7124, ACL-7125, ACL-7225, ACL-720, ACL-722, ACL-724, ACL-725,

ACL-725B, PCL-722, PCL-725, PCL-720.

 

 

Write to Digital Line

This function is used to set the specified digital output line in the specified digital port to the specified state.

 

 

 

 

cardID in : The card to be used for digital output. This terminal should be wired from an output terminal cardID out of a VI of ACLS-LVIEW1 VIs.

port : To indicate which port is data written to.

Valid value:

48DIO: 0 through 5

7120: 0 through 3

7122: 0 through 17

7124: 0 through 2

7125: 0

7225: 0 through 1

The default input is port 0.

line : the digital output line to be written to. The valid value of line is 0 through 7. The default output is line 0.

DO data : the new digital logic state, 0 or 1.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : Has the same value as cardID in.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-48DIO, ACL-7120, ACL-7122, ACL-7124, ACL-7125, ACL-7225, ACL-720, ACL-722, ACL-724, ACL-725,

ACL-725B, PCL-722, PCL-725, PCL-720.

 

 

Write to Digital Port

This function is used to write data to digital output ports.

 

 

 

 

cardID in : The card to be used for digital output. This terminal should be wired from an output terminal cardID out of a VI of ACLS-LVIEW1 VIs.

port : To indicate which port is data written to.

Valid value:

48DIO: 0 through 5

7120: 0 through 3

7122: 0 through 17

7124: 0 through 2

7125: 0

7225: 0 through 1

The default input is port 0.

DO data : The value that will be written to digital output port.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

cardID out : Has the same value as cardID in.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-48DIO, ACL-7120, ACL-7122, ACL-7124, ACL-7125, ACL-7225, ACL-720, ACL-722, ACL-724, ACL-725,

ACL-725B, PCL-722, PCL-725, PCL-720.

 

 

Release Card

 

There are at most 32 ADLink‘s data acquisition cards that can be configured to perform operation simultaneously. This function is used to tell system this card is not used currently and can be released. This would make room for new card to configured for operation.

 

 

 

cardID in : The card to be released.

error in : The error conditions occurring before this VI executes. This code default to no error. If an error has already occurred, this VI does not perform any operation. A value of 0 means no error, a negative value means an error. Refer to Appendix A, Error Codes, for a code descriptions.

error out : Error code. If the error in indicated an error, the error out contains the same value. Otherwise, error out describes the error status of this VI.

 

Cards Support

ACL-48DIO, ACL-7120, ACL-7122, ACL-7124, ACL-7125, ACL-7225, ACL-720, ACL-722, ACL-724, ACL-725,

ACL-725B, PCL-722, PCL-725, PCL-720.

 

Appendix A: Error Codes

Table A. The error code for ACLS-LVIEW1 VIs.

 

Code

Name

Description

0

NoError

No error occurred

-2

BadBaseAddress

The base address is not valid.

-3

TooManyRegisteredCards

There have been 32 cards that were configured.

-4

CardNotRegistered

No card is configured successfully as the id as the value of input terminal cardID in.

-21

NotInputPort

The input port that input terminal port specified is not configured as an input port.

-22

NotOutputPort

The output port that input terminal port specified is not configured as an output port.

-23

InvalidDIOPort

The value of input terminal port is out of range.

-24

InvalidDIOLine

The value of input terminal line is out of range.

 



©1995 Circuit Specialists, Inc.