Multi-backup data control method, system, storage medium and control device

By introducing a multi-backup data control method in the multi-backup computing control and display system, and using the negotiated data packet negotiation working mode, the independent switching of the computing control unit is realized, solving the problem that the graphics card switching system occupies the video interface and the display module in the prior art cannot switch independently, and improving the reliability and stability of the system.

CN112084067BActive Publication Date: 2025-02-28GUANGZHOU CAIYI TECHNOLOGY CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202010954408.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-09-11
Publication Date
2025-02-28
Estimated Expiration
2040-09-11

AI Technical Summary

Technical Problem

The existing multi-backup computing control and display systems require a graphics card switching system to display the normal operation of the computing control video data. The graphics card switching system occupies the video interface of the computing control unit. When the computing control unit fails, the display module cannot automatically switch to the backup unit, which increases the reliability risk of the system.

Method used

By introducing a multi-backed data control method in the control device, using the negotiated data packet to negotiate the master or slave working mode, it determines whether the first control module is the master control device. If otherwise, the second control module is recommended as the master control device to realize independent switching.

Benefits of technology

It effectively reduces the risk of a comprehensive system failure, avoids the use of the video output port of the computing control unit by the graphics card switching system, and improves the reliability and stability of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112084067B_ABST
    Figure CN112084067B_ABST
Patent Text Reader

Abstract

The present invention provides a multi-backup data control method, system, storage medium and control device, which are applied to a control device, the control device includes a first control module and at least one second control module in communication connection with the first control module; the data control method includes: after the control device is powered on, sending and receiving a negotiation data packet; the sent negotiation data packet includes a first negotiation parameter for negotiating a master or slave working mode with the second control module; the received negotiation data packet includes a second negotiation parameter sent by the second control module to negotiate a master or slave working mode with the first control module; according to the received negotiation data packet, deciding whether the first control module is a master control device; if so, executing a control operation; if not, recommending a second control module in communication with it as a master control device. The present invention can effectively reduce the risk of a comprehensive failure of the entire system, and does not need to occupy the video output port of the computing control unit and the graphics card switching system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of computer control technology, and relates to a control method and system, and in particular to a multi-backup data control method, system, storage medium and control device. Background Art

[0002] A multi-backup computing control and display system is a system in which multiple computing control units work simultaneously under the same program and drive the same set of displays. When one computing control unit works normally as the main control device, the remaining computing control units maintain real-time monitoring status. When the computing control unit of the main control device fails, it can replace its work in real time to ensure the normal operation of the entire system. Usually, a multi-backup system includes two or more computing control units (each equipped with a memory), a graphics card switching system, and one or more displays. Under the existing technology, a graphics card switching system is required to display the video data of one of the normally operating computing controls. The graphics card switching system needs to occupy the video interface such as DVI or HDMI of the computing control unit. In addition, when a computing control unit fails, the display module does not have the function of autonomously switching to the normal computing control unit. Due to its complexity, the computing control unit is often the part with higher reliability risk in the system.

[0003] Therefore, how to provide a multi-backup data control method, system, storage medium and control device to solve the problem that the prior art requires a graphics card switching system to display one of the normally operating computing control video data, the graphics card switching system needs to occupy the DVI or HDMI and other video interfaces of the computing control unit, once a computing control unit fails, the display module does not have the function of autonomously switching to the normal computing control unit, and due to the complexity of the computing control unit, it brings high risks to the system. This has become a technical problem that needs to be urgently solved by technical personnel in this field. Summary of the invention

[0004] In view of the shortcomings of the prior art described above, the purpose of the present invention is to provide a multi-backup data control method, system, storage medium and control device, which are used to solve the problem that the prior art requires a graphics card switching system to display one of the normally operating computing control video data, and the graphics card switching system needs to occupy the DVI or HDMI and other video interfaces of the computing control unit. Once a computing control unit fails, the display module does not have the function of autonomously switching to the normal computing control unit, and due to the complexity of the computing control unit, it brings high risks to the system.

