Diagnostic method, device, system and electronic equipment of vehicle controller and vehicle

By using different addressing ranges to allocate request and response addresses in vehicle controller diagnostics, the problem of insufficient controller diagnostic addresses is solved, achieving more efficient diagnostics and better compatibility, and adapting to complex network topologies.

CN119645002BActive Publication Date: 2026-06-19ZHEJIANG GEELY HLDG GRP CO LTD +2

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG GEELY HLDG GRP CO LTD
Filing Date
2024-12-16
Publication Date
2026-06-19

Smart Images

  • Figure CN119645002B_ABST
    Figure CN119645002B_ABST
Patent Text Reader

Abstract

This application discloses a diagnostic method, apparatus, system, electronic device, and vehicle for a vehicle controller, belonging to the field of vehicle technology. The method includes: acquiring a diagnostic request message sent by a diagnostic device, the diagnostic request message including a request address, which is an address allocated from a first addressing range; the request address is used to identify the target controller requiring diagnostics; sending the diagnostic request message to the target controller identified by the request address, obtaining a diagnostic response message returned by the target controller, the diagnostic response message including a response address, which is an address allocated from a second addressing range; the response address is used to identify the target controller that sent the diagnostic response message; and sending the diagnostic response message to the diagnostic device, so that the diagnostic device performs diagnostics on the target controller identified by the response address based on the diagnostic response message. This application increases the configurable number of controller diagnostic addresses, enabling support for more controller diagnostics and improving controller diagnostic efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of vehicle technology, and in particular relates to a diagnostic method, device, system, electronic device, and vehicle for a vehicle controller. Background Technology

[0002] With the rapid development of modern automotive technology, vehicle controller diagnostics has become an indispensable part of vehicle maintenance and fault detection. In traditional vehicle architectures, each controller is typically assigned a unique diagnostic address to facilitate identification and communication through the vehicle's diagnostic system.

[0003] In related technologies, diagnostic addresses include request addresses and response addresses, which are allocated within the same predefined address range. However, with the continuous expansion and integration of vehicle functions, the number of controllers has increased dramatically. Due to the limited number of addresses that can be allocated within an address range, there are insufficient diagnostic addresses for the controllers, affecting their diagnostic efficiency. Summary of the Invention

[0004] This application aims to address at least one of the technical problems existing in the prior art. To this end, this application proposes a diagnostic method, apparatus, system, electronic device, and vehicle for a vehicle controller, thereby increasing the number of configurable diagnostic addresses for the controller and improving the diagnostic efficiency of the controller.

[0005] In a first aspect, this application provides a diagnostic method for a vehicle controller, comprising:

[0006] The diagnostic request message sent by the diagnostic device is obtained. The diagnostic request message includes a request address, which is an address allocated from a first addressing range. The request address is used to identify the target controller that needs to be diagnosed.

[0007] The diagnostic request message is sent to the target controller identified by the request address, and a diagnostic response message is returned by the target controller. The diagnostic response message includes a response address, which is an address allocated from the second addressing range. The response address is used to identify the target controller that sent the diagnostic response message.

[0008] The diagnostic response message is sent to the diagnostic device so that the diagnostic device can perform diagnostics on the target controller identified by the response address based on the diagnostic response message.

[0009] According to the vehicle controller diagnostic method of this application, a diagnostic request message sent by a diagnostic device is obtained. The diagnostic request message includes a request address, which is an address allocated from a first addressing interval. The request address is used to identify the target controller that needs diagnostics. The diagnostic request message is sent to the target controller identified by the request address, and a diagnostic response message returned by the target controller is obtained. The diagnostic response message includes a response address, which is an address allocated from a second addressing interval. The response address is used to identify the target controller that sent the diagnostic response message. The diagnostic response message is sent to the diagnostic device, so that the diagnostic device performs diagnostics on the target controller identified by the response address based on the diagnostic response message. This embodiment of the application expands the diagnostic addresses in controller diagnostic applications by using different addressing intervals to allocate request and response addresses, increasing the configurable number of controller diagnostic addresses, thereby supporting more controller diagnostics and improving controller diagnostic efficiency.

[0010] According to one embodiment of this application, the vehicle includes a plurality of controllers, each controller being assigned a diagnostic address, wherein the request address in the diagnostic address is an address assigned from the first addressing interval; the response address in the diagnostic address is an address assigned from the second addressing interval; and the composition of the request address and response address of the same controller is at least partially the same.

[0011] In this embodiment, by allocating diagnostic addresses from two independent addressing intervals—the first addressing interval for allocating request addresses and the second addressing interval for allocating response addresses—the number of configurable diagnostic addresses is effectively expanded. Furthermore, each controller has a unique request address and response address, thereby enabling accurate diagnostic communication among multiple controllers, avoiding address conflicts, and improving diagnostic accuracy.

[0012] According to one embodiment of this application, the method further includes:

[0013] Determine the addressing mode;

[0014] The first addressing interval and the second addressing interval are divided according to the addressing mode.

[0015] In this embodiment, by dividing the first addressing interval and the second addressing interval according to the addressing method, the application scenarios under various network architectures during the diagnostic process are taken into account, thereby improving the compatibility of the diagnostic communication process in different network environments.

[0016] According to one embodiment of this application, dividing the first addressing interval and the second addressing interval according to the addressing mode includes:

[0017] When the addressing mode is diagnostic addressing using a standard frame, the first addressing interval and the second addressing interval are addressing intervals based on the identifier length of the standard frame; wherein, in the first addressing interval, the first target bit of each address represents a diagnostic request, and the second target bit is used to allocate the request address; in the second addressing interval, the first target bit of each address represents a diagnostic response, and the second target bit is used to allocate the response address.

[0018] In this embodiment, two addressing intervals are constructed based on the identifier length of the standard frame. In the first addressing interval, the first target bit of each address is dedicated to representing a diagnostic request, while the second target bit is used to allocate a specific request address. Correspondingly, in the second addressing interval, the first target bit of each address is used to represent a diagnostic response, while the second target bit is used to allocate a response address. This not only increases the number of configurable diagnostic addresses but also makes the diagnostic request and response clearly distinguishable, reducing the possibility of address conflicts.

[0019] According to one embodiment of this application, the method further includes:

[0020] When the addressing mode is diagnostic addressing using extended frames, the first addressing interval and the second addressing interval are addressing intervals based on the identifier length of the extended frame; wherein, the source address of the first addressing interval is used to allocate the request address, and the source address of the second addressing interval is used to allocate the response address.

[0021] In this embodiment, by using addressing intervals based on the identifier length of extended frames, the source address of the first addressing interval is used to allocate the request address, while the source address of the second addressing interval is used to allocate the response address. This allows the diagnostic process to perform diagnostic communication in a wider address space, increasing the number of configurable diagnostic addresses and thus supporting more controllers and more complex network topologies.

[0022] According to one embodiment of this application, the method further includes:

[0023] When the addressing mode is diagnostic addressing via IP protocol using diagnostic communication, the first addressing range and the second addressing range are addressing ranges composed of logical addresses via IP protocol using diagnostic communication; wherein, the request address and response address of the same controller are the same.

[0024] In this embodiment, the addressing range formed by the logical addresses of the IP protocol is used for diagnostic communication. The request address and response address of the same controller are the same, which enables efficient address allocation and diagnostic communication even in the IP protocol environment. This not only increases the number of configurable diagnostic addresses, but also further enhances the compatibility of the diagnostic system.

[0025] According to one embodiment of this application, the addressing ranges corresponding to different addressing modes are of the same size.

[0026] In this embodiment, all addressing modes provide the same addressing range, ensuring compatibility and consistency of the diagnostic system across different network environments. Regardless of the addressing mode chosen, the same address capacity can be expected, reducing additional configuration work. Furthermore, the uniform addressing range size also improves the scalability of the diagnostic system, enabling it to flexibly adapt to increases in the number of vehicle controllers and changes in network structure.

[0027] Secondly, this application provides a diagnostic device for a vehicle controller, comprising:

[0028] The acquisition module is used to acquire a diagnostic request message sent by the diagnostic device. The diagnostic request message includes a request address, which is an address allocated from a first addressing range. The request address is used to identify the target controller that needs to be diagnosed.

[0029] The sending module is configured to send the diagnostic request message to the target controller identified by the request address, and obtain a diagnostic response message returned by the target controller. The diagnostic response message includes a response address, which is an address allocated from the second addressing range. The response address is used to identify the target controller that sent the diagnostic response message.

[0030] The diagnostic module is used to send the diagnostic response message to the diagnostic device, so that the diagnostic device can perform diagnostics on the target controller identified by the response address based on the diagnostic response message.

[0031] According to the diagnostic device for a vehicle controller of this application, a diagnostic request message sent by a diagnostic device is obtained. The diagnostic request message includes a request address, which is an address allocated from a first addressing interval. The request address is used to identify the target controller requiring diagnostics. The diagnostic request message is sent to the target controller identified by the request address, and a diagnostic response message returned by the target controller is obtained. The diagnostic response message includes a response address, which is an address allocated from a second addressing interval. The response address is used to identify the target controller that sent the diagnostic response message. The diagnostic response message is then sent to the diagnostic device, so that the diagnostic device performs diagnostics on the target controller identified by the response address based on the diagnostic response message. This embodiment of the application expands the diagnostic addresses in controller diagnostic applications by using different addressing intervals to allocate request and response addresses, increasing the configurable number of controller diagnostic addresses, thereby supporting more controller diagnostics and improving controller diagnostic efficiency.

[0032] According to one embodiment of this application, the apparatus further includes:

[0033] A partitioning module is used to determine the addressing mode; and to partition the first addressing interval and the second addressing interval according to the addressing mode.

[0034] Thirdly, this application provides a diagnostic system for a vehicle controller, including: a diagnostic device, multiple controllers, and a gateway device;

[0035] The gateway device is used to perform the diagnostic method for the vehicle controller as described in the first aspect above.

[0036] Fourthly, this application provides an electronic device including a processor connected to a memory storing a computer program executable on the processor, wherein the processor, when executing the computer program, implements the diagnostic method for a vehicle controller as described in the first aspect above.

[0037] Fifthly, this application provides a vehicle that includes a diagnostic system for a vehicle controller as described in the third aspect above, or the vehicle includes electronic equipment as described in the fourth aspect above.

[0038] In a sixth aspect, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the diagnostic method for a vehicle controller as described in the first aspect above.

[0039] In a seventh aspect, this application provides a chip including a processor and a communication interface, the communication interface being coupled to the processor, the processor being used to run programs or instructions to implement the diagnostic method for a vehicle controller as described in the first aspect above.

[0040] In a seventh aspect, this application provides a computer program product, including a computer program that, when executed by a processor, implements the diagnostic method for a vehicle controller as described in the first aspect above.

[0041] The above-described one or more technical solutions in the embodiments of this application have at least one of the following technical effects:

[0042] According to the vehicle controller diagnostic method of this application, a diagnostic request message sent by a diagnostic device is obtained. The diagnostic request message includes a request address, which is an address allocated from a first addressing interval. The request address is used to identify the target controller that needs diagnostics. The diagnostic request message is sent to the target controller identified by the request address, and a diagnostic response message returned by the target controller is obtained. The diagnostic response message includes a response address, which is an address allocated from a second addressing interval. The response address is used to identify the target controller that sent the diagnostic response message. The diagnostic response message is sent to the diagnostic device, so that the diagnostic device performs diagnostics on the target controller identified by the response address based on the diagnostic response message. This embodiment of the application expands the diagnostic addresses in controller diagnostic applications by using different addressing intervals to allocate request and response addresses, increasing the configurable number of controller diagnostic addresses, thereby supporting more controller diagnostics and improving controller diagnostic efficiency.

[0043] Furthermore, in some embodiments, by allocating diagnostic addresses from two independent addressing ranges—a first addressing range for allocating request addresses and a second addressing range for allocating response addresses—the number of configurable diagnostic addresses is effectively expanded, and each controller has a unique request address and response address. This enables accurate diagnostic communication between multiple controllers, avoids address conflicts, and improves diagnostic accuracy.

[0044] Furthermore, in some embodiments, by dividing the first addressing interval and the second addressing interval according to the addressing method, the application scenarios under various network architectures during the diagnostic process are taken into account, thereby improving the compatibility of diagnostic communication in different network environments.

[0045] Furthermore, in some embodiments, two addressing intervals are constructed based on the identifier length of a standard frame. In the first addressing interval, the first target bit of each address is dedicated to representing a diagnostic request, while the second target bit is used to allocate a specific request address. Correspondingly, in the second addressing interval, the first target bit of each address is used to represent a diagnostic response, while the second target bit is used to allocate a response address. This not only increases the number of configurable diagnostic addresses but also makes the diagnostic request and response clearly distinguishable, reducing the possibility of address conflicts.

[0046] Furthermore, in some embodiments, by using addressing intervals based on the identifier length of extended frames, the source address of the first addressing interval is used to allocate the request address, while the source address of the second addressing interval is used to allocate the response address. This allows the diagnostic process to perform diagnostic communication in a wider address space, increasing the number of configurable diagnostic addresses and thus supporting more controllers and more complex network topologies.

[0047] Furthermore, in some embodiments, the addressing range formed by the logical address of the IP protocol is used for diagnostic communication. The request address and response address of the same controller are the same, and the lower 8 bits of the logical address are used to represent these addresses. This enables efficient address allocation and diagnostic communication even in an IP protocol environment, which not only increases the number of configurable diagnostic addresses, but also further enhances the compatibility of the diagnostic system.

[0048] Furthermore, in some embodiments, all addressing modes provide the same addressing range, thereby ensuring the compatibility and consistency of the diagnostic system in different network environments. Regardless of the addressing mode selected, the same address capacity can be expected, reducing additional configuration work. Moreover, the uniform addressing range size also improves the scalability of the diagnostic system, enabling it to flexibly adapt to increases in the number of vehicle controllers and changes in network structure.

[0049] Additional aspects and advantages of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of this application. Attached Figure Description

[0050] To more clearly illustrate the technical solutions of the embodiments of this application, 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 this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0051] Figure 1 This is a schematic flowchart of the diagnostic method for a vehicle controller provided in an embodiment of this application;

[0052] Figure 2 This is a schematic diagram illustrating the interaction process between the diagnostic device and the vehicle provided in an embodiment of this application;

[0053] Figure 3 This is a schematic diagram illustrating the mapping and transformation of messages in different network architectures provided in the embodiments of this application;

[0054] Figure 4 This is a schematic diagram of the structure of the diagnostic device for the vehicle controller provided in the embodiments of this application;

[0055] Figure 5 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application. Detailed Implementation

[0056] The technical solutions of the embodiments of this application will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application are within the scope of protection of this application.

[0057] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.

[0058] The diagnostic method, apparatus, system, electronic device, and vehicle of the vehicle controller provided in this application will be described in detail below with reference to the accompanying drawings and through specific embodiments and application scenarios.

[0059] The diagnostic methods for the vehicle controller can be applied to the terminal, and can be executed by the hardware or software in the terminal.

[0060] Optionally, the terminal may include, but is not limited to, portable communication devices such as mobile phones or tablets with touch-sensitive surfaces (e.g., touchscreen displays and / or touchpads). It should also be understood that in some embodiments, the terminal may not be a portable communication device, but rather a desktop computer with touch-sensitive surfaces (e.g., touchscreen displays and / or touchpads). In some embodiments, the terminal may also be an optical receiver with a processor, a fiber optic switch, etc.

[0061] However, it should be understood that a terminal may include one or more other physical user interface devices such as a physical keyboard, mouse, and joystick.

[0062] The vehicle controller diagnostic method provided in this application embodiment can be executed by an electronic device or a functional module or entity in an electronic device that can implement the vehicle controller diagnostic method. The electronic device mentioned in this application embodiment may include, but is not limited to, a server, an ECU (Electronic Control Unit), an MCU (Microcontroller Unit), or other controllers. The following describes the vehicle controller diagnostic method provided in this application embodiment using an electronic device as the execution subject.

[0063] like Figure 1 As shown, the diagnostic method for the vehicle controller includes steps 110, 120, and 130.

[0064] Step 110: Obtain the diagnostic request message sent by the diagnostic device. The diagnostic request message includes a request address, which is an address allocated from the first addressing range. The request address is used to identify the target controller that needs to be diagnosed.

[0065] In this embodiment, a vehicle controller refers to an electronic control unit (ECU) used to monitor and manage various systems and components of a vehicle. These controllers are typically interconnected via in-vehicle networks, such as Controller Area Network (CAN) or Local Interconnect Network (LIN), to coordinate the functions of various systems and ensure the safety, performance, and comfort of the vehicle. A vehicle may contain various controllers, such as engine controllers, transmission controllers, body controllers, driver assistance controllers, vehicle controllers, and air conditioning controllers.

[0066] In this embodiment, the diagnostic device can be a tool capable of communicating with the vehicle's electronic control unit (ECU) to read fault codes, clear fault codes, configure parameters, and update software. The diagnostic device can be based on the OBD (On-Board Diagnostics) standard or on other diagnostic communication protocols such as UDS (Unified Diagnostic Services). For example, the diagnostic tool can be an OBD-II scanning tool, a professional diagnostic computer, a portable diagnostic tool, or a cloud-based diagnostic system.

[0067] In some embodiments, such as Figure 2As shown, diagnostic equipment can connect to electronic devices through interfaces on the vehicle used to connect diagnostic equipment and on-board electronic control units, such as data link connectors (DLC), OBD-II interfaces, or other communication interfaces.

[0068] After establishing a connection, the diagnostic device can send a diagnostic request message to the electronic device. This message can be generated based on the diagnostic service requirements. The diagnostic request message may include a request address, a service identifier, and data parameters. The service identifier can be used to identify the requested service type, such as reading fault codes or clearing fault codes. The data parameters may include additional data parameters depending on the requested service type. Of course, the diagnostic request message may also include a data identifier and data payload, but this embodiment does not limit this.

[0069] In this embodiment, the request address can be used to identify the target controller that needs diagnostics. For example, in a CAN bus, the request address can be a CAN message ID. The addressing range can be an address range used to assign to different controllers in diagnostic communication.

[0070] Step 120: Send the diagnostic request message to the target controller identified by the request address, and obtain the diagnostic response message returned by the target controller. The diagnostic response message includes a response address, which is an address allocated from the second addressing range. The response address is used to identify the target controller that sent the diagnostic response message.

[0071] In this embodiment of the application, the target controller that needs to be diagnosed can be identified based on the request address in the diagnostic request message, and the diagnostic request message can be sent to the target controller.

[0072] In some embodiments, such as Figure 2 As shown, since the diagnostic device and the controller in the vehicle may communicate in different network architectures, after receiving the diagnostic request message, the electronic device can process the diagnostic request message through the gateway and send the diagnostic request message to the target controller.

[0073] Specifically, such as Figure 3As shown, taking a diagnostic request message as an example, diagnostic devices and electronic devices can communicate via Ethernet using the Diagnostics over Internet Protocol (DoIP). The various controllers in the vehicle communicate via the CAN network using the CAN / FD (CAN with Flexible Data Rate) protocol. After receiving the diagnostic request message, the gateway can parse the logical address (Target Address, TA) in the message and then map it to the CAN / FD ID in the CAN message. This completes the forwarding of the diagnostic request message.

[0074] Upon receiving a diagnostic request message, the target controller can process the request based on the request address and service identifier. If the request address matches the target controller's corresponding request address, the controller executes the appropriate diagnostic service. After processing the request, the target controller constructs a diagnostic response message. The diagnostic response message may include a response address, service identifier, and diagnostic response data. Depending on the requested service type, the diagnostic response data may be specific diagnostic data, such as fault codes, vehicle status information, or controller status information.

[0075] In this embodiment, the response address is used to identify the target controller that sent the diagnostic response message. For example, the response address can be the address used by the vehicle controller to identify itself and return a diagnostic response message in diagnostic communication, so that the diagnostic device can know which controller responded to the request. The response address is usually different from the request address, and the response address and request address can be allocated from two different addressing ranges.

