pipx40_getMaskPattern

 

VB

Function

pipx40_getMaskPattern (ByVal vi As Long, ByVal subUnit As Long, ByRef pattern As Long) As Long

C++

ViStatus

pipx40_getMaskPattern (ViSession vi, ViUInt32 subUnit, ViPUInt32 pattern);

 

Parameter

I/O

Description

vi

in

Instrument handle

subUnit

in

Numeric variable indicating in which sub-unit actions will take place

pattern

out

Pointer/reference to the one-dimensional array (vector) to receive result

Return Value

0 = Successful operation. Negative values are error codes and positive values are warnings. To get a description of the error, pass the error code to pipx40_error_message.

Description

Obtains the switch mask of a sub-unit.

Remarks

The result fills the number of least significant bits corresponding to the size of the sub-unit.

 

For a Matrix sub-unit, the result is folded into the vector on its row-axis. See Data formats.

Warning

The data array pointed to must contain sufficient bits to hold the bit-pattern for the specified sub-unit, or adjacent memory will be overwritten, causing data corruption and/or a program crash.

Visual Basic Note

To use this function in Visual Basic, it must be passed a pointer to the first element of the data array. For example (assuming a zero-based array):

pipx40_getMaskPattern(vi, subUnit, pattern(0))

Example Code

See the description of pipx40_setChannelPattern for example code using a pattern-based function.