A method for dynamically adjusting ECU message reception and transmission, electronic device and storage medium

By dynamically adjusting the configuration information of ECU sending and receiving messages in the application software, the problem of complex message configuration and long development cycle in the existing technology is solved, flexible message configuration and multi-packet message transmission are realized, and the controller's sending and receiving packets is expanded, and the cost is reduced.

CN117411743BActive Publication Date: 2025-05-23DONGFENG COMML VEHICLE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311398093.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-10-25
Publication Date
2025-05-23
Estimated Expiration
2043-10-25

AI Technical Summary

Technical Problem

In the prior art, in the automotive control system, each packet sent and received needs to be configured in the basic software and application software respectively, resulting in a long development cycle and high cost. Due to the controller resources, the total number of packets sent and received is limited.

Method used

By dynamically adjusting the configuration information of ECU sending and receiving messages in the application software, including message ID, period, length, sending method, enable, etc., the message definition can be changed only through the application software configuration, supports multi-packet message transmission, and realizes the sending and receiving of multiple groups of messages through the priority-sorted time-sequence interface.

Benefits of technology

It realizes the flexibility and universality of message configuration, reduces dependence on basic software suppliers, simplifies the message sending process, expands the controller's sending and receiving capabilities, and reduces development and maintenance costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117411743B_ABST
    Figure CN117411743B_ABST
Patent Text Reader

Abstract

The present invention discloses a method, electronic device and storage medium for dynamically adjusting ECU message transmission and reception, including a message change process based on application software: the basic software configures the configuration information of the underlying message transmission and reception to be defined by the application software, and when receiving and transmitting messages, the application software re-assigns the values ​​to realize the message ID transmission and reception information. The present invention re-assigns the message ID, message period, message length and trigger form of the message transmission and reception defined by BSW through ASW (application software), so that the message change can be realized only by configuring ASW, so that the message transmission and reception design is no longer subject to multiple organizations or suppliers, and the versatility is stronger.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of automobile control, and in particular relates to a method for dynamically adjusting ECU message reception and transmission, electronic equipment and storage medium. Background Art

[0002] The CAN bus communication protocol is widely used in the automotive field, and the controller is one of the important components of the CAN bus communication protocol. The controller (ECU) sends and receives messages in BSW (basic software) and ASW (application software). Generally, the basic software defines the number of sent and received messages, message ID, message cycle, and message length, and the application software defines the message signal.

[0003] In the existing technical solution, each time a message is received or sent, the basic software and application software of the message need to be configured separately.

[0004] Table 1: BSW, ASW configuration relationship table

[0005]

[0006] For conventional message 1 reception / transmission, configure BSW A1 information, including message ID, message period, message length, message enable, etc. At the same time, configure ASW B1 information to define the message content.

[0007] For the reception / transmission of multi-packet message A①, since the message with a length greater than 8 bytes cannot be loaded in a single CAN data frame, it is also necessary to configure the announcement message TP.CM_BAM① in sequence. After a certain period of time, the data Bdt① is intercepted in groups of 7 bytes and the data message TP.DT is sent in sequence.

[0008] The problem with the above solution is that each received / sent message needs to configure the message information B1 (message ID, period, length, sending mode, enable) in BSW, and then define the data information sent by B1 in ASW. Its limitation is that at the beginning of software development, the message ID, period, length, sending mode, and enable definition of all received / sent messages are locked, including:

[0009] 1. At the beginning of basic software development, the number of sent and received messages, message ID, message cycle, message length, message enable and other information were defined. With the iterative upgrade of the control system, the basic software's sent and received messages need to be reconfigured and expanded while the application software is upgraded. The controller's sent and received messages are subject to BSW. BSW and ASW are generally developed by teams in different professional fields. The basic software of many controllers is also developed using customized solutions from suppliers, and cross-border cooperation is also common. The freedom of reconfiguration and expansion is low, and the development cycle is particularly long. When it is necessary to change or add new messages, the BSW update cycle is long and the cost is high.

[0010] 2. Since the message cycle and type (periodic type, event type, etc.) are controlled by BSW, the sending of multi-packet messages can only be implemented by the underlying software, which makes the team focused on application software development subject to the underlying software suppliers.

