Method and device for flashing vehicle electronic control unit (ECU) and related equipment

By storing multiple versions of ECU flash packages in the preset server and automatically switching to other versions of flash packages in the diagnostic device for retry, the problem of ECU flashing failure is solved, improving the flashing efficiency and security is improved, and after-sales cost is reduced.

CN119829082APending Publication Date: 2025-04-15LAUNCH TECH CO LTD

Patent Information

Application Number
CN202411784791.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-06
Publication Date
2025-04-15

AI Technical Summary

Technical Problem

The existing vehicle electronic control unit ECU flashing method can easily lead to the ECU flashing failure when there is an error in the flashing packet, causing the ECU to fail to work, the entire process is cumbersome and time-consuming, inefficient, and may even cause damage to the vehicle.

Method used

Multiple version flush packets of the ECU are stored in the preset server. The diagnostic device reads the version information of the vehicle ECU and uploads it to the server. The server generates an ECU upgrade list, including the latest, current and default version flush packet URLs. The diagnostic device obtains the flash package from these queues in turn and flashes to ensure that after the flash fails, it automatically switches to other versions of the flash package for retry.

Benefits of technology

By automatically switching to other versions of the flash package, the time-consuming re-flashing after the ECU flashing fails is avoided, the efficiency and security of the ECU flashing is improved, the after-sales cost is reduced, and the damage caused by the failure of the flashing is prevented.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119829082A_ABST
    Figure CN119829082A_ABST
Patent Text Reader

Abstract

The invention provides a vehicle electronic control unit ECU flashing method and device and related equipment, and the method comprises the steps: reading the version information of a whole vehicle ECU through diagnosis equipment, uploading the version information to a preset server, and receiving an ECU upgrading list returned by the preset server; the ECU upgrading list indicates the ECUs needing to be flashed, the diagnosis equipment stores the ECUs needing to be flashed into a flashed queue according to the flashed priorities of the ECUs, the latest flashed files are downloaded in sequence, and the ECUs are flashed. And after the ECU of the whole vehicle is flashed, if the ECU node which fails to be flashed by using the new version of the flashing package exists, storing the information of the ECU node into other flashing queues, then downloading flashing files of other versions in sequence, and flashing the ECU which fails to be flashed to the current version or the default version. By re-flashing the ECU failed in flashing, it is ensured that the ECU is successfully flashed as much as possible, the safety and efficiency of whole vehicle ECU flashing are improved, and the after-sales cost is saved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to vehicle diagnostic equipment, and in particular to a method, device and related equipment for flashing a vehicle electronic control unit (ECU). Background Art

[0002] With the continuous development of automotive electronics, more and more electronic control units (ECUs) are installed in cars. In the upgrade and flashing of ECUs, the diagnostic equipment reads the version information of all ECUs of the vehicle and uploads it to the server. The server returns the ECU list of the ECUs to be flashed and the uniform resource locator URL of the corresponding flashing file according to the uploaded information. The diagnostic equipment downloads the latest flashing package of each ECU to be flashed and upgrades the ECUs to be flashed in the whole vehicle. However, the above flashing method has the following problems: when there is an error in the flashing package, it will cause the ECU flashing to fail, and the ECU will not work. The user can only request the correct flashing package of the ECU again and flash it locally through the diagnostic equipment. The whole process is cumbersome, time-consuming, inefficient, and may even cause damage to the vehicle.

[0003] Therefore, how to avoid the time-consuming re-flashing of the ECU after a flash failure and improve the efficiency of the ECU flashing has become an urgent problem to be solved. Summary of the invention

[0004] The embodiment of the present application provides a method, device and related equipment for flashing a vehicle electronic control unit ECU, which is used to solve the problem that it takes a long time to re-flash the ECU after the ECU flashing fails, thereby improving the ECU flashing efficiency.

[0005] In a first aspect, a method for flashing a vehicle electronic control unit (ECU), which is applied to an ECU flashing system, wherein the ECU flashing system includes a diagnostic device and a preset server, wherein a communication connection is established between the diagnostic device and the preset server, and the method includes: the diagnostic device is connected to a target vehicle to read version information of an ECU in the target vehicle; the diagnostic device sends the version information of the ECU to the preset server; the preset server stores multiple version flashing packages of the ECU, and the preset server compares the version information of the ECU with the version information of the multiple version flashing packages of the ECU to generate an ECU upgrade list, wherein the ECU upgrade list includes a first node group, wherein the first node group includes one or more first nodes, wherein the first node includes indication information of the ECU, a first uniform resource locator (URL), a second URL, and a third URL, wherein the multiple version flashing packages include a latest version flashing package, a current version flashing package, and a default version flashing package, wherein the first URL indicates the latest version flashing package, the second URL indicates the current version flashing package, and the third URL indicates the default version flashing package; and the preset server returns the ECU upgrade list to the diagnostic device, The diagnostic device parses the ECU upgrade list to obtain the first node group, generates a first flash queue, and the first flash queue is used to store the first node group; the diagnostic device obtains the latest version flash package based on the first URL of the first node, and flashes the ECU corresponding to the first node based on the latest version flash package; the diagnostic device obtains the first node where the ECU fails to be flashed, generates a second flash queue, and the second flash queue is used to store the second node group, the second node group includes one or more second nodes, and the second node is the first node where the ECU fails to be flashed; the diagnostic device obtains the current version flash package based on the second URL of the second node, and flashes the ECU corresponding to the second node based on the current version flash package; the diagnostic device obtains the second node where the ECU fails to be flashed, generates a third flash queue, and the third flash queue is used to store the third node group, the third node group includes one or more third nodes, and the third node is the second node where the ECU fails to be flashed; the diagnostic device obtains the default version flash package based on the third URL of the third node, and flashes the ECU corresponding to the third node based on the default version flash package.

[0006] In combination with the first aspect, the preset server compares the version information of the ECU with the version information of multiple version flash packages of the ECU, and the version information includes the software version number, specifically including: the preset server determines whether the software version number of the ECU is consistent with the software version number of the latest version flash package in the multiple version flash packages of the ECU; if the software version number of the ECU is inconsistent with the software version number of the latest version flash package in the multiple version flash packages of the ECU, the ECU is determined to be the ECU to be flashed, and the ECU upgrade list includes multiple version flash packages indicating the ECU to be flashed.

[0007] In combination with the first aspect, in some implementation methods provided in the first aspect, the indication information of the ECU includes a flash priority. After the diagnostic device generates a first flash queue, the method further includes: the diagnostic device arranges the first node group in the first flash queue based on the flash priority of the first node; after the diagnostic device generates a second flash queue, the method further includes: the diagnostic device arranges the second node group in the second flash queue based on the flash priority of the second node; after the diagnostic device generates a third flash queue, the method further includes: the diagnostic device arranges the third node group in the third flash queue based on the flash priority of the third node.

[0008] In combination with the first aspect, in the previous implementation method provided in the first aspect, the diagnostic device obtains the latest version flash package based on the first URL of the first node, and flashes the ECU corresponding to the first node based on the latest version flash package, specifically including: the diagnostic device sequentially obtains the latest version flash package corresponding to the first URL in the first node based on the arrangement order of the first nodes in the first queue, and sequentially flashes the ECU corresponding to the first node based on the latest version flash package; the diagnostic device obtains the current version flash package based on the second URL of the second node, and flashes the ECU corresponding to the second node based on the current version flash package, specifically The method comprises: the diagnostic device sequentially obtains the current version flash package corresponding to the second URL in the second node based on the arrangement order of the second node in the second queue, and sequentially flashes the ECU corresponding to the second node based on the current version flash package; the diagnostic device obtains the default version flash package based on the third URL of the third node, and flashes the ECU corresponding to the third node based on the default version flash package, specifically comprising: the diagnostic device sequentially obtains the default version flash package corresponding to the third URL in the third node based on the arrangement order of the third node in the third queue, and sequentially flashes the ECU corresponding to the third node based on the default version flash package.

[0009] In combination with the first aspect, in some implementation methods provided in the first aspect, after the ECU corresponding to the third node is flashed based on the default version flash package, the method also includes: the diagnostic device obtains the first node where the ECU is flashed successfully, and displays a first message, wherein the first message is used to indicate the ECU in the first node that is flashed successfully; the diagnostic device obtains the second node where the ECU is flashed successfully, and displays a second message, wherein the second message is used to indicate the ECU in the second node that is flashed successfully; the diagnostic device obtains the third node where the ECU is flashed successfully, and displays a third message, wherein the third message is used to indicate the ECU in the third node that is flashed successfully; the diagnostic device obtains the third node where the ECU fails to be flashed, and displays a fourth message, wherein the fourth message is used to indicate the ECU in the third node that fails to be flashed.

[0010] In the second aspect, a diagnostic device is provided, including: an ECU acquisition unit, used to read the version information of all ECUs in the vehicle; a first communication unit, used to upload the version information of the ECU to a preset server, and receive an ECU upgrade list returned by the preset server, the ECU upgrade list is used to indicate the ECUs that need to be flashed; a queue filling unit, used to fill each ECU that needs to be flashed into a preset flash queue in sequence according to the flash priority of each ECU that needs to be flashed, the flash queue includes a first flash queue, a second flash queue and a third flash queue, the first flash queue is used to fill the ECUs that need to be flashed indicated by the ECU upgrade list, the second flash queue is used to fill the ECUs that failed to be flashed in the first flash queue, and the third flash queue is used to fill the ECUs that failed to be flashed in the second flash queue; an ECU flash unit, used to determine the current ECU to be flashed from the flash queue in sequence according to a preset sequential execution method, and read the ECU The URL in the upgrade list is used to flash the ECU to be flashed based on the ECU flash package corresponding to the URL. Specifically, the ECU flash unit flashes the ECUs in the first flash queue, and fills the ECUs in the first flash queue that fail to be flashed into the second flash queue through the queue filling unit. The ECU flash unit flashes the ECUs in the second flash queue, and fills the ECUs in the second flash queue that fail to be flashed into the third flash queue through the queue filling unit. The ECU flash unit flashes the ECUs in the third flash queue, wherein the ECU flash package corresponding to the URL is located in the preset server, and the URL includes a first URL, a second URL and a third URL. The ECU flash package corresponding to the first URL is used to flash the first flash queue, the ECU flash package corresponding to the second URL is used to flash the second flash queue, and the ECU flash package corresponding to the third URL is used to flash the third flash queue.

[0011] In a third aspect, a preset server is provided, comprising: a second communication unit, used to receive the current version information of all ECUs sent by the diagnostic device, and return an ECU upgrade list to the diagnostic device, the ECU upgrade list being used to indicate the ECU to be flashed and the URL of the ECU flash package, and also used to receive the URL sent by the receiving diagnostic device, and return the ECU flash package of the version corresponding to the URL to the diagnostic device; a storage unit, used to store the flash packages of various versions of the ECU; a version judgment unit, used to judge whether the current version information and the latest version flash packages of all ECUs stored locally are consistent after the preset server receives the current version information of all ECUs sent by the diagnostic device, if the current version information and the latest version flash package stored locally are inconsistent, then determine the ECU as the ECU to be flashed; an ECU upgrade list generation unit, used to carry the information of the ECU to be flashed and the URL of the ECU flash package in the ECU upgrade list.

[0012] In a fourth aspect, an electronic device is provided, comprising one or more memories and one or more processors; the memory is coupled to the one or more processors, the memory is used to store computer program code, the computer program code comprises computer instructions, and the one or more processors call the computer instructions so that the electronic device executes any one of the methods executed by the diagnostic device in the first aspect or the first aspect.

[0013] In a fifth aspect, a computer-readable storage medium is provided, on which computer instructions are stored. When the computer instructions are executed by a processor, they implement the method as described in the first aspect or any one of the methods performed by the diagnostic device in the first aspect.

[0014] In a sixth aspect, a computer device is provided, comprising a memory, a processor and a computer program stored in the memory, wherein the processor executes the computer program to implement any one of the method steps performed by the diagnostic device in the first aspect or the first aspect.

[0015] The present application provides a method for flashing a vehicle electronic control unit ECU. The method stores the flashing package of the ECU in a preset server. The diagnostic device reads the version information of the vehicle ECU and uploads it to the preset server, and receives the ECU upgrade list ECUFlashList returned by the preset server. The ECUFlashList indicates the ECU that needs to be flashed. The diagnostic device stores the ECU that needs to be flashed in the flashing queue according to the flashing priority of the ECU, downloads the latest flashing files in sequence, and flashes the ECU. After the flashing of the whole vehicle ECU is completed, if the diagnostic device obtains an ECU node that fails to be flashed using the new version of the flashing package, its information is stored in other flashing queues, and then the flashing files of other versions are downloaded in sequence, and the ECU that failed to be flashed is flashed to the current version or the default version. The above method ensures that the ECU is flashed successfully as much as possible by re-flashing the ECU that failed to be flashed, thereby avoiding the problem that the ECU is unavailable after the ECU flashing fails, ensuring the convenience of flashing the whole vehicle ECU, improving the safety and efficiency of flashing the whole vehicle ECU, and saving after-sales costs. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] Figure 1 A flowchart of a method for flashing a vehicle electronic control unit ECU provided in an embodiment of the present application;

[0017] Figure 2 A schematic diagram of an ECUFlashList structure provided in an embodiment of the present application;

[0018] Figure 3 A schematic diagram of an ECU node structure provided in an embodiment of the present application;

[0019] Figure 4 A schematic diagram of another ECUFlashList structure provided in an embodiment of the present application;

[0020] Figure 5 A schematic diagram of a flash queue structure provided in an embodiment of the present application;

[0021] Figure 6 A flowchart of another method for flashing a vehicle electronic control unit ECU provided in an embodiment of the present application;

[0022] Figure 7 A schematic diagram of a communication system provided in an embodiment of the present application;

[0023] Figure 8 A schematic diagram of a diagnostic device structure provided in an embodiment of the present application;

[0024] Fig. 9 A schematic diagram of a preset server structure provided in an embodiment of the present application;

[0025] Fig.10 A schematic diagram of the hardware structure of the diagnostic device provided in the embodiment of the present application;

[0026] Fig.11 A schematic diagram of the hardware structure of the preset server provided in an embodiment of the present application. DETAILED DESCRIPTION

[0027] The terms used in the following embodiments of the present application are only for the purpose of describing specific embodiments and are not intended to be limiting of the present application. The technical solutions in the embodiments of the present application will be clearly and comprehensively described below in conjunction with the accompanying drawings. Among them, in the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in the text is only a description of the association relationship of associated objects, indicating that three relationships can exist, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone.

[0028] In the following, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as suggesting or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features, and in the description of the embodiments of the present application, unless otherwise specified, "plurality" means two or more.

[0029] First, several terms involved in the embodiments of the present application are introduced:

[0030] Electronic Control Unit (ECU). ECU is used to control the driving state of the vehicle and realize its various functions. It mainly uses data collection and exchange of various sensors and buses to judge the vehicle status and the driver's intention and control the vehicle through actuators. Common ECUs include but are not limited to the following: Engine Management System (EMS), Head Up Display (HUD), Air Conditioning (AC), Forward Collision Warning System (FCS), Electronic Stability Program (ESP), Battery Management System (BMS) and Vehicle Control Unit (VCU), etc. The ECU involved in the embodiments of the present application may include any one or more of the above.

[0031] The above are the terms involved in the embodiments of this application.

[0032] With the continuous development of automotive electronics, more and more ECUs are installed in cars, and the requirements for ECU upgrade and flashing are getting higher and higher. Traditional flashing is that the OEM sends the ECU that needs to be flashed to the user, and the user selects the flashing package locally to flash the ECU until all ECUs of the vehicle are upgraded. This is extremely inefficient and difficult to control the flashing authority. Later, with the development of the network, the whole vehicle flashing was gradually added to the networking function, that is, the diagnostic equipment software reads the version information of all ECUs of the vehicle and uploads it to the server. The server returns the list of ECUs that need to be flashed and upgraded and the download URL of the corresponding flashing file according to the uploaded information. The diagnostic equipment downloads the flashing packages of each ECU to be flashed based on the URL of the flashing file, and upgrades the ECUs in turn until the upgrade of the ECUs to be flashed is completed. However, the above method has the following problems: when there is an error in the flashing package of the ECU, the corresponding ECU will fail to flash. At this time, the ECU will not work. The user can only request the correct flashing package of the ECU and then use the diagnostic equipment to flash locally. The whole process is also very cumbersome and time-consuming, inefficient, and there is no fault tolerance mechanism for flashing failure, which may even cause damage to the vehicle.

[0033] In order to solve the problem of low efficiency and long time consumption of ECU flashing caused by ECU flashing failure, the embodiment of the present application provides a method for flashing the vehicle electronic control unit ECU. In this method, a preset server stores the flashing packages of various versions of the whole vehicle ECU. The diagnostic device flashes the whole vehicle ECU, reads the version information of the whole vehicle ECU and uploads it to the preset server. The preset server determines the ECU that needs to be upgraded in the target vehicle by comparing the version information (such as software version number) of the whole vehicle ECU and the latest version information of the corresponding ECU, and generates an ECU upgrade list (ECUFlashList). ECUFlashList includes multiple ECU nodes, each ECU node records an ECU information that needs to be upgraded, including: software version, hardware version, vendor code, flashing priority, and 3 uniform resource locators (Uniform Resource Locator, URL). Among them, the 3 URLs include the latest flashing package download URL (URL_New), the current flashing package download URL (URL_Now), and the default flashing package download URL (URL_Default) of this ECU. The diagnostic device parses the ECUFlashList information returned by the preset server, initializes the first flash queue (FlashQueue_First), and downloads the latest flash file through URL_New in sequence according to the flash priority of the ECU node to flash the ECU. After the flash of the entire vehicle ECU is completed, if there is an ECU node that fails to be flashed using the new version of the flash package, the diagnostic device stores its information in the second flash queue (FlashQueue_Second). At this time, the diagnostic device downloads the current software version of the ECU through URL_Now (that is, restores the software version of the ECU before the flash is executed), and restores the ECU that failed to be flashed to the version before the flash according to the flash priority of the node in FlashQueue_Second. After all nodes in FlashQueue_Second are flashed, if there are still ECU nodes that failed to be flashed, their information is stored in the third flash queue (FlashQueue_Third). At this time, the diagnostic software downloads the default software version of the ECU from URL_Default and performs the flash. After all nodes in FlashQueue_Third are flashed, if there are still ECUs that fail to flash, it can be considered that the ECU is damaged, and the diagnostic equipment can remind the user to contact the manufacturer for further processing. At this point, the flashing of the entire vehicle ECU is completed. The above method uses three rounds of automatic flashing, which not only ensures the convenience of flashing the entire vehicle, but also automatically restores to the pre-flashing version or the default available version after some ECUs fail to flash, avoiding the situation where the ECU is unavailable after the ECU flash fails, thereby greatly improving the safety and efficiency of the entire vehicle flashing and saving after-sales costs.

[0034] like Figure 1 As shown, the embodiment of the present application discloses a method for flashing a vehicle electronic control unit ECU, which is applied to a diagnostic device and specifically includes the following steps:

[0035] S101. Obtain the version information of the vehicle ECU and upload it to the preset server.

[0036] In an embodiment of the present application, the diagnostic device can establish a connection with the target vehicle to obtain the version information of the vehicle ECU. The ECU version information includes but is not limited to: software version number, hardware version number, and flash priority. Exemplarily, the diagnostic device establishes a connection with the vehicle through the On-Board Diagnostics (OBD) interface to obtain the software version number of the target vehicle ECU.

[0037] In the embodiment of the present application, the diagnostic device can establish a connection with a preset server via a wireless network. The preset server locally stores various versions of refresh packages of the vehicle ECU. After receiving the version information of the vehicle ECU, the preset server compares the latest version of the ECU refresh package with the version information of the vehicle ECU, determines the ECU in the vehicle ECU that has a low version and needs to be upgraded, that is, the ECU to be flashed, and carries the information of the ECU to be flashed in the ECU upgrade list (ECUFlashList).

[0038] Among them, ECUFlashList includes multiple ECU nodes, and the ECU node can be called the first node. Figure 2 As shown, exemplarily, ECUFlashList includes 4 ECU nodes, namely ECU node 1, ECU node 2, ECU node 3 and ECU node 4. The number of ECU nodes is consistent with the number of ECUs that need to be upgraded, and each ECU node records an ECU information to be flashed. The embodiment of the present application does not limit the number of ECU nodes in ECUFlashList.

[0039] It should be noted that each ECU node includes a variety of information about the ECU. Figure 3 As shown, illustratively, an ECU node includes but is not limited to the following information: ECU name, software version number, hardware version number, vendor code, flashing priority, latest version flashing package download URL (URL_New), current version flashing package download URL (URL_Now), default version flashing package download URL (URL_Default). The embodiment of the present application does not limit the type of ECU information recorded in the ECU node.

[0040] like Figure 4As shown, exemplarily, 4 ECU nodes are shown in one ECUFlashList. In ECU node 1, the ECU name is "EMS", the software version number of the ECU is "V1234", the hardware version number of the ECU is "V3256", the supplier code is "1048576", the priority of the ECU flash is 3, the latest flash package download URL (URL_New) of the ECU is "https: / / testDownload.com / / EMSV1234V3256", the current version of the ECU flash package download URL (URL_Now) is "https: / / testDownload.com / / EMSV1022V3256", and the default flash package download URL (URL_Default) of the ECU is "https: / / testDownload.com / / EMSV1001V3256". Similarly, the ECU information with the ECU name "AC" is shown in ECU node 2. The software version number of the ECU is "V3263", the hardware version number is "V2375", the vendor code is "2048341", the flash priority is 1, the URL_New is "https: / / testDownload.com / / ACV3263V2375", the URL_Now is "https: / / testDownload.com / / AGV3260V2375", and the URL_Default is "https: / / testDownload.com / / ACV3255V2375". Similarly, the data structure in ECU node 3 and ECU node 4 is the same as that in ECU node 1 and ECU node 2, and you can refer to the above Figure 4 The specific data contents of ECU node 3 and ECU node 4 are not described here.

