int32_t mpiSqNodeAnalogInPtr(MPISqNode   sqNode,
                          int32_t        channel,
                          int32_t        *mask,
int32_t **ptr);


Required Header: stdmpi.h

Change History: Added in 03.04.00.


mpiSqNodeAnalogInPtr gets a controller memory pointer and mask of an analog input (channel on the SynqNet node sqNode) and writes them to the locations pointed to by ptr and mask. The memory pointer and mask obtained by this function can be used when setting up the data recorder or user limits.

sqNode a handle to a SynqNet node object.
channel an index to a node's analog input channel.
*mask a pointer to a bitwise mask that corresponds to the specified word.
**ptr a pointer to a controller address that contains the analog input word.
Return Values

Sample Code

The sample code below shows how to set up the data recorder to record analog channel 2 on node 1.

int32_t mask;
int32_t * pointer;
mpiSqNodeAnalogInPtr( sqNode1, 2, &mask, &pointer );
void * points[MPIRecorderADDRESS_COUNT_MAX]; points[0] = pointer; int32_t pointCount = 1; mpiRecorderRecordConfig(recorder, MPIRecorderRecordTypePOINT, pointCount, points );

See Also

mpiSqNodeDigitalInPtr | mpiSqNodeDigitalOutPtr | mpiSqNodeAnalogOutPtr | MPIMotorLimitConfig | mpiRecorderRecordConfig