Method for controlling an engine control unit having a multi-core processor

By decomposing cyclic tasks into parent and sub-type subtasks and allocating them among multi-core microprocessors, the operation delay and safety problems of the engine control unit under multi-core microprocessors are solved, and more efficient and reliable engine control is achieved. Especially for safety and precision in cyclic operation at high rotational speeds.

CN113302592BActive Publication Date: 2024-08-23VTESCO TECH GMBH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201980082396.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2018-12-12
Filing Date
2019-12-12
Publication Date
2024-08-23
Estimated Expiration
2039-12-12

AI Technical Summary

Technical Problem

When existing engine control units use multi-core microprocessors, it is difficult to make full use of parallel processing capabilities, resulting in operational delays, and it is difficult to ensure safety and reliability under high-frequency operations, especially when cyclic operations are performed at high engine speeds. Fault.

Method used

By decomposing cyclic tasks into parent subtasks and subtype subtasks, and distributing the computing load among multi-core microprocessors, utilizing available computing resources, ensuring safe execution and balance of tasks, identifying and avoiding conflicts during task overlap, Dynamically adjust the execution order of executable files to avoid failures.

Benefits of technology

Faster and more powerful processing capabilities are achieved, the reliability and accuracy of the engine control unit are improved, faults related to task overlap are avoided, and optimal control of fuel injection and effective management of polluting products are ensured.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113302592B_ABST
    Figure CN113302592B_ABST
Patent Text Reader

Abstract

A method for controlling an engine control unit, the engine control unit comprising at least two cores of a microprocessor, the method comprising the steps of executing a parent subtask (FA1, FB1) and at least one child subtask (FA2, FB2). The method comprises the following steps: - when the parent subtask (FB1) of the second cycle (9B) starts, determining the number of executable files (R) remaining to be executed in the last child subtask (FA2) of the first cycle (9A); - when the last child subtask (FA2) of the first cycle (9A) is completed, determining the number of executable files (R) that have been executed in the parent subtask (FB1) of the second cycle (9B).
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the automotive field and to the control of an engine control unit which operates an internal combustion engine of a motor vehicle. Background Art

[0002] Most current motor vehicles have an engine control unit, usually located under the hood. This engine control unit is connected to sensors making it possible to acquire information about the state of the engine (temperature, pressure, vibrations, position of various components, etc.). Taking into account the data collected by these sensors, the engine control unit operates the internal combustion engine by controlling actuators such as fuel injectors, possibly spark plugs, valves arranged in the various fluid circuits associated with the engine, etc. In order to ensure its functionality, the engine control unit comprises electronic means for processing information, such as a microprocessor.

[0003] Recent motor vehicles are equipped with an increasing number of sensors, and their engine control units are programmed to manipulate the sensors in an increasingly complex and sophisticated manner. As a result, the size of the engine control unit is generally increasing from the point of view of its computing power, that is to say from the point of view of the power of its microprocessor. In this context, recent research has led to the use of multi-core microprocessors in engine control units, i.e. microprocessors with multiple physical cores that operate simultaneously. Thus, multiple programs can be executed in parallel and independently of each other.

[0004] However, since the function of the engine control unit is to operate complex physical components (such as the internal combustion engine), its failure rate must be close to zero, because its failure will lead to malfunction, which may cause damage to the engine and safety problems for the vehicle passengers. Therefore, the reliability of the digital operations in the engine control unit is crucial. The use of the possibilities provided by multi-core microprocessors (parallel execution of multiple programs) can only be carried out if it is guaranteed that these possibilities do not lead to a loss of reliability. However, certain operations are particularly critical because they must be carried out at high frequencies. This is the case, for example, for cyclic operations calculated by the rotation of the engine at high engine speeds.

[0005] In the prior art, in order to make these operations safe, methods for controlling engine control units with multi-core microprocessors generally use the semaphore principle, i.e. when the executable file of a task reads or modifies a variable, it locks the variable so that other executable files cannot read or modify it at the same time. These methods are satisfactory from the point of view of security, but they lead to considerable delay times because the executable files are thus executed sequentially and they therefore do not fully exploit the parallel processing capabilities provided by the multi-core processor. Summary of the invention

[0006] The invention provides a method for controlling an engine control unit which enables safe operation when using at least two microprocessor cores.

[0007] To this end, the present invention relates to a method for controlling an engine control unit connected to sensors and actuators associated with an internal combustion engine of a vehicle, the engine control unit comprising at least two microprocessor cores, the control method comprising the step of executing a cyclic task, the execution of which is triggered by a recurring event, the recurring event being repeated with a period associated with engine rotation, the cyclic task consisting of an executable file divided into a parent sub-task and at least one child sub-task, wherein the parent sub-task is triggered by a recurring event and executed by one microprocessor core, and the child sub-task is executed by another microprocessor core after the parent sub-task.

[0008] The method comprises the following steps:

[0009] - when the parent sub-task of the second cycle starts, determining the number of executable files remaining to be executed in the last child sub-task of the first cycle;

[0010] - When the last child-type sub-task of the first cycle is completed, the number of executable files that have been executed in the parent-type sub-task of the second cycle is determined.

[0011] This method according to the invention is particularly advantageous for cyclic tasks calculated per engine revolution (that is, when the execution of such a cyclic task is triggered by an event that repeats with a period related to the engine revolution). Thus, the same cyclic task is repeated with a period that shortens as the engine speed increases. Thus, at high speeds, a new cycle of the cyclic task starts again very soon after the start of the previous task.

[0012] The method divides each task to be performed in a cycle into individual subtasks that are distributed on the various cores of the microprocessor. The division of tasks into subtasks makes it possible to distribute the computational load among the available microprocessor cores. This division is advantageous because it allows the use of all available computational means and allows faster and more powerful processing, as well as balancing the computational load between the various microprocessor cores.

[0013] The method allows the chaining of cyclic tasks to be safe. When the last child sub-task of a cycle ends and the parent sub-task of the next cycle begins, the method determines how many executable files in the child sub-task still need to be executed and the number of executable files in the parent sub-task that have been executed. Thus, the overlapping period between the last child sub-task and the parent sub-task of the next cycle is identified.

[0014] The method according to the invention allows the diagnosis of an engine control unit. Thus, the overlap of subtasks in the cyclic task chain can be studied at regular intervals or on time to identify executable files that conflict with each other during the overlap phase that has been identified. In particular, when a child subtask overlaps with a parent subtask of the next cycle, they may conflict if the executable files are executed at the same time. Executable files that may conflict are, for example, executable files that modify the same variable.

[0015] The method according to the invention also allows for safer partitioning of executables within the same task. Specifically, executables to be executed during task overlap are identified. Dynamically (during runtime) or statically (during maintenance), executables known to be concurrent can be shifted within a task to be executed outside of this overlap.

[0016] The method according to the invention therefore allows a better understanding of potential faults of the engine control unit and makes it possible to avoid these faults, in particular those related to the execution of concurrent executable files during overlapping time periods.

[0017] Thus, the engine control unit, as well as the engine itself, benefits from a more precise and reliable control. For example, if the parent task includes an executable file allowing calculation in which cylinder the next fuel injection must be performed, the engine control unit prevents the executable file of the child task executed during the overlap with the parent task of the next cycle from using an incorrect cylinder number with respect to the current cycle (which will be calculated by the new parent task). Thus, the injected amount of gasoline is optimal and the emission or consumption of polluting products is better controlled.

[0018] The method for controlling an engine control unit may have the following additional features, alone or in combination:

[0019] - after the step of determining the number of executable files remaining to be executed in the last sub-type secondary task of the first cycle, the method comprises the step of storing this number of executable files in a memory;

[0020] - after the step of determining the number of executable files that have been executed in the parent type subtask of the second cycle, the method comprises the step of storing this number of executable files in a memory;

[0021] - The number of executable files stored in the memory is further saved in the diagnostic memory;

[0022] - the method comprises a diagnostic step, which comprises reading a diagnostic memory;

[0023] - the step of determining the number of executable files remaining to be executed in the last sub-type sub-task of the first cycle comprises implementing an executable file counter of the sub-type sub-task;

[0024] - the initial value of the executable file counter of the sub-type sub-task corresponds to the total number of executable files in the sub-type sub-task, and the counter is decremented when each executable file of the sub-type sub-task is executed;

[0025] - the step of determining the number of executable files that have been executed in the parent sub-task of the second cycle comprises implementing an executable file counter of the parent sub-task;

[0026] - The executable counter of the parent subtask is initially set to zero and is incremented when each executable is executed. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] A preferred exemplary embodiment of the present invention will now be described with reference to the accompanying drawings, in which:

[0028] Figure 1 An engine control unit is shown which is capable of implementing the control method according to the invention.

[0029] Figure 2 is a diagram illustrating the concatenation of two cyclic tasks that do not have overlapping periods.

