Improved method of board card type PLC (Programmable Logic Controller)

By designing the power-down data protection process and the onboard buzzer component process in the board-type PLC, the problems of poor performance and lack of onboard buzzer in high temperature environments are solved, the equipment life and reliability are improved, and Flash is avoided Over-erroring of the chip and the convenience of on-board buzzer is achieved.

CN119127781APending Publication Date: 2024-12-13MIANYANG SHUHUI NEW ENERGY TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411142823.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-20
Publication Date
2024-12-13

AI Technical Summary

Technical Problem

Existing board-type PLCs have poor performance and short life in high temperature environments. The use of supercapacitors or backup batteries leads to untimely storage of data, resulting in excessive Flash chip erasing, affecting life. At the same time, there is a lack of on-board buzzer, which requires external expansion. Increase costs and inconvenience.

Method used

Design the power-down data protection process and the on-board buzzer component process, detect the power voltage drop by hardware to trigger the MCU interrupt for data storage, avoid the use of electrolyte components, and set up the on-board buzzer on the surface of the PLC board, and use register drives buzzer.

Benefits of technology

It improves the life and reliability of the PLC, avoids excessive rewritten Flash chips, reduces maintenance costs, and realizes the convenient use of on-board buzzer without occupying the output terminal.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119127781A_ABST
    Figure CN119127781A_ABST
Patent Text Reader

Abstract

The invention relates to a board card type PLC improvement method, which comprises a power-down data protection process and an onboard buzzer element process, and is characterized in that the power-down data protection process comprises the following steps: S1, when the power supply voltage drops to the turn-off voltage of a voltage stabilizing diode, a transistor is changed from a turn-on state to a turn-off state, and level switching occurs; s2, the change causes an external interruption at the IO port of the MCU, at the moment, the MCU enters an interruption program to carry out data storage urgently, the external interruption is generated in the MCU after the voltage drop of the power supply is detected through hardware, and the interruption is jumped into the chip to carry out data storage, so that the use of a backup battery or a super capacitor which is rich in electrolyte is avoided; and the behavior of repeatedly erasing and writing Flash in the chip is avoided, the service life is prolonged, and the reliability is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the field of board-card PLC, in particular to an improvement method of board-card PLC. Background Art

[0002] The existing board card PLC power-off data preservation method is realized by supercapacitors or batteries. When the external power supply is cut off, the PLC microprocessor is powered by the backup battery or supercapacitor for a long time. Due to the chemical characteristics of supercapacitors or backup batteries, they have poor high temperature performance and short life, which affects the life of the PLC microprocessor and has poor reliability. At the same time, the PLC processor itself works very fast, but it is unknown when to save the data, so it is generally adopted to save the data once at a time, that is, the data to be saved is written to the Flash every once in a while. If it works for a long time, it will cause excessive erasure of the Flash inside the chip, affecting the life of the chip. In addition, the battery and supercapacitor themselves contain a large amount of electrolyte, which will dry up and evaporate. The higher the ambient temperature, the more obvious this phenomenon is, so the life is short, the reliability is poor, and the maintenance cost is high.

[0003] Existing board-type PLCs are not equipped with onboard buzzers. When used, an external buzzer is required, which occupies output terminals, increases costs and is inconvenient to install.

[0004] Therefore, we propose an improved method for board-type PLC, which avoids the use of backup batteries or components rich in electrolyte such as supercapacitors, and avoids the behavior of repeatedly erasing Flash inside the chip, thereby improving life and reliability. At the same time, the PLC onboard buzzer does not occupy the output terminal and is easy to use. Summary of the invention

[0005] The purpose of the present invention is to overcome the shortcomings of the prior art, adapt to actual needs, and provide an improved method for board-type PLC to solve the current problems of poor high temperature performance, short life, affecting the life of the PLC microprocessor, poor reliability, and at the same time, the PLC processor itself works very fast, but it is unknown when to save the data, so the general method is to save the data once at a time, that is, the data to be saved is written into the Flash every certain period. If it works for a long time, it will cause excessive erasure of the Flash inside the chip, affecting the life of the chip. In addition, the battery and supercapacitor themselves contain a large amount of electrolyte, and the electrolyte will dry up and evaporate. The higher the ambient temperature, the more obvious this phenomenon is, so the life is short, the reliability is poor, the maintenance cost is high, and the existing board-type PLC is not equipped with an onboard buzzer, and an external buzzer is required when in use, which occupies the output terminal, increases the cost, and is inconvenient to install. Technical problems.

[0006] In order to achieve the purpose of the present invention, the technical solution adopted by the present invention is: designing an improved method for board-type PLC, including a power-off data protection process and an onboard buzzer component process, wherein the power-off data protection process includes the following steps:

[0007] S1, when the power supply voltage drops to the turn-off voltage of the Zener diode, the transistor changes from on to off, and level switching occurs;

[0008] S2. This change causes an external interrupt at the MCU's IO port, and the MCU enters the interrupt program to save data urgently.

[0009] Preferably, the onboard buzzer component process includes the following steps:

[0010] S1. Set an onboard buzzer on the surface of the PLC board;

[0011] S2. When driving the buzzer, modify the program to select the M point of the PLC or other registers as the driving identifier of the buzzer;