[0041] In the embodiment of the present application, the preset server returns the above ECUFlashList to the diagnostic device, and the diagnostic device receives the ECUFlashList and executes the subsequent step S102.

[0042] In some embodiments, the target vehicle can run the diagnostic software in the diagnostic device, obtain the version information of the target vehicle's own ECU, and send the version information of the entire vehicle ECU to the preset server. In the subsequent steps S102-S110, the target vehicle can also execute the solution through the diagnostic software, and the embodiments of the present application do not limit this.

[0043] S102. Receive the ECUFlashList sent by the preset server, parse the ECUFlashList to obtain the ECU node information to be flashed.

[0044] In the embodiment of the present application, the ECU node information obtained by the diagnostic device indicates the ECU that needs to be flashed in the target vehicle, which can be called the first node information. Among them, the ECU that needs to be flashed includes one or more. When there is only one ECU that needs to be flashed, the diagnostic device can directly download the flash package of the ECU for flashing after the ECU is filled into the flash queue, without sorting the ECU node information; when multiple ECUs need to be flashed, the ECU node information needs to be arranged in order in the flash queue, and the subsequent S103 step is executed.

[0045] S103. Fill the ECU node information to be flashed into the first flashing queue.

[0046] In the embodiment of the present application, the diagnostic device initializes the first flash queue (FlashQueue_First), and arranges the first node information in FlashQueue_First in order according to the flash priority in the first node information. For example, the first node information with a high flash priority is arranged after the first node information with a low flash priority, and the first node information is arranged in FlashQueue_First. The queue group filled with multiple first nodes can be called a first node group. Figure 5 As shown, for example, in the first node information, the write priority of "EMS" is 3, the write priority of "AC" is 1, the write priority of "FCS" is 4, and the write priority of "HUD" is 2, then FlashQueue_First arranges the first node information from the tail of the queue to the head of the queue as "FSC->EMS->HUD->AC", and the node group obtained by filling the first queue with the first nodes "EMS", "AC", "FCS" and "HUD" can be called the first node group.

[0047] S104. Download the flash package of each ECU through the “URL_New” in each node, and flash the ECU according to the flash priority.

[0048] In the embodiment of the present application, the diagnostic device downloads the flash package from the end of the queue to the head of the queue in the order of the first node information in FlashQueue_First, and flashes the ECU of the whole vehicle in sequence. The diagnostic device downloads the flash package of the latest version of the ECU through the URL_New in the first node information. Figure 5 As shown, illustratively, the diagnostic device obtains the latest version of the flash package indicated by URL_New in the corresponding ECU in the order of "FSC->EMS->HUD->AC", and flashes the ECU of the entire vehicle in sequence.

[0049] S105. Determine whether there is an ECU whose flashing fails in the first node information.

[0050] In an embodiment of the present application, after the ECU indicated by the first node information is flashed, the diagnostic device determines whether there is an ECU that failed to be flashed. If so, the ECU that failed to be flashed needs to be flashed again, and the subsequent steps shown in S106 are executed. The first node corresponding to the ECU that failed to be flashed can be called the second node, and the first node information corresponding to the ECU that failed to be flashed can be called the second node information; if not, the ECU of the entire vehicle is flashed. The diagnostic device can display a message to the user that all ECUs of the entire vehicle have been flashed to the latest version, and this message can be called the first message.

[0051] Among them, the first node corresponding to the ECU that failed to be flashed can be called the second node, and the first node information corresponding to the ECU that failed to be flashed can be called the second node information, such as Figure 5 As shown, for example, the "EMS" and "HUD" in the first node fail in the first round of ECU flashing, and the nodes of the "EMS" and "HUD" can be called the second node, and the node information of the "EMS" and "HUD" can be called the second node information. The queue group filled with multiple second nodes can be called the second node group, and the node group of the "EMS" and "HUD" can be called the second node group.

[0052] S106. Fill the ECU node information that failed to be flashed into the second flashing queue.

[0053] In the embodiment of the present application, the diagnostic device initializes the second flash queue (FlashQueue_Second), and arranges the second node information in FlashQueue_Second in order according to the flash priority in the second node information. For example, the second node information with a high flash priority is arranged after the second node information with a low flash priority, and the second node information is arranged in FlashQueue_Second. Figure 5 As shown, for example, in the second node information, the write priority of "EMS" is 3, and the write priority of "HUD" is 2, then FlashQueue_Second arranges the second node information from the tail of the queue to the head of the queue in the manner of "EMS->HUD", and the node group obtained by filling the second queue with the second nodes "EMS" and "HUD" can be called the second node group.

[0054] S107. Download the flash package of each ECU through the “URL_Now” in each node, and flash the ECU according to the flash priority.

[0055] In the embodiment of the present application, the diagnostic device downloads the flash package from the end of the queue to the head of the queue in the order of the second node information in FlashQueue_Second, flashes the ECU that failed in the first round of flashing again, and re-flashes the current version of the ECU (i.e., restores it to the version before flashing). The diagnostic device downloads the flash package of the current version of the ECU through the URL_Now in the second node information. Figure 5 As shown, exemplarily, the diagnostic device obtains the flashing package of the current version indicated by URL_Now in the corresponding ECU in the order of "EMS->HUD", and flashes the aforementioned ECU in sequence.

[0056] S108. Determine whether there is an ECU whose flashing fails in the second node information.

[0057] In an embodiment of the present application, after the ECU indicated by the second node information is flashed, the diagnostic device determines whether there is an ECU that failed to flash for the second time. If so, the ECU that failed to flash for the second time needs to be flashed again, and the subsequent steps shown in S109 are executed. The second node corresponding to the ECU that failed to flash for the second time can be called the third node, and the second node information corresponding to the ECU that failed to flash for the second time can be called the third node information; if not, it is considered that the ECU flashing of the entire vehicle is completed, and the diagnostic device can display a message to the user that the ECUs corresponding to the second node information have been flashed to the current version, and the message can be called the second message.

[0058] Among them, the second node corresponding to the ECU that failed to flash for the second time can be called the third node, and the second node information corresponding to the ECU that failed to flash for the second time can be called the third node information, such as Figure 5 As shown, exemplarily, the "EMS" in the second node fails in the second round of ECU flashing, the node of the "EMS" can be called the third node, and the node information of the "EMS" can be called the third node information. The queue group filled with multiple third nodes can be called the third node group.

[0059] S109. Fill the ECU node information that failed to be flashed into the third flashing queue.

[0060] In the embodiment of the present application, the diagnostic device initializes the third flash queue (FlashQueue_Third), and arranges the third node information in FlashQueue_Third according to the flash priority in the third node information. For example, the third node information is arranged in FlashQueue_Second in the order that the third node information with a high flash priority is arranged after the third node information with a low flash priority. When the number of the third node is one, the third node can be arranged at the head of the queue of the third queue, such as Figure 5 As shown, exemplarily, the third node information only has "EMS", then FlashQueue_Third arranges the third node information corresponding to the "EMS" at the head of the queue.

[0061] S110. Download the flash package of each ECU through the “URL_Default” in each node, and flash the ECU according to the flash priority.

