Air conditioner controller communication protocol processing method and device, equipment and storage medium
By sending the first communication protocol when the internal and external units of the air conditioner controller communicates for the first time and determining the effective communication protocol type based on the response results, the problem of incompatibility between the new and old protocols is solved, and the effective operation of any matching internal and external units and the stability of the operating system is realized.
Patent Information
- Application Number
- CN202311785635.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-22
- Publication Date
- 2025-06-24
AI Technical Summary
In the prior art, there are incompatibility problems between the new and old protocols, resulting in some or all of the control logic of the internal and external units not being able to operate normally, affecting the operating system.
When the internal and external machines communicate for the first time, the first communication protocol is sent to the slave control device, and the effective communication protocol type is determined based on the response result of the slave control device, and the effective communication protocol type between the master control device and the slave control device is determined through a test method.
Ensure that any matching internal and external units can operate effectively, avoid control logic errors or affecting the operating system.
Smart Images

Figure CN120201042A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of computer communication protocols, and particularly to a method, device, equipment and storage medium for processing an air conditioner controller communication protocol. Background Art
[0002] During the development of electronic control software, in order to ensure the upgradability of the electronic control program of the electrical system, additional byte lengths are usually added on the basis of the array length specified in the communication protocol. With the iteration and optimization of new and old protocols, old products on the market may still use outdated old protocols, which may lead to incompatibility problems between new and old protocols. When this happens, it may cause some or all of the control logics of the indoor and outdoor units to fail to operate properly, thereby affecting other software logics and even the operating system. In severe cases, it may cause the operating system to crash. Summary of the Invention
[0003] The present invention aims to solve at least one of the technical problems existing in the related art. For this purpose, the present invention provides a method for processing an air conditioner controller communication protocol. When the indoor and outdoor units communicate for the first time, a first communication protocol is sent to the slave control device, and the effective communication protocol type of the slave control device is determined according to the response result of the slave control device. By means of experiments, the effective communication protocol type between the master control device and the slave control device is determined, which can enable the arbitrarily matched indoor and outdoor units to operate effectively, and avoid control logic errors or affecting the operating system.
[0004] The present invention also provides an apparatus for processing an air conditioner controller communication protocol.
[0005] The present invention also provides an electronic device.
[0006] The present invention also provides a storage medium containing computer-executable instructions.
[0007] According to the method for processing an air conditioner controller communication protocol provided by the first aspect embodiment of the present invention, it includes:
[0008] In response to determining that initialization is completed, a first communication protocol is sent to the slave control device, and the response result of the slave control device is received;
[0009] According to the response result of the slave control device, the communication protocol type to be sent to the slave control device next is determined, and the effective communication protocol type of the slave control device is determined; wherein, the communication protocol type includes a first communication protocol and a second communication protocol, and one of the first communication protocol and the second communication protocol is a new communication protocol, and the other is an old communication protocol;
[0010] The communication protocol type between the slave control device is configured as the above-mentioned effective communication protocol type.
[0011] According to an embodiment of the present invention, the step of sending the first communication protocol to the slave control device includes:
[0012] Sending the first communication protocol to the slave control device for a first preset number of times;
[0013] Then, the step of determining the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device specifically includes:
[0014] Determining the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device to the first communication protocol for the first preset number of times.
[0015] According to an embodiment of the present invention, the step of determining the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device to the first communication protocol for the first preset number of times specifically includes:
[0016] Determining the first actual number of times the slave control device correctly responds to the first communication protocol;
[0017] When a preset condition is satisfied between the first actual number of times and the first preset number of times, determining that the first communication protocol is the effective communication protocol type of the slave control device.
[0018] According to an embodiment of the present invention, after the step of determining the first actual number of times the slave control device correctly responds to the first communication protocol, it further includes:
[0019] When the preset condition is not satisfied between the first actual number of times and the first preset number of times, sending the second communication protocol to the slave control device, determining the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device, and determining the effective communication protocol type of the slave control device.
[0020] According to an embodiment of the present invention, the step of sending the second communication protocol to the slave control device, determining the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device, and determining the effective communication protocol type of the slave control device specifically includes:
[0021] Sending the second communication protocol to the slave control device for a second preset number of times;
[0022] Determining the second actual number of times the slave control device correctly responds to the second communication protocol;
[0023] When a preset condition is satisfied between the second actual number of times and the second preset number of times, determine that the second communication protocol is the valid communication protocol type of the slave control device.
[0024] According to an embodiment of the present invention, after the step of determining the second actual number of times for the slave control device to correctly respond to the second communication protocol, the method further includes:
[0025] When the preset condition is not satisfied between the second actual number of times and the second preset number of times, circularly send the first communication protocol and the second communication protocol to the slave control device;
[0026] When the number of circular transmissions is less than or equal to the third preset number of times, and the slave control device correctly responds to one of the first communication protocol or the second communication protocol, determine that the communication protocol type correctly responded by the slave control device is the valid communication protocol.
[0027] According to an embodiment of the present invention, after the step of circularly sending the first communication protocol and the second communication protocol to the slave control device, the method further includes:
[0028] When the number of circular transmissions is greater than the third preset number of times, and the slave control device fails to correctly respond to any of the first communication protocol and the second communication protocol, generate a fault signal.
[0029] According to an embodiment of the second aspect of the present invention, a communication protocol processing device for an air conditioner controller includes:
[0030] A communication module, configured to, in response to determining that initialization is completed, send a first communication protocol to a slave control device and receive a response result of the slave control device;
[0031] A receiving module, configured to determine the next communication protocol type to be sent to the slave control device according to the response result of the slave control device, and determine the valid communication protocol type of the slave control device; wherein, the communication protocol types include a first communication protocol and a second communication protocol, and one of the first communication protocol and the second communication protocol is a new communication protocol, and the other is an old communication protocol;
[0032] A configuration module, configured to configure the communication protocol type with the slave control device as the above-mentioned valid communication protocol type.
[0033] According to an embodiment of the third aspect of the present invention, an electronic device includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, the steps of the air conditioner controller communication protocol processing method provided in the first aspect of the present invention are implemented.
[0034] A storage medium containing computer-executable instructions according to an embodiment of the fourth aspect of the present invention, the computer-executable instructions being used to execute the steps of the air conditioner controller communication protocol processing method according to an embodiment of the first aspect of the present invention when executed by a computer processor.
[0035] One or more of the above technical solutions in the present invention have at least one of the following technical effects:
[0036] The air conditioner controller communication protocol processing method according to an embodiment of the present invention includes: in response to determining that initialization is completed, sending a first communication protocol to the slave control device and receiving a response result from the slave control device; determining the next communication protocol type to be sent to the slave control device according to the response result of the slave control device, and determining the valid communication protocol type of the slave control device; wherein, the communication protocol types include a first communication protocol and a second communication protocol, and one of the first communication protocol and the second communication protocol is a new communication protocol and the other is an old communication protocol; configuring the communication protocol type with the slave control device as the above valid communication protocol type. When the indoor and outdoor units communicate for the first time, sending a first communication protocol to the slave control device, determining the valid communication protocol type of the slave control device according to the response result of the slave control device, and determining the valid communication protocol type between the master control device and the slave control device by means of experiments can enable the arbitrarily matched indoor and outdoor units to operate effectively, avoiding control logic errors or affecting the operating system. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or related technologies, the following will briefly introduce the drawings required for use in the description of the embodiments or related technologies. Obviously, the drawings in the following description are only some embodiments of the present invention, and those of ordinary skill in the art can obtain other drawings according to these drawings without creative efforts.
[0038] Figure 1 It is a flowchart of the air conditioner controller communication protocol processing method provided by an embodiment of the present invention;
[0039] Figure 2 It is a schematic structural diagram of the air conditioner controller communication protocol processing device provided by an embodiment of the present invention;
[0040] Figure 3 It is a schematic structural diagram of the electronic device provided by an embodiment of the present invention.
[0041] Reference numerals:
[0042] 201. Communication module; 202. Control module; 203. Configuration module. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0043] To make the objectives, technical solutions, and advantages of the invention clearer, the following will clearly describe the technical solutions in the invention in conjunction with the accompanying drawings of the invention. Apparently, the described embodiments are some, rather than all, of the embodiments of the invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the invention without creative efforts fall within the scope of protection of the invention.
[0044] In the description of the embodiments of the present invention, it should be noted that the orientation or positional relationships indicated by the terms "center", "longitudinal", "transverse", "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", etc. are based on the orientation or positional relationships shown in the accompanying drawings. These are only for the convenience of describing the embodiments of the present invention and for simplification. They do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and thus should not be construed as a limitation on the embodiments of the present invention. In addition, the terms "first", "second", and "third" are only used for descriptive purposes and should not be construed as indicating or implying relative importance.
[0045] In the description of the embodiments of the present invention, it should be noted that unless otherwise clearly specified and defined, the terms "connected" and "coupled" should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be directly connected or indirectly connected through an intermediate medium. For those of ordinary skill in the art, the specific meanings of the above terms in the embodiments of the present invention can be understood according to specific circumstances.
[0046] In the embodiments of the present invention, unless otherwise clearly specified and defined, the first feature being "on" or "under" the second feature can be that the first and second features are in direct contact, or the first and second features are indirectly in contact through an intermediate medium. Moreover, the first feature being "above", "over", and "on top of" the second feature can be that the first feature is directly above or obliquely above the second feature, or simply indicates that the first feature has a higher horizontal height than the second feature. The first feature being "under", "beneath", and "underneath" the second feature can be that the first feature is directly below or obliquely below the second feature, or simply indicates that the first feature has a lower horizontal height than the second feature.
[0047] In the description of this specification, the descriptions with reference to terms such as "one embodiment", "some embodiments", "example", "specific example", or "some examples" mean that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the embodiments of the present invention. In this specification, the schematic expressions of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in a suitable manner in any one or more embodiments or examples. In addition, without contradiction, those skilled in the art can combine and combine the different embodiments or examples described in this specification and the features of different embodiments or examples.
[0048] In the embodiments of the present invention, the communication between the main control device and the slave control device exchanges data in a serial time-sharing manner. One of the main control device and the slave control device is a control panel or a wired controller or a remote control receiving board, and the other of the main control device and the slave control device is a main control board. When the indoor and outdoor units are used in combination, there is a problem of incompatibility between the new and old protocols between the main control device and the slave control device.
[0049] In the embodiments of the present invention, the control panel is used as the main control device, and the main control board is used as the slave control device.
[0050] According to the air conditioner controller communication protocol processing method provided by the first aspect embodiment of the present invention, please refer to Figure 1 , including:
[0051] S100. In response to determining that initialization is completed, send a first communication protocol to the slave control device and receive the response result of the slave control device.
[0052] It can be understood that initialization refers to a series of preparatory work performed when the indoor and outdoor units are started, including but not limited to loading the operating system, configuring hardware resources, and network connections. When these preparatory works are completed, the main functions can be started. After the initialization is completed, the main control device needs to establish communication with the slave control device. In order to achieve effective data exchange, both parties need to follow a specific communication rule, that is, the communication protocol. At this stage, the main control device will send the first communication protocol to the slave control device. After receiving the first communication protocol sent by the main control device, the slave control device will respond to the first communication protocol. The response result may be to confirm that the protocol has been received and understood, or it may indicate that the protocol cannot be recognized or supported. The main control device will wait and receive the response result of the slave control device.
[0053] S110. Determine the next communication protocol type to be sent to the slave control device based on the response result from the control device, and determine the valid communication protocol types of the slave control device. Among them, the communication protocol types include a first communication protocol and a second communication protocol, and one of the first communication protocol and the second communication protocol is a new communication protocol, and the other is an old communication protocol.
[0054] It can be understood that when the master control device receives the response result of the slave control device to the first communication protocol sent by it, it will analyze this response result to determine whether the slave control device can understand and support the protocol. If the slave control device confirms support, this protocol can continue to be used for communication; if not, another compatible communication protocol may need to be selected. After analyzing the response result of the slave control device, the master control device can determine which communication protocols are valid, that is, which communication protocols the slave control device can recognize and process, ensuring that subsequent data exchanges can be carried out under a communication protocol that both parties can understand, thus avoiding communication errors or data loss. The master control device can determine the next communication protocol type to be sent to the slave control device based on the response result of the slave control device. For example, if the slave control device can correctly respond to the first communication protocol, the subsequent code is sent according to the first communication protocol, and the first communication protocol is determined as the valid communication protocol. For different response results, the next communication protocol type to be sent to the slave control device is also different, and the determined valid communication protocol may also be different.
[0055] It should be noted that one of the first communication protocol and the second communication protocol is a new communication protocol, and the other is an old communication protocol. That is, after initialization, the master control device can verify through the new communication protocol or the old communication protocol. According to the response result of the slave control device, the valid communication protocol of the slave control device can be determined as the first communication protocol or the second communication protocol. Of course, it also includes other situations pointed out in the subsequent technical solutions.
[0056] S120. Configure the communication protocol type with the slave control device as the above valid communication protocol type.
[0057] It can be understood that in the previous step, the master control device has determined which communication protocols are valid based on the response result of the slave control device, that is, the protocols that the slave control device can recognize and process. To ensure the normal progress of data exchange between the master control device and the slave control device, the communication protocol type between the two parties needs to be set as the above valid communication protocol type. At this time, software or hardware settings need to be changed to enable the control device to follow the correct communication rules.
[0058] In the embodiments of the present invention, when the indoor unit and the outdoor unit communicate for the first time, a first communication protocol is sent to the slave control device, and the effective communication protocol type of the slave control device is determined according to the response result of the slave control device. By means of experiments, the effective communication protocol type between the master control device and the slave control device can be determined, enabling the indoor unit and the outdoor unit with any combination to operate effectively and avoiding control logic errors or affecting the operating system.
[0059] In some embodiments, the step of sending the first communication protocol to the slave control device includes:
[0060] Sending the first communication protocol to the slave control device for a first preset number of times.
[0061] It can be understood that the master control device needs to repeatedly send the first communication protocol to the slave control device according to the first preset number of times. For example, continuously sending the first communication protocol to the slave control device 5 times.
[0062] At this time, the step of determining the communication protocol type to be sent to the slave control device next according to the response result of the slave control device specifically includes:
[0063] S111. Determining the communication protocol type to be sent to the slave control device next according to the response result of the slave control device to the first communication protocol for the first preset number of times.
[0064] It can be understood that when the master control device repeatedly sends the first communication protocol to the slave control device according to the first preset number of times, if the slave control device can recognize and process the first communication protocol, it should correctly respond to the first communication protocol. The communication protocol type to be sent to the slave control device next can be determined according to the actual number of times the slave control device correctly responds to the first communication protocol for the first preset number of times.
[0065] In some embodiments, the step of determining the communication protocol type to be sent to the slave control device next according to the response result of the slave control device to the first communication protocol for the first preset number of times specifically includes:
[0066] S1111. Determining the first actual number of times the slave control device correctly responds to the first communication protocol.
[0067] It can be understood that when the slave control device receives the first communication protocol sent by the master control device, if it can understand and support this protocol, it will give a correct response. The response result may be to confirm receiving the protocol or indicate that subsequent data exchange can be carried out according to this protocol. The first actual number of times refers to the actual number of times the slave control device correctly responds to the first communication protocol, which may be different from the first preset number of times because the slave control device may not give a correct response in each attempt due to various reasons (such as network delay, device failure, etc.).
[0068] S1112. When a preset condition is satisfied between the first actual number of times and the first preset number of times, determine that the first communication protocol is the valid communication protocol type of the slave control device.
[0069] It can be understood that the preset condition refers to one or more pre-set judgment criteria. When the relationship between the first actual number of times and the first preset number of times conforms to these criteria, it can be considered that the condition is satisfied. For example, the preset condition is that the first actual number of times is equal to the first preset number of times, or the first actual number of times reaches a certain proportion of the first preset number of times, etc. In the embodiments of the present invention, the first preset number of times can be 5 times. At this time, when the first actual number of times is greater than or equal to 3 times, it can be considered that the preset condition is met.
[0070] In some embodiments, after the step of determining the first actual number of times when the slave control device correctly responds to the first communication protocol, it further includes:
[0071] S1113. When the preset condition is not satisfied between the first actual number of times and the first preset number of times, send the second communication protocol to the slave control device, determine the communication protocol type to be sent to the slave control device next according to the response result of the slave control device, and determine the valid communication protocol type of the slave control device.
[0072] It can be understood that when the preset condition is not satisfied between the first actual number of times and the first preset number of times, for example, the first actual number of times is not equal to the first preset number of times, or the first actual number of times does not reach a certain proportion of the first preset number of times. At this time, the first communication protocol has been excluded, and it is necessary to replace the second communication protocol to verify the valid communication protocol of the slave control device. The content of step S1113 is the same as that of steps S100 and S110, but the verification object has changed.
[0073] In some embodiments, the step of sending the second communication protocol to the slave control device, determining the communication protocol type to be sent to the slave control device next according to the response result of the slave control device, and determining the valid communication protocol type of the slave control device specifically includes:
[0074] S11131. Send the second communication protocol for the second preset number of times to the slave control device.
[0075] It can be understood that the master control device needs to repeatedly send the second communication protocol to the slave control device according to the second preset number of times. For example, continuously send the second communication protocol to the slave control device 5 times.
[0076] S11132. Determine the second actual number of times when the slave control device correctly responds to the second communication protocol.
[0077] It can be understood that when the secondary control device receives the second communication protocol sent by the primary control device, if it can understand and support this protocol, it will give a correct response. The response result may be to confirm the receipt of the protocol or indicate that subsequent data exchange can be carried out according to this protocol. The second actual number refers to the actual number of times the secondary control device correctly responds to the second communication protocol, which may be different from the second preset number because the secondary control device may fail to give a correct response in each attempt due to various reasons (such as network latency, device failure, etc.).
[0078] S11133. When a preset condition is met between the second actual number and the second preset number, determine that the second communication protocol is the valid communication protocol type of the secondary control device.
[0079] It can be understood that when the relationship between the second actual number and the second preset number meets the preset condition, for example, the preset condition is that the second actual number is equal to the second preset number, or the second actual number reaches a certain proportion of the second preset number, etc. In the embodiment of the present invention, the second preset number can be 5 times. When the second actual number is greater than or equal to 3 times, it can be considered that the preset condition is met. At this time, it can be confirmed that the second communication protocol is the valid communication protocol type of the secondary control device.
[0080] In some embodiments, after the step of determining the second actual number of times the secondary control device correctly responds to the second communication protocol, it further includes:
[0081] S11134. When the preset condition is not met between the second actual number and the second preset number, circularly send the first communication protocol and the second communication protocol to the secondary control device.
[0082] It can be understood that when the relationship between the second actual number and the second preset number does not meet the preset standard, for example, the second actual number is not equal to the second preset number, or the second actual number does not reach a certain proportion of the second preset number. At this time, the second communication protocol has been excluded, and other methods are needed to verify the valid communication protocol. The primary control device will continuously send the first communication protocol and the second communication protocol to the secondary control device in a certain order or at a certain time interval. Through this process, the primary control device can try different communication methods to establish an effective connection with the secondary control device and judge whether it is necessary to adjust the communication protocol according to the response of the secondary control device.
[0083] S11135. When the number of cycles is less than or equal to the third preset number, and the secondary control device correctly responds to either the first communication protocol or the second communication protocol, determine that the communication protocol type correctly responded by the secondary control device is the valid communication protocol.
[0084] It can be understood that the number of cycles refers to the total number of times the master control device sends the first communication protocol and the second communication protocol to the slave control device. When the number of cycles is greater than the third preset number, it can be considered that the cut-off point of the test has been reached. When the slave control device receives the first communication protocol or the second communication protocol sent by the master control device, if it can understand and support one of the communication protocols, it will give a correct response. By judging the response of the slave control device to the first communication protocol and the second communication protocol, it can be determined which communication protocol is effective. Through this process, the master control device can judge which protocol is suitable for subsequent data exchange according to the actual response of the slave control device to different communication protocols sent in a loop.
[0085] In some embodiments, after the step of cyclically sending the first communication protocol and the second communication protocol to the slave control device, it further includes:
[0086] S11136. When the number of cycles is greater than the third preset number and the slave control device fails to correctly respond to any one of the first communication protocol and the second communication protocol, a fault signal is generated.
[0087] It can be understood that when the number of cycles is greater than the third preset number, it can be considered that the cut-off point of the test has been reached. If at this time the slave control device still fails to correctly respond to any one of the first communication protocol and the second communication protocol, it can prove that there is a fault in one of the indoor unit and the outdoor unit. At this time, a fault signal is issued. Issuing a fault signal is to send a warning message to the operator, maintenance personnel or control system in a specific way, reminding the relevant personnel to pay attention to potential problems and take corresponding measures to solve or prevent the further deterioration of the problems.
[0088] According to the air conditioner controller communication protocol processing device provided by the second aspect embodiment of the present invention, please refer to Figure 2 , including:
[0089] A communication module 201, configured to send the first communication protocol to the slave control device in response to determining that initialization is completed, and receive the response result of the slave control device.
[0090] A receiving module 202, configured to determine the type of the communication protocol to be sent to the slave control device next according to the response result of the slave control device, and determine the effective communication protocol type of the slave control device; wherein, the communication protocol type includes the first communication protocol and the second communication protocol, and one of the first communication protocol and the second communication protocol is a new communication protocol, and the other is an old communication protocol.
[0091] A configuration module 203, configured to configure the communication protocol type with the slave control device as the above-mentioned effective communication protocol type.
[0092] It should be noted that the above steps S100 to S120, as well as other steps, are only for convenience of description and do not constitute a timing limitation on the steps in the air conditioner controller communication protocol processing method. Moreover, some content is described in detail in the air conditioner controller communication protocol processing method provided in the first aspect embodiment, and all the content in the air conditioner controller communication protocol processing method is also applicable to the air conditioner controller communication protocol processing device provided in the second aspect embodiment. Therefore, in order to avoid repetition, it is not described in detail in the air conditioner controller communication protocol processing device provided in the second aspect embodiment. Similarly, the content in the above two aspect embodiments can be used to explain the content of all subsequent aspect embodiments. Therefore, the repeated content is not described in the subsequent embodiments. According to the air conditioner controller communication protocol processing device provided by the embodiments of the present invention, its technical effects correspond to those of the above air conditioner controller communication protocol processing method, and will not be elaborated here.
[0093] According to the electronic device provided by the third aspect embodiment of the present invention, it includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, it implements the steps of the air conditioner controller communication protocol processing method provided by the first aspect embodiment of the present invention.
[0094] Figure 3 The schematic diagram of the entity structure of an electronic device is exemplified. The electronic device may include: a processor 810, a communication interface 820, a memory 830, and a communication bus 840. Among them, the processor 810, the communication interface 820, and the memory 830 complete mutual communication through the communication bus 840. The processor 810 can call the logical instructions in the memory 830 to execute the air conditioner controller communication protocol processing method, which includes: in response to determining that initialization is completed, sending a first communication protocol to the slave control device and receiving the response result of the slave control device; determining the next communication protocol type to be sent to the slave control device according to the response result of the slave control device, and determining the valid communication protocol type of the slave control device; where the communication protocol type includes a first communication protocol and a second communication protocol, and one of the first communication and the second communication protocol is a new communication protocol, and the other is an old communication protocol; configuring the communication protocol type with the slave control device as the above valid communication protocol type.
[0095] In addition, when the logical instructions in the above-mentioned memory 830 can be implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs that can store program codes.
[0096] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. A person of ordinary skill in the art can understand and implement it without creative labor.
[0097] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on such an understanding, the technical solution, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disc, etc., and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the methods described in various embodiments or some parts of the embodiments.
[0098] According to an embodiment of the fourth aspect of the present invention, a non-transitory computer-readable storage medium is further provided, on which a computer program is stored. When the computer program is executed by a processor, it is configured to execute the air conditioner controller communication protocol processing method provided above. The method includes: in response to determining that initialization is completed, sending a first communication protocol to a slave control device and receiving a response result from the slave control device; determining the next communication protocol type to be sent to the slave control device according to the response result of the slave control device, and determining the valid communication protocol type of the slave control device; wherein the communication protocol type includes a first communication protocol and a second communication protocol, and one of the first communication protocol and the second communication protocol is a new communication protocol and the other is an old communication protocol; configuring the communication protocol type with the slave control device as the above-mentioned valid communication protocol type.
[0099] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. A person of ordinary skill in the art can understand and implement it without creative labor.
[0100] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution, in essence, or the part that contributes to the prior art can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disc, etc., and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0101] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A method for processing an air conditioner controller communication protocol, characterized in that, Including: In response to determining that initialization is completed, send a first communication protocol to the slave control device and receive the response result of the slave control device; Determine the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device, and determine the valid communication protocol type of the slave control device; wherein, the types of communication protocols include a first communication protocol and a second communication protocol, and one of the first communication protocol and the second communication protocol is a new communication protocol and the other is an old communication protocol; Configure the communication protocol type with the slave control device as the above-mentioned valid communication protocol type.
2. The method for processing an air conditioner controller communication protocol according to claim 1, wherein The step of sending the first communication protocol to the slave control device includes: Send the first communication protocol to the slave control device for a first preset number of times; Then the step of determining the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device specifically includes: Determine the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device to the first communication protocol for the first preset number of times.
3. The method for processing an air conditioner controller communication protocol according to claim 2, wherein The step of determining the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device to the first communication protocol for the first preset number of times specifically includes: Determine the first actual number of times that the slave control device correctly responds to the first communication protocol; When the preset condition is satisfied between the first actual number of times and the first preset number of times, determine that the first communication protocol is the valid communication protocol type of the slave control device.
4. The air conditioner controller communication protocol processing method according to claim 3, wherein After the step of determining the first actual number of times that the slave control device correctly responds to the first communication protocol, it further includes: When the preset condition is not satisfied between the first actual number of times and the first preset number of times, send the second communication protocol to the slave control device, determine the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device, and determine the valid communication protocol type of the slave control device.
5. The method for processing the communication protocol of the air conditioner controller according to claim 4, wherein The step of sending the second communication protocol to the slave control device, determining the type of communication protocol to be sent to the slave control device next according to the response result of the slave control device, and determining the valid communication protocol type of the slave control device specifically includes: Send the second communication protocol to the slave control device for a second preset number of times; Determine the second actual number of times that the slave control device correctly responds to the second communication protocol; When the preset condition is satisfied between the second actual number of times and the second preset number of times, determine that the second communication protocol is the valid communication protocol type of the slave control device.
6. The method for processing an air conditioner controller communication protocol according to claim 5, characterized in that, After the step of determining the second actual number of times that the slave control device correctly responds to the second communication protocol, it further includes: When the preset condition is not satisfied between the second actual number of times and the second preset number of times, circularly send the first communication protocol and the second communication protocol to the slave control device; When the number of loops is less than or equal to a third preset number, and the slave control device correctly responds to one of the first communication protocol or the second communication protocol, it is determined that the communication protocol type correctly responded by the slave control device is the valid communication protocol.
7. The method for processing an air conditioner controller communication protocol according to claim 6, characterized in that, The step of cyclically sending the first communication protocol and the second communication protocol to the slave control device is followed by: When the number of loops is greater than the third preset number, and the slave control device fails to correctly respond to any of the first communication protocol and the second communication protocol, a fault signal is generated.
8. An air conditioner controller communication protocol processing device, characterized in that, It includes: A communication module, configured to send a first communication protocol to a slave control device and receive a response result of the slave control device in response to determining that initialization is completed; A receiving module, configured to determine the communication protocol type to be sent to the slave control device next according to the response result of the slave control device, and determine the valid communication protocol type of the slave control device; wherein, the communication protocol type includes a first communication protocol and a second communication protocol, and one of the first communication protocol and the second communication protocol is a new communication protocol and the other is an old communication protocol; A configuration module, configured to configure the communication protocol type with the slave control device as the above-mentioned valid communication protocol type.
9. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the air conditioner controller communication protocol processing method according to any one of claims 1 to 7.
10. A storage medium containing computer-executable instructions, characterized in that, The computer-executable instructions are used to execute the steps of the air conditioner controller communication protocol processing method according to any one of claims 1 to 7 when executed by a computer processor.