
B–61863E–1/06
13. NC COMMAND PROGRAM
(PMC-NB/NB2/15i–A)
PMC LIBRARY
331
SC/SC3/SC4 NB/NB2 16i/18i/21i 15i–A
f f
[Name]
pl_nc_download
[Description]
Registers (downloads) the data of the NC program. Character strings
represented in ASCII code are used as the NC program data.
[Format]
ret = pl_nc_download(P1, P2) ;
short ret ;
char *P1 ;
unsigned short P2 ;
[Input]
*P1 Data of NC command (string of 256 or less characters
represented in ASCII code)
P2 Number of characters contained in the NC command data
[Output]
______
[Returns]
ret Complete code : –11, –10, –4 or 0
–11: The NC has not yet terminated or executed the processing to
start outputting the data of the NC command to be registered.
–10: A function is being processed. Call the function repeatedly
until a value other than –10 is returned.
–4: The program registration terminated normally or abnormally.
Call the pl_nc_dwnend function described below.
0: The NC has normally terminated registering the data of the NC
command.
[Remarks]
Enter a program number beginning with address ¡ÇO¡Ç at the
beginning of each program to be registered. If an attempt is made to
register a program whose number is identical to that of a program
already registered in the NC, the system issues an alarm or replaces
the registered program, depending on the setting of bit 2 (REP) of NC
parameter 2200. The NC program is represented in ASCII code and
stored in bytes. Mark EOB of the NC command with LF (0AH). The
data of the program is registered in the NC tape format.
13.2
OUTPUTTING
(DOWNLOADING)
THE DATA OF THE
NC COMMAND TO BE
REGISTERED