ioSetMode (Function) |
Top Previous Next |
This function will change how external I/O devices are updated. There are two different update modes:
Asynchronous (0, Default) The update of the external I/O devices is started in the BEGIN/END construction and is performed asynchronously with the onboard I/O. This ensures that the communication will not slow down execution of the application while the variables bound to inputs in external I/O devices are not updated until the next instance of the BEGIN/END construction (possibly longer if the BEGIN/END loop is executed faster than the update communication).
Synchronous (1) The external I/O devices are never updated in the BEGIN/END construction. The update is performed with the ioSynchronize function which does not return until after the communication has been completed. Note: the VPL variables bound to in- and outputs are not updated by the ioSynchronize function. This only happens in the BEGIN/END construction.
Note: UPDATEIO and UPDATEOUT work like the BEGIN/END construction for updating the external I/O devices.
Input: mode : INT (0/1, Default 0) The I/O Extension update mode.
Returns:
Declaration: FUNCTION ioSetMode;
Example: INCLUDE rtcu.inc |