338
6 BASIC INSTRUCTIONS
6.8 Other Convenient Instructions
Teaching timer
TTMR
• Measures the time while the execution command is ON in units of seconds, and stores the multiplied value of the measured
time by the multiplier specified by n at the device designated by (D).
• Clears the device designated by (D)+0 or (D)+1 when the execution command is turned OFFON.
• The multipliers that can be designated by n are as shown below:
• Time measurements are conducted when the TTMR instruction is executed. Using the JMP or similar
instruction to jump the TTMR instruction will make it impossible to get an accurate measurement.
• Do not change the multiplier designated by n while the TTMR instruction is being executed. Changing this
multiplier will result in an inaccurate value being returned.
• The TTMR instruction can also be used in low speed execution type programs.
• The device designated by (D)+1 is used by the system of the CPU module, so users should not change its
value. If users do change this value, the value stored in the device designated by (D) will no longer be
accurate.
• No processing is performed when the value specified by "n" is other than 0 to 2.
• In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and an error code is stored into SD0.
(D): (D)+0: The device where measurement value is stored (BIN 16 bit)
(D)+1: For CPU module system use (BIN 16 bit)
n: Measurement value multiplier (BIN 16 bits)
Setting
data
Internal device R, ZR J\ U\G Zn Constant
K, H
Others
Bit Word Bit Word
(D)
n
n Multiplier
0 1
1 10
2 100
Error
code
Error details Q00J/
Q00/
Q01
QnH QnPH QnPRH QnU LCPU
4101 The device specified by (D) exceeds the range of the corresponding device.
Basic
Redundant
Process
High
performance
Universal
LCPU