CN112486549A - Automobile embedded software upgrading method and device and storage medium - Google Patents

Automobile embedded software upgrading method and device and storage medium Download PDF

Info

Publication number
CN112486549A
CN112486549A CN202011197393.1A CN202011197393A CN112486549A CN 112486549 A CN112486549 A CN 112486549A CN 202011197393 A CN202011197393 A CN 202011197393A CN 112486549 A CN112486549 A CN 112486549A
Authority
CN
China
Prior art keywords
application code
area
backup area
backup
embedded software
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011197393.1A
Other languages
Chinese (zh)
Inventor
黄迅
黄锐景
冯启翔
邹世斌
彭忠
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
GAC Component Co Ltd
Original Assignee
GAC Component Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by GAC Component Co Ltd filed Critical GAC Component Co Ltd
Priority to CN202011197393.1A priority Critical patent/CN112486549A/en
Publication of CN112486549A publication Critical patent/CN112486549A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • G06F8/654Updates using techniques specially adapted for alterable solid state memories, e.g. for EEPROM or flash memories
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1415Saving, restoring, recovering or retrying at system level
    • G06F11/1433Saving, restoring, recovering or retrying at system level during software upgrading
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1415Saving, restoring, recovering or retrying at system level
    • G06F11/1438Restarting or rejuvenating
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1448Management of the data involved in backup or backup restore

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Quality & Reliability (AREA)
  • Software Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses an automobile embedded software upgrading method, which comprises the following steps: when the system detects a reprogramming request, downloading a new application code to the storage device and backing up the new application code to a backup area of the storage device; receiving an erasing service request, erasing an application code backup area of the system and backing up an old application code of the application code area of the system to the application code backup area; erasing the application code area and copying the new application code to the application code area; and erasing the related information of the storage equipment and restarting the system after the error count is finished, thereby realizing the upgrading of the embedded software of the automobile. The upgrading method provided by the invention is more stable and safer. The invention also provides an automobile embedded software upgrading device and a storage medium.

Description