[0062] In the embodiment of the present application, the diagnostic device downloads the flash package from the end of the queue to the head of the queue in the order of the arrangement of the third node information in FlashQueue_Third, flashes the ECU that failed in the second round of flashing again, and flashes the ECU to the default version (restoring the ECU to the default version). The diagnostic device downloads the flash package of the default version of the ECU through the URL_Default in the third node information. Figure 5 As shown, exemplarily, the diagnostic device obtains the default version of the flash package indicated by URL_Default in the "EMS" node information, and flashes the aforementioned ECU.

[0063] In an embodiment of the present application, after the ECU flashing indicated by the third node information is completed, the diagnostic device determines whether there is an ECU that failed to be flashed for the third time. If so, the ECU that failed to be flashed for the third time has been damaged, and the diagnostic device prompts the user through a message that further processing is required for the ECU that failed to be flashed for the third time, such as contacting the manufacturer for processing. This message can be called the fourth message; if not, it is considered that the ECU flashing of the entire vehicle is completed, and the diagnostic device can display a message to the user that the ECUs corresponding to the third node information have all been flashed with the default version. This message can be called the third message.

[0064] like Figure 5 As shown, exemplarily, if the "EMS" in the third node information fails to be flashed, the diagnostic device can display the fourth message to the user; if the "EMS" in the third node information is flashed successfully, the diagnostic device can display the third message to the user.

[0065] Based on the flashing method of the vehicle electronic control unit ECU shown in the above steps S101-S110, the diagnostic device realizes automatic restoration to the version before flashing or the default available version when the ECU flashing fails, avoiding the situation where the ECU is unavailable after the ECU flashing fails. This method can not only ensure the convenience of flashing the whole vehicle ECU, but also improve the safety and efficiency of flashing the whole vehicle ECU, saving after-sales costs.

[0066] The present application also provides another flashing method for a vehicle electronic control unit ECU, such as Figure 6 As shown, Figure 6A method flow chart of another method for flashing a vehicle electronic control unit ECU provided in an embodiment of the present application is applied to a preset server and specifically includes the following steps:

[0067] S201. Receive the version information of the vehicle ECU, and compare the version information of the vehicle ECU with the latest version flash package of the ECU stored locally to see if they are consistent.

[0068] In the embodiment of the present application, the preset server locally stores the flashing packages of various versions of the vehicle ECU. The flashing packages of the vehicle ECU can be preset in the preset server, or the preset server can obtain the flashing packages of various versions of the ECU through the Internet. The embodiment of the present application does not limit the method for the preset server to obtain the flashing package of the vehicle ECU.

[0069] In an embodiment of the present application, the preset server can receive the version information of the vehicle ECU sent by the diagnostic device through a wireless network, and compare it with the latest version of the ECU flash package stored locally. The version information of the ECU includes the software version number. For example, the preset server obtains the software version number of the EMS in the diagnostic device, and compares it with the latest version of the EMS flash package stored locally on the preset server. If the two software version numbers are consistent, the EMS in the target vehicle is the latest version and does not need to be flashed; if the two software version numbers are inconsistent, the EMS in the target vehicle is not in the latest version, and the EMS may be the ECU to be flashed, and the subsequent steps shown in S202 are executed.

[0070] S202. Determine the ECU whose version information of the vehicle ECU is inconsistent with the latest version of the ECU flash package stored locally.

[0071] In the embodiment of the present application, the preset server compares the version information of the vehicle ECU in sequence to determine all the ECUs to be flashed. Exemplarily, the vehicle ECU includes EMS, HUD, AC, FCS, ESP, BMS and VCU, etc. The preset server can determine that EMS is the ECU to be flashed through step S201. Similarly, the preset server can determine in sequence whether the subsequent HUD, AC, FCS, ESP, BMS and VCU are the ECUs to be flashed, and finally determine that EMS, HUD, AC and FCS are the ECUs to be flashed.

[0072] S203. Generate ECUFlashList and send ECUFlashList to the diagnostic device.

[0073] In an embodiment of the present application, the preset server carries the ECU information to be flashed in the ECU upgrade list (ECUFlashList) based on the ECU to be flashed determined in the aforementioned step S202. Exemplarily, in the aforementioned step S202, the ECU to be flashed includes EMS, HUD, AC and FCS. The preset server adds four ECU nodes of EMS, HUD, AC and FCS in the ECUFlashList in sequence, and each ECU node records the information required to flash the ECU, including the ECU name, software version number, hardware version number, vendor code, flash priority, URL_New, URL_Now and URL_Default. The description of the ECUFlashList structure can refer to the aforementioned step S101, which will not be repeated here.

[0074] In the embodiment of the present application, the preset server can send the generated ECUFlashList to the diagnostic device via a wireless network, instructing the diagnostic device to flash the ECU to be flashed, and the diagnostic device executes the aforementioned steps S102-S110, which will not be repeated here.

[0075] S204. Receive the URL sent by the diagnostic device, and return the ECU flash package corresponding to the URL to the diagnostic device.

[0076] In an embodiment of the present application, the preset server can receive the URL sent by the diagnostic device, and the diagnostic device will obtain different versions of the ECU flash package from the preset server based on the flash status of the ECU. The preset server returns the corresponding version of the flash package to the diagnostic device based on the received URL. Exemplarily, the preset server receives URL_New and returns the latest version of the ECU flash package indicated by URL_New to the diagnostic device; the preset server receives URL_Now and returns the current version of the ECU flash package indicated by URL_Now to the diagnostic device; the preset server receives URL_Default and returns the default version of the ECU flash package indicated by URL_Default to the diagnostic device.

[0077] Based on the flashing method of the vehicle electronic control unit ECU shown in the above steps S201-S204, the preset server stores the flashing packages of various versions of the vehicle ECU, and returns the download URL of the flashing packages of various versions of the ECU to be flashed to the diagnostic device through ECUFlashList, supporting the diagnostic device to automatically restore to the version before flashing or the default available version when the ECU flashing fails, avoiding the situation where the ECU is unavailable after the ECU flashing fails. This method can ensure the convenience of flashing the vehicle ECU, improve the safety and efficiency of the vehicle ECU flashing, and save after-sales costs.

[0078] Figure 7The communication system architecture is shown, which is an exemplary architecture diagram of a communication system applicable to the embodiment of the present application. The communication system includes a diagnostic device 100, a preset server 200, and a target vehicle 300. The diagnostic device 100, the preset server 200, and the target vehicle 300 can communicate with each other. In the embodiment of the present application, the communication system is also called an inspection system.

[0079] The diagnostic device 100 may be distributed throughout the communication system and may be stationary or mobile. In some embodiments of the present application, the diagnostic device 100 may include a user equipment (UE), a mobile device, a mobile station, a mobile unit, a machine to machine (M2M) terminal, a wireless unit, a terminal device, a remote unit, a terminal agent, a mobile client, and the like.

[0080] The diagnostic device 100 can establish a connection with the ECU in the target vehicle 300 through the OBD interface to obtain the version information of the ECU in the target vehicle 300.

[0081] The version information of the ECU in the target vehicle 300 includes software version, hardware version, flashing priority, etc. The version information of the ECU can be modified synchronously with the modification of the ECU, and is used to indicate the ECU version currently running in the target vehicle 300.

[0082] The diagnostic device 100 sends the obtained version information of the vehicle ECU to the preset server 200, and the preset server 200 receives and compares the ECU version information with the latest version flash package of the ECU stored locally.

[0083] The preset server 200 may include a data management system, and the database management system includes storage of various versions of flash packages of the ECU. In some embodiments, the preset server can access the resource address of the ECU supplier, obtain the latest version of the flash package of the ECU in real time, and store it in the database management system. The database management system also stores other versions of the flash packages of the ECU, including the current flash package and the default flash package of the ECU, which is used to provide the ECU with other flash packages after the flash of the latest version fails.