[0030] Figure 3 Similar to Figure 2 , and illustrates the case of task concatenation with overlapping cycles.

[0031] Figure 4 yes Figure 2 Detailed view of the .

[0032] Figure 5 yes Figure 3 Detailed view of the . DETAILED DESCRIPTION

[0033] Figure 1 An engine control unit 1 for operating an internal combustion engine of a motor vehicle is shown schematically.

[0034] The engine control unit 1 is connected to a series of sensors 3, such as position sensors, temperature sensors, pressure sensors, flow sensors, etc. The engine control unit 1 is also connected to control outputs 4, which can control actuators involved in operating the engine. These actuators are, for example, spark plugs, fuel injectors, valves, etc.

[0035] The engine control unit 1 is programmed in a known manner in order, on the one hand, to acquire the measured values ​​provided by the sensors 3 and, on the other hand, to control the actuators in order to ensure operation of the engine.

[0036] The engine control unit 1 comprises a microprocessor 2 which, in this example, is provided with two cores C1, C2. In addition to conventional elements such as random access memory, various buses (not shown) and the like which allow the microprocessor 2 to function, the unit 1 comprises a first executable file counter RTF and a second executable file counter RTM which are intended to implement the method described below. These executable file counters RTF and RTM are each associated with a memory 11, 12 of executable files. A diagnostic memory 13 makes it possible to save the memories 11, 12 of executable files.

[0037] Figure 2 A cyclic task running in the microprocessor 2 is shown.

[0038] The microprocessor 2 is a conventional multi-core microprocessor. The engine control unit 1 comprises an operating system suitable for implementing a computer program designed for the engine control unit 1. Thus, the microprocessor 2 is caused to execute tasks (tasks are also referred to as "execution threads") corresponding to the various functions implemented by the engine control unit 1. One of these tasks can be, for example, the control of the fuel injection sequence, the control of the spark plug ignition sequence or the opening of the control valve. Some of these tasks are cyclic and calculated per engine revolution; this is the case, for example, with the injection task and the ignition task. In these cases, the execution of the task is triggered by an event identified by one of the sensors 3, which event is associated with the engine revolution. For example, the fact that one of the engine's pistons reaches its top dead center or another predetermined position is an event that triggers the injection sequence of the fuel in the corresponding cylinder. Thus, these cyclic tasks are triggered by an event that is repeated with a period related to the engine speed. Thus, an increase in the engine's rotation speed leads to a reduction in the time that passes between two events.

[0039] exist Figure 2 , trigger event 14A is shown at the beginning of the diagram. This event 14A triggers task FA. Continuing with the example given above, event 14A is the presence of the piston of the engine at or near top dead center, and task FA is the task of injecting fuel into the corresponding cylinder. This event is cyclical in that it repeats in each rotation cycle of the engine (when the piston returns to the same position).

[0040] exist Figure 2 In the embodiment, event 14B corresponds to the same event that occurs during the next engine cycle. Thus, events 14A, 14B follow one another in a cycle 8A, 8B that depends on the engine rotation speed.

[0041] exist Figure 2 In the example of , the engine speed is constant and the duration of the periods 8A, 8B is greater than the running duration of the tasks FA, FB.

[0042] In this example, since the microprocessor 2 is a dual-core C1, C2 microprocessor, the execution of each task FA, FB is distributed between different cores C1, C2 of the microprocessor 2. Figure 2 In the schematic diagram of FIG. 1 , the upper strip carries the reference C1 and corresponds to operations performed by the first core C1, while the lower strip carries the reference C2 and corresponds to operations performed by the second core C2 of the microprocessor 2. Thus, each task FA, FB is divided into two subtasks, called "parent subtask" FA1, FB1 and "child subtask" FA2, FB2. The parent subtask FA1, FB1 is executed on the first core C1, while the child subtask FA2, FB2 is executed by the second core C2.

[0043] For each task FA, FB, the parent sub-task FA1, FB1 and the child sub-task FA2, FB2 are connected in a chain manner, that is, the child sub-task FA2, FB2 is not started until the parent sub-task FA1, FB1 is completed.

[0044] Figure 3 shows that when the engine speed has increased Figure 2 The period 9A, 9B, 9C between two events 14A, 14B, 14C is less than Figure 2 Cycle 8A, 8B.

