Electronic controller and electronic control method

A shared buffer system for vehicle control systems addresses the inefficiency in buffer allocation by optimizing memory usage, reducing overall buffer consumption and enhancing data communication efficiency.

JP2024154992APending Publication Date: 2024-10-31NISSAN MOTOR CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
JP2023069285
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Filing Date
2023-04-20
Publication Date
2024-10-31

AI Technical Summary

Technical Problem

The existing vehicle control systems face an increase in buffer consumption due to the provision of dedicated buffers for each communication path between domain control unit applications, leading to inefficient use of memory resources.

Method used

Implementing a shared buffer system that stores both first and second data transmitted and received between SW-C ports, allowing for efficient data communication by sharing a single memory area for multiple data transfers.

Benefits of technology

This approach reduces the overall consumption of buffers by optimizing memory usage, thereby enhancing the efficiency of data transmission and reception processes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2024154992000001_ABST
    Figure 2024154992000001_ABST
Patent Text Reader

Abstract

To provide an electronic controller which can suppress power consumption of a buffer which stores data for communication.SOLUTION: An electronic controller 100 includes a plurality of SW-Cs 1 to 3, an RTE 4, and a memory 5. The memory 5 is a shared buffer functioning as a buffer for storing first data transmitted / received between a transmitting port 11 of the SW-C 1 and a receiving port 21 of the SW-C 2, and a buffer for storing second data transmitted / received between a transmitting port 12 of the SW-C 2 and a receiving port 22 of the SW-C 2.SELECTED DRAWING: Figure 1
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present invention relates to an electronic control device and an electronic control method. [Background technology]

[0002] For example, the vehicle control system described in Patent Document 1 has a cooperative control execution management unit that manages the execution of cooperative control. This cooperative control execution management unit includes a storage unit that stores, for each of a plurality of cooperative controls, individual controls that are individually executed by a plurality of domain control unit applications, and information regarding the data input / output relationship between the individual controls. The storage unit stores information regarding the data input / output relationship between the individual controls. In addition, the RTE provides communication between the domain control unit applications. [Prior art documents] [Patent documents]

[0003] [Patent Document 1] JP 2018-085686 A Summary of the Invention [Problem to be solved by the invention]

[0004] However, in the above vehicle control system, when multiple domain control unit applications transmit and receive data to each other to perform multiple cooperative controls, a buffer for saving data communicated by the RTE is provided in the recording unit. In this case, if a dedicated buffer is provided for each communication path between the domain control unit applications, there is a problem that the amount of buffer space used to store communication data increases.

[0005] An object of the present invention is to provide an electronic control device and an electronic control method capable of suppressing consumption of a buffer that stores data for communication. [Means for solving the problem]

[0006] The present invention solves the above problem by sharing a buffer that stores first data transmitted and received between the transmitting port of SW-C and the receiving port of SW-C, and a buffer that stores second data transmitted and received between the transmitting port of SW-C and the receiving port of SW-C. Effect of the Invention

[0007] The present invention can reduce the consumption of the buffer used for communication. [Brief description of the drawings]

[0008] [Figure 1] FIG. 1 is a schematic diagram of the software structure of an electronic control device according to this embodiment. [Diagram 2] FIG. 2 is a schematic diagram of Rannnabl. [Diagram 3] Figure 3 is a conceptual diagram of a task. [Figure 4] FIG. 4 is a schematic diagram of a software structure of an electronic control device according to a comparative example. [Diagram 5] FIG. 5 is a schematic diagram of a software structure of an electronic control device according to a modified example. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0009] DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS Hereinafter, an embodiment of an electronic control device and an electronic control method according to the present invention will be described with reference to the drawings.

[0010] 1 is a schematic diagram of the software structure of an electronic control device 100 according to this embodiment. The electronic control device 100 is an electronic control unit (ECU) mounted on a vehicle, and is a controller that controls the load of the vehicle. A vehicle is equipped with several hundred electronic control devices 100, and each electronic control device 100 controls various functions of the vehicle, such as the control of the drive system of the vehicle and the control of auxiliary systems such as lights.

[0011] As shown in Fig. 1, the electronic control device 100 has a software structure that complies with Autosar (AUTomotive Open System Architecture). The electronic control device 100 includes a plurality of software components (SW-C) 1 to 3, a runtime environment (RTE) 4 that connects the plurality of SW-Cs, and a memory 5 provided on the RTE 4. The plurality of SW-Cs 1 to 3 are provided in an application layer. The software sub-structure of the electronic control device 100 includes a BSW layer (Basic Software) in addition to the application layer and RTE 4 (RTE layer). The BSW layer includes basic software modules and the like, which are not shown in Fig. 1.

[0012] SW-C1 to 3 are processing programs (applications) that cause the electronic control device 100 to execute functions (control processing). SW-C1 to 3 are executed by hardware included in the electronic control device 100, and obtain data from other applications and perform data processing. As applications have become more complex in recent years, the number of SW-C1 to 3 included in the application layer has reached several hundred or more. Note that, although the example in FIG. 1 illustrates three SW-C1 to 3 out of several hundred or more SW-C, the electronic control device 100 has four or more SW-C.

[0013] SW-C1 includes a transmission port 11, SW-C2 includes a transmission port 11 and a reception port 21, and SW-C3 includes a reception port 22. The transmission port 11 and the reception port 21 are connected via a memory 5 on the RTE, and the transmission port 12 and the reception port 22 are connected via the memory 5. SW-C1 to 3 are connected in a daisy chain. The transmission port 11 and the reception port 21 are grouped as a sender / receiver port for data (hereinafter also referred to as first data) transmitted and received between the transmission port 11 of SW-C1 and the reception port 21 of SW-C2. The transmission port 12 and the reception port 22 are grouped as a sender / receiver port for data (hereinafter also referred to as second data) transmitted and received between the transmission port 12 of SW-C2 and the reception port 22 of SW-C3. The transmitting ports 11, 12 correspond to the "first and second transmitting ports" of the present invention, and the receiving ports 21, 22 correspond to the "first and second receiving ports" of the present invention.

[0014] REC4 is an interface layer for communication that connects SW-C1 to 3, and realizes communication between multiple SW-C1 to 3 and between SW-C1 to 3 and BSW. The communication is data communication and API call. In AUTOSAR, communication between multiple SW-C1 to 3 is performed through RTE4, and communication between SW-C and BSW is also performed through RTE4. REC4 has memory 5 for communication between multiple SW-C1 to 3. When communicating data between SW-C1 and SW-C2, REC4 selects transmission port 11 and reception port 21, and when communicating data between SW-C2 and SW-C3, REC4 selects transmission port 12 and reception port 22. Memory 5 is provided on RTE4, and is a buffer (RAM) that stores data transmitted and received between SW-C1 to 3.

[0015] When the number of SW-C1 to 3 included in the electronic control device 100 increases, the amount of data transmitted and received in the communication between SW-C and the number of communications increases. REC4 secures a communication buffer in the memory 5 to realize data transmission and reception, but when the amount of communicated data increases, the amount of communication buffer consumed also increases. The memory 5 is a shared buffer that shares a buffer for storing the first data and a buffer for storing the second data. In other words, the memory 5 is allocated to an area for temporarily storing (holding) data transmitted and received between SW-C1 and SW-C2 and an area for temporarily storing data transmitted and received between SW-C2 and SW-C3 in the same area. The shared buffer of the memory 5 can store either the first data or the second data, but does not store both the first data and the second data. The storage capacity of the shared buffer of the memory 5 is equal to or greater than the larger of the maximum capacity of the first data and the maximum capacity of the second data, and is less than the total data capacity of the maximum capacity of the first data and the maximum capacity of the second data. In other words, the memory 5 has a capacity capable of storing the larger of the amounts of data transmitted and received between the pairs of SW-C1 to SW-C3.

