Basic PLC programming question

Adrish

Member
Join Date
May 2003
Posts
2
I'm a complete beginner at PLC programming. Can anyone tell me WHY we separate the control and actuation sections in a ladder logic diagram? Is it a necessity or just good programming practice? :confused:
 
Last edited:
Depends on the author I suppose. Some reasons can include:

Easy to put Master control sections (MCR's) around outputs.

The state of an output may change based on several things (Set / Multiple reset's come to mind)

The outputs may be send down a communications link, and it's easier to keep the final message building till last

For testing. Perhaps you want to test code without firing outputs; you can put an 'END' type statement before the actual physical outputs.

In some cases, you may not even have the physical I/O Assignments available when you start programming (Projects where one person/team does hardware, one person/team does software), so you code generically with internal bits for I/O, and then later drive them from the actual I/O assignment when you have it.


Just a few possible reasons why, there are more I'm sure.
 
Portability

If you are working on several similar machines that have differences in I/O, seperating the logical and real world stuff has great advantages. Techs can learn one machine and know the others. Program changes are easier to propagate. As noted it also allows for easier zone control...

Recycling code becomes easier the more modular it is. Build good solid functions once then copy as needed. :^)
 
It is generally considered good programming practice by many people. It does make trouble shooting easier for someone who is unfamiliar with the program if the code is broken up into different section. You can even do this without impelenting sections but by sectionalising the program in one big section but it is not as easy to follow.
🍺
 
By doing that Adrish, we break the program in small understandable chunks. Essentially, it is only a good programming practice, born out of the necessity ( :D ) of making the program understandable to say, a new programer, portability would be a good word to use here (someone may use your codes in his programs). Secondly, it also helps in program development and in highlighting the problem when trubleshooting.
 
Advantages:
1) Regardless of the discrete input wiriing, the bit address can always represent the "TRUE" or "comment when 1" state of the address comment.
2) Allows the programmer to write the PLC program without a wiring schematic.
3) Easy program changes at installation time if wiring doesn't match print.
4) Since HMI reading of the I/O image table is taboo
5) Facilitates translation to Control Logix Processor since I/O in that processor is asynchrounous to the plc program scan
6) Easier to check out I/O at startup (can place jumps around I/O)
7) Facilitates simulation
 

Similar Topics

Hello all, i am planning to start basic plc and programming classes online if anybody is interested mail me
Replies
3
Views
1,416
Hi, I am using visilogic to control a system that i have designed. I have designed a automated color sorting mechanism using a color sensor. I...
Replies
2
Views
1,450
Hi, I am new to PLCs and would like to learn basics and possibly use them in my projects. I would like to use a PLC to generate pulses for a...
Replies
3
Views
11,443
Hello, Does anybody here from the Philippines who knows a resource person or institution who conducts Quantum PLC Basic Maintenance and...
Replies
0
Views
3,694
As per the title, does anybody make a basic PLC that directly supports IO-Link without requiring a fieldbus and remote IO modules? I know it goes...
Replies
9
Views
1,707
Back
Top Bottom