Debug data output method and related device
By using the CANFD bus and buffers in the on-board combined navigation device to process debug data, and generating and sending debug packets according to the preset protocol, the problem of complex and inefficient debug data acquisition process is solved, and simple and efficient debug data output is achieved.
Patent Information
- Application Number
- CN202211259063.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-14
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2042-10-14
AI Technical Summary
When obtaining debug data, the construction of the circuit is complicated, the way to obtain debug data is cumbersome, and the acquisition efficiency is low.
The obtained debug data is added to the buffer through the CANFD bus, and it is determined whether the debug data in the buffer meets the preset data transmission conditions. If satisfied, the debug data in the buffer is packaged according to the preset data transmission protocol, a debug message is generated and sent to the receiving device through the CANFD bus.
The debug data output process is simplified, the line complexity is reduced, and the efficiency of obtaining debug data is improved. The debug data can be obtained during on-site joint debugging without adding multiple cables.
Smart Images

Figure CN115665072B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of vehicle-mounted integrated navigation, and in particular to a debugging data output method and a related device. Background Art
[0002] At present, in some projects, the combined navigation equipment needs to add RS232, RS422, vehicle Ethernet and other interfaces to cooperate with the output of debugging data of the combined navigation products. Therefore, if the combined navigation equipment in some projects does not have RS232, RS422, vehicle Ethernet and other interfaces, the staff often need to add multiple cables to obtain debugging data during on-site joint debugging. The lines built by this method are complex, the method of obtaining debugging data is cumbersome, and the acquisition efficiency is low. Summary of the invention
[0003] In view of this, the object of the present invention is to provide a debugging data output method and related devices to solve the problems of complex circuit construction when obtaining debugging data, cumbersome way of obtaining debugging data, and low acquisition efficiency.
[0004] In order to achieve the above purpose, the technical solution adopted by the embodiment of the present invention is as follows:
[0005] In a first aspect, the present invention provides a debugging data output method, which is applied to a vehicle-mounted integrated navigation device, wherein the vehicle-mounted integrated navigation device, a receiving device and a collection device are electrically connected via a CANFD bus, and the method comprises:
[0006] Add the acquired debugging data to the buffer;
[0007] Determining whether the debugging data in the buffer satisfies a preset data sending condition;
[0008] If the data transmission condition is met, the debugging data in the buffer is packaged according to a preset data transmission protocol, a debugging message is generated and sent to the receiving device through the CANFD bus, so that the acquisition device can collect the debugging message.
[0009] In an optional implementation manner, the determining whether the debugging data in the buffer satisfies a preset data sending condition includes:
[0010] If the data amount of the debugging data in the buffer reaches a preset data amount, it is determined that the debugging data in the buffer meets a preset data sending condition.
[0011] In an optional implementation, the preset data amount is 62 bytes.
[0012] In an optional implementation manner, the determining whether the debugging data in the buffer satisfies a preset data sending condition includes:
[0013] If the time interval between the current time and the time when the debugging message was last sent reaches a preset time length, it is determined that the debugging data in the buffer area meets the preset data sending condition.
[0014] In an optional implementation, the preset duration is 50 ms.
[0015] In an optional implementation, the debug message includes a length field, a sequence number field, and a data field, the length field is used to store the length of the debug data, the sequence number field is used to store the sending sequence number, and the data field is used to store the debug data.
[0016] In an optional implementation manner, after the step of packaging the debugging data in the buffer according to a preset data transmission protocol to generate a debugging message, the method further includes:
[0017] A debugging message identifier is added to the debugging message.
[0018] In a second aspect, the present invention provides a debugging data output method, which is applied to an electronic device, wherein the electronic device is communicatively connected to a collection device, and the collection device, a vehicle-mounted integrated navigation device, and a receiving device are electrically connected via a CANFD bus; the method comprises:
[0019] Acquire the debug message collected by the acquisition device; the vehicle-mounted combined navigation device adds the acquired debug data to a buffer, determines whether the debug data in the buffer satisfies a preset data sending condition, and packages the debug data in the buffer according to a preset data sending protocol when the data sending condition is met, and the acquisition device collects the debug data when the vehicle-mounted combined navigation device sends the debug message to the receiving device through the CANFD bus; extracts the debug data in the debug message and stores the debug data.
[0020] In an optional implementation manner, the debug message corresponds to a debug message identifier, and the step of acquiring the debug message collected by the collection device includes:
[0021] According to the debug message identifier, the debug message is obtained from the acquisition device.
[0022] In an optional implementation manner, the debug message includes a length field, a sequence number field, and a data field, and extracting debug data from the debug message and storing the debug data includes:
[0023] Arranging the acquired debugging messages according to the sequence number field;
[0024] Extracting the debugging data stored in the data field according to the length field for each debugging message in the arrangement order;
[0025] The extracted debugging data is stored in a preset debugging file.
[0026] In a third aspect, the present invention provides a debugging data output device, which is applied to a vehicle-mounted integrated navigation device, wherein the vehicle-mounted integrated navigation device, a receiving device and a collection device are electrically connected via a CANFD bus, and the device comprises:
[0027] Add a module to add the acquired debugging data to the buffer;
[0028] A judging module, used for judging whether the debugging data in the buffer area meets a preset data sending condition;
[0029] The sending module is used to pack the debugging data in the buffer according to a preset data sending protocol when the data sending conditions are met, generate a debugging message and send it to the receiving device through the CANFD bus, so that the acquisition device can collect the debugging message.
[0030] In a fourth aspect, the present invention provides a debugging data output device, which is applied to an electronic device, wherein the electronic device is communicatively connected with a collection device, and the collection device, a vehicle-mounted integrated navigation device, and a receiving device are electrically connected via a CANFD bus; the device comprises:
[0031] An acquisition module is used to acquire the debugging message collected by the acquisition device; the vehicle-mounted integrated navigation device adds the acquired debugging data to a buffer, determines whether the debugging data in the buffer satisfies a preset data sending condition, and packages the debugging data in the buffer according to a preset data sending protocol when the data sending condition is met, and the acquisition device collects the debugging message when the vehicle-mounted integrated navigation device sends the debugging message to the receiving device through the CANFD bus;
[0032] The extraction module is used to extract the debugging data in the debugging message and store the debugging data.
[0033] In a fifth aspect, the present invention provides a vehicle-mounted integrated navigation device, comprising a processor and a memory, wherein the memory stores a computer program that can be executed by the processor, and the processor can execute the computer program to implement any of the methods described in the aforementioned embodiments.
[0034] In a sixth aspect, the present invention provides an electronic device, comprising a processor and a memory, wherein the memory stores a computer program executable by the processor, and the processor can execute the computer program to implement any of the methods described in the foregoing embodiments.
[0035] In a seventh aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method described in any one of the aforementioned embodiments.
[0036] The debugging data output method and related device provided by the embodiment of the present invention, the vehicle-mounted combined navigation device adds the acquired debugging data to the buffer, and determines whether the debugging data in the buffer satisfies the preset data transmission condition. If so, the debugging data in the buffer is packaged according to the preset data transmission protocol, thereby generating a debugging message, and the debugging message is sent to the receiving device through the CANFD bus, so that the acquisition device can collect the debugging message. When the debugging data in the buffer of the vehicle-mounted combined navigation device meets the preset data transmission condition, the method can package the debugging data through the preset data transmission protocol to generate a debugging message. Since the debugging message can be sent through the CANFD bus and directly collected by the acquisition device, when there is no RS232, RS422, vehicle-mounted Ethernet and other interfaces in the combined navigation device, there is no need to add multiple cables, and the debugging data can also be obtained during on-site joint debugging. The method is relatively simple and has a high acquisition efficiency.
[0037] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.
[0039] Figure 1 A block diagram of a vehicle-mounted integrated navigation system is shown;
[0040] Figure 2 A schematic flow chart of a method for outputting debugging data applied to a vehicle-mounted integrated navigation device provided by an embodiment of the present invention is shown;
[0041] Figure 3 A schematic diagram of the message format of a debug message is shown;
[0042] Figure 4A schematic flow chart of a method for outputting debugging data applied to an electronic device provided by an embodiment of the present invention is shown;
[0043] Figure 5 Another schematic flow chart of a method for outputting debugging data applied to an electronic device provided by an embodiment of the present invention is shown;
[0044] Figure 6 A schematic diagram of an extraction page of bus data extraction software is shown;
[0045] Figure 7 A functional module diagram of a debugging data output device applied to a vehicle-mounted integrated navigation device provided by an embodiment of the present invention is shown;
[0046] Figure 8 A functional module diagram of a debugging data output device applied to an electronic device provided by an embodiment of the present invention is shown;
[0047] Fig. 9 It shows a block diagram of a vehicle-mounted integrated navigation device 100 and an electronic device 130 provided in an embodiment of the present invention.
[0048] Icons: 10-vehicle integrated navigation system; 100-vehicle integrated navigation device; 110-receiving device; 120-collecting device; 130-electronic device; 140-CANFD bus; 20-address selection box; 21-extraction selection box; 200-add module; 210-judgment module; 220-sending module; 300-acquisition module; 310-extraction module; 400-memory; 410-processor; 420-communication module. DETAILED DESCRIPTION
[0049] The following will be combined with the accompanying drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.
[0050] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making creative work are within the scope of protection of the present invention.
[0051] It should be noted that relational terms such as "first" and "second" are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0052] Figure 1 is a block diagram of the vehicle-mounted integrated navigation system 10, see Figure 1 The vehicle-mounted combined navigation system 10 includes a vehicle-mounted combined navigation device 100, a receiving device 110, a collection device 120 and an electronic device 130, wherein the vehicle-mounted combined navigation device 100, the receiving device 110 and the collection device 120 can be electrically connected through a CANFD bus 140, and the collection device 120 is communicatively connected with the electronic device 130.
[0053] Optionally, the vehicle-mounted integrated navigation device 100 is used to generate a data message according to the generated or acquired data, and send the generated data message to the receiving device 110 via the CANFD bus.
[0054] Optionally, the receiving device 110 is used to receive a data message sent by the vehicle-mounted integrated navigation device 100 via the CANFD bus.
[0055] Optionally, the acquisition device 120 is used to acquire and save data messages sent by the vehicle-mounted integrated navigation device 100 to the receiving device 110 via the CANFD bus.
[0056] Optionally, the electronic device 130 is used to respond to the user's extraction instruction, obtain the corresponding data message in the acquisition device 120 and extract the corresponding data, and respond to the user's operation instruction to perform corresponding processing according to the data in the obtained data message.
[0057] In a possible implementation, the electronic device 130 may be provided with bus data extraction software or operation software, etc., so that the user can issue extraction instructions or operation instructions through the bus data extraction software.
[0058] Next, the above Figure 1The vehicle-mounted integrated navigation device 100 is the execution subject, and the debugging data output method provided by the embodiment of the present application is exemplarily introduced in combination with the flowchart. Specifically, Figure 2 A flowchart of a debugging data output method provided in an embodiment of the present application is shown in FIG. Figure 2 , the method comprising:
[0059] Step S20, adding the acquired debugging data to the buffer;
[0060] Optionally, the debugging data is data generated when the vehicle-mounted integrated navigation device is running, and the debugging data can be used to observe the running state of the vehicle-mounted integrated navigation device, for example, to perform fault analysis.
[0061] Optionally, the buffer is a storage interval in the vehicle-mounted integrated navigation device, used to store the generated debugging data.
[0062] Step S21, determining whether the debugging data in the buffer satisfies a preset data sending condition;
[0063] Optionally, the data sending condition is used to determine whether a debugging message should be generated and sent according to the debugging data in the buffer.
[0064] Optionally, the data sending conditions may be pre-set according to actual operating conditions and stored in the vehicle-mounted integrated navigation device.
[0065] In one possible implementation, the vehicle-mounted combined navigation device can determine in real time whether the debugging data in the buffer meets the preset data sending conditions; in another possible implementation, the vehicle-mounted combined navigation device can determine whether the debugging data in the buffer meets the preset data sending conditions once every period of time.
[0066] Step S22: If the data transmission condition is met, the debugging data in the buffer is packaged according to the preset data transmission protocol, a debugging message is generated and sent to the receiving device through the CANFD bus, so that the collection device can collect the debugging message.
[0067] Optionally, the data protocol may be pre-set according to actual operating conditions and stored in the vehicle-mounted integrated navigation device.
[0068] Optionally, the collection device may save the collected debugging messages in a blf file format in the collection device.
[0069] In this embodiment, the vehicle-mounted combined navigation device can add the acquired debugging data to the buffer and determine whether the debugging data in the buffer meets the preset data sending conditions. If the debugging data in the buffer meets the preset data sending conditions, the debugging data in the buffer can be packaged according to the preset data protocol to generate a debugging message, and the debugging message is sent to the receiving device through the CANFD bus. At this time, the collection device will collect the debugging message.
[0070] The debugging data output method and related device provided by the embodiment of the present invention, the vehicle-mounted combined navigation device adds the acquired debugging data to the buffer, and determines whether the debugging data in the buffer satisfies the preset data transmission condition. If so, the debugging data in the buffer is packaged according to the preset data transmission protocol, thereby generating a debugging message, and the debugging message is sent to the receiving device through the CANFD bus, so that the acquisition device can collect the debugging message. When the debugging data in the buffer of the vehicle-mounted combined navigation device meets the preset data transmission condition, the method can package the debugging data through the preset data transmission protocol to generate a debugging message. Since the debugging message can be sent through the CANFD bus and directly collected by the acquisition device, when there is no RS232, RS422, vehicle-mounted Ethernet and other interfaces in the combined navigation device, there is no need to add multiple cables, and the debugging data can also be obtained during on-site joint debugging. The method is relatively simple and has a high acquisition efficiency.
[0071] Optionally, in order to facilitate the vehicle-mounted integrated navigation device to package the debugging data, reduce the cache burden of the buffer, and improve the sending efficiency of the debugging message and increase the effective load ratio, a preset data amount can be set to determine whether the debugging data in the buffer meets the preset data sending conditions. Specifically, the above step S21 can also be implemented by the following steps:
[0072] If the data volume of the debugging data in the buffer reaches the preset data volume, it is determined that the debugging data in the buffer meets the preset data sending condition.
[0073] It can be understood that the data sending condition may be that the amount of debugging data in the buffer reaches a preset amount of data.
[0074] Optionally, the preset data amount may be set according to actual conditions. In one possible implementation, the preset data amount is 62 bytes.
[0075] In this embodiment, the vehicle-mounted combined navigation device can monitor in real time whether the data volume of the debugging data in the buffer has reached the preset data volume, or determine whether the data volume of the debugging data in the buffer has reached the preset data volume at intervals. If reached, it is determined that the debugging data in the buffer has met the preset data sending conditions, and therefore the debugging data in the buffer can be packaged according to the preset data sending protocol, thereby generating a debugging message and sending it.
[0076] Optionally, a preset time length may be set to determine whether the debugging data in the buffer satisfies a preset data sending condition. Specifically, the above step S21 may also be implemented by the following steps:
[0077] If the time interval between the current time and the time when the debugging message was last sent reaches a preset time length, it is determined that the debugging data in the buffer meets the preset data sending condition.
[0078] It can be understood that the data sending condition may be that the time interval between the current time and the time when the debugging message was last sent reaches a preset time length.
[0079] Optionally, the preset duration can be set according to actual operation requirements. In one possible implementation, the preset duration is 50 ms.
[0080] In this embodiment, the vehicle-mounted combined navigation device can determine in real time whether the time interval between the current moment and the last time the debug message was sent reaches a preset time length, or determine at intervals whether the time interval between the current moment and the last time the debug message was sent reaches a preset time length. If so, it is determined that the debug data in the buffer has met the preset data sending conditions, and therefore the debug data in the buffer can be packaged according to the preset data sending protocol, thereby generating a debug message and sending it.
[0081] Optionally, in order to solve the problem of message timing confusion caused by multi-channel mixed transmission and improve the message transmission efficiency and parsing efficiency, the debugging message generated according to the preset data transmission protocol can set the length field and the sequence number field before the data field.
[0082] Specifically, Figure 3 For a diagram of the debug message format, see Figure 3 The debug message includes a length field (len field), a sequence number field (seq field) and a data field (data field), wherein the length field is used to store the length of the debug data, the sequence number field is used to store the send sequence number, and the data field is used to store the debug data. Optionally, the debug message is a maximum of 64 bytes, and the debug message includes an arbitration frame.
[0083] Optionally, the field length of the debugging data may be 62 bytes. If the length of the data field is less than 62 bytes, it may be supplemented after the field of the debugging data, for example, by supplementing 0s in subsequent blank fields.
[0084] Optionally, the length field stores the valid data length, that is, if the length of the data field is less than 62 bytes, for example 60 bytes, the data length stored in the length field is 60 bytes, which is used to indicate that data[0]-data
[59] in the data field are all debugging data.
[0085] Optionally, the value range of the sequence number field can be 0 to 255.
[0086] Optionally, in order to facilitate subsequent electronic devices to distinguish various messages, the vehicle-mounted integrated navigation device may encapsulate a message identifier for representing the data type of data stored in the message after generating the message.
[0087] On this basis, the vehicle-mounted integrated navigation device can pack the debugging data in the buffer according to the preset data transmission protocol, and after generating a debugging message, add a debugging message identifier to the debugging message to indicate that the debugging data is stored in the message.
[0088] Optionally, after the acquisition device acquires the debugging information, the debugging information can also be saved, viewed, analyzed, etc. by the electronic device. Figure 1 The electronic device 130 in the embodiment is the execution subject, and the debugging data output method provided in the embodiment of the present application is exemplarily introduced in combination with the flowchart. Specifically, Figure 4 A flowchart of a debugging data output method provided in an embodiment of the present application is shown in FIG. Figure 4 , the method comprising:
[0089] Step S30, obtaining the debugging message collected by the collection device;
[0090] The debugging message vehicle integrated navigation device adds the acquired debugging data to the buffer, determines whether the debugging data in the buffer satisfies the preset data transmission conditions, and packages the debugging data in the buffer according to the preset data transmission protocol when the data transmission conditions are met, and is collected by the collection device when the vehicle integrated navigation device sends the debugging message to the receiving device through the CANFD bus;
[0091] Step S31, extracting the debugging data in the debugging message and storing the debugging data.
[0092] In this embodiment, the electronic device may obtain a debugging message from a collection device, extract debugging data from the debugging message, and store the debugging data in the electronic device.
[0093] Optionally, after storing the debugging data, the electronic device can respond to the user's instructions and perform corresponding operations according to the debugging data. For example, the electronic device can respond to the fault reproduction instructions input by the user and reproduce the fault according to the corresponding debugging data, so that on-site debugging personnel can accurately locate the fault.
[0094] The debugging data output method provided in the embodiment of the present application can enable an electronic device to obtain a debugging message collected by a collection device, and then extract the debugging data in the debugging message and store it. The extraction method is simple and convenient, and it is convenient to perform corresponding operations according to the extracted debugging data.
[0095] Optionally, since the collection device can collect messages sent by the vehicle-mounted combined navigation device to the receiving device through the CANFD bus, and the messages may also include other messages besides debug messages, such as application data messages, etc., therefore, considering that there may be multiple messages stored in the collection device, in order to facilitate the electronic device to obtain the debug messages, the electronic device can filter the messages in the collection device to obtain the debug messages.
[0096] In a possible implementation, the electronic device may store message identifiers corresponding to various types of messages in advance. Since the debug message is encapsulated with the debug message identifier, the electronic device may obtain the debug message from the acquisition device according to the debug message identifier. Specifically, the above step S30 may also be implemented by the following steps:
[0097] Obtain the debug message from the acquisition device according to the debug message identifier.
[0098] Optionally, the electronic device may extract the debugging data in the debugging message according to the length field, the sequence number field and the data field in the acquired debugging message. Specifically, Figure 4 On the basis of Figure 5 A flowchart of a debugging data output method provided in an embodiment of the present application is shown in FIG. Figure 5 , the above step S31 can also be implemented by the following steps:
[0099] Step S31-1, arranging the obtained debugging messages according to the sequence number field;
[0100] Step S31-2, extracting the debugging data stored in the data field according to the length field for each debugging message in the arrangement order;
[0101] In this embodiment, since the serial number field stores the sending serial number, the electronic device can arrange the acquired debug messages in order of serial number size, for example, from small to large. The electronic device can then extract debug data from the data field according to the length field of each debug message according to the arrangement order.
[0102] It can be understood that, since the length field stores the effective data length of the debugging data, the electronic device can extract the corresponding debugging data from the data field according to the content stored in the length data.
[0103] Step S31 - 3 , storing the extracted debugging data into a preset debugging file.
[0104] Optionally, the debugging file is created by the electronic device after receiving a debugging data extraction instruction, and the debugging file is used to store the extracted debugging data.
[0105] Optionally, the user may issue an extraction instruction through bus data extraction software on the electronic device, so that the user can obtain the debugging message from the acquisition device according to the extraction instruction, and extract and store the debugging data in the debugging message.
[0106] In one example, Figure 6 This is a schematic diagram of the extraction page of the bus data extraction software, see Figure 6 The user can select the storage address of the debugging data through the address selection box 20, and select the type of data to be extracted and the file format in which the data is to be stored through the extraction selection box 21.
[0107] Optionally, the user may input the corresponding message identifier (CAN ID) by himself, or the electronic device may respond to the description function input by the user and present the message identifier.
[0108] In order to execute the corresponding steps in the above embodiments and various possible methods, a method for implementing a debugging data output device is provided below. Figure 7 , Figure 7 The functional module diagram of a debugging data output device applied to a vehicle-mounted integrated navigation device provided by an embodiment of the present invention. It should be noted that the basic principle and technical effects of the debugging data output device provided by this embodiment are the same as those of the above-mentioned embodiments. For the sake of brief description, for the parts not mentioned in this embodiment, reference can be made to the corresponding contents in the above-mentioned embodiments. The debugging data output device includes: an adding module 200, a judging module 210 and a sending module 220.
[0109] The adding module 200 is used to add the acquired debugging data to the buffer;
[0110] It can be understood that the adding module 200 can also be used to perform the above step S20;
[0111] The judging module 210 is used to judge whether the debugging data in the buffer satisfies the preset data sending condition;
[0112] It can be understood that the determination module 210 can also be used to execute the above step S21;
[0113] The sending module 220 is used to pack the debugging data in the buffer according to the preset data sending protocol when the data sending conditions are met, generate a debugging message and send it to the receiving device through the CANFD bus so that the collection device can collect the debugging message.
[0114] It can be understood that the sending module 220 can also be used to execute the above step S22.
[0115] Optionally, the judgment module 210 is further configured to determine whether the debugging data in the buffer satisfies a preset data sending condition if the data volume of the debugging data in the buffer reaches a preset data volume.
[0116] Optionally, the judgment module 210 is further configured to determine that the debugging data in the buffer satisfies a preset data sending condition if the time interval between the current time and the time when the debugging message was last sent reaches a preset time length.
[0117] Optionally, the sending module 220 is further configured to add a debugging message identifier to the debugging message.
[0118] The debugging data output device provided in the embodiment of the present application adds the acquired debugging data to the buffer through the adding module; judges whether the debugging data in the buffer satisfies the preset data sending conditions through the judging module; and packs the debugging data in the buffer according to the preset data sending protocol when the data sending conditions are met through the sending module, generates a debugging message and sends it to the receiving device through the CANFD bus so that the collecting device can collect the debugging message. When the debugging data in the buffer of the vehicle-mounted combined navigation device meets the preset data sending conditions, the debugging data can be packed through the preset data sending protocol to generate a debugging message. Since the debugging message can be sent through the CANFD bus and directly collected by the collecting device, when there is no RS232, RS422, vehicle-mounted Ethernet and other interfaces in the combined navigation device, there is no need to add multiple cables, and the debugging data can also be obtained during on-site joint debugging. This method is relatively simple and has high acquisition efficiency.
[0119] See also Figure 8 , Figure 8 For a functional module diagram of a debugging data output device for an electronic device provided by an embodiment of the present invention, see Figure 8 The debugging data output device includes: an acquisition module 300 and an extraction module 310.
[0120] The acquisition module 300 is used to acquire the debugging message collected by the acquisition device; the debugging message vehicle-mounted integrated navigation device adds the acquired debugging data to the buffer, determines whether the debugging data in the buffer satisfies the preset data sending condition, and packages the debugging data in the buffer according to the preset data sending protocol when the data sending condition is met, and the acquisition device collects the debugging message when the vehicle-mounted integrated navigation device sends the debugging message to the receiving device through the CANFD bus;
[0121] It can be understood that the acquisition module 300 can also be used to implement the above step S30;
[0122] The extraction module 310 is used to extract the debugging data in the debugging message and store the debugging data.
[0123] It can be understood that the extraction module 310 can also be used to implement the above step S31.
[0124] Optionally, the acquisition module 300 is further configured to acquire a debug message from a collection device according to a debug message identifier.
[0125] Optionally, the extraction module 310 is further used to arrange the acquired debugging messages according to the serial number field; extract the debugging data stored in the data field according to the length field for each debugging message in the arrangement order; and store the extracted debugging data in a preset debugging file.
[0126] It is understandable that the extraction module 310 can also be used to implement the above steps S31 - 1 to S31 - 3.
[0127] The debugging data output device provided in the embodiment of the present application obtains the debugging message collected by the collection device through the acquisition module; extracts the debugging data in the debugging message and stores the debugging data through the extraction module. The extraction method is simple and convenient, and it is convenient to perform corresponding operations according to the extracted debugging data later.
[0128] The present application also provides a block diagram of a vehicle-mounted integrated navigation device 100 and an electronic device 130, see Fig. 9 The vehicle-mounted integrated navigation device 100 and the electronic device 130 include a memory 400, a processor 410 and a communication module 420. The memory 400, the processor 410 and the communication module 420 are electrically connected to each other directly or indirectly to achieve data transmission or interaction. For example, these components can be electrically connected to each other through one or more communication buses or signal lines.
[0129] The memory 400 is used to store programs or data. The memory 400 may be, but is not limited to, a random access memory (RAM), a read only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), etc.
[0130] The processor 410 is used to read / write data or programs stored in the memory and execute corresponding functions.
[0131] The communication module 420 is used to establish a communication connection between the server and other communication terminals through the network, and to send and receive data through the network.
[0132] It should be understood that Fig. 9 The structure shown is only a schematic diagram of the structure of the vehicle-mounted integrated navigation device 100 and the electronic device 130. The vehicle-mounted integrated navigation device 100 and the electronic device 130 may also include Fig. 9 More or fewer components as shown, or with Fig. 9 Different configurations shown. Fig. 9 Each component shown in the figure can be implemented by hardware, software or a combination thereof.
[0133] Optionally, an embodiment of the present application further provides a computer-readable storage medium on which a computer program is stored, and the computer program can implement the above-mentioned debugging data output method when executed by a processor.
[0134] In several embodiments provided in the present application, it should be understood that the disclosed devices and methods can also be implemented in other ways. The device embodiments described above are merely schematic. For example, the flowcharts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the devices, methods and computer program products according to multiple embodiments of the present invention. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, a program segment or a part of a code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of boxes in the block diagram and / or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.
[0135] In addition, the functional modules in the various embodiments of the present invention may be integrated together to form an independent part, or each module may exist independently, or two or more modules may be integrated to form an independent part.
[0136] If the functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0137] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A debugging data output method, characterized in that: Applied to a vehicle-mounted integrated navigation device, the vehicle-mounted integrated navigation device, the receiving device and the acquisition device are electrically connected via a CANFD bus, and the method includes: Add the acquired debugging data to the buffer; Determine whether the debugging data in the buffer satisfies a preset data sending condition; the data sending condition includes that the amount of debugging data in the buffer reaches a preset amount of data, and the time interval between the current moment and the moment when the debugging message was last sent reaches a preset duration; If the data transmission condition is met, the debugging data in the buffer is packaged according to a preset data transmission protocol to generate a debugging message; A debug message identifier is added to the debug message, and the debug message is sent to the receiving device via the CANFD bus, so that the collection device collects the debug message according to the debug message identifier.
2. The method according to claim 1, characterized in that: The preset data amount is 62 bytes.
3. The method according to claim 1, characterized in that The preset duration is 50ms.
4. The method according to claim 1, characterized in that The debugging message includes a length field, a sequence number field and a data field. The length field is used to store the length of the debugging data, the sequence number field is used to store a sending sequence number, and the data field is used to store the debugging data.
5. A debugging data output method, characterized in that: Applied to electronic equipment, the electronic equipment is communicatively connected with a collection device, and the collection device, a vehicle-mounted integrated navigation device and a receiving device are electrically connected via a CANFD bus; The method comprises: Acquire the debug message collected by the acquisition device; the vehicle-mounted integrated navigation device adds the acquired debug data to a buffer, determines whether the debug data in the buffer satisfies a preset data sending condition, and packages the debug data in the buffer according to a preset data sending protocol if the data sending condition is met, adds a debug message identifier to the debug message, and the acquisition device collects the debug message when the vehicle-mounted integrated navigation device sends the debug message to the receiving device through the CANFD bus; the data sending condition includes that the amount of debug data in the buffer reaches a preset amount of data, and the time interval between the current moment and the moment when the debug message was last sent reaches a preset duration; The debugging message corresponds to a debugging message identifier, and the obtaining of the debugging message collected by the collection device includes: According to the debug message identifier, obtaining the debug message from the acquisition device; The debugging data in the debugging message is extracted and stored.
6. The method according to claim 5, characterized in that The debugging message includes a length field, a sequence number field, and a data field, and the extracting the debugging data in the debugging message and storing the debugging data includes: Arranging the acquired debugging messages according to the sequence number field; Extracting the debugging data stored in the data field according to the length field for each debugging message in the arrangement order; The extracted debugging data is stored in a preset debugging file.
7. A debugging data output device, characterized in that Applied to a vehicle-mounted integrated navigation device, the vehicle-mounted integrated navigation device, the receiving device and the acquisition device are electrically connected via a CANFD bus, and the device comprises: Add a module to add the acquired debugging data to the buffer; A judgment module, used to judge whether the debugging data in the buffer satisfies a preset data sending condition; the data sending condition includes that the amount of debugging data in the buffer reaches a preset amount of data, and the time interval between the current moment and the moment when the debugging message was last sent reaches a preset duration; A sending module, used for packaging the debugging data in the buffer according to a preset data sending protocol to generate a debugging message when the data sending condition is met; The sending module is further used to add a debugging message identifier to the debugging message, and send it to the receiving device through the CANFD bus, so that the collecting device collects the debugging message according to the debugging message identifier.
8. A debugging data output device, characterized in that: Applied to electronic equipment, the electronic equipment is communicatively connected with a collection device, and the collection device, a vehicle-mounted integrated navigation device and a receiving device are electrically connected via a CANFD bus; The device comprises: The acquisition module is used to acquire the debugging message collected by the acquisition device; the vehicle-mounted integrated navigation device adds the acquired debugging data to a buffer, determines whether the debugging data in the buffer satisfies a preset data sending condition, and packages the debugging data in the buffer according to a preset data sending protocol if the data sending condition is met, adds a debugging message identifier to the debugging message, and the acquisition device collects the debugging message when the vehicle-mounted integrated navigation device sends the debugging message to the receiving device through the CANFD bus; the data sending condition includes that the amount of debugging data in the buffer reaches a preset amount of data, and the time interval between the current moment and the moment when the debugging message was last sent reaches a preset duration; The acquisition module is further used to acquire the debug message from the acquisition device according to the debug message identifier; The extraction module is used to extract the debugging data in the debugging message and store the debugging data.
9. A vehicle-mounted integrated navigation device, characterized in that: The method comprises a processor and a memory, wherein the memory stores a computer program executable by the processor, and the processor can execute the computer program to implement the method according to any one of claims 1 to 4.
10. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the memory stores a computer program executable by the processor, and the processor can execute the computer program to implement the method described in any one of claims 5-6.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 4 is implemented, or the method according to any one of claims 5 to 6 is implemented.
Citation Information
Patent Citations
Data acquisition method and device of vehicle-mounted terminal
CN110908363A
Electronic Devices With Adaptive Frame Rate Displays
US20130257752A1