User`s guide

54 C/C++ Library
5.11 _8316_DA
@ Description
This function is used to write data to D/A converters. There are two
Digital-to-Analog conversion channels on the ACL-8316/12. The
resolution of each channel is 12-bit; its data format can be binary or two‘s
complement format. Which data format is used for this function, depends
on the setting of function _8316_DA_Set_Mode().
@ Syntax
I16 _8316_DA( U8 da_ch_no, I16 da_data )
@ Argument
da_ch_no: D/A channel number, DA_CH_1 or DA_CH_2.
da_data: D/A converted value, the data format of binary and 2‘s
complement are shown as the table below:
Digital Input Digital Input Analog Output
Binary Format 2‘s complement Unipolar
0 to 10V
Bipolar
-10V to 10V
FFF hex 7FFhex +9.9976V +9.9951V
800 hex 000 hex +5.0000V 0.0000V
7FF hex FFF hex +4.9976V -0.0049V
000 hex 800 hex 0.0000V -10.0000V
1LSB 1 LSB 2.44mV 4.88mV
@ Return Code
ERR_NoError, ERR_BoardNoInit, ERR_InvalidDAChannel
5.12 _8316_AD_Set_Channel
@ Description
This function is used to set AD channel by means of writing data to the
multiplexer scan channel register. There are 16 single-ended or 8
differential A/D channels in ACL-8316/12, so the channel number should
be set either 0~15 or 0~7. The initial state is channel 0 which is a default
setting by the ACL-8316/12 hardware configuration.
@ Syntax
I16 _8316_AD_Set_Channel( U8 ad_ch_no )