[0045] exist Figure 3 In this example, the cycle 9A, 9B, 9C is now less than the time required to execute the tasks FA, FB, FC. Therefore, each child subtask FA2, FB2 ends while the parent subtask FB1, FC1 of the next cycle has already started. Therefore, there is a time overlap 10 (in Figure 3 (shown by hatching in the figure).

[0046] Figure 4 and Figure 5 A method allowing management of this overlapping area 10 is shown in more detail.

[0047] Figure 4 and Figure 5 are similar, and each shows a child-type subtask FA2 of a first cycle and a parent-type subtask FB1 of a next cycle. Figure 4 Corresponds to Figure 2 A configuration in which the cycles 8A and 8B have a sufficient duration so that the child-type sub-task FA2 does not overlap with the parent-type sub-task FB1 of the next cycle. Figure 5 Corresponds to Figure 3A configuration in which shortening of the reduced cycles 9A, 9B results in an overlap of the child-type subtask FA2 and the parent-type subtask FB1 of the next cycle.

[0048] exist Figure 4 and Figure 5 In the Figures 1 and 2, details of the tasks have been shown. These tasks are specifically composed of executable files R which are schematically shown in these figures. A task such as a fuel injection operation typically includes about fifty executable files R, each executable file being a function (a simple mathematical operation) or a group of functions executable by the microprocessor 2. The update of a variable indicating the engine cylinder number where the next fuel injection will occur is an example of an executable file R.

[0049] The method for controlling the engine control unit 1 implements a first executable file counter RTF for executable files of the child-type sub-task FA2 and a second executable file counter RTM for executable files of the parent-type sub-task FB1 .

[0050] exist Figure 4 and Figure 5 In the example, executable file counters RTF and RTM are displayed under subtasks FA2 and FB1, and their values ​​are continuously acquired by the counters.

[0051] When the sub-type subtask FA2 starts, the counter RTF takes an initial value equal to the total number of executable files of the sub-type subtask FA2. When the first executable file of the sub-type subtask FA2 is executed, the counter RTF is therefore equal to 6 (in the illustrated example). The counter RTF is a counter that is decremented starting from the first executable file: the execution of each new executable file R causes the counter RTF to be decremented. When the second executable file R is executed, the counter RTF is decremented to the value 5, and so on. During the execution of the last executable file R, the counter RTF is equal to 1, and at the end of the execution of this last executable file R, the counter RTF takes the value 0.

[0052] As for the second executable file counter RTM, it is an incremental counter and is associated with the count of the executable files R of the parent subtask FB1. Before the parent subtask FB1 starts, the counter RTM takes an initial value of zero. When the first executable file R of the parent subtask FB1 is executed, the counter RTM takes a value of 1. The counter RTM starts with a value of 0 and increases by one unit for each new executable file R executed during the parent subtask FB1. By starting to execute the last executable file R, the counter RTM takes a value of 5 (in the illustrated example, the parent subtask FB1 includes 5 executable files R).

[0053] At the end of task FA, that is, the end of child subtask FA2, engine control unit 1 will read the value of counter RTM. Similarly, at the start of the next cycle of task FB, that is, when parent subtask FB1 starts, engine control unit 1 will read the value of counter RTF.

[0054] exist Figure 4 In the example where the child-type sub-task FA2 and the parent-type sub-task FB1 do not overlap, the counter RTM is equal to 0 at the moment it is read (at the end of the child-type sub-task FA2), and the counter RTF is equal to 0 at the moment it is read (at the beginning of the parent-type sub-task FB1).

[0055] refer to Figure 5 , the child subtask FA2 overlaps with the parent subtask FB1 of the next cycle. In this case, when the parent subtask FB1 starts, the counter RTF is equal to 4. When the execution of the child subtask FA2 ends, the value of the counter RTM is equal to 3.

[0056] In this example, the value of counter RTF indicates that when the parent subtask FB1 starts, the child subtask FA2 still has 4 executable files R to be executed. The value of counter RTM indicates that when the child subtask FA2 is completed, the parent subtask FB1 of the next cycle has executed 3 executable files R (more precisely, the first two executable files R have been completely executed, and the third executable file is being executed).

[0057] The counter memories 11, 12 associated with the executable file counters RTF and RTM make it possible to store the last values ​​read by the engine control unit 1. At the end of the child-type subtask FA2, the value of the counter RTM is read and stored in the memory 12, while at the beginning of the parent-type subtask FB1, the value of the counter RTF is read and stored in the memory 11. The diagnostic memory 13 saves all the values ​​of the counters RTM and RTF stored by the memories 11, 12 when the counters RTM and RTF are greater than zero.

[0058] During the diagnosis of the engine control unit 1, the diagnostic memory 13 may be consulted to find out in which past tasks there was an overlap 10 in the concatenation and which executable files were executed during this overlap. The diagnosis can be performed on time or periodically. In the case of periodic diagnosis, the organization of the tasks can be modified so that when executable files R considered to be critical form part of the overlap area 10, these executable files R can be moved to the beginning of the child subtask FA2 or the end of the parent subtask FB1 so that they no longer appear in the overlap area 10. This task reorganization can also be performed in a dynamic way from one cycle to the next.

[0059] Without departing from the scope of the invention, variations of the above examples may be implemented. For example, the example described relates to an engine control unit equipped with a microprocessor 2 comprising two cores C1, C2; however, the invention is also applicable to all digital processing devices that allow the parallel execution of subtasks, and for example to engine control units having a plurality of microprocessors and / or processors having any number of cores greater than 2. In the case of a number of digital processing devices greater than 2, such as a 4-core microprocessor, the parent subtask FA1 will generate as many cascaded subtasks as the cores of the microprocessor available to process it. For example, if a microprocessor comprises 4 cores, the parent subtask will be executed on the first core and may generate a first subtask executed on the second core, which subtask itself, when completed, generates a second subtask executed on the third core, and then a fourth subtask executed on the fourth core. The method according to the invention will then implement the executable file counters RTF and RTM during the concatenation of the last subtask and the parent subtask of the next cycle.

Claims

1. A method for controlling an engine control unit (1), the engine control unit (1) being connected to sensors (3) and actuators associated with an internal combustion engine of a vehicle, the engine control unit (1) comprising at least two microprocessor (2) cores (C1, C2), the method comprising the step of executing a cyclic task (FA, FB, FC), the execution of which is triggered by a recurring event (14A, 14B, 14C) which is repeated with a period associated with the engine rotation, characterized in that The cyclic task (FA, FB, FC) is composed of an executable file (R) divided into a parent subtask (FA1, FB1) and at least one child subtask (FA2, FB2), wherein the parent subtask (FA1, FB1) is triggered by the recurring event (14A, 14B, 14C) and executed by one microprocessor core, and the child subtask (FA2, FB2) is executed by another microprocessor core after the parent subtask (FA1, FB1). The method comprises the following steps, during the series connection of a task (FA) of a first cycle (9A) and a task (FB) of a second cycle (9B) after the first cycle (9A): - when the parent sub-task (FB1) of the second cycle (9B) starts, determining the number of executable files (R) remaining to be executed in the last child sub-task (FA2) of the first cycle (9A); - When the last child-type subtask (FA2) of said first cycle (9A) is completed, determining the number of executable files (R) that have been executed in the parent-type subtask (FB1) of the second cycle (9B).

2. The method according to claim 1, characterized in that After the step of determining the number of executable files (R) remaining to be executed in the last sub-type subsidiary task (FA2) of the first cycle (9A), it comprises the step of storing this number of executable files in a memory (11).

3. The method according to claim 1, characterized in that After the step of determining the number of executable files (R) that have been executed in the parent subtask (FB1) of the second cycle (9B), it comprises the step of storing this number of executable files in the memory (12).

4. The method according to claim 2 or 3, characterized in that: The number of executable files stored in the memory (11, 12) is further stored in the diagnostic memory (13).

5. The method according to claim 4, characterized in that It comprises a diagnostic step which comprises reading the diagnostic memory (13).

6. The method according to any one of claims 1 to 3, characterized in that The step of determining the number of executable files (R) remaining to be executed in the last sub-type subsidiary task (FA2) of the first cycle (9A) comprises implementing an executable file counter (RTF) in said sub-type subsidiary task (FA2).

7. The method according to claim 6, characterized in that The initial value of the executable file counter (RTF) of the sub-type sub-task (FA2) corresponds to the total number of executable files in the sub-type sub-task (FA2), and the counter (RTF) is decremented when each executable file of the sub-type sub-task (FA2) is executed.

8. The method according to any one of claims 1 to 3, characterized in that The step of determining the number of executable files (R) that have been executed in the parent sub-task (FB1) of the second cycle (9B) comprises implementing an executable file counter (RTM) in the parent sub-task (FB1).

9. The method according to claim 8, characterized in that The initial value of the executable file counter (RTM) of the parent sub-task (FB1) is zero, and the counter (RTM) is incremented when each executable file (R) is executed.