CAN message analysis device

The CAN message analysis device deciphers the format of CAN messages by correlating vehicle information with identification numbers and digit ranges, addressing the challenge of unknown message formats and enhancing accuracy through noise filtering.

JP2026065795APending Publication Date: 2026-04-16TOYOTA JIDOSHA KK
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
JP2024174741
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Filing Date
2024-10-04
Publication Date
2026-04-16

AI Technical Summary

Technical Problem

Conventional devices fail to decipher the format of CAN messages when the format is unknown, specifically failing to identify the identification number of a CAN message or the range of digits in the data field where engine torque values are stored, as the format varies by vehicle manufacturer.

Method used

A CAN message analysis device that generates and analyzes CAN messages, identifies the correspondence between vehicle information stored in the data field and its identification number, and determines the range of digits using a reference data generation unit, candidate data generation unit, filter unit, and comparison unit to decipher the message format.

Benefits of technology

Enables the identification of the format of CAN messages even when unknown, improving accuracy by removing noise and identifying the range of digits where vehicle information is stored, thereby clarifying the message format.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2026065795000001_ABST
    Figure 2026065795000001_ABST
Patent Text Reader

Abstract

This invention provides a CAN message analysis device capable of deciphering the format of a CAN message when the format is unknown. [Solution] The candidate data generation unit P3 is capable of performing an extraction process to extract data of a predetermined bit length from the data field of each CAN message having the same identification number ID, data that is stored in a predetermined range of digits of the entire digits of the data field; a conversion process to convert the extracted data into peak values ​​that constitute waveform data potentially indicating a change in any of the vehicle information; and a candidate data acquisition process to acquire the time series of the peak values ​​as candidate data. The candidate data generation unit P3 acquires multiple types of candidate data by performing a series of processes consisting of the extraction process, the conversion process and the candidate data acquisition process each time the digit range is shifted by one bit while keeping the predetermined bit length fixed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a CAN message analysis device that analyzes CAN messages output from an electrical component unit (hereinafter referred to as a "CAN node") connected to a CAN (Controller Area Network) bus line of a vehicle.

Background Art

[0002] Devices for diagnosing the operating states of a plurality of CAN nodes connected to a vehicle's CAN bus line have been proposed (see, for example, Patent Document 1 below). This device (hereinafter referred to as the "conventional device") is connected to the CAN bus line and acquires data (CAN messages) transmitted and received between each CAN node to diagnose the operating states of each CAN node.

Prior Art Documents

Patent Documents

[0003]

Patent Document 1

Summary of the Invention

[0004] A CAN node can convert one or more types of information (e.g., engine torque values ​​and engine speed acquired from sensors) into CAN messages and transmit them sequentially to other CAN nodes. A CAN message includes an identifier field where an identification number is stored and a data field where the information is stored. The data length of the data field is, for example, 8 bytes (64 bits). Various types of information (binary data) are stored in predetermined ranges of digits within the data field (e.g., bits 0 to 63) according to the type of information. For example, the engine torque value is stored in bits 8 to 15 of the data field. In addition, a predetermined identification number corresponding to the combination of information types stored in the data field is stored in the identifier field. That is, the identification number indicates the type of information (combination of multiple types of information) contained in the CAN message. The format of a CAN message (identification number, range of digits within the data field where various types of information are stored, etc.) differs for each vehicle manufacturer (for each vehicle model).

[0005] The conventional device described above does not have a function to decipher the format of a CAN message when the format is unknown. In other words, the conventional device does not have a function to identify the identification number of a CAN message that includes the engine torque value, or a function to identify the range of digits in the data field in which the engine torque value is stored.

[0006] One of the objectives of the invention is to provide a CAN message analysis device capable of deciphering the format of a CAN message when the format of the CAN message is unknown.

