Side-connect api synchronization functions – ProSoft Technology MVI69-ADM User Manual
Page 314

Side-Connect API Library Functions
MVI-ADM ♦ 'C' Programmable
Developer's Guide
'C' Programmable Application Development Module
Page 314 of 342
ProSoft Technology, Inc.
February 20, 2013
11.5 Side-connect API Synchronization Functions
MVIsc_WaitForEos
Syntax
int MVIsc_WaitForEos(HANDLE handle, WORD timeout);
Parameters
handle Handle
returned by previous call to MVIsc_Open
timeout
Maximum number of milliseconds to wait
Description
MVIsc_WaitForEos allows an application to synchronize with the PLC-
5’s ladder
scan.
This function will return when the PLC-5 reaches the end of the ladder scan.
handle must be a valid handle returned from MVIsc_Open.
Return Value
MVISC_SUCCESS
The PLC-5 has reached the end of the ladder scan.
MVISC_ERR_NOACCESS
handle does not have access
MVISC_ERR_PLCTIMEOUT
The timeout expired before an end of scan occurred.
Example
HANDLE Handle;
/* Wait here until EOS, 5 second timeout */
rc = MVIsc_WaitForEos(Handle, 5000);