[0005] To achieve the above-mentioned purpose and other related purposes, the present invention provides a multi-backup data control method on the one hand, which is applied to a control device, which includes a first control module and at least one second control module that is communicatively connected to the first control module; the multi-backup data control method includes: after the control device is powered on, sending and receiving a negotiation data packet; the sent negotiation data packet includes a first negotiation parameter for negotiating a master or slave working mode with the second control module; the received negotiation data packet includes a second negotiation parameter sent by the second control module to negotiate a master or slave working mode with the first control module; based on the received negotiation data packet, deciding whether the first control module is a master control device; if so, executing a control operation; if not, recommending a second control module that communicates with it as a master control device.

[0006] In one embodiment of the present invention, the first negotiation parameter includes an identification code of the first control module, a default initial operating mode of the first control module, an identification code of the first control module recommended as the master device, and a corresponding recommended value; the second negotiation parameter includes an identification code of the second control module, a default initial operating mode of the second control module, an identification code of the second control module recommended as the master device, and a corresponding recommended value.

[0007] In one embodiment of the present invention, the step of deciding whether the first control module is the master device based on the received negotiation data packet includes: comparing the recommended value corresponding to the recommended second control module with the preset recommended value; if the recommended value corresponding to the recommended second control module is greater than or equal to the preset recommended value, it indicates that the second control module is the master device; if the recommended value corresponding to the recommended second control module is less than the preset recommended value, a comparison of identification codes is performed.

[0008] In one embodiment of the present invention, if no negotiation data packet is received from the second control module or an abnormal negotiation data packet is received within a preset time period after the first control module recommends itself as the master device, the first control module continues to be recommended as the master device, and the recommended value corresponding to the recommendation of the first control module as the master device is superimposed; if the superimposed recommended value reaches the preset recommended value, the first control module notifies the second control module connected to it that its working mode is the master mode, and clears the recommended value corresponding to the recommendation of the first control module as the master device.

[0009] In one embodiment of the present invention, the step of comparing the identification codes includes: if the identification code of the first control module is greater than the identification code of the second control module, recommending the first control module as a slave device, regenerating a negotiation data packet, and sending it to the second control module; if the identification code of the first control module is less than the identification code of the second control module, continuing to recommend the first control module as a master device, and superimposing the recommended value corresponding to the recommended second control module; when the superimposed recommended value reaches a preset recommended value, the identification code of the first control module is still less than the identification code of the second control module recommended as the master device, the first control module notifies the second control module communicating with it that its working mode is the master mode, and clears the recommended value corresponding to the recommendation of the first control module as the master device.

[0010] In one embodiment of the present invention, the regenerated negotiation data packet includes: an identification code of the first control module, a default initial working mode of the first control module, a recommendation that the second control module is the master device, and a recommended value corresponding to the recommended second control module plus 1; the identification code of the second control module recommended as the master device is smaller than the identification code of the first control module.

[0011] In one embodiment of the present invention, when the first control module is recommended as a slave device, it is detected whether the negotiation data packet sent by the second control module as the master device is abnormal; if so, a negotiation data packet recommending the first control module as the master device is sent to the second control module, and the recommended value corresponding to the recommended first control module is superimposed; when the superimposed recommended value reaches a preset recommended value, the first control module is recommended as the master device, and the recommended value corresponding to the second control module is cleared.

[0012] On the other hand, the present invention provides a multi-backup data control system, which is applied to a control device, which includes a first control module and at least one second control module that is communicatively connected to the first control module; the multi-backup data control system includes: a communication unit, which is used to send and receive negotiation data packets after the controlled device is powered on; the sent negotiation data packet includes a first negotiation parameter for negotiating a master or slave working mode with the second control module; the received negotiation data packet includes a second negotiation parameter sent by the second control module to negotiate a master or slave working mode with the first control module; a processing unit, which is used to decide whether the first control module is a master control device based on the received negotiation data packet; if so, execute a control operation; if not, recommend a second control module that communicates with it as a master control device.

[0013] Another aspect of the present invention provides a storage medium having a computer program stored thereon, which implements the multi-backup data control method when executed by a processor.

[0014] The last aspect of the present invention provides a control device, comprising: a processor and a memory; the memory is used to store a computer program, and the processor is used to execute the computer program stored in the memory, so that the control device executes the multi-backup data control method.

[0015] As described above, the multi-backup data control method, system, storage medium and control device of the present invention have the following beneficial effects:

[0016] The multi-backup data control method, system, storage medium and control device of the present invention can effectively reduce the risk of a complete failure of the entire system, and does not require the use of the video output port of the computing control unit and the graphics card switching system. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Figure 1 Shown is a schematic diagram of a communication network to which the present invention is applied.

[0018] Figure 2 FIG. 1 is a flow chart of a multi-backup data control method in one embodiment of the present invention.

[0019] Figure 3 It is a schematic diagram of the process of S22 of the present invention.

[0020] Figure 4 It is a schematic diagram showing the principle structure of a multi-backup data control system of the present invention in one embodiment.

[0021] Component number description

[0022] 1 Communication Network

[0023] 11 Control Equipment

[0024] 12 Ethernet switches

[0025] 13 Display Output Controller

[0026] 14 Display

[0027] 15 Output Controller

[0028] 4. Multi-backup data control system

[0029] 41 Communication unit

[0030] 42 Processing Units

[0031] Steps S21 to S25 DETAILED DESCRIPTION

[0032] The following describes the embodiments of the present invention by specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict.

[0033] It should be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present invention, and thus the drawings only show components related to the present invention rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout may also be more complicated.

[0034] Embodiment 1

[0035] This embodiment provides a multi-backup data control method, which is applied to a control device, the control device comprising a first control module and at least one second control module in communication with the first control module; the multi-backup data control method comprises:

[0036] After the controlled device is powered on, a negotiation data packet is sent and received; the sent negotiation data packet includes a first negotiation parameter for negotiating a master or slave working mode with the second control module; the received negotiation data packet includes a second negotiation parameter sent by the second control module for negotiating a master or slave working mode with the first control module;

[0037] According to the received negotiation data packet, it is determined whether the first control module is a master device; if so, a control operation is performed; if not, a second control module communicating with it is recommended as a master device.

[0038] The following is a diagram of the multiple backup data control method provided by this embodiment. The multiple backup data control method of this embodiment is applied to Figure 1 The communication network shown. The communication network 1 includes a control device 11, an Ethernet switch 12, a display output controller 13, a display 14 and an output controller 15. The control device 11 includes a first control module 111 and at least one second control module 112 that is communicatively connected to the first control module 111. The first control module 111 and the second control module 112 are communicatively connected to the Ethernet switch 12 via an Ethernet port. The Ethernet switch 12 is also communicatively connected to the display output controller 13 and the output controller 15 via an Ethernet port.

[0039] See also Figure 2, which is a flow chart of a multi-backup data control method in one embodiment. Figure 2 As shown, the multi-backup data control method specifically includes the following steps:

[0040] S21, after the control device is powered on, a negotiation data packet is sent, and S21' is executed at the same time to receive a negotiation data packet.

[0041] In this embodiment, the sent negotiation data packet includes a first negotiation parameter for negotiating the master or slave working mode with the second control module. The received negotiation data packet includes a second negotiation parameter sent by the second control module for negotiating the master or slave working mode with the first control module.

[0042] Specifically, the first negotiation parameter includes an identification code of the first control module (for example, a network MAC address, a device ID, etc.), a default initial working mode of the first control module, an identification code that recommends the first control module to be a master device, and a corresponding recommended value (the recommended value ranges from 0 to 255). In this embodiment, the default initial working mode of the first control module is a slave mode.

[0043] The second negotiation parameters include an identification code of the second control module (eg, a network MAC address, a device ID, etc.), a default initial working mode of the second control module, an identification code that recommends the second control module to be a master device, and a corresponding recommended value.

[0044] S22, based on the received negotiation data packet, decide whether the first control module is the master device; if so, execute S23, that is, execute the control operation; if not, execute S24, that is, recommend a second control module communicating with it as the master device. In this embodiment, executing the control operation includes controlling the display output of the display output controller 13 and controlling the output of the communication data of the output controller 15.

[0045] See also Figure 3 , which is a schematic diagram of the process of S22. Figure 3 As shown, the S22 includes:

[0046] S221, compare the recommended value corresponding to the recommended second control module with the preset recommended value. If the recommended value corresponding to the recommended second control module is greater than or equal to the preset recommended value (the predicted recommended value is, for example, 100), it indicates that the first control module is the main control device, and proceeds to S222; if the recommended value corresponding to the recommended second control module is less than the preset recommended value, compare the identification codes to determine whether the identification code of the first control module is greater than the identification code of the second control module. If so, proceed to S223; if not, proceed to S224.

