Normally open inputs are the ones that have the two vertical lines separated by a space in between. Normally open inputs, like normally open relays, do not by default create a connection between the two rails when connected.
When activated, only then it will create the connection. These inputs could be any input device or sensor that is used to conditionally activate an output device.
Normally closed inputs are the ones that have the two vertical lines with a forward slash that connects the two opposite ends. Shown above is the notation for an output device in a PLC ladder logic diagram. PLCs have solved the problem brought by relays, and it was thanks to the software-based relays that were designed for the PLC.
These relays now only rely on the memory component of the PLC so instead of actually using relays to create a connection point, the memory of the PLC now only stores the states of the supposed relays. Internal relays are elements that hold data to serve as relays for the system. This is what makes the PLC more cost-effective than the conventional relay systems that were used before. For example, using an internal relay in conjunction with a push button allows you to turn on a solenoid valve in one rung and a motor in another rung using the same push button.
When the PLC is suddenly turned off, whether due to a power outage or some connection breaks, the states of the internal relays become erased automatically. Because of this, when you start the PLC after that scenario, the states of the internal relay will go back to the initial stage of the program rather than the LAST state that it had before the power outage happened.
This is where battery backed relays come into play. They retain their state of activation even when the power supply of the PLC is entirely off. Hence, they are also called retentive coils. Internal relays only retain their state if the input devices that are placed to activate them are also retaining their activation states. For set and reset relays, however, you can actually retain their state indefinitely and then remove the state using another condition from an input device.
The internal relays were designed for a specific purpose which is obviously to eliminate the need of external relays. This is desirable because not only you would not worry anymore about a relay getting some wear and tear, but also you would not have to worry about spending money on them. In designing control systems, there are times when you would want more than one condition to turn something ON or OFF.
In this situation, using the input device notation over and over again would be impractical and messy as a ladder logic program. The rung would have too many things on it! Thus, the program above shows that there are two conditions that are represented by an internal relay EACH. In practical applications, sometimes an output must be held ON for an indefinite amount of time until power is cut. Input devices are usually momentary in nature, hence, for that scenario to happen, Latching programs are required to be set up in the PLC programming software.
So far, we have talked about retaining the states of relays and actually doing it even without power supplied to the PLC.
Now, this type of operation is used when you want just an output pulse that does not retain its state all throughout the program. This function is termed as one-shot. One shot operation is momentary, hence pushing the trigger button will only cause an impulse to the output device. Master inputs are used when you want the whole program to be dependent on a Master Control condition. It does not matter if the Slave START buttons were pushed over and over again, because the system will not start without the Master ON button being in an energized state.
The AND condition is basically just two inputs in series with each other. Because the inputs are in series, the two inputs must BOTH have continuity in order for the output to turn on. The OR condition is a parallel connection between the two inputs. Because the inputs are in parallel to each other, ANY of them may create continuity between the two power rails thus turning the output ON.
Negating inputs is as simple as turning a Normally Open input to a Normally Closed one. Normally Open inputs are inverted. The XOR condition has a different story than the rest of the logical conditions. If you look at the Boolean equation for the XOR condition:.
XNOR is rarely used as a logical statement, but it is actually best applied when simplifying logical expressions that have a negated output for XOR. The safest way is to apply it to the output. In applying the PLC programming skills that you have learned throughout this mini programming course, make sure that you familiarize yourself with the different safety techniques that are most commonly used in control systems!
Emergency stop buttons are essential in every control system because when the output devices start malfunctioning, you can have control of the power using the PLC by setting an emergency stop button. Usually, drilling machines are controlled using this type of setup. A sensor input is also used to ensure that an object that was expected to be in the drilling platform is actually on the platform before the operator can even start the drilling.
Lastly, proximity sensing is used as a safety measure when there are huge machines that may impose risks because of some produced tiny projectiles or even being caught by the machine itself.
This is used to ensure that the controlled machines would not cause any harm when accidentally approached if that is even a thing. In doing PLC programming, there are plenty more combinations of programs that you may be able to design using the knowledge that you have acquired in this post.
It can be done by using ladder logic and boolean logic instructions or it can be done with a counter. It can even be done with PLC rising edge and falling edge triggers or with shift registers.
The blog has a lot of very useful information about PLC programming and especially ladder logic. Take a look at the blog and see the many ladder logic examples. But… there is a faster way to make the same toggle function with a single push button:. In his example, he uses 3 4 rungs only to make the toggle function of a push button simple version :. Generally speaking, you have three types of PLC timers available in ladder logic. The on-delay timer , the off-delay timer and the retentive timer or pulse timer.
The first type of timer in ladder logic is the on delay timer. Its name comes from the fact, that the on delay timer delays its output from the on signal. As soon as the on delay timer gets a signal at the input , the timer starts to count down. When the preset time is up, the output of the on delay timer will turn on. If the input is turned off before the count down finish, the time will reset.
On delay timers in ladder logic can look different depending on the PLC programming software. But common for all of them are the following:. The enable output EN is the first output and it is on when the timer is energized.
So, as long as the input is true or on, the enable output will be true. Second output is the done output DN. This output in an on delay timer is only on, when the timer has counted down the preset time. Look at this great video for more info about the on delay timer.
Instead of starting the count down from the signal at the input turns on, the off delay timer starts to count down from the signal turning off at the input signal. The example below is from Sakshat Virtual Labs. In the example, ladder logic is used to visualize the values of the three bits in an off delay timer.
Another example with the use of the off delay timer in ladder logic is in heating. When you are heating something, you often have some sort of cooling too.
A good example of that is a heating oven. The oven is heated by an electrical heater, and in the side there are ventilation motors to cool the oven after use. The electrical heater and the cooling fans should turn on simultaneously. Why the cooling fans has to turn on too, is to circulate the hot air and spread the heat.
Since both the fans and the heater has to start at the same time, the two outputs should work simultaneously. But keep in mind, that the cooling fans has to run for some time, after the heater is turned off.
Example of motors with cooling in ladder logic. Off delay timer for extra delay. The time only pauses if the input is turned off before the count down is finished. When the input is turned on again, the timer continues counting down from where the time was paused.
The word retentive even means to retain , and that is what retentive timers do. They retain the time they have counted when the input is off. KronoTech has published a very informative PLC program example. With the use of a retentive timer to control a motor with an automatic lubrication system, they have made a great practical example.
Ladder logic program for automatc lubrication. Feel free to watch this video for more information about PLC timers in ladder logic. The video illustrates some great examples and the basics of PLC timers. Finally I will encourage you to take a look at my video about the pulse timer. The pulse timer is used for generating pulses of a specific length and is very useful in ladder logic:. Motor control can be done with a PLC program. Here are some examples of ladder diagrams for motor control.
One of the most common ways to start an AC motor is by first starting the motor in star connection. When the motor speed is sufficient, the connection is switched to delta. This is due to the high current AC motors use when starting.
To switch between the star and the delta relay, a timer is used. It includes a lot explination and a lot of great power and control circuit diagrams.
Example 5 is on page Still commonly used in many factories the DOL or direct on line motor starter is another way of starting AC motors. The DOL is made of a contactor usually 3-phase contactor , an overload relay like the thermal relay, and some connections in between. Sometimes you might have to use a smaller relay between the PLC output and the coil of the contactor.
Make sure you always check the ratings of the PLC outputs you are using. All examples of how to use PLC programming and ladder logic to solve real problems. One of the most used applications for a PLC is the traffic lights. At many schools, universities and even companies you will get the challenge to make a traffic light ladder logic diagram. The traffic light PLC program is a combination of timers to control which lights are turned on and for how long time.
But some sort of interlock must be there to prevent the green light to be on in multiple directions. A PLC program like the traffic light is a little more complicated and therefore are a lot more solutions to.
For inspiration you can look at these good examples of traffic light ladder diagrams:. The first ladder logic example is from Engineer On A Disk, which is a marvelous site full of great articles. In the example you will get all the ladder diagrams and step-by-step instructions and explanation. PLC program example of a traffic light. Inst Tools. Discuss different PLC program examples for Signal lamp task, Valve operation program and make an output switch off when any of the sensors activated.
A signal lamp is required to be switched on if a pump is running and the pressure is satisfactory, or if the lamp test switch is closed. For the inputs from the pump and the pressure sensors we have an AND logic situation since both are required if there is to be an output from the lamp.
We, however, have an OR logic situation with the test switch in that it is required to give an output of lamp on regardless of whether there is a signal from the AND system. The function block diagram and the ladder diagram are thus of the form shown in Figure 1. As another example, consider a valve which is to be operated to lift a load when a pump is running and either the lift switch is operated or a switch operated indicating that the load has not already been lifted and is at the bottom of its lilt channel.
0コメント