Program upgrading verification method, system and equipment based on single-chip microcomputer and storage medium

By performing byte-byte XOR table-checking operation and comparison verification of the lower upgrade package in the microcontroller upper computer, and combining the real-time software information of the lower computer to match and upgrade the software, the problem of inefficient upgrade verification of microcontroller programs in the existing technology is solved, and a more efficient and safe software upgrade process is achieved.

CN120086061APending Publication Date: 2025-06-03SHENZHEN COMEN MEDICAL INSTR
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411982432.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-26
Publication Date
2025-06-03

AI Technical Summary

Technical Problem

The existing microcontroller program upgrade verification method is relatively inefficient and is easily affected by artificial modification of package names and iterative versions, resulting in inefficient verification.

Method used

The upper computer is used to perform byte-byte XOR table-check operation on the lower upgrade package to obtain the check table check value, and the standard upgrade package is obtained through the comparison checksum and de-check operation. The lower computer then uses real-time software information to match and upgrade software.

Benefits of technology

It improves the efficiency and security of program upgrade verification, reduces the upgrade failure caused by artificially wrongly modifying package names, and enhances the security and stability of the software.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120086061A_ABST
    Figure CN120086061A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of software checking and upgrading, and discloses a program upgrading and checking method, system and device based on a single chip microcomputer and a storage medium. The method comprises the steps that a lower upgrading package is obtained from a USB flash disk through an upper computer, the lower upgrading package is subjected to byte-by-byte XOR table look-up operation through the upper computer, and a table look-up checking value is obtained; the upper computer is used for comparing and checking the lower upgrade package according to the table look-up check value to obtain a check result, the upper computer is used for carrying out check removal operation on the lower upgrade package according to the check result to obtain a standard upgrade package, and the upper computer is used for sending the standard upgrade package to the lower computer. And performing software matching on the standard upgrade package by utilizing the lower computer according to preset real-time software information to obtain a matching result, and performing software upgrade by utilizing the lower computer according to the matching result and the standard upgrade package. By performing XOR table look-up verification on the lower upgrade package and performing upgrade matching according to the software information, the efficiency of single-chip microcomputer program upgrade verification can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technology in the field of software verification and upgrade, and particularly to a program upgrade verification method, system, device and storage medium based on a single-chip microcomputer. Background Art

[0002] Single-chip microcomputer devices have become an indispensable part of our daily life and work. New functional requirements or potential safety hazards brought about by product use need to be solved through program upgrade. However, the lower computer in a general single-chip microcomputer cannot identify whether the upgrade package is matched, which may lead to the situation of upgrade failure. Therefore, it is necessary to perform single-chip microcomputer program upgrade verification.

[0003] The existing single-chip microcomputer program upgrade verification methods are mostly based on simple package name verification methods, that is, the upper computer reads the names of upgrade packages one by one from storage media such as USB flash drives, and when the names of the upgrade packages match, it transmits them to the lower computer for upgrade. In actual use, there is a situation where the package name is manually modified resulting in incorrect software matching, and after more iterative versions, it is necessary to modify the package name matching program every time, which may lead to low efficiency of single-chip microcomputer program upgrade verification. Summary of the Invention

[0004] The present invention provides a program upgrade verification method, system, device and storage medium based on a single-chip microcomputer, and its main purpose is to solve the problem of low efficiency of single-chip microcomputer program upgrade verification.

[0005] A program upgrade verification method based on a single-chip microcomputer provided by the present invention includes: the upper computer obtains a lower upgrade package from a preset USB flash drive, and performs byte-by-byte exclusive OR look-up table operation on the lower upgrade package to obtain a look-up table verification value; the upper computer performs comparison verification on the lower upgrade package according to the look-up table verification value to obtain a verification result; the upper computer performs de-verification operation on the lower upgrade package according to the verification result to obtain a standard upgrade package; the upper computer sends the standard upgrade package to the lower computer; the lower computer receives the standard upgrade package; the lower computer uses pre-generated real-time software information to perform software matching on the standard upgrade package to obtain a matching result; the lower computer performs software upgrade on the standard upgrade package according to the matching result.