[0047] S222, if the first control module does not receive a negotiation data packet sent by the second control module or receives an abnormal negotiation data packet within a preset time period after recommending itself as the master device, the first control module continues to recommend itself as the master device, and superimposes the recommended value corresponding to the recommendation of the first control module as the master device, that is, +1 is added to the original recommended value; if the superimposed recommended value reaches the preset recommended value (for example, 100), the first control module notifies the second control module connected to it that its working mode is the master mode, and clears the recommended value corresponding to the second control module; after determining that the first control module is the master device, go to S23 to perform the control operation. In this embodiment, the CRC check bit in the data packet is used to determine whether the negotiation data packet is abnormal.

[0048] S223, if the identification code of the first control module is greater than the identification code of the second control module, the first control module is recommended as a slave device, a negotiation data packet is regenerated, and sent to the second control module. In this embodiment, the regenerated negotiation data packet includes: the identification code of the first control module, the default initial working mode of the first control module, the recommendation of the second control module as the master device, and the recommendation value corresponding to the recommended second control module plus 1. At this time, the identification code of the second control module recommended as the master device is less than the identification code of the first control module.

[0049] S224, if the identification code of the first control module is smaller than the identification code of the second control module, continue to recommend the first control module as the master control device, and superimpose the recommended value corresponding to the recommended second control module, that is, add 1 to the original recommended value.

[0050] S225, when the superimposed recommended value reaches the preset recommended value, the identification code of the first control module is still smaller than the identification code of the second control module recommended as the master device, the first control module notifies the second control module communicating with it that its working mode is the master mode, and clears the recommended value corresponding to the recommendation of the first control module as the master device.

[0051] S24, recommends a second control module that communicates with it as the main control device, and at the same time, detects whether the negotiation data packet sent by the second control module as the main control device is abnormal (the manifestation of the abnormality of the sent negotiation data packet includes an erroneous negotiation data packet or stopping sending the negotiation data packet); if so, execute S25; if not, go to S21 and continue sending the negotiation data packet.

[0052] S25, sending a negotiation data packet recommending the first control module as the main control device to the second control module, and superimposing the recommended value corresponding to the recommended first control module, that is, adding 1 to the original recommended value; when the superimposed recommended value reaches the preset recommended value, recommending the first control module as the main control device, and clearing the recommended value corresponding to the second control module.

[0053] In this embodiment, after negotiation is completed by the multi-backup data control method described in this embodiment, the first control module serves as the display output control, and the second control module serves as the backup control device and stores the same data as the main control device.

[0054] The multi-backup data control method described in this embodiment can effectively reduce the risk of a complete failure of the entire system, and does not require the use of the video output port of the computing control unit and the graphics card switching system.

[0055] This embodiment also provides a storage medium (also called a computer-readable storage medium) on which a computer program is stored. When the computer program is executed by a processor, the above-mentioned multi-backup data control method is implemented.

[0056] A person skilled in the art can understand that computer-readable storage media: all or part of the steps of implementing the above-mentioned method embodiments can be completed by hardware related to the computer program. The aforementioned computer program can be stored in a computer-readable storage medium. When the program is executed, the steps of the above-mentioned method embodiments are executed; and the aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other media that can store program codes.

[0057] Embodiment 2

[0058] This embodiment provides a multi-backup data control system, which is applied to a control device, the control device comprising a first control module and at least one second control module in communication with the first control module; the multi-backup data control system comprises:

[0059] a communication unit, configured to send and receive a negotiation data packet after the controlled device is powered on; the sent negotiation data packet includes a first negotiation parameter for negotiating a master or slave working mode with the second control module; the received negotiation data packet includes a second negotiation parameter sent by the second control module for negotiating a master or slave working mode with the first control module;

[0060] The processing unit is used to decide whether the first control module is a master device according to the received negotiation data packet; if so, perform a control operation; if not, recommend a second control module communicating with it as the master device.

