Message collecting and reporting method and device and electronic equipment

By adopting different interception strategies for network management messages of different network segments, extracting and storing target signals, the problem of inaccurate information in the existing technology is solved, and higher signal accuracy and wider coverage of reporting.

CN119449921AActive Publication Date: 2025-02-14GUANGZHOU AUTOMOBILE GROUP CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411310892.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-19
Publication Date
2025-02-14
Estimated Expiration
2044-09-19

AI Technical Summary

Technical Problem

In the prior art, the gateway intercepts fixed key signals for the network management messages sent by each ECU, making the collected information inaccurate enough and unable to meet the reporting of key signals of a large number of ECUs.

Method used

By obtaining multiple network management messages, the message is extracted based on the interception strategy of different network segments, the target signal is obtained, and the target signal of the same network segment is stored in the corresponding buffer area to be sent. If the preset transmission conditions are met, the preset transmission conditions are met. Then generate assembly packets and send them.

Benefits of technology

It improves the accuracy of the target signal, avoids the problems of invalid signal interception and critical signal leakage interception, and meets the reporting needs of a large number of network management packets.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119449921A_ABST
    Figure CN119449921A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of networks, in particular to the technical field of automobile networks, and particularly relates to a message collecting and reporting method and device and electronic equipment, and the method comprises the steps: obtaining a plurality of network management messages; determining a corresponding interception strategy based on the network segment to which the network management message belongs, and performing signal extraction on the network management message based on the interception strategy to obtain a target signal; storing target signals corresponding to the network management messages belonging to the same network segment to a to-be-sent cache region corresponding to the network segment; if the to-be-sent cache region meets the corresponding preset sending condition, generating an assembled message based on the stored target signal, and sending the assembled message to the client; according to the method, different interception strategies are adopted for the network management messages of different network segments, so that the accuracy of target signal interception is improved; meanwhile, for the target signals of different network segments, message assembly and transmission are respectively carried out through different to-be-transmitted cache regions, and the requirement for reporting more target signals is met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of network technology, in particular to the field of automobile network technology, and specifically to a message collection and reporting method, device and electronic equipment. Background Art

[0002] With the rapid development of automotive electronic technology and the increasing degree of intelligence, the number of ECU (Electronic Control Unit) nodes has also increased. The gateway configures, manages and coordinates each ECU through network management strategies. Each ECU reports the current operating status by sending network management messages to the gateway, thereby realizing synchronous or asynchronous sleep and wake-up of each node. At the same time, the gateway will intercept key signals from the received network management messages, assemble them into new assembled messages and send them to the T-box. The T-box will report the assembled messages to the cloud to provide statistical data support for analyzing operating problems.

[0003] In the related art, the gateway intercepts fixed key signals from the network management messages sent by each ECU, which makes the collected information inaccurate. Summary of the invention

[0004] In view of this, an embodiment of the present application proposes a message collection and reporting method, device and electronic device, which can adopt different interception strategies for network management messages of different network segments, thereby improving the accuracy of target signal interception; at the same time, for target signals of different network segments, messages are assembled and sent respectively through different buffer areas to be sent, thereby satisfying the reporting of more target signals.

[0005] The embodiment of the present application is implemented by adopting the following technical solutions:

[0006] In the first aspect, an embodiment of the present application provides a method for message collection and reporting, the method comprising: obtaining multiple network management messages; performing signal extraction on the network management message based on the interception strategy corresponding to the network management message to obtain a target signal corresponding to the network management message, the interception strategy corresponding to the network management message being determined by the network segment to which the network management message belongs; storing the target signals corresponding to the network management messages belonging to the same network segment among the multiple network management messages in a to-be-sent buffer area corresponding to the network segment; if the to-be-sent buffer area meets the corresponding preset sending conditions, generating an assembled message based on the target signal stored in the to-be-sent buffer area, and sending the assembled message to the client.

[0007] In the second aspect, an embodiment of the present application provides a message collection and reporting device, which includes: an acquisition module for acquiring multiple network management messages; an interception module for performing signal extraction on the network management message based on the interception strategy corresponding to the network management message to obtain a target signal corresponding to the network management message, and the interception strategy corresponding to the network management message is determined by the network segment to which the network management message belongs; a storage module for storing the target signals corresponding to the network management messages belonging to the same network segment among the multiple network management messages into a to-be-sent buffer area corresponding to the network segment; a sending module for generating an assembled message based on the target signal stored in the to-be-sent buffer area if the to-be-sent buffer area meets the corresponding preset sending conditions, and sending the assembled message to the client.

[0008] In some implementations, the network management message corresponds to a message identifier, and the message collection and reporting device further includes an identification module for determining the network segment to which each of the network management messages belongs based on the message identifiers corresponding to each of the multiple network management messages.

[0009] In some embodiments, the network segment includes a first network segment, and the interception module includes an acquisition unit for acquiring the network segment to which each of the network management messages belongs; a signal extraction unit for performing signal extraction on the network management message whose network segment is the first network segment based on a first interception strategy to obtain a target signal corresponding to the network management message, wherein the first interception strategy is used to indicate the interception of a destination address signal, a network status indicator signal, and a wake-up source signal in the network management message.

[0010] In some embodiments, the buffer area to be sent includes a first buffer area to be sent corresponding to the first network segment, and the sending module is used to generate a first assembly message based on the target signals stored in the first buffer area to be sent if the number of target signals cached in the first buffer area to be sent reaches a quantity threshold, and send the first assembly message to the client.

[0011] In some embodiments, the network segment includes a second network segment, and the signal extraction unit is also used to perform signal extraction on the network management message whose network segment is the second network segment based on a second interception strategy to obtain a target signal corresponding to the network management message, and the second interception strategy is used to indicate the interception of the base address signal and the wake-up source signal in the network management message.

[0012] In some embodiments, the buffer area to be sent includes a second buffer area to be sent corresponding to the second network segment, and the sending module is also used to generate a second assembled message based on the target signal stored in the second buffer area to be sent if the second buffer area to be sent reaches a preset sending period, and send the second assembled message to the client.

[0013] In some embodiments, the acquisition module includes a query unit, which is used to query the cache queue according to a preset query frequency, and the cache queue is used to store network management messages sent by each node connected to the vehicle gateway, and the size of the cache queue is determined based on the number of nodes connected to the vehicle gateway; a message extraction unit, which is used to extract the network management message stored in the cache queue if it is queried that the cache queue contains the network management message.

[0014] In a third aspect, an embodiment of the present application provides an electronic device, which includes one or more processors; a memory; and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the above method.

[0015] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a program code, and the program code can be called by a processor to execute the above method.

[0016] The embodiments of the present application provide a message collection and reporting method, device and electronic device, the method comprising: after obtaining multiple network management messages; based on the interception strategy corresponding to the network management message, performing signal extraction on the network management message to obtain a target signal corresponding to the network management message, the interception strategy corresponding to the network management message is determined by the network segment to which the network management message belongs; wherein the network management messages of different network segments focus on different points, therefore, by adopting different interception strategies for network management messages of different networks, the intercepted target signal can more accurately reflect the focus of the network management message, avoid the interception of invalid signals, and avoid the problem of missed interception of key signals, thereby improving The accuracy of the intercepted target signal is ensured; then, the target signals corresponding to the network management messages belonging to the same network segment in the multiple network management messages are stored in the to-be-sent buffer area corresponding to the network segment; if the to-be-sent buffer area meets the corresponding preset sending conditions, an assembled message is generated based on the target signal stored in the to-be-sent buffer area, and the assembled message is sent to the client; that is, the assembled messages of different network segments are sent by different to-be-sent buffer areas. Compared with the prior art in which all target signals are sent by one assembled message, the generation and sending of assembled messages are performed separately by multiple to-be-sent buffer areas, so that multiple assembled messages can contain more target signals, thereby satisfying the reporting of a large number of network management messages.

[0017] These and other aspects of the present application will become more clearly understood in the description of the following embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.

[0019] Figure 1 A flow chart of the message collection and reporting method provided in an embodiment of the present application is shown.

[0020] Figure 2 The embodiment of the present application provides Figure 1 Schematic diagram of the process of step S110.

[0021] Figure 3 The embodiment of the present application provides Figure 1 Schematic diagram of the process of step S120.

[0022] Figure 4 The embodiment of the present application provides Figure 1 Schematic diagram of the process of step S140.

[0023] Figure 5 The application scenario diagram involved in the embodiment of the present application is shown.

[0024] Figure 6 A structural block diagram of a message collection and reporting device provided in an embodiment of the present application is shown.

[0025] Figure 7 A structural block diagram of an electronic device provided in an embodiment of the present application is shown. DETAILED DESCRIPTION

[0026] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be understood as limiting the present application.

[0027] In order to enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without making creative work are within the scope of protection of the present application.

[0028] In the following description, the terms "first\second" and the like are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It is understandable that "first\second" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.

[0029] The term "multiple" as used herein refers to two or more than two. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the related objects are in an "or" relationship.

[0030] With the rapid development of automotive electronic technology, the degree of intelligence is getting higher and higher, and the number of ECU nodes is also increasing. The gateway configures, manages and coordinates each ECU through network management strategies. Each ECU reports the current operating status by sending network management messages to the gateway, thereby realizing synchronous or asynchronous sleep and wake-up of each node; at the same time, the gateway will intercept key signals from the received network management messages, and assemble them into new assembled messages and send them to the T-box. The T-box reports the assembled messages to the cloud to provide statistical data support for analyzing operating problems.

[0031] In the related technology, the gateway intercepts fixed key signals for the network management messages sent by each ECU, which makes the collected information inaccurate. In addition, since the number of key signals that can be included in the assembled message is limited, the assembled message cannot meet the reporting of key signals of a large number of ECUs.

[0032] In order to solve the above problems, the present application provides a message collection and reporting method, device and electronic device, the method comprising: obtaining multiple network management messages; performing signal extraction on the network management message based on the interception strategy corresponding to the network management message to obtain a target signal corresponding to the network management message, the interception strategy corresponding to the network management message is determined by the network segment to which the network management message belongs; storing the target signals corresponding to the network management messages belonging to the same network segment among multiple network management messages in a to-be-sent buffer area corresponding to the network segment; if the to-be-sent buffer area meets the corresponding preset sending conditions, generating an assembled message based on the target signal stored in the to-be-sent buffer area, and sending the assembled message to the client.

