Method, device, equipment and medium for automatically generating diagnostic application data packets

By filling in the diagnostic requirement data into a preset template to generate a differential data package with a unified format, and combining it with a general data package, the problem of low efficiency in generating diagnostic data packages is solved and efficient and accurate diagnostic data package generation is achieved.

CN117574869BActive Publication Date: 2024-10-29镁佳(北京)科技有限公司
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202311359586.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-10-19
Publication Date
2024-10-29
Estimated Expiration
2043-10-19

AI Technical Summary

Technical Problem

When customers provide a large amount of diagnostic data and the demand is urgent, it is difficult for the existing technology to efficiently generate diagnostic data packages and is prone to errors.

Method used

By obtaining the diagnostic requirement data and filling it in the preset diagnostic file template, a differential data package with a uniform format is generated and combined with the preset general data package to form a diagnostic application data package.

Benefits of technology

It improves the efficiency and accuracy of generating diagnostic data packages, avoids errors in manual coding, simplifies the diagnostic framework, and facilitates maintenance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117574869B_ABST
    Figure CN117574869B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of data diagnosis technology, and discloses a method, device, equipment and medium for automatically generating a diagnostic application data packet, the method comprising: obtaining diagnostic demand data; filling the diagnostic demand data into a preset diagnostic file template; generating a difference data packet with a uniform format according to the diagnostic demand data in the diagnostic file template; and combining the difference data packet and the preset general data packet to form a diagnostic application data packet. The diagnostic application data packet generated by the present invention has high efficiency and high accuracy, and solves the problem of low efficiency in generating diagnostic data packets when the amount of diagnostic data provided by the customer is large and the demand time is urgent.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data diagnosis, and in particular to a method, device, equipment and medium for automatically generating a diagnostic application data packet. Background Art

[0002] Unified Diagnostic Services (UDS) is a standard protocol for diagnosis and communication between automotive electronic control units (ECUs). It is a low-level protocol that is mainly used to diagnose and program various automotive systems, such as engines, transmissions, brakes, and airbags. The UDS protocol can be used to read real-time data from automotive electronic control units (ECUs), such as engine speed, vehicle speed, oil temperature, and other parameters. Through the UDS protocol, diagnostic tools can send instructions to the ECU, read real-time data, and analyze this data through specific diagnostic tools to help technicians locate and solve vehicle problems.

[0003] When analyzing these data through diagnostic data, it is necessary to generate a diagnostic data packet according to the diagnostic requirement data provided by the customer. When the amount of diagnostic requirement data provided by the customer is large and the requirement is urgent, it is necessary to check the diagnostic requirement data provided by the customer, write specific diagnostic application functions in turn, and generate a diagnostic data packet for each diagnostic application function, which makes the data packet generation efficiency low. Since each diagnostic requirement data is different, it is easy to make mistakes during the generation process. Summary of the invention

[0004] In view of this, the present invention provides a method, apparatus, device and medium for automatically generating diagnostic application data packets to solve the problem of low efficiency in generating diagnostic data packets when the amount of diagnostic data provided by the customer is large and the time required is urgent.

[0005] In a first aspect, the present invention provides a method for automatically generating a diagnostic application data packet, the method comprising:

[0006] Obtain diagnostic demand data;

[0007] Fill in the diagnostic requirement data into the preset diagnostic file template;

[0008] Generate a difference data package with a unified format according to the diagnostic requirement data in the diagnostic file template;

[0009] The difference data package and the preset common data package are combined to form a diagnostic application data package.

[0010] The method for automatically generating a diagnostic application data packet provided by the present invention fills the diagnostic requirement data into a preset diagnostic file template, generates a differential data packet in a uniform format according to the diagnostic requirement data in the diagnostic file template, thereby realizing one-time generation of differential data packets for a large amount of customer diagnostic requirement data, and combining the differential data packet with the preset general data packet to form a diagnostic application data packet. The generated diagnostic application data packet has high efficiency and high accuracy, and solves the problem of low efficiency in generating diagnostic data packets when the customer provides a large amount of diagnostic data and the requirement is urgent.

[0011] In an optional implementation, the diagnostic requirement data includes any one or more of diagnostic and communication control function group data, data transmission function group data, input and output control data, and routine control data.

[0012] In an optional implementation, the diagnosis and communication control function group data, the data transmission function group data, the input and output control data and the routine control data all include: a diagnostic service ID and a service name corresponding to the diagnostic service ID.

[0013] The method for automatically generating a diagnostic application data packet provided by the present invention divides the diagnostic requirement data into diagnostic and communication control function group data, data transmission function group data, input and output control data, and routine control data. Each type of data includes a diagnostic service ID and a service name corresponding to the diagnostic service ID, thereby providing a data and format basis for the subsequent generation of difference data packets.

[0014] In an optional embodiment, the preset diagnostic file template includes a diagnostic service ID, a service name corresponding to the diagnostic service ID, a sub-function ID' corresponding to the diagnostic service ID, a sub-function service name corresponding to the sub-function ID', a prohibition / affirmative response bit, physical addressing, functional addressing, supported negative response codes and explanatory notes.

[0015] In an optional implementation, filling the diagnostic requirement data into a preset diagnostic file template includes:

[0016] Obtain the diagnostic service ID, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, the physical addressing, the functional addressing, the supported negative response codes and the description notes in the diagnostic requirement data;

[0017] Fill in the preset diagnostic file template with the diagnostic service ID, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, physical addressing, functional addressing, supported negative response codes and explanatory notes in the diagnostic requirement data.

[0018] The method for automatically generating a diagnostic application data packet provided by the present invention, the preset diagnostic file template summarizes the diagnostic service ID in the diagnostic requirement data, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, the physical addressing, the functional addressing, the supported negative response codes and the description notes into a unified data format template, thereby improving the accuracy of the data and providing a template basis for the subsequent generation of a unified format difference data packet.

[0019] In an optional implementation, the format unification includes data format unification, data character space unification and data arrangement unification;

[0020] The difference data packages that generate the unified format of the diagnostic requirement data in the diagnostic file template include:

[0021] Using a diagnostic tool to parse the diagnostic requirement data in the diagnostic file template to generate parsed data;

[0022] Based on the parsed data, a difference data packet with a unified data format, unified data occupied character space and unified data arrangement is generated.

[0023] The method for automatically generating a diagnostic application data packet provided by the present invention adopts a diagnostic tool to parse the diagnostic requirement data in the diagnostic file template to generate parsed data; based on the parsed data, a difference data packet with a unified data format, a unified data character space occupied by the data, and a unified data arrangement is generated, so that the data of the difference data packet is neat, the accuracy is high, and it is easy to calibrate; the diagnostic tool is used to generate the parsed data, and finally the difference data packet is generated, and code writing is not performed by manually comparing the diagnostic data, thereby avoiding the problem of easy errors in the process of generating data packets for each diagnostic requirement data one by one in turn, and improving the efficiency and accuracy of generating the difference data packet.

[0024] In an optional implementation, the preset common data packet is a common data packet generated according to the diagnostic standard and having the same format as the difference data packet, and combining the difference data packet and the preset common data packet to form a diagnostic application data packet includes:

[0025] The difference data package and the preset common data package are superimposed to form a diagnostic application data package.

[0026] The method for automatically generating a diagnostic application data packet provided by the present invention presets a universal data packet as a universal data packet generated according to a diagnostic standard and having a unified format with a differential data packet, and superimposes the differential data packet and the preset universal data packet to form a diagnostic application data packet. The diagnostic data packets are separated by universality and difference, so that the diagnostic framework is concise and clear, easy to maintain, and the data format and function of the constructed diagnostic application data packet are complete, and the data accuracy is high.

[0027] In a second aspect, the present invention provides a device for automatically generating a diagnostic application data packet, the device comprising:

[0028] An acquisition module, used to acquire diagnostic requirement data;

[0029] A filling module is used to fill in the diagnostic requirement data into the preset diagnostic file template;

[0030] A generation module, used for generating a difference data packet with a unified data format according to the diagnosis requirement data in the diagnosis file template;

[0031] The combination module is used to combine the difference data package and the preset common data package to form a diagnosis application data package.

[0032] In a third aspect, the present invention provides a computer device comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the method for automatically generating diagnostic application data packets according to the first aspect or any corresponding embodiment thereof by executing the computer instructions.

[0033] In a fourth aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the method for automatically generating a diagnostic application data packet according to the first aspect or any corresponding embodiment thereof. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0035] Figure 1 is a flow chart of a method for automatically generating a diagnostic application data packet according to an embodiment of the present invention;

[0036] Figure 2 is a flow chart of another method for automatically generating a diagnostic application data packet according to an embodiment of the present invention;

[0037] Figure 3 is a flowchart of another method for automatically generating a diagnostic application data packet according to an embodiment of the present invention;

[0038] Figure 4 is a flowchart of another method for automatically generating a diagnostic application data packet according to an embodiment of the present invention;

[0039] Figure 5 is a structural block diagram of an apparatus for automatically generating a diagnostic application data packet according to an embodiment of the present invention;

[0040] Figure 6 It is a schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0041] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.

[0042] According to an embodiment of the present invention, a method embodiment for automatically generating a diagnostic application data packet is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0043] In this embodiment, a method for automatically generating a diagnostic application data packet is provided, which can be used in a controller. Figure 1 is a flow chart of a method for automatically generating a diagnostic application data packet according to an embodiment of the present invention. Figure 1 As shown, the process includes the following steps:

[0044] Step S101, obtaining diagnostic requirement data.

[0045] Specifically, the diagnostic demand data includes the customer demand data involved in the unified diagnostic service UDS. The diagnostic demand data can be the internal data of the automotive electronic control unit (Electronic Control Unit, referred to as ECU) requested by the diagnostic device, specifically including: current data: data that the ECU is running, such as vehicle speed, throttle opening, engine speed, etc.; stored data: data stored in the memory by the ECU at a certain moment, such as DTC (Diagnostic Trouble Code); static data: constant ECU internal data, such as VIN code (Vehicle Identification Number). When the customer has the need to diagnose the automotive system, the diagnostic demand data provided by the customer is obtained.

[0046] For example, the diagnostic requirement data may be a diagnostic and communication control function group, including a diagnostic service ID and a service name of a diagnostic service, where the service name is the specific content of the service. The diagnostic service ID refers to a diagnostic service identifier.

[0047] Step S102, filling the diagnosis requirement data into a preset diagnosis file template.

[0048] Specifically, the preset diagnostic file template can be set as an Excel table, and a unified corresponding header format is set for each diagnostic requirement data. When a difference data packet needs to be generated, the diagnostic service ID in the diagnostic requirement data and the specific content of the diagnostic service corresponding to the diagnostic service ID need to be filled in the preset diagnostic file template. The specific content of the diagnostic service can be electronic control unit reset diagnosis, diagnostic session control, security access diagnosis, communication control diagnosis, etc.

[0049] Step S103, generating a differential data packet with a uniform format according to the diagnostic requirement data in the diagnostic file template. Specifically, the differential data packet is a data packet generated for the specific content in the customer's diagnostic requirement data. When the diagnostic requirement data is filled in the diagnostic file template, a diagnostic tool can be used to generate a differential data packet with a uniform format for the specific content in the diagnostic requirement data.

[0050] For example, the electronic control unit reset diagnosis, diagnostic session control, security access diagnosis, and communication control diagnosis in the specific content of the diagnostic service may be generated into a differential data packet with a unified format.

[0051] Step S104, combining the difference data packet and the preset common data packet to form a diagnostic application data packet. Specifically, the preset common data packet can be a data packet with a unified diagnostic function generated according to the diagnostic standard. The diagnostic application data packet is composed of the difference data packet and the preset common data packet. After the difference data packet is generated, it can be directly superimposed with the common data packet to form a diagnostic application data packet.

[0052] The method for automatically generating a diagnostic application data packet provided by the present invention fills the diagnostic requirement data into a preset diagnostic file template, generates a differential data packet in a uniform format according to the diagnostic requirement data in the diagnostic file template, thereby realizing one-time generation of differential data packets for a large amount of customer diagnostic requirement data, and combining the differential data packet with the preset general data packet to form a diagnostic application data packet. The generated diagnostic application data packet has high efficiency and high accuracy, and solves the problem of low efficiency in generating diagnostic data packets when the customer provides a large amount of diagnostic data and the requirement is urgent.

[0053] In this embodiment, a method for automatically generating a diagnostic application data packet is provided, which can be used in the above-mentioned controller. Figure 2is a flow chart of a method for automatically generating a diagnostic application data packet according to an embodiment of the present invention. Figure 2 As shown, the process includes the following steps:

[0054] Step S201, obtaining diagnostic demand data. Specifically, the diagnostic demand data includes: any one or more of diagnostic and communication control function group data, data transmission function group data, input and output control data, and routine control data. The diagnostic and communication control function group data, data transmission function group data, input and output control data, and routine control data all include: a diagnostic service ID and a service name corresponding to the diagnostic service ID, where the service name is the specific content of the service.

[0055] The diagnostic and communication control function group data includes six sub-functions, namely diagnostic service ID10 and the corresponding diagnostic session control diagnosis, diagnostic service ID11 and the corresponding electronic control unit reset diagnosis, diagnostic service ID27 and the corresponding security access diagnosis, diagnostic service ID28 and the corresponding communication control diagnosis, diagnostic service ID14 and the corresponding clearing of diagnostic information, and diagnostic service ID19 and the corresponding reading of fault code information.

[0056] The data transmission function group data includes two sub-functions, namely, diagnostic service ID22 and corresponding reading data diagnosis according to identifier, and diagnostic service ID2E and corresponding writing data diagnosis according to identifier.

[0057] The input / output control data includes the diagnostic service ID2F and the corresponding input / output control diagnosis.

[0058] The routine control data includes the diagnostic data ID 31 and the corresponding routine control diagnosis.

[0059] The specific diagnostic requirements are shown in Table 1 below:

[0060] Table 1

[0061]

[0062] Step S202: Fill the diagnosis requirement data into a preset diagnosis file template.

[0063] Exemplarily, the preset diagnostic file template includes a diagnostic service ID, a service name corresponding to the diagnostic service ID, a sub-function ID' corresponding to the diagnostic service ID, a sub-function service name corresponding to the sub-function ID', a prohibition / affirmative response bit, physical addressing, functional addressing, supported negative response codes and explanatory notes.

[0064] Specifically, the above step S202 includes:

[0065] Step S2021, obtain the diagnostic service ID in the diagnostic requirement data, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, physical addressing, functional addressing, supported negative response codes and description notes.

[0066] Step S2022, fill in the preset diagnostic file template with the diagnostic service ID, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, physical addressing, functional addressing, supported negative response codes and explanatory notes in the diagnostic requirement data.

[0067] For example, when the diagnostic requirement data belongs to the diagnostic and communication control function group diagnostic category, the diagnostic requirement data is filled into the preset diagnostic file template as shown in Table 2 below:

[0068] Table 2

[0069]

[0070]

[0071]

[0072] In Table 2, Y indicates that the ECU supports it, N indicates that the ECU does not support it, and N / A indicates that the service does not contain sub-functions.

[0073] Step S203: Generate a difference data packet with a unified format according to the diagnosis requirement data in the diagnosis file template. Figure 1 Step S103 of the illustrated embodiment will not be described in detail here.

[0074] Step S204: Combine the difference data package and the preset common data package to form a diagnostic application data package. Figure 1 Step S104 of the illustrated embodiment will not be described in detail here.

[0075] The method for automatically generating a diagnostic application data packet provided by the present invention, the preset diagnostic file template aggregates the diagnostic service ID in the diagnostic requirement data, the service name corresponding to the diagnostic service ID, the data source corresponding to the diagnostic service ID, the diagnostic mode corresponding to the diagnostic service ID, the service data type corresponding to the diagnostic service ID and the description remarks into a unified data format template, thereby improving the accuracy of the data and providing a template basis for the subsequent generation of a unified format difference data packet.

[0076] In this embodiment, a method for automatically generating a diagnostic application data packet is provided, which can be used in the above-mentioned controller. Figure 3is a flow chart of a method for automatically generating a diagnostic application data packet according to an embodiment of the present invention. Figure 3 As shown, the process includes the following steps:

[0077] Step S301, obtain diagnostic requirement data. Figure 2 Step S201 of the illustrated embodiment will not be described in detail here.

[0078] Step S302: Fill the diagnostic requirement data into the preset diagnostic file template. Figure 2 Step S202 of the illustrated embodiment will not be described in detail here.

[0079] Step S303, generating a difference data packet with a unified format according to the diagnosis requirement data in the diagnosis file template. The unified format includes unified data format, unified character space occupied by data and unified data arrangement.

[0080] Specifically, the above step S303 includes:

[0081] Step S3031, using a diagnostic tool to parse the diagnostic requirement data in the diagnostic file template to generate parsed data. Specifically, the diagnostic tool can be implemented in Python language, using Python language to parse the diagnostic requirement data in the diagnostic file template, obtain the specific data of each diagnostic service of the diagnostic and communication control function group data, data transmission function group data, input and output control data and routine control data, and generate a diagnostic code as parsed data.

[0082] Step S3032, generating a difference data packet with a unified data format, unified data occupied character space, and unified data arrangement based on the parsed data.

[0083] Specifically, a diagnostic tool is used to generate differential data packets with unified data format, unified data occupied character space and unified data arrangement for diagnostic codes of specific data of each diagnostic service, including diagnostic and communication control function group data, data transmission function group data, input and output control data and routine control data.

[0084] Step S304, combining the difference data packet and the preset common data packet to form a diagnostic application data packet. Specifically, the preset common data packet is a common data packet generated according to the diagnostic standard and having the same format as the difference data packet. The diagnostic standard is the UDS automotive diagnostic standard protocol ISO 14229-1. According to the UDS automotive diagnostic standard protocol ISO 14229-1, a diagnostic service with unified functions is generated into a common data packet in the same format as the difference data packet. After the difference data packet is generated, the difference data packet and the preset common data packet are superimposed to form a complete diagnostic application data packet.

[0085] The method for automatically generating a diagnostic application data packet provided by the present invention uses a diagnostic tool to parse the diagnostic requirement data in the diagnostic file template to generate parsed data; based on the parsed data, a difference data packet with a unified data format, uniform data occupied character space, and uniform data arrangement is generated, so that the data of the difference data packet is neat, high in accuracy, and easy to calibrate; the diagnostic tool is used to generate parsed data, and finally a difference data packet is generated, and code writing is not performed by manually comparing the diagnostic data, thereby avoiding the problem of easy errors in the process of generating a data packet for each diagnostic requirement data in sequence, and improving the efficiency and accuracy of generating the difference data packet. The diagnostic data packet is separated by universality and difference, so that the diagnostic framework is concise and clear, easy to maintain, and the data format and function of the constructed diagnostic application data packet are complete, and the data accuracy is high.

[0086] As one or more specific application embodiments of the embodiments of the present invention, Figure 4 As shown, the method for automatically generating a diagnostic application data packet can be implemented using the following process:

[0087] Step S401, obtaining diagnostic requirement data provided by the customer.

[0088] Specifically, the diagnostic demand data includes the customer demand data involved in the unified diagnostic service UDS. The diagnostic demand data can be the internal data of the automotive electronic control unit (Electronic Control Unit, referred to as ECU) requested by the diagnostic device, specifically including: current data: data that the ECU is running, such as vehicle speed, throttle opening, engine speed, etc.; stored data: data stored in the memory by the ECU at a certain moment, such as DTC (Diagnostic Trouble Code); static data: constant ECU internal data, such as VIN code (Vehicle Identification Number). When the customer has the need to diagnose the automotive system, the diagnostic demand data provided by the customer is obtained.

[0089] For example, the diagnostic requirement data may be a diagnostic and communication control function group, including a diagnostic service ID and a service name of a diagnostic service, where the service name is the specific content of the service. The diagnostic service ID refers to a diagnostic service identifier.

[0090] The diagnostic and communication control function group data includes six sub-functions, namely diagnostic service ID10 and the corresponding diagnostic session control diagnosis, diagnostic service ID11 and the corresponding electronic control unit reset diagnosis, diagnostic service ID27 and the corresponding security access diagnosis, diagnostic service ID28 and the corresponding communication control diagnosis, diagnostic service ID14 and the corresponding clearing of diagnostic information, and diagnostic service ID19 and the corresponding reading of fault code information.

[0091] The data transmission function group data includes two sub-functions, namely, diagnostic service ID22 and corresponding reading data diagnosis according to identifier, and diagnostic service ID2E and corresponding writing data diagnosis according to identifier.

[0092] The input / output control data includes the diagnostic service ID2F and the corresponding input / output control diagnosis.

[0093] The routine control data includes the diagnostic data ID 31 and the corresponding routine control diagnosis.

[0094] The specific diagnostic requirements are shown in Table 1 below:

[0095] Table 1

[0096]

[0097] Step S402, obtain the diagnostic service ID in the diagnostic requirement data, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, physical addressing, functional addressing, supported negative response codes and description notes.

[0098] Step S403, fill in the preset diagnostic file template with the diagnostic service ID, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, the physical addressing, the functional addressing, the supported negative response codes and the description notes in the diagnostic requirement data.

[0099] Step S404, using a diagnostic tool to parse the diagnostic requirement data in the diagnostic file template to generate parsed data. Specifically, the diagnostic tool can be implemented in Python language, and the diagnostic requirement data in the diagnostic file template is parsed in Python language to obtain the specific data of each diagnostic service of the diagnostic and communication control function group data, the data transmission function group data, the input and output control data and the routine control data to generate a diagnostic code as the parsed data.

[0100] Step S405 , generating a difference data packet with a unified data format, unified character space occupied by the data, and unified data arrangement based on the parsed data.

[0101] Specifically, a diagnostic tool is used to generate differential data packets with unified data format, unified data occupied character space and unified data arrangement for diagnostic codes of specific data of each diagnostic service, including diagnostic and communication control function group data, data transmission function group data, input and output control data and routine control data.

[0102] Step S406, combining the difference data packet and the preset common data packet to form a diagnostic application data packet. Specifically, the preset common data packet is a common data packet generated according to the diagnostic standard and having the same format as the difference data packet. The diagnostic standard is the UDS automotive diagnostic standard protocol ISO 14229-1. According to the UDS automotive diagnostic standard protocol ISO 14229-1, a diagnostic service with unified functions is generated into a common data packet in the same format as the difference data packet. After the difference data packet is generated, the difference data packet and the preset common data packet are superimposed to form a complete diagnostic application data packet.

[0103] The method for automatically generating a diagnostic application data packet provided by the present invention splits the entire diagnostic requirement data packet according to universality and diversity. Each project of the universal data packet remains consistent, thereby improving code utilization. The difference data packet is generated by a diagnostic tool, and the generated difference data packet is accurate and fast, thereby greatly improving development efficiency and data packet correctness.

