ETEL Doc. - Operation & Software Manual # DSC2P 903 / Ver. F / 3/6/05 Chapter E: Appendixes
Operation & Software Manual
Direct Drives & Systems 255
15.24 TCL, TMK, TNB, TRS triggers example
:10.2 ;Label 10
MMD.2=17 ;Sets the rotary S-curve movement
PWR.2=1 ;Power on
WTM.2 ;Waits until the movement is finished
IND.2 ;Starts the homing
WTM.2 ;Waits until the movement is finished
POS.2=0.00000 ;Goes to the position 0 (ISO unit)
WTM.2 ;Waits until the movement is finished
DOUT.2=0 ;All digital outputs of the controller are set to 0
TCL.2 ;All triggers tables are cleared
TNB.2=2 ;The table is defined with 2 triggers per mapping (alias of parameter K187)
TMK.2=3 ;Selects the DOUT1 and 2 to be modified by the trigger
:20.2 ;Label 20
Mapping #0 (triggers E
0
and E
1
)
E0:0.2=0x00010081 ;Positive trigger (0x81) and action 1 (0x01), controller's DOUTs & SD2
E0:1.2=1 ;Controller outputs =0001 bin. DOUT1=1 (masked by TMK), other DOUTs = 0
E0:2.2=1 ;’Status Drive’ SD2 bits = 01 bin. Bit# 9=0, Bit# 8=1 (masked by parameter K184)
E0:3.2=1137778 ;Trigger position = 1137778 [upi]
E1:0.2=0x00010082 ;Negative trigger (0x82) and action 1 (0x01), controller's DOUTs & SD2
E1:1.2=2 ;Controller's outputs = 0010 bin. DOUT2=1 (masked by TMK), other DOUTs = 0
E1:2.2=1 ;’Status Drive’ SD2 bits = 01 bin. Bit# 9=0, Bit# 8=1 (masked by parameter K184)
E1:3.2=568889 ;Trigger position = 568889 [upi]
TRS.2=0 ;Mapping # 0 is activated (alias of parameter K186)
:30.2 ;Label 30
POS.2=20.0 ;Goes to the position 20 (ISO unit)
WTM.2 ;Waits until the movement is finished
WTT.2=1.00000 ;Waits for 1 (ISO unit)
POS.2=0.0 ;Goes to the position 0 (ISO unit)
WTM.2 ;Waits until the movement is finished
WTT.2=1.00000 ;Waits for 1 (ISO unit)
JMP.2=30 ;Jumps to label 30