[0061] The following will describe in detail the multi-backup data control system provided by this embodiment in conjunction with the diagram. Figure 4 , which is a schematic diagram showing the principle structure of a multi-backup data control system in one embodiment. Figure 4 As shown, the multi-backup data control system 4 includes a communication unit 41 and a processing unit 42 .

[0062] The communication unit 41 is used to send a negotiation data packet after the device to be controlled is powered on, and the communication unit 41 receives the negotiation data packet.

[0063] In this embodiment, the sent negotiation data packet includes a first negotiation parameter for negotiating the master or slave working mode with the second control module. The received negotiation data packet includes a second negotiation parameter sent by the second control module for negotiating the master or slave working mode with the first control module.

[0064] Specifically, the first negotiation parameter includes an identification code of the first control module (for example, a network MAC address, a device ID, etc.), a default initial working mode of the first control module, an identification code that recommends the first control module to be a master device, and a corresponding recommended value (the recommended value ranges from 0 to 255). In this embodiment, the default initial working mode of the first control module is a slave mode.

[0065] The second negotiation parameters include an identification code of the second control module (eg, a network MAC address, a device ID, etc.), a default initial working mode of the second control module, an identification code that recommends the second control module to be a master device, and a corresponding recommended value.

[0066] The processing unit 42 is used to determine whether the first control module is the master device according to the received negotiation data packet; if so, perform a control operation; if not, recommend a second control module communicating with it as the master device. In this embodiment, performing a control operation includes controlling the display output of the display output controller 13 and controlling the output of the communication data of the output controller 15.

[0067] Specifically, the processing unit 42 compares the recommended value corresponding to the recommended second control module with the preset recommended value. If the recommended value corresponding to the recommended second control module is greater than or equal to the preset recommended value (the predicted recommended value is, for example, 100), it indicates that the first control module is the master device. If the communication unit 41 does not receive the negotiation data packet sent by the second control module or receives an abnormal negotiation data packet within the preset time period after the first control module recommends itself as the master device, the processing unit 42 continues to recommend the first control module as the master device, and superimposes the recommended value corresponding to the recommended first control module as the master device, that is, +1 is added to the original recommended value; if the superimposed recommended value reaches the preset recommended value (for example, 100), the first control module notifies the second control module connected to it that its working mode is the master mode, and clears the recommended value corresponding to the recommended first control module as the master device; after determining that the first control module is the master device, a control operation is performed; if the recommended value corresponding to the recommended second control module is less than the preset recommended value, the identification code is compared to determine whether the identification code of the first control module is greater than the identification code of the second control module.

[0068] If the identification code of the first control module is greater than the identification code of the second control module, the processing unit 42 recommends the first control module as a slave device, regenerates a negotiation data packet, and sends it to the second control module. In this embodiment, the regenerated negotiation data packet includes: the identification code of the first control module, the default initial working mode of the first control module, the recommendation of the second control module as the master device, and the recommendation value corresponding to the recommended second control module plus 1. At this time, the identification code of the second control module recommended as the master device is less than the identification code of the first control module.

[0069] If the identification code of the first control module is smaller than the identification code of the second control module, the processing unit 42 continues to recommend the first control module as the master device, and superimposes the recommended value corresponding to the recommended second control module, that is, adds 1 to the original recommended value. When the superimposed recommended value reaches the preset recommended value, the identification code of the first control module is still smaller than the identification code of the second control module recommended as the master device, the first control module notifies the second control module in communication with it that its working mode is the master mode, and clears the recommended value corresponding to the second control module.

[0070] The processing unit 42 recommends a second control module that communicates with it as a master device, and at the same time, detects whether the negotiation data packet sent by the second control module as the master device is abnormal (the manifestation of the negotiation data packet being abnormal includes an erroneous negotiation data packet or stopping sending the negotiation data packet); if so, sends a negotiation data packet recommending the first control module as the master device to the second control module through the communication unit 41, and superimposes the recommended value corresponding to the recommended first control module, that is, +1 is added to the original recommended value; when the superimposed recommended value reaches the preset recommended value, the first control module is recommended as the master device, and the recommended value corresponding to the second control module is cleared.

