beautypg.com

ADLINK ACL-8111 User Manual

Page 55

background image

C/C++ Library for DOS 49

5.17 _8111_AD_Timer

@ Description

This function is used to setup the Timer #1 and Timer #2. Timer #1 & #2
are used as frequency divider for generating constant A/D sampling rate
dedicatedly. It is possible to stop the pacer trigger by setting any one of the
dividers as 0. The AD conversion rate is limited due to the conversion time
of the AD converter, the highest sampling rate of the ACL-8111 can not be
exceeded 30 KHz,Thus the multiplication of the dividers must be larger
than 70.

@ Syntax

int _8111_AD_Timer( unsigned int c1 , unsigned int

c2 )

@ Argument:

c1:

frequency divider of timer #1

c2:

frequency divider of timer #2,

@ Return Code:

ERR_NoError
ERR_BoardNoInitERR_InvalidTimerValue

@ Example:

main()
{

int ErrCode;

_8111_Initial( CARD_1, 0x220 );

/* Assume ERR_NoError when Initialize ACL-
8111 */

_8111_AD_Timer( 100 , 100 );

/* set AD sampling rate to 2MHz/(10*10) */


..

_8111_AD_Timer( 0 , 0 );

/* stop the pacer trigger */

}