National Instruments 321645c-01 Welding System User Manual


 
Chapter 2 Function Reference GPCTR_Config_Buffer
©
National Instruments Corporation 2-209 NI-DAQ FRM for PC Compatibles
GPCTR_Config_Buffer
Format
status = GPCTR_Config_Buffer (deviceNumber, gpctrNum, reserved, numPoints, buffer)
Purpose
Assigns a buffer that NI-DAQ will use for a buffered counter operation.
Parameters
Input
Parameter Discussion
The legal range for gpctrNum is given in terms of constants defined in a header file. The
header file you should use depends on the language you are using:
C programmers—
NIDAQCNS.H (DATAACQ.H for LabWindows/CVI)
BASIC programmers—
NIDAQCNS.INC (Visual Basic for Windows programmers should
refer to the Programming Language Considerations section in Chapter 1, Using the
NI-DAQ Functions, for more information.)
Pascal programmers—
NIDAQCNS.PAS
gpctrNum to indicates which counter to program. Legal values for this parameter are in
Table 2-20.
numPoints is the number of data points the buffer can hold. The definition of a data point
depends on the application the counter is used for. Legal range is 2 through 2
32
– 1.
When you use the counter for one of the buffered event counting or buffered time
measurement operations, a data point is a single counted number.
buffer is an array of unsigned 32-bit integers.
Name Type Description
deviceNumber i16 assigned by configuration utility
gpctrNum u32 number of the counter to use
reserved u32 reserved parameter, must be 0
numPoints u32 number of data points the buffer can hold
buffer [u32] used to hold counts