3-643.8Test Operations
D. SETTING TIME
3.9.11 Editing Local Variables
As well as user variables, local variables can be used for the storage of counters, calculations, and input signals. The data format is the same as that of user variables. As shown in the following table, the letter L is affixed to the variable number to indicate a local variable.
Local variables differ from user variables in the following four ways:
• Used in One Job Only
With user variables it is possible to define and use one variable in multiple jobs, but local variables are used only in the job in which they are defined, and cannot be read from other jobs.
Accordingly, local variables do not affect other jobs, so it is possible to define a variable number (such as LB001) separately in different jobs, and use it in different ways in each of these jobs.
• Able to Use Any Number of Variables
The number is set in the JOB HEADER window. When the number is set, the area for the value is saved in memory.
Table 3-7: Local Variables
Data Format Variable No. Functions
Byte Type
LB000 to LB
Range of storable values is from 0 to 255.
Can store I/O status.
Can perform logical opera-tions (AND, OR, etc.)
Integer Type Ll000 to
LI
Range of storable values is from -32768 to 32767.
Double Precision
Integer Type LD000 to
LD
Range of storable values is from -2147483648 to 2147483647.
Real Type
LR000 to LR
Range of storable values is from -3.4E+38 to 3.4E+38 Accuracy: 1.18E-38 < x ≤ 3.4E+38
Character Type LS000 to
LS
Maximum storable number of characters is 16.
Position
Type Robot Axes LP000 to LP
Can store position data in pulse form or in XYZ form.
XYZ type variables can be used as target position data for move instructions, and as incremental values for parallel shift instructions.
Base Axes LBP000 to LBP Station Axes LEX000 to
LEX
3 Teaching
DX100 3.9 Other Job-editing Functions
3-88
• Not Able to Display the Variable Contents
To display the local variable contents, user variables are needed.
For example, to view the contents of local variable LP000, save it temporarily as user variable P001. Then execute the instruction SET P001 LP000, and view the POSITION VARIABLE window for P001.
• Enabled Only During the Execution of the Defined Job The contents of the local variables are enabled only during the exe-cution of the defined job.
The local variable field is assured when the defined job is called (when the job is executed by a CALL or JUMP instruction, or the job is selected by the menu). Once the job is completed by the execu-tion of a RET, END, or JUMP instrucexecu-tion, the local variable data that was set is disabled. However, if a job which uses local variables itself calls a separate job, then is returned by use of a RET instruc-tion, the data that was present prior to the CALL instruction remains in effect and can be used.
NOTE
Precautions for Variables and Units
As was the case with user variables, note that, depending on the value of the unit being used, the value of the variable and the value of the actual speed or time an occasion might not match. Refer to chapter 3.9.4 "User Variables" at page 3-71.
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-89
3.9.11.1 Setting the Number of Local Variables
The number of local variables used in a job is set in the JOB HEADER window. When the number of local variables is set, memory is allocated for those variables.
1. Select {JOB} under the main menu.
2. Select {JOB}.
3. Select {DISPLAY} under the menu.
4. Select {JOB HEADER}.
– The JOB HEADER window appears. Scroll the window using the cursor.
5. Select the number of local variables to be set.
– The input buffer line appears.
6. Input the number of variables.
7. Press [ENTER].
– The number of local variables are set.
NOTE
Only when expanding the “INSTRUCTION LEVEL,” it is possible to use local variables. Refer to “8.12 Instruction Level Setting” of “DX100 INSTRUCTIONS” (RE-CTO-A215) for details on setting the language level.
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-90
3.9.12 Search
When editing or checking, jobs and steps can be searched for. Search can be done when the cursor is in either the address or instruction area on the JOB CONTENT window.
1. Select {JOB} under the main menu.
2. Select {JOB}.
– The JOB CONTENT window appears.
3. Select {EDIT} under the menu.
– The pull-down menu appears.
4. Select {SEARCH}.
– The selection dialog box appears.
5. Select the search type.
Search is an operation by which the cursor is moved to a specific step or instruction in the edit job. The desired item can be instantly searched for without using the cursor.
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-91
3.9.12.1 Line Search
This function moves the cursor to the desired line number.
1. Select {EDIT], {SEARCH} and “LINE SEARCH.”
– The number can be entered.
2. Input desired line number.
3. Press [ENTER].
– The cursor is moved to the line number and the window appears.
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-92
3.9.12.2 Step Search
This function moves the cursor to the desired step number (move instruction).
1. Select {EDIT], {SEARCH} and “STEP SEARCH.”
– The number can be entered.
2. Input desired step number.
3. Press [ENTER].
– The cursor is moved to the input step and the window appears.
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-93
3.9.12.3 Label Search
This function searches for the desired label and the instruction using that label.
1. Select {EDIT}, {SEARCH} and “LABEL SEARCH.”
– The characters can be entered.
2. Input desired label name.
– For information on character input operation, refer to chapter 1.2.6 "Character Input Operation" at page 1-18.
– At this time, search can be conducted by entering any one character of the label. For example, to search for the “START” label, enter only “S,” and the search can be done.
3. Press [ENTER].
– The cursor is moved to the desired label and the window appears.
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-94
4. Use the cursor to continue search.
– While searching, forward search and backward search are possible by pressing the cursor key.
– To end search, select {EDIT} {END SEARCH} on the menu and press [SELECT].
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-95
3.9.12.4 Instruction Search
This function moves the cursor to a desired instruction.
1. Select {EDIT}, {SEARCH} and “INSTRUCTION SEARCH.”
– The INFORM command list appears.
2. Select desired instruction group.
3. Select desired instruction.
– The cursor is moved to the selected instruction and the window appears.
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-96
4. Use the cursor to continue search.
– While searching, forward search and backward search are possible by pressing the cursor key.
– To end search, select {EDIT} {END SEARCH} on the menu and press [SELECT], or press [CANCEL].
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-97
3.9.12.5 Tag Search
This function moves the cursor to the desired tag.
1. Select {EDIT}, {SEARCH} and “TAG SEARCH.”
– The instruction list dialog box appears.
2. Select desired instruction group.
3. Select desired instruction for which the tag is to be searched.
– The tag list dialog box for selected instruction appears.
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
3 Teaching
DX100 3.9 Other Job-editing Functions
3-98
4. Select the desired tag.
– The cursor is moved to the selected tag and the window appears.
5. Use the cursor to continue search.
– While searching, forward search and backward search are possible by pressing the cursor key.
– To end search, select {EDIT} {END SEARCH} on the menu and press [SELECT], or press [CANCEL].
工控帮助教小舒QQ:2823408167
长沙工控帮教育科技有限公司
工控帮助教小舒QQ:2823408167
4 Playback
DX100 4.1 Preparation for Playback