[0007] To achieve the above objective, the CAN message analysis device (1) of the present invention is: A device to be analyzed (V0) sequentially generates and outputs CAN messages, which are serial data including an identifier field where an identification number (ID) is stored and a data field where various information is stored, wherein one or more pieces of vehicle information (INFn), which are information about a vehicle (V0), are stored in a predetermined range of digits (x, x+L-1) of the data field that corresponds to the type of vehicle information, and an identification number corresponding to the combination of types of vehicle information stored in the data field is stored in the identifier field. The device to be analyzed is connected to the device to be analyzed, and multiple CAN messages are obtained from the device to be analyzed, the correspondence between the combination of vehicle information stored in the data field and the identification number is identified, and the range of digits in the data field where various types of vehicle information are stored is identified. The CAN message analysis device is A reference data generation unit (P1) sequentially acquires vehicle information from the aforementioned device that outputs various vehicle information, and records the time series of said vehicle information as reference data (Rn) that shows the changes in each of the various vehicle information, A candidate data generation unit (P2) is capable of performing the following: a parameter acquisition process for acquiring a parameter (prm) used to extract data from the data field of the CAN message; a CAN message acquisition process for sequentially acquiring and storing the CAN messages from the device under analysis during the process of acquiring various vehicle information; an extraction process for extracting data of a predetermined bit length determined based on the parameter from the data field of each CAN message having the same identification number, which is stored in a range of digits of the data field determined based on the parameter; a conversion process for converting the extracted data into peak values ​​that constitute waveform data potentially indicating a change in any of the vehicle information, based on the parameter; and a candidate data acquisition process for acquiring the time series of the peak values ​​as candidate data (CD[ID,DA]); and by performing a series of processes consisting of the extraction process, the conversion process and the candidate data acquisition process each time the range of digits is shifted by one bit while the predetermined bit length is fixed, a candidate data generation unit (P2) is capable of performing the following: a parameter acquisition process for acquiring a parameter (prm) used to extract data from the data field of the CAN message; a CAN message acquisition process for sequentially acquiring and storing the CAN messages from the device under analysis during the process of acquiring various vehicle information; an extraction process for extracting data of a predetermined bit length determined based on the parameter, which is stored in a range of digits of the data field determined based on the parameter; a conversion process for converting the extracted data into peak values ​​that constitute waveform data potentially indicating a change in any of the vehicle information, based on the parameter; and a candidate data acquisition process for acquiring the time series of the peak values ​​as candidate data (CD[ID,DA]). A comparison unit (P4) calculates the similarity between each candidate data and the reference data, identifies the correspondence between the combination of vehicle information stored in the data field and the identification number based on the combination of the reference data and the candidate data with the highest similarity, and identifies the range of digits in the data field in which various types of vehicle information are stored. It is equipped with.

[0008] The candidate data generation unit of the CAN message analysis device according to the present invention selects a range of digits (from the xth bit to the x+L-1th bit) from among all the digits of the data field of multiple CAN messages having the same identification number, extracts the data (binary data) from that range of digits, converts it to a peak value, and obtains the time series of the converted data as candidate data. The candidate data generation unit executes a process to acquire candidate data each time the digit range is shifted by one bit. This ensures that multiple candidate data are comprehensively acquired. The comparison unit then identifies the candidate data that is most similar to the reference data. This allows the correspondence between the combination of vehicle information stored in the data field and the identification number to be identified, and also allows the identification of the range of digits in the data field where various types of vehicle information are stored. In other words, according to the present invention, the format of a CAN message can be deciphered when the format is unknown.

[0009] In a CAN message analysis device according to one aspect of the present invention, The system includes a filter unit (P3) that performs filtering to remove noise contained in the reference data and the candidate data.

[0010] According to this, the accuracy of calculating the similarity between reference data and candidate data will improve.

[0011] In another aspect of the present invention, a CAN message analysis device, The reference data generation unit acquires the vehicle information by utilizing the self-diagnostic function (OBD2) of the various electrical units that constitute the vehicle.

[0012] According to this, the reference data generation unit can acquire various vehicle information relatively easily. [Brief explanation of the drawing]

