Description
Writes the custom macro variables specified by the starting number, "s_no", and number of variables, "*num". The data is stored in "data" with double format. It is not influenced by setting of cnc_setmactype function.
The kind of custom macro variable is as follows. The local variable(#1,..,#33) cannot be written.
(1) | Common variable (#100,..,#999) See the description of cnc_rdmacroinfo function about the available range of common variables. |
(2) | Common variable (#98000~#98499) See the description of cnc_rdmacroinfo function about the available range of common variables. |
The value of an undefined variable is called "vacant", and it is expressed as follows.
0xFFFFFFFFFFFFFFFF
See "OPERATOR'S MANUAL" of CNC for details of the custom macro variable.
Universal Fanuc Driver
Fanuc Focas Library CD
Declaration
Arguments
Specify the library handle. See "Library handle" for details.
Specify the start custom macro variable number.
Specify pointer to the number of custom macro variable.
The number which was written actually is returned.
Pointer to the data of custom macro variable.
Return
EW_OK is returned on successful completion, otherwise any value except EW_OK is returned.
The major error codes are as follows.
Return code | Meaning/Error handling |
---|---|
(2) |
The number of custom macro variables(*num) is 0 or less. |
(3) |
Custom macro variable number(s_no) is wrong. |
(6) |
This function needs the custom macro option. |
(7) |
The variable is read-only. |
As for the other return codes or the details, see "Return status of Data window function"
CNC option
This function need the following CNC option.
And this function is related to the following CNC option.
Embedded macro
Addition of custom macro common variables 1000
For HSSB connection,
For Ethernet connection,
The Ethernet function and the extended driver/library function are necessary. However, in case of Series 0i-D/F, Series 30i and PMi-A, the required CNC option is as follows. When Embedded Ethernet is used,above two optional functions are not required.
When Ethernet board is used,
- only Ethernet function is required.
CNC parameter
This function is related to the following CNC parameter.
See the manual of CNC parameter for details.
6031, 6032 (influenced by setting)
CNC mode
This function can be used in any CNC mode.
Available CNC
0i-A | 0i-B/C(Note) | 0i-D | 0i-F | 15 | 15i | 16 | 18 | 21 | 16i-A | 18i-A | 21i-A | 16i-B | 18i-B | 21i-B | 30i-A | 30i-B | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
M (Machining) | |||||||||||||||||
T (Turning) | - | ||||||||||||||||
LC (Loader) | - | - | - | - | - | - | - | - |
0i-D | 0i-F | 16i | 18i | 30i-A | 30i-B | |
---|---|---|---|---|---|---|
P (Punch press) | - | |||||
L (Laser) | - | - | - | - | ||
W (Wire) | - | - |
Power Mate i-D | |
Power Mate i-H | |
Power Motion i-A | O |
"O" | : | Both Ethernet and HSSB | |
"E" | : | Ethernet | |
"H" | : | HSSB | |
"X" | : | Cannot be used | |
"-" | : | None |
Note) 0i-C does not support the HSSB function.
See Also
cnc_rdmacro cnc_wrmacro cnc_rdmacror cnc_wrmacror cnc_rdmacror2 cnc_rdmacroinfo cnc_getmactype cnc_setmactype