[0012] S3. This register is monitored in the PLC program. If this point is 1 or 0, the high or low level output from the MCU output port will drive the onboard buzzer.

[0013] Preferably, in S3 of the onboard buzzer component process, when other registers are used as driving identifiers of the buzzer, the other registers are arbitrarily specified.

[0014] Preferably, in S3 of the onboard buzzer component process, when the corresponding IO port is set high, the onboard buzzer sounds, and when the corresponding IO port is set low, the onboard buzzer is turned off.

[0015] Compared with the prior art, the present invention has the following beneficial effects:

[0016] 1. The present invention generates an external interrupt in the MCU after the power supply voltage drops through hardware detection, and the chip jumps into the interrupt to save data, avoiding the use of components rich in electrolyte such as backup batteries or supercapacitors, and avoiding the behavior of repeatedly erasing and writing Flash inside the chip, thereby improving life and reliability.

[0017] 2. The PLC onboard buzzer of the present invention does not occupy the output terminal and is easy to use. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] Figure 1 It is a schematic diagram of the power-off data protection program flow of the present invention;

[0019] Figure 2 It is a schematic diagram of the process flow of the onboard buzzer element of the present invention;

[0020] Figure 3This is a block diagram of the power-off detection principle of the present invention;

[0021] Figure 4 This is a circuit diagram of a buzzer drive added to the board type of the present invention. DETAILED DESCRIPTION

[0022] The present invention is further described below in conjunction with the accompanying drawings and embodiments:

[0023] Example 1: Improvement method of board-type PLC, see Figures 1 to 4 , including the power-off data protection process and the onboard buzzer component process. The power-off data protection process includes the following steps:

[0024] S1, when the power supply voltage drops to the turn-off voltage of the Zener diode, the transistor changes from on to off, and level switching occurs;

[0025] S2. This change causes an external interrupt at the MCU's IO port, and the MCU enters the interrupt program to save data urgently.

[0026] Since the MCU itself executes very quickly and the time to write data to the Flash is very short, data can be saved completely before the power supply voltage drops to a voltage where the MCU cannot work. Data is written to the Flash only when the voltage drops sharply, thus avoiding repeated erasing of the Flash and extending the life of the chip.

[0027] Since the Flash does not need to be repeatedly erased and written, and it only occurs when the voltage drops sharply, the time is short and infrequent, and the power supply does not need super capacitors or backup batteries that can continuously supply power for a long time. Only ordinary filter electrolytic capacitors are sufficient.

[0028] For details, see Figure 2 , the onboard buzzer component process includes the following steps:

[0029] S1. Set an onboard buzzer on the surface of the PLC board;

[0030] S2. When driving the buzzer, modify the program to select the M point of the PLC or other registers as the driving identifier of the buzzer;

[0031] S3. This register is monitored in the PLC program. If this point is 1 or 0, it corresponds to the high or low level output from the MCU output port to drive the onboard buzzer. Adding a buzzer to the PLC board is small in size, low in cost, does not occupy the output port, and is easy to use.

[0032] For further information, see Figure 2 In S3 of the onboard buzzer component process, when other registers are used as the driving identifier of the buzzer, other registers are specified arbitrarily.

[0033] It is worth noting that see Figure 2 In S3 of the onboard buzzer component process, when the corresponding IO port is set high, the onboard buzzer sounds, and when the corresponding IO port is set low, the onboard buzzer is turned off.

[0034] In addition, the components designed in the present invention are all universal standard parts or components known to technical personnel in this field. Their structures and principles can be known to technical personnel through technical manuals or through conventional experimental methods. They can be fully implemented by technical personnel in this field. Needless to say, the content protected by the present invention does not involve improvements to internal structures and methods.

[0035] The embodiments of the present invention disclose preferred embodiments, but are not limited thereto. A person skilled in the art can easily understand the spirit of the present invention based on the above embodiments and make different extensions and changes. However, as long as they do not deviate from the spirit of the present invention, they are all within the protection scope of the present invention.

Claims

1. An improved method for a board-type PLC, including a power-off data protection process and a board-mounted buzzer component process, characterized in that: The power-off data protection process includes the following steps: S1, when the power supply voltage drops to the turn-off voltage of the Zener diode, the transistor changes from on to off, and level switching occurs; S2. This change causes an external interrupt at the MCU's IO port, and the MCU enters the interrupt program to save data urgently.

2. The improved method of the board-type PLC as claimed in claim 1, characterized in that: The onboard buzzer component process includes the following steps: S1. Set an onboard buzzer on the surface of the PLC board; S2. When driving the buzzer, modify the program to select the M point of the PLC or other registers as the driving identifier of the buzzer; S3. This register is monitored in the PLC program. If this point is 1 or 0, the high or low level output from the MCU output port will drive the onboard buzzer.

3. The improved method of the board-type PLC as claimed in claim 1, characterized in that: In S3 of the onboard buzzer component process, when other registers are used as driving identifiers of the buzzer, the other registers are arbitrarily specified.

4. The improved method of the board-type PLC as claimed in claim 1, characterized in that: In S3 of the onboard buzzer component process, when the corresponding IO port is set high, the onboard buzzer sounds, and when the corresponding IO port is set low, the onboard buzzer is turned off.