[0011] 3. Due to controller resource limitations, the total number of messages it sends and receives is limited. As long as the new messages exceed this limit, the controller must be replaced. Summary of the invention

[0012] The purpose of the present invention is to solve the deficiencies of the above-mentioned background technology and to provide a method, electronic device and storage medium for dynamically adjusting ECU message reception and transmission.

[0013] The technical solution adopted by the present invention is: a method for dynamically adjusting ECU receiving and sending messages, including a message change process based on application software: the basic software configures the configuration information of the underlying receiving / sending messages to be defined by application software assignment, and when receiving / sending messages, the application software re-assigns values ​​to realize the receiving / sending information by changing the message ID.

[0014] Furthermore, it also includes a multi-packet message sending process based on application software:

[0015] The application software defines the configuration information of a certain sending interface of the basic software according to TP.CM_VN, and sends a frame of announcement message TP.CM_VN through this interface;

[0016] Assume that the sending cycle of the data message TP.DT_VN is T. After sending the announcement message TP.CM_VN Tx time, the configuration information of the same sending interface is defined according to TP.DT_VN, and the first frame of TP.DT_VN is sent, and then each subsequent frame of TP.DT_VN is sent in sequence every T time; thus, a group of multi-frame data of the announcement message TP.CM_VN and the data message TP.DT_VN based on the variable message ID is sent;

[0017] Repeat the above process to complete the sending of periodic multi-packet messages.

[0018] Furthermore, the multi-packet message sending is to pack, reassemble, connect, manage and transmit the parameter groups whose data length is greater than 8 bytes.

[0019] Furthermore, the value of x is T / 10.

[0020] Furthermore, the configuration information includes message ID, period, length, sending mode, enable, and message content.

[0021] Furthermore, it also includes a multi-group message receiving and sending process based on a single receiving / transmitting interface of the basic software: when the increased number of received / transmitted messages exceeds the number of reserved ports of the basic software, a priority-based sequential receiving / transmitting method is adopted to enable one reserved interface to receive / send multiple different message contents.

[0022] Furthermore, the priority-based sequential receiving / sending method is as follows:

[0023] Initially, receive / send message A of the first cycle;

[0024] After the first set time, receive / send message B of the second cycle;

[0025] After the second set time, receive / send message C of the third cycle;

[0026] Repeat the above process to receive / send multiple different message contents.

[0027] Furthermore, the first set time and the second set time are both 10 ms.

[0028] An electronic device comprising

[0029] A memory for storing one or more programs;

[0030] processor;

[0031] When the one or more programs are executed by the processor, any of the above methods is implemented.

[0032] A computer-readable storage medium stores a computer program, wherein the computer program implements any of the above methods when executed by a processor.

[0033] The beneficial effects of the present invention are:

[0034] 1. The present invention reassigns the message ID, message period, message length, and trigger form of the sent and received messages defined by BSW through ASW, so that the message change can be achieved only by configuring ASW, so that the message sending and receiving design is no longer subject to multiple organizations or suppliers, and has stronger versatility.

[0035] 2. The multi-packet message sending method based on ASW of the present invention enables the sub-packet sending that originally strongly depends on BSW to be directly implemented through ASW, which is simpler and faster.

[0036] 3. The present invention is based on the sending of multiple groups of messages multiplexed by a single BSW interface, and realizes the sending of multiple message data through an underlying configuration port Ax, thereby expanding the situation where the total number of received / sent messages is limited due to controller resource limitations. When the controller reaches a bottleneck in sending and receiving messages, the number of messages that the system can send and receive can be expanded again. BRIEF DESCRIPTION OF THE DRAWINGS

[0037] Figure 1 It is a flow chart of the present invention. DETAILED DESCRIPTION

[0038] The specific embodiments of the present invention are further described below in conjunction with the accompanying drawings. It should be noted that the description of these embodiments is used to help understand the present invention, but does not constitute a limitation of the present invention. In addition, the technical features involved in the various embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.

[0039] like Figure 1 As shown, the present invention provides a method for dynamically adjusting the ECU to send and receive messages. The basic software configures the message ID, message period, message length, message enable and other information in the original underlying message receiving / sending configuration information Ax to be assigned values ​​through application software variables. When sending and receiving messages, the message ID and other information in the underlying configuration information Ax are redefined by the application software, and then the dynamic adjustment technology is used to change the definition of the receiving / sending message through the application software, send multi-packet messages based on the application software, and expand the total number of sent and received messages based on dynamic adjustment. The specific process is as follows:

[0040] Step 1: The basic software configures the configuration information of the underlying message receiving / sending (message ID, period, length, sending mode, enable, and message content of Ax) to be defined by the application software.

[0041] Example of original BSW configuration message information definition:

[0042] ConfigRxMsgC(0x0CFE6CEE,50,8,TT_CYCLIC,1,(uint32_t*)&gMSG_TCO1,...);

[0043] Message ID: 0x0CFE6CEE

[0044] Message period: 50

[0045] Message length: 8

[0046] Send method: TT_CYCLIC

[0047] Enable: 1

[0048] Message content: (uint32_t*)&gMSG_TCO1,...

[0049] The present invention defines an example through ASW message information:

[0050] ConfigRxMsgC(MSG_ID MSG_CycleTime,MSG_BitLength,Msg_SendType,MSG_Enable,(uint32_t*)&gMSG_Name,...);

[0051] Message ID:MSG_ID

[0052] Message cycle: MSG_CycleTime

[0053] Message length: MSG_BitLength

[0054] Sending method: Msg_SendType

[0055] Enable: MSG_Enable

[0056] Message content: (uint32_t*)&gMSG_Name.

[0057] Among them, the specific message information originally defined in BSW is changed to be assigned in the application software (such as the message cycle, changed from the original 50 to MSG_CycleTime, and then assigned in the application software), that is, the relevant definitions of the original sending and receiving messages are designed to be configurable.

[0058] Step 2: Based on the application software configuration of the message information, the configuration information of the message definition in the Ax information of the original underlying message definition is assigned in the application software, including:

[0059] Message ID:MSG_ID

[0060] Message cycle: MSG_CycleTime

[0061] Message length: MSG_BitLength

[0062] Sending method: Msg_SendType

[0063] Enable: MSG_Enable

[0064] Message content: (uint32_t*)&gMSG_Name.

[0065] Taking A1 as an example, the original message receiving / sending definition is:

[0066] Message ID:MSG_ID1

[0067] Message cycle: MSG_CycleTime1

[0068] Message length: MSG_BitLength1

[0069] Sending method: Msg_SendType1

[0070] Enable: MSG_Enable1

[0071] Message content: (uint32_t*)&gMSG_Name1.

[0072] Through the above steps 1 and 2, without changing the BSW configuration information of the receiving / sending message, the configuration information of the receiving message can be changed by re-assigning the above message definition information through the ASW application software. That is, the Ax (A1, A2...) information that needs to be defined in the basic software and the Bx (B1, B2...) information that needs to be defined in the application software can be unified into the configuration in the application software.

[0073] The above-mentioned technology realizes that when adding or changing receiving / sending messages, BSW supplier support is no longer required.

[0074] Step 3: Send multi-packet messages based on ASW.

[0075] Taking a multi-packet message as an example, the existing technology is to configure two messages

[0076] ConfigRxMsgC(0xxxxxxxxx 1000,8,TT_CYCLIC,1,

[0077] (uint32_t*)&gMSG_TP.CM_VN,...);

[0078] ConfigRxMsgC(0xxxxxxxxy,150,8,TT_CYCLIC,1,

[0079] (uint32_t*)&gMSG_TP.DT_VN,...);

[0080] Then send the message TP.CM_VN in time sequence respectively, send TP.DT_VN1.data1-7 as event-type message after 150-x ms, send TP.DT_VN2.data8-14 as event-type message after 300-x ms, and send TP.DT_VN3.data15-17 as event-type message after 450-x ms.

[0081] x represents the earlier time, that is, the message ID, cycle, length, sending mode, enable, and message content are switched in advance so that the message is filled with the new content before it is sent.

[0082] The present invention only needs a reserved sending port of BSW to realize the sending of multi-packet messages. Multi-packet messages are used to package, reorganize, connect, manage and transmit data of parameter groups with data length greater than 8 bytes to realize multi-packet transmission. The multi-packet message contains two parts, one announcement message TP.CM, which feedbacks the parameter group number, message size, and the number of unpacked data packets; and one data message TP.DT, which is specifically:

[0083] Step 1), the application software first defines the configuration information of a certain sending interface of the basic software according to TP.CM_VN, and sends a frame of announcement message TP.CM_VN data through this interface.

[0084] In this step, the basic software makes the underlying configuration information configurable according to step 1, as shown in Table 1: ASW and BSW configuration relationship table, and the application software redefines the basic software Acm① with the configuration information Bcm①;

[0085] In subsequent embodiments, the basic software and application software steps involved in dynamically adjusting the ECU's message sending and receiving processes are the same as described above.

[0086] Step 2), assuming that the sending period of the data message TP.DT_VN is T, then after sending the announcement message TP.CM_VN Tx time, the value of x is T / 10, the configuration information of the same sending interface is defined according to TP.DT_VN, and the first frame of TP.DT_VN is sent at time T, and then each subsequent frame of TP.DT_VN is sent in sequence every T time; thus completing the sending of a group of multi-frame data of the announcement message TP.CM_VN and the data message TP.DT_VN based on the variable message ID;

[0087] The significance of Tx is to re-assign the basic software message definition a certain time in advance, that is, it must be ensured that when the basic software sends the next frame data, the message ID, message period, and message length of the sending interface have been switched.

[0088] Step 3), after reaching the sending cycle of the announcement message TP.CM_VN, repeat steps 1) and 2) to send a new packet of messages, that is, complete the sending of periodic multi-packet messages.

[0089] If the above T is 50ms, the value of x is 5ms, and the announcement message TP.CM_VN is sent at the initial time. After 45ms, the configuration information of the same sending interface is defined according to TP.DT_VN, and the first frame data TP.DT_VN1.data1-7 of TP.DT_VN is sent. After 95ms, the second frame data TP.DT_VN1.data8-14 of TP.DT_VN is sent. After 145ms, the third frame data TP.DT_VN1.data15-17 of TP.DT_VN is sent.

[0090] Step 4: Receive / send multiple groups of message data based on the BSW single receive / send interface.

[0091] In the existing technology, when new receive / transmit messages are needed, the BSW software supplier needs to expand the adapter B1 configuration; when the total number of configured receive / transmit messages exceeds the controller resource limit, the number of receive / transmit messages must be expanded by replacing the controller hardware.

[0092] The present invention dynamically plans the receiving / sending messages, and can realize the receiving / sending of multiple groups of message data on the original single receiving / sending interface of the BSW.

[0093] When the number of currently increased received and sent messages is far greater than the reserved port of BSW, a priority-based sequential receiving and sending strategy is adopted to implement a reserved interface to receive and send multiple different message contents.

[0094] To extend the sending of messages with a period of 100ms, 500ms, and 1000ms, the dynamic adjustment sending strategy is as follows:

[0095] Initially, message A is sent with a period of 100ms;

[0096] After 10ms, message B is sent with a period of 500ms;

[0097] After 20ms, send message C with a period of 1000ms;

[0098]

[0099] In the above process, BSW (basic software) only needs to provide a message index interface compared with before;

[0100] ASW (application software) changes ID and performs cycle control according to the above logic, and calls and sends specified data at the corresponding time.

[0101] The present invention also provides an electronic device, including a memory and a processor, wherein the memory is used to store one or more programs; when the one or more programs are executed by the processor, the method for sending and receiving messages as described above is implemented.

[0102] The present invention also provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method and embodiment for sending and receiving messages are implemented.

[0103] Those skilled in the art may also understand that the various illustrative logical blocks, units, and steps listed in the embodiments of the present invention may be implemented by electronic hardware, computer software, or a combination of the two. In order to clearly demonstrate the interchangeability of hardware and software, the various illustrative components, units, and steps described above have generally described their functions. Whether such functions are implemented by hardware or software depends on the specific application and the design requirements of the entire system. Those skilled in the art may use various methods to implement the described functions for each specific application, but such implementation should not be understood as exceeding the scope of protection of the embodiments of the present invention.

[0104] The various illustrative logic blocks or units described in the embodiments of the present invention can be implemented or operated by a general-purpose processor, a digital signal processor, an application-specific integrated circuit (ASIC), a field programmable gate array or other programmable logic device, a discrete gate or transistor logic, a discrete hardware component, or any combination of the above. The general-purpose processor can be a microprocessor, and optionally, the general-purpose processor can also be any conventional processor, controller, microcontroller or state machine. The processor can also be implemented by a combination of computing devices, such as a digital signal processor and a microprocessor, a plurality of microprocessors, one or more microprocessors combined with a digital signal processor core, or any other similar configuration.

[0105] It should be understood that the specific order or hierarchy of steps in the disclosed process is an example of an exemplary method. Based on design preferences, it should be understood that the specific order or hierarchy of steps in the process can be rearranged without departing from the scope of protection of the present disclosure. The attached method claims present the elements of the various steps in an exemplary order and are not intended to be limited to the specific order or hierarchy described.

[0106] In order to make the description of the present disclosure more detailed and complete, the above description is provided for the implementation and specific embodiments of the present invention; however, this is not the only form of implementing or using the specific embodiments of the present invention. The implementation covers the features of multiple specific embodiments and the method steps and sequences used to construct and operate these specific embodiments. However, other specific embodiments can also be used to achieve the same or equivalent functions and step sequences.

[0107] In the above detailed description, various features are grouped together in a single embodiment to simplify the disclosure. This method of disclosure should not be interpreted as reflecting an intention that the embodiments of the claimed subject matter require more features than are clearly stated in each claim. On the contrary, as reflected in the appended claims, the invention is in a state of having less than all the features of the disclosed individual embodiments. Therefore, the appended claims are hereby expressly incorporated into the detailed description, with each claim standing on its own as a separate preferred embodiment of the invention.

[0108] The above are only specific embodiments of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed by the present invention should be included in the protection scope of the present invention. The contents not described in detail in this specification belong to the prior art known to professional and technical personnel in the field.

Claims

1. A method for dynamically adjusting ECU sending and receiving messages, Features: Including the message change process based on application software: the basic software configures the configuration information of the underlying receiving / sending messages to be defined by the application software. When receiving / sending messages, the application software re-assigns the values ​​to realize the receiving / sending of information by changing the message ID; It also includes a multi-packet message sending process based on application software, wherein the multi-packet message sending is to package, reorganize, connect, manage, and transmit data for parameter groups with a data length greater than 8 bytes: The application software defines the configuration information of a certain sending interface of the basic software according to TP.CM_VN, and sends a frame of announcement message TP.CM_VN through this interface; Assuming that the sending period of the data message TP.DT_VN is T, after sending the announcement message TP.CM_VN Tx time, the value of x is T / 10, the configuration information of the same sending interface is defined according to TP.DT_VN, and the first frame of data of TP.DT_VN is sent, and then each subsequent frame of data of TP.DT_VN is sent in sequence every T time; thus completing the sending of a group of multi-frame data of the announcement message TP.CM_VN and the data message TP.DT_VN based on the variable message ID; Repeat the above process to complete the sending of periodic multi-packet messages.

2. The method for dynamically adjusting ECU message reception and transmission according to claim 1, Features: The configuration information includes message ID, period, length, sending mode, enable, and message content.

3. The method for dynamically adjusting ECU message reception and transmission according to claim 1, Features: It also includes a multi-group message receiving and sending process based on a single receiving / transmitting interface of the basic software: when the number of increased receiving / transmitting messages exceeds the number of reserved ports, a priority-based sequential receiving / transmitting method is adopted to enable one reserved interface to receive / transmit multiple different message contents.

4. The method for dynamically adjusting ECU message reception and transmission according to claim 3, Features: The priority-based time-sequenced receiving / sending method is as follows: Initially, the first cycle message A is received / sent; After the first set time, receive / send message B of the second cycle; After the second set time, the message C of the third cycle is received / sent; Repeat the above process to receive / send multiple different message contents.

5. The method for dynamically adjusting ECU message reception and transmission according to claim 4, Features: The first set time and the second set time are both 10 ms.

6. An electronic device, Features: include A memory for storing one or more programs; processor; When the one or more programs are executed by the processor, the method according to any one of claims 1 to 5 is implemented.

7. A computer-readable storage medium having a computer program stored thereon, Features: When the computer program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.

Citation Information

Patent Citations

  • Automatic generation method and system of CAN signal interface software and vehicle

    CN108345288A

  • Fault processing and diagnosis control strategy suitable for new energy automobile

    CN112650203A