[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

WO2023272570A1 - 电子控制单元ecu更新的方法、ecu和终端 - Google Patents

电子控制单元ecu更新的方法、ecu和终端 Download PDF

Info

Publication number
WO2023272570A1
WO2023272570A1 PCT/CN2021/103466 CN2021103466W WO2023272570A1 WO 2023272570 A1 WO2023272570 A1 WO 2023272570A1 CN 2021103466 W CN2021103466 W CN 2021103466W WO 2023272570 A1 WO2023272570 A1 WO 2023272570A1
Authority
WO
WIPO (PCT)
Prior art keywords
ecu
file
version
update
app
Prior art date
Application number
PCT/CN2021/103466
Other languages
English (en)
French (fr)
Inventor
张涛
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Priority to CN202180001811.1A priority Critical patent/CN113853580A/zh
Priority to PCT/CN2021/103466 priority patent/WO2023272570A1/zh
Priority to EP21947524.1A priority patent/EP4361798A4/en
Publication of WO2023272570A1 publication Critical patent/WO2023272570A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • G06F8/658Incremental updates; Differential updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Definitions

  • the present application relates to the field of vehicles, and specifically relates to a method for updating an ECU, an ECU and a terminal.
  • an electronic control unit In a smart vehicle, an electronic control unit (ECU) is used to execute programs to process data. It can be understood as a microcomputer controller in the field of automatic driving, and can also be called a vehicle-specific single-chip microcomputer. Each ECU includes a processor and a memory, and the processor is used to execute programs stored in the memory to achieve specific functions.
  • the application program in the ECU can be updated by means of hardware replacement, near-end upgrade, over the air (OTA) etc., so as to upgrade or repair the application program.
  • OTA over the air
  • the present application provides an ECU update method, an ECU and a terminal, which improve the flexibility of the ECU update, improve the efficiency of the ECU update, and reduce the cost.
  • a method for updating an ECU comprising: a second ECU obtains a first file from a first ECU, and the first file is a file stored locally by the first ECU; the second ECU updating according to the first file; the first ECU and the second ECU are located in the same terminal.
  • the files described in this application may also be called version files, programs, program files, software, or software versions, etc., which represent programs or software that can be used or run on the ECU.
  • the first file may be an application program APP file, and is a version file of an APP that has not been updated by the first ECU.
  • the first file can be understood as an object file or an object program, and the second file below can be understood as an original file or an original program.
  • the second ECU can be updated to the first file stored locally by the first ECU, without the need for each ECU to obtain the first file from the external network, which improves the efficiency of the file in the ECU. Update flexibility.
  • the obtaining the first file from the first ECU by the second ECU includes: obtaining the file by the second ECU from the first ECU if the update requirement is met.
  • the first file, the update requirement includes that the version of the first file is higher than the version of the second file, and the second file is a file used when the second ECU is not updated.
  • the second file is an APP version file that can be updated by the second ECU.
  • the first ECU sends the first file to the second ECU when the update requirements are met, which can make the file versions in the first ECU and the second ECU match and compatible, thereby enhancing the compatibility between ECUs , Enhanced functional coordination between ECUs.
  • Newer versions of the files have better performance.
  • Each ECU uses the newer version of the first file to process the data, which can improve the processing performance.
  • each ECU uses the same version of the file to process the data, and the processing results are consistent.
  • the method further includes: the second ECU sends version information to the first ECU, where the version information is used to indicate the version of the second file;
  • the second ECU obtaining the first file from the first ECU includes: receiving the first file, the first file is determined by the first ECU according to the version information to meet the update requirement sent under the circumstances.
  • the first ECU may determine whether to update the second file according to the version information sent by the second ECU.
  • the first ECU can judge whether to send the first file to the second ECU without installing additional equipment for judgment, which is relatively simple to implement and can reduce costs.
  • the first ECU can regularly check whether other ECUs of the terminal can work normally or check whether the versions of other ECUs are lower, so that the first ECU can confirm whether to send the first file to other ECUs according to actual conditions.
  • the second ECU obtaining the first file from the first ECU includes: when the second file is abnormal, the second ECU obtains the first file from the first ECU The first file is acquired, and the second file is a file used when the second ECU is not updated.
  • the first ECU sends the target program to the second ECU, so that the abnormal file in the second ECU can be updated in time.
  • the method before the second ECU updates according to the first file, the method further includes: the second ECU detects whether the second file is normal.
  • the second ECU may also detect whether the first file is normal.
  • the second ECU detects whether the second file in the second ECU is normal, and the detection method is relatively simple.
  • the second ECU can also detect whether the updated file is abnormal.
  • the second ECU can periodically detect whether the updated file is abnormal, so that it can be detected in time whether the second ECU can be updated normally. And if it can be updated normally, whether it can work normally, so as to ensure the normal operation of the ECU and improve the reliability of the ECU.
  • the second ECU detects whether the updated file is abnormal, and can re-acquire the file if the updated file is abnormal, thereby ensuring the normal operation of the ECU and improving the reliability of the ECU.
  • the second ECU detecting whether the first file is normal includes: the second ECU performing an integrity check on the first file.
  • Whether the first file is normal can be detected through the integrity check, and an effective method for judging whether the file is normal is provided.
  • the first file is acquired by the first ECU from a communication box TBOX of the terminal. That is to say, the first file may be obtained by the first ECU from the external network (network) regularly or irregularly through OTA.
  • the terminal obtains the first file from the external network through OTA, and further sends the first file to the first ECU through the TBOX and/or gateway of the terminal.
  • Sending the first file can update the program in the first ECU; when sending the first file to the second ECU through the first ECU, TBOX does not need to send the same file to each ECU. That is to say, the TBOX does not need to obtain and forward the first file repeatedly, thereby saving transmission resources for updating the ECU.
  • the method further includes: before the second ECU acquires the first file from the first ECU, determining whether the second ECU needs to acquire the first file.
  • Whether the second ECU needs to obtain the first file can be judged by the first ECU or the second ECU.
  • the second ECU acquires first version information, where the first version information is used to indicate the version of the first file; according to the first version information, the The second ECU compares the version of the first file with the version of the second file; the acquisition of the first file by the second ECU from the first ECU includes: when the version of the second file is lower than the version of the first file version of the file, the second ECU obtains the first file from the first ECU.
  • the method further includes: before the second ECU obtains the first file from the first ECU, the second ECU detects whether there is an abnormality in the second file;
  • the second ECU obtaining the first file from the first ECU includes: when the second file is abnormal, the second ECU obtaining the first file from the first ECU.
  • the second ECU detects whether the second file is abnormal, and acquires the first file when the second file is abnormal, so that the second file can be updated in time.
  • a method for updating an ECU comprising: a first ECU reading a first file stored locally by the first ECU; the first ECU sending the first file to a second ECU, In order for the second ECU to update the second file to the first file, the first ECU and the second ECU are located in the same terminal.
  • the first ECU sends the first file stored in the storage area corresponding to the first ECU to the second ECU to update the second file in the second ECU, and the second ECU utilizes the communication with the first ECU in the terminal
  • the file can be updated through communication, without the need to obtain the first file from outside the terminal, which improves the flexibility of ECU update.
  • the ECU method provided by the present application can improve efficiency and reduce cost.
  • sending the first file to the second ECU by the first ECU includes: sending the first file to the second ECU if the update requirement is met.
  • the first file is sent, and the update requirement includes that the version of the first file is higher than the version of the second file, and the second file is a file used when the second ECU is not updated.
  • the first ECU can send the first file to the second ECU when the update requirements are met, so that the file versions in the first ECU and the second ECU can be matched and compatible, avoiding functional inconsistency, or even conflict.
  • Newer versions of the files have better performance.
  • Each ECU uses the newer version of the first file to process the data, which can improve the processing performance.
  • each ECU uses the same version of the file to process the data, and the processing results are consistent.
  • the method further includes: the first ECU receiving version information sent by the second ECU, the version information being used to indicate the version of the second file, The first ECU judges whether the update requirement is met according to the version information.
  • the first ECU can determine whether the second file needs to be updated according to the version information sent by the second ECU.
  • the first ECU can judge whether to send the first file to the second ECU, and no additional equipment is required for the judgment, and the implementation is relatively simple.
  • the method further includes: the first ECU receiving the first file sent by a communication box T-BOX.
  • the first file can be sent to the first ECU through TBOX to update the program in the first ECU;
  • TBOX does not need to send the same file to each ECU. That is to say, the TBOX does not need to obtain the first file repeatedly, thereby reducing the occupation of transmission resources.
  • the terminal includes a communication box T-BOX
  • the method further includes: the first ECU receiving the measurement information sent by the T-BOX; the first ECU sending first response information to the T-BOX, among multiple response information received by the T-BOX, the response time corresponding to the first response information is shorter than the response time corresponding to the second response message, and the second The response information is sent to the T-BOX by the second ECU after receiving the measurement information; the first file is forwarded by the T-BOX and transmitted to the first ECU.
  • T-BOX determines the first ECU with a shorter response time among multiple ECUs, and forwards the first file to the first ECU, which can reduce transmission delay and improve transmission efficiency.
  • the T-BOX can be used to forward the first file sent by the server.
  • the first ECU sending the target program to the second ECU includes: when the second file is abnormal, the first ECU sends the The second ECU sends the first file, and the second file is a file used when the second ECU is not updated.
  • the first ECU sends the target program to the second ECU, so that the abnormal file in the second ECU can be updated in time.
  • the method further includes: the first ECU sends version query information to the second ECU; the first ECU sends the target program to the second ECU, Including: when the first ECU has not received the version information sent by the second ECU within a preset period of time after the version query information is sent, the first ECU determines that the original program is abnormal, and the The above version information is used to indicate the version of the original program.
  • the second ECU When the second ECU does not respond to the version query information sent by the first ECU within a preset time period, it can be determined that the second ECU is abnormal, so as to update the abnormal program in the second ECU in time.
  • the method further includes: the first ECU detecting whether the first file is normal; the first ECU sending the first file to the second ECU, including : When the first file is normal, the first ECU sends the first file to the second ECU.
  • the first file is sent to the second ECU, so that the second ECU updates the second file to the first file, which improves the probability that the updated first file in the second ECU is normal, and avoids For abnormal file transfer, reduce resource usage.
  • the first ECU detecting whether the first file is normal includes: the first ECU performing an integrity check on the first file.
  • Whether the first file is normal can be detected through the integrity check, and an effective method for judging whether the file is normal is provided.
  • the first file is an application program APP file.
  • an ECU including various functional modules for implementing the ECU updating method described in the first aspect or the second aspect.
  • an ECU including a communication interface and a processor, the communication interface is used for the ECU to exchange information with other devices, and when the program instructions are executed in the processor, the ECU is made to execute the first aspect Or the ECU update method described in the second aspect.
  • a computer program storage medium wherein the computer program storage medium has program instructions, and when the program instructions are executed, the method described in the first aspect or the second aspect is executed.
  • a chip is provided.
  • the chip system includes at least one processor.
  • program instructions are executed in the at least one processor, the method described in the first aspect or the second aspect is executed.
  • the chip may further include a memory, the memory stores instructions, the processor is configured to execute the instructions stored in the memory, and when the instructions are executed, the The processor is configured to execute the method in any one of the implementation manners of the first aspect or the second aspect.
  • the aforementioned chip may specifically be a field-programmable gate array (field-programmable gate array, FPGA) or an application-specific integrated circuit (application-specific integrated circuit, ASIC).
  • FPGA field-programmable gate array
  • ASIC application-specific integrated circuit
  • a seventh aspect provides a terminal, including a first ECU and a second ECU, the second ECU is used to execute the method described in the first aspect, and the first ECU is used to execute the method described in the second aspect.
  • the terminal is a vehicle.
  • Fig. 1 is a functional block diagram of a vehicle to which the embodiment of the present application is applicable.
  • Fig. 2 is a schematic structural diagram of a communication method.
  • Fig. 3 is a schematic flowchart of an ECU updating method provided by an embodiment of the present application.
  • Fig. 4 is a schematic flowchart of another ECU updating method provided by the embodiment of the present application.
  • Fig. 5 is a schematic flowchart of a method for upgrading an ECU program provided by an embodiment of the present application.
  • Fig. 6 is a schematic structural diagram of an ECU provided by an embodiment of the present application.
  • Fig. 7 is a schematic structural diagram of another ECU provided by the embodiment of the present application.
  • Fig. 8 is a schematic structural diagram of another ECU provided by the embodiment of the present application.
  • the ECU update method provided in the embodiment of the present application can be applied to intelligent driving vehicles.
  • the technical solutions of the embodiments of the present application will be introduced below with reference to the accompanying drawings.
  • Fig. 1 is a functional block diagram of a vehicle to which the embodiment of the present application is applicable.
  • the vehicle 100 may be an intelligent driving vehicle, and the configuration of the vehicle 100 may be a fully or partially automatic driving mode.
  • the vehicle 100 can control the own vehicle while in the automatic driving mode, and can determine the current state of the vehicle and its surrounding environment through human operation, determine the possible behavior of at least one other vehicle in the surrounding environment, and A confidence level corresponding to the likelihood that the other vehicle will perform the possible action is determined, and the vehicle 100 is controlled based on the determined information. While the vehicle 100 is in the autonomous driving mode, the vehicle 100 may be configured to operate without human interaction.
  • Various subsystems may be included in the vehicle 100, such as a travel system 110, a sensing system 120, a control system 130, and the like.
  • vehicle 100 may include more or fewer subsystems, and each subsystem may include multiple elements.
  • each subsystem and element of the vehicle 100 may be interconnected by wire or wirelessly.
  • Propulsion system 110 may include components for providing powered motion to vehicle 100 .
  • the sensing system 120 may include several sensors that sense information about the environment around the vehicle 100 .
  • Control system 130 controls the operation of vehicle 100 and its components.
  • FIG. 1 should not be construed as limiting the embodiment of the present application.
  • the vehicle 100 may be an autonomous vehicle traveling on the road, which can recognize objects in its surroundings to determine adjustments to the current speed.
  • Objects may be other vehicles, traffic control devices, or other types of objects.
  • each identified object may be considered independently and based on the object's respective characteristics, such as its current speed, acceleration, distance to the vehicle, etc., may be used to determine the speed at which the autonomous vehicle is to adjust.
  • the vehicle 100 or a computing device associated with the vehicle 100 may predict the performance of the identified object based on the characteristics of the identified object and the state of the surrounding environment (e.g., traffic, rain, ice on the road, etc.). Behavior.
  • the above-mentioned vehicle 100 may be a car, truck, motorcycle, bus, boat, airplane, helicopter, lawn mower, recreational vehicle, playground vehicle, construction equipment, tram, golf cart, train, trolley, etc. Examples are not particularly limited.
  • these electronic components can be divided into multiple domains such as the power domain, the intelligent driving domain, and the intelligent cockpit domain.
  • Each domain may include at least one electronic control unit (ECU).
  • ECU electronice control unit
  • the electronic components in the travel system 110 belong to the power domain, and the electronic components in the sensing system 120 and the control system 130 belong to the intelligent driving domain.
  • Electronic components in the smart cockpit domain are used to support office, leisure, and entertainment activities in dynamic commuting scenarios.
  • Each ECU in the same domain can communicate through the communication bus
  • the ECU includes a processor (such as a microcontroller unit (MCU), etc.), a memory, and an input/output interface (input/output, I/O).
  • the ECU may also include one or more of an analog to digital converter (A/D), a shaping integrated circuit, a driving integrated circuit, and the like.
  • A/D analog to digital converter
  • the update frequency of the application program (Application, APP) run by the vehicle-mounted ECU is constantly increasing. Due to the abnormal triggering of the erasing operation of the storage area of the application program, or the failure during the upgrade process, the application program itself may have defects, and the application program needs to be repaired.
  • the application program in the vehicle ECU can be upgraded or repaired.
  • the application program in the ECU is the application program stored in the memory.
  • the parts where the ECU is located can be removed from the vehicle, and a hardware module with a new application program can be reinstalled.
  • Replacement of hardware modules is costly. In order to disassemble and assemble the hardware, it is time-consuming to go to a professional vehicle repair shop or ask a professional to provide on-site service.
  • the application program stored in the ECU memory in the replaced hardware module may not be compatible with the application program stored in the memory of other on-board ECUs in the vehicle, resulting in the failure of the on-board system to operate normally.
  • the on-board system can be connected with the diagnostic instrument or the specific upgrade equipment of the original equipment manufacturer (OEM) through the communication cable, and the new application program stored on the diagnostic instrument can be transmitted to the to-be-upgraded or to-be-upgraded device.
  • OEM original equipment manufacturer
  • the application program upgrade or repair of the ECU is realized.
  • the application program stored in the OEM cloud server can be transmitted to a specific ECU through a wireless network through a communication box (telematics box, T-Box), gateway and other devices in the vehicle system, thereby realizing ECU Application upgrades and fixes.
  • a communication box telephone box, T-Box
  • gateway gateway
  • the gateway is the central node of in-vehicle communication, which connects most of the electronic control units inside the vehicle, supports various bus systems, and can realize cross-domain function integration, basic routing communication and protocol translation, in-vehicle data extraction and integration, and safe deployment , Provide diagnostic communication services and network services, making vehicle interconnection services a reality.
  • the communication box (telematics box, T-Box), also known as the vehicle information box, is mainly used to provide the interaction between the gateway and the Internet.
  • T-Box can belong to the communication domain.
  • An in-vehicle system can include multiple ECUs of the same type.
  • the hardware composition of multiple ECUs of the same type is the same, and the application program stored in the memory of each ECU of the same type is the same.
  • Each ECU in the vehicle system adopts OTA and near-end upgrade methods to upgrade and repair the application program, and the cost is relatively high.
  • the embodiments of the present application provide an ECU updating method and device.
  • the update software locally stored in the first ECU is forwarded to the second ECU, so that the second ECU is updated. Therefore, when there is a second ECU with a lower software version among the multiple ECUs in the terminal or the update software of the second ECU is damaged, so that the second ECU needs to be updated, it can be directly downloaded from other ECUs of the terminal, such as a higher software version.
  • the first ECU or the first ECU with intact software version obtain the updated software.
  • the above-mentioned software may also be referred to as software version, file, installation file, update file, program, or program file, etc., which means a program or software that can be used or run on the ECU.
  • the ECU described in this application is a kind of controller of the terminal, and the name of the controller is not limited in this application.
  • the functions of the ECU described in this application include controlling the operating state of the terminal and/or collecting environmental data. For example, when the ECU is used in a vehicle, the ECU can control the driving state of the vehicle.
  • Fig. 3 is a schematic flowchart of an ECU updating method provided by an embodiment of the present application.
  • the terminal includes a first ECU and a second ECU.
  • the terminal may be one or more of devices such as a car, a vehicle-mounted device, and a vehicle-mounted chip.
  • the ECU update method 300 includes S320-S330.
  • the second ECU acquires the first file from the first ECU.
  • the first file is a file stored locally by the first ECU.
  • the first file is stored in a storage area corresponding to the first ECU.
  • the first file may be an application file.
  • Application files may also be called version files.
  • the first ECU can execute the first file to realize the functions of the application program.
  • the second ECU is updated according to the first file.
  • the second file is a file stored locally by the second ECU.
  • the second ECU can be updated to the first file stored locally by the first ECU, without requiring each ECU to obtain the first file from the external network, Improved flexibility of file update in ECU.
  • the first file can be understood as the target program, and the second file can be understood as the original program.
  • the second ECU can obtain the first file stored locally by the first ECU.
  • the second ECU may acquire the first file locally stored by the first ECU when the second file is abnormal.
  • the second ECU may perform an integrity check on the second file. Integrity verification can be performed based on cyclic redundancy check (cyclic redundancy check, CRC), cipher-based message authentication code (cipher-based message authentication code, CMAM) and other methods. Whether the second file is abnormal can be determined through the integrity check.
  • CRC cyclic redundancy check
  • CMAM cipher-based message authentication code
  • the second ECU may also acquire the first file stored locally by the first ECU when the version of the second file is lower than the version of the first file.
  • the second ECU can obtain the first version information from the first ECU.
  • the first version information is used to indicate the version of the first file.
  • the second ECU may compare the version of the first file with the version of the second file according to the first version information. If it is determined that the version of the first file is higher than the version of the second file, the second ECU may obtain the first file locally stored by the first ECU.
  • the second ECU can send the second version information of the second file of the second ECU itself to the first ECU, and the first ECU makes a judgment according to the first version information of the first ECU and the second version information of the second ECU , when the first ECU determines that the version of the first file is higher than the version of the second file, the second ECU may acquire the first file locally stored by the first ECU.
  • S310 Before S320, S310 can be performed.
  • the first ECU reads the first file locally stored by the first ECU.
  • the first ECU may send the first file to the second ECU.
  • each ECU does not need to have the ability to read the local storage of other ECUs, and the second ECU can update the second file by receiving the first file from the first ECU.
  • the first ECU may also send the file identification to the second ECU.
  • the second ECU may update the second file to the first file according to the file identifier.
  • the first file and the second file may be files of the same type and have the same identifier.
  • the second ECU can acquire the first file.
  • the update requirement may be that the version of the first file is higher than the version of the second file. Therefore, the versions of the files for realizing the same or similar functions in each ECU are the same and are the latest versions.
  • each ECU uses the latest version of the file to process the data, which can improve the processing performance.
  • each ECU uses the same version of the file to process the data, and the processing results have a high consistency.
  • the second ECU may periodically or irregularly send version information to the first ECU.
  • the first ECU may send version query information to the second ECU.
  • the version query information is used to indicate that the second ECU sends version information to the first ECU.
  • the second ECU may send version information to the first ECU.
  • the first ECU may periodically or irregularly send version query information to the second ECU.
  • a terminal in other embodiments, includes a processing system and a control device.
  • the processing system includes a first ECU and a second ECU.
  • the control device may be a device independent of each ECU in the processing system.
  • the first ECU may send the first version information to the control device, and the second ECU may send the second version information to the control device.
  • the first version information is used to indicate the version of the first file
  • the second version file is used to indicate the version of the second file.
  • the control device may control the processing system to perform S320 to S330.
  • the control device may send version query information to each ECU in the processing system. After each ECU receives the version query information, it can send version information representing the ECU to the control device, so as to represent the version of the file stored locally in the ECU. Alternatively, each ECU may periodically or irregularly send the version information of the ECU to the control device.
  • the control device may control the processing system to perform S310 to S330 according to the received version information sent by each ECU. For example, the control device may control the processing system to perform S310 to S330 in at least one case: the version information of the second ECU is not received, it is determined that the second file stored locally by the second ECU is abnormal, and it is determined that the second file is updated to meet the requirements .
  • the first ECU sends the first file to the second ECU.
  • the first ECU sends the first file to the second ECU, and the abnormal file in the second ECU can be updated in time.
  • the second ECU may send abnormality indication information to the first ECU, where the abnormality indication information is used to indicate that the second file is abnormal.
  • the first ECU may determine that the second file needs to be updated according to the received abnormality indication information, and send the first file to the second ECU.
  • the first ECU may send version query information to the second ECU.
  • the version query information is used to instruct the second ECU to send version information to the first ECU
  • the version information sent by the second ECU is used to indicate the version of the second file locally stored by the second ECU.
  • the second ECU may not send the version information to the first ECU. If the first ECU has not received the version information sent by the second ECU within the preset period of time after the version query information is sent, the first ECU determines that the second file is abnormal, and sends the second file to the second ECU. a file.
  • the first ECU inquires about the version of the second file in the second ECU, it can be determined whether the second file is abnormal, so as to update the abnormal second file in the second ECU in time.
  • the first ECU can receive the first file sent by the TBOX.
  • TBOX is located in the same terminal as the first ECU and the second ECU. That is, the first file may be obtained by the first ECU from the external network through OTA on a regular or irregular basis.
  • the first ECU can not only use the first file to update itself, but also forward the first file to other ECUs of the terminal that need to be updated, thereby improving the update efficiency of the terminal ECU and saving network transmission resources.
  • TBOX can forward the information and files sent by the server to each ECU.
  • the server may be one or more of different types of servers such as physical servers and virtual servers, and may have processing functions and sending and receiving functions.
  • the server can be, for example, an OEM cloud server.
  • the first ECU may be any one of multiple ECUs of the same type, and receives the first file sent by the server. Files for realizing the same function can be stored in multiple ECUs of the same type.
  • the first ECU may be the ECU that responds fastest to the measurement information sent by the T-BOX.
  • Terminals include T-BOX.
  • T-BOX can send measurement information to each similar ECU in the terminal.
  • Each ECU sends response information to the T-BOX after receiving the measurement information sent by the T-BOX.
  • the T-BOX can determine the ECU with the shortest response time as the first ECU, and forward the first file sent by the server to the first ECU.
  • the first ECU may be the main ECU.
  • the first ECU can receive the measurement information sent by the T-BOX.
  • the first ECU may send first response information to the T-BOX.
  • the response time corresponding to the first response message is shorter than the response time corresponding to the second response message.
  • the second response information is sent to the T-BOX by the second ECU after receiving the measurement information. Afterwards, the first ECU receives the first file sent by the T-BOX.
  • T-BOX determines the first ECU with a shorter response time among multiple ECUs, and T-BOX forwards the first file sent by the server to the first ECU. files, which can reduce transmission delay and improve transmission efficiency.
  • Fig. 4 is a schematic flowchart of an ECU updating method provided by an embodiment of the present application.
  • the application program APP of ECU refers to the ECU program used to complete one or more specific tasks.
  • the following is an example of updating the application program APP in the ECU.
  • the terminal includes multiple ECUs of the same type.
  • the plurality of ECUs of the same type includes ECU 1 and ECU 2.
  • S411 When each ECU is powered on, S411 can be performed.
  • the ECU performs integrity check on the APP file stored in the storage area of the ECU.
  • a boot loader BootLoader can be used to initialize the ECU and guide the running of APP files.
  • the APP file stored in the storage area of each ECU can also be understood as the APP file of the ECU, that is, the APP file currently used by the ECU.
  • the ECU can perform an integrity check on the APP file stored in the storage area corresponding to the ECU. Integrity detection may also be referred to as integrity verification.
  • BootLoader is stored in a storage area with protection function. After leaving the factory, the data stored in the protected memory area will not be changed. Therefore, the BootLoader is not easily damaged and will not be upgraded after leaving the factory.
  • the ECU runs the APP file. That is to say, after the APP file passes the integrity test, the ECU jumps to the APP file after completing BootLoader booting, that is, the ECU starts to execute the APP file to realize the business function of the APP file.
  • the ECU sends version query information to other similar ECUs.
  • the version query information is used to request the version information of the APP file in the other similar ECUs.
  • the ECU 2 sends version response information to the ECU 1.
  • the version response information sent by the ECU 2 is used to indicate the version information of the APP file 2 in the ECU 2.
  • ECU 2 can send abnormal information to ECU 1 when receiving the version query information sent by ECU 1.
  • the abnormal information is used to indicate that there is an abnormality in the complete new inspection of the APP file 2 in the ECU 2.
  • ECU 2 may not send version response information to ECU 1.
  • the ECU 1 judges whether the APP file 2 in the ECU 2 needs to be updated.
  • ECU 1 can determine that the APP file 2 in ECU 2 needs to be updated: ECU 1 receives the abnormal information sent by ECU 2, and ECU 1 does not receive the message sent by ECU 2 after the preset time after S421 The version response information sent by ECU 2 and the version response information sent by ECU 2 meet the update conditions.
  • the ECU 1 when receiving the version response information sent by the ECU 2, the ECU 1 can judge whether the APP file 2 in the ECU 2 needs to be updated according to the version information carried in the version response information, that is, whether the update requirement is met.
  • the update requirement may be that the version of the APP file 2 indicated by the version information carried in the version response information is lower than the version of the APP file 1 in the ECU 1.
  • ECU 1 determines that the APP file 2 in ECU 2 needs to be updated.
  • ECU 1 judges that the APP file 2 in ECU 2 does not need to be updated, ECU 1 can perform S421 again periodically or irregularly. That is to say, ECU 1 can regularly or irregularly detect whether the APP files in other similar ECUs need to be updated.
  • ECU 1 can determine to update APP file 2 in ECU 2.
  • the update condition may include at least one of a preset voltage range of the ECU 2, a preset maximum terminal speed, and the like. It can be judged by ECU 1 or ECU 2 whether ECU 2 meets the updating conditions.
  • the preset maximum terminal speed may be the driving speed of the vehicle.
  • Updating the APP file 2 in the ECU 2 when the voltage of the ECU 2 satisfies the preset voltage range can reduce the possibility of errors in the ECU 2 storing the received APP file 2. Updating the APP file 2 in the ECU 2 when the terminal speed is less than the preset maximum terminal speed can reduce the impact of the ECU 2 update on the driving safety of the vehicle. In some cases, the preset maximum vehicle speed can be 0, that is, the ECU is updated when the vehicle is not running.
  • ECU 1 can send an update condition check request to ECU 2 to instruct ECU 2 to obtain update detection information such as the working voltage of ECU 2 and the speed of the vehicle where it is located.
  • ECU 2 can perform detection to obtain update detection information and send update detection information to ECU 1.
  • the ECU 1 can judge whether the update condition is met according to the update detection information.
  • ECU 2 can judge whether the update condition is satisfied according to the update detection information, and send the judgment result of whether the update condition is satisfied to ECU 1.
  • the ECU 1 can perform detection to obtain update detection information, and determine whether the update condition is met.
  • part of the information in the update detection information can be detected by ECU 1, and other information can be detected by ECU 2.
  • ECU 1 can send an update condition check request to ECU 2 to instruct ECU 2 to detect the operating voltage of ECU 2.
  • ECU 1 can detect the speed of the vehicle where it is located. Afterwards, ECU1 can determine whether the update condition is met according to the detected vehicle speed and the working voltage of ECU 2 sent by ECU 2.
  • ECU 1 determines that the update condition is not met. If ECU 1 determines not to update, ECU 1 can continue to run the APP file 1. When ECU 1 determines that the update condition is not met, the update process ends. In some embodiments, when the ECU 1 determines that the update condition is not met, the ECU 1 may perform S424 again after a preset period of time.
  • ECU 1 determines to update the APP file 2 in ECU 2.
  • S431 can be performed.
  • ECU 1 sends an update instruction to ECU 2.
  • the ECU 1 determines that the updating conditions are met, the ECU 1 can stop running the APP file 1 and run the BootLoader.
  • ECU 2 If the detection result of ECU 2 in S411 is normal, that is, ECU 2 is running the APP file 2, then ECU 2 performs S432 after receiving the update instruction.
  • the ECU 2 stops running the APP file 2.
  • ECU 2 can also run BootLoader.
  • ECU 1 performs identity verification with ECU 2.
  • ECU 1 can send an identity authentication request to ECU 2.
  • ECU 2 determines whether the identity of ECU 1 is legal according to the identity authentication request, and sends the result of judging whether the identity of ECU 1 is legal to ECU 1.
  • ECU 1 sends the APP file 1 to ECU 2.
  • ECU 1 reads the APP file 1 in the storage area of ECU 1, and sends the read APP file 1 to ECU 2.
  • ECU 2 can write APP file 1 sent by ECU 1 into the storage area of ECU 2, so as to update ECU 2 according to APP file 1.
  • ECU 1 can continue to run the APP file 1, and ECU 2 can read and run the APP file 1 in the storage area of ECU 2.
  • ECU 1 and ECU 2 can run BootLoader to guide the running of APP file 1.
  • ECU 1 after ECU 1 finishes sending the APP file 1 in S434, it can send a reset request to ECU 2.
  • ECU 2 can run BootLoader after receiving the reset request, and read and run the APP file 1 in the storage area.
  • the ECU 2 When the ECU 2 is running the BootLoader, the ECU 2 can perform an integrity check on the APP file 1 in the storage area. Thereby, ECU 2 can judge whether the updated APP file 1 is normal.
  • the ECU 2 can be updated when the APP file 2 of the ECU 2 is incomplete or the version is low.
  • ECU 2 may send abnormal indication information to other ECUs such as ECU 1.
  • ECU 1 can ignore the abnormal indication information after receiving the abnormal indication information sent by ECU 2. If the detection result of ECU 1 in S411 is normal, then ECU 1 can perform S424 and subsequent steps after receiving the abnormal indication information.
  • ECU 1 after ECU 1 receives the abnormal indication information, it determines to update in S424, and S431 may not be performed, that is, the update indication may no longer be sent to ECU 2. That is to say, after S424, S433 can be performed, and ECU 1 and ECU 2 perform identity authentication. And in the case of successful identity authentication, proceed to S434, ECU 1 sends the APP file 1 to ECU 2.
  • ECU 1 can also judge whether ECU 1 needs to be updated.
  • the ECU 1 can also judge whether the APP file 1 in the ECU 1 needs to be updated according to the version information carried in the version response information. For example, when the version of the APP file 1 in the ECU 1 is lower than the version of the APP file 2 indicated by the version information carried in the version response information, the ECU 1 determines that the APP file 1 in the ECU 1 needs to be updated.
  • ECU 1 can send APP file 1 request update information to ECU 2, so as to request ECU 2 to send the APP file 2 in ECU 2 to ECU 1.
  • ECU 2 can perform the steps performed by ECU 1 in S423-S434, and update the APP file 1 in ECU 1.
  • the ECU checks the integrity of its own APP file, and compares the version of the APP file between each ECU, so as to detect the ECU with abnormal APP file integrity detection results or the version of the APP file is lower
  • the ECU updates the APP files, and troubleshoots and upgrades the APP files in each ECU through the internal processing of the vehicle. Therefore, the ECU update method provided by the embodiment of the present application does not require going to a professional maintenance point or asking a professional to provide on-site service, and the terminal does not need to be connected to the Internet to update the APP file in the ECU, reducing the requirements for the external environment.
  • APP files are stored in the OEM's cloud server. To download it to the ECU, it needs to go through wireless transmission, T-BOX forwarding, gateway forwarding and other links.
  • APP files are transferred between ECUs inside the terminal, APP files can be transferred between ECUs in the same domain through a communication bus, and ECUs in different domains can be transferred through a communication bus.
  • the forwarding of the gateway can realize the transmission of APP files without wireless transmission and T-BOX forwarding, which reduces the transmission delay and improves the update efficiency.
  • the APP file in the updated ECU is newly downloaded from the outside of the vehicle, and the version of the APP file in other similar ECUs in the terminal may be different, and there may be incompatibility problems.
  • the ECU update method provided by the embodiment of the present application can use the latest version of the APP file stored in a certain ECU among the ECUs of the same type to update the APP files in other ECUs, thereby avoiding that the versions of the APP files in the ECUs of the same type are different. Fixed an incompatibility issue.
  • Fig. 5 is a schematic flowchart of a method for upgrading an ECU program provided by an embodiment of the present application.
  • the cloud server can send a new APP file to some of the ECUs of the same type.
  • the multiple ECUs of the same type execute the ECU update method shown in FIG. 4 , thereby completing the upgrade of each ECU. That is, when the ECU of the terminal needs to be updated, it is only necessary to download the APP file to some ECUs through OTA, such as ECU 1 shown in Figure 5, without downloading the update file to each ECU , saving network transmission resources.
  • ECU 1 itself can use the APP file to update, and ECU 1 can also forward the updated APP file to other ECUs so that other ECUs can update them.
  • APP files are updated.
  • multiple ECUs of the terminal do not need to obtain APP files through the external network (networked) in OTA mode every time they are updated, and can obtain APP files from the external network regularly or irregularly, and store
  • the ECU updates or forwards it to other ECUs so that other ECUs can update.
  • the update efficiency is greatly improved, and some ECUs can be updated without networking when updating, which reduces the dependence of the ECU update on the network.
  • the part of ECUs can be upgraded first through the ECU program upgrading method described in FIG. 5 .
  • this ECU is used in a vehicle.
  • the terminal includes T-BOX and multiple ECUs of the same type.
  • the plurality of ECUs of the same type includes ECU 1 and ECU 2.
  • T-BOX is used to communicate with devices other than terminals.
  • the terminal When the T-BOX is triggered by the outside world, the terminal starts to execute the ECU program upgrade method shown in Figure 5, that is, starts the APP file upgrade process.
  • the T-BOX is triggered by the outside world, which may be that the T-BOX receives a new APP file or an APP file upgrade request sent by the cloud server or other devices.
  • the T-BOX sends measurement information to multiple ECUs of the same type.
  • each ECU of the plurality of ECUs of the same type sends measurement response information to the T-BOX.
  • the T-BOX determines the ECU with the fastest transmission among the plurality of ECUs of the same type.
  • T-BOX determines the time interval corresponding to each ECU according to the difference between the sending time of sending measurement information to each ECU and the receiving time of receiving measurement response information sent by each ECU.
  • the corresponding ECU with the smallest time interval is the ECU with the smallest transmission time, which can also be understood as the part of the ECU with the fastest transmission.
  • the fastest-transmitting partial ECUs may include ECU 1, for example.
  • ECU 1 can be the main ECU.
  • the ECU, T-BOX or other in-vehicle electronic equipment can determine whether the update condition is met.
  • the updating conditions may include the maximum vehicle speed, the preset voltage range of the ECU operating voltage, and the like.
  • T-BOX can determine the ECU with the fastest transmission among multiple ECUs whose working voltage meets the preset voltage range.
  • the T-BOX may send measurement information to a plurality of ECUs whose operating voltages meet a preset voltage range.
  • the T-BOX sends a new APP file, namely APP file 1, to the one or more ECUs with the fastest transmission.
  • T-BOX sends APP file 1 to ECU 1 as an example for illustration.
  • ECU 1 may be running BootLoader or APP file.
  • T-BOX Before performing S520, T-BOX can send an upgrade request to ECU 1.
  • ECU 1 If ECU 1 is running the original APP file at the end of S513, after receiving the upgrade request, ECU 1 can stop running the original APP file and run BootLoader.
  • ECU 1 If ECU 1 is running BootLoader at the end of S513, ECU 1 keeps BootLoader running.
  • the program run by the ECU 1 is BootLoader, which reduces the possibility of errors in the ECU 1 receiving and storing the APP file 1.
  • T-BOX can also send a reset request to ECU 1.
  • ECU 1 can read APP file 1 and run it after receiving the reset request.
  • the multiple ECUs of the same type may execute S421 to S434 shown in FIG. 4 to upgrade the programs of each ECU in the terminal.
  • one or more steps in S421-S431 may be omitted.
  • T-BOX only upgrades one of the multiple ECUs of the same type, that is, ECU 1.
  • ECU 1 does not need to request and obtain the version of APP files in other ECUs. , save the communication between ECUs, and reduce the waste of resources.
  • the ECU program upgrade method of the embodiment of the present application Compared with the method of downloading a new APP file for each ECU from the cloud to upgrade, the ECU program upgrade method of the embodiment of the present application, multiple ECUs of the same type upgrade the APP, and some ECUs obtain new APP files from other ECUs, reducing the The number of downloads of new APP files from the cloud server saves wireless transmission resources and saves the time-consuming wireless transmission of repeatedly downloading the same APP file from the cloud server.
  • Fig. 6 is a schematic structural diagram of an ECU provided by an embodiment of the present application.
  • the ECU 2000 includes a reading module 2010 and a transceiver module 2020.
  • the reading module 2010 is configured to read the first file stored locally.
  • the transceiver module 2020 is configured to send the first file to the second ECU, so that the second ECU is updated, and the first ECU and the second ECU are located in the same terminal.
  • the first ECU sends the first file to the second ECU when the update requirement is met, the update requirement includes that the version of the first file is higher than the version of the second file,
  • the second file is a file used when the second ECU is not updated.
  • the transceiving module 2020 is further configured to receive version information sent by the second ECU, where the version information is used to indicate the version of the second file.
  • the ECU 2000 also includes a processing module, and the processing module is used to judge whether the update requirement is met according to the version information.
  • the transceiver module 2020 is also configured to receive the first file sent by the communication box T-BOX.
  • the transceiver module 2020 is configured to, in the case that the second file is abnormal, the first ECU sends the first file to the second ECU, and the second file is The file to use when updating.
  • the transceiver module 2020 is further configured to send version query information to the second ECU.
  • the ECU 2000 may also include a processing module, configured to determine that the second file is abnormal if the ECU 2000 does not receive the version information from the second ECU within a preset period of time after the version query information is sent , the version information is used to indicate the version of the second file.
  • the ECU 2000 may also include a processing module, which is used to detect whether the first file is normal.
  • the transceiving module 2020 is further configured to, if the first file is normal, the first ECU sends the first file to the second ECU.
  • the processing module is configured to perform integrity check on the first file.
  • the first file is an application program APP file.
  • Fig. 7 is a schematic structural diagram of an ECU provided by an embodiment of the present application.
  • the ECU 4000 includes an acquisition module 4010 and an update module 4020.
  • the acquiring module 4010 is configured to acquire a first file from the first ECU, where the first file is a file stored locally by the first ECU;
  • the update module 4020 is configured to update according to the first file.
  • the obtaining module 4010 is configured to obtain the first file from the first ECU by the second ECU if the update requirement is met, and the update requirement includes that the version of the first file is higher than The version of the second file, the second file is a file used when the second ECU is not updated.
  • ECU 4000 also includes a transceiver module, configured to send version information to the first ECU, where the version information is used to represent the version of the second file.
  • a transceiver module configured to send version information to the first ECU, where the version information is used to represent the version of the second file.
  • the obtaining module 4010 is configured to receive the first file, the first file is sent by the first ECU when it is determined according to the version information that the update requirement is met.
  • the obtaining module 4010 is configured to obtain the first file from the first ECU when the second file is abnormal, and the second file is a file used when the second ECU is not updated.
  • ECU 4000 also includes a processing module, configured to determine whether there is an exception in the second file.
  • the ECU 4000 also includes a processing module, configured to detect whether the acquired first file is normal.
  • the processing module is configured to perform integrity check on the acquired second file.
  • the first file is obtained by the first ECU from a communication box TBOX.
  • the first file is an application program APP file.
  • Fig. 8 is a schematic structural diagram of an ECU provided by an embodiment of the present application.
  • the ECU 3000 includes a processor 3010 and a communication interface 3020.
  • the communication interface 3020 is used for information exchange between the ECU 3000 and other devices.
  • the ECU 3000 is made to execute the aforementioned ECU update method.
  • the ECU 3000 can be used to execute the steps performed by any one of the first ECU and the second ECU in Figure 3, ECU 1 and ECU 2 in Figure 4 and Figure 5 .
  • the embodiment of the present application also provides a terminal, including ECU 2000 and ECU 4000.
  • An embodiment of the present application further provides a computer program storage medium, wherein the computer program storage medium has program instructions, and when the program instructions are executed, the foregoing method is executed.
  • An embodiment of the present application further provides a system-on-a-chip, wherein the system-on-a-chip includes at least one processor, and when program instructions are executed on the at least one processor, the foregoing method is executed.
  • "at least one” means one or more, and “multiple” means two or more.
  • “And/or” describes the association relationship of associated objects, indicating that there may be three kinds of relationships, for example, A and/or B may indicate that A exists alone, A and B exist simultaneously, or B exists alone. Among them, A and B can be singular or plural.
  • the character “/” generally indicates that the contextual objects are an “or” relationship.
  • “At least one of the following” and similar expressions refer to any combination of these items, including any combination of single items or plural items.
  • At least one of a, b, and c may represent: a, b, c, a-b, a-c, b-c, or a-b-c, wherein a, b, and c may be single or multiple.
  • sequence numbers of the above-mentioned processes do not mean the order of execution, and the execution order of the processes should be determined by their functions and internal logic, and should not be used in the embodiments of the present application.
  • the implementation process constitutes any limitation.
  • the disclosed systems, devices and methods may be implemented in other ways.
  • the device embodiments described above are only illustrative.
  • the division of the units is only a logical function division. In actual implementation, there may be other division methods.
  • multiple units or components can be combined or May be integrated into another system, or some features may be ignored, or not implemented.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit.
  • the functions described above are realized in the form of software function units and sold or used as independent products, they can be stored in a computer-readable storage medium.
  • the technical solution of the present application is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including Several instructions are used to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage media include: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disk or optical disc and other media that can store program codes. .

Landscapes

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

Abstract

提供了一种电子控制单元ECU更新方法和ECU,方法包括:第二ECU从第一ECU获取第一文件(S320),第一文件为第一ECU本地存储的文件;第二ECU根据第一文件进行更新(S330);第一ECU和第二ECU位于同一终端中。利用终端中各个ECU之间的通信对第一ECU本地存储的第一文件进行传输至第二ECU,即可对第二ECU进行更新,提高ECU更新的灵活性和更新效率。

Description

电子控制单元ECU更新的方法、ECU和终端 技术领域
本申请涉及车辆领域,具体涉及一种ECU更新的方法、ECU和终端。
背景技术
随着社会的发展,智能运输设备、智能家居设备、机器人等智能终端正在逐步进入人们的日常生活中。
在智能车辆中,电子控制单元(electronic control unit,ECU)用于执行程序,以实现对数据的处理。可以理解为自动驾驶领域的微机控制器,也可以称为车辆专用单片机。每个ECU包括处理器和存储器,处理器用于执行存储器中存储的程序,以实现特定功能。可以通过硬件更换、近端升级、空中升级(over the air,OTA)等方式实现对ECU中应用程序的更新,从而对应用程序进行升级或修复。
发明内容
本申请提供一种ECU更新方法、ECU和终端,提高ECU更新的灵活性,提高ECU更新效率,降低成本。
第一方面,提供一种ECU更新的方法,所述方法包括:第二ECU从第一ECU获取第一文件,所述第一文件为所述第一ECU本地存储的文件;所述第二ECU根据所述第一文件进行更新;所述第一ECU和所述第二ECU位于同一终端中。
本申请所述的文件也可以称为版本文件,程序,程序文件,软件,或者软件版本等,表示可以用于或者运行于ECU的程序或者软件。示例地,该第一文件可以为应用程序APP文件,且为第一ECU未更新的APP的版本文件。第一文件可以理解为目标文件或者说目标程序,下文的第二文件可以理解为原文件或者原程序。
利用终端中第一ECU与第二ECU之间的通信,可以将第二ECU更新为第一ECU本地存储的第一文件,无需每个ECU都从外网获取第一文件,提高了ECU中文件更新的灵活性。
结合第一方面,在一些可能的实现方式中,所述第二ECU从第一ECU获取第一文件,包括:在符合更新需求的情况下,所述第二ECU从所述第一ECU获取所述第一文件,所述更新需求包括所述第一文件的版本高于第二文件的版本,所述第二文件为所述第二ECU未更新时使用的文件。示例地,该第二文件为第二ECU可以更新的APP的版本文件。
通过设置更新需求,第一ECU在满足更新需求的情况下向第二ECU发送第一文件,可以使得第一ECU和第二ECU中的文件版本匹配和兼容,从而增强了ECU之间的兼容性,增强了ECU之间功能上的协调。
较新版本的文件具有较好的性能。各个ECU利用较新版本的第一文件对数据进行处理,可以提高处理性能。另外,各个ECU利用相同版本的文件对数据进行处理,处理结 果具有一致性。
结合第一方面,在一些可能的实现方式中,所述方法还包括:所述第二ECU向所述第一ECU发送版本信息,所述版本信息用于表示所述第二文件的版本;所述第二ECU从所述第一ECU获取所述第一文件,包括:接收所述第一文件,所述第一文件是所述第一ECU在根据所述版本信息确定符合所述更新需求的情况下发送的。
第一ECU可以根据第二ECU发送的版本信息确定是否需要对第二文件进行更新。第一ECU可以对是否向第二ECU发送第一文件进行判断,无需设置额外的设备进行判断,实现较为简单,能够降低成本。示例地,第一ECU可以定期的检测该终端的其他ECU是否可以正常工作或者检测其他ECU的版本是否较低,从而第一ECU可以根据实际情况,确实是否给其他ECU发送第一文件。
结合第一方面,在一些可能的实现方式中,所述第二ECU从第一ECU获取第一文件,包括:当所述第二文件存在异常时,所述第二ECU从所述第一ECU获取所述第一文件,所述第二文件为所述第二ECU未更新时使用的文件。
在第二ECU中的第二文件存在异常的情况下,第一ECU向第二ECU发送目标程序,可以及时对第二ECU中的异常文件进行更新。
结合第一方面,在一些可能的实现方式中,所述第二ECU根据所述第一文件进行更新之前,所述方法还包括:所述第二ECU检测第二文件是否正常。可选地,所述第二ECU根据所述第一文件进行更新之前,所述第二ECU还可以检测第一文件是否正常。
第二ECU对第二ECU中的第二文件是否正常进行检测,检测方式较为简便。
示例性地,第二ECU还可以检测更新后的文件是否存在异常,可选地,第二ECU可以周期的检测更新后的文件是否存在异常,从而可以及时检测出第二ECU能否正常更新,以及能正常更新的话,能否正常工作,从而确保ECU正常工作,提高ECU的可靠性。
另外,第二ECU检测更新后的文件是否存在异常,可以在更新后的文件存在异常的情况下,重新获取文件,从而确保ECU正常工作,提高ECU的可靠性。
结合第一方面,在一些可能的实现方式中,所述第二ECU检测所述第一文件是否正常,包括:所述第二ECU对所述第一文件进行完整性校验。
可以通过完整性校验,检测第一文件是否正常,提供了一种判断文件是否正常的有效方法。
结合第一方面,在一些可能的实现方式中,所述第一文件是所述第一ECU从所述终端的通信盒子TBOX获取的。也即是,第一文件可以为第一ECU定期或者不定期的通过OTA方式从外网(联网)获取的。
示例地,在终端的第一ECU与第二ECU中的程序需要升级的情况下,该终端通过OTA方式从外网获取第一文件,进一步通过该终端的TBOX和/或网关,向第一ECU发送第一文件,可以实现对第一ECU中程序的更新;在通过第一ECU向第二ECU发送第一文件,TBOX无需向各个ECU发送相同的文件。也就是说,TBOX无需重复获取并转发第一文件,从而,可以节约ECU更新的传输资源。
结合第一方面,在一些可能的实现方式中,所述方法还包括:所述第二ECU从第一ECU获取第一文件之前,判断所述第二ECU是否需要获取所述第一文件。
可以由第一ECU或第二ECU对第二ECU是否需要获取第一文件进行判断。
结合第一方面,在一些可能的实现方式中,所述第二ECU获取第一版本信息,所述第一版本信息用于表示所述第一文件的版本;根据所述第一版本信息,所述第二ECU比较所述第一文件的版本和所述第二文件的版本;所述第二ECU从第一ECU获取第一文件包括:当所述第二文件的版本低于所述第一文件的版本时,所述第二ECU从第一ECU获取所述第一文件。
结合第一方面,在一些可能的实现方式中,所述方法还包括:所述第二ECU从第一ECU获取第一文件之前,所述第二ECU检测所述第二文件是否存在异常;所述第二ECU从第一ECU获取第一文件,包括:当所述第二文件异常时,所述第二ECU从第一ECU获取第一文件。
通过第二ECU对第二文件的是否异常进行检测,并在第二文件异常时获取第一文件,能够及时对第二文件进行更新。
第二方面,提供一种ECU更新的方法,所述方法包括:第一ECU读取所述第一ECU本地存储的第一文件;所述第一ECU向第二ECU发送所述第一文件,以使得所述第二ECU将第二文件更新为所述第一文件,所述第一ECU和所述第二ECU位于同一终端中。
通过第一ECU将第一ECU对应的存储区域中存储的第一文件发送至第二ECU,对第二ECU中的第二文件进行更新,第二ECU利用与终端中的第一ECU之间的通信,即可实现对文件的更新,无需从终端之外获取第一文件,提高了ECU更新的灵活性。与采用空中升级或近端升级的方式对终端中各个ECU进行更新的方向相比,本申请提供的ECU方法可以提高效率,降低成本。
结合第二方面,在一些可能的实现方式中,所述第一ECU向第二ECU发送所述第一文件,包括:在符合更新需求的情况下,所述第一ECU向所述第二ECU发送所述第一文件,所述更新需求包括所述第一文件的版本高于所述第二文件的版本,所述第二文件为所述第二ECU未更新时使用的文件。
通过设置更新需求,第一ECU在满足更新需求的情况下向第二ECU发送第一文件,可以使得第一ECU和第二ECU中的文件版本匹配和兼容,避免功能上无法协调一致,甚至产生冲突。
较新版本的文件具有较好的性能。各个ECU利用较新版本的第一文件对数据进行处理,可以提高处理性能。另外,各个ECU利用相同版本的文件对数据进行处理,处理结果具有一致性。
结合第二方面,在一些可能的实现方式中,所述方法还包括:所述第一ECU接收所述第二ECU发送的版本信息,所述版本信息用于表示所述第二文件的版本,所述第一ECU根据所述版本信息判断是否符合所述更新需求。
从而,第一ECU可以根据第二ECU发送的版本信息确定是否需要对第二文件进行更新。第一ECU可以对是否向第二ECU发送第一文件进行判断,无需设置额外的设备进行判断,实现较为简单。
结合第二方面,在一些可能的实现方式中,所述方法还包括:所述第一ECU接收通信盒子T-BOX发送的所述第一文件。
在终端的第一ECU与第二ECU中的程序需要升级的情况下,通过TBOX向第一ECU发送第一文件,可以实现对第一ECU中程序的更新;在通过第一ECU向第二ECU发送 第一文件,TBOX无需向各个ECU发送相同的文件。也就是说,TBOX无需重复获取第一文件,从而,可以降低对传输资源的占用。
结合第二方面,在一些可能的实现方式中,所述终端包括通信盒子T-BOX,所述方法还包括:所述第一ECU接收所述T-BOX发送的测量信息;所述第一ECU向所述T-BOX发送第一响应信息,在所述T-BOX接收的多个响应信息中,所述第一响应信息对应的响应时间小于第二响应消息对应的响应时间,所述第二响应信息是所述第二ECU接收所述测量信息后向所述T-BOX发送的;所述第一文件经过所述T-BOX转发,传输至所述第一ECU。
T-BOX在多个ECU中确定响应时间较短的第一ECU,并向第一ECU转发第一文件,可以降低传输时延,提高传输效率。T-BOX可以用于对服务器发送的第一文件进行转发。
结合第二方面,在一些可能的实现方式中,所述第一ECU向第二ECU发送所述目标程序,包括:在所述第二文件存在异常的情况下,所述第一ECU向所述第二ECU发送所述第一文件,所述第二文件为所述第二ECU未更新时使用的文件。
在第二ECU中的第二文件存在异常的情况下,第一ECU向第二ECU发送目标程序,可以及时对第二ECU中的异常文件进行更新。
结合第二方面,在一些可能的实现方式中,所述方法还包括:所述第一ECU向所述第二ECU发送版本查询信息;所述第一ECU向第二ECU发送所述目标程序,包括:在所述版本查询信息发送后的预设时长内所述第一ECU未收到所述第二ECU发送的版本信息的情况下,所述第一ECU确定所述原程序存在异常,所述版本信息用于表示所述原程序的版本。
在第二ECU未在预设时长内对第一ECU发送的版本查询信息进行响应的情况下,可以确定第二ECU存在异常,从而及时对第二ECU中的异常程序进行更新。
结合第二方面,在一些可能的实现方式中,所述方法还包括:所述第一ECU检测所述第一文件是否正常;所述第一ECU向第二ECU发送所述第一文件,包括:在所述第一文件正常的情况下,所述第一ECU向所述第二ECU发送所述第一文件。
在第一文件正常的情况下,将第一文件发送至第二ECU,以使得第二ECU将第二文件更新为第一文件,提高第二ECU中更新后的第一文件正常的概率,避免对异常文件传输,降低对资源的占用。
结合第二方面,在一些可能的实现方式中,所述第一ECU检测所述第一文件是否正常,包括:所述第一ECU对所述第一文件进行完整性校验。
可以通过完整性校验,检测第一文件是否正常,提供了一种判断文件是否正常的有效方法。
结合第二方面,在一些可能的实现方式中,所述第一文件为应用程序APP文件。
第三方面,提供一种ECU,包括用于实现第一方面或第二方面所述的ECU更新方法的各个功能模块。
第四方面,提供一种ECU,包括通信接口和处理器,所述通信接口用于ECU与其他装置进行信息交互,当程序指令在所述处理器中执行时,使得所述ECU执行第一方面或第二方面所述的ECU更新方法。
第五方面,提供一种计算机程序存储介质,其特征在于,所述计算机程序存储介质具 有程序指令,当所述程序指令被执行时,使得第一方面或第二方面所述的方法被执行。
第六方面,提供一种芯片,所述芯片系统包括至少一个处理器,当程序指令在所述至少一个处理器中执行时,使得第一方面或第二方面所述的方法被执行。
可选地,作为一种实现方式,所述芯片还可以包括存储器,所述存储器中存储有指令,所述处理器用于执行所述存储器上存储的指令,当所述指令被执行时,所述处理器用于执行第一方面或第二方面中的任意一种实现方式中的方法。
上述芯片具体可以是现场可编程门阵列(field-programmable gate array,FPGA)或者专用集成电路(application-specific integrated circuit,ASIC)。
第七方面,提供一种终端,包括第一ECU和第二ECU,所述第二ECU用于执行第一方面所述的方法,所述第一ECU用于执行第二方面所述的方法。示例地,所述终端为车辆。
附图说明
图1是本申请实施例适用的一种车辆的功能框图。
图2是一种通信方法的示意性结构图。
图3是本申请实施例提供的一种ECU更新方法的示意性流程图。
图4是本申请实施例提供的另一种ECU更新方法的示意性流程图。
图5是本申请实施例提供的一种ECU程序升级方法的示意性流程图。
图6是本申请实施例提供的一种ECU的示意性结构图。
图7是本申请实施例提供的另一种ECU的示意性结构图。
图8是本申请实施例提供的又一种ECU的示意性结构图。
具体实施方式
下面将结合附图,对本申请中的技术方案进行描述。
本申请实施例所提供的ECU更新方法可以应用于智能驾驶车辆。下面结合附图,对本申请实施例的技术方案进行介绍。
图1是本申请实施例适用的一种车辆的功能框图。其中,车辆100可以是智能驾驶车辆,车辆100配置可以为完全或部分地自动驾驶模式。
在一个示例中,车辆100可以在处于自动驾驶模式中的同时控制自车,并且可通过人为操作来确定车辆及其周边环境的当前状态,确定周边环境中的至少一个其他车辆的可能行为,并确定其他车辆执行可能行为的可能性相对应的置信水平,基于所确定的信息来控制车辆100。在车辆100处于自动驾驶模式中时,可以将车辆100设置为在没有和人交互的情况下操作。
车辆100中可以包括各种子系统,例如,行进系统110、传感系统120、控制系统130等。
可选地,车辆100可以包括更多或更少的子系统,并且每个子系统可包括多个元件。另外,车辆100的每个子系统和元件可以通过有线或者无线互连。
行进系统110可以包括用于向车辆100提供动力运动的组件。传感系统120可以包括感测关于车辆100周边的环境的信息的若干个传感器。控制系统130为控制车辆100及其 组件的操作。
可选地,上述组件只是一个示例,实际应用中,上述各个模块中的组件有可能根据实际需要增添或者删除,图1不应理解为对本申请实施例的限制。
可选地,车辆100可以是在道路行进的自动驾驶汽车,可以识别其周围环境内的物体以确定对当前速度的调整。物体可以是其它车辆、交通控制设备、或者其它类型的物体。在一些示例中,可以独立地考虑每个识别的物体,并且基于物体的各自的特性,诸如它的当前速度、加速度、与车辆的间距等,可以用来确定自动驾驶汽车所要调整的速度。
可选地,车辆100或者与车辆100相关联的计算设备可以基于所识别的物体的特性和周围环境的状态(例如,交通、雨、道路上的冰等等)来预测所述识别的物体的行为。
上述车辆100可以为轿车、卡车、摩托车、公共汽车、船、飞机、直升飞机、割草机、娱乐车、游乐场车辆、施工设备、电车、高尔夫球车、火车、手推车等,本申请实施例不做特别的限定。
根据车辆的车载系统中电子部件的功能,可以将这些电子部件划分为动力域、智能驾驶域、智能座舱域等多个域。每个域可以包括至少一个电子控制单元(electronic control unit,ECU)。
行进系统110中的电子部件属于动力域,传感系统120和控制系统130中的电子部件属于智能驾驶域。智能座舱域的电子部件用于支持动态通勤场景下的办公、休闲、娱乐活动等。
在同一个域中的各个ECU可以通过通信总线进行通信
ECU包括处理器(如微控制单元(microcontroller unit,MCU)等)、存储器、输入/输出接口(input/output,I/O)。ECU还可以包括模数转换器(analog to digital converter,A/D)、整形集成电路、驱动集成电路等中的一个或多个。
随着车载ECU数量增加以及功能日趋复杂化、智能化,车载ECU运行的应用程序(application,APP)的升级频率不断提高。由于异常触发应用程序的存储区域的擦除操作,或升级过程中发生故障等情况可能导致应用程序本身存在缺陷,需要对该应用程序进行修复。
通过空中升级(over the air,OTA)、近端升级或更换硬件的方式,可以实现对车载ECU中应用程序的升级或修复。ECU中的应用程序即存储在存储器中的应用程序。
通过更换硬件,可以将ECU所在的零部件从整车上拆下,重新装上带有新应用程序的硬件模块。更换硬件模块,成本较高。为了拆装硬件,需要前往专业的车辆维修店或者请专业人员上门服务,较为费时。更换的硬件模块中的ECU存储器中存储的应用程序可能与车辆中其他车载ECU存储器中存储的应用程序不兼容,导致车载系统无法正常运行。
通过近端升级,可以通过通信线缆将车载系统与诊断仪或原始设备制造商(original equipment manufacturer,OEM)的特定升级设备连接,将存储在诊断仪上的新应用程序传输到待升级或者待修复的ECU的存储器中,实现ECU的应用程序升级或修复。为了实现近端升级,需要将车载系统与诊断仪或特定升级设备通过通信线缆连接,也就是说,需要前往专业的车辆维修店或者请专业人员上门服务,较为费时。
通过OTA,如图2所示,可以通过无线网络,将存储在OEM云端服务器的应用程序经过车载系统中的通信盒子(telematics box,T-Box)、网关等设备传输至特定ECU,从 而实现ECU的应用程序升级和修复。
网关是车内通信的中央节点,连接整车内部大部分电控单元,支持各种总线系统,可实现跨域功能集成、基本的路由通信以及协议翻译、车内数据的提取和整合、安全部署、提供诊断通信服务及网联服务,使得车辆互联服务成为现实。
通信盒子(telematics box,T-Box),也称车载信息盒,主要用于提供网关与互联网的交互。T-Box可以属于通信域。
车载系统可以包括多个同类ECU。多个同类ECU的硬件组成相同,且每个同类ECU的存储器中的存储的应用程序相同。
车载系统中各个ECU均采用OTA、近端升级的方式进行应用程序升级和修复,成本较高。
为了解决上述问题,本申请实施例提供了一种ECU更新方法和装置。通过将第一ECU本地存储的更新软件转发给第二ECU,以使得第二ECU进行更新。从而,当终端中多个ECU中存在软件版本低的第二ECU或者第二ECU的更新软件受损,从而需要更新第二ECU时,便可以直接从该终端其他的ECU,如软件版本较高的第一ECU或者软件版本完好无损的第一ECU,获取更新软件。可见,通过本申请所述的方法,当终端的ECU中存在可用的更新软件时,可以直接转发给需要进行更新的ECU,从而无需要实时地通过OTA方式获取更新软件,大大节省了网络资源,且节约了更新的时间,提高了更新效率。且,第一ECU本地存储的更新软件不仅可以用于第一ECU自身,还可以共享给该终端内其他ECU,提高了该更新软件的复用效率。
上述的软件也可以称为软件版本,文件,安装文件,更新文件,程序,或程序文件等,表示可以用于或者运行于ECU的程序或者软件。
本申请所述的ECU为终端的一种控制器,本申请对控制器的名称不做限制,本申请所述的ECU的功能包括控制终端的运行状态和/或环境数据采集。示例地,当ECU用于车辆时,ECU可以控制车辆的行驶状态。
图3是本申请实施例提供的一种ECU更新方法的示意性流程图。
终端包括第一ECU和第二ECU。
终端可以是车、车载装置、车载芯片等装置中的一个或多个。
ECU更新方法300包括S320-S330。
在S320,第二ECU从第一ECU获取第一文件。
第一文件为所述第一ECU本地存储的文件。第一文件存储在第一ECU对应的存储区域中。
第一文件可以是应用程序文件。应用程序文件也可以称为版本文件。第一ECU可以执行该第一文件,以实现应用程序的功能。
在S330,第二ECU根据第一文件进行更新。
第二文件是第二ECU本地存储的文件。
通过S320至S330,利用终端中第一ECU与第二ECU之间的通信,可以将第二ECU更新为第一ECU本地存储的第一文件,无需每个ECU都从外网获取第一文件,提高了ECU中文件更新的灵活性。
第一文件可以理解为目标程序,第二文件可以理解为原程序。
在一些实施例中,第二ECU可以获取第一ECU本地存储的第一文件。
第二ECU可以在第二文件异常的情况下,获取第一ECU本地存储的第一文件。
可选地,第二ECU可以对第二文件进行完整性校验。完整性校验可以基于循环冗余校验(cyclic redundancy check,CRC)、基于密码的消息认证码(cipher-based message authentication code,CMAM)等方式进行。通过完整性校验可以确定第二文件是否异常。
第二ECU也可以在第二文件的版本低于第一文件的版本的情况下,第二ECU获取第一ECU本地存储的第一文件。
可选地,第二ECU可以从第一ECU获取第一版本信息。所述第一版本信息用于表示第一文件的版本。第二ECU可以根据第一版本信息,将第一文件的版本与第二文件的版本进行比较。在确定第一文件的版本高于第二文件的版本的情况下,第二ECU可以获取第一ECU本地存储的第一文件。或者,第二ECU可以将第二ECU自身的第二文件的第二版本信息发送给第一ECU,由第一ECU根据第一ECU的第一版本信息和第二ECU的第二版本信息进行判断,在第一ECU确定第一文件的版本高于第二文件的版本的情况下,第二ECU可以获取第一ECU本地存储的第一文件。
在S320之前,可以进行S310。在S310,第一ECU读取所述第一ECU本地存储的第一文件。在S320,第一ECU可以向第二ECU发送第一文件。
从而,在各个ECU无需具备对其他ECU的本地存储进行读取的能力,第二ECU通过从第一ECU接收第一文件,就能够对第二文件进行更新。
在S320,第一ECU还可以向第二ECU发送文件标识。第二ECU可以根据文件标识,将第二文件更新为第一文件。第一文件与第二文件可以是相同类型的文件,具有相同的标识。
在满足更新需求的情况下,第二ECU可以获取第一文件。
更新需求可以是所述第一文件的版本高于所述第二文件的版本。从而,各个ECU中用于实现相同或相近的功能的文件的版本一致,均为最新版本。
一般情况下,较新版本的文件具有较好的性能。各个ECU利用最新版本的文件对数据进行处理,可以提高处理性能。另外,各个ECU利用相同版本的文件对数据进行处理,处理结果具有较高的一致性。
可选地,第二ECU可以定期或者不定期的向第一ECU发送版本信息。
或者,第一ECU可以向所述第二ECU发送版本查询信息。版本查询信息用于表示第二ECU向第一ECU发送版本信息。在接收版本查询信息后,第二ECU可以向第一ECU发送版本信息。
或者,第一ECU可以定期或者不定期的向第二ECU发送版本查询信息。
在另一些实施例中,终端包括处理系统和控制装置。处理系统包括第一ECU和第二ECU。控制装置可以为独立于处理系统中各ECU的设备。在进行S320之前,第一ECU可以向控制装置发送第一版本信息,第二ECU可以向控制装置发送第二版本信息。第一版本信息用于表示第一文件的版本,第二版本文件用于表示第二文件的版本。控制装置可以控制处理系统进行S320至S330。
控制装置可以向处理系统中的各个ECU发送版本查询信息。各个ECU可以在接收版本查询信息后,向控制装置发送用于表示该ECU的版本信息,以表示该ECU本地存储的 文件的版本。或者,各个ECU可以定期或者不定期的向控制装置发送该ECU的版本信息。控制装置可以根据接收的各个ECU发送的版本信息,控制处理系统进行S310至S330。例如,控制装置可以在至少一种情况下,控制处理系统进行S310至S330:未接收第二ECU的版本信息,确定第二ECU本地存储的第二文件异常,确定满足需要对第二文件进行更新。
单独设置控制装置,使得终端设备的设备数量增加,占用较多的空间。
可选地,在所第二文件存在异常的情况下,所述第一ECU向所述第二ECU发送第一文件。
可见,在第二ECU中本地存储的第二文件存在异常的情况下,第一ECU向第二ECU发送第一文件,可以及时对第二ECU中的异常文件进行更新。
在一些实施例中,在第二ECU确定第二文件异常的情况下,第二ECU可以向第一ECU发送异常指示信息,异常指示信息用于指示该第二文件异常。第一ECU可以根据接收的异常指示信息确定第二文件需要更新,向第二ECU发送第一文件。
在另一些实施例中,第一ECU可以向所述第二ECU发送版本查询信息。版本查询信息用于指示第二ECU向第一ECU发送版本信息,第二ECU发送的版本信息用于表示第二ECU本地存储的第二文件的版本。在第二文件存在异常的情况下,第二ECU可以不向第一ECU发送版本信息。在所述版本查询信息发送后的预设时长内所述第一ECU未收到所述第二ECU发送的版本信息的情况下,第一ECU确定第二文件存在异常,向第二ECU发送第一文件。
从而,通过第一ECU在查询第二ECU中第二文件的版本的过程中,就能够确定第二文件是否异常,从而对第二ECU中异常的第二文件的进行及时更新。
第一ECU可以接收TBOX发送的第一文件。TBOX与第一ECU、第二ECU位于相同的终端中。也即是,第一文件可以为第一ECU定期或者不定期的通过OTA方式从外网获取的。且第一ECU不仅可以自己使用该第一文件进行更新,还可以将该第一文件转发给该终端其他需要更新的ECU,从而提高了该终端ECU的更新效率,节约了网络传输资源。
TBOX可以将服务器发送的信息、文件等转发至各个ECU。服务器可以是实体服务器、虚拟服务器等不同类型的服务器中的一个或多个,可以具有处理功能和收发功能。该服务器例如可以是OEM云端服务器。
在终端的第一ECU与第二ECU中的文件需要升级的情况下,通过TBOX向第一ECU转发新的文件,可以实现对第一ECU中文件的更新;再通过第一ECU向第二ECU发送该新的文件,减少服务器向终端重复发送新的文件的次数,从而,可以降低对传输资源的占用,并提高文件更新效率。
第一ECU可以是多个同类ECU中的任一个ECU,接收服务器发送的第一文件。多个同类ECU中可以存储有用于实现相同功能的文件。例如,第一ECU可以是对T-BOX发送的测量信息响应最快的ECU。
终端包括T-BOX。T-BOX可以向终端中的各个同类ECU发送测量信息。
每个ECU接收所述T-BOX发送的测量信息后,向T-BOX发送响应信息。在T-BOX接收的多个响应信息中,所述T-BOX可以确定响应时间最短的ECU作为第一ECU,并 将服务器发送的第一文件转发至第一ECU。示例地,该第一ECU可以为主ECU。
也就是说,第一ECU可以接收T-BOX发送的测量信息。第一ECU可以向T-BOX发送第一响应信息。在T-BOX接收的多个响应信息中,第一响应信息对应的响应时间小于第二响应消息对应的响应时间。第二响应信息是第二ECU接收测量信息后向T-BOX发送的。之后,第一ECU接收所述T-BOX发送的第一文件。
在T-BOX对服务器发送的第一文件进行转发的情况下,T-BOX在多个ECU中确定响应时间较短的第一ECU,并由T-BOX向第一ECU转发服务器发送的第一文件,可以降低传输时延,提高传输效率。
图4是本申请实施例提供的一种ECU更新方法的示意性流程图。
ECU的应用程序APP是指用以完成某项或多项特定工作的ECU程序。下面以对ECU中的应用程序APP进行更新为例进行说明。
终端包括多个同类ECU。
该多个同类ECU包括ECU 1和ECU 2。
各个ECU在上电时,可以进行S411。
在S411,ECU对该ECU的存储区域中存储的APP文件进行完整性检测。每个ECU在上电时,可以运行引导装载程序(BootLoader)。BootLoader可以用于对ECU进行初始化,并引导APP文件的运行。每个ECU的存储区域中存储的APP文件,也可以理解为该ECU的APP文件,也即是当前该ECU所使用的APP文件。
在运行BootLoader时,ECU可以对存储在该ECU对应的存储区域中的APP文件进行完整性检测。完整性检测也可以称为完整性校验。
一般情况下,BootLoader存储在具有保护功能的存储区中。在出厂后,具有保护功能的存储区中存储的数据不再改变。因此,BootLoader不易损坏且出厂后不会再升级。
当S411的检测结果为异常时,不再运行该APP文件,并保持BootLoader运行。
当检测结果为正常时,进行S412。
在S412,ECU运行该APP文件。也就是说,在APP文件通过完整性检测,ECU在完成BootLoader的启动引导之后,跳转至APP文件,即ECU开始执行APP文件以实现该APP文件的业务功能。
在S421,ECU向其他同类ECU发送版本查询信息。
版本查询信息用于请求该其他同类ECU中的该APP文件的版本信息。
以ECU 1向ECU 2发送版本查询信息为例进行说明。
当ECU 2运行APP文件2时,如果接收到ECU 1发送的版本查询信息,则进行S422。
也就是说,当ECU 2运行APP文件2时,如果接收到ECU 1发送的版本查询信息,则进行S422。
在S422,ECU 2向该ECU 1发送版本响应信息。
ECU 2发送的版本响应信息用于表示该ECU 2中的APP文件2的版本信息。
如果ECU 2在S411的检测结果为异常,未运行该APP文件2,则ECU 2在接收到ECU 1发送的版本查询信息时,可以向ECU 1发送异常信息。异常信息用于表示ECU 2中的该APP文件2完整新检验存在异常。
或者,ECU 2在S411的检测结果为异常,未运行该APP文件2时,ECU 2可以不向 ECU 1发送版本响应信息。
在S423,ECU 1判断ECU 2中的APP文件2是否需要更新。
在出现以下至少一种情况时,ECU 1可以确定ECU 2中的该APP文件2需要更新:ECU 1接收到ECU 2发送的异常信息、在S421之后经过预设时间ECU 1未收到ECU 2发送的版本响应信息、ECU 2发送的版本响应信息满足更新条件。
示例性地,当接收ECU 2发送的版本响应信息时,ECU 1可以根据该版本响应信息中携带的版本信息,判断ECU 2中的APP文件2是否需要更新,即是否满足更新需求。例如,更新需求可以是,该版本响应信息中携带的版本信息表示的APP文件2的版本低于ECU 1中该APP文件1的版本。在该版本响应信息中携带的版本信息满足更新需求的情况下,ECU 1确定ECU 2中的该APP文件2需要更新。
当ECU 1判断ECU 2中的APP文件2不需要更新时,ECU 1可以经过定期或者不定期的再次进行S421。也就是说,ECU 1可以定期或者不定期的对其他同类ECU中的APP文件是否需要更新进行检测。
当ECU 1判断ECU 2中的APP文件2需要更新时,进行S424。
在S424,ECU 1判断是否满足更新条件。
在满足更新条件的情况下,ECU 1可以确定对ECU 2中的APP文件2进行更新。
更新条件可以包括ECU 2的预设电压范围、预设最大终端速度等中的至少一个。可以由ECU 1或ECU 2判断ECU 2是否满足更新条件。当该终端为车辆时,该预设最大终端速度可以为该车辆的行驶速度。
在ECU 2的电压满足预设电压范围的情况下对ECU 2中的APP文件2进行更新,可以降低ECU 2对接收的APP文件2进行存储出现错误的可能性。在终端速度小于预设最大终端速度的情况下对ECU 2中的APP文件2进行更新,可以降低ECU 2更新对车辆行驶安全性的影响。在一些情况下,预设最大车速可以为0,即进行车辆未行驶的情况下进行ECU更新。
ECU 1可以向ECU 2发送更新条件检查请求,以指示ECU 2获取ECU 2的工作电压、所在车辆的车速等更新检测信息。ECU 2可以进行检测以获取更新检测信息,并向ECU 1发送更新检测信息。ECU 1可以根据更新检测信息,判断是否满足更新条件。或者,ECU 2可以根据更新检测信息,判断是否满足更新条件,并将是否满足更新条件的判断结果发送至ECU 1。
或者,ECU 1可以进行检测获取更新检测信息,并判断是否满足更新条件。或者,更新检测信息中部分信息可以由ECU 1进行检测,另一些信息可以由ECU 2进行检测。例如,ECU 1可以向ECU 2发送更新条件检查请求,以指示ECU 2检测ECU 2的工作电压。ECU 1可以对所在车辆的车速进行检测。之后,ECU1可以根据检测得到的车速以及ECU 2发送的ECU 2的工作电压,确定是否满足更新条件。
如果不满足更新条件,或者ECU 1未收到ECU 2发送的更新检测信息或是否满足更新条件的判断结果,则ECU 1确定不满足更新条件。ECU 1确定不进行更新时,ECU 1可以继续运行该APP文件1。ECU 1确定不满足更新条件时,更新流程结束。在一些实施例中,ECU 1确定不满足更新条件时,经过预设时长,ECU 1可以再次进行S424。
如果ECU 1从ECU 2接收更新检测信息并确定升级检测信息满足更新条件,或者ECU  1从ECU 2接收满足更新条件的判断结果,则ECU 1确定对ECU 2中的APP文件2更新。ECU 1确定满足更新条件时,可以进行S431。
在S431,ECU 1向ECU 2发送更新指示。
ECU 1确定满足更新条件时,ECU 1可以停止运行该APP文件1,并运行BootLoader。
如果ECU 2在S411的检测结果为异常,进行S433。
如果ECU 2在S411的检测结果为正常,即ECU 2正在运行该APP文件2,则ECU 2在接收该更新指示后,进行S432。
在S432,ECU 2停止运行该APP文件2。ECU 2还可以运行BootLoader。
在S432之后,可以进行S433。
在S433,ECU 1与ECU 2进行身份验证。
具体地,ECU 1可以向ECU 2发送身份认证请求。ECU 2根据该身份认证请求,确定ECU 1是否身份合法,并向ECU 1发送对ECU 1是否身份合法的判断结果。
如果身份验证成功,进行S434。
在S434,ECU 1向ECU 2发送该APP文件1。
ECU 1在ECU 1的存储区域中读取该APP文件1,并将读取的APP文件1发送至ECU 2。
ECU 2可以将ECU 1发送的APP文件1写入ECU 2的存储区域,从而实现根据APP文件1对ECU 2的更新。
在S434之后,ECU 1可以继续运行该APP文件1,ECU 2可以在ECU 2中存储区域读取该APP文件1并运行。示例性地,ECU 1和ECU 2可以运行BootLoader,以引导APP文件1的运行。
具体地,ECU 1在完成S434对该APP文件1的发送之后,可以向ECU 2发送复位请求。ECU 2可以在接收复位请求后,运行BootLoader,并在该存储区域读取该APP文件1并运行。
在ECU 2运行BootLoader的过程中,ECU 2可以对存储区域的APP文件1进行完整性检测。从而,ECU 2可以判断更新后的APP文件1是否正常。
也就是说,在S434之后,可以再次进行S411至S434。
通过S411至S434,在ECU 2的APP文件2不完整或版本较低的情况下,可以对ECU 2进行更新。
在一些实施例中,当ECU 2进行S411的检测结果为异常时,ECU 2可以向其他ECU例如ECU 1发送异常指示信息。
如果ECU 1在S411的检测结果为异常,ECU 1在接收ECU 2发送的异常指示信息后,可以忽略该异常指示信息。如果ECU 1在S411的检测结果为正常,则ECU 1在接收该异常指示信息后,可以进行S424以及后续步骤。
示例性地,在ECU 1在接收该异常指示信息后,在S424确定进行更新,可以不再进行S431,即可以不再向ECU 2发送更新指示。也就是说,在S424之后,可以进行S433,ECU 1与ECU 2进行身份认证。并在身份认证成功的情况下,进行S434,ECU 1向ECU 2发送该APP文件1。
同理,与ECU 2的更新类似,ECU 1还可以对ECU 1是否需要更新进行判断。在一 些实施例中,在S423,ECU 1还可以根据该版本响应信息中携带的版本信息,判断ECU 1中的APP文件1是否需要更新。例如,当ECU 1中该APP文件1的版本低于该版本响应信息中携带的版本信息表示的APP文件2的版本时,ECU 1确定ECU 1中的该APP文件1需要更新。在ECU 1确定ECU 1中的该APP文件1需要更新时,ECU 1可以向ECU 2发送APP文件1请求更新信息,以请求ECU 2向ECU 1发送ECU 2中的该APP文件2。之后,ECU 2可以进行S423-S434中ECU 1进行的各个步骤,对ECU 1中的APP文件1进行更新。
通过S411至S434,由ECU对自身APP文件的完整性进行校验,并在各个ECU之间进行APP文件的版本的对比,从而对APP文件完整性检测结果异常的ECU或APP文件版本较低的ECU进行APP文件的更新,通过车辆内部的处理对各个ECU中的APP文件进行故障排除和升级。因此,本申请实施例提供的ECU更新方法,不要求前往专业维修点或请专业人士上门服务,终端也无需联网,即可实现对ECU中APP文件的更新,降低对外界环境的要求。
在现有OTA升级技术中,APP文件存储在OEM的云端服务器中。若要将其下载到ECU,需要经过无线传输、T-BOX转发、网关转发等环节。本申请实施例提供的ECU更新方法,终端内部的ECU之间进行APP文件的传输,同一个域内ECU之间通过通信总线可以实现APP文件的传输,不同域的ECU之间通过通信总线的传输以及网关的转发可以实现APP文件的传输,无需无线传输和T-BOX转发,减小了传输延时,提高了更新效率。
另外,无论采用近端升级还是OTA技术,更新后的ECU中的APP文件都是从车辆外部新下载的,与终端内的其他同类ECU中APP文件的版本可能不同,可能存在不兼容的问题。本申请实施例提供的ECU更新方法,可以利用各个同类ECU中某个ECU中存储的最新版本的APP文件,对其他ECU中的APP文件进行更新,从而避免各个同类ECU中的APP文件版本不同,解决了不兼容的问题。
图5是本申请实施例提供的一种ECU程序升级方法的示意性流程图。
利用图4所示的ECU更新方法,在需要对终端中的多个同类ECU进行软件升级的情况下,云服务器可以向该多个同类ECU中的部分ECU发送新的APP文件。之后,该多个同类ECU执行图4所示的ECU更新方法,从而完成对各个ECU的升级。也即是,在需要对该终端的ECU进行更新时,只需要通过OTA的方式将APP文件下载至部分ECU中,如图5所示的ECU 1,而无需将该更新文件下载至每个ECU,节约了网络传输资源。另外,ECU 1自身可以使用该APP文件进行更新,ECU 1还可以将更新后的APP文件转发给其他ECU以使得其他ECU进行更新,如图5所示的ECU 2,使得ECU 2也可以根据该APP文件进行更新。
可见,本申请实施例提供的更新方法,针对终端的多个ECU无需每次更新都以OTA方式通过外网(联网)获取APP文件,可以定期或者不定期的从外网获取APP文件后,存储在ECU本地中,在该ECU需要更新或者其他ECU需要更新的时候,该ECU进行更新或者转发给其他ECU以使得其他ECU进行更新。大大提高了更新效率,且有些ECU更新的时候无需联网就能更新,降低了该ECU更新对网络的依赖。
具体的,可以通过图5所述的ECU程序升级方法先对该部分ECU进行升级。示例地, 该ECU用于车辆。
终端包括T-BOX和多个同类ECU。该多个同类ECU包括ECU 1和ECU 2。T-BOX用于与终端之外的设备进行通信。
当T-BOX受到外界触发,终端开始执行图5所示的ECU程序升级方法,即启动APP文件的升级流程。T-BOX受到外界触发,可以是T-BOX接收到云服务器或其他设备发送的新的APP文件或者APP文件升级请求。
在S511,T-BOX向多个同类ECU发送测量信息。
在S512,该多个同类ECU中的每个ECU向T-BOX发送测量响应信息。
在S513,T-BOX确定该多个同类ECU中传输最快的ECU。
T-BOX根据向每个ECU发送测量信息的发送时间,以及接收每个ECU发送的测量响应信息的接收时间之间的差值,确定每个ECU对应的时间间隔。对应的时间间隔最小的ECU即传输时间最小的ECU,也可以理解为传输最快的部分ECU。
该传输最快的部分ECU例如可以包括ECU 1。ECU 1可以为主ECU。
在进行S520之前,ECU、T-BOX或其他车载电子设备可以确定是否满足更新条件。更新条件可以包括最大车速、ECU工作电压的预设电压范围等。
如果在进行S513之前进行更新条件的确定,还可以在进行S513之前,还确定各个ECU的工作电压是否满足该预设电压范围。在S513,T-BOX可以在工作电压满足预设电压范围的多个ECU中确定传输最快的ECU。
或者,在S511,T-BOX可以向工作电压满足预设电压范围的多个ECU发送测量信息。
在S520,T-BOX向该传输最快的一个或多个ECU发送新的APP文件,即APP文件1。
以ECU 1为传输最快的ECU,T-BOX向ECU 1发送APP文件1为例进行说明。在S513结束时,ECU 1可能正在运行BootLoader或APP文件。
在进行S520之前,T-BOX可以向ECU 1发送升级请求。
如果ECU 1在S513结束时正在运行原APP文件,ECU 1接收升级请求后,可以停止运行该原APP文件,并运行BootLoader。
如果ECU 1在S513结束时正在运行BootLoader,则ECU 1保持BootLoader的运行。
从而,在进行S520时,ECU 1运行的程序为BootLoader,降低ECU 1接收并存储APP文件1出现错误的可能性。
在S520之后,T-BOX还可以向ECU 1发送复位请求。ECU 1可以在接收复位请求后,读取APP文件1并运行。
在S520之后,该多个同类ECU可以执行图4所示的S421至S434从而对终端中的各个ECU进行程序升级。
在一些实施例中,在S520之后,可以省略S421-S431中的一个或多个步骤。
例如,在S511-S520,T-BOX仅对多个同类ECU中的一个ECU即ECU 1进行升级,在S520之后,可以省略S421-S423,ECU 1无需再请求并获取其他ECU中APP文件的版本,节省ECU之间的通信,降低对资源的浪费。
相比于从云端为每个ECU下载新的APP文件进行升级的方式,本申请实施例的ECU程序升级方法,多个同类ECU进行APP的升级,部分ECU从其他ECU获取新的APP 文件,减少从云端服务器下载新的APP文件的次数,节省无线传输资源,省去了重复地从云服务器下载相同APP文件的无线传输耗时。
上文结合图1至图5,描述了本申请实施例的交互系统和方法实施例,下面结合图6至图8,描述本申请实施例的装置实施例。应理解,各个实施例的描述相互对应,因此,未详细描述的部分可以参见前面交互系统和方法实施例的描述。
图6是本申请实施例提供的一种ECU的示意性结构图。
ECU 2000包括读取模块2010和收发模块2020。
读取模块2010用于,读取本地存储的第一文件。
收发模块2020用于,向第二ECU发送所述第一文件,以使得所述第二ECU更新,所述第一ECU和所述第二ECU位于同一终端中。
可选地,在符合更新需求的情况下,所述第一ECU向所述第二ECU发送所述第一文件,所述更新需求包括所述第一文件的版本高于第二文件的版本,所述第二文件为所述第二ECU未更新时使用的文件。
可选地,收发模块2020还用于,接收所述第二ECU发送的版本信息,所述版本信息用于表示所述第二文件的版本。
ECU 2000还包括处理模块,处理模块用于根据所述版本信息判断是否符合所述更新需求。
可选地,收发模块2020还用于,接收通信盒子T-BOX发送的第一文件。
可选地,收发模块2020用于,在第二文件存在异常的情况下,所述第一ECU向所述第二ECU发送所述第一文件,所述第二文件为所述第二ECU未更新时使用的文件。
可选地,收发模块2020还用于,向所述第二ECU发送版本查询信息。
ECU 2000还可以包括处理模块,用于在所述版本查询信息发送后的预设时长内所述ECU 2000没有从所述第二ECU接收到版本信息的情况下,确定所述第二文件存在异常,所述版本信息用于表示所述第二文件的版本。
可选地,ECU 2000还可以包括处理模块,处理模块用于检测所述第一文件是否正常。
收发模块2020还用于,在所述第一文件正常的情况下,所述第一ECU向所述第二ECU发送所述第一文件。
可选地,处理模块用于,对所述第一文件进行完整性校验。
可选地,所述第一文件为应用程序APP文件。
图7是本申请实施例提供的一种ECU的示意性结构图。
ECU 4000包括获取模块4010和更新模块4020。
获取模块4010用于,从第一ECU获取第一文件,所述第一文件为所述第一ECU本地存储的文件;
更新模块4020用于,根据所述第一文件进行更新。
可选地,获取模块4010用于,在符合更新需求的情况下,所述第二ECU从所述第一ECU获取所述第一文件,所述更新需求包括所述第一文件的版本高于所述第二文件的版本,所述第二文件为所述第二ECU未更新时使用的文件。
可选地,ECU 4000还包括收发模块,用于向所述第一ECU发送版本信息,所述版本信息用于表示所述第二文件的版本。
获取模块4010用于,接收所述第一文件,所述第一文件是所述第一ECU在根据所述版本信息确定符合所述更新需求的情况下发送的。
可选地,获取模块4010用于,当第二文件存在异常时,从所述第一ECU获取所述第一文件,所述第二文件为所述第二ECU未更新时使用的文件。
可选地,ECU 4000还包括处理模块,用于判断所述第二文件是否存在异常。
可选地,ECU 4000还包括处理模块,用于检测获取的所述第一文件是否正常。
可选地,处理模块用于对获取的所述第二文件进行完整性校验。
可选地,所述第一文件是所述第一ECU从通信盒子TBOX获取的。
可选地,所述第一文件为应用程序APP文件。
图8是本申请实施例提供的一种ECU的示意性结构图。
ECU 3000包括处理器3010和通信接口3020。
通信接口3020用于ECU 3000与其他装置进行信息交互。当程序指令在处理器3010中执行时,使得ECU 3000执行前文所述的ECU更新方法。
具体的,ECU 3000可以用于执行图3中第一ECU、第二ECU,图4、图5中ECU 1、ECU 2中的任一个ECU执行的步骤。
本申请实施例还提供一种终端,包括ECU 2000和ECU 4000。
本申请实施例还提供一种计算机程序存储介质,其特征在于,所述计算机程序存储介质具有程序指令,当所述程序指令被执行时,使得前文中的方法被执行。
本申请实施例还提供一种芯片系统,其特征在于,所述芯片系统包括至少一个处理器,当程序指令在所述至少一个处理器中执行时,使得前文中的方法被执行。
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统、装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
本申请实施例中,“至少一个”是指一个或者多个,“多个”是指两个或两个以上。“和/或”,描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示单独存在A、同时存在A和B、单独存在B的情况。其中A,B可以是单数或者复数。字符“/”一般表示前后关联对象是一种“或”的关系。“以下至少一项”及其类似表达,是指的这些项中的任意组合,包括单项或复数项的任意组合。例如,a,b和c中的至少一项可以表示:a,b,c,a-b,a-c,b-c,或a-b-c,其中a,b,c可以是单个,也可以是多个。所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统、装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
应理解,在本申请的各种实施例中,上述各过程的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。
在本申请所提供的几个实施例中,应该理解到,所揭露的系统、装置和方法,可以 通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统、装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
所述功能如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。

Claims (22)

  1. 一种电子控制单元ECU更新方法,其特征在于,所述方法包括:
    第二ECU从第一ECU获取第一文件,所述第一文件为所述第一ECU本地存储的文件;
    所述第二ECU根据所述第一文件进行更新;
    所述第一ECU和所述第二ECU位于同一终端中。
  2. 根据权利要求1所述的方法,其特征在于,所述第二ECU从第一ECU获取第一文件,包括:
    在符合更新需求的情况下,所述第二ECU从所述第一ECU获取所述第一文件,所述更新需求包括所述第一文件的版本高于第二文件的版本,所述第二文件为所述第二ECU未更新时使用的文件。
  3. 根据权利要求2所述的方法,其特征在于,所述方法还包括:
    所述第二ECU向所述第一ECU发送版本信息,所述版本信息用于表示所述第二文件的版本;
    所述第二ECU从所述第一ECU获取所述第一文件,包括:接收所述第一文件,所述第一文件是所述第一ECU在根据所述版本信息确定符合所述更新需求的情况下发送的。
  4. 根据权利要求1所述的方法,其特征在于,
    所述第二ECU从第一ECU获取第一文件,包括:当第二文件存在异常时,所述第二ECU从所述第一ECU获取所述第一文件,所述第二文件为所述第二ECU未更新时使用的文件。
  5. 根据权利要求2-4中任一项所述的方法,其特征在于,所述第二ECU根据所述第一文件进行更新之前,所述方法还包括:所述第二ECU检测所述第二文件是否正常。
  6. 根据权利要求5所述的方法,其特征在于,所述第二ECU检测所述第二文件是否正常,包括:所述第二ECU对所述第二文件进行完整性校验。
  7. 根据权利要求1-6所述的方法,其特征在于,所述第一文件是所述第一ECU从所述终端的通信盒子TBOX获取的。
  8. 根据权利要求1-7中任一项所述的方法,其特征在于,所述第一文件为应用程序APP文件。
  9. 一种电子控制单元ECU更新方法,其特征在于,所述方法包括:
    第一ECU读取所述第一ECU本地存储的第一文件;
    所述第一ECU向第二ECU发送所述第一文件,以使得所述第二ECU更新,所述第一ECU和所述第二ECU位于同一终端中。
  10. 根据权利要求9所述的方法,其特征在于,
    所述第一ECU向第二ECU发送所述第一文件,包括:在符合更新需求的情况下,所述第一ECU向所述第二ECU发送所述第一文件,所述更新需求包括所述第一文件的版本高于第二文件的版本,所述第二文件为所述第二ECU未更新时使用的文件。
  11. 根据权利要求10所述的方法,其特征在于,所述方法还包括:
    所述第一ECU接收所述第二ECU发送的版本信息,所述版本信息用于表示所述第二 文件的版本;
    所述第一ECU根据所述版本信息判断是否符合所述更新需求。
  12. 根据权利要求9-11中任一项所述的方法,其特征在于,所述方法还包括:
    所述第一ECU接收通信盒子T-BOX发送的所述第一文件。
  13. 根据权利要求9-12中任一项所述的方法,其特征在于,所述第一ECU向第二ECU发送所述第一文件,包括:
    在第二文件存在异常的情况下,所述第一ECU向所述第二ECU发送所述第一文件,所述第二文件为所述第二ECU未更新时使用的文件。
  14. 根据权利要求13所述的方法,其特征在于,
    所述方法还包括:所述第一ECU向所述第二ECU发送版本查询信息;
    所述第一ECU向第二ECU发送所述第一文件,包括:在所述版本查询信息发送后的预设时长内所述第一ECU没有从所述第二ECU接收到版本信息的情况下,所述第一ECU确定所述第二文件存在异常,所述版本信息用于表示所述第二文件的版本。
  15. 根据权利要求9-14中任一项所述的方法,其特征在于,所述方法还包括:所述第一ECU检测所述第一文件是否正常;
    所述第一ECU向第二ECU发送所述第一文件,包括:在所述第一文件正常的情况下,所述第一ECU向所述第二ECU发送所述第一文件。
  16. 根据权利要求15所述的方法,其特征在于,所述第一ECU检测所述第一文件是否正常,包括:所述第一ECU对所述第一文件进行完整性校验。
  17. 根据权利要求9-16中任一项所述的方法,其特征在于,所述第一文件为应用程序APP文件。
  18. 一种电子控制单元ECU,其特征在于,包括通信接口和处理器,所述通信接口用于所述ECU与其他装置进行信息交互,当程序指令在所述处理器中执行时,使得所述ECU执行权利要求1-17任一项所述的ECU更新方法。
  19. 一种计算机程序存储介质,其特征在于,所述计算机程序存储介质具有程序指令,当所述程序指令被执行时,使得如权利要求1-17中任一项所述的方法被执行。
  20. 一种芯片,其特征在于,所述芯片包括至少一个处理器,当程序指令被所述至少一个处理器中执行时,使得如权利要求1-17中任一项所述的方法被执行。
  21. 一种终端,其特征在于,包括第一电子控制单元ECU和第二ECU,所述第一ECU用于执行权利要求1-8中任一项所述的方法,所述第二ECU用于执行权利要求9-17中任一项所述的方法。
  22. 根据权利要求21所述的终端,其特征在于,所述终端为车辆。
PCT/CN2021/103466 2021-06-30 2021-06-30 电子控制单元ecu更新的方法、ecu和终端 WO2023272570A1 (zh)

Priority Applications (3)

Application Number Priority Date Filing Date Title
CN202180001811.1A CN113853580A (zh) 2021-06-30 2021-06-30 电子控制单元ecu更新的方法、ecu和终端
PCT/CN2021/103466 WO2023272570A1 (zh) 2021-06-30 2021-06-30 电子控制单元ecu更新的方法、ecu和终端
EP21947524.1A EP4361798A4 (en) 2021-06-30 2021-06-30 PROCEDURE FOR UPDATE OF AN ELECTRONIC CONTROL UNIT (ECU), ECU AND TERMINAL DEVICE

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2021/103466 WO2023272570A1 (zh) 2021-06-30 2021-06-30 电子控制单元ecu更新的方法、ecu和终端

Publications (1)

Publication Number Publication Date
WO2023272570A1 true WO2023272570A1 (zh) 2023-01-05

Family

ID=78982699

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/103466 WO2023272570A1 (zh) 2021-06-30 2021-06-30 电子控制单元ecu更新的方法、ecu和终端

Country Status (3)

Country Link
EP (1) EP4361798A4 (zh)
CN (1) CN113853580A (zh)
WO (1) WO2023272570A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116069478B (zh) * 2023-03-07 2023-06-02 湖南师范大学 基于图神经网络的车载系统安全感知设计优化方法及设备

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108241514A (zh) * 2017-12-28 2018-07-03 宁德时代新能源科技股份有限公司 车载程序更新方法和装置
KR102064519B1 (ko) * 2018-12-04 2020-01-09 인포뱅크 주식회사 차량 ecu 소프트웨어 업데이트 방법, 그를 수행하기 위한 장치 및 시스템
CN111818463A (zh) * 2019-08-13 2020-10-23 北京骑胜科技有限公司 传输镜像文件的方法、装置、存储介质及电子设备
CN112181463A (zh) * 2020-09-29 2021-01-05 广州汽车集团股份有限公司 一种ecu的更新方法及主节点设备
CN112882742A (zh) * 2019-11-30 2021-06-01 华为技术有限公司 软件更新方法以及相关设备

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103309761B (zh) * 2013-05-31 2016-12-28 深圳创维数字技术有限公司 一种基于在线服务的自动纠错的方法和系统
JP7200708B2 (ja) * 2019-01-31 2023-01-10 富士通株式会社 車載システム及びecu
WO2022021191A1 (zh) * 2020-07-30 2022-02-03 华为技术有限公司 软件升级的方法、装置和系统
CN111858124A (zh) * 2020-07-30 2020-10-30 深圳市亿道信息股份有限公司 一种自动检测智能终端驱动程序完整性的方法及系统
CN112988213B (zh) * 2021-04-13 2023-11-14 荣耀终端有限公司 一种程序数据更新方法、电子设备及计算机存储介质

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108241514A (zh) * 2017-12-28 2018-07-03 宁德时代新能源科技股份有限公司 车载程序更新方法和装置
KR102064519B1 (ko) * 2018-12-04 2020-01-09 인포뱅크 주식회사 차량 ecu 소프트웨어 업데이트 방법, 그를 수행하기 위한 장치 및 시스템
CN111818463A (zh) * 2019-08-13 2020-10-23 北京骑胜科技有限公司 传输镜像文件的方法、装置、存储介质及电子设备
CN112882742A (zh) * 2019-11-30 2021-06-01 华为技术有限公司 软件更新方法以及相关设备
CN112181463A (zh) * 2020-09-29 2021-01-05 广州汽车集团股份有限公司 一种ecu的更新方法及主节点设备

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4361798A4 *

Also Published As

Publication number Publication date
EP4361798A1 (en) 2024-05-01
CN113853580A (zh) 2021-12-28
EP4361798A4 (en) 2024-07-24

Similar Documents

Publication Publication Date Title
US20210344700A1 (en) Vehicle security monitoring apparatus, method and non-transitory computer readable medium
CN108107875B (zh) 一种汽车诊断方法、装置和车辆通讯接口
CN112817617B (zh) 软件升级方法、装置和系统
US20190034192A1 (en) Hot updates to ecu software using tool chain
EP3609138A1 (en) Method for detecting unauthorized communication, system for detecting unauthorized communication, and program
US20150331686A1 (en) Over-the-air vehicle issue resolution
WO2017187997A1 (ja) 車両制御システム検証装置、車両制御システム、及び車両制御システム検証方法
US20220156057A1 (en) In-vehicle update device, update processing program, and program update method
CN112913190A (zh) 基于空中下载技术ota的升级方法及装置
EP3609139A1 (en) Method for determining reference for unauthorized communication detection, system for determining reference for unauthorized communication detection, and program
JP7176488B2 (ja) データ保存装置、及びデータ保存プログラム
WO2019188233A1 (ja) 処理装置
WO2023272570A1 (zh) 电子控制单元ecu更新的方法、ecu和终端
CN113302599A (zh) 可升级的交通工具计算方法和设备
CN111064630A (zh) 更新前和更新后交通工具总线流量指纹识别
EP4246844A1 (en) Data packet processing method and apparatus
WO2021106568A1 (ja) 車載更新装置、プログラム及び、プログラムの更新方法
US20220207129A1 (en) On-board computer, computer execution method, and computer program
JP6519829B1 (ja) 電子制御装置、監視方法、プログラム及びゲートウェイ装置
US20220284743A1 (en) Center device and in-vehicle electronic control device
CN113767034B (zh) 中心装置、数据分发系统以及记录限制实施程序的记录介质
CN115556682B (zh) 配置汽车控制器的方法、汽车控制器和汽车控制器系统
US12142094B2 (en) Center device, data distribution system, and computer program product for executing restriction on function of data
US20220300403A1 (en) Isolated software testing in production vehicles
WO2024105946A1 (ja) 車両データ収集装置及び車両データ収集システム

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21947524

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2021947524

Country of ref document: EP

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2021947524

Country of ref document: EP

Effective date: 20240125