Appendix A:Variable Context Appendix A: Variable Context The following eV+ monitor commands can be used to access automatic and local variables, as well as global variables: BPT HERE POINT DELETEL LISTL TEACH DELETER LISTR TOOL DELETES LISTS WATCH DO When these commands access local or automatic variables, you must specify the program context to be used. That is, the system must know which program's variables are to be accessed.
The general syntax for a command that can access local and automatic variables is command @task:program parameters Where "command" represents the command name (for example, HERE), and "parameters" represents the normal command parameters (for example, a location variable name for the HERE command). The optional element "@task:program" specifies the program context for any variables referenced in the command parameters. The "task" portion is an integer that specifies one of the system program tasks. The "program" portion of the context is the name of a program in the system memory. The context can be specified in any of the formats described below.
Interpretation of Context Specification for Variables summarizes the various context specifications that can be used. 1. "task:program" is blank (that is, "@ " is input). Then the context for referenced variables will be one of the following: l A blank context specification in an MCS instruction, for example: MCS "DELETEL @ parts[]" indicates that the variables are treated as though they are referenced within the program containing the MCS instruction. Thus, an instruction like the example above can be used to delete local variables after they are used by a routine (regardless of which task is assigned to the executing program).
l Variables will be treated as though they are referenced within the program on the top of the stack for the robot control task. (That is, the last program listed by the STATUS command-for example, "STATUS 0".) eV+Operating System Reference Guide, 2.x,18321-000 Rev A Page 197