[0016] Next, a description will be given of a method for transmitting and receiving data (electronic control method) between a plurality of SW-C1 to 3. Among the plurality of SW-C included in the electronic control device 100, SW-C1 to 3 are connected in a daisy chain via a shared buffer, and perform data communication that satisfies the following conditions (1) and (2). (1) Sending and receiving data between SW-C1 and SW-C2, and sending and receiving data between SW-C2 and SW-C3 (2) Data updating (storage) in the shared buffer of memory 5 is performed in the order of the first data and then the second data.

[0017] Communications that satisfy conditions (1, 2) are performed in cases where data is communicated serially in a single pipeline process according to the processing order defined by AUTOSAR (hereinafter also referred to as case A), or in cases where data necessary for abnormality diagnosis of the electronic control device 100, such as diagnostic commands, is transferred (hereinafter also referred to as case B).

[0018] As an example of case A, the electronic control unit 100 executes the following control flow as a control process for determining whether the vehicle is stopped or not. Step S1: SW-C1 outputs vehicle speed data to SW-C2. Step S2: SW-C2 performs a process of judging whether the vehicle speed is 0 or greater than 0 based on the vehicle speed data, and outputs judgment result data indicating the judgment result by "0" or "1" to SW-C3. Step S3: The judgment result data is input to the SW-C3, and if the judgment result is "0", the SW-C3 judges that the vehicle is stopped, and if the judgment result is "1", it judges that the vehicle is not stopped.

[0019] In one example of the above-mentioned case A, in step S1, vehicle speed data is recorded in the shared buffer of memory 5. When SW-C2 executes the process of step S2, the vehicle speed data recorded in the shared buffer is input from the receiving port 21, and after the vehicle speed determination process, the determination result data is output from the transmitting port 12 and recorded in the shared buffer. In other words, since the vehicle speed data recorded in the shared buffer becomes unnecessary after the process by SW-C2, the data transfer buffer in memory 5 is shared and used for transferring the determination result data. This makes it possible to reduce the consumption of the data transfer buffer.

[0020] Additionally, the diagnostic commands in Case B are specified by USD (Unified Diagnostic Service), and multiple diagnostic commands are not executed simultaneously during ECU abnormality diagnosis. The diagnostic commands are sent from SW-C1 to SW-C2, and then from SW-C2 to SW-C3, so the buffer used to transfer diagnostic commands can be shared. This makes it possible to reduce the consumption of buffers for data transfer.

[0021] The electronic control device 100 realizes various processes using tasks, and Rannables (Rannable interfaces) are assigned to the tasks. Rannables indicate processing units, and are indicated by the processing order, data input / output ports, data size of data transmitted and received, etc. FIG. 2 is a conceptual diagram (table) of Rannables. In Rannable A, a process is executed in which "2 bytes of data (first data) are output from the transmitting port 11." In Rannable B, a process is executed in which "data is input from the receiving port 21, and 4 bytes of data (second data) are output from the transmitting port 12." In Rannable C, a process is executed in which "data is input from the receiving port 22."

[0022] Fig. 3 is a conceptual diagram of a task. In order to make the execution priority of Runnables the same, the electronic control unit 100 assigns execution to the same task, and executes Rannables in the order defined within the task. In the example of Fig. 3, in TASK D, Rannable A, Rannable B, and Rannable C are executed in that order.

[0023] Specifically, SW-C1 executes Rannable A. The first data is recorded in the shared buffer of memory 5. SW-C2 executes Rannable B, triggered by the recording of the first data. The second data is recorded in the shared buffer of memory 5. In other words, the first data recorded in the shared buffer is overwritten with the second data, thereby updating the shared buffer. SW-C3 executes Rannable C, triggered by the recording of the second data. In this way, in communication between multiple SW-C1 to 3 connected in a daisy chain, the data update order of the shared buffer is determined, and the transfer buffer for input / output data (first and second data) is shared in the same memory. Furthermore, data transmitted and received at different ports may be of different sizes.