[0084] After receiving the vehicle ECU version sent by the diagnostic device 100, the preset server 200 compares the vehicle ECU version information (such as the software version number) with the latest version of the corresponding ECU flash package through the data management system to see if they are consistent. If the two software version numbers are inconsistent, the preset server 200 determines that the ECU is the ECU to be flashed; if the two software version numbers are consistent, the preset server 200 determines that the ECU is the latest version of the ECU. Exemplarily, if the version information of the EMS is the first version number, and the latest version of the flash package of the EMS in the preset server 200 is the second version number, the preset server 200 determines that the EMS is the ECU to be flashed; if the version information of the ESP is the third version number, and the latest version of the flash package of the ESP in the preset server 200 is the third version number, the preset server 200 determines that the ESP is the latest version of the ECU.

[0085] In some embodiments, the communication system may include more or fewer devices, for example, the communication system includes a target vehicle 300 and a preset server 200. That is, the target vehicle 300 and the diagnostic device 100 may be the same device, and the communication between the target vehicle 300 and the diagnostic device 100 is internal communication of the device. The target vehicle 300 communicates with the preset server 200 via a wireless network to execute the scheme shown in the aforementioned diagnostic device 100.

[0086] In the above introduction, the communication method provided in the embodiment of the present application is applied to Figure 7 The communication system shown. In addition, the method can be performed by two communication devices, such as a first communication device and a second communication device. Among them, the first communication device can be a diagnostic device 100 and a target vehicle 300, or a communication device that can support the diagnostic device 100 to implement the functions required by the method, and of course it can also be other communication devices, such as a chip system. For the second communication device, it can be a preset server 200 or a communication device that can support the preset server 200 to implement the functions required by the method, and of course it can also be other communication devices, such as a chip system.

[0087] If the embodiment of the present application is applied to Figure 7 The communication system shown in FIG. 1 , the diagnostic device described above may be Figure 7 The diagnostic device 100 in the communication system shown. It should be noted that the embodiment of the present application is only performed by the diagnostic device 100, the preset server 200, and the target vehicle 300 as an example, and is not limited to the diagnostic device 100.

[0088] based on Figure 7 The communication system shown, Figure 8 The structure of the diagnostic device provided in the embodiment of the present application is shown, including the following units:

[0089] The ECU acquisition unit 801 is used to acquire the version information of all ECUs in the vehicle.

[0090] The queue filling unit 802 is used to fill each ECU that needs to be flashed into a preset flashing queue in sequence according to the flashing priority of each ECU that needs to be flashed.

[0091] Among them, the flash queue includes a first flash queue, a second flash queue and a third flash queue. The first flash queue is used to fill the ECUs that need to be flashed indicated by the ECU upgrade list, the second flash queue is used to fill the ECUs that failed to be flashed in the first flash queue, and the third flash queue is used to fill the ECUs that failed to be flashed in the second flash queue.

[0092] The ECU flashing unit 803 is used to determine the ECU to be flashed from the flashing queue in sequence according to a preset sequential execution method, read the URL in the ECU upgrade list, and flash the ECU to be flashed based on the ECU flashing package corresponding to the URL.

[0093] Specifically, the ECU flashing unit flashes the ECUs in the first flashing queue; the ECUs that failed to be flashed in the first flashing queue are filled into the second flashing queue through the queue filling unit, and the ECU flashing unit flashes the ECUs in the second flashing queue; the ECUs that failed to be flashed in the second flashing queue are filled into the third flashing queue through the queue filling unit, and the ECU flashing unit flashes the ECUs in the third flashing queue. The ECU flashing package corresponding to the URL is located in the preset server, and the URL includes a first URL, a second URL, and a third URL. The ECU flashing package corresponding to the first URL is used to flash the first flashing queue, the ECU flashing package corresponding to the second URL is used to flash the second flashing queue, and the ECU flashing package corresponding to the third URL is used to flash the third flashing queue.

[0094] The first communication unit 804 is used to upload the version information of the ECU to the preset server, and receive the ECU upgrade list returned by the preset server, where the ECU upgrade list is used to indicate the ECUs that need to be flashed.

[0095] Figure 8 The diagnostic equipment shown, with Figure 1 The corresponding method of the vehicle ECU flashing shown is as follows:

[0096] The ECU acquisition unit 801 is used to execute the method of establishing a connection with the vehicle through the OBD interface in step S101 to acquire the version information of the vehicle ECU.

[0097] The queue filling unit 802 is used to execute the execution method of filling the flashing ECU node information into the flashing queue in steps S103, S105-S106 and S108-S109.

[0098] The ECU flashing unit 803 is used to execute steps S104, S107 and S110 to download the flashing package of each ECU through the URL in each ECU node, and flash the ECU according to the flashing priority.

[0099] The first communication unit 804 is used to perform the uploading of the vehicle ECU version information to the preset server as shown in step S101, and is also used to perform the execution method of receiving the ECUFlashList sent by the preset server as shown in step S102. The specific implementation methods of the above corresponding steps are not repeated in this embodiment of the application.

[0100] based on Figure 7 The communication system shown, Fig. 9 The preset server structure provided in the embodiment of the present application is shown, including the following units:

[0101] The version judgment unit 901 is used to judge whether the current version information of all ECUs sent by the diagnostic device is consistent with the latest version flash package of all ECUs stored locally after the preset server receives the current version information of all ECUs sent by the diagnostic device. If the current version information is inconsistent with the latest version flash package stored locally, the ECU is determined as the ECU to be flashed.

[0102] The storage unit 902 is used to store various version flashing packages of the ECU.

[0103] The ECU upgrade list generating unit 903 is used to carry the information of the ECU to be flashed and the URL of the ECU flashing package in the ECU upgrade list.

[0104] The second communication unit 904 is used to receive the current version information of all ECUs sent by the diagnostic device, and return an ECU upgrade list to the diagnostic device, where the ECU upgrade list is used to indicate the ECU to be flashed and the URL of the ECU flash package, and is also used to receive the URL sent by the diagnostic device and return the ECU flash package of the version corresponding to the URL to the diagnostic device.

[0105] Fig. 9 The vehicle inspection equipment shown is Figure 6 The flashing method of the vehicle electronic control unit ECU shown corresponds to the specific corresponding relationship as follows:

[0106] The version judgment unit 901 is used to perform the comparison of the version information of the vehicle ECU and the latest version of the ECU flash package stored locally as shown in steps S201-S202, and to determine the ECU whose version information of the vehicle ECU is inconsistent with the latest version of the ECU flash package stored locally.

[0107] The storage unit 902 is used to execute the preset server to locally store the flashing packages of various versions of the vehicle ECU as shown in step S201.

[0108] The ECU upgrade list generating unit 903 is used to generate the ECU upgrade list as shown in step S203.

[0109] The second communication unit 904 is used to receive the version information of the vehicle ECU as shown in step S201, and to send the ECU upgrade list as shown in step S203, and is also used to receive the URL sent by the diagnostic device as shown in step S024, and return the ECU flash package of the corresponding version of the URL to the diagnostic device. The specific implementation methods of the above corresponding steps are not repeated in the embodiment of the present application.