[0033] By adopting the method provided in the present application, different interception strategies are adopted for network management messages of different networks, so that the intercepted target signal can more accurately reflect the focus of the network management message in the network segment, avoid the interception of invalid signals, and avoid the problem of missing interception of key signals, thereby improving the accuracy of the intercepted target signal; at the same time, the assembled messages of different network segments are sent by different buffer areas to be sent. Compared with the prior art of sending all target signals through one assembled message, the assembled messages independently sent by multiple buffer areas to be sent can contain more target signals, thereby satisfying the reporting of a large number of network management messages.

[0034] The embodiments provided in this application will be described below with reference to the accompanying drawings.

[0035] See also Figure 1 , Figure 1 A flow chart of a message collection and reporting method provided in an embodiment of the present application is given. The message collection and reporting method includes steps S110-S140:

[0036] S110. Acquire multiple network management messages.

[0037] Among them, the network management message is sent by multiple ECUs connected to the gateway and is a key information carrier for realizing communication coordination, status synchronization and network management between ECUs; the communication status of ECU includes wake-up, sleep, synchronization and error handling, etc.; among them, each ECU can be described as a node connected to the gateway, and the gateway connects each node through the CAN channel and receives the network management message sent by each node.

[0038] It should be noted that different network management messages sent by the same node have the same field, and different network management messages sent by different nodes may have the same field or different fields.

[0039] In some implementations, obtaining multiple network management messages may be receiving network management messages sent by each node in real time. After receiving the network management message, the network management message is processed in real time to obtain a target signal, and then the subsequent assembly message is sent. That is, each node sends the network management message and sends the assembly message in the subsequent step can be performed in real time.

[0040] In other implementations, the network management messages sent by each node may be stored in a cache queue, and then extracted from the cache queue for subsequent processing. That is, the sending of network management messages by each node and the sending of assembly messages by the gateway may be performed asynchronously.

[0041] See also Figure 2 , Figure 2 The embodiment of the present application provides Figure 1 Schematic diagram of the process of step S110, step S110 may include steps S111-S112:

[0042] S111. Query a cache queue according to a preset query frequency. The cache queue is used to store network management messages sent by each node connected to the vehicle gateway. The size of the cache queue is determined based on the number of nodes connected to the vehicle gateway.

[0043] The cache queue manages network management messages according to the first-in-first-out (FIFO) principle; the size of the cache queue, also called the capacity of the cache queue, refers to the upper limit of the number of messages that can be stored in the cache queue.

[0044] In some embodiments, the size of the cache queue can be determined based on the number of nodes connected to the vehicle gateway; it is understandable that the frequency of a node sending network management messages is relatively fixed. Therefore, the number of nodes connected to the vehicle gateway reflects the write speed of the cache queue to a certain extent. The more nodes there are, the higher the write speed of the cache queue. Determining the size of the cache queue by the number of nodes connected to the vehicle gateway can effectively avoid the discard of network management messages due to cache queue overflow.

[0045] Exemplarily, the size of the cache queue may be greater than the number of nodes connected to the vehicle gateway.

[0046] In other embodiments, the size of the cache queue may also be determined by the number of nodes connected to the vehicle gateway and the preset query frequency; it is understandable that the purpose of querying the cache queue is to extract network management messages from the cache queue. Therefore, the preset query frequency of the cache queue can reflect the consumption speed of the cache queue to a certain extent. The higher the query frequency, the faster the consumption speed of the cache queue. Therefore, the size of the cache queue is jointly determined by the number of nodes connected to the vehicle gateway and the preset query frequency, which improves the accuracy of the size of the cache queue and avoids resource waste caused by setting the cache queue too large.

[0047] Exemplarily, the correspondence between the preset query frequency and the adjustment coefficient can be pre-set. On the basis that the size of the cache queue is greater than the number of nodes connected to the vehicle gateway, the adjustment coefficient corresponding to the preset query frequency is multiplied to achieve further adjustment of the cache queue size.

[0048] In some embodiments, the size of the cache queue can be initialized to a set value each time the vehicle stops running, and after the vehicle is restarted, the connection quantity information and preset query frequency of the ECU are obtained from the on-board gateway to automatically adjust the size of the cache queue, thereby achieving dynamic adjustment of the cache queue size.

[0049] S112: If it is found that the cache queue contains network management messages, the network management messages stored in the cache queue are extracted.

[0050] It can be understood that, based on the query that network management messages are stored in the cache queue, the network management messages stored in the cache queue are extracted according to the first-in-first-out principle; the number of network management messages extracted each time can be pre-set, or all network management messages in the cache queue can be extracted, and the extracted network management messages are used to execute subsequent steps.

[0051] If it is found that no network management message is stored in the buffer queue, the target signal in the buffer area to be sent can be directly queried, and the assembled message is generated and sent according to the target signal.

[0052] S120. Perform signal extraction on the network management message based on the interception strategy corresponding to the network management message to obtain a target signal corresponding to the network management message. The interception strategy corresponding to the network management message is determined by the network segment to which the network management message belongs.

[0053] The interception strategy is used to indicate the signal that needs to be intercepted from the network management message. In the present application, the signal that needs to be intercepted from the network management message indicated by the interception strategy is described as the target signal.

[0054] It should be noted that the target signal to be intercepted indicated by an interception strategy may be one or more, and the target signals to be intercepted indicated by different interception strategies may contain the same signal.

[0055] In some implementations, the interception policy corresponding to the network management message is determined by the network segment to which the network management message belongs; that is, network management messages belonging to the same network segment correspond to the same interception policy.

[0056] It is worth mentioning that network management messages belonging to the same network segment correspond to the same network management policy, and the same network policy has the same focus on each network management message. Therefore, the target signal in each network management message belonging to the same network segment can be extracted by using the same interception strategy.

[0057] In some implementations, the network management message corresponds to a message identifier. Before step S120, the message collection and reporting method may further include the following steps:

[0058] Based on the message identifiers corresponding to the multiple network management messages, the network segment to which each network management message belongs is determined.

[0059] Among them, the message identifier, also called message ID, frame ID or message ID, is used to uniquely identify and distinguish different messages in the network.

[0060] It is worth mentioning that the message identifier is a part of the network management message and is usually included in the header of the network management message. It generates binary numbers of different lengths depending on the transmission protocol. The message identifier usually consists of a base address and an ECU address.

[0061] Exemplarily, under the CAN (Control Area Network) transmission protocol commonly used in the field of automotive technology, two network management strategies, OSEK and AUTOSAR, may be included, corresponding to two network segments, namely, the OSEK network segment and the AUTOSAR network segment, wherein the message identification range corresponding to the OSEK network segment is [0x400-0x4FF], and the message identification range corresponding to the AUTOSAR network segment is [0x500-0x5FF]; therefore, the network segment to which the network management message belongs can be determined through the message identification corresponding to the network management message.

[0062] Of course, in other implementations, the interception strategy corresponding to the network management message may also be determined by the node to which the network management message belongs, wherein the node to which the network management message belongs refers to the ECU node that sends the network management message; further, the node to which the network management message belongs can be uniquely determined by the source address contained in the network management message; exemplarily, the correspondence between the node and the interception strategy can be pre-set, and the corresponding interception strategy can be determined according to the node to which the network management message belongs.

[0063] S130: Store target signals corresponding to network management messages belonging to the same network segment among multiple network management messages into a buffer area to be sent corresponding to the network segment.

[0064] It can be understood that different network segments correspond to different buffer areas to be sent; further, different buffer areas to be sent are independent of each other, and their buffer area size, preset sending conditions defined in the buffer area, the form of assembled messages and other related configurations are all independent of each other. Among them, the preset sending conditions defined in the buffer area mean that the buffer area will only perform the sending operation after the preset sending conditions are triggered.

[0065] By setting the buffer areas to be sent for different network segments, the target signals of different network segments can be sent separately to meet the diverse sending requirements; at the same time, the number of target signals sent can be increased to meet the sending of a large number of target signals.

[0066] S140: If the buffer area to be sent meets the corresponding preset sending condition, generate an assembled message based on the target signal stored in the buffer area to be sent, and send the assembled message to the client.

[0067] Among them, the preset sending conditions corresponding to the buffer area to be sent are pre-set, and the preset sending conditions corresponding to different buffer areas to be sent may be the same or different; exemplarily, the preset sending conditions may be a preset sending cycle, or it may be that the target signal stored in the buffer area to be sent reaches a set number, which can be set specifically according to actual needs.

[0068] In some implementations, generating an assembly message based on a target signal may be performed by combining a preset number of target signals to obtain the assembly message; further, the order of combining multiple target signals may be arbitrary, or the target signals may be combined in the order of their interception time.

[0069] In other implementations, considering that the target signal corresponding to the same network management message should be sent through the same assembly message, the assembly message is generated based on the target signal, and the target signals corresponding to a preset number of network management messages can be combined to obtain the assembly message.

[0070] Through the method provided in the embodiment of the present application, different interception strategies are adopted for network management messages of different networks, so that the intercepted target signal can more accurately reflect the focus of the network management message in the network segment, avoid the interception of invalid signals, and avoid the problem of missing interception of key signals, thereby improving the accuracy of the intercepted target signal; at the same time, the assembled messages of different network segments are sent by different buffer areas to be sent. Compared with the prior art of sending all target signals through one assembled message, the assembled messages independently sent by multiple buffer areas to be sent can contain more target signals, thereby satisfying the reporting of a large number of network management messages.

[0071] It is worth mentioning that the client can be a vehicle-mounted client or other clients; when the client is a vehicle-mounted client, after sending the assembly message to the vehicle-mounted client, the vehicle-mounted client can further report the assembly message to the cloud to realize cloud storage of the assembly message, so as to provide data support for vehicle operation diagnosis, wherein the vehicle-mounted client can be a vehicle-mounted T-box.

