Omron CP1H PLC Programming Timers

The Omron CP1H series of programmable logic controllers are capable of having 4096 timers. There are twelve different timing instructions in the PLC. Six binary and six BCD instructions for the set values of the timers separate the six basic instructions. The memory area for timers has separate areas for the Timer PVs (Present values) and the Timer Completion Flags. We will be looking at the timer instructions in the CP1H along with some programming examples.

Previously in this CP1H series, we have discussed:
System Hardware – Video
CX-Programmer – Video
Establish Communication – Video
Setting, Forcing and Online Editing – Video
Numbering System and Addressing – Video
CP1H Timers – Video
Counters – Video
Data Movement – Video
Compare Instructions – Video
Data Shift Instructions
Video Part 1
Video Part 2
Math Instructions – Video
Data Conversion – Video
Program Control Instructions – Video
Table Data Instructions – Video
Data Control Instructions – Video
AdvancedHMI Communication – Video

The secret to using timers is a post that will go over timing charts. It is a good place to understand how timing charts can assist you in programming timers. The Secret of Using Timers

Omron CP1H PLC Timer Instructions

We will be covering the following instructions:
TIM – Timer – This is a decrementing timer (0.1-sec base)
TIMH – High-Speed Timer – This is a decrementing timer (0.01-sec base)
TMHH – ONE-MS Timer – This is a decrementing timer (0.001-sec base)
TTIM – Accumulative Timer – This is an incrementing timer (0.1-sec base)
TIML – Long Timer – This is a decrementing timer (0.01-sec base)
MTIM – Multi-Output Timer – This is an incrementing timer (0.1-sec base)
All of the instructions above have a set value in BCD (Binary Coded Decimal). If you put an ‘X’ behind each of the above instructions you will indicate the same operation with a set value in binary.
The following table shows the specifications of the timers:
Omron CP1H PLC Programming Timers

The Timer operation is specified in the following chart:
Omron CP1H PLC Programming Timers
Note: CNR/CNRX is the instruction to reset the timer. Further information can be obtained from the programming manual at the end of this post.

Let’s take a look at a sample of an on-delay timer. We can use any of the following timer instructions. TIM / TIMH / TMHH will all work the same way except for the timing base rate.
Our sample will use TIM. The SV (set value) will be in BCD as the instruction specifies.

On-Delay Timer – Omron CP1H Timers

Omron CP1H PLC Programming Timers
When bit 21.00 is turned on, Timer 0000 will start to decrement from the set value of #100.
100 X 0.1 seconds = 10.0 seconds
After the timer expires the bit T000 will turn on. This will then turn on the output 100.00
The timer will reset to the set value of #100 once bit 21.00 turns off. This timer is not memory retentive.

Off-Delay Timer – Omron CP1H Timers

Omron CP1H PLC Programming Timers
When bit 21.01 is turned on, output 100.01 will be turned on. This output is sealed on by itself and will only turn off when Timer T0001 turns on.
When bit 21.01 is turned off, the output remains on and the timer T0001 will start to decrement from the set value of #100. After the timer expires the bit T0001 will turn on. This will then reset the output 100.01.

Flicker Timer – Omron CP1H Timers

CP1 Ladder Logic Programming Sample Code
When bit 21.02 turns on, it will go through the normally closed timer T0003 bit and start timer T0002. Timer T0002 will decrement until it expires. When T0002 turns on it will start T0003.
Output 100.02 will turn on when T0002 is on and T0003 is not on. When T0003 expires it will reset T0002 and the output 100.02 will turn off. The cycle will not repeat itself.
Output 100.02 will be off for as long as T0002 and on for T0003. When Bit 21.02 turns off the circuit will stop flickering the output and the timers reset.

TTIM – Accumulative Timer – Omron CP1H Timers