[0076] In some embodiments, the vehicle includes a plurality of controllers, each controller being assigned a diagnostic address, wherein the request address in the diagnostic address is an address assigned from a first addressing range; the response address in the diagnostic address is an address assigned from a second addressing range; and the composition of the request address and response address of the same controller is at least partially the same.

[0077] In this embodiment, the request address and response address of the same controller are at least partially identical. For example, the first addressing range can be 0x700 to 0x7FF, and the second addressing range can be 0x600 to 0x6FF. The high 3 bits (0x7) of the first addressing range represent a diagnostic request, and the high 3 bits (0x6) of the second addressing range represent a diagnostic response. The low 8 bits (0x00 to 0xFF) of both the first and second addressing ranges represent the diagnostic address. The low 8 bits of the request address and response address of the same controller can be the same; for example, the request address of controller 1 is 0x701, and the response address is 0x601, while the request address of controller 2 is 0x702, and the response address is 0x602.

[0078] In this embodiment, by allocating diagnostic addresses from two independent addressing intervals—the first addressing interval for allocating request addresses and the second addressing interval for allocating response addresses—the number of configurable diagnostic addresses is effectively expanded. Furthermore, each controller has a unique request address and response address, thereby enabling accurate diagnostic communication among multiple controllers, avoiding address conflicts, and improving diagnostic accuracy.

[0079] In some embodiments, the response address may be included in the address information of the diagnostic response message, which is an important component of the diagnostic message. For example, in a CAN bus, the address information may be mapped to the CAN message ID.

[0080] Step 130: Send a diagnostic response message to the diagnostic device so that the diagnostic device can perform diagnostics on the target controller identified by the response address based on the diagnostic response message.

[0081] In this embodiment, after the diagnostic response message is sent to the diagnostic device, the diagnostic device can parse the message and determine which controller corresponds to the information in the message based on the response address. The diagnostic device can parse the service identifier in the message to confirm the type of diagnostic service executed by the controller and analyze the data fields, such as fault codes, sensor readings, and controller status information. If the controller returns a positive response, the diagnostic device will continue the diagnostic process based on the response content; if a negative response is returned, the device will determine the reason for the request failure based on the negative response code (NRC) and decide whether to resend the request or take other diagnostic measures.

[0082] According to the vehicle controller diagnostic method of this application, a diagnostic request message sent by a diagnostic device is obtained. The diagnostic request message includes a request address, which is an address allocated from a first addressing interval. The diagnostic request message is sent to the target controller corresponding to the request address, and a diagnostic response message returned by the target controller is obtained. The diagnostic response message includes a response address, which is an address allocated from a second addressing interval. The diagnostic response message is then sent to the diagnostic device so that the diagnostic device can perform diagnostics on the target controller corresponding to the response address based on the diagnostic response message. This embodiment of the application expands the diagnostic addresses in controller diagnostic applications by using different addressing intervals to allocate request and response addresses, increasing the configurable number of controller diagnostic addresses, thereby supporting more controller diagnostics and improving controller diagnostic efficiency.

[0083] In some embodiments, the method further includes:

[0084] Determine the addressing mode;

[0085] The addressing interval is divided into the first addressing interval and the second addressing interval according to the addressing mode.

[0086] In this embodiment, different addressing methods are used during diagnostic communication under different network architectures. For example, in CAN, the diagnostic communication process uses the CAN / FD (CAN with Flexible Data Rate) protocol, and the addressing methods can include 11-bit CAN / FD standard frame addressing and 29-bit CAN / FD extended frame addressing; wherein, the arbitration segment of the CAN / FD standard frame includes an 11-bit base identifier, and the arbitration segment of the CAN / FD extended frame includes a 29-bit base identifier. In Ethernet, the addressing method can be Diagnostics over Internet Protocol (DoIP) addressing during the diagnostic communication process.

[0087] In this embodiment, the addressing mode can be determined based on the network architecture of the diagnostic communication process, and then the first addressing interval and the second addressing interval can be divided according to the addressing mode. For example, the first addressing interval corresponding to the 11-bit CAN / FD standard frame addressing mode is 0x700~0x7FF, and the corresponding second addressing interval is 0x600~0x6FF; the first addressing interval corresponding to the 29-bit CAN / FD extended frame addressing mode is 0x18DA00F1~0x18DAFFF1, and the corresponding second addressing interval is 0x18DAF100~0x18DAF1FF.

[0088] In this embodiment, by dividing the first addressing interval and the second addressing interval according to the addressing method, the application scenarios under various network architectures during the diagnostic process are taken into account, thereby improving the compatibility of the diagnostic communication process in different network environments.

[0089] In some embodiments, dividing a first addressing interval and a second addressing interval according to an addressing mode includes:

[0090] When the addressing mode is diagnostic addressing using standard frames, the first addressing interval and the second addressing interval are addressing intervals based on the identifier length of the standard frame; wherein, in the first addressing interval, the first target bit of each address represents a diagnostic request, and the second target bit is used to allocate the request address; in the second addressing interval, the first target bit of each address represents a diagnostic response, and the second target bit is used to allocate the response address.

[0091] In the CAN / FD protocol, a standard frame is a data frame structure that can include a start bit, an identifier, a control field, a data field, and a CRC (Cyclic Redundancy Check) check. The identifier of a standard frame is 11 bits long.

[0092] In this embodiment, the first addressing interval and the second addressing interval can be determined based on the identifier length of the standard frame. Specifically, the address lengths in the first addressing interval and the second addressing interval can be the same as the identifier length of the standard frame. For example, when the addressing mode is diagnostic addressing using an 11-bit CAN / FD standard frame, the first addressing interval can be 0x700 to 0x7FF, and the second addressing interval can be 0x600 to 0x6FF.

[0093] In this embodiment, the high 3 bits of the address within the first addressing interval can be the same. In this case, the high 3 bits of the address within the first addressing interval can be determined as the first target bit, used to represent a diagnostic request; and the low 8 bits of the address within the first addressing interval can be determined as the second target bit, used to allocate the requested address. The high 3 bits of the address within the second addressing interval can also be the same. In this case, the high 3 bits of the address within the second addressing interval can be determined as the first target bit, used to represent a diagnostic response; and the low 8 bits of the address within the second addressing interval can be determined as the second target bit, used to allocate the response address. For example, the high 3 bits of the first addressing interval (0x7) represent a diagnostic request, the high 3 bits of the second addressing interval (0x6) represent a diagnostic response, and the low 8 bits of both the first and second addressing intervals (0x00~0xFF) represent the diagnostic address. Through the first and second addressing intervals, 256 sets of diagnostic addresses can be configured, which can satisfy the needs of 256 vehicle diagnostic controllers.

[0094] In this embodiment, two addressing intervals are constructed based on the identifier length of the standard frame. In the first addressing interval, the first target bit of each address is dedicated to representing a diagnostic request, while the second target bit is used to allocate a specific request address. Correspondingly, in the second addressing interval, the first target bit of each address is used to represent a diagnostic response, while the second target bit is used to allocate a response address. This not only increases the number of configurable diagnostic addresses but also makes the diagnostic request and response clearly distinguishable, reducing the possibility of address conflicts.

[0095] In some embodiments, the method further includes:

[0096] When the addressing mode is diagnostic addressing using extended frames, the first addressing interval and the second addressing interval are addressing intervals based on the identifier length of the extended frame; wherein, the source address of the first addressing interval is used to allocate the request address, and the source address of the second addressing interval is used to allocate the response address.

[0097] In the CAN / FD protocol, an extended frame is a data frame structure that adds an extended identifier bit to the standard frame. The identifier bit length of an extended frame is 29 bits. The source address of an extended frame occupies 8 bits, with a source address range of 0x00 to 0xFF.

[0098] For example, when using a 29-bit CAN / FD extended frame for diagnostic addressing, the first addressing range is 0x18DA00F1 to 0x18DAFFF1, and the second addressing range is 0x18DAF100 to 0x18DAF1FF. The request address is allocated using the source address of the first addressing range, and the response address is allocated using the source address of the second addressing range. Since the lower 8 bits of the source address range are the same as those of the addressing range corresponding to diagnostic addressing using a standard frame (0x00 to 0xFF), this achieves unified reuse across different addressing modes, improving diagnostic compatibility under different addressing modes.

[0099] In this embodiment, by using addressing intervals based on the identifier length of extended frames, the source address of the first addressing interval is used to allocate the request address, while the source address of the second addressing interval is used to allocate the response address. This allows the diagnostic process to perform diagnostic communication in a wider address space, increasing the number of configurable diagnostic addresses and thus supporting more controllers and more complex network topologies.

[0100] In some embodiments, the method further includes:

[0101] When the addressing mode is diagnostic addressing via IP protocol using diagnostic communication, the first addressing range and the second addressing range are addressing ranges composed of logical addresses via IP protocol using diagnostic communication; wherein, the request address and response address of the same controller are the same.

[0102] In this embodiment, the logical address of DoIP is a unique identifier used to identify and distinguish different electronic control units (ECUs) in the vehicle network.

[0103] In this embodiment, during Ethernet DoIP communication, a logical address can be used to uniquely identify a controller. Therefore, when using DoIP for diagnostic addressing, the request address and response address of the same controller are the same, so the first addressing interval and the second addressing interval can also be the same. Furthermore, the first and second addressing intervals are addressing intervals composed of logical addresses, and the second target bit of the first and second addressing intervals can be used to allocate the request address or response address. For example, the first and second addressing intervals can be 0xXX00 to 0xXXFF, where the lower 8 bits (0x00 to 0xFF) represent the request address or response address. Since the lower 8 bits of the logical address interval are the same as those corresponding to the addressing interval using standard frames for diagnostic addressing (0x00 to 0xFF), the reuse and unification of different addressing modes are achieved, improving the compatibility of diagnostics under different addressing modes.

[0104] In this embodiment, the addressing range formed by the logical addresses of the IP protocol is used for diagnostic communication. The request address and response address of the same controller are the same, which enables efficient address allocation and diagnostic communication even in the IP protocol environment. This not only increases the number of configurable diagnostic addresses, but also further enhances the compatibility of the diagnostic system.

[0105] In some embodiments, the addressing ranges corresponding to different addressing modes are the same size.

