Speak with authority, quality is trustworthy.

The programming method of improving the speed PLC program

by:Coolmay     2020-10-17
Method to improve programming of PLC programs run at newmaker welcome to e hall exhibition hall 3 PLC PLC programmable controller, PLC programming cable. 。 。 How to improve PLC controller program running speed, can adopt the following several programming methods, only supplies the reference: 1, according to the actual engineering demand, function block planning, write subroutines in PLC, subroutine is controlled for some specific purpose of relatively independent program. Instruction execution CALL subroutine CALL, etc. , if the condition does not meet the subroutine CALL, the application of scanning is only in the main program, no longer to scan the jokes, thus reducing the unnecessary scan time. 2, words, or double word is rumored to DO points method in the application of PLC controller to control the output usually have a large number of output control, words or double word is rumored to DO some methods to control the output can improve the speed, as long as according to the requirements of practical application, the reasonable distribution of output address, commutation control output control word, can greatly reduce the steps of PLC program execution, so as to speed up the PLC controller program is running. 3, pulse trigger the SET and RESET the PLC, using the SET command can be executed only once, don't need to scan every time to carry out the instructions, very suitable for and pulse output ( PLS/PLF) Instruction. Some engineering personnel to overlook the problem, using the conventional method to drive a SET order, inadvertently increased the PLC program scans the running time. 4, to avoid the type conversion to S7 - 200 as an example, its memory format is the opposite of our commonly used PC, it is the high word before, and the low word in the back. So we can put two bytes after word variable, two bytes before the program initialization time will reset ( The rest of the program may not use this two bytes) 。 If we define symbols defined word variable in VW2, while maintaining VW0 value is zero. The program can be used in the VW2 to access the variable type, at the same time also can VD0 with double word access, to avoid the type conversion. In order to avoid confusion when using, in order to make clear the best symbol definition to distinguish word type and double word type. In this class are strongly recommended to Hungarian: with a prefix indicating variable types, with capitalize the first letter of the English words in the group cooperation variable names. I used the following compose: b - — Byte type variable ( byte) w— — Type variable ( 词) d— — Double word variable ( 双) r— — Real variables ( real) f— — A variable ( 国旗) btn— — Since the reset button input ( 按钮) sw— — Toggle switch, or the lock button input ( 开关) sig— — Sensor, the coding level signal input (such as 信号) r - — The output relay ( relay) This according to personal habits, of course, there is no rule, mainly to distinguish his advantages. If there is a word type variable named VarName, for using the technique of the conversion, we can define like this: wVarName - — VW2 dVarName— — VD0 VW0 at initialization program reset ( If you don't need to memory variables, directly to the dVarName reset can also) Or in the heart of the data block VW0 set to zero. Later need to word with wVarName when type variable access, need to double word type with dVarName when variable access. No need to type conversion. This method can greatly reduce the number of program statements, make the program more concise, readable, because do not need to do time consuming type conversion, process efficiency is also improved. And mathematical computation, the greater the efficiency, the more obvious. Disadvantage is to take up two bytes of memory, more later in the program cannot use VW0. But S7 - 200 RAM space is very big, generally is to burn, in 226, for example, there are as many as 10 k RAM, I never had more than 1 k. The RAM are bought, not white, not also is wasted. Likewise, if a byte type variables often need and word type transformation, let take up a word memory byte variable width waste a byte, avoid type conversion. The above is improving the speed of PLC programming method.
plc controller price are required in the manufacture of almost every product and programmable control systems plc manufacturers is one of the most common machines.
The best for plc controller price is one that works best for your needs and what you can support in your home. Among Shenzhen Coolmay Technology Co., Ltd. 's diversified list of products at different price ranges, you will surely find your one with high quality. make your choice at Coolmay PLC!
Like anything else in programmable control systems, there are a variety of choices and types to choose from, and each of them will affect your budget in some form. Shenzhen Coolmay Technology Co., Ltd. offers a range of quality at competitive prices.
To have a that needs much precaution in handling, it is best to rely only on reliable providers. Shenzhen Coolmay Technology Co., Ltd. can provide quality plc controller price plc manufacturers that meet all your requirements for a while meet your individual needs.
Chat Online
Chat Online
Chat Online inputting...
Sign in with: