CN112347047B - Vehicle data file generation method and device - Google Patents

Vehicle data file generation method and device Download PDF

Info

Publication number
CN112347047B
CN112347047B CN201910733856.2A CN201910733856A CN112347047B CN 112347047 B CN112347047 B CN 112347047B CN 201910733856 A CN201910733856 A CN 201910733856A CN 112347047 B CN112347047 B CN 112347047B
Authority
CN
China
Prior art keywords
signal
field
data
row
matrix
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910733856.2A
Other languages
Chinese (zh)
Other versions
CN112347047A (en
Inventor
郭和攀
李彤
谢亚果
潘佳炜
翟振威
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Automobile Group Co Ltd
Original Assignee
Guangzhou Automobile Group Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Automobile Group Co Ltd filed Critical Guangzhou Automobile Group Co Ltd
Priority to CN201910733856.2A priority Critical patent/CN112347047B/en
Publication of CN112347047A publication Critical patent/CN112347047A/en
Application granted granted Critical
Publication of CN112347047B publication Critical patent/CN112347047B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L12/40006Architecture of a communication node
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L2012/40208Bus networks characterized by the use of a particular bus standard
    • H04L2012/40215Controller Area Network CAN
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/40Bus networks
    • H04L2012/40267Bus for use in transportation systems
    • H04L2012/40273Bus for use in transportation systems the transportation system being a vehicle

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Small-Scale Networks (AREA)

Abstract

The invention discloses a vehicle data file generation method and a device, wherein the vehicle data file generation method comprises the following steps: acquiring a bus matrix and a signal demand table under a set path; reading and analyzing data cells in the bus matrix and the signal demand table one by one to generate an RX table; sequencing the RX table row by row, arranging signal names under the same message name together, grouping according to Motorola forward LSB matrix format and acquisition frequency, adopting a greedy algorithm to fill 64 bit data frames into each signal poll, and generating a TX table; setting type judgment rule adding signal mode schema information according to the signal value description attribute of the TX table, and generating a communication matrix by combining the RX table, the TX table and the schema information; and reading the communication matrix row by row through a DBC conversion program to generate a DBC file. The invention reduces the labor and time cost of engineers for manufacturing the communication matrix and the DBC, and provides great convenience for signal acquisition of big data of the automobile and subsequent data analysis.

Description

Vehicle data file generation method and device
Technical Field
The invention relates to the technical field of Internet of vehicles, in particular to a method and a device for generating a vehicle data file.
Background
With the development of the Internet of vehicles and the increasingly mature application of big data technology, big data is increasingly valued by each vehicle enterprise as strategic assets. The automobile mainly collects big data through the configuration T-BOX (Telematics BOX). The acquisition work needs to follow a specific protocol to manufacture a big data communication matrix, and the format of the big data acquisition of the ECU signals of each vehicle type is defined. The communication matrix of each model is different, if the communication matrix and the DBC file (DBC file is a file describing data communication between CAN network nodes) are manually manufactured for each model, the DBC file is an ASCII file, and the DBC extension CAN be used for defining the CAN network), the programming time is long, the cost of alternation is high, and the maintainability is weak.
Disclosure of Invention
The technical problem to be solved by the invention is to provide a method and a device for generating a vehicle data file, so that the manufacturing efficiency of the vehicle data file is effectively improved, and the labor and time cost are saved.
In order to solve the above technical problems, the present invention provides a vehicle data file generating method, including:
Step S1, a bus matrix and a signal demand table under a set path are obtained;
step S2, reading and analyzing data cells in the bus matrix and the signal demand table one by utilizing JAVAPOI to generate an RX table containing collected signal information transmitted by a CAN bus;
step S3, sorting the RX table row by row, arranging the signal names under the same message name together, grouping the signal names according to Motorola forward LSB matrix format and acquisition frequency, and adopting a greedy algorithm to fill 64 bit data frames into each signal poll to generate a TX table;
step S4, setting a type judgment rule to add the mode schema information of the signal according to the signal value description attribute of the TX table, and generating a communication matrix by combining the RX table, the TX table and the schema information;
and S5, reading the communication matrix row by row through a DBC conversion program to generate a DBC file.
In the step S2, analyzing the data cells in the bus matrix and the signal requirement table by using JAVAPOI specifically includes:
reading a message 16 ID of a signal demand table and two rows of data of a signal name to form a key value pair linked list;
and (3) each row of the progressive scanning bus matrix is subjected to key value pair in a matching linked list, if matching is met, the row is copied to an RX table, and the copying process is carried out by a JAVAPOI program to set format, font, row height and column width attributes.
And step S2 is to perform signal de-duplication according to a uniqueness principle and perform signal name matching according to the data cross-correlation property when analyzing the data cells.
The step S3 specifically includes:
Running TXFirstinput a code module, and converting the RX table to obtain a TXFirstinput table, wherein the TXFirstinput table comprises three columns of data including a time period MSGCYCLETIME, a signal name SIGNALNAME and a signal length SIGLENGTH of a data message;
Running TXSecondinput a code module, reading the TXFirstinput table, obtaining three columns of data including a time period MSGCYCLETIME of a data message, a signal name SIGNALNAME and a signal length SIGLENGTH, adopting a greedy algorithm, carrying out polling and filling of 64-bit data frames on each signal according to a Motorola forward LSB matrix format and acquisition frequency grouping until the data frames are filled or no signal meeting the requirement exists, and outputting a signal.
Setting signal start bit and signal length two-column value in signal. Txt, and generating the TX table by signal. Txt.
Wherein the pattern schema information types comprise int, float, double types,
The int type needs to satisfy one of the following conditions: the signal value description attribute does not contain a linear field; the signal value description attribute contains a linear field but does not contain a ' ″ field and does not contain a '% ' field; the signal value description attribute comprises a linear field and a 'field, wherein the' field and the 'n' field are separated by more than 5;
The float type needs to satisfy one of the following conditions: the signal value description attribute contains a linear field and contains a ' ″ field but does not contain a '% ' field; the signal value description attribute comprises a linear field and comprises a 'field and the' field is separated from the 'n' field by no more than 5; the signal value description attribute includes a linear field and includes a '& gt field and the' & gt field is separated from the 'pre' field by no more than 15;
the double type needs to satisfy: the signal value description attribute includes a linear field and includes a 'field and the' field is separated from the 'pre' field by more than 15.
After generating the DBC file in the step S5, determining whether the DBC file meets the functional requirement according to log information, if the log only includes warning information, it indicates that the DBC conversion is successful, if there is error information feedback, it needs to check the content of the communication matrix and format specification, and then convert the DBC file again until there is no error information feedback.
The invention also provides a vehicle data file generating device, which comprises:
The acquisition unit is used for acquiring the bus matrix and the signal demand table under the set path;
The first generation unit is used for reading and analyzing the data cells in the bus matrix and the signal demand table one by using JAVAPOI to generate an RX table containing the acquired signal information transmitted by the CAN bus;
The second generating unit is used for sequencing the RX table row by row, arranging the signal names under the same message name together, grouping the signal names according to Motorola forward LSB matrix format and acquisition frequency, and adopting a greedy algorithm to fill 64-bit data frames into each signal poll to generate a TX table;
a third generating unit, configured to set pattern schema information of a type judgment rule adding signal according to a signal value description attribute of the TX table, and generate a communication matrix by combining the RX table, the TX table and the schema information;
And the fourth generating unit is used for reading the communication matrix row by row through a DBC conversion program to generate a DBC file.
The first generating unit uses JAVAPOI to analyze the bus matrix and the data cells in the signal demand table, and specifically includes:
reading a message 16 ID of a signal demand table and two rows of data of a signal name to form a key value pair linked list;
and (3) each row of the progressive scanning bus matrix is subjected to key value pair in a matching linked list, if matching is met, the row is copied to an RX table, and the copying process is carried out by a JAVAPOI program to set format, font, row height and column width attributes.
When the first generation unit analyzes the data cells, signal deduplication is performed according to a uniqueness principle, and signal name matching is performed according to the data cross-correlation characteristics.
The second generating unit is specifically configured to:
Running TXFirstinput a code module, and converting the RX table to obtain a TXFirstinput table, wherein the TXFirstinput table comprises three columns of data including a time period MSGCYCLETIME, a signal name SIGNALNAME and a signal length SIGLENGTH of a data message;
Running TXSecondinput a code module, reading the TXFirstinput table, obtaining three columns of data including a time period MSGCYCLETIME of a data message, a signal name SIGNALNAME and a signal length SIGLENGTH, adopting a greedy algorithm, carrying out polling and filling of 64-bit data frames on each signal according to a Motorola forward LSB matrix format and acquisition frequency grouping until the data frames are filled or no signal meeting the requirement exists, and outputting a signal.
Setting signal start bit and signal length two-column value in signal. Txt, and generating the TX table by signal. Txt.
Wherein the pattern schema information types comprise int, float, double types,
The int type needs to satisfy one of the following conditions: the signal value description attribute does not contain a linear field; the signal value description attribute contains a linear field but does not contain a ' ″ field and does not contain a '% ' field; the signal value description attribute comprises a linear field and a 'field, wherein the' field and the 'n' field are separated by more than 5;
The float type needs to satisfy one of the following conditions: the signal value description attribute contains a linear field and contains a ' ″ field but does not contain a '% ' field; the signal value description attribute comprises a linear field and comprises a 'field and the' field is separated from the 'n' field by no more than 5; the signal value description attribute includes a linear field and includes a '& gt field and the' & gt field is separated from the 'pre' field by no more than 15;
the double type needs to satisfy: the signal value description attribute includes a linear field and includes a 'field and the' field is separated from the 'pre' field by more than 15.
Wherein the vehicle data file generation device further includes:
And the judging unit is used for judging whether the DBC file meets the functional requirement according to log information after the DBC file is generated, if the log only contains warning information, the DBC conversion is successful, if error information feedback exists, the DBC file is converted again after the communication matrix content and format specification are checked, and until no error information feedback exists.
The embodiment of the invention has the following beneficial effects: the method can standardize the manufacturing flow of the communication matrix, reduces the labor and time cost of engineers for manufacturing the communication matrix and DBC, reduces the probability of manual misoperation of the engineers, meets the timeliness that data analysis can be used, and provides great convenience for signal acquisition of big data of the automobile and subsequent analysis of the data.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, it being obvious that the drawings in the following description are only some embodiments of the invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flowchart of a method for generating a vehicle data file according to an embodiment of the present invention.
Fig. 2 is a schematic flow chart of a method for generating a vehicle data file according to an embodiment of the present invention.
Fig. 3 is a schematic diagram of signal length splicing according to an embodiment of the invention.
Fig. 4 is a schematic diagram of a schema manufacturing flow in accordance with an embodiment of the present invention.
Detailed Description
The following description of embodiments refers to the accompanying drawings, which illustrate specific embodiments in which the invention may be practiced.
Referring to fig. 1, a first embodiment of the present invention provides a method for generating a vehicle data file, including:
Step S1, a bus matrix and a signal demand table under a set path are obtained;
step S2, reading and analyzing data cells in the bus matrix and the signal demand table one by utilizing JAVAPOI to generate an RX table containing collected signal information transmitted by a CAN bus;
step S3, sorting the RX table row by row, arranging the signal names under the same message name together, grouping the signal names according to Motorola forward LSB matrix format and acquisition frequency, and adopting a greedy algorithm to fill 64 bit data frames into each signal poll to generate a TX table;
step S4, setting a type judgment rule to add the mode schema information of the signal according to the signal value description attribute of the TX table, and generating a communication matrix by combining the RX table, the TX table and the schema information;
and S5, reading the communication matrix row by row through a DBC conversion program to generate a DBC file.
Specifically, referring to fig. 2, step S1 of the present embodiment further includes performing a format error identification on the bus matrix and the signal requirement table, where the format error identification operation includes data total line number matching, column number identification, and column name matching, so as to correct the error data, and ensure that the subsequent operation is normal. The total number of rows in the format error identification is matched, the column number identification is automatically calculated by JAVAPOI statistical logic, and the bus matrix should contain the following when the column names are matched: the electronic control unit type, the message name, the message 16-ary ID, the message byte number, the message transmission type, the message circulation time, the message quick circulation time, the message invalid value, the signal name, the signal description, the signal start bit, the signal length, the signal minimum value, the signal maximum value, the signal default value, the signal invalid value, the timeout time, the precision, the signal offset, the signal unit, the signal transmission type, whether the event command signal is or not and the signal value description are carried out; the signal demand table should include the following: message 16 is ID, message cycle time, and signal name.
And then inputting the set paths of the bus matrix and the signal demand table, judging whether the bus matrix and the signal demand table exist in the set paths, and if yes, acquiring the bus matrix and the signal demand table under the set paths. It should be noted that the identifiable data file in this embodiment must be an Excel file, preferably in xls format, and is converted when the Excel format is xlsx format.
Step S2 generates an RX table, where the RX table includes the collected signal information transmitted by the CAN bus. Firstly, a createRXTable code module (namely a code module for generating an RX table) is operated, the contents in the bus matrix and the signal requirement table are read one by one, JAVAPOI is used for analyzing the data cells, JAVAPOI is used for analyzing the data cells, and the steps are as follows: firstly, reading a message 16 ID of a signal demand table and two columns of data of a signal name to form a key value pair linked list; then scanning each line of the bus matrix line by line to match key value pairs in the linked list, copying the line to an RX table if matching is satisfied, and setting the attributes such as format, font, line height, column width and the like by a JAVAPOI program in the copying process; wherein the JAVA program applied thereto comprises: mainRXTable.java, checkexcel.java, copyAndCreateRXexcel.java, readexcel.java, searchexcel.java.
Further, in step S2, when analyzing the data unit cell, signal deduplication is further performed according to the uniqueness principle, and signal name matching is performed according to the data cross-correlation characteristic. Signal deduplication according to the uniqueness principle means that each signal in the signal requirement table is present and only once; performing signal name matching according to the data cross-correlation property refers to performing positioning matching on each signal of the signal demand table in the bus matrix.
Step S3, sorting the obtained RX table row by row, and adding gray blank rows to separate different message names in the sorting process. Further, after checking the RX table for the correct content and format, the TXFirstinput code module is run to convert the RX table to TXFirstinput table, and TXFirstinput table contains three columns of data including time period MSGCYCLETIME, signal name SIGNALNAME and signal length SIGLENGTH of the data message. Then, a TXSecondinput code module is operated, TXFirstinput table is read, three columns of data including a time period MSGCYCLETIME of a data message, a signal name SIGNALNAME and a signal length SIGLENGTH are obtained, each signal is polled and filled with 64-bit data frames according to a Motorola forward LSB matrix format and acquisition frequency grouping by adopting a greedy algorithm until the data frames are filled or no signal meeting the requirements is output, and signal txt is output, so that empty positions are reduced, the 64-bit communication protocol requirement of each frame is met, and the service efficiency of flow is improved. The cyclic period time sequencing is adopted to improve the data readability, and frame interpolation sequencing is required to ensure that the byte length of the message name is fixed to 64 frames.
The signal. Txt is generated by TxSecondinput codes and comprises five columns of data, namely a data message Name Msg Name, a time period MSG CYCLE TIME (ms) of the data message, a signal Name SIGNAL NAME, a signal start bit Start Bit Position and a signal length Sig. Length, wherein the start bit and the length of the signal data in the signal. Txt can meet the communication protocol requirement of 64 bits per frame, as shown in fig. 3, the signal start bit and the signal length are set to be two columns of values, and the signal. Txt is generated into a TX table.
The vehicle body signal is sent to the background through the vehicle-mounted T-Box, the background runs an analysis program, and the vehicle body signal is judged to be effectively stored in the database according to the effective bit of the analyzed signal. The statistical indicators in steps S2 and S3 are all calculated based on the valid data.
There are only int, float, double types of pattern schema information types, and schema judgment logic is shown in fig. 4. The int type needs to satisfy one of the following conditions: the signal value description attribute does not contain a linear field; the signal value description attribute contains a linear field but does not contain a ' ″ field and does not contain a '% ' field; the signal value description attribute includes a linear field and includes a 'field and the' field is separated from the 'n:' field by more than 5. The float type needs to satisfy one of the following conditions: the signal value description attribute contains a linear field and contains a ' ″ field but does not contain a '% ' field; the signal value description attribute comprises a linear field and comprises a 'field and the' field is separated from the 'n' field by no more than 5; the signal value description attribute includes a linear field and includes a 'field and the' field is separated from the 'pre' field by no more than 15. The double type needs to satisfy: the signal value description attribute includes a linear field and includes a 'field and the' field is separated from the 'pre' field by more than 15. Each signal has corresponding scheme information, so that the vehicle type communication matrix is generated by combining the RX table, the TX table and the scheme information.
Step S5, reading the communication matrix line by line through a DBC conversion program to generate a DBC file, and judging whether the DBC meets the functional requirement or not according to log information. The DBC conversion program needs to specify RX table and TX table paths, the RX table and TX table contents can be automatically identified, and the DBC file generated after conversion is ended is used for analyzing the message uploaded later.
In the process of converting the communication matrix into the DBC file, the log is fed back, if the log only contains warning information, the DBC is successfully converted, if error information is fed back, the DBC file is converted again after the content and format specification of the communication matrix are checked, and until no error information is fed back.
Corresponding to the first embodiment of the present invention, a second embodiment of the present invention further provides a vehicle data file generating device, including:
The acquisition unit is used for acquiring the bus matrix and the signal demand table under the set path;
The first generation unit is used for reading and analyzing the data cells in the bus matrix and the signal demand table one by using JAVAPOI to generate an RX table containing the acquired signal information transmitted by the CAN bus;
The second generating unit is used for sequencing the RX table row by row, arranging the signal names under the same message name together, grouping the signal names according to Motorola forward LSB matrix format and acquisition frequency, and adopting a greedy algorithm to fill 64-bit data frames into each signal poll to generate a TX table;
a third generating unit, configured to set pattern schema information of a type judgment rule adding signal according to a signal value description attribute of the TX table, and generate a communication matrix by combining the RX table, the TX table and the schema information;
And the fourth generating unit is used for reading the communication matrix row by row through a DBC conversion program to generate a DBC file.
The first generating unit uses JAVAPOI to analyze the bus matrix and the data cells in the signal demand table, and specifically includes:
reading a message 16 ID of a signal demand table and two rows of data of a signal name to form a key value pair linked list;
and (3) each row of the progressive scanning bus matrix is subjected to key value pair in a matching linked list, if matching is met, the row is copied to an RX table, and the copying process is carried out by a JAVAPOI program to set format, font, row height and column width attributes.
When the first generation unit analyzes the data cells, signal deduplication is performed according to a uniqueness principle, and signal name matching is performed according to the data cross-correlation characteristics.
The second generating unit is specifically configured to:
Running TXFirstinput a code module, and converting the RX table to obtain a TXFirstinput table, wherein the TXFirstinput table comprises three columns of data including a time period MSGCYCLETIME, a signal name SIGNALNAME and a signal length SIGLENGTH of a data message;
Running TXSecondinput a code module, reading the TXFirstinput table, obtaining three columns of data including a time period MSGCYCLETIME of a data message, a signal name SIGNALNAME and a signal length SIGLENGTH, adopting a greedy algorithm, carrying out polling and filling of 64-bit data frames on each signal according to a Motorola forward LSB matrix format and acquisition frequency grouping until the data frames are filled or no signal meeting the requirement exists, and outputting a signal.
Setting signal start bit and signal length two-column value in signal. Txt, and generating the TX table by signal. Txt.
Wherein the pattern schema information types comprise int, float, double types,
The int type needs to satisfy one of the following conditions: the signal value description attribute does not contain a linear field; the signal value description attribute contains a linear field but does not contain a ' ″ field and does not contain a '% ' field; the signal value description attribute comprises a linear field and a 'field, wherein the' field and the 'n' field are separated by more than 5;
The float type needs to satisfy one of the following conditions: the signal value description attribute contains a linear field and contains a ' ″ field but does not contain a '% ' field; the signal value description attribute comprises a linear field and comprises a 'field and the' field is separated from the 'n' field by no more than 5; the signal value description attribute includes a linear field and includes a '& gt field and the' & gt field is separated from the 'pre' field by no more than 15;
the double type needs to satisfy: the signal value description attribute includes a linear field and includes a 'field and the' field is separated from the 'pre' field by more than 15.
Wherein the vehicle data file generation device further includes:
And the judging unit is used for judging whether the DBC file meets the functional requirement according to log information after the DBC file is generated, if the log only contains warning information, the DBC conversion is successful, if error information feedback exists, the DBC file is converted again after the communication matrix content and format specification are checked, and until no error information feedback exists.
According to the description of the embodiment, the method and the device have the beneficial effects that the communication matrix manufacturing flow can be standardized, the labor and time cost of engineers for manufacturing the communication matrix and the DBC can be reduced, meanwhile, the probability of manual misoperation of the engineers can be reduced, the timeliness that data analysis is available is met, and great convenience is provided for signal acquisition of automobile big data and subsequent data analysis.
In addition, compared with the existing data file generation scheme which does not involve the manufacture of a big data communication matrix, the invention designs a core algorithm for the manufacture of the big data communication matrix: a check bus matrix, a signal demand table and a big data matrix; the characteristics of 64-bit valid bits of a standard data frame are utilized to arrange signals required to be collected, so that the positions of the signals are not overlapped, the ID of the data frame is not repeated, and the maximum utilization rate of the valid bits of each frame is ensured. The manufacture of the big data communication matrix is the premise that the car can bus transmits a specific message, and has important significance for data acquisition and analysis of the car sensor.
The foregoing disclosure is illustrative of the present invention and is not to be construed as limiting the scope of the invention, which is defined by the appended claims.

Claims (8)

1. A vehicle data file generation method, characterized by comprising:
Step S1, a bus matrix and a signal demand table under a set path are obtained;
step S2, reading and analyzing data cells in the bus matrix and the signal demand table one by utilizing JAVAPOI to generate an RX table containing collected signal information transmitted by a CAN bus;
step S3, sorting the RX table row by row, arranging the signal names under the same message name together, grouping the signal names according to Motorola forward LSB matrix format and acquisition frequency, and adopting a greedy algorithm to fill 64 bit data frames into each signal poll to generate a TX table;
step S4, setting a type judgment rule to add the mode schema information of the signal according to the signal value description attribute of the TX table, and generating a communication matrix by combining the RX table, the TX table and the schema information;
step S5, reading the communication matrix row by row through a DBC conversion program to generate a DBC file;
in the step S2, analyzing the data cells in the bus matrix and the signal requirement table by using JAVAPOI specifically includes:
reading a message 16 ID of a signal demand table and two rows of data of a signal name to form a key value pair linked list;
Each row of the progressive scanning bus matrix is de-matched with a key value pair in a linked list, if matching is met, the row is copied to an RX table, and a JAVAPOI program sets format, font, row height and column width attributes in the copying process;
the step S3 specifically includes:
Running TXFirstinput a code module, and converting the RX table to obtain a TXFirstinput table, wherein the TXFirstinput table comprises three columns of data including a time period MSGCYCLETIME, a signal name SIGNALNAME and a signal length SIGLENGTH of a data message;
Running TXSecondinput a code module, reading the TXFirstinput table, obtaining three columns of data including a time period MSGCYCLETIME of a data message, a signal name SIGNALNAME and a signal length SIGLENGTH, adopting a greedy algorithm, carrying out polling and filling of 64-bit data frames on each signal according to a Motorola forward LSB matrix format and acquisition frequency grouping until the data frames are filled or no signal meeting the requirement exists, and outputting a signal.
Setting signal start bit and signal length two-column value in signal. Txt, and generating the TX table by signal. Txt.
2. The method according to claim 1, wherein the step S2 further performs signal de-duplication according to a uniqueness rule and performs signal name matching according to a data cross-correlation property when analyzing the data cells.
3. The vehicle data file generation method according to claim 1, wherein the pattern schema information types include int, float, double types,
The int type needs to satisfy one of the following conditions: the signal value description attribute does not contain a linear field; the signal value description attribute contains a linear field but does not contain a ' ″ field and does not contain a '% ' field; the signal value description attribute comprises a linear field and a 'field, wherein the' field and the 'n' field are separated by more than 5;
The float type needs to satisfy one of the following conditions: the signal value description attribute contains a linear field and contains a '% ' field but does not contain a '. -%; the signal value description attribute comprises a linear field and comprises a 'field and the' field is separated from the 'n' field by no more than 5; the signal value description attribute includes a linear field and includes a '& gt field and the' & gt field is separated from the 'pre' field by no more than 15;
the double type needs to satisfy: the signal value description attribute includes a linear field and includes a 'field and the' field is separated from the 'pre' field by more than 15.
4. The method according to claim 1, wherein after the DBC file is generated in the step S5, it is determined from log information whether the DBC file meets the functional requirement, if the log includes only warning information, it indicates that the DBC conversion is successful, if there is error information feedback, it is necessary to check the content of the communication matrix and format specification, and then convert the DBC file again until there is no error information feedback.
5. A vehicle data file generation device, characterized by comprising:
The acquisition unit is used for acquiring the bus matrix and the signal demand table under the set path;
The first generation unit is used for reading and analyzing the data cells in the bus matrix and the signal demand table one by using JAVAPOI to generate an RX table containing the acquired signal information transmitted by the CAN bus;
The second generating unit is used for sequencing the RX table row by row, arranging the signal names under the same message name together, grouping the signal names according to Motorola forward LSB matrix format and acquisition frequency, and adopting a greedy algorithm to fill 64-bit data frames into each signal poll to generate a TX table;
a third generating unit, configured to set pattern schema information of a type judgment rule adding signal according to a signal value description attribute of the TX table, and generate a communication matrix by combining the RX table, the TX table and the schema information;
a fourth generating unit, configured to read the communication matrix row by row through a DBC conversion program, and generate a DBC file;
the first generating unit uses JAVAPOI to parse the data cells in the bus matrix and the signal requirement table, and specifically includes:
reading a message 16 ID of a signal demand table and two rows of data of a signal name to form a key value pair linked list;
Each row of the progressive scanning bus matrix is de-matched with a key value pair in a linked list, if matching is met, the row is copied to an RX table, and a JAVAPOI program sets format, font, row height and column width attributes in the copying process;
The second generating unit is specifically configured to:
Running TXFirstinput a code module, and converting the RX table to obtain a TXFirstinput table, wherein the TXFirstinput table comprises three columns of data including a time period MSGCYCLETIME, a signal name SIGNALNAME and a signal length SIGLENGTH of a data message;
Running TXSecondinput a code module, reading the TXFirstinput table, obtaining three columns of data including a time period MSGCYCLETIME of a data message, a signal name SIGNALNAME and a signal length SIGLENGTH, adopting a greedy algorithm, carrying out polling and filling of 64-bit data frames on each signal according to a Motorola forward LSB matrix format and acquisition frequency grouping until the data frames are filled or no signal meeting the requirement exists, and outputting a signal.
Setting signal start bit and signal length two-column value in signal. Txt, and generating the TX table by signal. Txt.
6. The vehicle data file generation device according to claim 5, wherein when the first generation unit parses the data cells, signal deduplication is further performed according to a uniqueness rule, and signal name matching is performed according to a data cross-correlation property.
7. The vehicle data file generation device of claim 5, wherein the pattern schema information types include int, float, double types,
The int type needs to satisfy one of the following conditions: the signal value description attribute does not contain a linear field; the signal value description attribute contains a linear field but does not contain a ' ″ field and does not contain a '% ' field; the signal value description attribute comprises a linear field and a 'field, wherein the' field and the 'n' field are separated by more than 5;
The float type needs to satisfy one of the following conditions: the signal value description attribute contains a linear field and contains a '% ' field but does not contain a '. -%; the signal value description attribute comprises a linear field and comprises a 'field and the' field is separated from the 'n' field by no more than 5; the signal value description attribute includes a linear field and includes a '& gt field and the' & gt field is separated from the 'pre' field by no more than 15;
the double type needs to satisfy: the signal value description attribute includes a linear field and includes a 'field and the' field is separated from the 'pre' field by more than 15.
8. The vehicle data file generation device according to claim 5, characterized by further comprising:
And the judging unit is used for judging whether the DBC file meets the functional requirement according to log information after the DBC file is generated, if the log only contains warning information, the DBC conversion is successful, if error information feedback exists, the DBC file is converted again after the communication matrix content and format specification are checked, and until no error information feedback exists.
CN201910733856.2A 2019-08-09 2019-08-09 Vehicle data file generation method and device Active CN112347047B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910733856.2A CN112347047B (en) 2019-08-09 2019-08-09 Vehicle data file generation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910733856.2A CN112347047B (en) 2019-08-09 2019-08-09 Vehicle data file generation method and device

Publications (2)

Publication Number Publication Date
CN112347047A CN112347047A (en) 2021-02-09
CN112347047B true CN112347047B (en) 2024-06-11

Family

ID=74367597

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910733856.2A Active CN112347047B (en) 2019-08-09 2019-08-09 Vehicle data file generation method and device

Country Status (1)

Country Link
CN (1) CN112347047B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112947376A (en) * 2021-02-19 2021-06-11 中国第一汽车股份有限公司 Test vehicle use supervision method and supervision system
CN113518015B (en) * 2021-04-08 2023-03-14 重庆长安汽车股份有限公司 Automatic realization method based on vehicle machine CAN network signal test
CN113542086B (en) * 2021-06-28 2023-03-10 合肥国轩高科动力能源有限公司 CAN signal initial position calculation method and DBC file generation method
CN116847004B (en) * 2023-08-30 2023-11-17 江铃汽车股份有限公司 Analysis method, system and computer equipment for automobile CAN signals

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101019107A (en) * 2004-08-27 2007-08-15 罗伯特·博世有限公司 Communications module comprising a communications interface element, and communications interface element
CN102088787A (en) * 2010-12-10 2011-06-08 中兴通讯股份有限公司 Method and system for demodulating uplink data channel in wideband code division multiple access system
CN102307118A (en) * 2011-08-10 2012-01-04 福建星网锐捷网络有限公司 Back plate test method, apparatus thereof and system thereof
CN102611741A (en) * 2012-02-17 2012-07-25 浙江大学 Method for extracting communication matrix from AUTOSAR (Automotive Open System Architecture) system allocation model
CN102892183A (en) * 2011-07-22 2013-01-23 富士通株式会社 Wireless communication system for determining mobile devices positions and related method
CN103425692A (en) * 2012-05-22 2013-12-04 阿里巴巴集团控股有限公司 Data exporting method and data exporting device
CN103823804A (en) * 2012-11-19 2014-05-28 广州汽车集团股份有限公司 Method and device for converting CAN (controller area network) files into Excel files
CN106165481A (en) * 2014-04-02 2016-11-23 Lg电子株式会社 The method of receiving and transmitting signal and equipment thereof in a wireless communication system
CN107247697A (en) * 2017-07-05 2017-10-13 上海蔚赫信息科技有限公司 A kind of method that Excel file is converted to automotive networking DBC files
CN108829647A (en) * 2018-05-04 2018-11-16 天津大学 A kind of data transfer device and device
CN109753043A (en) * 2017-11-06 2019-05-14 联合汽车电子有限公司 The test device and method of CAN bus communication matrix
KR101989340B1 (en) * 2018-11-01 2019-06-17 비티에스테크놀로지스(주) Data link layer test method and system of CAN communication

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10763695B2 (en) * 2016-07-26 2020-09-01 Schweitzer Engineering Laboratories, Inc. Microgrid power flow monitoring and control
DE102016222740A1 (en) * 2016-11-18 2018-05-24 Continental Automotive Gmbh Method for a communication network and electronic control unit

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101019107A (en) * 2004-08-27 2007-08-15 罗伯特·博世有限公司 Communications module comprising a communications interface element, and communications interface element
CN102088787A (en) * 2010-12-10 2011-06-08 中兴通讯股份有限公司 Method and system for demodulating uplink data channel in wideband code division multiple access system
CN102892183A (en) * 2011-07-22 2013-01-23 富士通株式会社 Wireless communication system for determining mobile devices positions and related method
CN102307118A (en) * 2011-08-10 2012-01-04 福建星网锐捷网络有限公司 Back plate test method, apparatus thereof and system thereof
CN102611741A (en) * 2012-02-17 2012-07-25 浙江大学 Method for extracting communication matrix from AUTOSAR (Automotive Open System Architecture) system allocation model
CN103425692A (en) * 2012-05-22 2013-12-04 阿里巴巴集团控股有限公司 Data exporting method and data exporting device
CN103823804A (en) * 2012-11-19 2014-05-28 广州汽车集团股份有限公司 Method and device for converting CAN (controller area network) files into Excel files
CN106165481A (en) * 2014-04-02 2016-11-23 Lg电子株式会社 The method of receiving and transmitting signal and equipment thereof in a wireless communication system
CN107247697A (en) * 2017-07-05 2017-10-13 上海蔚赫信息科技有限公司 A kind of method that Excel file is converted to automotive networking DBC files
CN109753043A (en) * 2017-11-06 2019-05-14 联合汽车电子有限公司 The test device and method of CAN bus communication matrix
CN108829647A (en) * 2018-05-04 2018-11-16 天津大学 A kind of data transfer device and device
KR101989340B1 (en) * 2018-11-01 2019-06-17 비티에스테크놀로지스(주) Data link layer test method and system of CAN communication

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
CAN网络辅助平台的开发;顾祖飞等;《湖北汽车工业学院学报》;第32卷(第3期);第50-54页 *
Design and Implementation of An ECC-Based Digital Baseband Controller for RFID Tag Chip;Dongsheng Liu等;《 IEEE Transactions on Industrial Electronics》;第62卷(第7期);第4365-4373页 *
基于通信矩阵转化成DBC数据库的研究;曾桂芬;《汽车电器》(第9期);第57-59页 *

Also Published As

Publication number Publication date
CN112347047A (en) 2021-02-09

Similar Documents

Publication Publication Date Title
CN112347047B (en) Vehicle data file generation method and device
CN108600192B (en) Regular expression based DBC file analysis and message analysis method
CN112485019B (en) Vehicle fault diagnosis method and device, vehicle and storage medium
CN112287009A (en) Interface calling and interface data warehousing method, device, equipment and storage medium
CN204832946U (en) Long -range system that writes with a brush dipped in chinese ink of VIN sign indicating number information
CN212694288U (en) TBOX detection device
CN111966084A (en) TBOX detection device and method
CN102215126A (en) Method and device for generating performance report
CN112187936A (en) Vehicle data processing method, device, equipment, storage medium and vehicle
CN111143429A (en) Vehicle road test data evaluation method, device and system
CN115190190B (en) Pre-analysis method and pre-analysis system for electric power Internet of things protocol
CN115473924A (en) Carbon emission metering system based on thing networking block chain
CN111756688B (en) Method and system for realizing meter protocol and application decoupling
CN113438226B (en) Message generating and analyzing method, device and system based on hybrid transmission protocol
CN113067794B (en) Method and device for processing high-speed train data general protocol
CN111638874B (en) Matlab software-based automobile controller coding information writing and reading method
CN110262459B (en) Fault information output control method and system
CN112068982B (en) Automobile code setting method and device, computer equipment and storage medium
CN114567682B (en) Equipment state monitoring method and signal maintenance support system
CN112702303A (en) Train real-time data analysis method, device, equipment and storage medium
CN105678637A (en) Data parsing system and application method thereof for vehicle charging posts
CN118261410A (en) Intelligent flexible whole vehicle data error-proofing and refreshing system
CN112347751B (en) Method and device for generating COSIC workload evaluation document
CN114282519B (en) CAN data analysis method and device
CN113093688B (en) Input and output testing method and system for new energy vehicle control unit

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant