Download PNC CPL Programming Manual

Transcript
4–46
4.14
System Functions
NCS coupling
Process and data services of the internal NCS interface can be accessed by
means of the functions for NCS coupling.
4.14.1
Possible error return values of the functions
All function calls supply a return value for verification and remedying errors.
This value can be assigned to an integer variable or to a real variable.
Example:
ERR_VAR% = MCOPS(...)
ERR_VAR% = MCODS(...)
CAUTION
Incorrect program reactions possible!
If invoked functions return an error code, actions which might be important for the continued program sequence were performed incompletely or not at all.
We therefore urgently recommend that after a function call you
check the program (e.g. using CASE) to determine whether the function was able to be executed without error.
The further program behaviour will then be based on the type and
severity of any error occurring.
The following return values are currently defined:
0:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
No error occurred.
The specified channel does not exist.
The function cannot be executed because the specified channel is
momentarily occupied (the momentary status does not permit the action).
In the specified channel an initiated control reset is not yet completed.
The specified program name is too long (currently not in use).
The function requires reference points traversed to.
The specified program does not exist or cannot be executed.
When entering buffered NC blocks, writing into the buffer was interrupted. A second authority had simultaneously attempted to write in
the buffer.
The function cannot be executed in the current operation mode.
The channel cannot be started because its status is not READY.
The function cannot be executed because no program is selected.
The specified program cannot be selected because the channel status does not permit it (e.g. status of block processing and interpolator
is RUNNING).
Currently not in use.
The operation mode cannot be changed because the channel status
does not permit this.
The destination of ”Search block” was not found.
1070 073 740-111 (02.11) GB