Fanuc C-Executer Operating Manual
B-62443EN-3/03E
- 471 -
------------------------------------------------------------------------------
1.62 Write custom macro variables (range specified). <Main,Alarm>
------------------------------------------------------------------------------
[Name]
cnc_wrmacror
[Syntax]
#include <data.h>
#include <fwindow.h>
int cnc_wrmacror( int length, struct iodbmr *buf ) ;
struct iodbmr {
int datano_s ; /* Start custom macro variable number. */
int dummy ; /* Not used. */
int datano_e ; /* End custom macro variable number. */
struct {
long mcr_val ; /* Custom macro variable value. */
int dec_val ; /* Digit number after decimal */
/* point. */
} data[N] ; /* N is number of variables to be written. */
} ;
[Arguments]
length Data block length ( =6+6*(number of variables to be
written) )
buf Buffer in which the custom macro variable data are
stored.
[Return]
0 Successful.
2 Incorrect data block length "length".
3 Incorrect custom macro variable number "buf.datano_s" or
"buf.datano_e".
5 Value of the custom macro variable is out of the limit.
6 There are no required options.
The related options;
- Custom macro.
- Custom macro common variable addition (#100,..,#199,
#500,..,#999).
-1 Attempted to execute this function while the other low-speed
window function is being executed.
Retry after completing currently executed window's process.