CP1 Ladder Logic Programming Sample Code
As the name implies, the accumulative timer will count up to the set value. In our case, the SV value is #200. (20 seconds) When bit 21.03 turns on the timer start to time. Timing stops when bit 21.03 turns off but the present value (PV) remains the same until a reset is done. The reset is a separate input to the timer with bit 21.04. The reset bit will override the enable bit.
When the PV is greater than or equal to the SV, output 100.03 will turn on.

TIML – Long Timer – Omron CP1H Timers

CP1 Ladder Logic Programming Sample Code
The long timer can be used to set a maximum time value of #99999999. This would translate to 9 999 999.9 seconds, which is just over 115 days long. When bit 21.05 turns on, the timer will decrement from the SV down to 0 and the first bit of the completion word specified will turn on. In our case, this will be H0.00.

MTIM – Multi Output Timer – Omron CP1H Timers

CP1 Ladder Logic Programming Sample Code
The multi output timer will allow you to set up to eight outputs off of a single timer. We specify the completion flags (Channel 300 – 300.00 to 300.07) to trigger when the corresponding SP value is reached for each of the outputs. (D210 – D217). The reset bit for the timer is bit 8 of the completion flag word. (300.08)
This timer may be memory retentive if the PV value is stored in a memory retentive area. See the operation of this timer in the YouTube video below.


The CP1H PLC comes with a series of internal clock bits. 0.02s, 0.1s, 0.2s, 1s, and 1 min clock bits are included. These will turn on and off at a 50% duty cycle.
Omron CP1H PLC Programming Timers
Call these bits up by their respective names in CX programmer.

All CP1H controllers also have a real-time clock. (Calendar / Clock)
The address to access values are in the following table:
Omron CP1H PLC Programming Timers
Setting the real-time clock can be done with a CX programmer. You can also set this area with instructions in the PLC.

See the YouTube video below on timers in the Omron CP1H PLC.

The following is a list of manuals associated with the CP1H programmable logic controller. See the descriptions for each of these manuals in the first post: Omron CP1H System Hardware
W450 – SYSMAC CP Series CP1H CPU Unit Operation Manual
W451 – SYSMAC CP Series CP1H CPU Unit Programming Manual
W342 – SYSMAC CS/CJ series Communications Commands Reference Manual
W446 – SYSMAC CX-Programmer Ver. 6.1 Operation Manual
W447 – SYSMAC CX-Programmer Ver. 6.1 Operation Manual Function Blocks
W444 – CX-One FA Integrated Tool Package Setup Manual
W445 – CX-Integrator Operation Manual
W344 – CX-Protocol Operation Manual

You can download the PLC program as discussed above here.

Next time we will look at counters in the Omron CP1H PLC.

Watch on YouTube : Omron CP1H Timers

Omron CP1H PLC Programming Timers
Omron CP1H PLC Programming Timers

If you have any questions or need further information please contact me.
Thank you,
Garry



If you’re like most of my readers, you’re committed to learning about technology. Numbering systems used in PLC’s are not difficult to learn and understand. We will walk through the numbering systems used in PLCs. This includes Bits, Decimal, Hexadecimal, ASCII and Floating Point.

To get this free article, subscribe to my free email newsletter.


Use the information to inform other people how numbering systems work. Sign up now.

The ‘Robust Data Logging for Free’ eBook is also available as a free download. The link is included when you subscribe to ACC Automation.


4 thoughts on “Omron CP1H PLC Programming Timers”

  1. Hi,thanks for the good work.I don’t understand how MTIM pv value is showing in Bcd (this is in the screen shots) but in your video the same pv and sv memory areas are in hexa.
    please elaborate further

    Regards.

    Reply
    • Hi Martin,
      Thank you for the comment. You are correct. The areas are in hexadecimal, however the instruction used will dictate how the area is to be used. In this case the BCD (Binary Coded Decimal) will be used for the MTIM multi timer instruction. Remember that hexadecimal is just used to display the binary value of a register.
      Hope this helps you out.
      Regards,
      Garry

      Reply

Leave a Reply to garrys Cancel reply