VXI VM4016 User Manual

Page 46

Advertising
background image

VXI Technology, Inc.

46

VM4016 Programming

ViPInt16

first_latched_reg

- This parameter returns the first input channel which crosses the
programmed threshold voltage.

ViPInt16 raw_data

- This returns the 16 bit value that represents the current
unconditioned [raw] state of the inputs.

ViPInt16

conditioned_data

- This returns the 16 bit value that represents the current
conditioned state of the inputs.

Return Values:

Returns VI_SUCCESS if successful, else returns error
value.

Description

This is an application function that shows how the
user can use core functions to enable/disable the
specified channels for interrupt generation and
configure the specified channels’ various parameters
such as offset, polarity and voltage-range. It returns
the value of the First Latched register which records
the first input channel to cross its threshold and
queries the current state of the inputs. Note that
this function resets the module to its default state.

***************************************************************************/

ViStatus_VI_FUNC vtvm4016_setup_and_read_data(ViSession instr_hndl,

ViInt16 channel_list[],ViInt16 num_of_channels,ViReal32
offset[],ViInt16 polarity[],ViInt16 voltage_range[],

ViPInt16 first_latched_reg,ViPInt16 raw_data,

ViPInt16 conditioned_data)

{

/* Variable used to store return status of the function */

ViStatus status = VI_NULL;

Advertising