Automobile embedded software upgrading method and device and storage medium
Technical Field
The invention relates to embedded software upgrading, in particular to a method and a device for upgrading embedded software of an automobile and a storage medium.
Background
At present, embedded software is installed in embedded devices of automobiles, and corresponding upgrading is required for upgrading the automobiles, but because original application programs need to be covered in the upgrading process, errors are easily caused to cause upgrading failure, and meanwhile, the problems that the system is broken down and the like are caused by upgrading failure in the upgrading process.
Disclosure of Invention
In order to overcome the defects of the prior art, one of the objectives of the present invention is to provide an automobile embedded software upgrading method, which can solve the problems in the prior art that an error is easy to occur in the automobile embedded software upgrading process, the upgrading is failed, and the system is paralyzed.
The second objective of the present invention is to provide an automobile embedded software upgrading device, which can solve the problem that the system is broken down due to the failure of upgrading caused by the easy error in the automobile embedded software upgrading process in the prior art.
The invention further aims to provide a storage medium which can solve the problems that in the prior art, errors are easy to occur in the upgrading process of automobile embedded software, upgrading fails, and the system is paralyzed.
One of the purposes of the invention is realized by adopting the following technical scheme:
an automobile embedded software upgrading method comprises the following steps:
a request detection step: when the system detects a reprogramming request, downloading a new application code to the storage device and backing up the new application code to a backup area of the storage device;
a backup step: receiving an erasing service request, erasing an application code backup area of the system and backing up an old application code of the application code area of the system to the application code backup area;
an updating step: erasing the application code area and copying the new application code to the application code area;
a clearing step: and restarting after erasing the related information of the storage device and the error count of the system.
Further, when the system does not detect a reprogramming request and the system is available: detecting whether the storage equipment is available, if so, erasing relevant information of the storage equipment, and then jumping to a system software interface; if not, directly jumping to a system software interface.
Further, when the system does not detect a reprogramming request and the system is not available:
a detection step: detecting whether the application code backup area and the storage equipment backup area are both available, and if so, executing a backup recovery step; if not, the system is stopped in a Boot area to execute a BootLoader program;
a backup and recovery step: and copying the new application codes in the backup area of the storage device to a system memory and copying the old application codes in the backup area of the application codes to the application code area, and then erasing the relevant information of the storage device and clearing the system error count and restarting the storage device.
Further, the backup restoring step includes:
a first recovery step: copying a new application code in a backup area of the storage device to a system memory;
a first judgment step: judging whether the new application codes in the system memory are consistent with the new application codes in the backup area of the storage device, if so, executing a second recovery step; if not, the counter is + 1;
a second recovery step: copying the old application codes of the application code backup area to the application code area, and then executing a second judgment step;
a second judgment step: judging whether the old application codes in the application code area are consistent with the old application codes in the application code backup area or not, if so, setting the available state of the application code area as available; if not, the counter is + 1.
Further, in the first and second determining steps: when the counter is larger than a preset value, restarting the system; and when the counter is larger than the preset value, the system stays in a Boot area to execute a Boot loader program.
Further, the preset value is 5.
Further, the request detection step further comprises:
a downloading step: downloading the new application code in the storage device to a system memory;
a first judgment step: when the backup area of the storage equipment is available and the new application codes in the system memory are consistent with the new application codes in the backup area of the storage equipment, executing a backup step; when the backup area of the storage equipment is unavailable or the new application codes in the system memory are inconsistent with the new application codes in the backup area of the storage equipment, executing a first backup erasing step;
a first backup erasing step: erasing the backup area of the storage device and re-backing up the new application codes in the system memory to the backup area of the storage device;
a first checking step: checking whether the new application code in the backup area of the storage device is consistent with the new application code in the system memory, if so, marking a setting step; if not, restarting;
a mark setting step: setting the available state of a Flash Driver backup area as available; a backup step is then performed.
Further, the step of backing up further comprises:
a second detection step: when the old application codes of the application code backup area are consistent with the old application codes of the application code area and the application code backup area is available, executing an erasing step; when the old application code of the application code backup area is inconsistent with the old application code of the application code area or the application code backup area is unavailable, executing a second backup erasing step;
a second backup erasing step: erasing the application code backup area and copying the old application code to the application code backup area;
a second checking step: checking whether the old application codes of the application code backup area are consistent with the old application codes of the application code area, if so, setting the available state of the application code backup area as available, and then executing an erasing step; if not, restarting the system.
The second purpose of the invention is realized by adopting the following technical scheme:
the invention discloses an automobile embedded software upgrading device, which comprises a memory and a processor, wherein an automobile embedded software upgrading program capable of running on the processor is stored in the memory, the automobile embedded software upgrading program is a computer program, and the steps of the automobile embedded software upgrading method adopted by one of the purposes of the invention are realized when the processor executes the automobile embedded software upgrading program.
The third purpose of the invention is realized by adopting the following technical scheme:
a storage medium, which is a computer-readable storage medium, having stored thereon an automotive embedded software upgrade program, which is a computer program, which when executed by a processor implements the steps of a method for automotive embedded software upgrade as employed in one of the objects of the present invention.
Compared with the prior art, the invention has the beneficial effects that:
the invention stores new application codes by setting the backup area of the storage device and stores old application codes by using the backup area of the application codes of the system, thereby realizing the upgrade of the embedded software of the automobile.
Drawings
FIG. 1 is a main flow chart of a method for upgrading embedded software of an automobile according to the present invention;
FIG. 2 is a flowchart of step S12 of FIG. 1 according to the present invention;
FIG. 3 is a flowchart of step S11 of FIG. 1 according to the present invention;
FIG. 4 is a flowchart of step S31 provided by the present invention;
fig. 5 is a block diagram of an automobile embedded software upgrading device provided by the invention.
In the figure: 11. a memory; 12. a processor; 13. a communication bus; 14. a network interface.
Detailed Description
The present invention will be further described with reference to the accompanying drawings and the detailed description, and it should be noted that any combination of the embodiments or technical features described below can be used to form a new embodiment without conflict.
Example one
The invention provides an automobile embedded software upgrading method, which can quickly realize upgrading through a backup mechanism, reduce the upgrading error rate and greatly improve the upgrading stability, and as shown in figure 1, the main flow of the method specifically comprises the following steps:
step S10, the system checks whether there is a reprogramming request, if yes, step S11 is executed, and if not, step S20 is executed. The reprogramming request refers to a request for judging whether the embedded software of the automobile needs to be updated or not.
For example, when the embedded software of the automobile needs to be upgraded, the device such as the upper computer generally sends a reprogramming request to the system, and therefore whether the software is upgraded or not is judged by detecting whether the reprogramming request exists or not by the system.
And step S11, downloading the new application code to the storage device and backing up the new application code to the storage device backup area.
The new application code refers to new program code data after software is upgraded.
Preferably, the storage device in this embodiment adopts Flash Driver (Flash drive). Therefore, after detecting the reprogramming request, the new application code is downloaded to the Flash Driver and backed up to the Flash Driver backup area. By setting the Flash Drive backup area, when the new application code is damaged due to other factors in the Flash Drive in the upgrading process, the new application code can be quickly recovered from the Flash Drive backup area.
Preferably, the storage device in this embodiment may be various external memories such as a commonly used usb disk and a mobile hard disk, in addition to the Flash Driver. Preferably, the present embodiment is described by taking Flash Driver as an example.
Step S12, the system receives the erase service request and erases the application code backup area and backs up the old application code of the application code area to the application code backup area.
Wherein, the application code area is used for storing the application code of the system. The old application code is the application code prior to the upgrade. During the upgrade, the software upgrade is implemented by copying the new application code to the application code area, thereby overwriting the old application code.
Meanwhile, the old application codes are backed up by setting the application code backup area, so that after the upgrade fails, the state before the upgrade can be restored according to the application code backup area.
And step S13, copying the new application code of the Flash Driver into the system memory, and erasing the application code area to copy the new application code in the system memory into the application code area.
And step S14, after the relevant information of the Flash Driver is erased and the system is restarted after the error count is carried out, the embedded software of the automobile is upgraded.
The related information of the Flash Driver refers to various flag bits set in the upgrading process of the system and is used for marking the rollback position when the upgrading fails in the upgrading process. The error count is data specified in the system, such as the number of determinations and the number of calculations.
Further, as shown in FIG. 1, when no programming request is detected in the system:
step S20, detecting whether the system is available, if yes, executing step S21; if not, step S30 is executed.
Preferably, the present embodiment indicates the availability of a device, program, system, or the like by setting a valid flag. That is, when the valid flag in the system is valid, the system is considered to be available and the APP of the embedded software of the automobile is available.
Step S21, detecting whether Flash Drive is available, if yes, executing step S22; if not, jumping to other interfaces of the application program or executing other operations.
And step S22, after the relevant information of the Flash Driver is erased, jumping to other interfaces of the application program or executing other operations. And restoring the data of the False Driver in the system by erasing the related information of the Flash Driver, thereby ensuring the safety of upgrading the data.
Because the current embedded software does not need to be upgraded and the system is available, if the current Flash Driver is available, it is indicated that the upgraded application code is stored in the Flash Driver, and therefore, in order to ensure the security of the software, the related information of the Flash Driver, the error count in the system and the like are erased.
When the system is unavailable, that is, the embedded software APP cannot be used normally, the system needs to be recovered, specifically:
step S30, detecting whether the application code backup area and the Flash Driver backup area are both available, if yes, executing step S31; if not, the system stays in the Boot area to execute the BootLoader program.
The step of stopping the system in the Boot area to execute the BootLoader program means that the most basic operation program of the system is reserved, and the basic operation of the system is ensured.
Step S31, copy the new application code in the Flash Driver backup area to the system memory and copy the old application code in the application code backup area to the application code area, and then execute step S32.
And step S32, erasing the relevant information of the Flash Driver, and restarting after clearing the system error count. At this time, the old application code in the application code backup area is copied to the application code area, so that the system enters the state before upgrading after the system is restarted at this time.
Preferably, in order to ensure the correctness of the upgrade, when the new application code is downloaded, the correctness of the new application code also needs to be ensured. Further, as shown in fig. 3, step S11 further includes:
and step S110, downloading the new application code in the Flash Driver to a system memory.
Step S111, checking whether the Flash Driver backup area is available and whether the new application codes in the system memory are consistent with the application codes in the Flash Driver backup area, and executing step S12 if the Flash Driver backup area is available and the new application codes in the system memory are consistent with the application codes in the Flash Driver backup area; otherwise, step S112 is executed.
Preferably, when determining whether the application codes are consistent, the present embodiment performs the determination by calculating crc (cyclic Redundancy check). The CRC is a cyclic redundancy check code, and whether the data is correct or not can be checked by calculating and checking the CRC.
That is, step S110 further includes calculating a CRC value of the new application code in the system memory.
In step S111, when the CRC value of the new application code in the system memory is the same as the CRC value of the new application code in the Flash Driver backup area and the Flash Driver backup area is available, step S12 may be executed to perform the next data backup; and otherwise, if the new application codes in the Flash Driver backup area are wrong, the new application codes in the Flash Driver backup area are backed up again.
And S112, erasing the Flash Driver backup area and backing up the new application codes in the Flash Driver to the Flash Driver backup area.
And step S113, judging whether the new application codes in the Flash Driver backup area are consistent with the new application codes in the system memory, if so, executing step S114, and if not, restarting.
And step S114, setting the available state of the Flash Driver backup area as available, and then executing step S12.
Step S114 specifically includes: and setting the valid flag of the Flash Driver backup area as valid and the CRC value of the new application code.
Preferably, when the old application code of the application code area is backed up to the application code backup area, in order to ensure the correctness of the subsequent rollback, as shown in fig. 2, step S12 specifically includes the following steps:
step S120, whether the application code backup area is available or not is verified, and whether the old application codes of the application code backup area are consistent with the old application codes of the application code area or not is verified; when the application code backup area is available and the old application code of the application code backup area is consistent with the old application code of the application code area, performing step S13; otherwise, step S121 is executed.
And step S121, erasing the application code backup area and copying the old application code into the application code backup area.
Step S122, checking whether the old application code of the application code area is consistent with the old application code of the application code backup area, and if not, restarting; if yes, go to step S123.
Preferably, when checking whether the old application code in the application code area is consistent with the old application code in the application code backup area, the CRC value of the old application code in the application code area and the CRC value of the old application code in the application code backup area are respectively calculated, and then the comparison is made whether the CRC values of the old application code in the application code area and the old application code in the application code backup area are consistent, if so, the old application codes of the old application code and the application code backup area are considered to be consistent.
Step S123, the available state of the application code backup area is set to available, and then step S13 is executed. Preferably, step S123 further includes setting the valid flag of the application code backup area to be valid, and setting the CRC value of the old application code of the application code backup area to the CRC value of the old application code of the application code area.
Further, as shown in fig. 4, when the upgrade is wrong and needs to be rolled back to before the upgrade status, that is, in step S31, after the new application code in the Flash Driver backup area is downloaded to the system memory, the CRC value of the new application code in the system memory is further calculated, and then step S310 is executed.
Step S310, checking whether the new application code of the Flash Driver backup area is consistent with the new application code in the system memory, if so, executing step S311; if not, the counter is + 1.
Step 311, copying the old application code in the application code backup area to the application code area.
Step S312, judging whether the old application codes of the application code area are consistent with the old application codes of the application code backup area, if so, executing step S313; if not, the counter is increased by 1.
Step S313 sets the available state of the application code area to available. Preferably, the valid flag of the application code area is set to valid and the old application code of the application code area is set to the CRC value of the old application code of the application code backup area.
Preferably, in step S310 and step S312, when the counter is greater than the preset value, the system stays in the Boot area to execute the BootLoader program; and when the counter is smaller than the preset value, restarting the system.
Preferably, the preset value is 5.
The invention judges whether the application program, the FlashDriver backup area, the application code backup area and the like are available or not by setting the effective mark to ensure the upgrading stability, and simultaneously judges whether the backup of the new and old application codes in the upgrading process is correct or not by combining CRC (cyclic redundancy check), thereby ensuring the upgrading accuracy and ensuring that the application program can be rolled back to the state before upgrading after the upgrading fails.
Example two
The invention provides an automobile embedded software upgrading device. As shown in fig. 5, an internal structure diagram of the embedded software upgrading apparatus for an automobile according to an embodiment of the present invention is provided.
In this embodiment, the embedded software upgrading device of the automobile may be a PC (Personal Computer), or may also be a terminal device such as a smart phone, a tablet Computer, or a portable Computer. The embedded software upgrading device for the automobile at least comprises: a processor 12, a communication bus 13, a network interface 14, and a memory 11.
The memory 11 includes at least one type of readable storage medium, which includes a flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, and the like. The memory 11 may in some embodiments be an internal memory unit of the car embedded software upgrade device, for example a hard disk of the car embedded software upgrade device. The memory 11 may also be an external storage device of the embedded software upgrading device of the vehicle in other embodiments, for example, a plug-in hard disk provided on the embedded software upgrading device of the vehicle, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like. Further, the memory 11 may also include both an internal storage unit of the automobile embedded software upgrade apparatus and an external storage device. The memory 11 may be used not only to store application software installed in the car embedded software upgrade apparatus and various types of data, such as codes of a car embedded software upgrade program, etc., but also to temporarily store data that has been output or is to be output.
The processor 12 may be, in some embodiments, a Central Processing Unit (CPU), controller, microcontroller, microprocessor or other data Processing chip for executing program codes stored in the memory 11 or Processing data, such as executing an automobile embedded software upgrade program.
The communication bus 13 is used to realize connection communication between these components.
The network interface 14 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface), and is typically used to establish a communication link between the vehicle embedded software upgrade and other electronic devices.
Optionally, the embedded software upgrading device of the automobile may further include a user interface, the user interface may include a Display (Display), an input unit such as a Keyboard (Keyboard), and the optional user interface may further include a standard wired interface and a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display, which may also be referred to as a display screen or display unit, is suitable for displaying information processed in the vehicle embedded software upgrading device and for displaying a visual user interface.
While fig. 5 shows only an automobile embedded software upgrade device with components 11-14 and an automobile embedded software upgrade program, those skilled in the art will appreciate that the configuration shown in fig. 5 does not constitute a limitation of an automobile embedded software upgrade device, and may include fewer or more components than shown, or combine certain components, or a different arrangement of components.
In the embodiment of the embedded software upgrading device for the vehicle shown in fig. 5, the memory 11 stores an embedded software upgrading program for the vehicle; the processor 12 implements the following steps when executing the automobile embedded software upgrading program stored in the memory 11:
a request detection step: when the system detects a reprogramming request, downloading a new application code to the storage device and backing up the new application code to a backup area of the storage device;
a backup step: receiving an erasing service request, erasing an application code backup area of the system and backing up an old application code of the application code area of the system to the application code backup area;
an updating step: erasing the application code area and copying the new application code to the application code area;
a clearing step: and restarting after erasing the related information of the storage device and the error count of the system.
Further, when the system does not detect a reprogramming request and the system is available: detecting whether the storage equipment is available, if so, erasing relevant information of the storage equipment, and then jumping to a system software interface; if not, directly jumping to a system software interface.
Further, when the system does not detect a reprogramming request and the system is not available:
a detection step: detecting whether the application code backup area and the storage equipment backup area are both available, and if so, executing a backup recovery step; if not, the system is stopped in a Boot area to execute a BootLoader program;
a backup and recovery step: and copying the new application codes in the backup area of the storage device to a system memory and copying the old application codes in the backup area of the application codes to the application code area, and then erasing the relevant information of the storage device and clearing the system error count and restarting the storage device.
Further, the backup restoring step includes:
a first recovery step: copying a new application code in a backup area of the storage device to a system memory;
a first judgment step: judging whether the new application codes in the system memory are consistent with the new application codes in the backup area of the storage device, if so, executing a second recovery step; if not, the counter is + 1;
a second recovery step: copying the old application codes of the application code backup area to the application code area, and then executing a second judgment step;
a second judgment step: judging whether the old application codes in the application code area are consistent with the old application codes in the application code backup area or not, if so, setting the available state of the application code area as available; if not, the counter is + 1.
Further, in the first and second determining steps: when the counter is larger than a preset value, restarting the system; and when the counter is larger than the preset value, the system stays in a Boot area to execute a Boot loader program.
Further, the preset value is 5.
Further, the request detection step further comprises:
a downloading step: downloading the new application code in the storage device to a system memory;
a first judgment step: when the backup area of the storage equipment is available and the new application codes in the system memory are consistent with the new application codes in the backup area of the storage equipment, executing a backup step; when the backup area of the storage equipment is unavailable or the new application codes in the system memory are inconsistent with the new application codes in the backup area of the storage equipment, executing a first backup erasing step;
a first backup erasing step: erasing the backup area of the storage device and re-backing up the new application codes in the system memory to the backup area of the storage device;
a first checking step: checking whether the new application code in the backup area of the storage device is consistent with the new application code in the system memory, if so, marking a setting step; if not, restarting;
a mark setting step: setting the available state of a Flash Driver backup area as available; a backup step is then performed.
Further, the step of backing up further comprises:
a second detection step: when the old application codes of the application code backup area are consistent with the old application codes of the application code area and the application code backup area is available, executing an erasing step; when the old application code of the application code backup area is inconsistent with the old application code of the application code area or the application code backup area is unavailable, executing a second backup erasing step;
a second backup erasing step: erasing the application code backup area and copying the old application code to the application code backup area;
a second checking step: checking whether the old application codes of the application code backup area are consistent with the old application codes of the application code area, if so, setting the available state of the application code backup area as available, and then executing an erasing step; if not, restarting the system.
EXAMPLE III
A storage medium, which is a computer-readable storage medium, on which an automobile embedded software upgrade program is stored, wherein the automobile embedded software upgrade program is a computer program, and when executed by a processor, the automobile embedded software upgrade program implements the steps of an automobile embedded software upgrade method as provided in an embodiment one.
The above embodiments are only preferred embodiments of the present invention, and the protection scope of the present invention is not limited thereby, and any insubstantial changes and substitutions made by those skilled in the art based on the present invention are within the protection scope of the present invention.