[0104] In the present embodiment, a device for automatically generating a diagnostic application data packet is also provided, and the device is used to implement the above-mentioned embodiment and the preferred implementation mode, and the description thereof has been made no further. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the device described in the following embodiments is preferably implemented with software, the implementation of hardware, or a combination of software and hardware is also possible and contemplated.

[0105] This embodiment provides a device for automatically generating a diagnostic application data packet, such as Figure 5 As shown, including:

[0106] The acquisition module 501 is used to acquire diagnosis requirement data.

[0107] The filling module 502 is used to fill the diagnosis requirement data into the preset diagnosis file template.

[0108] The generating module 503 is used to generate a difference data packet with a unified data format according to the diagnosis requirement data in the diagnosis file template.

[0109] The combining module 504 is used to combine the difference data packet and the preset common data packet to form a diagnostic application data packet.

[0110] In some optional implementations, the filling module 502 includes:

[0111] An acquisition unit, used to acquire the diagnostic service ID, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, the physical addressing, the functional addressing, the supported negative response codes and the description remarks in the diagnostic requirement data;

[0112] The filling unit is used to fill in the diagnostic service ID in the diagnostic requirement data, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, the physical addressing, the functional addressing, the supported negative response codes and the description notes into the preset diagnostic file template.

[0113] In some optional implementations, the generating module 503 includes:

[0114] The first generating unit uses a diagnostic tool to parse the diagnostic requirement data in the diagnostic file template to generate parsed data.

[0115] The second generating unit is used to generate a difference data packet with a unified data format, a unified data occupied character space and a unified data arrangement based on the parsed data.

[0116] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.

[0117] The device for automatically generating diagnostic application data packets in this embodiment is presented in the form of functional units, where the units refer to ASIC (Application Specific Integrated Circuit) circuits, processors and memories that execute one or more software or fixed programs, and / or other devices that can provide the above-mentioned functions.

[0118] The embodiment of the present invention also provides a computer device having the above Figure 5 The apparatus shown automatically generates diagnostic application data packets.

[0119] See also Figure 6 , Figure 6 is a schematic diagram of the structure of a computer device provided by an optional embodiment of the present invention, such as Figure 6As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 6 A processor 10 is taken as an example.

[0120] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic or any combination thereof.

[0121] The memory 20 stores instructions executable by at least one processor 10, so that the at least one processor 10 executes the method shown in the above embodiment.

[0122] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0123] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.

[0124] The computer device also includes an input device 30 and an output device 40. The processor 10, the memory 20, the input device 30 and the output device 40 may be connected via a bus or other means. Figure 6 The example of connecting through bus is taken in the following.

[0125] The input device 30 can receive input digital or character information, and generate key signal input related to the user settings and function control of the computer device, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, an indicator bar, one or more mouse buttons, a trackball, a joystick, etc. The output device 40 may include a display device, an auxiliary lighting device (e.g., an LED) and a tactile feedback device (e.g., a vibration motor), etc. The above-mentioned display device includes but is not limited to a liquid crystal display, a light emitting diode, a display and a plasma display. In some optional embodiments, the display device can be a touch screen.

[0126] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.

[0127] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.

Claims

