<< Click to Display Table of Contents >> Navigation: NmxDLL Reference Guide > API (programming interface) > Static Measurement (Non-Realtime) > NMX_SetOutputs_1 |
This function is used to change the state of the digital outputs.
Definition
NMX_STATUS NMX_SetOutputs_1(
NMX_PHANDLE pHandle,
unsigned char* pucDigiOut, unsigned long ulSizeofDigiOut,
unsigned char ucForceSendImmediately);
Parameter
pHandle
pucDigiOut
Pointer to the array, in which the digital output bytes are stored.
ulSizeofDigiOut
Size of the array "behind" pucDigiOut in Bytes.
ucForceSendImmediately
0 -> Default: The output data will be send with the next communication cycle. The default cycle time is approximately 30ms.
1 -> Send the output data immediately. Use this only, if an urgent update is required. Sending urgent updates repeatedly at a high frequency could slow down transfer rate for sampled data.
Typical function call (C example)
NMX_SetOutputs_1(pHandle, aucDigiOut, sizeof(aucDigiOut), 0);
.Net DLL specific implementation
NMX_MSTATUS SetOutputs_1(
System::IntPtr pHandle,
array<System::Byte>^aucDigiOut,
System::Byte ucForceSendImmediately);
No Length/Sizeof-Parameter is required for the array aucDigiOut, since this information automatically available in a .Net environment.
Comments
With ucForceSendImmediately = 0, the output data is only updated inside the NMX DLL with this function call. Each time cyclic data is exchanged between the DLL and the device, the output data is send to the device. No matter if it has been changed or not.
Never use digital in-/outputs for emergency critical applications. If required, use an external emergency circuit. See the users manual of your measurement system for more information.