mpiSqNodeDigitalIn

Declaration

long mpiSqNodeDigitalIn(MPISqNode      node,
                        long           bitStart,
                        long          bitCount,
unsigned long *state );

Required Header: stdmpi.h
Change History: Added in the 03.02.00

Description

mpiSqNodeDigitalIn gets the current state of multiple digital inputs on the specified SynqNet node.

node a handle to a SynqNet node object.
bitStart the first bit.
bitCount the number of bits to be read.
*state a pointer to where the current state of the input bits is written to by this function.
Return Values
MPIMessageOK

Sample Code

The following MPI code will get the current state of digital inputs 3, 4, and 5 of Node 0 (in the example network these bits spread over segments 0 and 1):

long x;
mpiSqNodeDigitalIn( sqNode0, 3, 3, &x );

See Also

Accessing Digital I/O | SQIO-DIN32DOUT32: Input Pinouts