Fanuc C-Executer Operating Manual
B-62443EN-3/03E
- 592 -
------------------------------------------------------------------------------
2.2 Write arbitrary PMC data (range specified). <Main,Alarm>
------------------------------------------------------------------------------
[Name]
pmc_wrpmcrng
[Syntax]
#include <data.h>
#include <fwindow.h>
int pmc_wrpmcrng( int length, struct iodbpmc *buf ) ;
struct iodbpmc {
int type_a ; /* Kind of PMC address. */
int type_d ; /* Type of PMC data. */
int datano_s ; /* Start PMC address. */
int datano_e ; /* End PMC address. */
union {
char cdata[N] ; /* PMC data (Byte) */
int idata[N] ; /* (Word) */
long ldata[N] ; /* (2-Word) */
} u ; /* N is number of data to be written. */
} ;
[Arguments]
length Data block length
( =8+(byte size of data)*(number of data to be
written) ).
buf Buffer in which the PMC data are stored.
[Return]
0 Successful.
2 Incorrect data block length "length".
3 Incorrect PMC address "buf.datano_s" or "buf.datano_e".
4 Incorrect kind of PMC address "buf.type_a" or type of PMC data
"buf.type_d".