+(86)0752-5103606 E-mail:info@hytech-cn.com

Analysis of the difference between PLC control and single-chip microcomputer control

Last Updated on 2021-10-25 Hits:4232

PLC is actually a set of already-built single-chip microcomputer (microcontroller has a wide range) system.

     You can understand the PLC ladder diagram as a programming language like assembly and other calculator languages, but the scope of use is different! And the usual practice is to convert your ladder diagram into C or assembly language by the PLC software (used by the PLC) CPU decision), and then use assembly or C compilation system to compile into machine code! PLC runs just a few code. Ladder diagram just makes it easier for users to use.

       The same MCS-51 single-chip microcomputer can of course also be used for PLC production, but 8-bit CPU in some advanced applications such as: a large number of calculations (including floating point calculations), embedded systems (now UCOS can also be transplanted to MCS-51), etc., a little bit powerless That's it. The industrial system our company is using is made with MCS-51 single-chip microcomputer, but with the addition of DSP, it can already meet our requirements (our equipment is slower and the logic control is mainly used, but there are a lot of points. 128 points of I/O!!), and also using ladder diagram programming, we are converting our ladder diagram to C51 and then compiling with KEIL's C51. Have you not noticed that different types of PLC will use different CPUs! !

       Of course, it is also possible to directly develop the control system with a single-chip microcomputer, but the requirements for developers are quite high (not the general level can be competent), the development cycle is long, and the cost is high (for some large-scale systems, you need to do experiments, and the printed circuit board needs a The pen is quite expensive. You can say that you use the emulator and the experiment board to develop, but I want to tell you that you only verify the feasibility of the hardware and software, and it does not mean that it can be used in industrial control systems, because the industry The requirements of the control system against interference are very high, stability first, not performance first, so your circuit board design must be constantly experimented and improved). When you solve the above problems, you will find that you have made a PLC Of course, if you need others to use it easily, you also need a set of software, so you don’t need to tell others about your circuit (you can't tell others).

       Many people think that PLC is very mysterious. In fact, PLC is very simple. In addition to its high speed, its internal CPU is not as good as ordinary single-chip microcomputers in other functions. Usually PLC adopts 16-bit or 32-bit CPU with 1 or 2 serial channels to communicate with the outside world. It is enough to have a timer inside. If you want to improve reliability, it is enough to add a watchdog timer.

      The key technology of the PLC is that a program that can explain the ladder diagram language and an auxiliary communication program are solidified inside. The efficiency of the interpreter program of the ladder diagram language determines the performance of the PLC, and the communication program determines the difficulty of the PLC to exchange information with the outside world. For simple applications, it usually operates as an independent controller, and does not need to exchange information with the outside world, only a program that can explain the ladder diagram language is solidified inside.

      In fact, the main job of designing a PLC is to develop and explain the ladder diagram language program.

友情链接: 广州到上海物流 集运系统 情趣家具 猎酷网 物流网站 展会运输 淘宝集运