int32 DAQmxSwitchGetMultiRelayCount (const char relayList[], uInt32 count[], uInt32 countArraySize, uInt32 *numRelayCountsRead);
Returns the number of times a set of relays have been actuated. Use this function to track relay lifetime and usage. You must set the waitForSettling parameter of Switch functions to TRUE to obtain an accurate relay count.
Input | ||
Name | Type | Description |
---|---|---|
relayList |
|
The set of relays you want to query. |
countArraySize | uInt32 | The size of count. If you pass 0, this function returns the number of samples needed to allocate. |
Output | ||
Name | Type | Description |
count |
|
Number of times each specified relay has been actuated. The order of this array depends on the order of relayList. If you pass NULL, this function returns the number of samples needed to allocate. |
numRelayCountsRead |
|
The number of relay counts read by the function. |
Name | Type | Description |
---|---|---|
status | int32 | The error code returned by the function in the event of an error or warning. A value of 0 indicates success. A negative value indicates an error. For this function, if you pass NULL for the buffer or 0 for the buffer size, this function returns the number of samples needed to allocate. For example, malloc (n*sizeof(uInt32)); |