Skip to main content
Submitted by Warren on Wed, 01/28/2015 - 08:18

It would be helpful while doing debugging if the state of the trace command could be interrogated ( as in XXX = _TR ) so that if there is a section of code where a trace is not desired, a check could be made at entry to the section to determine the trace state then trace could be disabled and upon exiting the section of code trace could be restored to whatever state existed on entry.

Comments 1

Galil_RobinR on 08/22/2016 - 15:08

One option would be to control the Trace/No Trace via a user variable, for example a variable "tr" If you as the user set tr=0 vs tr=1, then in a thread on the controller, the controller can trace/no trace:
#TRACE
IF (tr=0)
TR0
ELSE
TR1
ENDIF
JP#TRACE