EasyManua.ls Logo

Omron NJ501-1500

Omron NJ501-1500
990 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
2 Instruction Descriptions
2-124
NJ-series Instructions Reference Manual (W502)
The following figure shows a programming example and timing chart for a PT of T#10ms. Variable abc
changes to TRUE as soon as variable A changes to TRUE. Variable abc changes to FALSE 10 ms later.
Use the TON instruction (page 2-116) for a timer that starts when In changes to TRUE and then
changes the timer output to TRUE when the elapsed time reaches the set time.
Use the TOF instruction (page 2-120) for a timer that starts when In changes to FALSE and then
changes the timer output to FALSE when the elapsed time reaches the set time.
ET and Q are updated only when the instruction is executed. Therefore, Q does not change to FALSE
precisely when the elapsed time from when the timer starts reaches PT. Q changes the next time the
instruction is executed after the elapsed time from when the timer starts reaches PT. The change in Q
can therefore occur with a delay of up to one task period.
Set PT and ET in nanoseconds (ns), but remember the timing accuracy is 100 ns.
The timer starts as soon as operation starts if In is already TRUE.
If T#0ms or a negative number is set for PT, Q will not change to TRUE even if the value of In
changes to TRUE.
You can change the value of PT while the value of In is TRUE. Operation is as follows:
If this instruction is in a master control region and the master control region is reset, timing is contin-
ued to the end if the timer is operating. Then, the value of ET changes to 0 and the value of Q
changes to FALSE. However, if an Out instruction is connected to Q, the execution condition to the
Out instruction is FALSE even if the value of Q is TRUE.
Additional Information
Precautions for Correct Use
Timer status Value of Q
Value of PT after it is
changed
Operation
After comple-
tion of timing
FALSE --- The value of Q remains FALSE.
The value of ET also does not change. (It remains at
the value of PT before it was changed.)
Timing in
progress
TRUE
PT ET Timing is continued. When the value of ET reaches
the value of PT, the value of Q changes to FALSE
and ET is no longer incremented.
PT < ET The value of Q changes to FALSE immediately.
Incrementing ET stops immediately.
TP_instance(A, T#10ms, abc, def);
LD ST
abc
A
def
T#10ms
TP
In Q
PT ET
TP_instance
In=A
Q=abc
TRUE
FALSE
TRUE
FALSE
ET=def
PT=T#10ms

Table of Contents

Related product manuals