A method for one-to-two brush writing ECU
By combining the EOL tool and USBCAN with the UDS$27Service request seed command, Key#1 and Key#2 are calculated to unlock ECU#1 and ECU#2, solving the problem that a single-channel USBCAN can only write one ECU and reducing the equipment cost of multi-channel USBCAN.
Patent Information
- Application Number
- CN202210795996.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-07
- Publication Date
- 2025-11-11
- Estimated Expiration
- 2042-07-07
AI Technical Summary
In the existing technology, a single-channel USBCAN can only be flashed to one ECU at a time, while a multi-channel USBCAN requires increased equipment costs, resulting in higher investment costs.
By connecting via EOL tool and USBCAN, and using the UDS$27Service request Seed command, Key#1 and Key#2 are calculated to unlock ECU#1 and ECU#2, and data transmission and verification are performed to complete ECU data flashing. The Bosch EDC17 system's secure access mechanism is used to achieve one-to-two flashing.
Without increasing equipment costs, a single-channel USBCAN can be used to flash multiple ECUs at once, reducing investment costs and eliminating the need for hardware upgrades.
Smart Images

Figure CN115237450B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of ECU flashing technology, and more specifically, to a method for flashing two ECUs simultaneously. Background Technology
[0002] ECU stands for Electronic Control Unit. In a common rail injection system, the ECU receives signals from various sensors and, with the help of solenoid valves on the injectors, ensures that diesel fuel is injected at the correct injection pressure and at the correct injection point with the correct injection quantity. This guarantees the diesel engine's optimal combustion ratio, atomization, and ignition timing, as well as good fuel economy and minimal emissions.
[0003] The ECU flashing methods in related technologies can only flash one ECU at a time with a single-channel USBCAN without increasing equipment costs, and multi-channel USBCAN requires investment in upgrading equipment, which increases the investment cost. Summary of the Invention
[0004] To overcome the above shortcomings, this invention provides a method for flashing two ECUs simultaneously, aiming to improve the situation where a single-channel USBCAN can only flash one ECU at a time without increasing equipment costs, and multi-channel USBCAN requires investment in upgrading equipment, thus increasing investment costs.
[0005] This invention is implemented as follows:
[0006] This invention provides a method for flashing two ECUs simultaneously, comprising the following steps:
[0007] S1: The EOL tool downloads ECU data from the production database to the local machine;
[0008] S2: The EOL tool is connected to the USBCAN. The USBCAN is connected to two or more Bosch EDC17 ECUs through the tooling harness. At this time, the EOL tool and ECU #1 and ECU #2 are all in the same CAN bus.
[0009] S3: The EOL tool sends a UDS$27Service request Seed command via USBCAN. Assume that ECU#1 and ECU#2 reply with Seed#1 and Seed#2 respectively.
[0010] S4: The EOL tool calculates Key#1 and Key#2 using Seed#1 and Seed#2 respectively according to a specific algorithm;
[0011] S5: The EOL tool sends Key#1 to the CAN bus and will receive a positive response from ECU#1 and a negative response from ECU#2;
[0012] S6: The EOL tool sends Key#2 to the CAN bus and will receive a negative response from ECU#1 and a positive response from ECU#2;
[0013] S7: At this time, both ECU#1 and ECU#2 are in the unlocked state, and ECU data transmission begins;
[0014] S8: After data transmission is completed, ECU data verification and reset are performed;
[0015] S9: After successful verification, a message will be displayed indicating that the flashing process is complete. The flashing record will be transmitted to the database, and finally the ECU label will be printed.
[0016] In one embodiment of the present invention, the ECU data in step S1 is separated in the Flash physical space of the microcontroller, and the ECU data can be divided into different data areas according to the different nature of the control task.
[0017] In one embodiment of the present invention, the USBCAN in step S2 is a CAN testing tool. The testing tool is equipped with host computer software. The USBCAN is connected to the computer via a USB cable. After the connection is completed, the working status of the USBCAN is checked. A green light indicates that the device is ready, and a red light indicates that the device connection is abnormal.
[0018] In one embodiment of the present invention, the host computer software controls the adapter in the flashing module, and the adapter controls ECU1 and ECU2.
[0019] In one embodiment of the present invention, the adapter in the flashing module refers to a single-channel USBCAN device. The two controllers are unlocked sequentially using UDS$27Service. Each controller has 5 unlocking opportunities, so the 1-to-2 solution can be expanded to 5 controllers. The 1-to-2 solution has been verified on the Bosch EDC17 system.
[0020] In one embodiment of the present invention, the intelligent electronic control device that enables communication data forwarding between various electronic control devices via the CAN bus in step S2 adopts a 16-bit microcontroller with two CAN controllers, supports CAN2.0A and CAN2.0B protocols, is developed according to the UDS standard protocol, and can be applied to both high-speed and low-speed CAN bus networks.
[0021] In one embodiment of the present invention, the instruction interaction of the flashing module includes session control, requesting a seed, sending key #1, sending key #2, and the flashing process.
[0022] In one embodiment of the present invention, the ECU on the Bosch EDC17 in step S2 can restore data and modify calibration parameters by flashing, and can perform backup and flashing operations.
[0023] In one embodiment of the present invention, the flashing module obtains flashing data sent by the host computer software through a USB interface circuit.
[0024] In one embodiment of the present invention, the database in step S9 is a data warehouse, which is a collection of large amounts of data that is stored in a computer for a long time, is organized, can be shared, and is uniformly managed.
[0025] The beneficial effects of this invention are as follows: This invention provides a method for flashing two ECUs using a single-drive configuration. During use, the EOL tool downloads ECU data from the production database to the local machine. The EOL tool connects to a USBCAN bus, which in turn connects to two or more Bosch EDC17 ECUs via a tooling harness. At this time, the EOL tool, ECU #1, and ECU #2 are all on the same CAN bus. The EOL tool sends a UDS$27Service request seed command via USBCAN. ECU #1 and ECU #2, assuming they respond with Seed #1 and Seed #2 respectively, use a specific algorithm to calculate Key #1 and Key #2 using Seed #1 and Seed #2 respectively. The EOL tool then sends Key #1 to the CAN bus. The system will receive a positive response from ECU#1 and a negative response from ECU#2. The EOL tool will send Key#2 to the CAN bus, which will then receive a negative response from ECU#1 and a positive response from ECU#2. At this point, both ECU#1 and ECU#2 are in an unlocked state, and ECU data transmission begins. After the data transmission is complete, ECU data verification and reset are performed. Once verification is successful, a message indicating that the flashing is complete will be displayed, and the flashing record will be transmitted to the database. Finally, an ECU label will be printed. This method of flashing two ECUs simultaneously using a single-channel USBCAN can achieve the flashing of multiple ECUs at once without increasing equipment costs, and it does not require upgrading the USBCAN. It can be upgraded based on existing hardware without any hardware investment. It cleverly utilizes the EDC17 controller's secure access mechanism to unlock multiple ECUs for flashing simultaneously, reducing investment costs. Attached Figure Description
[0026] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained from these drawings without creative effort.
[0027] Figure 1 This is a schematic diagram of the instruction interaction of a method for flashing two ECUs according to the present invention. Detailed Implementation
[0028] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0029] Example
[0030] Please see Figure 1 This invention provides a technical solution: a method for flashing two ECUs simultaneously, comprising the following steps:
[0031] S1: The EOL tool downloads ECU data from the production database to the local machine. The ECU data in step S1 is separated in the Flash physical space of the microcontroller. The Flash physical space is usually placed at the beginning of the flash and the EEPROM at the end. The specific size needs to be allocated according to the actual project needs. The ECU data can be divided into different data areas according to the different nature of the control task. The data partitioning design is convenient to meet the needs of different application scenarios. The microcontroller has a CPU, memory, parallel bus, and storage devices that function like hard disks. It mainly serves as the core component of the control part.
[0032] S2: The EOL tool and USBCAN are connected. The USBCAN is connected to two or more Bosch EDC17 ECUs via a tooling harness. At this time, the EOL tool and ECU #1 and ECU #2 are all on the same CAN bus. The USBCAN in step S2 is a CAN testing tool, which is equipped with host computer software. The USBCAN is connected to the computer via a USB cable. After the connection is complete, the working status of the USBCAN is checked. A green light indicates that the device is ready, and a red light indicates that the device connection is abnormal. The host computer software controls the adapter in the flashing module. The adapter controls ECU1 and ECU2. The adapter refers to a single-channel USBCAN device. It uses UDS$27Service to unlock two controllers sequentially. Each controller has 5 unlocking opportunities, so the 1-to-2 solution can be expanded to 5 controllers. The 1-to-2 solution has been verified on the Bosch EDC17 system. The CAN bus in step S2 enables communication data forwarding between various electronic control devices. It uses a 16-bit microcontroller with two CAN controllers, supports CAN2.0A and CAN2.0B protocols, is developed according to the UDS standard protocol, and can be used in both high-speed and low-speed CAN bus networks. It has excellent sealing performance and can be used in various harsh environments.
[0033] The instruction interaction of the flashing module includes session control, seed request, sending key #1, sending key #2, and the flashing process: the session control process is DIAGNOSTICSESSIONCONTROL, POSITIVERESPONSE#1, POSITIVERESPONSE#2; the seed request process is REQUESTSEED, Seed#1, Seed#2; the key sending process is SEEND KEY#1, POSITIVERESPONSE, NEGATIVERESPONSE; the key sending process is SEEND KEY#2, NEGATIVERESPONSE, POSITIVERESPONSE; and the flashing process is Request-1, Response#1, Response#2, Request-n, Response-n#1, Response-n#2.
[0034] The ECU on the Bosch EDC17 in step S2 can restore data and modify calibration parameters through flashing. It can perform backup and flashing operations. The flashing module obtains the flashing data sent by the host computer software through the USB interface circuit. The database in step S9 is a data warehouse. It is a collection of large amounts of organized, shareable, and uniformly managed data that is stored in a computer for a long time. The host computer refers to the computer that can directly issue control commands. It is generally a PC / host computer / master computer / upper computer. Various signal changes are displayed on the screen. The slave computer is the computer that directly controls the equipment and obtains the equipment status. It is generally a PLC / single chip microcomputer / slave computer / lower computer, etc. The commands issued by the host computer are first sent to the slave computer. The slave computer then interprets the commands into corresponding timing signals to directly control the corresponding equipment. The slave computer reads the equipment status data from time to time, converts it into digital signals and feeds it back to the host computer. Both the host computer and the slave computer need to be programmed and have dedicated development systems.
[0035] S3: The EOL tool sends a UDS$27Service request Seed command via USBCAN. Assume that ECU#1 and ECU#2 reply with Seed#1 and Seed#2 respectively.
[0036] S4: The EOL tool calculates Key#1 and Key#2 using Seed#1 and Seed#2 respectively according to a specific algorithm;
[0037] S5: The EOL tool sends Key#1 to the CAN bus and will receive a positive response from ECU#1 and a negative response from ECU#2;
[0038] S6: The EOL tool sends Key#2 to the CAN bus and will receive a negative response from ECU#1 and a positive response from ECU#2;
[0039] S7: At this time, both ECU#1 and ECU#2 are in the unlocked state, and ECU data transmission begins;
[0040] S8: After data transmission is completed, ECU data verification and reset are performed;
[0041] S9: After successful verification, a message will be displayed indicating that the flashing process is complete. The flashing record will be transmitted to the database, and finally the ECU label will be printed.
[0042] Specifically, the working principle of this one-to-two ECU flashing method is as follows: During use, the EOL tool downloads ECU data from the production database to its local machine. The EOL tool connects to the USBCAN bus, which is connected to two or more Bosch EDC17 ECUs via a tooling harness. At this time, the EOL tool and ECU #1 and ECU #2 are all on the same CAN bus. The EOL tool sends a UDS$27Service request Seed command via USBCAN. Assuming ECU #1 and ECU #2 reply with Seed #1 and Seed #2 respectively, the EOL tool calculates Key #1 and Key #2 using Seed #1 and Seed #2 respectively, according to a specific algorithm. The EOL tool then sends Key #1 to the CAN bus and receives ECU #2. The EOL tool sends Key#2 to the CAN bus, receiving a positive response from ECU#1 and a negative response from ECU#2. At this point, both ECU#1 and ECU#2 are unlocked, and ECU data transmission begins. After data transmission, ECU data verification and reset are performed. Upon successful verification, a message indicating completion of the flashing process is displayed, and the flashing record is transmitted to the database. Finally, an ECU label is printed. This method of flashing two ECUs simultaneously using a single-channel USBCAN without increasing equipment costs, and without requiring USBCAN upgrades, allows for upgrades based on existing hardware without additional hardware investment. It cleverly utilizes the EDC17 controller's secure access mechanism to simultaneously unlock and flash multiple ECUs, reducing overall costs.
[0043] The above are merely preferred embodiments of the present invention and are not intended to limit the present invention. For those skilled in the art, the present invention can have various modifications and variations. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for flashing two ECUs simultaneously, characterized in that, Includes the following steps: S1: The EOL tool downloads ECU data from the production database to the local machine; S2: The EOL tool is connected to the USBCAN. The USBCAN is connected to two or more Bosch EDC17 ECUs through the tooling harness. At this time, the EOL tool and ECU #1 and ECU #2 are all in the same CAN bus. S3: The EOL tool sends a UDS $27 Service request Seed command via USBCAN. Assume that ECU #1 and ECU #2 reply with Seed #1 and Seed #2 respectively. S4: The EOL tool uses Seed #1 and Seed #2 to calculate Key #1 and Key #2 respectively; S5: The EOL tool sends Key #1 to the CAN bus and will receive a positive response from ECU #1 and a negative response from ECU #2; S6: The EOL tool sends Key #2 to the CAN bus and will receive a negative response from ECU #1 and a positive response from ECU #2; S7: At this time, both ECU #1 and ECU #2 are in the unlocked state, and ECU data transmission begins; S8: After data transmission is completed, ECU data verification and reset are performed; S9: After successful verification, a message will be displayed indicating that the flashing process is complete. The flashing record will be transmitted to the database, and finally the ECU label will be printed.
2. The method for flashing an ECU using a one-to-two converter according to claim 1, characterized in that, The ECU data in step S1 is separated in the Flash physical space of the microcontroller. The ECU data is divided into different data areas according to the different nature of the control task.
3. The method for flashing an ECU using a one-to-two converter according to claim 1, characterized in that, The USBCAN in step S2 is a CAN testing tool. The testing tool is equipped with host computer software. The USBCAN is connected to the computer using a USB cable. After the connection is completed, the working status of the USBCAN is checked. A green light indicates that the device is ready, and a red light indicates that the device connection is abnormal.
4. The method for flashing an ECU using a one-to-two converter according to claim 3, characterized in that, The host computer software controls the adapter in the flashing module, and the adapter controls ECU #1 and ECU #2.
5. The method for flashing an ECU using a one-to-two converter according to claim 4, characterized in that, The adapter in the flashing module refers to a single-channel USBCAN device, which uses UDS $27 Service to unlock the two controllers sequentially.
6. The method for flashing an ECU using a one-to-two converter according to claim 1, characterized in that, The CAN bus in step S2 enables communication data forwarding between various electronic control devices in intelligent electronic control equipment. It adopts a 16-bit microcontroller with two CAN controllers, supports CAN2.0A and CAN2.0B protocols, is developed according to the UDS standard protocol, and is suitable for both high-speed and low-speed CAN bus networks.
7. The method for flashing an ECU using a one-to-two converter according to claim 4, characterized in that, The instruction interaction of the flashing module includes session control, requesting a seed, sending Key #1, sending Key #2, and the flashing process.
8. The method for flashing an ECU using a one-to-two converter according to claim 1, characterized in that, In step S2, the ECU on the Bosch EDC17 can recover data and modify calibration parameters by flashing, and can perform backup and flashing operations.
9. The method for flashing an ECU using a one-to-two converter according to claim 4, characterized in that, The flashing module obtains flashing data sent by the host computer software through a USB interface circuit.
10. The method for flashing an ECU using a one-to-two converter according to claim 1, characterized in that, The database in step S9 is a data warehouse, a large collection of organized, shareable, and uniformly managed data that is stored in a computer for a long time.