A Method for Implementing a VCU Fault Diagnosis Strategy
By defining the controller fault code attributes in the VCU fault diagnosis strategy, using Matlab to generate structure variables and importing Simulink, the problem of huge and difficult maintenance in the existing technology is solved, and the fault diagnosis is clear and easy to maintain, reducing the risk of misjudgment of driving functions.
Patent Information
- Application Number
- CN202210604419.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-31
- Publication Date
- 2025-07-04
- Estimated Expiration
- 2042-05-31
AI Technical Summary
When existing VCU fault diagnosis strategies deal with fault codes and fault levels of multiple controllers, the strategy is huge and difficult to maintain, prone to errors, and may lead to misjudgment of driving functions.
Define the controller fault code attributes through Excel, use Matlab script to generate structure variables, import into Simulink workspace, assert and activate according to the fault code and level, and perform fault attribute judgment and processing, and execute vehicle control strategy.
It realizes the clarity and easy maintenance of VCU fault diagnosis strategies, reduces the modification workload and reduces the impact on driving functions.
Smart Images

Figure CN114859872B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a method for implementing a VCU fault diagnosis strategy, belonging to the technical field of fault diagnosis. Background Art
[0002] In existing VCU fault diagnosis strategies, most diagnose each fault code of the VCU in the control strategy, then generate a fault code, and define the corresponding vehicle fault level according to the characteristics of the fault code. For the fault codes and fault levels of other controllers, some VCU fault diagnosis strategies only handle the fault levels. However, because there are too many fault codes and each is processed, the fault diagnosis strategy will be relatively large and difficult to maintain. In addition to handling the fault strategy of the VCU itself, the VCU also needs to manage the fault codes and fault levels of multiple other controllers on the vehicle, so that the fault codes and fault levels of each controller can be uniformly corresponded to the fault level strategy that the VCU needs to execute.
[0003] However, to complete the above strategy, it is necessary to process each fault code of each controller and its corresponding fault level in the strategy. This method is extremely error-prone, and the workload of writing the strategy is extremely large. It is also easy to make mistakes in later modification and maintenance. If only the fault levels of other controllers are processed, some fault codes that originally limit energy recovery may limit the driving function because only the fault levels are processed in the VCU strategy. This misjudgment is an extremely unwise strategy. Therefore, the present invention proposes a method for implementing a VCU fault diagnosis strategy. Summary of the Invention
[0004] In view of the problems existing in the above-mentioned prior art, the present invention provides a method for implementing a VCU fault diagnosis strategy.
[0005] To achieve the above object, the technical solution adopted by the present invention is: a method for implementing a VCU fault diagnosis strategy, including the following steps:
[0006] S1. Define the attributes required for each fault code of each controller in the VCU fault diagnosis strategy through Excel;
[0007] S2. Write a Matlab script to generate an m script from the content in the defined Excel. The m script defines a structure according to each fault code and fault attribute of each controller in the Excel;
[0008] S3. Import the structure variable into the Simulink workspace;
[0009] S4. According to the fault codes and fault levels received by the VCU from each controller, set and activate the corresponding fault code status of the structure variable corresponding to the controller;
[0010] S5. Extract the activated fault codes in all structure variables and extract the fault attributes of the activated fault codes;
[0011] S6. Judge and process the extracted fault attributes;
[0012] S7. Execute the vehicle control strategy corresponding to the fault handling result.
[0013] Furthermore, the attributes required in the VCU fault diagnosis strategy in step S1 include defining the initial fault state, defining the fault code value, defining the fault code number, defining the fault level of the controller where the fault code is located, defining the fault level executed by the VCU when this fault code occurs during VCU discharge, and defining the fault level executed by the VCU when this fault code occurs during VCU charging.
[0014] Furthermore, in step S2, the fault codes and attributes of each controller are defined as a structure variable.
[0015] Furthermore, in step S4, when the VCU receives a certain fault code of a certain controller, according to the currently occurring fault code and fault level, it judges with the attributes in the structure variable corresponding to this controller. If it meets the fault attributes, it sets and activates the fault state of this fault code in the fault structure. When the fault state is activated, other fault attributes are also activated.
[0016] Furthermore, in step S4, after processing the fault structure variables of each controller according to the current fault codes and levels of each controller, the various attributes in the structure variables can be classified.
[0017] Furthermore, in step S4, extract from all fault structure variables the vehicle fault level during maximum discharge and the vehicle fault level during maximum charge. According to these two fault levels and the current vehicle working conditions, judge the VCU fault measures to be executed currently.
[0018] The beneficial effects of the present invention are:
[0019] It can make the VCU fault diagnosis strategy easier to implement and clearer, and it is also relatively easy to modify and maintain the strategy later.
[0020] It can make the Simulink model clearer. When it is necessary to modify the fault code or fault attribute, only need to modify the fault attribute definition in Excel, then generate the fault structure variable through the m script, and then fine-tune the model to achieve the matching and modification of the fault strategy, reducing the workload and reducing the impact on driving functions. Description of the Drawings
[0021] Figure 1 This is a flowchart of the implementation method of a VCU fault diagnosis strategy according to the present invention. Specific implementation manners
[0022] To make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments.
[0023] However, it should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the scope of the present invention.
[0024] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which the present invention belongs. The terms used in the description of the present invention herein are only for the purpose of describing specific embodiments and are not intended to limit the present invention.
[0025] As Figure 1 shown, a method for implementing a VCU fault diagnosis strategy includes the following steps:
[0026] S1. Define the attributes required for each fault code of each controller in the VCU fault diagnosis strategy through Excel.
[0027] S2. Write a Matlab script to generate an m script from the content in the defined Excel. The m script defines a structure according to each fault code and fault attribute of each controller in the Excel.
[0028] S3. Import the structure variable into the Simulink workspace.
[0029] S4. According to the fault codes and fault levels received by the VCU from each controller, set and activate the corresponding fault code status of the structure variable of the controller.
[0030] S5. Extract the activated fault codes from all structure variables, and extract the fault attributes of the activated fault codes.
[0031] S6. Judge and process the extracted fault attributes.
[0032] S7. Execute the vehicle control strategy corresponding to the fault handling result.
[0033] The attributes required for the VCU fault diagnosis strategy in step S1 include defining the initial fault state, defining the fault code value, defining the fault code number, defining the fault level of the controller where the fault code is located, defining the fault level executed by the VCU when this fault code occurs during VCU discharge, and defining the fault level executed by the VCU when this fault code occurs during VCU charging.
[0034] In step S2, the fault codes and attributes of each controller are defined as a structure variable.
[0035] In step S3, when the VCU receives a certain fault code of a certain controller, it judges according to the currently occurring fault code and fault level and the attributes in the structure variable corresponding to this controller. If it meets the fault attributes, it sets and activates the fault status of this fault code in the fault structure. When the fault status is activated, other fault attributes are also activated.
[0036] In step S4, according to the fault codes and levels of each current controller, after processing the fault structure variables of each controller, the various attributes in the structure variables can be classified.
[0037] In step S4, the vehicle fault level during maximum discharge and the vehicle fault level during maximum charge are extracted from all the fault structure variables. According to these two fault levels and the current vehicle working condition, the VCU fault measures to be executed currently are judged.
[0038] This embodiment can conveniently extract the vehicle fault level during maximum discharge and the vehicle fault level during maximum charge from all the fault structure variables. According to these two fault levels and the current vehicle working condition, it can clearly judge the VCU fault measures to be executed currently.
[0039] In the present invention, the attributes required for each fault code of each controller in the VCU fault diagnosis strategy are defined through Excel, and a Matlab script is written to generate an m script from the defined content in Excel. The m script defines a structure according to each fault code and fault attribute of each controller in Excel, imports the structure variable into the Simulink workspace, sets and activates the corresponding fault code status of the structure variable corresponding to the controller according to the fault codes and fault levels received by the VCU, extracts the activated fault codes from all the structure variables, and extracts the fault attributes of the activated fault codes. Judging and processing the extracted fault attributes can make the VCU fault diagnosis strategy easier to implement and clearer, and it is also relatively easy to modify and maintain the strategy later.
[0040] Such a method can make the Simulink model clearer and more understandable. At the same time, when it is necessary to modify the fault code or fault attribute, only the fault attribute definition in Excel needs to be modified, then generate the fault structure variable through the m script, and then fine-tune the model to achieve the matching and modification of the fault strategy, reducing the workload and the impact on the driving function.
[0041] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions, or improvements made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.
Claims
1. A method for implementing a VCU fault diagnosis strategy, characterized in that It includes the following steps: S1. Define the attributes required for each fault code of each controller in the VCU fault diagnosis strategy through Excel; S2. Write a Matlab script to generate an m script from the content in the defined Excel. The m script defines a structure according to each fault code and fault attribute of each controller in the Excel; S3. Import the structure variable into the Simulink workspace; S4. According to the fault codes and fault levels received by the VCU from each controller, set and activate the corresponding fault code status of the structure variable corresponding to the controller; S5. Extract the activated fault codes from all structure variables and extract the fault attributes of the activated fault codes; S6. Judge and process the extracted fault attributes; S7. Execute the vehicle control strategy corresponding to the fault handling result.
2. The method for implementing a VCU fault diagnosis strategy according to claim 1, wherein The attributes required in the VCU fault diagnosis strategy in step S1 include defining the initial fault state, defining the fault code value, defining the fault code number, defining the fault level of the controller where the fault code is located, defining the fault level executed by the VCU when this fault code occurs during VCU discharge, and defining the fault level executed by the VCU when this fault code occurs during VCU charging.
3. The method for implementing a VCU fault diagnosis strategy according to claim 1, wherein, In step S2, the fault codes and attributes of each controller are defined as a structure variable.
4. The method for implementing a VCU fault diagnosis strategy according to claim 1, wherein In step S4, when the VCU receives a certain fault code of a certain controller, it judges according to the currently occurring fault code and fault level and the attributes in the structure variable corresponding to this controller. If it meets the fault attributes, it sets and activates the fault state of this fault code in the fault structure. When the fault state is activated, other fault attributes are also activated.
5. The method for implementing a VCU fault diagnosis strategy according to claim 1, characterized in that In step S4, after processing the fault structure variables of each controller according to the current fault codes and levels of each controller, the attributes in the structure variables can be classified.
6. The method for implementing a VCU fault diagnosis strategy according to claim 1, wherein, In step S4, the vehicle fault levels during maximum discharge and maximum charge are extracted from all fault structure variables. According to these two fault levels and the current vehicle working conditions, the VCU fault measures to be executed currently are judged.
Citation Information
Patent Citations
Generalized fault diagnosis method based on avionics equipment
CN110377448A
Military vehicle fault code-based real-time key driving data extraction system
CN110473308A