Search

CN-122018940-A - Method and device for self-updating BOOT of vehicle-mounted electronic control unit based on APP

CN122018940ACN 122018940 ACN122018940 ACN 122018940ACN-122018940-A

Abstract

The invention provides a method and a device for self-updating BOOT of a vehicle-mounted electronic control unit based on APP, and relates to the technical field of vehicle control, wherein the method comprises the steps of responding to the condition that a BOOT application program to be refreshed meets a preset refreshing condition, and modifying an original starting address of a corresponding chip of the vehicle-mounted electronic control unit into a preset address; writing a BOOT information header file and a BOOT code segment stored by a BOOT application program to be written into the BOOT of the vehicle-mounted electronic control unit in response to the completion of modification of the preset address, and carrying out writing verification on the written BOOT of the vehicle-mounted electronic control unit; and in response to successful verification of the swipe, modifying the preset address to be the starting address of the BOOT code segment in the swipe BOOT, and resetting the swipe BOOT. The invention is used for solving the technical problems that the updating of the BOOT program of the traditional vehicle-mounted electronic control unit depends on special equipment, and has low efficiency and larger customer perception.

Inventors

  • GAO QIANG
  • Guan Juanyi

Assignees

  • 武汉江夏楚能汽车技术研发有限公司

Dates

Publication Date
20260512
Application Date
20260211

Claims (10)

  1. 1. The method for self-updating BOOT of the vehicle-mounted electronic control unit based on the APP is characterized by comprising the following steps of: Responding to the BOOT application program to be refreshed meeting a preset refreshing condition, and modifying an original starting address of a corresponding chip of the vehicle-mounted electronic control unit into a preset address; Writing the BOOT information header file and the BOOT code segment stored by the BOOT application program to be written into the BOOT of the vehicle-mounted electronic control unit in response to the completion of modification of the preset address, and carrying out writing verification on the written BOOT of the vehicle-mounted electronic control unit; and responding to successful verification of the swipe, modifying the preset address into the starting address of the BOOT code segment in the swipe BOOT, and resetting the swipe BOOT.
  2. 2. The method for self-updating a BOOT of an APP-based vehicle-mounted electronic control unit according to claim 1, wherein the preset brushing conditions include: the BOOT application program to be refreshed detects existence; the BOOT application program to be refreshed is matched with the hardware version of the vehicle-mounted electronic control unit; And the software version of the BOOT application program to be refreshed is inconsistent with the software version of the BOOT in the vehicle-mounted electronic control unit.
  3. 3. The method for self-updating a BOOT of an APP-based vehicle-mounted electronic control unit according to claim 1, wherein an address space occupied by executing the BOOT application to be refreshed and an address space occupied by the BOOT application to be refreshed are provided in an address space architecture of the BOOT application to be refreshed.
  4. 4. The method for self-updating BOOT of the APP-based on vehicular electronic control unit according to claim 3, wherein the address space occupied by the BOOT application program to be refreshed is the same as the address space architecture of the BOOT of the vehicular electronic control unit, and the address space architecture of the BOOT of the vehicular electronic control unit comprises a BOOT information header file space, a BOOT code segment space and a BOOT verification information space.
  5. 5. The method for self-updating a BOOT of an APP-based vehicle-mounted electronic control unit according to claim 1, wherein writing the BOOT information header file and the BOOT code segment stored by the BOOT application to be refreshed to the BOOT of the vehicle-mounted electronic control unit comprises: Determining erasure parameters stored in a BOOT information header file in the BOOT application program to be refreshed, wherein the erasure parameters comprise erasure address positions and erasure position lengths for erasing address spaces corresponding to BOOT space architectures, and the BOOT space architectures are address architectures of BOOTs of the vehicle-mounted electronic control units; Invoking a memory driver of the vehicle-mounted electronic control unit to erase a BOOT information header file space and a BOOT code segment space in the BOOT space architecture according to the erasing parameters respectively to obtain a first target address space and a second target address space; Writing a BOOT information header file of the BOOT application program to be written in the first target address space; and writing the BOOT code segment of the BOOT application program to be refreshed in the second target address space.
  6. 6. The method for self-updating a BOOT of an APP-based vehicle-mounted electronic control unit of claim 1, wherein the performing a swipe check on a swipe BOOT of the vehicle-mounted electronic control unit comprises: And verifying the BOOT after the vehicle-mounted electronic control unit is subjected to the brushing according to preset brushing verification conditions, wherein the brushing verification conditions comprise: The version of the BOOT application program to be refreshed is consistent with the version of the refreshed BOOT; The target check value is consistent with the check value in the BOOT check information space in the BOOT application program to be written, and the target check value is calculated according to the BOOT code segment written in the BOOT after being written; when the BOOT after the brushing meets the brushing verification condition, determining that the brushing verification is successful; And when the BOOT after the brushing does not meet the brushing verification condition, determining that the brushing verification fails.
  7. 7. The method of APP-based on-board electronic control unit self-updating BOOT of claim 1, further comprising: In response to successful writing verification, writing a target verification value obtained by calculation according to the written BOOT code segment in writing verification into a BOOT verification information space corresponding to the written BOOT; and resetting the preset address to be the original starting address of the corresponding chip of the vehicle-mounted electronic control unit in response to the failure of the refreshing verification.
  8. 8. The utility model provides a device of on-vehicle electrical control unit self-updating BOOT based on APP which characterized in that includes: The pre-refreshing module is used for responding to the fact that the BOOT application program to be refreshed meets preset refreshing conditions, and modifying an original starting address of a corresponding chip of the vehicle-mounted electronic control unit into a preset address; The brushing module is used for writing the BOOT information head file and the BOOT code segment stored by the BOOT application program to be brushed into the BOOT of the vehicle-mounted electronic control unit and brushing and checking the BOOT after the brushing of the vehicle-mounted electronic control unit in response to the completion of the modification of the preset address; and the post-processing module is used for responding to successful verification of the brushing, modifying the preset address into the starting address of the BOOT code section in the BOOT after the brushing, and resetting the BOOT after the brushing.
  9. 9. An electronic device comprising a memory and a processor, wherein, The memory is used for storing programs; the processor is coupled to the memory for executing the program stored in the memory to implement the steps of the method of self-updating a BOOT of an APP-based vehicle-mounted electronic control unit as claimed in any one of claims 1 to 7.
  10. 10. A non-transitory computer readable storage medium having stored thereon a computer program, wherein the computer program when executed by a processor implements the steps of the method of APP-based on-board electronic control unit self-updating BOOT of any of claims 1 to 7.