[0106] In this embodiment, as shown in the table below, the source address range of the CAN / FD extended frame is 0x00 to 0xFF. The number of source addresses is the same as the number of diagnostic addresses in the CAN / FD standard frame. That is, the addressing range corresponding to the addressing modes of the CAN / FD extended frame and the standard frame is the same size. The source address content and the diagnostic address content of the 11-bit addressing mode are reused and unified. The lower 8 bits of the Ethernet DoIP logical address reuse the lower 8 bits of the CAN / FD standard frame address, achieving the reuse and unification of ECU diagnostic addresses under different networks. In other words, the lower 8 bits of the Ethernet DoIP diagnostic logical address, the lower 8 bits of the CAN / FD standard frame diagnostic address, and the source address of the CAN / FD extended frame are all unified.

[0107]

[0108] In this embodiment, all addressing modes provide the same addressing range, ensuring compatibility and consistency of the diagnostic system across different network environments. Regardless of the addressing mode chosen, the same address capacity can be expected, reducing additional configuration work. Furthermore, the uniform addressing range size also improves the scalability of the diagnostic system, enabling it to flexibly adapt to increases in the number of vehicle controllers and changes in network structure.

[0109] The vehicle controller diagnostic method provided in this application can be executed by a vehicle controller diagnostic device. This application uses the example of a vehicle controller diagnostic device executing the vehicle controller diagnostic method to illustrate the vehicle controller diagnostic device provided in this application.

[0110] This application also provides a diagnostic device for a vehicle controller.

[0111] like Figure 4 As shown, the diagnostic device for the vehicle controller includes:

[0112] The acquisition module 410 is used to acquire a diagnostic request message sent by the diagnostic device. The diagnostic request message includes a request address, which is an address allocated from the first addressing range. The request address is used to identify the target controller that needs to be diagnosed.

[0113] The sending module 420 is used to send a diagnostic request message to the target controller identified by the request address, and to obtain a diagnostic response message returned by the target controller. The diagnostic response message includes a response address, which is an address allocated from the second addressing range. The response address is used to identify the target controller that sent the diagnostic response message.

[0114] The diagnostic module 430 is used to send a diagnostic response message to the diagnostic device so that the diagnostic device can perform diagnostics on the target controller identified by the response address based on the diagnostic response message.

[0115] According to the diagnostic device for a vehicle controller of this application, the diagnostic request message sent by a diagnostic device is obtained. The diagnostic request message includes a request address, which is an address allocated from a first addressing interval. The request address is used to identify the target controller that needs to be diagnosed. The diagnostic request message is sent to the target controller identified by the request address, and a diagnostic response message returned by the target controller is obtained. The diagnostic response message includes a response address, which is an address allocated from a second addressing interval. The response address is used to identify the target controller that sent the diagnostic response message. The diagnostic response message is sent to the diagnostic device so that the diagnostic device can diagnose the target controller identified by the response address based on the diagnostic response message. This embodiment of the application expands the diagnostic addresses in controller diagnostic applications by using different addressing intervals to allocate request and response addresses, increasing the configurable number of controller diagnostic addresses, thereby supporting more controller diagnostics and improving the diagnostic efficiency of the controller.

[0116] In some embodiments, the apparatus further includes:

[0117] The partitioning module is used to determine the addressing mode; it divides the first addressing interval and the second addressing interval according to the addressing mode.

[0118] In some embodiments, the partitioning module is further configured to:

[0119] When the addressing mode is diagnostic addressing using standard frames, the first addressing interval and the second addressing interval are addressing intervals based on the identifier length of the standard frame; wherein, in the first addressing interval, the first target bit of each address represents a diagnostic request, and the second target bit is used to allocate the request address; in the second addressing interval, the first target bit of each address represents a diagnostic response, and the second target bit is used to allocate the response address.

[0120] In some embodiments, the partitioning module is further configured to:

[0121] When the addressing mode is diagnostic addressing using extended frames, the first addressing interval and the second addressing interval are addressing intervals based on the identifier length of the extended frame; wherein, the source address of the first addressing interval is used to allocate the request address, and the source address of the second addressing interval is used to allocate the response address.

[0122] In some embodiments, the partitioning module is further configured to:

[0123] When the addressing mode is diagnostic addressing via IP protocol using diagnostic communication, the first addressing range and the second addressing range are addressing ranges composed of logical addresses via IP protocol using diagnostic communication; wherein, the request address and response address of the same controller are the same.

[0124] The diagnostic device for the vehicle controller in this application embodiment can be a terminal or other devices besides a terminal. For example, the diagnostic device for the vehicle controller can be an in-vehicle electronic device, a mobile internet device (MID), a robot, an ultra-mobile personal computer (UMPC), an ECU (Electronic Control Unit), an MCU (Microcontroller Unit), or other controllers. It can also be a server, network attached storage (NAS), a personal computer (PC), a television set (TV), an ATM, or a self-service machine, etc. This application embodiment does not impose specific limitations.

[0125] The diagnostic device for the vehicle controller in this embodiment can be a device with an operating system. This operating system can be a Microsoft (Windows) operating system, an Android operating system, an iOS operating system, or other possible operating systems; this embodiment does not specifically limit the specific operating system.

[0126] In some embodiments, such as Figure 5 As shown, this application embodiment also provides an electronic device 500, including a processor 501, the processor 501 being connected to a memory 502, the memory 502 storing a computer program that can run on the processor 501. When the program is executed by the processor 501, it implements the various processes of the above-described vehicle controller diagnostic method embodiment and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0127] It should be noted that the electronic devices in the embodiments of this application include the aforementioned mobile electronic devices and non-mobile electronic devices.

[0128] This application also provides a diagnostic system for a vehicle controller, including: a diagnostic device, multiple controllers, and a gateway device;

[0129] Gateway devices are used to perform diagnostic methods for vehicle controllers as described above.

[0130] This application also provides a vehicle that includes the diagnostic system of the vehicle controller described above, or the vehicle includes the electronic equipment described above.

[0131] This application also provides a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, it implements the various processes of the above-described vehicle controller diagnostic method embodiments and achieves the same technical effect. To avoid repetition, it will not be described again here.

[0132] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0133] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the diagnostic method for the vehicle controller described above.

[0134] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0135] This application embodiment also provides a chip, which includes a processor and a communication interface. The communication interface and the processor are coupled. The processor is used to run programs or instructions to implement the various processes of the above-described vehicle controller diagnostic method embodiment and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0136] It should be understood that the chip mentioned in the embodiments of this application may also be referred to as a system-on-a-chip, system chip, chip system, or system-on-a-chip, etc.

[0137] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.

[0138] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0139] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.

[0140] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "illustrative embodiment," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.

[0141] Although embodiments of this application have been shown and described, those skilled in the art will understand that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of this application, the scope of which is defined by the claims and their equivalents.

Claims

1. A diagnostic method of a vehicle controller, characterized by, include: Acquire a diagnostic request message sent by a diagnostic device, the diagnostic request message including a request address, the request address being an address allocated from a first addressing range; The request address is used to identify the target controller that needs to be diagnosed; The diagnostic request message is sent to the target controller identified by the request address, and a diagnostic response message is returned by the target controller. The diagnostic response message includes a response address, which is an address allocated from the second addressing range. The response address is used to identify the target controller that sent the diagnostic response message. The diagnostic response message is sent to the diagnostic device so that the diagnostic device can diagnose the target controller identified by the response address based on the diagnostic response message; The method further includes: Determine the addressing mode; The first addressing interval and the second addressing interval are divided according to the addressing mode; When the addressing mode is diagnostic addressing using standard frames, the first addressing interval and the second addressing interval are addressing intervals based on the identifier length of the standard frame; wherein, in the first addressing interval, the first target bit of each address represents a diagnostic request, and the second target bit is used to allocate the request address; in the second addressing interval, the first target bit of each address represents a diagnostic response, and the second target bit is used to allocate the response address; When the addressing mode is diagnostic addressing using extended frames, the first addressing interval and the second addressing interval are addressing intervals based on the identifier length of the extended frame; wherein, the source address of the first addressing interval is used to allocate the request address, and the source address of the second addressing interval is used to allocate the response address. When the addressing mode is diagnostic addressing via IP protocol using diagnostic communication, the first addressing range and the second addressing range are addressing ranges composed of logical addresses via IP protocol using diagnostic communication; wherein, the request address and response address of the same controller are the same.

2. The method of claim 1, wherein, The vehicle includes multiple controllers, each controller is assigned a diagnostic address, the request address in the diagnostic address is an address assigned from the first addressing interval; the response address in the diagnostic address is an address assigned from the second addressing interval; the request address and response address of the same controller have at least partially the same composition.

3. The method according to claim 1, characterized in that, The addressing ranges corresponding to different addressing modes are the same size.

4. A diagnostic apparatus of a vehicle controller characterized by comprising: For implementing the method as described in any one of claims 1-3, comprising: The acquisition module is used to acquire a diagnostic request message sent by the diagnostic device. The diagnostic request message includes a request address, which is an address allocated from a first addressing range. The request address is used to identify the target controller that needs to be diagnosed. The sending module is configured to send the diagnostic request message to the target controller identified by the request address, and obtain a diagnostic response message returned by the target controller. The diagnostic response message includes a response address, which is an address allocated from the second addressing range. The response address is used to identify the target controller that sent the diagnostic response message. The diagnostic module is used to send the diagnostic response message to the diagnostic device, so that the diagnostic device can perform diagnostics on the target controller identified by the response address based on the diagnostic response message; The device further includes: A partitioning module is used to determine the addressing mode; and to partition the first addressing interval and the second addressing interval according to the addressing mode.

5. A diagnostic system for a vehicle controller, characterized by include: Diagnostic equipment, multiple controllers and gateway devices; The gateway device is configured to perform the method as described in any one of claims 1-3.

6. An electronic device comprising a processor connected with a memory, the memory storing a computer program operable on the processor, characterized in that, When the processor executes the program, it implements the method as described in any one of claims 1-3.

7. A vehicle characterized by comprising: The vehicle includes the system as described in claim 5, or the vehicle includes the electronic equipment as described in claim 6.