Speak with authority, quality is trustworthy.

Based on PLC light light is the basic problem understanding standardization of PLC programming -

by:Coolmay     2020-06-22
What? Light lamp can also serve as the topic, also is worth you once-ler topic writing an article on the so-called technology to do?

well, today is going to start from the basic problem, write an article on the standardized programming, let's see if everyone has been pushing the standardization of programming is simple how to deal with this problem. Also let you test yourself, common understanding of the most simple programming problem is in place.

light, is the most simple application indicates the running machine. Started at the time of relay logic, usually directly from the motor phase line all the way out of AC 220 v power supply, the indicator light is lit 220 v. Later, for the sake of safety, light is not use 220 v, switch to 24 v dc lamp, then use a pair of auxiliary contacts of contactor, achieve the goal of the same.

later, found that the light bulb is a life, will be bad, and once if bulb is broken, can't correct instruction equipment running status. So I need a single lamp check button, at the time of LAMP_TEST button, disk all indicator lights up, so that maintenance personnel can find which light bulb is broken. If it is a PLC controller system, cannot borrow contactor contacts at this moment, must use a separate DO channel.

after a single indicator lights DO, also can add a function, namely the equipment running lights, stops, and in the event of failure, can let the light shine. Even, can give different alarm level, design different flicker frequency. Usually for 1 hz, in S7 - Is SM0 in 200. 5.

a standard indicator of ladder diagram logic is as follows:

this logic, read or write their own, not thousands of times. Principle is very simple, but each time around, however, didn't from simplification to simplify, only boring to repeat over and over again.

when doing the standardization demonstrative project, I didn't think much of lights, thinking of nothing but one more OUT pins in FB module, used to put light, while inside the FB, put the ladder diagram of the repeat.

well, now, because of the upper machine equipment malfunction and interface are mostly from the WINCC screen can be expressed. Basic don't need in the operation of the device class disk installed lights. So do demonstration project for a long time didn't do light is logical.

but then have important process period, finally met indicator light. And is that is audible and visual alarm:

in my FB to simply add an output pin HA, and then wait for the alarm lamp point Q tied here.

to FB calls for the second time, I found, process design, process called twice indicator light is the same! From at that time I actually began to be ladder diagram nausea. Pay attention to my article one can find the previous article '' Wan quan river. Success ladder diagram. A careful reading.

where evil? FB OUT the output is completely thorough exclusive! Not just pin to 1 Q 1, and 0, Q must be 0. Must be lifetime, not a woman to marry. That is not allowed to double output, double coil.

like I here twice process with one lamp, if the simple direct binding, the final state of light can only follow logical state of FB call one last time. In front of the binding failed.

so, I was compelled helpless, abruptly beyond logic and building a the OR logic:

if you understand somewhat to standardized programming concept, will know after the repair patch to me, how don't. It can be said that was something for a long time can't relief.

it violates the principle of modular standardization project, namely the logic and object separately, script and cast completely separate rules.

thoroughly standardized demonstration projects, that alone, demonstrates is not enough. But when I was in the share project program, and specially for the students, as a lesson, until today to criticize my own.

I admit, I did not attach enough importance to light in the past, did not regard it as a device type, is wrong. New project is coming, I first take lamp operation, created the special light FB module.

two INOUT pins, is used to control the output flicker and normally on respectively.

then also compiled for simple synchronous LINK FB LINK. LINK1 and LINK2 are INOUT types used in the output.

setting output, when the rise of input signal along the reset output falling edge. The effect seems to be on the output will be equal to the input signal. But essentially the input signal for output is not occupied. Other input signal can also be used to control the same output.

calls within the program logic is as follows:

HA. HA_ON is introduced into to arguments as INOUT type.

I here two sets of technology is absolutely impossible to run at the same time, so don't happen ON requirements for light time overlap, lead to can't light up or put out correctly. So FB in simple processing. And even if there is the possibility of overlapping, but can be by counting method to achieve more precise logic.


With new and upcoming social commerce technologies, the biggest change for plc manufacturers marketers will be a shift in focus from branding to lead generation and conversion.
Have you been looking for a good plc manufacturers programmable control systems provider? If so, we suggest that you check out Shenzhen Coolmay Technology Co., Ltd. at Coolmay PLC.
The proprietor has many years experience in providing promotion services and is a sought after expert in plc manufacturers.
Along the way, Shenzhen Coolmay Technology Co., Ltd. will face a wide range of challenges. The most successful will show our resolve by working through the challenges and finding ways to improve and grow.
plc manufacturers are raising the stakes of social marketing, but they also ease the sales process by providing ways for plc controller price to effectively interact with customers.
Chat Online
Chat Online
Chat Online inputting...
Sign in with: