HEIDENHAIN TNC 335 Technical Manual User Manual
Page 131

4-34
TNC 360
1 Machine Axes
8/95
Example: PLC positioning of the Z axis
A PLC positioning in the Z axis is to be initiated with the M function M70. The target position is
stored in the machine parameter MP4210.2. The feed for the PLC positioning is defined in machine
parameter MP4220.2
.
.
.
67
L M0
68
ON M0
69
S M2496
;Decoded M code output (M1900 to M1999)
70
S M2719
;Word processing (incompatible with TNC 155/355)
71
L M1970
;M function M70?
72
A M2045
;Change signal M function?
73
AN M4
;Edge marker
74
CMT 110
;Load position and feed
75
S M2706
;Activate PLC positioning Z axis
76
S M4
;Edge marker
77
L M1970
;M function M70?
78
A M2045
;Change signal M function?
79
AN M2706
;PLC positioning Z axis done
80
S M2482
;Acknowledgment M function done
81
LN M2045
;No M function?
82
R M2482
;Acknowledgment reset
83
R M4
;Edge marker reset
.
.
.
1210
EM
;Main program end
1211
LBL 110
;Load Z position and feed rate
1212
L D776
;Load target position from MP4210.2
1213
= D536
;Target position PLC positioning Z axis
1214
L W964
;Load feed from MP4220.2
1215
= W564;Feed PLC positioning Z axis
1216
EM
M1970
M2045
M4
M2706
M2482