EasyManuals Logo

Allen-Bradley Logix5000 Reference Manual

Allen-Bradley Logix5000
708 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
Page #138 background imageLoading...
Page #138 background image
138 Rockwell Automation Publication 1756-RM003N-EN-P - October 2011
Chapter 3 Timer and Counter Instructions (TON, TOF, RTO, TONR, TOFR, RTOR, CTU, CTD, CTUD, RES)
Description: The RTOR instruction accumulates time until it is disabled. When the RTOR
instruction is disabled, it retains its ACC value. You must clear the .ACC value by
using the Reset input.
The time base is always 1 ms. For example, for a two-second timer, enter 2000 for
the PRE value.
Set the Reset input parameter to reset the instruction. If TimerEnable is set when
Reset is set, the RTOR instruction begins timing again when Reset is cleared.
A timer runs by subtracting the time of its last scan from the time now:
ACC = ACC + (current_time - last_time_scanned)
After it updates the ACC, the timer sets last_time_scanned = current_time. This
gets the timer ready for the next scan.
TimerEnable
Enable Bit (EN)
Timer Done Bit ( DN)
Timer Accumulated Value (ACC)
Timer Timing Bit (TT)
Preset
0
16651
Reset
Timer did not reach PRE value
IMPORTANT
Make sure to scan the timer at least every 69 minutes while it runs. Otherwise, the ACC
value won’t be correct.
The last_time_scanned value has a range of up to 69 minutes. The timer’s calculation rolls
over if you don’t scan the timer within 69 minutes. The ACC value won’t be correct if this
happens.
While a timer runs, scan it within 69 minutes if you put it in a:
• Subroutine
• Section of code that is between JMP and LBL instructions
• Sequential function chart (SFC)
• Event or periodic task
• State routine of a phase

Table of Contents

Other manuals for Allen-Bradley Logix5000

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Allen-Bradley Logix5000 and is the answer not in the manual?

Allen-Bradley Logix5000 Specifications

General IconGeneral
BrandAllen-Bradley
ModelLogix5000
CategoryController
LanguageEnglish

Related product manuals