MISCELLANEOUS FUNCTIONS (M-FUNCTION). YASKAWA J50M
જાહેરાત
જાહેરાત
2.7.3 H- AND D-FUNCTION (H, D CODES) (Cent’d)
H o w e v e r , for programming ease, it is recommended to divide the numbers into H code part and
D code part.
H codes: HO1 to H30
D codes: D31to D99 offset method
Tool length offset
Tool position offset
Tool dia. compensation C
(Intersection com puting system)
Table 2.16 H or D Code and Offset Number
G code H or D code Offset value memory
G43
G44
G49
G45
G46
G47
G48
G40
G41
G42
I
I
I
No.
01
02
03
04
96
97
98
Offset value
2.8 MISCELLANEOUS FUNCTIONS
(M-FUNCTION)
The miscellaneous function is specified with the address M and maximum three digits. The function of each M code (MOO to M89) is determined by the machine, except for several M codes.
R e f e r to the machine tool builder’s manual for the function of M codes except for the following M codes concerned with the control.
2.8.1 M CODES FOR STOP (MOO, MO1 , M02, M30)
MOO (Program Stop)
This code, when given in automatic operation mode, stops the automatic operation after the commands in the block containing MOO have been completed and MOO R signal is fed. The program may be continued by pressing the
CYCLE START button.
MO1 (Optional Stop)
MO1 performs the same function as program stop MOO whenever the OPTIONAL STOP switch is on.
When the OPTIONAL STOP switch is off, the hlOl code is disregarded.
M02 (End-of-Program)
MOZ is used at the end of program When given in automatic operation mode , this code stops the automatic operation after the commands in the block containing M02 have been completed.
Although the control is reset in most cases, the details are determined by the machine. Refer to the machine tool builder’s manual.
M30 (End-of-Tape)
M30 is given at the end of tape. When given in automatic operation mode, this code stops the automatic operation after the commands in the block containing M30 have been completed. In addition, in most cases, the control is reset and rewinds the memory.
Since the details are determined by the machine, refer to the machine tool builder’s manual.
Notes :
. When MOO, MO1, M02 or M30 is given, it prevents the control from reading ahead the next block of information.
The single decoded signal is fed in addition to the 2-digit BCD output for
M codes.
. Whether MOO, MO1, M02 or M30 executes spindle stop , coolant off or some other executions, refer to the machine tool builder’s manual.
2.8.2 M CODES FOR INTERNAL PROCESSING
(M90 TO Ml 99)
M90 through Ml 99 are used only for internal proc e s s i n g .
Even when they are programmed , no external output signal (BIN and decoded output) is sent.
14
M90t :
M917:
M92t:
Program interrupt off
Program interrupt on
Multi-active register off
Multi-active register on M93t:
M94:
M95:
M 96+:
M97t:
Mirror image off
Mirror image on
Tool radius compensation C: circular path mode
Tool radius compensation C : intersection computing mode
M98:
M99:
Subroutine program call
Subroutine program end
M1OO to 199: Used for enhansed codes
2.8.3 PROGRAM INTERRUPTION ON/OFF
(M91 , M90) t
The following M codes are used for the program interruption function .
Program interrupt function OFF
~
N o t e : When power is applied or the control is reset, the control is in the state of M code marked with ~.
.M91 P. . . . . . ;
During the time from this command to an M90 command, whenever a program interruption signal is received, the program under execu– tion is interrupted (if the machine is in motion, it is stopped after deceleration) , and the a jump is made to the program the number of which is written after the P .
. M90;
With this command, the program interrupt function is cancelled.
2.8.4 MULTI-ACTIVE REGISTERS ON/OFF
(M93, M92) t
M code
M 92
Y
Meaning
Multi-active register OFF
M 9 3 ~ M u l t i - a c t i v e r e g i s t e r ON
I
N o t e : When power is applied or the control is reset, the control is in the state of M code marked with ~ .
M93:
During the time from this command to M92, the control assumes the 4 blocks-advance-reading mode.
Namely, up to 4 blocks of data are read in advance for the following operation.
Inter-block stoppage can be eliminated when the program is so made that the operation time of advance reading of 4 blocks is longer than processing time of advance reading of next 4 blocks of data.
M92:
This command cancels 4 blocks-advance -reading mode.
Note : In tool radius compensation C mode, the blocks without move command can be contained( up to two blocks ) .
Under this condition, 6 blocks, including the two blocks, may be read in advance.
2.8.5 MIRROR IMAGE ON/OFF (M95, M94)
M code
M94
I
I
Meaning
Mirror image OFF
M95 Mirror image ON
Note: When power is applied or the control is reset, the control is in the state of M code marked with-.
With these codes, mirror image operation can be started and stopped at any desired point in the program.
These commands must always be made on a single block,
M94 and M95 are modal.
When the power supply is turned on, M94 (OFF) is in effect.
The axis on which mirror image is to be effected is specified by setting #6000 Do to D3 (or mirror image axis designation switch). For this procedure, refer to
5.1.25, “MIRROR IMAGE AXIS SELE~OR SWITCH” on page 171.
W h e n M95 is given, the subsequent blocks will control the machine in mirror-image fashion, that is, movements in the specified coordinate direction will be reversed.
Y I
&–-
~:&OGRAD
T\
‘\
‘
//,
M95
F
X-AXIS MIRROR
IMAGE ON x
Fig. 2.8
15
16
2.8.5 MIRROR IMAGE ON/OFF (M95, M94) (Cent’d)
With both the absolute and increment move commands, the same mirror image effect will be obtained.
The block including M95 command constitutes the mirror point.
. When M94 is given , mirror image effect will be cancelled on the subsequent blocks. Mirror image operation must be started and cancelled at the same position.
Notes :
“ When G28 or G30 is used to change tools or for ending machining processes, make sure to cancel the mirror image effect by means of M94.
If mirror image effect is not cancelled when G28 or
G30 is given, an error “058” occurs.
EXAMPLE r
X AXIS MIRROR INAGE ON loo -—-—-
1
+Y
The mirror image effect is not effective on the offset movement resulting from the tool length offset function.
Do not switch the designation of mirror image axis during operations under M95 (ON) mode,
Displayed current position by POS key in mirror image fashion indicates the actual motion of tool .
Displayed data by COM key show programmed commands,
. Program must be made so that mirror image operation starts and stops at the same position.
If the start position and the stop position are not the same, movements of the machine after canceling mirror image will be shifted by the difference between both positions.
PROGRAMMED COWD
L.—___
A’
/
/
1
1A
-120
/
\
-80 \\
\ t
\
\
\.-
-40 STAR
POIN
– – – - 9 0 - 4 0 r
PATH BY
ERRONEOUS
CANCELLING
20 40 60
L t
CORiECT PATH
120
+x
NO1 G92 XO YO ;
N02 M95 :
. . . . .
Mirror image on.
N03 G90 GO1 X40.
N04 X120. ;
Ylr)o. ; N05
N06
N07
N08
N09’
X40. ;
Y40. ;
Xo Yo ;
M94 ;
N1O
Nll
Y40.
+
. . . .
X20.
x60. ;
Y-40. ;
F300 “;
If “M94 ; “ is programmed here, the tool moves on the dotted line.
Correct mirror image off.
Fig. 2.9
. Mirror image external input function
(a) Overview
In addition to the conventional mirror image function, the mirror image execution mode can also be set when power is turned on, or reset, by setting the corresponding parameter.
When the mode is the mirror image execution mode (power on or reset, ) the parameter can be set to select the command mirror image at the G28 intermediate point or not.
(b) How to use the function
(i) Upon power ON or upon reset
#6005, D2 O: M94 mode (mirror image off)
1: M95 mode (mirror image on)
(ii) Upon power ON, when it is M95 mode (#6005,
D2 i s “ l . ” )
#6005, D1 O: Commands mirror image at the G28 intermediate point
1: Does not command mirror image at the G28 intermediate point
Note : The specifications are the same as the conventional specifications, when #6005, D2 is “O. ”
Therefore, turn off mirror image by M94, when commanding G28, or G29 under this mode.
E r r o r
1!058!1 occurs if not t u r n e d off.
(c) Program example
~ Example of commanding mirror image on the G28 intermediate point
Program example (mirror image of X-axis only is on)
2.8.6 CIRCULAR PATH MODE ON/OFF ON
TOOL RADIUS COMPENSATION C (M97, M96) t
M code
M 96
7
M 97
Meaning
Tool radius compensation circular path ON.
Tool radius compensation circular path OFF.
(Execution of intersection point)
Note: When power is applied or the control is reset, the control is in the state of M code marked withy .
In the G41 or G42 tool radius compensation mode, when M96 is given, the tool moves along a circular path around a corner with an angle of 18W or larger.
In the M97 mode, the tool does not move along a circular path at the corner, but moves along two intersecting straight lines intersecting at a calculated intersecting point shifted from the programmed contour by the tool radius.
M96 MODE
CIRCULAR
‘ATHFEcTIO:F
P PROGRAMMED
CONTOUR *
N97 NODE
REFERENCE POINT Y
Fig. 2.10
X-AXIS MIRROR .~ ‘
IMAGE ON
-
100
, / ”
50
– 100
I
- \ .
I
–40 o 40
PROGRAM COMMAND
100 w x
Note : When commanding axis designation under the mirror image mode (M95) by m code, stop the lookahead by parameter (#61 16) of the set/reset M codes.
M96 and M97 are modal. When the power is turned on, M96 takes effect.
M 96 and M97 are effective on the following move command blocks.
GO1 X.. .OC; C;
(GO1) X.. . Y.. . M96 ;
)
Effective from the corner of these 2 blocks
GOIXO. .Y. .. FS. . ;
M96 (or M97) ;
(GOl)X. .. y... ; }
Effective from the corner of these 2 blocks
17
2.8.7 SUBROUTINE PROGRAM (M98, M99)
With this function , call of subroutine programs which have been numbered and stored in advance is made and executed as many times as desired.
The following M codes are used for this function.
M code I
M98
M99
Meaning
Call of subroutine program
Subroutine program end
Call of subroutine program (M98)
M98 P.. . L.. . ;
With this command, call of the subroutine program with the number specified after P is made and is executed number of times specified after
L .
When no L code is programmed, the subroutine is executed once.
Subroutine programs can be nested up to 4 times.
Format of subroutine program (M99)
Subroutine programs are written in the followin g format, and are stored in the part program memory in advance.
I o
. . .
;
. . . . . . . . . . . . . . .;
. . . . . . . . . . . . . . .;
I
— Program No.
. . . . . . . . . . . . . . .; hf99 ;
-
—
Subroutine program end.
Automatic return command from gram subroutine prm
M99 ;
At the end of subroutine programs, M99 is written in a block of its own.
When M99 is commanded in the subroutine program which has been called by M98, the execution of the main program is automatically restarted at the block immediately following the M98 block.
EXAMPLE
Call of subroutine program and execution of it are made in the seque~ce shown below.
Main program
0100 ;
NOO1 GOO . . . . ;
NO02 h198 P200 L3 ; –
NO03 ..,. ;
NO04 M98 P200 ; —
NO05 . . . . ;
Subroutine program
0200 ;
NOO1 ..., ;
NO02 o.. . ;
N050 M99 ;
. Special use of M99
M99 P.. . ;
With this command, the main program does not return to the block following the M 98 block after executing the subroutine program , but returns to the block with a sequence No. specified by the P code.
Notes :
If the program number specified by the P code is not found, this is regarded as an error “041. “
While a subroutine program is repeated L times, the number of remaining repetitions may be
18 displayed.
For details , refer to 4.3 D I S P L A Y
A N D w R I T I N G
O P E R A T I O N
.
This function is usable when subroutine programs are stored in the part program memory.
The main program can either be commanded from NC tape or the part program memory.
When the nesting of subroutine programs is attempted more than 4 times, an error state is caused.
Commanding M99; in main prOgram will ‘et~n the execution of the program to the head of the main program and control endless operation.
ડાઉનલોડ કરો
જાહેરાત