[0071] It should be noted that it should be understood that the division of the various modules of the above system is only a division of logical functions. In actual implementation, they can be fully or partially integrated into one physical entity, or they can be physically separated. And these modules can all be implemented in the form of software called by processing elements, or all in the form of hardware, or some modules can be implemented in the form of software called by processing elements, and some modules can be implemented in the form of hardware. For example: the x module / unit can be a separately established processing element, or it can be integrated in a certain chip of the above system. In addition, the x module / unit can also be stored in the memory of the above system in the form of program code, and called and executed by a certain processing element of the above system. The implementation of other modules is similar. These modules can be integrated together in whole or in part, or they can be implemented independently. The processing element described here can be an integrated circuit with signal processing capabilities. In the implementation process, each step of the above method or each module above can be completed by an integrated logic circuit of hardware in the processor element or instructions in the form of software. The above modules may be one or more integrated circuits configured to implement the above methods, such as one or more application specific integrated circuits (ASIC), one or more digital singnal processors (DSP), one or more field programmable gate arrays (FPGA), etc. When a module is implemented in the form of a processing element scheduling program code, the processing element may be a general-purpose processor, such as a central processing unit (CPU) or other processors that can call program code. These modules may be integrated together and implemented in the form of a system-on-a-chip (SOC).

[0072] Embodiment 3

[0073] This embodiment provides a control device, which includes: a processor, a memory, a transceiver, a communication interface and / or a system bus; the memory and the communication interface are connected to the processor and the transceiver through the system bus and complete communication with each other, the memory is used to store computer programs, the communication interface is used to communicate with other devices, and the processor and the transceiver are used to run computer programs, so that the control device executes each step of the multi-backup data control method described in the above embodiment.

[0074] The system bus mentioned above can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The system bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus. The communication interface is used to realize the communication between the database access system and other devices (such as clients, read-write libraries, and read-only libraries). The memory may include random access memory (RAM), and may also include non-volatile memory, such as at least one disk storage.

[0075] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.

[0076] The protection scope of the multi-backup data control method described in the present invention is not limited to the execution order of the steps listed in this embodiment. All solutions implemented by adding, reducing, or replacing steps in the prior art based on the principles of the present invention are included in the protection scope of the present invention.

[0077] The present invention also provides a multi-backup data control system, which can implement the multi-backup data control method described in the present invention. However, the implementation system of the multi-backup data control method described in the present invention includes but is not limited to the structure of the multi-backup data control system listed in this embodiment. All structural deformations and replacements of the prior art made according to the principles of the present invention are included in the protection scope of the present invention.

[0078] In summary, the multi-backup data control method, system, storage medium and control device of the present invention can effectively reduce the risk of a complete failure of the entire system, and does not require the use of the video output port of the computing control unit and the graphics card switching system. The present invention effectively overcomes various shortcomings in the prior art and has a high industrial utilization value.

[0079] The above embodiments are merely illustrative of the principles and effects of the present invention, and are not intended to limit the present invention. Anyone familiar with the art may modify or alter the above embodiments without departing from the spirit and scope of the present invention. Therefore, all equivalent modifications or alterations made by a person of ordinary skill in the art without departing from the spirit and technical concept disclosed by the present invention shall still be covered by the claims of the present invention.

Claims

1. A multi-backup data control method, characterized in that: Applied to a control device, the control device includes a first control module and at least one second control module in communication with the first control module; the multi-backup data control method includes: After the controlled device is powered on, a negotiation data packet is sent and received; the sent negotiation data packet includes a first negotiation parameter for negotiating a master or slave working mode with the second control module; the received negotiation data packet includes a second negotiation parameter sent by the second control module for negotiating a master or slave working mode with the first control module; According to the received negotiation data packet, decide whether the first control module is a master device; if so, perform a control operation; if not, recommend a second control module communicating with it as a master device; The first negotiation parameter includes an identification code of the first control module, a default initial working mode of the first control module, an identification code of the first control module recommended as a master device and a corresponding recommended value; the second negotiation parameter includes an identification code of the second control module, a default initial working mode of the second control module, an identification code of the second control module recommended as a master device and a corresponding recommended value, and the default initial working mode of the first control module is a slave control mode; The step of determining whether the first control module is the master device according to the received negotiation data packet comprises: comparing the recommended value corresponding to the recommended second control module with the preset recommended value, and if the recommended value corresponding to the recommended second control module is greater than or equal to the preset recommended value, indicating that the first control module is the master device; if the recommended value corresponding to the recommended second control module is less than the preset recommended value, comparing the identification code; The step of comparing the identification codes includes: if the identification code of the first control module is greater than the identification code of the second control module, recommending the first control module as a slave device, regenerating a negotiation data packet, and sending it to the second control module; if the identification code of the first control module is less than the identification code of the second control module, continuing to recommend the first control module as a master device, and superimposing the recommended value corresponding to the recommended second control module; when the superimposed recommended value reaches a preset recommended value, the identification code of the first control module is still less than the identification code of the second control module recommended as the master device, the first control module notifies the second control module communicating with it that its working mode is the master mode, and clears the recommended value corresponding to the recommendation of the first control module as the master device.