[0013] [Figure 1] Figure 1 is a block diagram of a CAN message analysis device according to one embodiment of the present invention. [Figure 2] Figure 2 is a functional block diagram of the CAN message analysis device. [Figure 3] Figure 3 is a table showing the reference data. [Figure 4] Figure 4 is a table showing an example of extracting data from bits 0 to 7 out of all digits (bits 0 to 63) of a data field. [Figure 5] Figure 5 is a table showing an example of extracting data from the 1st to the 8th bit of a data field. [Figure 6] Figure 6 is a table classifying the acquired candidate data by identification number. [Figure 7] Figure 7 is a table showing the analysis results. [Modes for carrying out the invention]

[0014] (Summary) A CAN message analysis device 1 according to one embodiment of the present invention is connected to a vehicle V0, as shown in Figure 1. Here, the vehicle V0 is equipped with a plurality of electrical units A, B, ... as CAN nodes. The vehicle V0 is also equipped with a self-diagnostic function (compliant with On-Board Diagnostics 2). That is, the vehicle V0 can determine (diagnose) whether the various devices constituting its own vehicle are operating normally and transmit the result to an external device (for example, the CAN message analysis device 1) connected to a predetermined OBD connector. This self-diagnostic function (OBD2) includes a function to transmit various vehicle information (for example, RAW data showing engine torque value, engine speed, etc.) to an external device connected to the OBD connector.

[0015] When the format of the CAN messages transmitted and received between these CAN nodes is unknown, the CAN message analysis device 1 has a function to clarify the format. That is, the CAN message analysis device 1 identifies the correspondence between the combination of vehicle information stored in the data field of the CAN message acquired from the vehicle V0 (or a specific electrical component unit) and the identification number, and also identifies the digit range in which various vehicle information is stored among all the digits of the data field.

[0016] (Specific Configuration) The CAN message analysis device 1 includes an arithmetic unit 10, an input device 20, and an image display device 30.

[0017] The arithmetic unit 10 includes a microcomputer equipped with a CPU 10a, a ROM 10b (flash ROM), a RAM 10c, a timer 10d, etc. Further, the arithmetic unit 10 has a communication port 10e. The communication port 10e includes a CAN port 10e1 and an OBD port 10e2. The CAN port 10e1 is connected to the CAN connector (CAN bus line BS) of the vehicle V0 via a cable. Also, the OBD port 10e2 is connected to the OBD connector of the vehicle V0 via a cable.

[0018] The input device 20 includes a general-purpose keyboard, mouse, trackpad, etc. The user can operate these devices to input predetermined information to the arithmetic unit 10.

[0019] The image display device 30 includes a general-purpose liquid crystal display. The image display device 30 acquires a display command from the arithmetic unit 10 and displays an image according to the command.

[0020] (CAN Message Analysis Function) By executing a predetermined program PR1, the arithmetic unit 10 functions as a reference data generation unit P1, a candidate data generation unit P2, a filter unit P3, and a comparison unit P4 as shown in FIG. 2.

[0021] (Reference data generation unit) The reference data generation unit P1 sequentially acquires various vehicle information INFn (n=1,2,...) from vehicle V0 (OBD port 10e2). The reference data generation unit P2 acquires various vehicle information INFn, for example, every 0.01 seconds. The reference data generation unit P2 then records the time series of this vehicle information INFn (see Figure 3). The reference data generation unit P1 terminates the vehicle information INFn acquisition process when a predetermined time (a time specified in advance by the user) has elapsed since the start of vehicle information INFn acquisition. The time series of vehicle information INFn acquired in this way shows the time change (waveform) of the vehicle information INFn. Hereinafter, the time series of vehicle information INFn will be referred to as "reference data Rn". Furthermore, in order to improve the accuracy of the analysis, during the process in which the reference data generation unit P1 acquires vehicle information INFn, the user should actively operate various devices of the vehicle V0 (devices related to the desired vehicle information INFn) so that the vehicle information INFn changes relatively significantly.

[0022] (Candidate data generation unit) When program PR1 is started, the user inputs various parameters prm, which are used to generate candidate data CD[ID,DA] as described later, using the input device 20. Specifically, the parameters prm include the data length (bit length) L of the candidate data CD[ID,DA], the sign definition (signed / unsigned), LSB-first / MSB-first, etc. The candidate data generation unit P2 stores the input parameters prm. This process is referred to as the "parameter acquisition process".

