
------------------------------------------------------------------------------
1.54 Read custom macro variables (range specified). <Main,Alarm>
------------------------------------------------------------------------------
[Name]
cnc_rdmacror
[Syntax]
#include <data.h>
#include <fwindow.h>
short cnc_rdmacror( short s_number, short e_number, short length,
struct iodbmr *buf ) ;
struct iodbmr {
short datano_s ; /* Start custom macro variable number.*/
short dummy ; /* Not used. */
short datano_e ; /* End custom macro variable number.*/
struct {
long mcr_val ; /* Custom macro variable value. */
short dec_val ; /* Digit number after decimal */
/* point. */
} data[N] ; /* N is number of variables to be read. */
} ;
[Arguments]
s_number Start custom macro variable number.
e_number End custom macro variable number.
length Data block length ( =6+6*(number of variables to be
read) )
buf Buffer in which the custom macro variable data are
stored.
[Return]
EW_OK( 0) Successful.
EW_LENGTH( 2) Incorrect data block length "length".
EW_NUMBER( 3) Incorrect custom macro variable number "datano_s"
or "datano_e".
EW_DATA( 5) Value of the custom macro variable is out of the limit.
EW_NOOPT( 6) There are no required options.
The related options;
- Custom macro.
- Custom macro common variable addition (#100 to #199
and #500 to #999)
EW_BUSY(-1) It was impossible to read a custom macro variable
because a command from another application program to
write the custom macro variable was already being
executed. Alternatively, an attempt was made to execute
this command when other window processing of a low-speed
type was in progress. Execute the command after the
window processing has ended.