2. The multi-backup data control method according to claim 1, characterized in that: If no negotiation data packet from the second control module is received within a preset time period after the first control module recommends itself as the master device, or an abnormal negotiation data packet is received, the first control module continues to be recommended as the master device, and the recommended value corresponding to the recommendation of the first control module as the master device is superimposed; if the superimposed recommended value reaches the preset recommended value, the first control module notifies the second control module connected to it that its operating mode is the master mode, and clears the recommended value corresponding to the recommendation of the first control module as the master device.

3. The multi-backup data control method according to claim 2, characterized in that: The regenerated negotiation data packet includes: an identification code of the first control module, a default initial working mode of the first control module, a recommendation that the second control module be the master device, and a recommendation value corresponding to the recommended second control module plus 1; the identification code of the second control module recommended as the master device is smaller than the identification code of the first control module.

4. The multi-backup data control method according to claim 2, characterized in that: When the first control module is recommended as a slave device, detect whether the negotiation data packet sent by the second control module as the master device is abnormal; if so, send a negotiation data packet recommending the first control module as the master device to the second control module, and superimpose the recommended value corresponding to the recommended first control module; when the superimposed recommended value reaches the preset recommended value, recommend the first control module as the master device, and clear the recommended value corresponding to the second control module.

5. A multi-backup data control system, characterized in that: Applied to a control device, the control device includes a first control module and at least one second control module in communication with the first control module; the multi-backup data control system includes: A communication unit, configured to send and receive a negotiation data packet after the device to be controlled is powered on; the sent negotiation data packet includes a first negotiation parameter for negotiating a master or slave working mode with the second control module; the received negotiation data packet includes a second negotiation parameter sent by the second control module for negotiating a master or slave working mode with the first control module; wherein the first negotiation parameter includes an identification code of the first control module, a default initial working mode of the first control module, an identification code of the first control module recommended as the master device and a corresponding recommended value; the second negotiation parameter includes an identification code of the second control module, a default initial working mode of the second control module, an identification code of the second control module recommended as the master device and a corresponding recommended value; a processing unit, configured to determine whether the first control module is a master device according to the received negotiation data packet; if so, perform a control operation; if not, recommend a second control module communicating with it as the master device; the default initial working mode of the first control module is a slave mode; The processing unit is also used for: comparing the recommended value corresponding to the recommended second control module with the preset recommended value, if the recommended value corresponding to the recommended second control module is greater than or equal to the preset recommended value, it indicates that the first control module is a master device; if the recommended value corresponding to the recommended second control module is less than the preset recommended value, then the identification code is compared; if the identification code of the first control module is greater than the identification code of the second control module, the first control module is recommended as a slave device, and a negotiation data packet is regenerated and sent to the second control module; if the identification code of the first control module is less than the identification code of the second control module, the first control module is continuously recommended as a master device, and the recommended value corresponding to the recommended second control module is superimposed; when the superimposed recommended value reaches the preset recommended value, the identification code of the first control module is still less than the identification code of the second control module recommended as a master device, the first control module notifies the second control module connected to it that its working mode is the master mode, and clears the recommended value corresponding to the recommended first control module as a master device.

6. A storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the multi-backup data control method described in any one of claims 1 to 4 is implemented.

7. A control device, characterized in that: include: Processor and memory; The memory is used to store a computer program, and the processor is used to execute the computer program stored in the memory, so that the control device executes the multi-backup data control method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Redundancy switching unit of Chinese-made-Loongson-processor-based measurement and control devices

    CN107728463A