Basics of Programming


Basics of Programming
There are two types of contacts in PLC's and they are normally open and normally closed switches. A normally open contact means the contact is on when pressed/closed, and a normally closed contact is on when open/not pressed. Contacts represent the states of real world inputs like sensors, switches, if the part is present, empty, full, etc. PLC's also consist of coils, which are outputs like motors, pumps, lights, timers, etc. The PLC examines inputs and turns coils on or off whenever it is needed. They can also be used as inputs to other rungs in the ladder diagram. 
Functionality
The functionality of the PLC has evolved over the years to include sequential relay control, motion control, process control, distributed control systems, and networking. The data handling, storage, processing power, and communication capabilities of some modern PLCs are approximately equivalent to desktop computers. PLC-like programming combined with remote I/O hardware, allow a general-purpose desktop computer to overlap some PLCs in certain applications. Desktop computer controllers have not been generally accepted in heavy industry because the desktop computers run on less stable operating systems than do PLCs, and because the desktop computer hardware is typically not designed to the same levels of tolerance to temperature, humidity, vibration, and longevity as the processors used in PLCs. Operating systems such as Windows do not lend themselves to deterministic logic execution, with the result that the controller may not always respond to changes of input status with the consistency in timing expected from PLCs. Desktop logic applications find use in less critical situations, such as laboratory automation and use in small facilities where the application is less demanding and critical, because they are generally much less expensive than PLCs.
Basic and Complex functions
The most basic function of a Programmable logic controller (PLC) is to receive inputs from status components, which can be from sensors or switches. Some of the basic components of a PLC are input modules, a central processing unit, output modules, and a programming device. When an input is activated, some output will also be activated by whatever you told the machine to do. Some examples of this are setting a timer to 10ms, activating the timer and once 10ms have passed a siren goes off. Some advantages to using a PLC over other programming devices are the user doesn't have to rewire anything, the PLC has very little downtime in between running different programs, the user can program off-line, and PLC's aren't time constrained. If the user tells the PLC to perform an output in 10ms, it will perform the output in 10ms unlike other programs like LabView which can have a delay in activation. 
Timers and Counters
The main function of a timer is to keep an output on for a specific length of time. A good example of this is a garage light needing to cut off after 2 minutes to give someone time to go into the house. The three different types of timers that are commonly used are a Delay-OFF, a Delay-ON, and a Delay-ON-Retentive. A Delay-OFF timer activates immediately when turned on, counts down from a programmed time then cuts off, and is cleared when the enabling input is off. A Delay-ON timer is activated by input and starts accumulating time, counts up to a programmed time and then cuts off, and is cleared when the enabling input is turned off. A Delay-ON-Retentive timer is activated by input and starts accumulating time, retains the accumulated value even if the rung goes false, and resets only by a RESET contact.


Comments

Popular posts from this blog

Security

Programming