[0023] The candidate data generation unit P2 sequentially acquires CAN messages from vehicle V0 (CAN port 10e1) during the period when the reference data generation unit P1 is acquiring vehicle information INFn, and records the CAN message in association with the time t at which it was acquired. Next, the candidate data generation unit P2 executes the following extraction and conversion processes each time it selects an identification number ID starting from "0".

[0024] <Extraction Process> The candidate data generation unit P2 selects all CAN messages that have the selected identification number ID. Next, the candidate data generation unit P2 obtains the data (64-bit binary data) consisting of all digits of the data field of each selected CAN message as data D0[ID,t]. Next, the candidate data generation unit P2 extracts data D1[ID,t] of data length L, which is determined based on the parameter prm, from each data D0[ID,t]. Specifically, the candidate data generation unit P2 selects the x+L-1 bit from the x-th bit (x=0,1,2,...63-L+1) as the digit range DA. Then, the candidate data generation unit P2 obtains (extracts) the binary data stored in the digit range DA of all digits of each data D0[ID,t] as data D1[ID,t]. This process is called the "extraction process".

[0025] <Conversion process> Next, the candidate data generation unit P2 converts each extracted data D1[ID,t] into a decimal number (peak value) according to the definition of the code and the definition of LSB-first / MSB-first, which are determined based on the parameter prm. Hereinafter, this process will be referred to as the "conversion process". The time series of data obtained by extracting and converting to peak values ​​in this way will be referred to as candidate data CD[ID,DA]. Next, the candidate data generation unit P2 selects bits x+1 to x+L as the digit range DA, and then executes the above extraction process and conversion process to obtain candidate data CD[ID,DA]. That is, the candidate data generation unit P2 extracts the next candidate data with the digit range DA shifted by 1 bit. Each candidate data CD[ID,DA] obtained in this way may represent the time change (waveform) of any of the vehicle information INFn.

[0026] For example, Figure 4 shows an example where, when the data length L is 8 bits, bits 0 to 7 of data D0[ID,t] are selected as the digit range DA (= "0 to 7"). Figure 5 shows an example where the digit range DA is shifted by 1 bit towards the MSB side from the state in Figure 4. That is, in Figure 5, bits 1 to 8 are selected as the digit range DA (= "1 to 8").

[0027] As described above, candidate data CD[ID,DA] is comprehensively generated. That is, as shown in Figure 6, candidate data CD[ID,DA] is generated for all identification numbers ID and digit range DA. Note that while the data length (total digits) of data D0[ID,t] is 64 bits, in the examples shown in Figures 4 to 6, the data length L of data D1[ID,t] is 8 bits. Therefore, in this example, 57 candidate data are generated for each identification number ID. The user can generate even more candidate data by appropriately changing the data length L (changing the parameter prm). Alternatively, the candidate data generation unit P2 may sequentially change the data length L from "1" to "64".

[0028] (Filter section) The filter unit P3 obtains all reference data Rn from the reference data generation unit P1. The filter unit P3 also obtains all candidate data CD[ID,DA] from the candidate data generation unit P2. The filter unit P3 removes high-frequency components (noise) from the waveforms represented by each reference data Rn and each candidate data CD[ID,DA]. This process is referred to as "filtering." Note that filtering may be performed on only one of the reference data Rn or candidate data CD[ID,DA].