[0072] In some embodiments, the network segment includes a first network segment and a second network segment. The first network segment may be an OSEK network segment, and the second network segment may be an AUTOSAR network segment. Figure 3 , Figure 3 The embodiment of the present application provides Figure 1 Schematic diagram of the process of step S120, step S120 includes:

[0073] S121. Obtain the network segment to which each network management message belongs.

[0074] As mentioned in the above-mentioned embodiment, the network segment to which the network management message belongs can be determined by the message identifier of the network management message.

[0075] S122. For a network management message whose network segment is the first network segment, perform signal extraction on the network management message based on a first interception strategy to obtain a target signal corresponding to the network management message. The first interception strategy is used to indicate the interception of a destination address signal, a network status indicator signal, and a wake-up source signal in the network management message.

[0076] It is worth mentioning that the network management messages of different network segments have different message formats; specifically, for the OSEK network segment, the network management message belonging to the network segment includes 8 bytes of information, as follows:

[0077] Byte0 is used to indicate the destination address (Dest i nat i on Address);

[0078] Byte1 is used to indicate the network status, including 8 Bits, Bit0 is used to indicate wake-up (Ali ve), Bit1 is used to indicate token ring (Ring), Bit2 is used to indicate fault (Limp Home), Bit3 is used to indicate sleep indication (Sleep In, Sleep Indicator), Bit4 is used to indicate sleep confirmation (Sleep Ack, Sleep Acknowledge), Bit5-Bit7 are used to store other specific status information;

[0079] Byte2 is used to indicate the wakeup source (Wakeup Origin);

[0080] Byte3-Byte7 are used to store other specific signals.

[0081] It is worth mentioning that when each node belonging to the OSEK network segment communicates, it is necessary to first establish a logical ring, and each node communicates through the established logical ring; for example, the logical ring established between the three nodes a, b, and c is abca. When a sends a wake-up message, a will not enter the wake-up state immediately, but will need to wait for the wake-up message to be sent to b, b will then send a message to c, and c will then send a message to a. a will decide whether to wake up based on the message received from c. If b and c both decide to wake up, a can wake up, and if b or c decides not to wake up, a will not wake up; that is to say, in the OSEK network segment, the status of each node (such as wake up, sleep) needs to refer to the network status indication of the message sent by other nodes in the same network segment, and a logical ring needs to be established for information transmission. Among them, it should be noted that the messages sent by a, b, and c will not only be sent to the next node, but also to the vehicle gateway at the same time.

[0082] Therefore, for the network management message whose network segment is the first network segment (i.e., the OSEK network segment), it is necessary to intercept the Byte0 destination address signal, Byte1 network status indicator signal, and Byte2 wake-up source signal in the network management message, wherein the destination address signal is used to obtain the network status flow, the network status indicator signal is used to obtain the network status information, and the wake-up source signal is used to determine the wake-up reason.

[0083] On the basis of step S122, the buffer area to be sent includes a first buffer area to be sent corresponding to the first network segment, and the target signal corresponding to the network management message belonging to the first network segment is stored in the first buffer area to be sent. Figure 4 , Figure 4 The embodiment of the present application provides Figure 1 Schematic diagram of the process of step S140, step S140 may include:

[0084] S141: If the number of target signals cached in the first buffer area to be sent reaches a number threshold, generate a first assembly message based on the target signals stored in the first buffer area to be sent, and send the first assembly message to the client.

[0085] It is understandable that, in the first network segment (OSEK network segment), the status of each node (such as wake-up, sleep) needs to refer to the network status indication of the message sent by other nodes in the same network segment; that is, a sufficient number of first assembly messages are required to analyze whether the status of each node is abnormal.

[0086] Therefore, the preset sending condition of the first buffer area to be sent is set to that the first assembly message is generated based on the target signal and the first assembly message is sent to the client only after the number of target signals cached in the first buffer area to be sent reaches a quantity threshold; this can ensure that a sufficient number of first assembly messages are sent during this round of sending, thereby facilitating analysts to perform anomaly analysis based on the first assembly messages.

[0087] Exemplarily, the size of the first buffer area to be sent can be set to 90 bytes. It can be seen from the above embodiment that the target signal of a single network management message includes Byte0 destination address signal, Byte1 network status indication signal and Byte2 wake-up source signal, which occupy a total of 3 bytes. Therefore, after collecting the target signals of 30 network management messages, it can be determined that the number of target signals cached in the first buffer area to be sent reaches the quantity threshold.

[0088] In the CAN channel, a frame message usually contains 8 bytes. The format of the first assembled message can be shown in the following table:

[0089]

[0090] It can be seen from the above table that a frame of the first assembly message contains target signals corresponding to two network management messages, wherein Byte6 represents the ECU address and Byte7 represents the message sequence number. In this embodiment, the message sequence number includes 1-15.

[0091] Under the format of the first assembled message shown in the above table, when the target signal cached in the first buffer area to be sent reaches 90Byte, a first assembled message of 15 frames can be assembled; thereafter, the 15-frame message can be sent with a sending period of 100ms; it should be noted that the size of the first buffer area to be sent, the format of the first assembled message and the sending period are all illustrative examples and do not constitute a limitation to this solution.

[0092] In some embodiments, a sending queue may also be established in the first buffer area to be sent. After the target signal cached in the first buffer area to be sent reaches a quantity threshold, the target signal is assembled to obtain a first assembled message, and the first assembled message is moved into the sending queue. While the sending queue sends the first assembled message, the first buffer area to be sent can still continue to receive the target signal, thereby avoiding the problem of overflow of the first buffer area to be sent.

[0093] S123. For a network management message belonging to the second network segment, perform signal extraction on the network management message based on a second interception strategy to obtain a target signal corresponding to the network management message, wherein the second interception strategy is used to instruct interception of a base address signal and a wake-up source signal in the network management message.

[0094] The second network segment is an AUTOSAR network segment. Specifically, for the AUTOSAR network segment, the network management message belonging to the network segment includes 8 bytes of information, which are as follows:

[0095] Byte0 is used to indicate the base address (Source Address);

[0096] Byte1 is a custom field, which can be set differently according to different nodes;

[0097] Byte2 is used to indicate the wakeup source (Wakeup Origin);

[0098] Byte3-Byte7 are used to store other specific signals.

[0099] It is worth mentioning that each node belonging to the AUTOSAR network segment adopts a distributed strategy. When communicating, each node can autonomously enter the sleep state or the wake-up state. For example, taking nodes a and b as an example, when a sends a wake-up message to b, a can enter the wake-up state without waiting for b's status indication. In other words, in the AUTOSAR network segment, the state of each node (such as wake-up and sleep) is independent. It should be noted that the messages sent by a and b will not only be sent to the next node, but also to the vehicle gateway at the same time.

[0100] Therefore, for the network management message whose network segment is the second network segment (i.e., the AUTOSAR network segment), it is only necessary to intercept the Byte0 base address signal and the Byte2 wake-up source signal in the network management message, wherein the node corresponding to the network management message can be determined by the Byte0 base address signal, and the wake-up reason can be determined by the Byte2 wake-up source signal.

[0101] On the basis of step S123, the buffer area to be sent further includes a second buffer area to be sent corresponding to the second network segment, and the target signal corresponding to the network management message belonging to the second network segment is stored in the second buffer area to be sent. Figure 4 , step S140 may include:

[0102] S142: If the second buffer area to be sent reaches a preset sending period, generate a second assembled message based on the target signal stored in the second buffer area to be sent, and send the second assembled message to the client.

[0103] It can be understood that, since in the second network segment (AUTOSAR network segment), the state of each node (such as wake-up, sleep) can be determined according to the target signal of the corresponding network management message; therefore, the preset sending condition of the second buffer area to be sent is set to the second buffer area to send the second assembled message with a preset sending period; the timeliness of the second assembled message can be ensured.

[0104] Exemplarily, the size of the second assembled message can still be 8 Bytes. It can be seen from the above embodiment that in the second network segment (AUTOSAR network segment), the target signal of a single network management message includes a Byte0 base address signal and a BByte2 wake-up source signal, which occupy a total of 2 Bytes. Therefore, the format of the second assembled message can be shown in the following table:

[0105]

[0106] It can be seen from the above table that one frame of the second assembled message can include target signals corresponding to four network management messages; the second buffer area to be sent can send the second assembled message with 100 ms as the preset sending period.

[0107] Since the second buffer area to be sent assembles and sends the second assembled message according to a preset sending cycle, if the number of target signals received in the second buffer area to be sent is large within a preset sending cycle, it will cause the target signal to overflow; therefore, when the target signals received within a preset sending cycle overflow, the target signal can be updated according to a first-in-first-out method, that is, the first target signal stored in the second buffer area to be sent is removed, and the latest target information stored is written in; further, when assembling the second assembled message, the first target signal stored can be stored in the low-order byte position (such as Byte0, Byte1), and the latest target signal can be stored in the high-order byte position (such as Byte6, Byte7).

[0108] It is understandable that when the target signal in the second buffer to be sent overflows, the first-in-first-out method is used to ensure that the target signal stored in the second buffer to be sent is the latest target signal, thereby ensuring the timeliness of the second assembled message.

[0109] Of course, if the number of target signals received by the second buffer to be sent is insufficient to assemble a second assembled message within a preset sending cycle, the empty Byte bits of the second assembled message can be filled, such as filling the ECU address.

[0110] For easier understanding, see Figure 5 , Figure 5 The application scenario diagram involved in the embodiment of the present application is given, which is specifically applied to the automobile intelligent driving system. The specific implementation process is as follows:

[0111] After the vehicle is started, determine whether the vehicle network is awakened. If the vehicle network is not awakened, determine that the reporting is completed; if the vehicle network is in the awakened state, receive the network management message sent by each ECU node and write it into the cache queue, where the size of the cache queue is determined by the number of ECU nodes.

[0112] The cache queue is checked periodically. If the cache queue stores network management messages, all network management messages in the cache queue are extracted; if the cache queue does not store network management messages, the process directly jumps to determining whether the buffer area to be sent meets the corresponding preset sending condition.

[0113] For each network management message, an interception strategy and a buffer area to be sent are determined according to the network segment to which the network management message belongs, and a signal extraction is performed on the network management message according to the interception strategy corresponding to the network segment to obtain a target signal corresponding to the network management message; and the target signals corresponding to the network management messages belonging to the same network segment among multiple network management messages are stored in the buffer area to be sent corresponding to the network segment.

[0114] It is determined whether the buffer area to be sent meets the corresponding preset sending condition. If the buffer area to be sent meets the corresponding preset sending condition, an assembly message is generated based on the target signal stored in the buffer area to be sent, and the assembly message is sent to the T-box.

[0115] See also Figure 6 , Figure 6 A schematic diagram of a message collection and reporting device provided in an embodiment of the present application is given. The message collection and reporting device 300 includes:

[0116] The acquisition module 310 is used to acquire multiple network management messages.

[0117] The interception module 320 is used to extract the signal of the network management message based on the interception strategy corresponding to the network management message to obtain the target signal corresponding to the network management message. The interception strategy corresponding to the network management message is determined by the network segment to which the network management message belongs.

[0118] The storage module 330 is used to store the target signals corresponding to the network management messages belonging to the same network segment among the multiple network management messages into the to-be-sent buffer area corresponding to the network segment.

[0119] The sending module 340 is configured to generate an assembled message based on the target signal stored in the buffer area to be sent, and send the assembled message to the client if the buffer area to be sent meets the corresponding preset sending condition.

[0120] In some implementations, the network management message corresponds to a message identifier, and the message collection and reporting device 300 further includes an identification module for determining the network segment to which each network management message belongs based on the message identifiers corresponding to each of the multiple network management messages.

[0121] In some embodiments, the network segment includes a first network segment, and the interception module 320 includes an acquisition unit for acquiring the network segment to which each network management message belongs; a signal extraction unit for performing signal extraction on the network management message whose network segment is the first network segment based on a first interception strategy to obtain a target signal corresponding to the network management message, and the first interception strategy is used to indicate the interception of a destination address signal, a network status indicator signal, and a wake-up source signal in the network management message.

[0122] In some embodiments, the buffer area to be sent includes a first buffer area to be sent corresponding to the first network segment, and the sending module 340 is used to generate a first assembly message based on the target signals stored in the first buffer area to be sent if the number of target signals cached in the first buffer area to be sent reaches a quantity threshold, and send the first assembly message to the client.

[0123] In some embodiments, the network segment includes a second network segment, and the signal extraction unit is also used to perform signal extraction on the network management message whose network segment is the second network segment based on the second interception strategy to obtain a target signal corresponding to the network management message, and the second interception strategy is used to indicate the interception of the base address signal and the wake-up source signal in the network management message.

[0124] In some embodiments, the buffer area to be sent includes a second buffer area to be sent corresponding to the second network segment, and the sending module 340 is also used to generate a second assembled message based on the target signal stored in the second buffer area to be sent if the second buffer area to be sent reaches a preset sending period, and send the second assembled message to the client.

[0125] In some embodiments, the acquisition module 310 includes a query unit, which is used to query the cache queue according to a preset query frequency, the cache queue is used to store network management messages sent by each node connected to the vehicle gateway, and the size of the cache queue is determined based on the number of nodes connected to the vehicle gateway; a message extraction unit, which is used to extract the network management message stored in the cache queue if it is queried that the cache queue contains the network management message.

[0126] In some implementations, based on the message collection and reporting method provided in the above embodiment, the embodiment of the present application also provides an electronic device, such as Figure 7 , Figure 7A structural block diagram of an electronic device provided in an embodiment of the present application is given, where the electronic device 400 includes one or more processors 410; a memory 420; and one or more programs, wherein the one or more programs are stored in the memory 420 and configured to be executed by the one or more processors 410, and the one or more programs are configured to execute the above method.

[0127] The electronic device 400 may be a terminal device, and the terminal device may be a computer, a tablet computer, a vehicle-mounted terminal, etc.

[0128] The processor 410 may include one or more processing cores. The processor 410 uses various interfaces and lines to connect various parts of the entire wearable device, and executes various functions of the wearable device and processes data by running or executing instructions, programs, code sets or instruction sets stored in the memory 420, and calling data stored in the memory 420. Optionally, the processor 410 can be implemented in at least one hardware form of digital signal processing (DSP), field programmable gate array (FPGA), and programmable logic array (PLA). The processor 410 can integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content to be displayed; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor, but may be implemented separately through a communication chip.

[0129] The memory 420 may include a random access memory (RAM) or a read-only memory (ROM). The memory 420 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 420 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the following various method embodiments, etc. The data storage area may also store data created by the electronic device during use.

[0130] In some embodiments, the present application further provides a computer-readable storage medium, which stores program code, and the program code can be called by a processor to execute the above method.

[0131] The computer readable storage medium can be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read-only memory), an EPROM, a hard disk or a ROM. Optionally, the computer readable storage medium includes a non-transitory computer-readable storage medium. The computer readable storage medium has a storage space for program codes that execute any of the method steps in the above method. These program codes can be read from or written into one or more computer program products. The program code can be compressed in an appropriate form.

