Dear all,
Is there a way to record how long it takes to execute a set of commands in KRL?
Dear all,
Is there a way to record how long it takes to execute a set of commands in KRL?
Maybe you can user $timer ,start a $timer and stop a $timer between the KRLs
I am trying to use the following code to time the commands, but I do not see the timer changing in the display.
&ACCESS RVP
&REL 57
&PARAM TEMPLATE = C:\KRC\Roboter\Template\vorgabe
&PARAM EDITMASK = *
DEF only_one( )
;FOLD INI;%{PE}
;FOLD BASISTECH INI
GLOBAL INTERRUPT DECL 3 WHEN $STOPMESS==TRUE DO IR_STOPM ( )
INTERRUPT ON 3
BAS (#INITMOV,0 )
;ENDFOLD (BASISTECH INI)
;FOLD USER INI
;Make your modifications here
;ENDFOLD (USER INI)
;ENDFOLD (INI)
PTP $POS_ACT
PTP {X 1350, Y 0, Z 1540, A 180, B 0, C 180}
;Start Timer
WAIT SEC 0
$TIMER_STOP[ 7 ] = TRUE
$TIMER[ 7 ] = 0
$TIMER_STOP[ 7 ] = FALSE
PTP {X 1350, Y 100, Z 1440, A 180, B 0, C 180}
PTP {X 1450, Y 0, Z 1540, A 180, B 0, C 180}
;Stop Timer
$TIMER_STOP[ 7 ] = TRUE
END
Display More
Yes, if you're trying to record the time of motion commands, the Advance pointer can trip you up. Using WAIT SEC 0 can help. Or, in situations where you don't want the robot to stop (even momentarily), you can use TRIGGER commands to control the relationship of the Timer start/stop precisely relative to particular motions.