Air conditioner
By verifying the software version information in the memory when the air conditioner is powered on, and replacing it with a second software version information using a specific checksum calculation formula when failure occurs, the problem of inconsistent memory checksums in OTA without backup is solved, thereby improving the reliability of the air conditioner and the accuracy of OTA upgrades.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HISENSE (SHANDONG) AIR CONDITIONING CO LTD
- Filing Date
- 2024-12-18
- Publication Date
- 2026-06-19
AI Technical Summary
In OTA (Over-The-Air) software upgrades for air conditioners without backup, existing technologies cannot reliably store software version information without increasing costs, leading to inconsistencies in software checksums and affecting the reliability of the air conditioner.
When the air conditioner is powered on, the first software version information in the memory is retrieved and verified. If the verification fails, the second software version information is read from the first control module, verified based on a specific verification and calculation formula, and stored in the memory to replace the first software version information if successful.
Without increasing costs, ensuring the consistency of checksums in the memory improves the reliability of the air conditioner, prevents data corruption or tampering, and ensures the accuracy of OTA upgrades.
Smart Images

Figure CN122240156A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of air conditioning technology, and in particular to an air conditioner. Background Technology
[0002] With the continuous development of air conditioning technology, OTA (Over-The-Air) online upgrade technology has gradually become the mainstream method for air conditioning software upgrades. It can be mainly divided into two types: backup OTA and backupless OTA. While backup OTA is secure and reliable, it requires larger flash (non-volatile memory) storage space, increasing costs. Therefore, backupless OTA, due to its smaller flash requirement and lower cost, has gradually become the preferred solution for air conditioning manufacturers.
[0003] However, in OTA without backup, the storage of air conditioning software version information becomes a critical issue. Currently, the existing storage method is to store the version information in the flash memory of the user area (i.e., the area that stores the application program for air conditioning control logic and the area that stores user settings and historical operating data, mainly used for air conditioning control), and then read and write it into the flash memory of the boot area (i.e., the area that stores the startup code, which is responsible for initializing the hardware and loading the user application, mainly used for OTA control) when powered on. However, this method will change the contents of the flash memory, causing the checksum of the entire air conditioning software to change. This results in the checksum of the released software target code being inconsistent with the checksum after power-on, thus failing the factory inspection.
[0004] Therefore, how to reliably store air conditioning software version information without increasing costs, while ensuring software verification and consistency, has become a pressing issue that current backup-free OTA solutions need to address. Summary of the Invention
[0005] The present invention aims to solve at least one of the technical problems existing in the prior art.
[0006] Therefore, one objective of this invention is to provide an air conditioner that, upon power-on, acquires and verifies first software version information stored in memory. If verification fails, second software version information can be read from a first control module. A specific checksum calculation formula is determined based on the second software version information, and the second software version information is verified based on the checksum calculation formula. If verification succeeds, the second software version information can be stored in memory to replace the first software version information. This ensures the consistency of the checksum in memory without increasing costs, avoids the problem of checksum changes in memory caused by writing software version information, and thus improves the reliability of the air conditioner.
[0007] Therefore, a second objective of this invention is to provide a control method for an air conditioner.
[0008] To achieve the above objectives, a first aspect of the present invention provides an air conditioner, the air conditioner comprising: an air conditioner body; A refrigerant circulation loop is provided inside the air conditioner body to allow the refrigerant to circulate in a cooling loop consisting of a compressor, condenser, expansion valve, and evaporator. One of the condenser and the evaporator is an outdoor heat exchanger, and the other is an indoor heat exchanger. A memory for storing the first software version information of the air conditioner; The controller includes a first control module and a second control module, wherein the first control module stores the second software version information of the air conditioner, and the second control module is configured to: When the air conditioner is powered on, the first software version information is retrieved from the memory; Verify the first software version information; When it is determined that the first software version information verification fails, the second software version information is obtained from the first control module, wherein the second software version information includes a second software number, a second version serial number, and a second preset checksum; The second verification calculation formula is determined based on the second software version information; The second software version information is verified based on the second verification calculation formula; If the second software version information is successfully verified, the second software version information is stored in the memory to replace the first software version information.
[0009] According to an embodiment of the present invention, when the air conditioner is powered on, it can acquire and verify the first software version information stored in the memory. If the verification fails, it can read the second software version information from the first control module, determine a specific checksum calculation formula based on the second software version information, and verify the second software version information based on the checksum calculation formula. If the verification is successful, the second software version information can be stored in the memory to replace the first software version information. This ensures the consistency of the checksum in the memory without increasing costs, avoids the problem of checksum changes in the memory caused by writing software version information, and thus improves the reliability of the air conditioner.
[0010] In some embodiments, when determining the second verification formula based on the second software version information, the second control module is further configured to: determine the second cumulative sum based on the second software number and the second version number; and determine the second verification formula by subtracting the preset value from the second cumulative sum.
[0011] The above technical solution has the following beneficial effects: by accumulating and calculating, it is possible to accurately verify whether the second preset checksum in the second software version information is correct, so as to facilitate OTA upgrade based on the second software version information and improve the reliability of the air conditioner.
[0012] In some embodiments, when verifying the second software version information based on the second verification formula, the second control module is further configured to: determine a second checksum based on the second verification formula; determine whether the second checksum is consistent with the second preset checksum; if so, determine that the second software version information verification is successful; otherwise, determine that the second software version information verification fails.
[0013] The above technical solution has the following beneficial effects: by using the second verification formula to calculate the second checksum and comparing it with the second preset checksum, the integrity of the second software version information can be accurately verified, which helps to prevent the problem of inaccurate software version information caused by data corruption, transmission errors or malicious tampering.
[0014] In some embodiments, the second control module is further configured to: output a prompt message indicating an error in the version information when it is determined that the second software version information is invalid or that the verification of the second software version information fails, wherein the second software version information is determined to be invalid when the data frame of the second software version information is empty or is the maximum value.
[0015] The above technical solution has the following beneficial effects: when the second software version information is determined to be invalid or the second software version information verification fails, a prompt message indicating an error in the version information is output, which can quickly notify the user or administrator about the software version information problem, and help to quickly locate and resolve the software version error problem.
[0016] In some embodiments, when obtaining the first software version information, the second control module is configured to: obtain the first software number, the first version number, and the first preset checksum from the first software version information.
[0017] The above technical solution has the following beneficial effects: by extracting and parsing the first software number, the first version number and the first preset checksum in the first software version information, it is possible to verify whether the current software version information has changed, which can ensure the accuracy of OTA upgrades and thus improve the reliability of the air conditioner.
[0018] In some embodiments, when verifying the first software version information, the second control module is further configured to: determine a first verification formula based on the first software version information; and verify the first software version information based on the first verification formula.
[0019] The above technical solution has the following beneficial effects: by determining the first verification formula through the first software version information, the first verification formula can be used to accurately verify the first software version information, ensuring that its integrity is not compromised, and helping to prevent data damage or tampering during data transmission, storage or processing. In some embodiments, when determining the first verification formula based on the first software version information, the second control module is further configured to: determine a first cumulative sum based on the first software number and the first version number; and determine the first verification formula based on the first cumulative sum.
[0020] The above technical solution has the following beneficial effects: by using the first verification calculation formula to calculate the first checksum and comparing it with the first preset checksum, the integrity of the first software version information can be accurately verified, which helps to prevent the problem of inaccurate software version information caused by data corruption, transmission errors or malicious tampering.
[0021] In some embodiments, when verifying the first software version information based on the first verification formula, the second control module is configured to: determine a first checksum based on the first verification formula; determine whether the first checksum is consistent with the first preset checksum; if so, determine that the first software version information has been successfully verified; otherwise, re-acquire the first software version information and re-verify the re-acquired first software version information; if the number of consecutive failures in verifying the first software version information reaches a preset number, determine that the first software version information has failed to be verified.
[0022] The above technical solution has the following beneficial effects: by using a first verification formula to calculate a first checksum and comparing it with a first preset checksum, the integrity of the first software version information can be accurately verified, helping to prevent inaccurate software version information caused by data corruption, transmission errors, or malicious tampering. At the same time, setting up multiple re-acquisition and verification methods can improve the accuracy of the software version information, thereby improving the reliability of the air conditioner.
[0023] In some embodiments, after determining that the first software version information verification is successful or the second software version verification is successful, the second control module is configured to send the first software version information or the second software version information to the software upgrade server for backup.
[0024] The above technical solution has the following beneficial effects: by sending the successfully verified software version information to the software upgrade server for backup, the required software version information can be obtained from the backup during OTA upgrade, so that OTA can be upgraded stably.
[0025] In some embodiments, the second control module is further configured to: clear the first software version information or the second software version information from the software upgrade server when the air conditioner is powered off.
[0026] The above technical solution has the following beneficial effects: it ensures that the first software version information or the second software version information is only valid during the power-on to power-off process, thereby ensuring that no outdated software version information is left in the software upgrade server after the air conditioner is turned off or the power is cut off, thus avoiding loading incorrect or outdated information during the next upgrade.
[0027] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description
[0028] The above and / or additional aspects and advantages of the present invention will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which: Figure 1 This is a schematic diagram of the refrigeration cycle system of an air conditioner according to an embodiment of the present invention; Figure 2 This is a schematic diagram of the structure of an air conditioner according to an embodiment of the present invention; Figure 3 This is a schematic diagram of the controller according to an embodiment of the present invention; Figure 4 This is a schematic diagram of the structure of an air conditioner according to another embodiment of the present invention; Figure 5 This is a flowchart of an air conditioner control method according to an embodiment of the present invention; Figure 6 This is a flowchart illustrating the verification of second software version information based on a second verification calculation formula according to an embodiment of the present invention. Figure 7 This is a schematic flowchart illustrating the verification of first software version information based on a first verification calculation formula according to an embodiment of the present invention. Detailed Implementation
[0029] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0030] In the description of this invention, it should be understood that the terms "center", "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this invention.
[0031] The terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this invention, unless otherwise stated, "a plurality of" means two or more.
[0032] In the description of this invention, it should be noted that, unless otherwise explicitly specified and limited, the terms "installation," "connection," and "linking" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.
[0033] like Figure 1 As shown, in this invention, the air conditioner 1 performs a refrigeration cycle by using a compressor, a condenser, an evaporator, and a four-way valve. The refrigeration cycle includes a series of processes involving compression, condensation, and evaporation, and supplies refrigerant to the conditioned and heat-exchanged air.
[0034] The compressor compresses the refrigerant gas, which is in a high-temperature, high-pressure state and enters through the return pipe, and then discharges the compressed refrigerant gas through the exhaust pipe. The discharged refrigerant gas flows into the condenser through the condenser inlet pipe. The condenser condenses the compressed refrigerant into a liquid phase, and the heat is released to the surrounding environment through the condensation process.
[0035] The evaporator evaporates the refrigerant that expands in the expansion valve and returns the refrigerant gas, now at a low temperature and low pressure, to the compressor. The evaporator achieves its cooling effect by utilizing the latent heat of refrigerant evaporation to exchange heat with the material being cooled. Throughout the cycle, air conditioner 1 regulates the temperature of the indoor space.
[0036] Combination Figure 2 and Figure 4 As shown, the air conditioner 1 in this application includes an indoor fan 11 and an outdoor fan 12, which can be configured as an integrated unit or a split unit. The indoor fan 11 can be configured as a wall-mounted unit, a ceiling unit, a duct unit, etc., and the indoor fan 11 is installed on the top or ceiling of the room.
[0037] Taking indoor wall-mounted units as an example, indoor wall-mounted units are usually installed on indoor walls or other locations. For example, indoor cabinet units (not shown in the figure) are also a type of indoor fan 11.
[0038] Taking a split-type air conditioner as an example, the air conditioner 1 includes an indoor fan 11 and an outdoor fan 12. The outdoor fan 12 is usually installed outdoors and is used for heat exchange in the indoor environment.
[0039] Furthermore, the air conditioner 1 includes a controller 71 to control the operation of various components within the air conditioner 1, enabling each component to perform its predetermined functions. The air conditioner 1 also includes a control device 200, which, exemplarily, is a remote control. This remote control has the capability to communicate with the controller 71, for example, using infrared or other communication methods. The remote control allows the user to perform various controls on the air conditioner 1, enabling interaction between the user and the air conditioner 1.
[0040] In this embodiment of the application, the indoor fan 11 of the air conditioner 1 is located at the top or upper part of the room. Generally, the installation height of the indoor fan 11 is higher than the user's activity area. The indoor fan 11 includes a return air vent 17 and an air outlet 16 that communicate with the room. Indoor air passes through the indoor fan 11 in the return air vent 17 and flows back into the room through the air outlet 16.
[0041] An air guide plate 2 is installed at the air outlet 16. By changing its relative rotation angle with the air outlet 16, the air guide plate 2 adjusts the outflow direction of the air flowing through the air outlet 12, thereby affecting the stratification of indoor air temperature.
[0042] This application embodiment also provides a hardware structure diagram of the controller 71, such as... Figure 3 As shown, the controller 71 includes a processor 83, and optionally, a memory 82 and a communication interface 84 connected to the processor 83. The processor 83, memory 82, and communication interface 84 are connected via a bus 81.
[0043] Processor 83 can be a central processing unit (CPU), a general-purpose processor (NP), a network processor (NP), a digital signal processor (DSP), a microprocessor (Microcontroller), a programmable logic device (PLD), or any combination thereof. Processor 83 can also be any other device with processing capabilities, such as a circuit, device, or software module. Processor 83 can also include multiple CPUs, and processor 83 can be a single-core (single-CPU) processor or a multi-core (multi-CPU) processor. Here, processor 83 can refer to one or more devices, circuits, or processing cores used for processing data (e.g., computer programs).
[0044] The memory 82 can be a read-only memory (ROM) or other types of static storage devices capable of storing static information, a random access memory (RAM) or other types of dynamic storage devices capable of storing information, or an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital universal optical discs, Blu-ray discs, etc.), a magnetic disk storage medium or other magnetic storage devices, or any other medium capable of carrying or storing desired program code in the form of a data structure and accessible by a computer. This application embodiment does not impose any limitations on this. The memory 82 can exist independently or be integrated with the processor 83. The memory 82 may contain computer program code. The processor 83 is used to execute the computer program code stored in the memory 82, thereby implementing the control method of the air conditioner 1 provided in this application embodiment.
[0045] The communication interface 84 can be used to communicate with other devices or communication networks (such as Ethernet, radio access network (RAN), wireless local area networks (WLAN), etc.). The communication interface 84 can be a module, circuit, transceiver, or any device capable of communication.
[0046] Bus 81 can be a peripheral component interconnect (PCI) bus 81 or an extended industry standard architecture (EISA) bus 81, etc. Bus 81 can be divided into address bus 81, data bus 81, control bus 81, etc.
[0047] The following is combined Figures 4-7 An air conditioner 1 and its control method according to an embodiment of the present invention are described.
[0048] In some embodiments, such as Figure 4 As shown, the air conditioner 1 includes: an air conditioner body 10.
[0049] In some embodiments, such as Figure 4 As shown, the air conditioner 1 may include: a refrigerant circulation loop 13, which allows the refrigerant to circulate in a loop consisting of a compressor, condenser, expansion valve, and evaporator. One of the condenser and the evaporator is an outdoor heat exchanger and the other is an indoor heat exchanger.
[0050] In some embodiments, such as Figure 4 As shown, the air conditioner 1 may include: a memory 14 for storing the first software version information of the air conditioner.
[0051] In some embodiments, such as Figure 4 As shown, the air conditioner 1 may include: a controller 71, the controller 71 includes a first control module and a second control module, wherein the first control module stores the second software version information of the air conditioner 1, and the second control module is configured to: retrieve the first software version information from the memory 14 when the air conditioner 1 is powered on; and verify the first software version information; When the verification of the first software version information fails, the second software version information is obtained from the first control module. The second software version information includes the second software number, the second version serial number, and the second preset checksum. The second verification calculation formula is determined based on the second software version information; The second software version information is verified based on the second verification calculation formula; If the second software version information is successfully verified, the second software version information is stored in the memory 14 to replace the first software version information.
[0052] Specifically, when the air conditioner 1 is powered on, the second control module can access the memory 14 connected to the controller 71, including but not limited to an EEPROM (Electrically Erasable Programmable Read-Only Memory 14), and read the first software version information stored at a specific address in the memory 14. Furthermore, the memory 14 can respond to the access request from the second control module by transmitting the first software version information back to the second control module, so that the second control module can verify the first software version information. Verification methods include, but are not limited to, adding the bytes of the first software version information and comparing it with a pre-stored checksum value, determining whether the verification was successful based on the comparison result.
[0053] Furthermore, when it is determined that the first software version information verification fails, it indicates that the first software version information is incomplete or has been tampered with, that is, the air conditioner 1 cannot rely on the currently stored first software version information to perform OTA upgrade. At this time, the second software version information can be obtained from the first control module. The second software version information includes a name number (second software number) representing the second software version information, a unique number of the software (second version serial number), and a preset checksum (second preset checksum) associated with the second software version information.
[0054] Furthermore, a second verification formula can be determined based on the second software version information, including but not limited to adding the bytes included in the second software version information and combining them with a preset algorithm to determine the second verification formula. Furthermore, the second software version information can be verified based on the second verification formula, including but not limited to recalculating the checksum based on the second verification formula and the read second software version information, comparing it with the pre-stored checksum value, and determining whether the verification was successful based on the comparison result.
[0055] Furthermore, when the verification of the second software version information is successful, it indicates that the checksum obtained according to the second verification formula is consistent with the second preset checksum. Therefore, the second software version information can be stored in the memory 14 to replace the first software version information. It is understood that since the checksum calculation in the memory 14 uses an additive summation method, when the second software version information is successfully verified according to a specific formula and stored in the memory 14, the specific second verification formula can cancel out the additive summation of each byte in the second software version information, thereby ensuring the consistency of the checksum in the memory 14 and avoiding the problem of checksum changes in the memory 14 due to the writing of the second software version information, thus improving the reliability of the air conditioner 1.
[0056] According to an embodiment of the present invention, when the air conditioner 1 is powered on, it can obtain the first software version information in the memory 14 and verify it. If the verification fails, it can read the second software version information from the first control module, determine a specific checksum calculation formula based on the second software version information, and verify the second software version information based on the checksum calculation formula. If the verification is successful, the second software version information can be stored in the memory 14 to replace the first software version information. This ensures the consistency of the checksum in the memory 14 without increasing costs, avoids the problem of checksum changes in the memory 14 due to writing software version information, and thus improves the reliability of the air conditioner 1. In one embodiment of the present invention, when determining the second verification calculation formula based on the second software version information, the second control module is further configured to: determine the second cumulative sum based on the second software number and the second version number; The difference between the preset value and the second sum is used to determine the second verification formula.
[0057] Specifically, the second software version information stored in the first control module is usually a 10-bit data frame, in which seven bits represent the second software number and two bits represent the second version sequence number. When determining the second verification formula based on the second software version information, the bytes representing the second software number and the second version sequence number can be accumulated and the lower eight bits can be taken to determine the second accumulated sum.
[0058] Furthermore, a preset value can be set according to the actual situation and experimental data, and the preset value and the second cumulative sum can be subtracted from the preset value. For example, if the preset value is 0xFF, the second verification calculation formula is: 0xFF - second cumulative sum.
[0059] In one embodiment of the present invention, when verifying the second software version information based on the second verification formula, the second control module is further configured to: determine the second checksum based on the second verification formula; and determine whether the second checksum is consistent with the second preset checksum. If yes, the verification of the second software version information is successful; otherwise, the verification of the second software version information is unsuccessful.
[0060] Specifically, when verifying the second software version information based on the second verification formula, a second checksum can be determined based on the second verification formula, including but not limited to using the difference between a preset value and the second accumulated sum as the second checksum. Furthermore, the second checksum can be compared with an obtained second preset checksum, i.e., it can be determined whether the second checksum and the second preset checksum are consistent, so as to determine whether the verification was successful based on the comparison result.
[0061] Furthermore, if the second checksum matches the second preset checksum, it indicates that the second software version information is complete or has not been tampered with, and the second software version information verification is successful; if the second checksum does not match the second preset checksum, it indicates that the second software version information is incomplete or has been tampered with, and the second software version information verification fails.
[0062] In one embodiment of the present invention, the second control module is further configured to: output a prompt message indicating that the version information is invalid when it is determined that the second software version information is invalid or that the verification of the second software version information fails, wherein the second software version information is determined to be invalid when the data frame of the second software version information is empty or is the maximum value.
[0063] Specifically, after the second control module obtains the second software version information, it can determine whether the second software version information is valid. Specifically, if the data frame of the second software version information is empty (i.e., there is no data) or the data frame of the second software version information has the maximum value (i.e., all bytes in the second software version information have the maximum value), then the second software version information is invalid; otherwise, the second software version information is valid. Furthermore, when the second software version information is invalid, an error message can be output. When the second software version information is valid, it can be validated. If the validation fails, an error message can also be output.
[0064] In a specific embodiment, the prompt information may be a corresponding icon or message displayed on the display unit of the air conditioner 1. For example, it may display text information such as "OTA upgrade failed" or "version information error", or it may be a voice message reminding the user of an error.
[0065] In one embodiment of the present invention, when obtaining the first software version information, the second control module is configured to: obtain the first software number, the first version serial number and the first preset checksum from the first software version information.
[0066] Specifically, when obtaining the first software version information, the first software number, the first version serial number, and the first preset checksum can be obtained from the first software version information. The first software number represents the name number of the first software version information, the second version serial number represents the number of the first software version information, and the second preset checksum is a preset check value associated with the second software version information, used to verify whether the first software version information has been tampered with or is complete.
[0067] In one embodiment of the present invention, when verifying the first software version information, the second control module is further configured to: determine a first verification calculation formula based on the first software version information; The first software version information is verified based on the first verification formula.
[0068] Specifically, when verifying the first software version information, a first verification formula can be determined based on the first software version information, including but not limited to adding up each byte included in the first software version information and combining it with a preset algorithm to determine the first verification formula. Furthermore, the first software version information can be verified based on the first verification formula, including but not limited to recalculating the checksum based on the first verification formula and the read first software version information, comparing it with the pre-stored checksum value, and determining whether the verification was successful based on the comparison result.
[0069] In one embodiment of the present invention, when determining the first verification calculation formula based on the first software version information, the second control module is further configured to: determine the first cumulative sum based on the first software number and the first version number; The first verification calculation formula is determined based on the first cumulative sum.
[0070] Specifically, since the first software version information is usually a 10-bit data frame, where seven bits represent the first software number and two bits represent the first version sequence number, when determining the first check calculation formula based on the first software version information, the bytes representing the first software number and the first version sequence number can be accumulated and the lower eight bits can be taken to determine the first accumulated sum.
[0071] Furthermore, preset values can be set according to time conditions and experimental data, and the difference between the preset value and the first accumulated sum can be calculated, that is, the first accumulated sum is subtracted from the preset value. For example, if the preset value is 0xFF, then the first verification calculation formula is: 0xFF - first accumulated sum.
[0072] In one embodiment of the present invention, when verifying the first software version information based on the first verification formula, the second control module is configured to: determine the first checksum based on the first verification formula; Determine whether the first checksum is consistent with the first preset checksum; If yes, the first software version information verification is successful; otherwise, the first software version information is retrieved again and re-verified. If the number of consecutive failures to verify the first software version information reaches a preset number, then the verification of the first software version information is determined to have failed.
[0073] Specifically, when verifying the first software version information based on the first verification formula, a first checksum can be determined based on the first verification formula, including but not limited to using the difference between a preset value and a first accumulated sum as the first checksum. Furthermore, the first checksum can be compared with an acquired first preset checksum, i.e., it can be determined whether the first checksum and the first preset checksum are consistent, so as to determine whether the verification was successful based on the comparison result.
[0074] Furthermore, if the first checksum matches the first preset checksum, it indicates that the first software version information is complete or has not been tampered with, and the first software version information verification can be confirmed as successful. If the first checksum does not match the first preset checksum, it indicates that the first software version information may be incomplete or may have been tampered with. In this case, the first software version information can be re-acquired and re-verified, that is, the first checksum can be recalculated, and it can be determined whether the recalculated checksum matches the re-acquired first preset checksum to determine whether the verification is successful.
[0075] Furthermore, if the number of consecutive failures to verify the first software version information reaches a preset number, it can be determined that the verification of the second software version information has failed. The preset number can be set according to the actual situation and experimental theory, including but not limited to 3 times.
[0076] In one embodiment of the present invention, after determining that the first software version information verification is successful or the second software version verification is successful, the second control module is configured to send the first software version information or the second software version information to the software upgrade server for backup.
[0077] Specifically, when the verification of the first software version information is successful, that is, when the first checksum obtained based on the first verification formula is consistent with the first preset checksum, it indicates that the first software version information is complete and has not been tampered with. At this time, the first software version information can be sent to the software upgrade server for backup, so that the software upgrade server can upgrade based on the first software version information. Similarly, when the verification of the second software version is successful, that is, when the second checksum obtained based on the second verification formula is consistent with the second preset checksum, it indicates that the second software version information is complete and has not been tampered with. At this time, the second software version information can be sent to the software upgrade server for backup, so that the software upgrade server can upgrade based on the second software version information.
[0078] In one embodiment of the present invention, the second control module is further configured to: clear the first software version information or the second software version information from the software upgrade server when the air conditioner 1 is powered off.
[0079] Specifically, when the second control module detects that the air conditioner 1 is powered off (e.g., the user turns off the power or disconnects the power) through the built-in power monitoring circuit, it can clear the first software version information or the second software version information from the software upgrade server. That is, the first software version information or the second software version information is only valid during the period from the current power-on to the power-off of the air conditioner 1, thereby ensuring that no outdated software version information is left in the software upgrade server after the air conditioner 1 is turned off or disconnected from the power, thus avoiding loading incorrect or outdated information during the next upgrade.
[0080] According to an embodiment of the present invention, when the air conditioner 1 is powered on, it can obtain the first software version information in the memory 14 and verify it. If the verification fails, it can read the second software version information from the first control module, determine a specific checksum calculation formula based on the second software version information, and verify the second software version information based on the checksum calculation formula. If the verification is successful, the second software version information can be stored in the memory 14 to replace the first software version information. This ensures the consistency of the checksum in the memory 14 without increasing costs, avoids the problem of checksum changes in the memory 14 due to writing software version information, and thus improves the reliability of the air conditioner 1.
[0081] The following is for reference. Figure 5 This invention describes a control method for an air conditioner according to an embodiment of the present invention.
[0082] like Figure 5 As shown, the air conditioner control method of this embodiment includes at least steps S1-S3.
[0083] Step S1: When the air conditioner is powered on, retrieve the first software version information from the memory.
[0084] Step S2: Verify the first software version information.
[0085] Step S3: When it is determined that the first software version information verification fails, the second software version information is obtained from the first control module. The second software version information includes the second software number, the second version number, and the second preset checksum.
[0086] Step S4: Determine the second verification calculation formula based on the second software version information.
[0087] Step S5: Verify the second software version information based on the second verification calculation formula.
[0088] Step S6: If the second software version information is successfully verified, the second software version information is stored in the memory to replace the first software version information.
[0089] In some embodiments, determining the second verification formula based on the second software version information specifically includes: determining the second summation based on the second software number and the second version number; and subtracting the preset value and the second summation to determine the second verification formula.
[0090] In some embodiments, combined with Figure 6 As shown, when verifying the second software version information based on the second verification formula, the specific steps include: determining the second checksum based on the second verification formula; determining whether the second checksum is consistent with the second preset checksum; if so, determining that the second software version information verification is successful; otherwise, determining that the second software version information verification fails.
[0091] In some embodiments, the control method for the air conditioner further includes: when it is determined that the second software version information is invalid or when it is determined that the second software version information verification fails, outputting a prompt message indicating that the version information is incorrect, wherein the second software version information is determined to be invalid when the data frame of the second software version information is empty or is the maximum value.
[0092] In some embodiments, obtaining the first software version information specifically includes: obtaining the first software number, the first version number, and the first preset checksum from the first software version information.
[0093] In some embodiments, verifying the first software version information specifically includes: determining a first verification formula based on the first software version information; and verifying the first software version information based on the first verification formula.
[0094] In some embodiments, determining the first verification formula based on the first software version information specifically includes: determining a first cumulative sum based on the first software number and the first version number; and determining the first verification formula based on the first cumulative sum.
[0095] In some embodiments, combined with Figure 7 As shown, when verifying the first software version information based on the first verification formula, the specific steps include: determining the first checksum based on the first verification formula; determining whether the first checksum is consistent with the first preset checksum; if so, determining that the first software version information has been successfully verified; otherwise, re-acquiring the first software version information and re-verifying the re-acquiring first software version information; if the number of consecutive failures in verifying the first software version information reaches a preset number, determining that the first software version information has failed to be verified.
[0096] In some embodiments, after determining that the first software version information verification is successful or the second software version verification is successful, the method further includes: sending the first software version information or the second software version information to a software upgrade server for backup. In some embodiments, the control method for the air conditioner further includes: clearing the first software version information or the second software version information from the software upgrade server when the air conditioner is powered off.
[0097] It should be noted that the specific implementation method of controlling the air conditioner is similar to that of the air conditioner in any of the above embodiments of the present invention. Therefore, for a detailed exemplary description of the control process of the air conditioner, please refer to the relevant description of the air conditioner mentioned above. To reduce redundancy, it will not be repeated here.
[0098] According to the air conditioner control method of the present invention, when the air conditioner is powered on, the first software version information in the memory can be obtained and verified. If the verification fails, the second software version information can be read from the first control module, and a specific checksum calculation formula can be determined based on the second software version information. The second software version information can be verified based on the checksum calculation formula. If the verification is successful, the second software version information can be stored in the memory to replace the first software version information. This ensures the consistency of the checksum in the memory without increasing costs, avoids the problem of checksum changes in the memory caused by writing software version information, and thus improves the reliability of the air conditioner.
[0099] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "illustrative embodiment," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of the present invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example.
[0100] Although embodiments of the invention have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.
Claims
1. An air conditioner characterized by comprising: include: Air conditioner body; A refrigerant circulation loop is provided inside the air conditioner body to allow the refrigerant to circulate in a cooling loop consisting of a compressor, condenser, expansion valve, and evaporator. One of the condenser and the evaporator is an outdoor heat exchanger, and the other is an indoor heat exchanger. A memory for storing the first software version information of the air conditioner; The controller includes a first control module and a second control module, wherein the first control module stores the second software version information of the air conditioner, and the second control module is configured to: When the air conditioner is powered on, the first software version information is retrieved from the memory; Verify the first software version information; When it is determined that the first software version information verification fails, the second software version information is obtained from the first control module, wherein the second software version information includes a second software number, a second version serial number, and a second preset checksum; The second verification calculation formula is determined based on the second software version information; The second software version information is verified based on the second verification calculation formula; If the second software version information is successfully verified, the second software version information is stored in the memory to replace the first software version information.
2. The air conditioner of claim 1, wherein When determining the second verification formula based on the second software version information, the second control module is also configured to: The second cumulative sum is determined based on the second software number and the second version number; The difference between the preset value and the second sum is used to determine the second verification formula.
3. The air conditioner of claim 2, wherein When verifying the second software version information based on the second verification formula, the second control module is also configured to: The second checksum is determined based on the second check calculation formula; Determine whether the second checksum is consistent with the second preset checksum; If yes, then the verification of the second software version information is successful; otherwise, the verification of the second software version information is unsuccessful.
4. The air conditioner of claim 3, wherein The second control module is also configured as follows: When it is determined that the second software version information is invalid or that the verification of the second software version information fails, an error message indicating that the version information is invalid is output. Specifically, when the data frame of the second software version information is empty or is the maximum value, the second software version information is determined to be invalid.
5. The air conditioner of claim 1, wherein When acquiring the first software version information, the second control module is configured as follows: Obtain the first software number, the first version number, and the first preset checksum from the first software version information.
6. The air conditioner of claim 5, wherein When verifying the first software version information, the second control module is also configured to: The first verification calculation formula is determined based on the first software version information; The first software version information is verified based on the first verification calculation formula.
7. The air conditioner of claim 6, wherein When determining the first verification formula based on the first software version information, the second control module is further configured to: The first cumulative sum is determined based on the first software number and the first version number; The first verification calculation formula is determined based on the first cumulative sum.
8. The air conditioner of claim 7, wherein When verifying the first software version information based on the first verification formula, the second control module is configured as follows: The first checksum is determined based on the first checksum calculation formula; Determine whether the first checksum is consistent with the first preset checksum; If yes, then the first software version information verification is successful; otherwise, the first software version information is retrieved again and re-verified. If the number of consecutive failures to verify the first software version information reaches a preset number, then the verification of the first software version information is determined to have failed.
9. The air conditioner of claim 7, wherein After confirming that either the first software version information verification or the second software version verification is successful, the second control module is configured as follows: The first software version information or the second software version information is sent to the software upgrade server for backup.
10. The air conditioner of claim 1, wherein The second control module is also configured as follows: When the air conditioner is powered off, the first software version information or the second software version information is cleared from the software upgrade server.