[0024] When transmitting and receiving data between SW-C1 to 3, memory sharing code (union) may be used to share a buffer in memory 5. The union is included in the program for executing Random Blocks A to C, and is code for sharing the storage areas of the first data and the second data in memory 5.

[0025] Next, the consumption of the shared buffer will be described in comparison with the memories 51 and 52 of the battery control device according to the comparative example. FIG. 4 is a schematic diagram of the software structure of the electronic control device 100 according to the comparative example. As shown in FIG. 4, the memories 51 and 52 on the RTE 4 are not shared buffers, and the memory 51 is a buffer that stores the first data and is allocated as an area for storing data transmitted and received between SW-C1 and SW-C2. The memory 52 is a buffer that stores the second data and is allocated as an area for storing data transmitted and received between SW-C2 and SW-C3. The storage capacity of the memory 51 is the maximum capacity of the first data, and the storage capacity of the memory 52 is the maximum capacity of the second data. For example, if the maximum capacity of the first data is 384 bytes, a buffer with a storage capacity of at least 384 bytes is used for the memory 51. Also, for example, if the maximum capacity of the second data is 512 bytes, a buffer with a storage capacity of at least 512 bytes is used for the memory 52. In the communications between the plurality of SW-C1 to 3, the amount of buffer space consumed for storing data is 864 bytes, which is the total storage capacity of the memory 51 and the memory 52.

[0026] On the other hand, in this embodiment, the memory 5 is a shared buffer that stores the first data and the second data, so the capacity (512 bytes) that can store the first data with the larger maximum capacity is set as the storage capacity. In other words, in this embodiment, the consumption amount can be reduced by 384 bytes compared to the comparative example. Note that the capacity of the memory for vehicle use is several hundred Kbytes to several Mbytes, so the reduction amount of 384 bytes is quite effective.

[0027] As described above, the electronic control device 100 according to this embodiment includes a plurality of SW-C1 to 3, an RTE 4, and a memory 5. The memory 5 is a shared buffer that serves as both a buffer for storing the first data transmitted and received between the transmission port 11 of SW-C1 and the reception port 21 of SW-C2, and a buffer for storing the second data transmitted and received between the transmission port 12 of SW-C2 and the reception port 22 of SW-C2, and records either the first data or the second data. This makes it possible to reduce the consumption of the buffer used for communication.

[0028] Moreover, the electronic control method according to this embodiment is a method for transmitting and receiving data between a plurality of SW-C1 to 3, in which electronic control device 100 includes a shared buffer that shares a buffer for storing first data and a buffer for storing second data, outputs the first data from transmission port 11, and after the first data is recorded in the shared buffer of memory 5, inputs the first data from reception port 21, outputs second data from transmission port 12 after the first data is input, and after the second data is recorded in the shared buffer of memory 5, inputs the second data from second reception port 22. This makes it possible to reduce the consumption of the buffer used for communication.

[0029] In the electronic control device 100 according to this embodiment, the transmitting port 11 and the receiving port 21 are grouped as a port for the first data communication, and the transmitting port 12 and the receiving port 22 are grouped as a port for the second data communication, thereby reducing the consumption of the buffer used for communication.

[0030] In the electronic control device 100 according to this embodiment, the RTE 4 selects the transmission port 11 and the reception port 21 to execute the first data communication, and selects the transmission port 12 and the reception port 22 to execute the second data communication. This makes it possible to suppress the consumption of the buffer used for communication.

[0031] In the electronic control device 100 according to the present embodiment, the memory 5 stores the first data in a shared buffer and updates the shared buffer by overwriting the first data stored in the shared buffer with the second data. This makes it possible to reduce the consumption of the buffer used for communication.

[0032] In the electronic control device 100 according to this embodiment, the recording capacity of the shared buffer of the memory 5 is equal to or larger than the maximum capacity of the first data and the maximum capacity of the second data, but is smaller than the total data capacity of the maximum capacity of the first data and the maximum capacity of the second data. This makes it possible to reduce the consumption of the buffer used for communication.