[0029] (Comparison section) The comparison unit P4 obtains filtered reference data Rn and candidate data CD[ID,DA] from the filter unit P3. Then, each time the comparison unit P4 sequentially selects reference data Rn, it calculates the similarity (waveform similarity) between the selected reference data Rn and each candidate data CD[ID,DA]. For example, the comparison unit P4 can plot the waveforms based on the superdata (calculating the coordinates at each time point) and obtain the similarity between the two by performing a well-known pattern matching process. When plotting waveforms based on candidate data, it is advisable to use multiple data points adjacent in the time axis direction and interpolate the peak values ​​at intermediate points in time. The comparison unit P4 identifies the candidate data CD[ID,DA] with the highest similarity (the candidate data CD[ID,DA] that is most similar to the selected reference data Rn). The comparison unit P4 displays a list LST (see Figure 7) on the image display device 30, which shows the combination of the name of the vehicle information INFn related to the selected reference data Rn (for example, "engine torque value", "engine speed", etc.) and the identification number ID and digit range DA (bit x to bit x+L-1) related to the identified candidate data CD[ID,DA].

[0030] (effect) The candidate data generation unit P2 of the CAN message analysis device 1 selects a range of digits (from the xth bit to the x+L-1th bit) from the total digits of the data field of multiple CAN messages having the same identification number ID, extracts the data (binary data) from that range of digits, converts it to peak values, and obtains the time series of the converted data as candidate data. The candidate data generation unit P2 executes a process to obtain candidate data CD[ID,DA] each time the digit range is shifted by 1 bit. This ensures that multiple candidate data CD[ID,DA] are obtained comprehensively. Then, the comparison unit P4 identifies the candidate data CD[ID,DA] that is most similar to the reference data Rn. This allows for the identification of the correspondence between the combination of vehicle information stored in the data field and the identification number, and also allows for the identification of the range of digits in the total digits of the data field in which various types of vehicle information are stored. In other words, according to the present invention, the format of a CAN message can be deciphered when the format is unknown. [Explanation of Symbols]

[0031] 1...CAN message analysis device, 10...arithmetic unit, 20...image display device, 30...input device

Claims

1. An analysis target device that sequentially generates and outputs CAN messages which are serial data including an identifier field where an identification number is stored and a data field where various information is stored, wherein one or more vehicle information, which is information about the vehicle's equipment, is stored in a predetermined range of digits of the data field corresponding to the type of vehicle information, and an identification number corresponding to the combination of vehicle information types stored in the data field is stored in the identifier field, and the analysis target device is connected to the analysis target device, and a plurality of the CAN messages are acquired from the analysis target device, the correspondence between the combination of vehicle information stored in the data field and the identification number is identified, and the range of digits of the data field in which various vehicle information is stored is identified, A reference data generation unit that sequentially acquires vehicle information from the aforementioned device that outputs various vehicle information, and records the time series of said vehicle information as reference data that shows the changes in each of the various vehicle information, A candidate data generation unit is capable of performing the following: parameter acquisition processing to acquire parameters used to extract data from the data field of the CAN message; CAN message acquisition processing to sequentially acquire and store the CAN messages from the analysis target device in the process of acquiring various vehicle information; extraction processing to extract data of a predetermined bit length determined based on the parameters from the data field of each CAN message having the same identification number, which is stored in a range of digits of the data field determined based on the parameters; conversion processing to convert the extracted data into peak values ​​that constitute waveform data potentially indicating a change in any of the vehicle information, based on the parameters; and candidate data acquisition processing to acquire the time series of the peak values ​​as candidate data, and by performing a series of processes consisting of the extraction processing, the conversion processing and the candidate data acquisition processing each time the range of digits is shifted by one bit while keeping the predetermined bit length fixed, a candidate data generation unit is capable of acquiring multiple types of candidate data. A comparison unit calculates the similarity between each candidate data and the reference data, identifies the correspondence between the combination of vehicle information stored in the data field and the identification number based on the combination of the reference data with the highest similarity and the candidate data, and identifies the range of digits in the data field in which various types of vehicle information are stored. A CAN message analysis device equipped with [a specific feature / feature].

2. In the CAN message analysis device according to claim 1, A CAN message analysis device comprising a filter unit that performs filtering to remove noise contained in the reference data and the candidate data.

3. In the CAN message analysis device according to claim 1 or claim 2, The reference data generation unit is a CAN message analysis device that acquires vehicle information by utilizing the self-diagnostic functions of various electrical units that constitute the vehicle.

Citation Information

Patent Citations

  • JP244779A