[0110] like Fig.10 The hardware structure of the diagnostic device provided in the embodiment of the present application is shown. The diagnostic device 100 includes: a processor 101, a memory 102, a communication module 104, and a computer program 103 stored in the memory 102 and executable on the processor 101. When the processor 101 executes the computer program 103, the following is achieved: Figure 1 Part or all of the steps of the vehicle electronic control unit ECU flashing method shown.

[0111] Exemplarily, the computer program 103 may be divided into one or more units / modules, and the one or more units / modules are stored in the memory 102 and executed by the processor 101 to complete the present application. The one or more units / modules may be a series of computer program instruction segments capable of completing specific functions, and the instruction segments are used to describe the execution process of the computer program 103 in the diagnostic device 100. For example, the computer program 103 may be used to obtain ECU version information, parse ECU upgrade lists, fill ECU flash queues, flash ECUs, etc. The specific functions or mechanisms have been described in the above embodiments and will not be repeated here.

[0112] Those skilled in the art will understand that Fig.10 It is only an example of the diagnostic device 100 and does not constitute a limitation of the diagnostic device 100. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the above-mentioned diagnostic device 100 may also include input and output devices, network access devices, buses, etc.

[0113] The processor 101 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.

[0114] The memory 102 may be an internal storage unit of the diagnostic device 100, such as a hard disk or memory of the diagnostic device 100. The memory 102 may also include both an internal storage unit of the diagnostic device 100 and an external storage device. The memory 102 is used to store the computer program and other programs and data required by the diagnostic device 100. The memory 102 may also be used to temporarily store data that has been output or is to be output. For example, the memory 102 may include a flash queue for storing information of the ECU to be flashed that is returned from a preset server.

[0115] The communication module 104 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR) and the like applied to the diagnostic device 100. The communication module 104 can be one or more devices integrating at least one communication processing module. The communication module 104 receives electromagnetic waves through the antenna, demodulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 101. The communication module 104 can also receive the signal to be sent from the processor 101, modulate the frequency, amplify it, and convert it into electromagnetic waves for radiation through the antenna. For example, the diagnostic device sends the version information of the vehicle ECU to the preset server through the communication module 104, and receives the ECU upgrade list returned by the preset server to obtain the ECU to be flashed. For another example, based on the URL of the ECU to be flashed, the communication module 104 obtains the flashing package of the ECU to be flashed from a preset server to implement the flashing of the ECU.

[0116] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In actual applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the above-mentioned device is divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated in one processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit, and the above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application.

[0117] Please refer to Fig.11 , Fig.11A schematic diagram of the structure of a preset server provided in an embodiment of the present application. The preset server 200 includes a processor 201, a memory 202 and a wireless communication module 204. The processor 201, the memory 202 and the wireless communication module 204 can be interconnected via a communication bus 203. The communication bus 203 can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The communication bus 203 can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Fig.11 The memory 202 is used to store computer programs. The computer programs include program instructions. The processor 201 is configured to call the program instructions. The program includes instructions for executing the following. Figure 6 Some or all of the steps performed by the preset server shown.

[0118] The processor 201 may be a CPU, a microprocessor, an ASIC, an ECU, or one or more integrated circuits for controlling the execution of the above program.

[0119] The memory 202 may be a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a random access memory (RAM) or other types of dynamic storage devices that can store information and instructions, or an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD ROM) or other optical disc storage, optical disc storage (including compressed optical disc, laser disc, optical disc, digital versatile disc, Blu-ray disc, etc.), a disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store the desired program code in the form of an instruction or data structure and can be accessed by a computer, but is not limited thereto. The memory may be independent and connected to the processor via a bus. The memory may also be integrated with the processor. Exemplarily, the memory 202 may store multiple versions of the ECU flashing package, including the latest version flashing package, the existing version flashing package, and the default version flashing package.

[0120] The preset server 200 may further include a communication interface, which includes a Universal Serial Bus (USB) interface, and may be used to connect to an external storage medium.

[0121] The wireless communication module 204 can provide solutions for wireless communication including WLAN, BT, GNSS, FM, NFC, IR, etc. applied on the preset server 200. The wireless communication module 204 can be one or more devices integrating at least one communication processing module. The wireless communication module 204 receives electromagnetic waves via an antenna, demodulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 201. The wireless communication module 204 can also receive the signal to be sent from the processor 201, modulate the frequency, amplify it, and convert it into electromagnetic waves for radiation through the antenna. The wireless communication module 204 can also receive electromagnetic waves sent by other vehicle inspection equipment and store the received data in the memory 202. Exemplarily, the preset server 200 can receive the version information of the ECU sent by the diagnostic device and return the upgrade list of the ECU to the diagnostic device; the preset server 200 can also receive the URL sent by the diagnostic device and return the ECU flash package of the corresponding version of the URL to the diagnostic device.

[0122] In some embodiments, the wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time-division code division multiple access (TD-SCDMA), long term evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technology, etc. The GNSS may include GPS, global navigation satellite system (GLONASS), Beidou navigation satellite system (BDS), quasi-zenith satellite system (QZSS) and / or satellite based augmentation systems (SBAS).

[0123] In addition, the preset server 200 may also include common components such as antennas, which will not be described in detail here.

[0124] It should be understood that each step in the above method embodiment provided by the present application can be completed by an integrated logic circuit of hardware in a processor or by instructions in the form of software. The method steps disclosed in the embodiments of the present application can be directly embodied as being executed by a hardware processor, or by a combination of hardware and software modules in a processor.

[0125] The present application also provides a computer program product, which includes: a computer program (also referred to as code, or instruction), which, when executed, enables a computer to execute the method executed by the vehicle inspection device in the above embodiment.

[0126] The present application also provides a computer-readable storage medium, which stores a computer program (also referred to as code or instruction). When the computer program is executed, the computer executes the method executed by the vehicle inspection device in the above embodiment.

[0127] A person skilled in the art can understand that to implement all or part of the processes in the aforementioned embodiments, the processes can be completed by a computer program to instruct the relevant hardware, and the program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the aforementioned method embodiments. The aforementioned storage medium includes: a read-only memory ROM or a random access memory RAM, a magnetic disk or an optical disk, and other media that can store program codes.

[0128] In short, the above description is only an embodiment of the technical solution of this application, and is not intended to limit the protection scope of this application. Any modification, equivalent replacement, improvement, etc. made according to the disclosure of this application shall be included in the protection scope of this application.

Claims

1. A method for flashing a vehicle electronic control unit ECU, applied to an ECU flashing system, wherein the ECU flashing system comprises a diagnostic device and a preset server, wherein a communication connection is established between the diagnostic device and the preset server, and wherein: The method comprises: The diagnostic device is connected to the target vehicle to read the version information of the ECU in the target vehicle; The diagnostic device sends the version information of the ECU to the preset server; The preset server stores multiple version flash packages of the ECU, and the preset server compares the version information of the ECU with the version information of the multiple version flash packages of the ECU to generate an ECU upgrade list, wherein the ECU upgrade list includes a first node group, the first node group includes one or more first nodes, the first node includes indication information of the ECU, a first uniform resource locator URL, a second URL and a third URL, the multiple version flash packages include a latest version flash package, a current version flash package and a default version flash package, the first URL indicates the latest version flash package, the second URL indicates the current version flash package, and the third URL indicates the default version flash package; The preset server returns the ECU upgrade list to the diagnostic device, the diagnostic device parses the ECU upgrade list to obtain the first node group, and generates a first flashing queue, where the first flashing queue is used to store the first node group; The diagnostic device obtains the latest version flash package based on the first URL of the first node, and flashes the ECU corresponding to the first node based on the latest version flash package; The diagnostic device acquires the first node of the ECU that fails to be flashed, and generates a second flashing queue, where the second flashing queue is used to store a second node group, where the second node group includes one or more second nodes, and the second node is the first node of the ECU that fails to be flashed; The diagnostic device obtains the current version flashing package based on the second URL of the second node, and flashes the ECU corresponding to the second node based on the current version flashing package; The diagnostic device acquires the second node on which the ECU fails to be flashed, and generates a third flashing queue, wherein the third flashing queue is used to store a third node group, wherein the third node group includes one or more third nodes, and the third node is the second node on which the ECU fails to be flashed; The diagnostic device obtains the default version flashing package based on the third URL of the third node, and flashes the ECU corresponding to the third node based on the default version flashing package.

2. The method according to claim 1, characterized in that: The preset server compares the version information of the ECU with the version information of multiple version flashing packages of the ECU, where the version information includes a software version number, specifically including: The preset server determines whether the software version number of the ECU is consistent with the software version number of the latest version flash package among the multiple version flash packages of the ECU. If the software version number of the ECU is inconsistent with the software version number of the latest version flash package among the multiple version flash packages of the ECU, it is determined that the ECU is the ECU to be flashed, and the ECU upgrade list includes multiple version flash packages indicating the ECU to be flashed.

3. The method according to claim 1 or 2, characterized in that: The indication information of the ECU includes a flashing priority, and after the diagnostic device generates a first flashing queue, the method further includes: the diagnostic device arranging the first node group in the first flashing queue based on the flashing priority of the first node; After the diagnostic device generates the second flash queue, the method further includes: the diagnostic device arranging the second node group in the second flash queue based on the flash priorities of the second nodes; After the diagnostic device generates the third flash queue, the method further includes: the diagnostic device arranging the third node group in the third flash queue based on the flash priorities of the third nodes.

4. The method according to claim 3, characterized in that: The diagnostic device obtains the latest version flash package based on the first URL of the first node, and flashes the ECU corresponding to the first node based on the latest version flash package, specifically including: the diagnostic device sequentially obtains the latest version flash package corresponding to the first URL in the first node based on the arrangement order of the first nodes in the first queue, and sequentially flashes the ECU corresponding to the first node based on the latest version flash package; The diagnostic device obtains the current version flashing package based on the second URL of the second node, and flashes the ECU corresponding to the second node based on the current version flashing package, specifically including: the diagnostic device sequentially obtains the current version flashing package corresponding to the second URL in the second node based on the arrangement order of the second nodes in the second queue, and sequentially flashes the ECU corresponding to the second node based on the current version flashing package; The diagnostic device obtains the default version flash package based on the third URL of the third node, and flashes the ECU corresponding to the third node based on the default version flash package, specifically including: the diagnostic device obtains the default version flash package corresponding to the third URL in the third node in sequence based on the arrangement order of the third nodes in the third queue, and flashes the ECU corresponding to the third node in sequence based on the default version flash package.

5. The method according to any one of claims 1 to 4, characterized in that: After flashing the ECU corresponding to the third node based on the default version flashing package, the method further includes: The diagnostic device obtains the first node where the ECU is successfully flashed, and displays a first message, where the first message is used to indicate the ECU in the first node where the flashing is successfully completed; The diagnostic device obtains the second node where the ECU is successfully flashed, and displays a second message, where the second message is used to indicate the ECU in the second node where the ECU is successfully flashed; The diagnostic device obtains the third node where the ECU is successfully flashed, and displays a third message, where the third message is used to indicate the ECU in the third node where the flashing is successfully completed; The diagnostic device obtains the third node where the ECU fails to be flashed, and displays a fourth message, where the fourth message is used to indicate the ECU in the third node where the flashing fails.

6. A diagnostic device, characterized in that include: ECU acquisition unit, used to read the version information of all ECUs in the vehicle; A first communication unit, used to upload the version information of the ECU to a preset server, and receive an ECU upgrade list returned by the preset server, wherein the ECU upgrade list is used to indicate the ECUs that need to be flashed; A queue filling unit, used to fill each ECU that needs to be flashed into a preset flash queue in sequence according to the flash priority of each ECU that needs to be flashed, wherein the flash queue includes a first flash queue, a second flash queue and a third flash queue, wherein the first flash queue is used to fill the ECUs that need to be flashed indicated by the ECU upgrade list, the second flash queue is used to fill the ECUs that failed to be flashed in the first flash queue, and the third flash queue is used to fill the ECUs that failed to be flashed in the second flash queue; The ECU flashing unit is used to determine the ECU to be flashed from the flashing queue in sequence according to a preset sequential execution method, read the URL in the ECU upgrade list, and flash the ECU to be flashed based on the ECU flashing package corresponding to the URL. Specifically, the ECU flashing unit flashes the ECUs in the first flashing queue, fills the ECUs in the first flashing queue that fail to be flashed into the second flashing queue through the queue filling unit, and the ECU flashing unit flashes the ECUs in the second flashing queue, and fills the ECUs in the second flashing queue that fail to be flashed into the third flashing queue through the queue filling unit, and the ECU flashing unit flashes the ECUs in the third flashing queue, wherein the ECU flashing package corresponding to the URL is located in the preset server, and the URL includes a first URL, a second URL and a third URL, the ECU flashing package corresponding to the first URL is used to flash the first flashing queue, the ECU flashing package corresponding to the second URL is used to flash the second flashing queue, and the ECU flashing package corresponding to the third URL is used to flash the third flashing queue.

7. A preset server, characterized in that: include: A second communication unit is used to receive the current version information of all ECUs sent by the diagnostic device, and return an ECU upgrade list to the diagnostic device, wherein the ECU upgrade list is used to indicate the URLs of the ECUs to be flashed and the ECU flashing packages, and is also used to receive the URL sent by the receiving diagnostic device, and return the ECU flashing package of the version corresponding to the URL to the diagnostic device; A storage unit, used for storing various versions of flashing packages of the ECU; A version judgment unit, configured to judge whether the current version information and the latest version flashing packages of all ECUs stored locally are consistent after the preset server receives the current version information of all ECUs sent by the diagnostic device, and if the current version information and the latest version flashing packages stored locally are inconsistent, determine the ECU as the ECU to be flashed; The ECU upgrade list generating unit is used to carry the information of the ECU to be flashed and the URL of the ECU flashing package in the ECU upgrade list.

8. An electronic device, comprising one or more memories and one or more processors; the memory is coupled to the one or more processors, the memory is used to store computer program code, the computer program code includes computer instructions, and the one or more processors call the computer instructions so that the electronic device executes any one of the methods performed by the diagnostic device as described in claims 1-5.

9. A computer-readable storage medium having computer instructions stored thereon, characterized in that: When the computer instructions are executed by a processor, any one of the methods described in claims 1 to 5 is implemented.

10. A computer device comprising a memory, a processor and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement any one of the method steps performed by the diagnostic device in claims 1-5.

Citation Information

Patent Citations

  • Automobile controller software remote upgrade method and internet-of-vehicle system

    CN105208112A

  • Electronic controller flashing method, electronic controller and management server

    CN116483390A

  • Upgrading method and device of vehicle electronic control unit, equipment and storage medium

    CN116909808A

  • Vehicle electronic control unit flashing method, device and equipment and storage medium

    CN118331632A

  • Data processing method and related device

    US20240020111A1

Cited By

  • Diagnosis agent assembly and diagnosis control method of vehicle

    CN120652962A