[0132] In the embodiments of the present application, the term "module" or "unit" refers to a computer program or a part of a computer program with a predetermined function, and works together with other related parts to achieve a predetermined goal, and can be implemented in whole or in part by using software, hardware (such as processing circuits or memories) or a combination thereof. Similarly, a processor (or multiple processors or memories) can be used to implement one or more modules or units. In addition, each module or unit can be a part of the overall module or unit of the module or unit function.

[0133] The above are only preferred embodiments of the present application, and are not intended to limit the present application in any form. Although the present application has been disclosed as above with preferred embodiments, it is not intended to limit the present application. Any technical personnel in the field can make some changes or modify the technical contents disclosed above into equivalent embodiments without departing from the scope of the technical solution of the present application. However, any brief modifications, equivalent changes and modifications made to the above embodiments based on the technical essence of the present application without departing from the content of the technical solution of the present application are still within the scope of the technical solution of the present application.

Claims

1. A message collection and reporting method, characterized in that: include: Obtain multiple network management messages; Performing signal extraction on the network management message based on the interception strategy corresponding to the network management message to obtain a target signal corresponding to the network management message, wherein the interception strategy corresponding to the network management message is determined by the network segment to which the network management message belongs; storing the target signals corresponding to the network management messages belonging to the same network segment among the plurality of network management messages in a buffer area to be sent corresponding to the network segment; If the buffer area to be sent meets the corresponding preset sending condition, an assembled message is generated based on the target signal stored in the buffer area to be sent, and the assembled message is sent to the client.

2. The method according to claim 1, characterized in that: The network management message corresponds to a message identifier, and before performing signal extraction on the network management message based on the interception strategy corresponding to the network management message to obtain a target signal corresponding to the network management message, the method includes: Based on the message identifiers corresponding to the multiple network management messages, the network segment to which each of the network management messages belongs is determined.

3. The method according to claim 1, characterized in that The network segment includes a first network segment, and the signal extraction of the network management message based on the interception strategy corresponding to the network management message to obtain a target signal corresponding to the network management message includes: Obtaining the network segment to which each of the network management messages belongs; For a network management message whose network segment is the first network segment, signal extraction is performed on the network management message based on a first interception strategy to obtain a target signal corresponding to the network management message. The first interception strategy is used to indicate the interception of a destination address signal, a network status indication signal and a wake-up source signal in the network management message.

4. The method according to claim 3, characterized in that: The to-be-sent buffer area includes a first to-be-sent buffer area corresponding to the first network segment, and if the to-be-sent buffer area meets a corresponding preset sending condition, generating an assembled message based on a target signal stored in the to-be-sent buffer area, and sending the assembled message to the client, including: If the number of target signals cached in the first buffer area to be sent reaches a number threshold, a first assembly message is generated based on the target signals stored in the first buffer area to be sent, and the first assembly message is sent to the client.

5. The method according to claim 3, characterized in that: The network segment includes a second network segment, and the signal extraction of the network management message based on the interception strategy corresponding to the network management message to obtain the target signal corresponding to the network management message also includes: For the network management message belonging to the second network segment, signal extraction is performed on the network management message based on the second interception strategy to obtain the target signal corresponding to the network management message. The second interception strategy is used to indicate the interception of the base address signal and the wake-up source signal in the network management message.

6. The method according to claim 5, characterized in that The buffer area to be sent includes a second buffer area to be sent corresponding to the second network segment, and if the buffer area to be sent meets the corresponding preset sending condition, generating an assembled message based on the target signal stored in the buffer area to be sent, and sending the assembled message to the client, further comprising: If the second buffer area to be sent reaches a preset sending period, a second assembled message is generated based on the target signal stored in the second buffer area to be sent, and the second assembled message is sent to the client.

7. The method according to claim 1, characterized in that The obtaining of multiple network management messages includes: Querying a cache queue according to a preset query frequency, the cache queue being used to store network management messages sent by each node connected to the vehicle gateway, and the size of the cache queue being determined based on the number of nodes connected to the vehicle gateway; If it is found that the cache queue stores the network management message, the network management message stored in the cache queue is extracted.

8. A message collection and reporting device, characterized in that: include: An acquisition module, used for acquiring multiple network management messages; An interception module, used to extract a signal from the network management message based on an interception strategy corresponding to the network management message, to obtain a target signal corresponding to the network management message, wherein the interception strategy corresponding to the network management message is determined by the network segment to which the network management message belongs; A storage module, used for storing target signals corresponding to network management messages belonging to the same network segment among the plurality of network management messages into a buffer area to be sent corresponding to the network segment; The sending module is used to generate an assembled message based on the target signal stored in the buffer area to be sent, and send the assembled message to the client if the buffer area to be sent meets the corresponding preset sending condition.

9. An electronic device, characterized in that: include: one or more processors; Memory; One or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, and the one or more programs are configured to execute the method as claimed in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: include: The computer-readable storage medium stores program codes, and the program codes can be called by a processor to execute the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Message processing method and device and computer readable storage medium

    CN107707477A

  • Network message assembling method and device, equipment, medium and program product

    CN114448976A

  • Vehicle-mounted local network management method and system

    CN115167218A

  • Vehicle data reporting method and device, vehicle, gateway and storage medium

    CN116668478A

  • Management server, communication cutoff device and information processing system

    US20120030351A1