PLC Programming Quickstart Guide : First 60 minutes of most PLC Programming Environments – Part 3- PLC Programming tools

This is part 3 of the PLC programming quickstart. The checklist continues with items 5 and 6.  This part will cover PLC programming tools in the development environments . To recap the items covered in the previous two parts.

  1. I/O Declaration : Find the methods and location of I/O declaration for the PLC program.
  2. Variable declaration: Find the location and types of variables supported.
  3. PLC Logic: Check on the location of program organization units (POU’s) . Check on applicability of programs, functions and function blocks.
  4. Task Configuration: Are the POU’s to be executed organized by task. If so, check on the location functionality of the task manager.

This part will cover 2 more items. Step 5  is to explore the general environment and program language editors. Step 6 is the function in the environment.

5. Environment, Editors, Toolbars 

There is often more than one way to do things in the programming environment. Get to know the locations and options of the tools and editor specific functions.

A good starting point is usually the toolbox and toolbars. In SoMachine and CCW, selecting  View in the menu bar at the top yields a selection of toolbars and functions available in the environment.

The toolbox
The toolbox

In SoMachine and CCW, the toolbox shows up on the right side of the screen.

The toolbox objects and functions in SoMachine for ladder
The toolbox objects and functions in SoMachine for ladder

The other option for adding objects into a program is using the object icons in the toolbar at the top, below the menus.

PLC programming environment tools
Objects at the top

 

Another place to check is the contextual options available when using the right click button. For example, in the ladder environment, right clicking in a rung ( or network as it is referred to in IEC terminology) brings up the objects that can be added.

Contextual right click as a PLC programming tool
Right click in the ladder editor brings up objects that can be added

This also applies to other parts of the environment. For example, right clicking in the device directory brings up items that can be added in a specific context.

 

Adding ethernet device in the PLC programming tool
Right click in the Ethernet network setting brings up the option to add a device

This shows us there are often multiple ways to accomplish the same outcome. An coil can be added by dragging and dropping it from the toolbox. A coil can be added by right clicking on the rung/network. A coil can be added from the menu bar at the top.

The right click also pulls up some contextual options in the CCW environment.

PLC Programming tools in CCW
Adding functions and objects in CCW by using a right click and the selector.

 

PLC programming environment - CCW -
Adding a new program with a right click

Find the way that you feel most comfortable using. There is no right and wrong to it.

6. Functions and libraries

Any task becomes harder without the right tools. For a long time, I was re-creating a periodic ON-OFF function using two timers until I discovered a function called BLINK in CODESYS. The same applied to a simple scaling function block. I later found  one already built into SoMachine. The moral of the story is to figure out what is available in the environment early. It will save time and effort. It will reduce the amount of code that gets written. 

There are a set of functions that are used in most PLC programs. These include timers, triggers and PID function blocks. Knowing where these functions are and how they are used is next on this checklist.

To find the basic functions:

  • check toolbox from previous step.
  • if there is a library manager, check the libraries
  • review the help files

For instance, in SoMachine, the Util and Toolbox libraries are worth a review. They contain functions to simplify programming..scaling, limit checking, PID,…

They are located in the Library Manager.

Library Manager – Util library functions

Final point about familiarizing with a PLC environment, browse through the help files. There may be details about implementing different functions. The structure of the help files in SoMachine and CCW includes a content list and a search function. Browse through the content list. If anything, this may show you the  functions and terminology in the environment.

 

In summary, the tools and functions in a PLC programming environment will make or break the programming experience. Some key steps on getting up to speed:

  1. Familiarize yourself and explore the environment prior to starting a project.
  2. Exploration will include clicking (including right clicks : 0) through all the functions, object and menus on-screen.
  3. Browse through the functions libraries and toolboxes.
  4. Browse through the help files.

If a question comes up while doing the above, note it down. Check with the vendor or refer to any example projects that may be available.

Happy programming on your next PLC project!

 

Share

Leave a Reply

Your email address will not be published. Required fields are marked *