Click Plc Software

Continuing our series, we will now look at timers and counters and how they are used in the Click PLC. Previously we have discussed:
System Hardware – Video
Installing the Software – Video
Establish Communication – Video
Numbering System and Addressing – Video
The programming software and manuals can be downloaded from the Automation Direct website free of charge.

  1. Click Koyo Plc Software
  2. Click Plc Software Update
  3. Click Plc Software Free
  4. Click Plc Software Manual
  5. Click Plc Software Update
  • The CLICK PLC family of components is designed to offer practical PLC features in a compact and expandable design, and at the same time offer the best ease-of-use. The CLICK PLC programming software can be downloaded for free from our Web site and provides an intuitive programming tool that will get you up and running quickly.
  • Previously we discussed the Click PLC System Hardware - Video. Today we will be installing the free software required to program the PLC. This includes the actual program and communication drivers.
Click PLC TIMERS
Click Plc Software

Click PLC Series Certificate Course Now available three convenient ways, all featuring our signature hands-on learning approach: Scheduled in-person courses around the U.S.

The Click PLC can have 500 unique timers in the program. (T1 to T500) There is only one timer (TMR) instruction in the PLC, but you can adapt it to handle any timing application that you may need.


Timer Number – This is a number from T1 to T500 to specify the timer.
Set Point – This is an integer (16 Bit) that represents the set point of the timer. The values are from 1 to 9999. This can also be a memory location so that the timer set value can change during program execution.
Unit – This can be set for milliseconds (ms), seconds (sec), minutes (min), hours (hour) or days (day).
Current Value – This is the location in which you can see use the current value. It is automatically assigned by the timer number. Example: T1 = TD1, T2 = TD2, etc.
Delay Setting – The delay setting is used to determine if you would like an ON Delay timer or an OFF Delay timer. You will see in the diagram above the timing chart is displayed to show you the difference.
Current Value Option – This is used to determine if the timer will be reset with the enabling rung or it will require a separate reset rung.
Applications that use timers always start with a timing chart. This is the secret to using timers in your programs. Additional information on timers can be found at the following post. The Secret Of Using Timers

Timers in the Click PLC by default are not memory retentive. However, this can be changed. See Memory Retentive heading below.

The Click PLC can come with a real time clock. To set the clock in the PLC to match the PC (computer), call up the following Calendar/Clock Setup window. When online select the following from the top menu. PLC | Calendar/Clock Setup
You will notice that it will display both the date and time in the PLC as well as the computer. Under setting, you can manually enter a date and time or select adjust to PC Clock. Then hit the Write to PLC button at the bottom of the window. Your date and time will now be synced with the PLC.
The real-time clock is located in the SD area of memory in the PLC. Use the Address Picker to display the real-time clock from SD19 to SD26.
Additional Information on the real-time clock of the Click PLC can be found here:
Real-Time Clock (RTC) – Video

Watch on YouTube: Click PLC Timers

Click PLC COUNTERS

The Click PLC can have 250 unique counters in the program. (CT1 to CT250) There is only one counter (CNT) instruction in the PLC, but you can adapt it to handle any counting application that you may need.
Counter Number – This is a number from CT1 to CT250 to specify the counter.
Set Point – This is an integer (16 Bit) or double integer that represents the set point of the counter. The values are from 1 to 9999 for and integer and 1 to 999999999 for a double integer. This can also be a memory location (I or I2) so that the counter set value can change during program execution.
Current Value – This is the location in which you can see use the current value. It is automatically assigned by the counter number. Example: CT1 = CTD1, CT2 = CTD2, etc.
Completion Bit – This is the bit that will turn on when the counter has completed. It is set automatically by the software and is the same as the counter number.
Count Type – This can be one of the three types of counter. Count UP – Will increment up to the set point. Count Down – Will decrement down from the set point to zero. Count Up & Down – Will increment or decrement the current count value. The output will turn on when the set value is reached.
Note: All of the counters will have a reset input. This will reset the current value to zero for the Count Up and Count Up & Down modes. The Count Down will reset the current value to the set value.
Applications that use counters always start with a timing chart. This is the secret to using counters in your programs. Additional information on counters can be found at the following post. The Secret Of Using Counters

Memory Retentive

Click Koyo Plc Software

Memory retentive means that when power is removed from the PLC or it switches from run to stop mode, the current value is not lost. (Reset) The default for timers is non-memory retentive. The counters are memory retentive. In the Click PLC we can choose this setting along with the initial (Reset) values.

Next time we will look at compare and math instructions.

Watch on YouTube : Click PLC Counters
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.

Plc


The program control instructions will allow us to specify what parts of the logic get solved and when this happens. This will control how the PLC will scan and solve your logic in your program.

Previously in this series we have discussed:
System Hardware – Video
Installing the Software – Video
Establish Communication – Video
Numbering System and Addressing – Video
Timers and Counters
– Counter Video
– Timer Video
Compare and Math Instructions – Video
The programming software and manuals can be downloaded from the Automation Direct website free of charge.

Click PLC Program Control Instructions

Program control (flow) instructions in the Click PLC will utilize interrupts and subroutines. In the last post on Click PLC Compare and Math Instructions, we discussed interrupts. They can be timed or event (Built-in inputs on the CPU.) When the interrupt happens it will immediately go and solve the logic in the interrupt and then return to the instruction following the location that it was called. This can and will happen at any time throughout the scan of the PLC.

Interrupt – Click Program Control

Let’s take a look at an example of an interrupt. We will flash an output on for 3 seconds and off for 3 seconds. A review of entering interrupts can be found in our last post. Click PLC Compare and Math Instructions

We will be using software interrupt 1. The interval time will be 3 seconds and it will call up our interrupt routine called ‘Flasher 3sec’.

Here is the interrupt program quick guide that will be displayed as a reminder of the way in which interrupts are used.

The code that we use for the flasher is just a normally closed contact going to the output of the same contact. Since this logic will only execute once every three seconds, it will alternate the output on and off.

Subroutines – Click Program Control

Subroutines are blocks of code that will get executed when they are called from the main program. This differs from the interrupt because with subroutines we have complete control of when it will be executed in relation to the main program. In the Click PLC, we can have 986 subroutines. This means that we will have 986 calls or more in the main program to execute the code in the subroutine. We cannot have nested subroutines. This means that each subroutine must return to the main program. It cannot call another subroutine.
When a Subroutine program is not called during a scan of the main program the memory bits and data registers within the subroutine will maintain their status unless some other part of the program changes their status or data.

The purpose of subroutines is to organize your code into manageable pieces. These pieces can also be re-usable. The readability of your PLC program improves when using subroutines because you are just looking at smaller pieces of code. The alternative would be all of the rungs in just the main program. This is hard to read and especially troubleshoot when things are not working.
Here is what happens when scanning the program:

  1. Main program logic is scanned/solved until it reaches a subroutine call
  2. Subroutines logic is scanned /solved until it reaches the return statement
  3. The main program logic continues to scan/solve with the rung that follows the subroutine call
  4. This will continue until the End statement is read which will then complete the rest of the PLC scan and start again

Note: Interrupt routines can happen at any time and the logic will continue to be solved after the logic of the interrupt is executed.

Subroutine Example – Click Program Control

Let’s look at an example. We will have two motors that need to be controlled. Each motor will have a start, stop and jog push buttons.
The first thing that we will do is make our subroutines. (Motor 1 and Motor 2)

Click Plc Software Update

To make a new subroutine, you can do one of the following.
Main Menu – Program | Add new subroutine program…
Keyboard Shortcut – Control ‘U’ – CTRL+ U
Navigation Window – Right Click on ‘Subroutine Program’ and select ‘Add New Subroutine Program CTRL+ U’

Enter the name of the subroutine. (Motor 1) Hit OK. The subroutine program quick guide will now appear. It will remind us of how to use the subroutine program. Hit OK.

Under the navigation window, we will now see our subroutine Motor 1. Double click on it and we will enter the following code for motor 1.

You will notice that the subroutine background defaults to green. The interrupt background is red. This can be changed by going to the following menu selection. Main Menu – Setup | Software Setup…
Now repeat the steps above for another subroutine for motor 2. It should look like the following:

Under the navigation window, double-click the main program. We can now call our subroutines that we have just made in the main program so that they will execute. We will use unconditional rungs and the ‘Call’ instruction. Enter the following on the main program.

Click Plc Software

Note: Since we created our subroutines before using the call instruction they are available in the pull down menu of the instruction. We could also have added a new subroutine by this same instruction.

Looking at the navigation window we can see our two subroutines and interrupt the program.

Download the Click PLC Program Control sample PLC program.

Controlling our program is easy with subroutines and interrupts. The advantage is that our program will also be easier to read, understand and troubleshoot.

Next time we will look at shift register instruction.

Watch on YouTube: Click PLC Program Control Instructions
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 PLCs 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.

Click Plc Software Free

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.

Click Plc Software Manual

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

Click Plc Software Update