1. A method for automatically generating a diagnostic application data packet, characterized in that: The method comprises: Obtain diagnostic demand data; Filling the diagnostic requirement data into a preset diagnostic file template; Generate a difference data packet with a unified format according to the diagnosis requirement data in the diagnosis file template; Combining the difference data packet and the preset common data packet to form a diagnostic application data packet; The diagnostic requirement data includes: any one or more of diagnostic and communication control function group data, data transmission function group data, input and output control data and routine control data; The diagnostic and communication control function group data, data transmission function group data, input and output control data and routine control data all include: a diagnostic service ID and a service name corresponding to the diagnostic service ID; The preset diagnosis file template includes a diagnosis service ID, a service name corresponding to the diagnosis service ID, a sub-function ID' corresponding to the diagnosis service ID, a sub-function service name corresponding to the sub-function ID', a prohibition / affirmative response bit, a physical address, a functional address, supported negative response codes, and description notes; The format unification includes data format unification, data character space unification and data arrangement unification; Generating a differential data package with a unified format for the diagnostic requirement data in the diagnostic file template includes: Using a diagnostic tool to parse the diagnostic requirement data in the diagnostic file template to generate parsed data; Based on the parsed data, a difference data packet with a unified data format, a unified data occupied character space, and a unified data arrangement is generated; According to the UDS automotive diagnostic standard protocol ISO 14229-1, diagnostic services with unified functions are generated into a common data packet with the same format as the difference data packet. After the difference data packet is generated, the difference data packet and the preset common data packet are superimposed to form a complete diagnostic application data packet. Filling the diagnostic requirement data into the preset diagnostic file template includes: Obtain the diagnostic service ID, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, the physical addressing, the functional addressing, the supported negative response codes and the description notes in the diagnostic requirement data; The diagnostic service ID, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, physical addressing, functional addressing, supported negative response codes and description notes in the diagnostic requirement data are filled in the preset diagnostic file template accordingly.

2. The method according to claim 1, characterized in that The preset universal data packet is a universal data packet generated according to the diagnostic standard and having the same format as the difference data packet.

3. A device for automatically generating a diagnostic application data packet, characterized in that: The device comprises: An acquisition module, used to acquire diagnostic requirement data; A filling module is used to fill the diagnosis requirement data into a preset diagnosis file template; A generating module, used for generating a difference data packet with a unified data format according to the diagnostic requirement data in the diagnostic file template; A combining module, used for combining the difference data packet and the preset common data packet to form a diagnostic application data packet; The diagnostic requirement data includes: any one or more of diagnostic and communication control function group data, data transmission function group data, input and output control data and routine control data; The diagnostic and communication control function group data, data transmission function group data, input and output control data and routine control data all include: a diagnostic service ID and a service name corresponding to the diagnostic service ID; The preset diagnosis file template includes a diagnosis service ID, a service name corresponding to the diagnosis service ID, a sub-function ID' corresponding to the diagnosis service ID, a sub-function service name corresponding to the sub-function ID', a prohibition / affirmative response bit, a physical address, a functional address, supported negative response codes, and description notes; The format unification includes data format unification, data character space unification and data arrangement unification; Generating a differential data package with a unified format for the diagnostic requirement data in the diagnostic file template includes: Using a diagnostic tool to parse the diagnostic requirement data in the diagnostic file template to generate parsed data; Based on the parsed data, a difference data packet with a unified data format, a unified data occupied character space, and a unified data arrangement is generated; According to the UDS automotive diagnostic standard protocol ISO 14229-1, diagnostic services with unified functions are generated into a common data packet with the same format as the difference data packet. After the difference data packet is generated, the difference data packet and the preset common data packet are superimposed to form a complete diagnostic application data packet. The filling module includes: an acquisition unit, which is used to acquire the diagnostic service ID in the diagnostic demand data, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, the physical addressing, the functional addressing, the supported negative response codes and the description remarks; The filling unit is used to fill in the diagnostic service ID in the diagnostic requirement data, the service name corresponding to the diagnostic service ID, the sub-function ID' corresponding to the diagnostic service ID, the sub-function service name corresponding to the sub-function ID', the prohibition / affirmative response bit, the physical addressing, the functional addressing, the supported negative response codes and the description notes into the preset diagnostic file template.

4. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the method for automatically generating a diagnostic application data packet as described in any one of claims 1 and 2 by executing the computer instructions.

5. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions for causing a computer to execute the method for automatically generating a diagnostic application data package according to any one of claims 1 and 2.

Citation Information

Patent Citations

  • Test method and test system of engine controller software diagnosis module

    CN105224447A

  • Fuzzy test method and system for vehicle CAN bus, electronic equipment and storage medium

    CN111865743A

  • Test case generation method and device, computer equipment and storage medium

    CN114443503A

  • Vehicle diagnosis demand data processing method and device, equipment and storage medium

    CN116244348A