uSyntax
Visual C++ (Window
int W_9112_AD_Set_Mode (int card_number, int ad_mode)
Visual Basic
W_9112_AD_Set_Mode (ByVal card_number As Long, ByVal ad_mode As Long) As Long
C/C++ ( DOS)
int _9112_AD_Set_Mode (int card_number, int ad_mode )
uArgument
card_number : the card number of
ad_mode : AD trigger and data transfer mode
( please refer to above table.)
uReturn Code
ERR_NoError
ERR_BoardNoInit ERR_InvalidMode
uExample
#include “9112.h” main()
{
Int baseAddr, irqNo;
_9112_Initial( CARD_1, &baseAddr, &irqNo);
/* Assume NoError when Initialize
_9112_AD_Set_Range(CARD_1, AD_B_5_V );
printf( "The A/D analog input range is +/- 5V \n" );
_9112_AD_Set_Mode(CARD_1, AD_MODE_4 );
printf( "Now, The Internal Timer Pacer trigger is set \n" );
/* All A/D conversion will be trigger by internal timer pacer, and the converted data should be transfered in the interrupt service routine. ( ISR). */
}
5.11 _9112_AD_Set_Autoscan
uDescription
This function is used to set automatic hardware channel scan to be enable or disable. If the