Fault diagnosis automated test method and system based on LabVIEW
Through the fault diagnosis automated testing method based on LabVIEW, the problem of verifying the controller interactive diagnostic function in the existing technology is solved, efficient and wide-coverage automated testing is achieved, and product reliability is improved.
Patent Information
- Application Number
- CN202111167859.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-29
- Publication Date
- 2025-01-21
- Estimated Expiration
- 2041-09-29
AI Technical Summary
The prior art is difficult to effectively verify the interactive diagnostic function between controllers, resulting in the failure of the vehicle's functions and manual testing cannot meet the timing requirements of the ms level.
The fault diagnosis automated testing method based on LabVIEW is used to realize automated testing by setting test scenarios, responding to diagnostic trigger signals, determining fault types and outputting test results.
It improves test efficiency and test coverage, ensures product contingency strategies under various fault scenarios, and improves product reliability.
Smart Images

Figure CN113867319B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of automobile fault detection, and in particular to a LabVIEW-based fault diagnosis automated testing method and system. Background Art
[0002] Intelligent networked vehicles have become the development trend of automobiles, and more humanized configurations have emerged, and interactive functions have become more complex. Most of the interactive problems between controllers belong to the diagnosis field, but due to the defects in the diagnostic functions of some controllers, the whole vehicle function will fail. Because the timing involved in the verification of diagnostic functions is at the ms level, manual testing by personnel cannot meet the requirements, so the diagnostic functions of some controllers have not been fully verified, which will cause unpredictable vehicle failures.
[0003] Therefore, there is an urgent need for an automated fault diagnosis test method and system based on LabVIEW. Summary of the invention
[0004] The purpose of the present invention is to provide a LabVIEW-based fault diagnosis automated testing method and system to solve the above-mentioned problems in the prior art, thereby improving test efficiency and test coverage and improving product reliability.
[0005] The present invention provides a LabVIEW-based fault diagnosis automated testing method, which includes:
[0006] Step S1, setting each test scenario based on the LabVIEW platform;
[0007] Step S2: In response to a diagnostic trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnostic message;
[0008] Step S3, determine whether it is the last test scenario, if so, execute step S4, if not, test the next test scenario, and return to step S2 until all test scenarios are tested;
[0009] Step S4: output the test results.
[0010] In the above-mentioned LabVIEW-based fault diagnosis automated testing method, preferably, the step S1, setting each test scenario based on the LabVIEW platform, specifically includes:
[0011] Based on the diagnostic protocol of the controller under test on the host computer system, the precondition control program and bus signal monitoring program of the controller diagnostic function are developed based on the LabVIEW platform;
[0012] The preconditions for the operation of the controller under test are set through the bus simulation monitoring module.
[0013] In the above-mentioned LabVIEW-based fault diagnosis automated testing method, preferably, the step S2, in response to the diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message, specifically includes:
[0014] Initiating a diagnostic request through the host computer system to generate a diagnostic trigger signal corresponding to the current test scenario;
[0015] In response to a diagnostic trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnostic message;
[0016] The diagnostic message fed back by the controller under test is read through the bus simulation monitoring module.
[0017] In the LabVIEW-based fault diagnosis automated testing method as described above, preferably, the diagnostic message fed back by the controller under test corresponds to a fault type,
[0018] The step S2, in response to the diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message, further includes:
[0019] The bus simulation monitoring module determines whether the controller under test has multiple fault types according to the diagnostic message fed back by the controller under test;
[0020] If yes, the bus simulation monitoring module sends a control signal;
[0021] In response to the control signal, the controller under test feeds back a diagnosis message of other fault types.
[0022] The above-mentioned LabVIEW-based fault diagnosis automated testing method, wherein preferably, the step S2, in response to the diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message, further comprises:
[0023] The host computer system determines whether the diagnostic function of the current test scenario is realized to obtain the test result of the current test scenario.
[0024] In the above-mentioned LabVIEW-based fault diagnosis automated testing method, preferably, the step S4, outputting the test results, specifically includes:
[0025] The test results are outputted by the host computer system, and the results include test results corresponding to each test scenario.
[0026] As described above, the LabVIEW-based automated fault diagnosis test method, wherein preferably, the LabVIEW-based automated fault diagnosis test method further includes:
[0027] The fault injection test box is used to test each pin of the controller under test, and a test signal is input to each pin of the controller under test.
[0028] As described above, the LabVIEW-based automated fault diagnosis test method, wherein preferably, the LabVIEW-based automated fault diagnosis test method further includes:
[0029] Through a programmable power supply, power supply parameters are output to the controller under test in each test scenario.
[0030] The present invention also provides a LabVIEW-based fault diagnosis automated test system using the above method, comprising:
[0031] The host computer system, bus simulation monitoring module, fault injection test box and controller under test are set up in sequence, where:
[0032] The host computer system is used to set the program execution process and set the judgment rules;
[0033] The bus simulation monitoring module is used to set the preconditions for the operation of the controller under test, monitor the feedback signal of the controller under test, and return the feedback signal to the host computer system;
[0034] The fault injection test box serves as a transfer box for each terminal of the controller under test, and is used to accept the control of the host computer system, perform test operations on each pin of the controller under test, and input test signals to each pin of the controller under test;
[0035] The controller under test is used to return a diagnostic message to the host computer system after receiving each test signal.
[0036] The LabVIEW-based fault diagnosis automation test system as described above, wherein, preferably, the LabVIEW-based fault diagnosis automation test system also includes a programmable power supply, which is arranged between the host computer system and the fault injection test box and is controlled by the host computer system. It is used to accept the control of the host computer system according to the diagnosis scenario and output accurate power supply parameters to the controller under test.
[0037] The present invention provides a fault diagnosis automation test method and system based on LabVIEW. According to the diagnostic function strategy of the controller under test, various scenarios and expected results are developed in accordance with the arrangement and combination of various preconditions, and the test sequence is set, so that the test process works according to the set scenarios and is automatically executed in a certain order until all the test scenarios are verified. Finally, the test results are automatically output, which can improve the test efficiency and test coverage, ensure the product's contingency strategy for dealing with various fault scenarios, and improve product reliability. In the design and development stage of each controller, it can be automatically verified whether the function of the controller meets the design requirements. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to make the purpose, technical solutions and advantages of the present invention more clear, the present invention will be further described below with reference to the accompanying drawings, in which:
[0039] Figure 1 A flowchart of an embodiment of a fault diagnosis automated testing method based on LabVIEW provided by the present invention;
[0040] Figure 2 The present invention provides a block diagram of an embodiment of a fault diagnosis automated test system based on LabVIEW. DETAILED DESCRIPTION
[0041] Various exemplary embodiments of the present disclosure will now be described in detail with reference to the accompanying drawings. The description of the exemplary embodiments is merely illustrative and is in no way intended to limit the present disclosure and its application or use. The present disclosure can be implemented in many different forms and is not limited to the embodiments described herein. These embodiments are provided to make the present disclosure thorough and complete and to fully express the scope of the present disclosure to those skilled in the art. It should be noted that unless otherwise specifically stated, the relative arrangement of the components and steps, the composition of the materials, the numerical expressions and the numerical values set forth in these embodiments should be interpreted as being merely exemplary and not as limiting.
[0042] The words "first", "second" and similar words used in this disclosure do not indicate any order, quantity or importance, but are only used to distinguish different parts. The words "include" or "comprises" and similar words mean that the elements before the word include the elements listed after the word, and do not exclude the possibility of including other elements. "Up", "down" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.
[0043] In the present disclosure, when a specific component is described as being located between a first component and a second component, there may or may not be an intermediate component between the specific component and the first component or the second component. When a specific component is described as being connected to other components, the specific component may be directly connected to the other components without an intermediate component, or may not be directly connected to the other components but have an intermediate component.
[0044] All terms (including technical terms or scientific terms) used in the present disclosure have the same meanings as those understood by ordinary technicians in the field to which the present disclosure belongs, unless otherwise specifically defined. It should also be understood that terms defined in general dictionaries, such as general dictionaries, should be interpreted as having meanings consistent with their meanings in the context of the relevant technology, and should not be interpreted in an idealized or extremely formal sense, unless explicitly defined herein.
[0045] Technologies, methods, and equipment known to ordinary technicians in the relevant art may not be discussed in detail, but where appropriate, the technologies, methods, and equipment should be considered part of the specification.
[0046] The traditional testing method is manual testing by personnel, which can only verify a very small part of the diagnostic functions of the controller, and the verification of timing-related diagnostic functions is missing; moreover, the test environment is single and the test coverage cannot be guaranteed.
[0047] like Figure 1 As shown, the fault diagnosis automation test method based on LabVIEW provided in this embodiment specifically includes the following steps during the actual execution process:
[0048] Step S1, setting each test scenario based on the LabVIEW platform.
[0049] In one implementation of the LabVIEW-based fault diagnosis automated testing method of the present invention, step S1 may specifically include:
[0050] Step S11: Based on the diagnostic protocol of the controller under test, a precondition control program and a bus signal monitoring program of the controller diagnostic function are developed on the host computer system based on the LabVIEW platform.
[0051] The controller under test refers to a controller with diagnostic functions, such as a vehicle controller, a hybrid power controller, an automatic transmission controller, etc.
[0052] Step S12: setting the working preconditions of the controller under test through the bus simulation monitoring module.
[0053] In a specific implementation, each precondition and any combination of preconditions can be manually controlled on the interface of the bus simulation monitoring module, or they can be automatically combined through the bus simulation monitoring module to simulate various scenarios that may occur in the controller in a vehicle environment.
[0054] Step S2: In response to a diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message.
[0055] In one implementation of the LabVIEW-based fault diagnosis automated testing method of the present invention, step S2 may specifically include:
[0056] Step S21: Initiate a diagnosis request through the host computer system to generate a diagnosis trigger signal corresponding to the current test scenario.
[0057] In step S21, the diagnosis process is triggered by the host computer system.
[0058] Step S22: In response to a diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message.
[0059] Step S23: reading the diagnostic message fed back by the controller under test through the bus simulation monitoring module.
[0060] Wherein, in step S23, the diagnostic message fed back by the controller under test corresponds to a fault type.
[0061] Further, in some embodiments of the present invention, the step S2, in response to the diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message, further includes:
[0062] Step S24: the bus simulation monitoring module determines whether the controller under test has multiple fault types according to the diagnostic message fed back by the controller under test.
[0063] Step S25: If yes, the bus simulation monitoring module sends a control signal.
[0064] Step S26: In response to the control signal, the controller under test feeds back a diagnosis message of other fault types.
[0065] Exemplarily, in step S23, the diagnostic message fed back by the controller under test corresponds to an open circuit fault, while in step S26, the diagnostic message fed back by the controller under test corresponds to a fault type other than an open circuit fault, such as a short circuit, a short to power, a short to ground, etc.
[0066] Furthermore, in some embodiments of the present invention, the step S2, in response to the diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message, further includes:
[0067] Step S27: determining, by the host computer system, whether the diagnostic function of the current test scenario is realized, so as to obtain the test result of the current test scenario.
[0068] In a specific implementation, the fault diagnosis function can be automatically verified by parsing and comparing the diagnostic message corresponding to each test scenario with the expected fault code.
[0069] Therefore, when the diagnostic process is triggered, the controller under test needs to respond and feedback the corresponding diagnostic message according to the actual diagnostic requirements, and then read the diagnostic message feedback from the controller under test through the bus monitoring module, and determine whether it is necessary to send a control signal. If necessary, send the control signal and then monitor the diagnostic message feedback from the controller under test, and automatically determine whether the diagnostic function in the corresponding scenario is realized in the host computer system, and output the test results.
[0070] Step S3, determine whether it is the last test scenario, if so, execute step S4, if not, test the next test scenario, and return to step S2 until all test scenarios are tested.
[0071] When testing the next test scenario, step S2 is repeated until all test scenarios are completed.
[0072] Step S4: output the test results.
[0073] Specifically, the host computer system outputs the test results, which include the test results corresponding to each test scenario. The test results may be, for example, a spreadsheet report.
[0074] Furthermore, in some implementations of the present invention, the LabVIEW-based fault diagnosis automated testing method further includes:
[0075] Step S5: testing each pin of the controller under test by using a fault injection test box, and inputting a test signal to each pin of the controller under test.
[0076] Furthermore, the LabVIEW-based fault diagnosis automated testing method further includes:
[0077] Step S6: outputting power supply parameters to the controller under test in each test scenario through a programmable power supply.
[0078] The LabVIEW-based fault diagnosis automated testing method provided by the embodiment of the present invention develops various scenarios and expected results according to the diagnostic function strategy of the controller under test and the arrangement and combination of various preconditions, and sets the test sequence, so that the test process works according to the set scenarios and is automatically executed in a certain order until all test scenarios are verified, and finally the test results are automatically output, which can improve the test efficiency and test coverage, ensure the product's contingency strategy for dealing with various fault scenarios, and improve product reliability; in the design and development stage of each controller, it can be automatically verified whether the function of the controller meets the design requirements.
[0079] Accordingly, if Figure 2 As shown, the present invention also provides a LabVIEW-based fault diagnosis automated test, comprising: a host computer system 1, a bus simulation monitoring module 2, a fault injection test box 4 and a controller under test 5 which are arranged in sequence, wherein:
[0080] The host computer system 1 is used to set the program execution process and set the judgment rules;
[0081] The bus simulation monitoring module 2 is used to set the preconditions for the operation of the controller under test 5, monitor the feedback signal of the controller under test 5, and return the feedback signal to the host computer system 1;
[0082] The fault injection test box 4 serves as a transfer box for each terminal of the controller under test 5, and is used to accept the control of the host computer system 1, perform test operations on each pin of the controller under test 5, and input test signals to each pin of the controller under test 5;
[0083] The controller under test 5 is used to return a diagnostic message to the host computer system 1 after receiving each test signal.
[0084] Among them, the host computer system 1 includes an operating system and a software development environment, which are used for program code development, setting program execution flow and judgment rules. The developed program code includes bus signal simulation transmission timing, bus signal monitoring interface display, programmable power supply control, fault injection test box control, etc.
[0085] The test operation of the fault injection test box 4 on each pin of the controller under test 5 may include, for example, open circuit, short circuit, short to power, short to ground, etc.
[0086] Furthermore, the LabVIEW-based fault diagnosis automation test system also includes a programmable power supply, which is arranged between the host computer system and the fault injection test box and is controlled by the host computer system. It is used to accept the control of the host computer system according to the diagnosis scenario and output accurate power supply parameters to the controller under test.
[0087] The LabVIEW-based fault diagnosis automated test system provided in the embodiment of the present invention develops various scenarios and expected results according to the diagnostic function strategy of the controller under test and the arrangement and combination of various preconditions, and sets the test sequence, so that the test process works according to the set scenarios and is automatically executed in a certain order until all test scenarios are verified, and finally the test results are automatically output, which can improve the test efficiency and test coverage, ensure the product's contingency strategy for dealing with various fault scenarios, and improve product reliability; in the design and development stage of each controller, it can automatically verify whether the function of the controller meets the design requirements.
[0088] So far, various embodiments of the present disclosure have been described in detail. In order to avoid obscuring the concept of the present disclosure, some details known in the art are not described. Based on the above description, those skilled in the art can fully understand how to implement the technical solution disclosed here.
[0089] Although some specific embodiments of the present disclosure have been described in detail by way of examples, it should be understood by those skilled in the art that the above examples are for illustration only and are not intended to limit the scope of the present disclosure. It should be understood by those skilled in the art that the above embodiments may be modified or some technical features may be replaced by equivalents without departing from the scope and spirit of the present disclosure. The scope of the present disclosure is defined by the appended claims.
Claims
1. A fault diagnosis automated testing method based on LabVIEW, characterized in that: include: Step S1, setting each test scenario based on the LabVIEW platform; The step S1, setting each test scenario based on the LabVIEW platform, specifically includes: Based on the diagnostic protocol of the controller under test, a precondition control program and a bus signal monitoring program of the controller diagnostic function are developed on the host computer system based on the LabVIEW platform, wherein the controller under test includes a variety of controllers with diagnostic functions; Setting the preconditions for the operation of the controller under test through the bus simulation monitoring module, manually controlling the preconditions and any combination of the preconditions on the interface of the bus simulation monitoring module, or automatically combining the preconditions through the bus simulation monitoring module to simulate various scenarios that may occur in the controller under test in a vehicle environment; Step S2: In response to a diagnostic trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnostic message; Step S3, determine whether it is the last test scenario, if so, execute step S4, if not, test the next test scenario, and return to step S2 until all test scenarios are tested; Step S4: output the test results.
2. The LabVIEW-based fault diagnosis automated testing method according to claim 1, characterized in that: The step S2, in response to the diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message, specifically includes: Initiating a diagnostic request through the host computer system to generate a diagnostic trigger signal corresponding to the current test scenario; In response to a diagnostic trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnostic message; The diagnostic message fed back by the controller under test is read through the bus simulation monitoring module.
3. The fault diagnosis automation test method based on LabVIEW according to claim 2, characterized in that: The diagnostic message fed back by the controller under test corresponds to a fault type, The step S2, in response to the diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message, further includes: The bus simulation monitoring module determines whether the controller under test has multiple fault types according to the diagnostic message fed back by the controller under test; If yes, the bus simulation monitoring module sends a control signal; In response to the control signal, the controller under test feeds back a diagnosis message of other fault types.
4. The LabVIEW-based fault diagnosis automated testing method according to claim 2, characterized in that: The step S2, in response to the diagnosis trigger signal corresponding to the current test scenario, the controller under test feeds back a diagnosis message, further includes: The host computer system determines whether the diagnostic function of the current test scenario is realized to obtain the test result of the current test scenario.
5. The LabVIEW-based fault diagnosis automated testing method according to claim 1, characterized in that: The step S4, outputting the test results, specifically includes: The test results are outputted by the host computer system, and the results include test results corresponding to each test scenario.
6. The LabVIEW-based fault diagnosis automated testing method according to claim 1, characterized in that: The LabVIEW-based fault diagnosis automated testing method further includes: The fault injection test box is used to test each pin of the controller under test, and a test signal is input to each pin of the controller under test.
7. The LabVIEW-based fault diagnosis automated testing method according to claim 1, characterized in that: The LabVIEW-based fault diagnosis automated testing method further includes: Through a programmable power supply, power supply parameters are output to the controller under test in each test scenario.
8. A fault diagnosis automated test system based on LabVIEW, characterized in that: include: The host computer system, bus simulation monitoring module, fault injection test box and controller under test are set up in sequence, where: The host computer system is used to set the program execution process and set the judgment rules, based on the diagnostic protocol of the controller under test, and develop the precondition control program and bus signal monitoring program of the controller diagnostic function based on the LabVIEW platform; The bus simulation monitoring module is used to set the preconditions for the operation of the controller under test, so as to simulate various scenarios that may occur in the vehicle environment of the controller under test, monitor the feedback signal of the controller under test, and return the feedback signal to the host computer system; The fault injection test box serves as a transfer box for each terminal of the controller under test, and is used to accept the control of the host computer system, perform test operations on each pin of the controller under test, and input test signals to each pin of the controller under test; The controller under test is used to return a diagnostic message to the host computer system after receiving each test signal, wherein the controller under test includes multiple controllers with diagnostic functions.
9. The LabVIEW-based fault diagnosis automated test system according to claim 8, characterized in that: The LabVIEW-based fault diagnosis automated test system also includes a programmable power supply, which is arranged between the host computer system and the fault injection test box and is controlled by the host computer system. The power supply is used to accept the control of the host computer system according to the diagnosis scenario and output accurate power supply parameters to the controller under test.
Citation Information
Patent Citations
Method and system for establishing test cases
CN104850110A
Automatic diagnosis method, device and system
CN109240278A
Vehicle-mounted ECU bus refreshing test system and method
CN112748713A