[0006] The present invention also provides a program upgrade verification system based on a single-chip microcomputer, including a host computer and a slave computer; the host computer is configured to: obtain a slave upgrade package from a preset USB flash drive, perform a byte-by-byte exclusive OR look-up table operation on the slave upgrade package to obtain a look-up table verification value; perform a comparison verification on the slave upgrade package according to the look-up table verification value to obtain a verification result; perform a division verification operation on the slave upgrade package according to the verification result to obtain a standard upgrade package; send the standard upgrade package to the slave computer; the slave computer is configured to: receive the standard upgrade package; perform software matching on the standard upgrade package by using pre-generated real-time software information to obtain a matching result; perform software upgrade on the standard upgrade package according to the matching result.

[0007] The present invention also provides an electronic device, which includes at least one processor; and a memory communicatively connected to the at least one processor; wherein, the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the above-mentioned program upgrade verification method based on a single-chip microcomputer.

[0008] The present invention also provides a computer-readable storage medium, in which at least one computer program is stored, and the at least one computer program is executed to implement the above-mentioned program upgrade verification method based on a single-chip microcomputer.

[0009] In the embodiment of the present invention, by performing a byte-by-byte exclusive OR look-up table operation on the slave upgrade package, the preliminary verification of the software content in the slave upgrade package can be realized by using the byte-by-byte exclusive OR operation method, and the secondary verification can be realized by using the look-up table verification method, which improves the verification efficiency and the security of the software package upgrade. It can be judged whether the slave upgrade package has been modified before the upgrade, thus further ensuring software security, preventing the situation that the upgrade cannot be performed due to the external accidental modification of the upgrade package name, enhancing the software security, and the host computer can also stably ensure the upgrade of the upgrade package corresponding to the model. By performing software upgrade according to the matching result and the standard upgrade package, the corresponding upgrade matching of the slave computer can be realized, reducing the verification time for matching by software name and improving the upgrade efficiency. Therefore, the program upgrade verification method, system, device and storage medium based on a single-chip microcomputer proposed by the present invention can improve the efficiency of performing the single-chip microcomputer program upgrade verification. Description of the Drawings

[0010] Figure 1 It is a signaling diagram of the program upgrade verification method based on a single-chip microcomputer provided by an embodiment of the present invention;

[0011] Figure 2 It is a flowchart of the program upgrade verification method based on a single-chip microcomputer provided by an embodiment of the present invention;

[0012] Figure 3Schematic diagram of the program upgrade verification system based on a single-chip microcomputer provided by an embodiment of the present invention.

[0013] The realization of the purpose of the present invention, functional features and advantages will be further described in conjunction with the embodiments with reference to the accompanying drawings. Specific embodiments

[0014] It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0015] To solve the efficiency problem existing in the program upgrade verification method based on a single-chip microcomputer provided in the prior art, an embodiment of the present invention provides a program upgrade verification method based on a single-chip microcomputer.

[0016] As Figure 1 shown, it is a signaling interaction diagram of the program upgrade verification method based on a single-chip microcomputer provided by an embodiment of the present invention.

[0017] The host computer is used to obtain the lower-level upgrade package from the USB flash drive, perform byte-by-byte exclusive OR look-up table operation on the lower-level upgrade package to obtain the look-up table verification value, use the host computer to perform comparison verification on the lower-level upgrade package according to the look-up table verification value to obtain the verification result, use the host computer to perform de-verification operation on the lower-level upgrade package according to the verification result to obtain the standard upgrade package, use the host computer to send the standard upgrade package to the lower-level machine, use the lower-level machine to perform software matching on the standard upgrade package according to the preset real-time software information to obtain the matching result, and use the lower-level machine to perform software upgrade according to the matching result and the standard upgrade package.

[0018] Referring to Figure 2 shown, it is a flowchart of the program upgrade verification method based on a single-chip microcomputer provided by an embodiment of the present invention. In this embodiment, the following specific processes are included:

[0019] S21. The host computer obtains the lower-level upgrade package from a preset USB flash drive and performs byte-by-byte exclusive OR look-up table operation on the lower-level upgrade package to obtain the look-up table verification value.

[0020] Specifically, the USB flash drive refers to a USB flash drive, a flash drive or a USB drive, which is a portable storage device, usually used for storing, transmitting and backing up data. The lower-level upgrade package for upgrading the lower-level machine is stored in the USB flash drive. The lower-level upgrade package refers to a pre-compiled software upgrade installation package for the lower-level machine, including an upgrade verification code, multiple upgrade softwares and software information corresponding to the multiple upgrade softwares. The upgrade verification code is the look-up table verification value of the lower-level upgrade package calculated in advance. The upgrade software is the software used for upgrading. The software information includes information such as the time, model and version number of the corresponding upgrade software.

[0021] In an embodiment of the present invention, a byte-by-byte exclusive OR look-up table operation is performed on the lower-level upgrade package to obtain a look-up table check value, including: performing a check operation on the lower-level upgrade package to obtain a standard upgrade package; performing byte binary conversion on the standard upgrade package to obtain software byte data; byte-by-byte selecting byte data in the software byte data as target byte data, performing an exclusive OR look-up table operation on the target byte data using a preset register check code to obtain an exclusive OR check code; using the exclusive OR check code to update the register check code, and returning to the step of byte-by-byte selecting byte data in the software byte data as target byte data until the target byte data is the last byte data in the software byte data, and taking the exclusive OR check code as the look-up table check value.

[0022] Specifically, the check operation refers to extracting the data content in the lower-level upgrade package except for the upgrade check code, that is, the standard upgrade package. The standard upgrade package includes multiple upgrade softwares and corresponding software information for each. The byte binary conversion refers to converting the standard upgrade package into binary data and performing byte sorting.

[0023] In detail, performing an exclusive OR look-up table operation on the target byte data using a preset register check code to obtain an exclusive OR check code includes: performing a low-byte exclusive OR operation on the target byte data using the preset register check code to obtain an exclusive OR byte code; performing a check look-up on the exclusive OR byte code to obtain a look-up table byte code; performing a byte cyclic right shift operation on the register check code to obtain a right shift check code; performing a low-byte exclusive OR operation on the right shift check code using the look-up table byte code to obtain an exclusive OR check code.

[0024] Specifically, the target byte data is eight-bit binary data in the software byte data. The low-byte exclusive OR operation refers to performing an exclusive OR operation on the target byte data using the low eight-bit data in the register check code.

[0025] In detail, the register check code is a preset 32-bit check code. The check look-up refers to selecting an eight-bit byte code corresponding to the exclusive OR byte from a preset check table as the look-up table byte code. The check table is a table containing 256 corresponding eight-bit byte codes. The cyclic right shift refers to shifting a data to the right in binary form, and the overflow bit will "cycle" from the rightmost to the leftmost.

[0026] In an embodiment of the present invention, by performing a byte-by-byte exclusive OR look-up table operation on the lower-level upgrade package, the preliminary check of the software content in the lower-level upgrade package can be realized by the method of byte-by-byte exclusive OR operation, and the secondary check can be realized by the method of look-up table check, reducing the check duration, improving the check efficiency, and improving the security of software package upgrade.

[0027] S22. The host computer performs a comparison check on the lower-level upgrade package according to the look-up table check value to obtain a check result.

[0028] Specifically, the verification result includes verification success and verification failure. Verification success indicates that the content of the lower-level upgrade package has not been modified and can be upgraded. Verification failure indicates that the content of the lower-level upgrade package has been modified, which may pose a security risk.

[0029] In the embodiment of the present invention, the host computer performs a comparison verification on the lower-level upgrade package according to the look-up table verification value to obtain a verification result, including: the host computer extracts the upgrade verification code from the lower-level upgrade package; determines whether the look-up table verification value is the same as the upgrade verification code; if so, it is determined that the verification is successful; if not, it is determined that the verification fails.

[0030] Specifically, the upgrade verification code refers to the verification value obtained by performing a byte-by-byte exclusive OR look-up table operation on each software in the lower-level upgrade package and the software information corresponding to the software before packaging.

[0031] In the embodiment of the present invention, by performing a comparison verification on the lower-level upgrade package, it can be determined whether the lower-level upgrade package has been modified before the upgrade, thereby further ensuring software security and improving the stability of the upgrade.

[0032] S23. The host computer performs a de-verification operation on the lower-level upgrade package according to the verification result to obtain a standard upgrade package.

[0033] Specifically, the standard upgrade package includes the data content in the lower-level upgrade package except for the upgrade verification code. The standard upgrade includes multiple upgrade software and corresponding software information for each software. The host computer performing a de-verification operation on the lower-level upgrade package according to the verification result means that when the verification result is verification success, the host computer extracts the data content in the lower-level upgrade package except for the upgrade verification code. When the verification result is verification failure, the upgrade verification ends. The de-verification operation is the same as that in step S21 above and will not be elaborated here.

[0034] In the embodiment of the present invention, by performing a de-verification operation on the lower-level upgrade package according to the verification result to obtain a standard upgrade package, the capacity size of the transmitted upgrade package can be reduced and it is convenient for the lower computer to perform a direct upgrade.

[0035] S24. The host computer sends the standard upgrade package to the lower computer.

[0036] In the embodiment of the present invention, the host computer sending the standard upgrade package to the lower computer includes: the host computer extracts the package features of the standard upgrade package to obtain the upgrade package features; performs feature matching compression on the standard upgrade package according to the upgrade package features to obtain a compressed upgrade package; performs transmission matching on the compressed upgrade package to obtain transmission information, and sends the transmission information to the lower computer; after receiving the confirmation information returned by the lower computer for the transmission information, sends the compressed upgrade package to the lower computer according to the confirmation information.

[0037] Specifically, the upgrade package features refer to the overall features of the standard upgrade package, including the package capacity feature, the package encoding feature, and the package information feature. The package capacity feature refers to the capacity size feature of the standard upgrade package. The package encoding feature refers to the encapsulation structure and the encoding structure feature of the standard upgrade package. The package information feature refers to features such as the modification time, size, and upgrade content description of the standard upgrade package.

[0038] Specifically, package feature extraction is performed on the standard upgrade package to obtain the upgrade package features, including: performing capacity statistics on the standard upgrade package to obtain the package capacity feature; splitting the standard upgrade package into files to obtain the upgrade software set and the software information set; performing encoding feature extraction on the upgrade software set to obtain the package encoding feature; performing keyword feature extraction on the software information set to obtain the package information feature; and aggregating the package capacity feature, the package encoding feature, and the package information feature into the upgrade package features.

[0039] Specifically, the method of file splitting can be the header parsing method or the marker parsing method. The standard upgrade package can be split into a split data set according to the markers of each file in the standard upgrade package, and each split data in the split data set is split by markers to obtain the upgrade software set and the software information set. Among them, each split data in the split data set includes an upgrade software and the software information corresponding to the upgrade software. Marker splitting refers to splitting according to a preset marker.

[0040] Specifically, the upgrade software set includes multiple upgrade software, and the software information set includes the software information corresponding to each upgrade software in the upgrade software set. The upgrade software is the software code used for upgrading, and the software information includes information such as the time, model, and version number of the corresponding upgrade software.

[0041] Specifically, feature matching compression is performed on the standard upgrade package according to the upgrade package features to obtain the compressed upgrade package, including: performing feature normalization encoding operation on the upgrade package features to obtain the upgrade package feature encoding; matching the corresponding compression features from a preset compression form according to the upgrade package feature encoding; and performing block-level and hierarchical compression on the standard upgrade package according to the compression features to obtain the compressed upgrade package.

[0042] Specifically, the method of feature normalization encoding can be functions such as softmax or sigmoid. The compression form is a preset table of compression features matched for different upgrade package feature encoding intervals. The compression features include the block size split during compression, the selection of the compression algorithm, and the compression level, and the selection parameters of the dictionary size.

[0043] Specifically, the transmission matching includes extracting the data packet size of the compressed upgrade package, matching the corresponding transmission rate according to the data packet size, and integrating the data packet size, transmission rate, and compression characteristics into transmission information, where the transmission information includes data such as the data packet size, transmission rate, and compression characteristics of the compressed upgrade package.

[0044] Specifically, the confirmation information refers to the confirmation information of the negotiation parameters for this transmission by the lower computer. When the confirmation information is correct, the transmission can be carried out, and the compressed upgrade package can be sent to the lower computer by using the YMODEM transmission method of serial communication.

[0045] In the embodiment of the present invention, by adaptively compressing the standard upgrade package before sending it to the lower computer, the size of the transmitted data is further reduced, the data transmission efficiency is improved, and the computational load on the lower computer is reduced, thereby improving the software upgrade efficiency.

[0046] In the embodiment of the present invention, by performing byte-by-byte exclusive OR look-up table operations on the lower upgrade package, the preliminary verification of the software content in the lower upgrade package can be realized by using the method of byte-by-byte exclusive OR operation, and the secondary verification can be realized by using the look-up table verification method, reducing the verification duration, improving the verification efficiency, and improving the security of the software package upgrade. By comparing and verifying the lower upgrade package, it can be determined whether the lower upgrade package has been modified before the upgrade, further ensuring software security and improving the stability of the upgrade. By performing de-verification operations on the lower upgrade package according to the verification result to obtain the standard upgrade package, the capacity size of the transmitted upgrade package can be reduced and it is convenient for the lower computer to perform direct upgrade. By adaptively compressing the standard upgrade package before sending it to the lower computer, the size of the transmitted data is further reduced, the data transmission efficiency is improved, and the computational load on the lower computer is reduced, thereby improving the software upgrade efficiency. Therefore, the program upgrade verification method based on a single-chip microcomputer proposed by the present invention can improve the efficiency of single-chip microcomputer program upgrade verification.

[0047] S25. The lower computer receives the standard upgrade package.

[0048] In the embodiment of the present invention, the lower computer receiving the standard upgrade package includes: the lower computer receiving the transmission information sent by the upper computer; generating confirmation information according to the transmission information; sending the confirmation information to the upper computer; and obtaining the standard upgrade package sent by the upper computer in response to the confirmation information according to the transmission information.

[0049] Specifically, the confirmation information refers to the confirmation information of the negotiation parameters for this transmission by the lower computer. The confirmation information includes NAK information and ACK information. NAK information indicates that when the receiving party receives a data packet with an error or loss, it requests the retransmission of the data packet. ACK information indicates that when the receiving party successfully receives and correctly processes a data packet, it has successfully received and is ready to receive the next data packet. The confirmation information can be sent to the upper computer using the YMODEM protocol.

[0050] Specifically, obtain the standard upgrade package sent by the upper computer according to the transmission information, including: extracting the compression features from the transmission information; extracting the block size and compression algorithm from the compression features; decompressing the standard upgrade package in blocks according to the compression algorithm to obtain a decompressed upgrade data block group; and splicing the decompressed upgrade data block group according to the block size to obtain the standard upgrade package.

[0051] Specifically, the compression features include features such as the data block size split during compression, the selection of the compression algorithm and compression level, and the selection parameters of the dictionary size. Each decompressed upgrade data block in the decompressed upgrade data block group corresponds to each data block obtained by splitting the standard upgrade package according to the block size.

[0052] In the embodiment of the present invention, by receiving the transmission information sent by the upper computer, lossless decompression of the data sent by the upper computer can be achieved, improving the data transmission efficiency, saving the time for upgrade verification, and thus improving the efficiency of upgrade verification.

[0053] S26. The lower computer uses the pre-generated real-time software information to perform software matching on the standard upgrade package to obtain a matching result.

[0054] Specifically, the real-time software information is the software information of the corresponding upgrade software automatically generated by the lower computer each time the program is compiled, including information such as time, model, and version number. The matching result refers to the corresponding relationship between each upgrade software in the standard upgrade package and each software to be upgraded in the lower computer. There are multiple software to be upgraded in the lower computer, and each software needs to be matched and upgraded with the corresponding upgrade software in the standard upgrade package.

[0055] In the embodiment of the present invention, the lower computer performs software matching on the standard upgrade package by using the pre-generated real-time software information to obtain a matching result, including: the lower computer splits the standard upgrade package into files to obtain an upgrade software set and a software information set corresponding to the upgrade software set; selects the software information in the software information set one by one as the target software information, and uses the upgrade software corresponding to the target software information in the upgrade software set as the target upgrade software; performs software matching on the target upgrade software according to the pre-generated real-time software information and the target software information to obtain a target matching result; and aggregates the target matching results of all the target upgrade software in the upgrade software set into a matching result.

[0056] Specifically, the file splitting is the same as the file splitting in the above step S24 and will not be elaborated here. Each upgrade software in the upgrade software set is the software for upgrade, and each software information in the software information set includes information such as the time, model, and version number of the corresponding upgrade software.

[0057] Specifically, performing software matching on the target upgrade software according to the pre-generated real-time software information and the target software information to obtain a target matching result includes: performing version and model matching on the pre-generated real-time software information by using the target software information to obtain the software to be upgraded; performing time matching on the real-time software information by using the target software information to obtain the upgrade time; and generating a target matching result according to the upgrade time, the software to be upgraded, and the target upgrade software.

[0058] Specifically, the version and model matching means selecting the software corresponding to the real-time software information with the same version number and movement type as the target software information in the real-time software information as the software to be upgraded. The time matching means comparing the time of the target software information and the real-time software information corresponding to the software to be upgraded. The upgrade time includes the new version time and the old version time. If the time in the target software information is newer than the time of the software to be upgraded, the upgrade time is the new version time. If the time in the target software information is older than the time of the software to be upgraded, the upgrade time is the old version time. The target matching result includes the upgrade time, the software to be upgraded, and the target upgrade software.

[0059] In the embodiment of the present invention, by performing software matching on the standard upgrade package, the lower computer software that needs to be upgraded can be matched for each upgrade software in the standard upgrade package according to the version and model packaged in the software information, which improves the upgrade efficiency, makes each lower computer program uniquely correspond to an upper computer program, prevents the situation that the upgrade cannot be performed due to external accidental modification of the upgrade package name, enhances the software security, and enables the upper computer to stably ensure the upgrade of the upgrade package corresponding to the model.

[0060] S27. The lower computer performs software upgrade on the standard upgrade package according to the matching result.

[0061] In the embodiment of the present invention, the lower computer performs software upgrade on the standard upgrade package according to the matching result, which means extracting the upgrade time, the software to be upgraded, and the target upgrade software from the target matching results in the matching result one by one, performing time verification on the software to be upgraded according to the upgrade time to obtain a verification result, and using the target upgrade software to upgrade the software to be upgraded according to the verification result.

[0062] Specifically, the time verification means that when the upgrade time is the old version time, an upgrade prompt is generated, and the upgrade confirmation information returned by the user for the upgrade prompt is used as the verification result.

[0063] Specifically, by performing software upgrade according to the matching result and the standard upgrade package, the corresponding upgrade matching of the lower computer can be realized, the verification time for matching the software name is reduced, and the upgrade efficiency is improved.

[0064] In the embodiment of the present invention, by receiving the standard upgrade package sent by the upper computer, lossless decompression of the data sent by the upper computer can be realized, the data transmission efficiency is improved, the time for upgrade verification is saved, and thus the efficiency of upgrade verification is improved. By performing software matching on the standard upgrade package, the lower computer software to be upgraded can be matched for each upgrade software in the standard upgrade package according to the version and model packaged in the software information, the upgrade efficiency is improved, each lower computer program uniquely corresponds to an upper computer program, and the situation that the upgrade cannot be performed due to external accidental modification of the upgrade package name is prevented, and the software security is enhanced. The upper computer can also stably ensure the upgrade of the upgrade package corresponding to the model. By performing software upgrade according to the matching result and the standard upgrade package, the corresponding upgrade matching of the lower computer can be realized, the verification time for matching the software name is reduced, and the upgrade efficiency is improved. Therefore, the program upgrade verification method based on the single-chip microcomputer proposed by the present invention can improve the efficiency of single-chip microcomputer program upgrade verification.

[0065] Refer to Figure 3 As shown in the figure, it is a schematic structural diagram of a program upgrade verification system based on a single-chip microcomputer provided by an embodiment of the present invention.

[0066] The program upgrade verification system 300 based on the single-chip microcomputer of the present invention may include: an upper computer 301 and a lower computer 302.

[0067] In this embodiment, the specific configuration of each module / unit is described as follows:

[0068] The upper computer 301 is configured to: obtain the lower upgrade package from a preset USB flash drive, perform byte-by-byte exclusive OR look-up table operation on the lower upgrade package to obtain a look-up table verification value; perform comparison verification on the lower upgrade package according to the look-up table verification value to obtain a verification result; perform division verification operation on the lower upgrade package according to the verification result to obtain a standard upgrade package; and send the standard upgrade package to the lower computer 302.

[0069] The lower computer 302 is configured to: receive a standard upgrade package; perform software matching on the standard upgrade package using pre-generated real-time software information to obtain a matching result; and perform software upgrade on the standard upgrade package according to the matching result.

[0070] The present invention also provides an electronic device, which includes at least one processor; and a memory communicatively connected to the at least one processor; wherein, the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the above-mentioned program upgrade verification method based on a single-chip microcomputer.

[0071] The present invention also provides a storage medium, and the readable storage medium stores a computer program, which can implement the program upgrade verification method based on a single-chip microcomputer according to one or more embodiments provided in the present application when executed by a processor of the system.

[0072] For those skilled in the art, it is obvious that the present invention is not limited to the details of the above-mentioned exemplary embodiments, and without departing from the spirit or basic characteristics of the present invention, the present invention can be implemented in other specific forms.

[0073] Therefore, from any point of view, the embodiments should be regarded as exemplary and non-limiting. The scope of the present invention is defined by the appended claims rather than the above description. Therefore, all changes falling within the meaning and scope of the equivalent elements of the claims are intended to be included in the present invention. Any reference signs in the claims should not be regarded as limiting the claimed rights. In addition, it is obvious that the word "comprising" does not exclude other units or steps, and the singular does not exclude the plural. The multiple units or systems stated in the system claims can also be implemented by one unit or system through software or hardware. The terms such as "first" and "second" are used to represent names and do not indicate any specific order.

[0074] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit them. Although the present invention has been described in detail with reference to the preferred embodiments, those of ordinary skill in the art should understand that the technical solutions of the present invention can be modified or equivalently replaced without departing from the spirit and scope of the technical solutions of the present invention.

Claims

1. A program upgrade verification method based on a single chip microcomputer, characterized in that: The method comprises: The upper computer obtains the lower upgrade package from the preset U disk, and performs a byte-by-byte XOR table lookup operation on the lower upgrade package to obtain a table lookup check value; The upper computer performs a comparison check on the lower upgrade package according to the table check value to obtain a check result; The upper computer performs a de-verification operation on the lower upgrade package according to the verification result to obtain a standard upgrade package; The upper computer sends the standard upgrade package to the lower computer; The lower computer receives the standard upgrade package; The lower computer uses the pre-generated real-time software information to perform software matching on the standard upgrade package to obtain a matching result; The lower computer performs software upgrade on the standard upgrade package according to the matching result.

2. The program upgrade verification method based on a single chip microcomputer as claimed in claim 1, characterized in that: The performing a byte-by-byte XOR table lookup operation on the lower-level upgrade package to obtain a table lookup check value includes: Performing a de-verification operation on the lower-level upgrade package to obtain a standard upgrade package; Performing byte-binary conversion on the standard upgrade package to obtain software byte data; Selecting byte data in the software byte data as target byte data byte by byte, performing an XOR table lookup operation on the target byte data using a preset registration check code to obtain an XOR check code; The stored check code is updated using the XOR check code, and the step of selecting byte data in the software byte data as the target byte data byte by byte is returned until the target byte data is the last byte data in the software byte data, and the XOR check code is used as the table lookup check value.

3. The program upgrade verification method based on a single chip microcomputer as claimed in claim 2, characterized in that: The method of performing an XOR table lookup operation on the target byte data using a preset registration check code to obtain an XOR check code includes: Using a preset registration check code to perform a low-byte XOR operation on the target byte data to obtain an XOR byte code; Performing a check table lookup on the XOR bytecode to obtain a table lookup bytecode; Performing a byte cyclic right shift operation on the stored check code to obtain a right shift check code; The table lookup bytecode is used to perform a low byte XOR operation on the right shift check code to obtain an XOR check code.

4. The program upgrade verification method based on a single chip microcomputer as claimed in claim 1, characterized in that: The upper computer performs a comparison check on the lower upgrade package according to the table check value to obtain a check result, including: The upper computer extracts the upgrade verification code from the lower upgrade package; Determining whether the table lookup check value is the same as the upgrade check code; If yes, the verification is deemed successful; If not, the verification is determined to have failed.

5. The program upgrade verification method based on a single chip microcomputer as claimed in claim 1, characterized in that: The upper computer sends the standard upgrade package to the lower computer, including: The host computer extracts package features from the standard upgrade package to obtain upgrade package features; Perform feature matching and compression on the standard upgrade package according to the features of the upgrade package to obtain a compressed upgrade package; Performing transmission matching on the compressed upgrade package to obtain transmission information, and sending the transmission information to the lower computer; After receiving the confirmation information returned by the lower computer in response to the transmission information, the compressed upgrade package is sent to the lower computer according to the confirmation information.

6. The program upgrade verification method based on a single chip microcomputer as claimed in claim 5, characterized in that: The lower computer receives the standard upgrade package, including: The lower computer receives the transmission information sent by the upper computer; generating confirmation information according to the transmission information; Sending the confirmation information to the host computer; A standard upgrade package sent by the host computer in response to the confirmation information is obtained according to the transmission information.

7. The program upgrade verification method based on a single chip microcomputer as claimed in claim 6, characterized in that: The lower computer performs software matching on the standard upgrade package using the pre-generated real-time software information to obtain a matching result, including: The lower computer splits the standard upgrade package into files to obtain an upgrade software set and a software information set corresponding to the upgrade software set; Selecting software information in the software information set one by one as target software information, and taking the upgrade software corresponding to the target software information in the upgrade software set as target upgrade software; Performing software matching on the target upgrade software according to the pre-generated real-time software information and the target software information to obtain a target matching result; The target matching results of all target upgrade software in the upgrade software set are aggregated into a matching result.

8. A program upgrade verification system based on a single chip microcomputer, characterized in that: Including: upper computer and lower computer; The upper computer is configured as follows: obtaining a lower upgrade package from a preset U disk, and performing a byte-by-byte XOR table lookup operation on the lower upgrade package to obtain a table lookup check value; performing a comparison check on the lower upgrade package according to the table lookup check value to obtain a check result; performing a check-out operation on the lower upgrade package according to the check result to obtain a standard upgrade package; and sending the standard upgrade package to the lower computer; The lower computer is configured to: receive the standard upgrade package; perform software matching on the standard upgrade package using pre-generated real-time software information to obtain a matching result; and perform software upgrade on the standard upgrade package according to the matching result.

9. An electronic device, characterized in that: The electronic device comprises: at least one processor; and, a memory communicatively connected to the at least one processor; wherein, The processor is used to execute the computer program stored in the memory; When the processor executes the computer program, the steps in the method according to any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.