Claims (10)

1. An automobile embedded software upgrading method is characterized by comprising the following steps:
a request detection step: when the system detects a reprogramming request, downloading a new application code to the storage device and backing up the new application code to a backup area of the storage device;
a backup step: receiving an erasing service request, erasing an application code backup area of the system and backing up an old application code of the application code area of the system to the application code backup area;
an updating step: erasing the application code area and copying the new application code to the application code area;
a clearing step: and restarting after erasing the related information of the storage device and the error count of the system.
2. The method for upgrading embedded software of automobile according to claim 1, characterized in that when the system does not detect a reprogramming request and the system is available: detecting whether the storage equipment is available, if so, erasing relevant information of the storage equipment, and then jumping to a system software interface; if not, directly jumping to a system software interface.
3. The method for upgrading embedded software of automobile according to claim 2, characterized in that when the system does not detect a reprogramming request and the system is not available:
a detection step: detecting whether the application code backup area and the storage equipment backup area are both available, and if so, executing a backup recovery step; if not, the system is stopped in a Boot area to execute a BootLoader program;
a backup and recovery step: and copying the new application codes in the backup area of the storage device to a system memory and copying the old application codes in the backup area of the application codes to the application code area, and then erasing the relevant information of the storage device and clearing the system error count and restarting the storage device.
4. The method for upgrading embedded software of an automobile according to claim 3, wherein the backup restoring step comprises:
a first recovery step: copying a new application code in a backup area of the storage device to a system memory;
a first judgment step: judging whether the new application codes in the system memory are consistent with the new application codes in the backup area of the storage device, if so, executing a second recovery step; if not, the counter is + 1;
a second recovery step: copying the old application codes of the application code backup area to the application code area, and then executing a second judgment step;
a second judgment step: judging whether the old application codes in the application code area are consistent with the old application codes in the application code backup area or not, if so, setting the available state of the application code area as available; if not, the counter is + 1.
5. The upgrading method for the embedded software of the automobile according to claim 4, wherein in the first judging step and the second judging step: when the counter is larger than a preset value, restarting the system; and when the counter is larger than the preset value, the system stays in a Boot area to execute a Boot loader program.
6. The method for upgrading embedded software of an automobile according to claim 5, wherein the preset value is 5.
7. The method for upgrading embedded software of automobile according to claim 1, wherein the step of detecting the request is followed by the steps of:
a downloading step: downloading the new application code in the storage device to a system memory;
a first judgment step: when the backup area of the storage equipment is available and the new application codes in the system memory are consistent with the new application codes in the backup area of the storage equipment, executing a backup step; when the backup area of the storage equipment is unavailable or the new application codes in the system memory are inconsistent with the new application codes in the backup area of the storage equipment, executing a first backup erasing step;
a first backup erasing step: erasing the backup area of the storage device and re-backing up the new application codes in the system memory to the backup area of the storage device;
a first checking step: checking whether the new application code in the backup area of the storage device is consistent with the new application code in the system memory, if so, marking a setting step; if not, restarting;
a mark setting step: setting the available state of a Flash Driver backup area as available; a backup step is then performed.
8. The method for upgrading embedded software of an automobile according to claim 1, wherein the step of backing up further comprises:
a second detection step: when the old application codes of the application code backup area are consistent with the old application codes of the application code area and the application code backup area is available, executing an erasing step; when the old application code of the application code backup area is inconsistent with the old application code of the application code area or the application code backup area is unavailable, executing a second backup erasing step;
a second backup erasing step: erasing the application code backup area and copying the old application code to the application code backup area;
a second checking step: checking whether the old application codes of the application code backup area are consistent with the old application codes of the application code area, if so, setting the available state of the application code backup area as available, and then executing an erasing step; if not, restarting the system.
9. The embedded software upgrading device for the automobile comprises a memory and a processor, wherein an embedded software upgrading program of the automobile, which can run on the processor, is stored on the memory, and the embedded software upgrading program of the automobile is a computer program, and is characterized in that: the steps of a method for upgrading embedded software of an automobile according to any one of claims 1-8 are realized when the processor executes the program for upgrading embedded software of an automobile.
10. A storage medium which is a computer-readable storage medium having an automobile embedded software upgrade program stored thereon, the automobile embedded software upgrade program being a computer program, characterized in that: the steps of a method for upgrading embedded software of a vehicle according to any one of claims 1-8 are implemented when the embedded software upgrading program is executed by a processor.
CN202011197393.1A 2020-10-30 2020-10-30 Automobile embedded software upgrading method and device and storage medium Pending CN112486549A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011197393.1A CN112486549A (en) 2020-10-30 2020-10-30 Automobile embedded software upgrading method and device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011197393.1A CN112486549A (en) 2020-10-30 2020-10-30 Automobile embedded software upgrading method and device and storage medium

Publications (1)

Publication Number Publication Date
CN112486549A true CN112486549A (en) 2021-03-12

Family

ID=74927956

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011197393.1A Pending CN112486549A (en) 2020-10-30 2020-10-30 Automobile embedded software upgrading method and device and storage medium

Country Status (1)

Country Link
CN (1) CN112486549A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070055969A1 (en) * 2005-09-06 2007-03-08 Benq Corporation System and method for updating firmware
CN101557583A (en) * 2009-03-19 2009-10-14 珠海银邮光电技术发展股份有限公司 Remote-updating and version-switching method of repeater equipment embedded software
CN106569847A (en) * 2016-10-14 2017-04-19 数源科技股份有限公司 Method for realizing IAP remote upgrade through vehicle-mounted system based on mobile network
JP2019008693A (en) * 2017-06-28 2019-01-17 日立オートモティブシステムズ株式会社 Vehicle-purpose electronic control unit
CN110874237A (en) * 2019-12-30 2020-03-10 深圳市英博超算科技有限公司 Software upgrading method, device, terminal and readable storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070055969A1 (en) * 2005-09-06 2007-03-08 Benq Corporation System and method for updating firmware
CN101557583A (en) * 2009-03-19 2009-10-14 珠海银邮光电技术发展股份有限公司 Remote-updating and version-switching method of repeater equipment embedded software
CN106569847A (en) * 2016-10-14 2017-04-19 数源科技股份有限公司 Method for realizing IAP remote upgrade through vehicle-mounted system based on mobile network
JP2019008693A (en) * 2017-06-28 2019-01-17 日立オートモティブシステムズ株式会社 Vehicle-purpose electronic control unit
CN110874237A (en) * 2019-12-30 2020-03-10 深圳市英博超算科技有限公司 Software upgrading method, device, terminal and readable storage medium

Similar Documents

Publication Publication Date Title
CN106020865B (en) System upgrading method and device
CN110178114B (en) Vehicle control device and program update system
KR101515198B1 (en) Apparatus and method for firmware upgrade in mobile device
CN102117234B (en) Method for recovering original software by mobile terminal in software upgrading failure
CN110333891A (en) The method of enhanced OTA upgrading based on Internet of Things
CN109358887B (en) On-line upgrading method, device and system for single chip microcomputer program
CN103518191A (en) Upgrade method, intelligent terminal and upgrade system
CN105260215A (en) Method of updating vehicle-mounted automobile data recorder terminal by USB flash disk
CN107678762B (en) System version upgrading method and device
CN111813428A (en) Method and device for upgrading terminal firmware, electronic equipment and storage medium
CN111142911A (en) Embedded system with abnormal recovery function and upgrading method thereof
CN113254048B (en) Method, device and equipment for updating boot program and computer readable medium
CN112015447B (en) System updating method and device of electronic equipment, electronic equipment and storage medium
CN106201640A (en) A kind of method and device of BootLoader program of upgrading
CN112181455B (en) Online upgrading method of microcontroller, microcontroller and storage medium
CN111984298B (en) Program upgrading area in flash memory, program upgrading method and system
CN112486549A (en) Automobile embedded software upgrading method and device and storage medium
CN109408079B (en) Embedded equipment and upgrading method thereof
CN112579179A (en) Partition mounting method of embedded system
KR101461650B1 (en) Apparatus and method for managing file system of a computing device
CN112732301A (en) Vehicle upgrading method and device
CN110727450A (en) Method and device for updating boot loader
CN111190627A (en) System upgrading method and device
CN107656747B (en) Data upgrading method and mobile terminal
US9916029B2 (en) Sensor controller, sensor device including sensor controller, electronic apparatus equipped with sensor device, and application software recovery method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination