5.22 _9112_AD_INT_Start

uDescription

The function will perform A/D conversion N times with interrupt data transfer. It takes place in the background which will not stop until the N-th conversion has been completed or your program execute _9112_AD_INT_Stop() function to stop the process. After executing this function, it is necessary to check the status of the operation by using the function 9112_AD_INT_Status(). The function is performed on single A/D channel with fixed analog input range.

uSyntax

Visual C++(Windows-95)

int W_9112_AD_INT_Start(int card_number, int auto_scan, int ad_ch_no, int ad_range, int count, unsigned long *ad_buffer,

int c1, int c2)

Visual Basic (Windows-95)

W_9112_ AD_INT_Start (ByVal card_number As Long, ByVal auto_scan As Long, ByVal ad_ch_no As Long, ByVal ad_range As Long, ByVal count As Long, ad_buffer As Integer,ByVal c1 As Long, ByVal c2 As Long) As Long

C/C++ (DOS)

int _9112_INT_Start (int card_number, int auto_scan, int ad_ch_no, int ad_range,int count, unsigned long *ad_buffer, int c1, int c2)

uArgument

card_number : the card number of PCI-9112

auto_scan : TRUE or FALSE

Example1 : auto_scan is FALSE, ad_ch_no is 3. Using DMA mode to read A/D data only channel 3.

Example2 : auto_scan is TRUE, ad_ch_no is 3. Using INT mode to read A/D data with multi-channel , channel 3, 2, 1 and 0. Reading sequence is channel 3,2,1,0, 3,2,1,0,3,2,1,0....

ad_ch_no : A/D channel number

ad_range : A/D analog input range, please refer to the section 4.3.8 for the possible values.

count : the number of A/D conversion

ad_buffer : the start address of the memory buffer to store the AD data, the buffer size must large than the number of AD conversion.

In DOS environment, please make sure this memory is double-word alignment. Every 16-bit unsigned integer data in ad_buffer:

C/C++ Library 59