Description

Method and device for self-updating BOOT of vehicle-mounted electronic control unit based on APP Technical Field The invention relates to the technical field of vehicle control, in particular to a method for automatically updating BOOT of a vehicle-mounted electronic control unit based on APP. Background An operation BOOT (BOOT) program of a vehicle-mounted electronic control power supply (Electronic Control Unit, ECU) guides the controller to complete initialization and load a core bottom program of an application program, and the software stability of the controller directly determines the running state of the controller. In the prior art, a main stream method for updating a BOOT program of a vehicle-mounted electronic control unit comprises the following modes, namely, one mode is to carry out brushing by a special brushing tool, such as lauterbach, iSYSTEM and the like. Any software can be written and written in the method, but the method needs to be directly connected with a debugging port of a circuit board, a mass-production controller is limited by an information security function, the debugging port is difficult to be externally arranged, and a large amount of manpower is needed for offline updating, so that the method has a great limitation. Secondly, the method is performed by a special BOOT updating program, and the method does not need professional tools, but only can be performed on line by professional technicians to update. This also requires recall of the vehicle, which is very unfriendly to the perception of the user. Thirdly, the controller AB surface backup software is used for writing, and the writing can be performed through self-updating BOOT. However, this refresh mode divides the memory cells of the chip into 2 copies, and operates while being used for refresh and backup. Such an update approach also requires half of the chip memory space to be inoperable and is not suitable for use with controllers having high cost requirements. Disclosure of Invention In view of the foregoing, it is necessary to provide a method for self-updating a BOOT of a vehicle-mounted electronic control unit based on APP, so as to solve the technical problems of low efficiency and greater customer perceptibility of the conventional vehicle-mounted electronic control unit due to the dependency of BOOT program updating on a special device. In order to solve the problems, the invention provides a method for self-updating BOOT of an APP-based vehicle-mounted electronic control unit, which comprises the following steps: Responding to the BOOT application program to be refreshed meeting a preset refreshing condition, and modifying an original starting address of a corresponding chip of the vehicle-mounted electronic control unit into a preset address; Writing the BOOT information header file and the BOOT code segment stored by the BOOT application program to be written into the BOOT of the vehicle-mounted electronic control unit in response to the completion of modification of the preset address, and carrying out writing verification on the written BOOT of the vehicle-mounted electronic control unit; and responding to successful verification of the swipe, modifying the preset address into the starting address of the BOOT code segment in the swipe BOOT, and resetting the swipe BOOT. In one possible implementation manner, the preset brushing condition includes: the BOOT application program to be refreshed detects existence; the BOOT application program to be refreshed is matched with the hardware version of the vehicle-mounted electronic control unit; And the software version of the BOOT application program to be refreshed is inconsistent with the software version of the BOOT in the vehicle-mounted electronic control unit. In one possible implementation manner, an address space occupied by the to-be-refreshed BOOT application program and an address space occupied by the to-be-refreshed BOOT application program are set in an address space architecture of the to-be-refreshed BOOT application program. In one possible implementation manner, the address space occupied by the to-be-written BOOT application program is the same as the address space architecture of the BOOT of the vehicle-mounted electronic control unit, and the address space architecture of the BOOT of the vehicle-mounted electronic control unit comprises a BOOT information header file space, a BOOT code segment space and a BOOT verification information space. In one possible implementation manner, the writing the BOOT information header file and the BOOT code segment stored in the BOOT application to be written to the BOOT of the on-board electronic control unit includes: Determining erasure parameters stored in a BOOT information header file in the BOOT application program to be refreshed, wherein the erasure parameters comprise erasure address positions and erasure position lengths for erasing address spaces corresponding to BOOT space architectures, and