[0033] The electronic control device 100 according to the modification of the present embodiment may have a plurality of SW-C1 to 3 connected in a daisy chain. FIG. 5 is a schematic diagram of a software structure of the electronic control device 100 according to the modification. As shown in FIG. 5, the electronic control device 100 has an SW-C group 31 in which three SW-C1 to 3 are connected in a daisy chain, and an SW-C group 32 having a similar configuration to the SW-C group 31. The SW-C group 31 includes a memory 5 that stores data transmitted and received within the SW-C group 31. The SW-C group 32 includes a memory 5 that stores data transmitted and received within the SW-C group 32. The memory 5 is a shared buffer that shares a buffer that stores the first data and a buffer that stores data transmitted and received within the SW-C group 32, and is provided for each SW-C group. This makes it possible to suppress the consumption of the buffer used for communication.

[0034] In this embodiment including the modified example, three SW-C1 to 3 are connected in a daisy chain, but four or more SW-C1 to 3 may be connected in a daisy chain. The memory 5 may be a shared buffer that stores data transmitted and received within the four or more SW-C1 to 3. [Explanation of symbols]

[0035] 1~3 Software Component (SW-C) 4 Runtime Environment (RTE) 5. Memory 11, 12 Outbound ports 21, 22 Receiving ports 31, 32 SW-C Group 100 Electronic control device

Claims

1. A plurality of software components (SW-C); A runtime environment (RTE) that connects the plurality of SW-Cs; A memory provided on the RTE; The plurality of SW-Cs include A first SW-C including a first transmission port, a second SW-C including a first reception port and a second transmission port, and a third SW-C including a second reception port; The memory includes: a shared buffer that serves as a buffer for storing first data transmitted and received between the first transmitting port and the second receiving port, and a buffer for storing second data transmitted and received between the second transmitting port and the second receiving port; an electronic control device that records either the first data or the second data;

2. 2. The electronic control device according to claim 1, the first transmitting port and the first receiving port are grouped as a port for communication of the first data; An electronic control device, wherein the second transmitting port and the second receiving port are grouped as a port for communication of the second data.

3. 3. The electronic control device according to claim 1, The plurality of SW-Cs include A plurality of SW-C groups are provided in which three or more SW-Cs are connected in a daisy chain; The memory is an electronic control device provided for each SW-C group as the shared buffer for storing data transmitted and received within the SW-C group.

4. 3. The electronic control device according to claim 1, The RTE is selecting the first transmitting port and the first receiving port to perform communication of the first data; An electronic control device that selects the second transmitting port and the second receiving port to perform communication of the second data.

5. 3. The electronic control device according to claim 1, The memory includes: storing the first data in the shared buffer; an electronic control device that overwrites the first data stored in the shared buffer with the second data to update the shared buffer;

6. 3. The electronic control device according to claim 1, The recording capacity of the shared buffer is An electronic control device having a data capacity equal to or larger than the larger of the maximum capacity of the first data and the maximum capacity of the second data, and smaller than the total data capacity of the maximum capacity of the first data and the maximum capacity of the second data.

7. An electronic control method executed by an electronic control device to transmit and receive data between a plurality of software components (SW-C), The electronic control device includes: a shared buffer that serves as both a buffer for storing first data transmitted and received between a first transmission port included in a first SW-C and a first reception port included in a second SW-C, and a buffer for storing second data transmitted and received between a second transmission port included in the second SW-C and a second reception port included in a third SW-C; outputting the first data from the first transmission port; inputting the first data from the first receiving port after the first data is recorded in the shared buffer, and outputting the second data from the second transmitting port after the first data is input; The electronic control method further comprises inputting the second data from the second receiving port after the second data has been recorded in the shared buffer.

Citation Information

Patent Citations

  • Vehicular control system

    JP2018085686A