Internal module circuit verification method and system based on double MCUs

By using dual MCU modules in the circuit for signal comparison and sampling, the problem of low circuit fault diagnosis efficiency in the prior art is solved, rapid fault judgment and self-checking are achieved, and the safety and reliability of the circuit are improved.

CN119780670AActive Publication Date: 2025-04-08ZHENGZHOU JIACHEN ELECTRIC CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202411877949.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-19
Publication Date
2025-04-08
Estimated Expiration
2044-12-19

AI Technical Summary

Technical Problem

The prior art is less efficient in circuit fault diagnosis and it is difficult to respond quickly to and deal with circuit faults.

Method used

Using the internal module circuit verification method based on dual MCUs, the EN signal is emitted through the first MCU module, the driving circuit module outputs the signal, the process sampling module samples the internal signal, the first MCU and the second MCU module compare the sampled signal with the expected signal, and if it is inconsistent, the second sampling and comparison are performed to judge the fault.

Benefits of technology

It realizes rapid judgment and self-checking of circuit failures, and improves the safety and reliability of the circuit.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119780670A_ABST
    Figure CN119780670A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of circuit verification, and particularly relates to an internal module circuit verification method and system based on double MCUs, and the method comprises the steps: a first MCU module transmits a first EN signal to drive a tested circuit module to generate an internal signal, a process sampling module carries out the sampling of the internal signal of the tested circuit module, and obtains a first sampling signal; the first MCU module and the second MCU module discover whether the first sampling signal is consistent with an expected signal through comparison, if yes, it is judged that the detected circuit module works normally, otherwise, the first MCU module stops sending out a first EN signal, the second MCU module sends out a second EN signal and a second Signal signal, a second sampling signal is constructed, and the detected circuit module works normally; and carrying out second sampling on the detected circuit module based on the second sampling signal to obtain a new first sampling signal, and judging a fault based on the new first sampling signal. According to the invention, rapid judgment of circuit faults can be realized by performing self-correction verification on the circuit.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of circuit verification, and in particular relates to an internal module circuit verification method and system based on dual MCUs. Background Art

[0002] In the field of electronic technology, the modularization of circuit modules makes the connection between modules uncertain, so circuit verification becomes particularly important. Existing technical solutions often lack effective fault diagnosis and processing mechanisms, making it difficult to quickly respond and handle circuit failures.

[0003] A similar prior art Chinese patent application with publication number CN114721862A provides a watchdog circuit with a signal verification function, the method comprising: a signal verification circuit, which is communicatively connected to a signal sender, and is used to verify whether a signal received by the watchdog circuit is consistent with a signal sent by the signal sender; an error injection circuit, which is communicatively connected to the signal verification circuit, and is used to detect the function of the signal verification circuit; a watchdog circuit, which is communicatively connected to the signal verification circuit, and is used to respond to a signal verified by the signal verification circuit; the watchdog circuit comprises a refresh controller, which is communicatively connected to a counter of the watchdog circuit, and is used to control the counter to refresh after determining the validity of the feeding signal.

[0004] A similar prior art also includes a Chinese patent application with publication number CN113656230A, which discloses a fault diagnosis circuit, method, device and computer-readable storage medium, the method comprising: a safety protection circuit and a diagnostic module; the safety protection circuit is electrically connected to the protected circuit, and is used to perform a verification operation on the stored data in the protected circuit to obtain first verification data, and to inject errors into second verification data corresponding to the stored data, and to generate a first verification result signal based on the first verification data and the second verification data after the error injection; the diagnostic module is electrically connected to the safety protection circuit, and the diagnostic module is used to perform fault diagnosis on the safety protection circuit based on the first verification result signal.

[0005] However, the above two applications do not consider the problem of low fault diagnosis efficiency. Therefore, the present invention provides an internal module circuit verification method and system based on dual MCUs. Summary of the invention

[0006] The present invention can quickly locate fault problems and enter the control system when a fault occurs to ensure the normal operation of the circuit and the external output status, thereby ensuring the safe state of the system.

[0007] In order to achieve the above-mentioned purpose of the invention, the present invention provides a dual MCU-based internal module circuit verification method as described below, which is implemented by executing the following steps:

[0008] Step S1, the first MCU module sends a first EN signal to the driving circuit module, and the driving circuit module sends a first SignalEN signal after receiving the first EN signal, and sends it to the circuit module under test, and the circuit module under test outputs an internal signal after internal processing;

[0009] Step S2: When the circuit module under test outputs the internal signal, the process sampling module samples the internal signal of the circuit module under test, outputs a first sampling signal, and sends the first sampling signal to the first MCU module and the second MCU module;

[0010] Step S3, the first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time. If it is found that the first sampling signal is consistent with the expected signal, it indicates that the circuit module under test works normally. If it is found that the first sampling signal is inconsistent with the expected signal, step S4 is executed;

[0011] Step S4, the first MCU module turns off the output of the first EN signal, the second MCU module sends a second EN signal and a second SignalEN signal, and constructs a new second sampling signal to the circuit module under test through the enabling circuit module and the verification signal construction module;

[0012] Step S5: After the second sampling signal is input into the circuit module under test, the internal signal output by the circuit module under test is sampled for the second time to obtain a new first sampling signal, and the new first sampling signal is input into the first MCU module and the second MCU module to determine fault information.

[0013] As a preferred technical solution of the present invention, judging fault information includes the following steps:

[0014] Step S51: the first MCU module and the second MCU module compare the new first sampling signal with the expected signal for the second time. If the new first sampling signal is consistent with the expected signal, it indicates that the circuit module under test is working normally.

[0015] Step S52: If the new first sampling signal is still inconsistent with the expected signal, it indicates that there is an internal fault in the circuit module under test.

[0016] As a preferred technical solution of the present invention, in step S1, the following steps are further performed:

[0017] The first MCU module also establishes a communication channel with the second MCU module, and sends the first EN signal to the second MCU module through the communication channel.

[0018] As a preferred technical solution of the present invention, the first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time, including the following steps:

[0019] Step S31: After receiving the first sampling signal, the first MCU module compares the first sampling signal with the expected signal to obtain a first comparison result, where the first comparison result includes two situations: consistency and inconsistency;

[0020] Step S32: After receiving the first sampling signal, the second MCU module compares the first sampling signal with the expected signal to obtain a second comparison result, where the second comparison result includes two situations: consistency and inconsistency;

[0021] Step S33: the first MCU module sends the first comparison result to the second MCU module through the communication channel, and the second MCU module sends the second comparison result to the first MCU module through the communication channel;

[0022] Step S34: If the first comparison result and the second comparison result are both consistent, it is determined that the first sampling signal is consistent with the expected signal; otherwise, it is determined that the first sampling signal is inconsistent with the expected signal.

[0023] As a preferred technical solution of the present invention, comparing the first sampled signal with the expected signal to obtain a first comparison result includes the following steps:

[0024] Signal conditioning is performed on the first sampling signal, key parameters are extracted from the conditioned first sampling signal, the key parameters including amplitude, frequency, phase and timestamp, and the key parameters are compared with key parameters of the expected signal to obtain a first comparison result.

[0025] As a preferred technical solution of the present invention, comparing the key parameter with the key parameter of the expected signal to obtain a first comparison result includes the following steps:

[0026] Determine whether each key parameter of the first sampling signal is within the threshold range of each key parameter of the expected signal; if each of the key parameters is within the threshold range of the corresponding key parameter of the expected signal, determine that the first comparison result of the first sampling signal and the expected signal is consistent; otherwise, the first comparison result is inconsistent.

[0027] As a preferred technical solution of the present invention, the expected signal means that there is a set of preset standards inside the first MCU module and the second MCU module. Based on the preset standards, the first MCU module and the second MCU module can output the expected signal based on the first EN signal. The preset standards may be a theoretical model of circuit design, or signal characteristics under normal working conditions in historical data.

[0028] As a preferred technical solution of the present invention, the process sampling module samples the internal signal of the circuit module under test, including the following steps:

[0029] Real-time detection of environmental parameters, including temperature and humidity, assessing the impact of the environmental parameters on signal quality to obtain a first environmental parameter, the first environmental parameter refers to the environmental parameter that has the greatest impact on signal quality, setting sampling rules, and increasing the sampling frequency under specific circumstances.

[0030] As a preferred technical solution of the present invention, evaluating the influence of the environmental parameter on the signal quality to obtain the first environmental parameter includes the following steps:

[0031] Acquire sampling signals and corresponding environmental parameters in the historical sampling process. For each type of environmental parameter, obtain the corresponding key signal feature based on the sampling signal, where the key signal feature refers to the amplitude value of the signal. Calculate the correlation coefficient between different environmental parameter values ​​and the key signal feature, and take the environmental parameter with the largest correlation coefficient as the first environmental parameter.

[0032] The present invention also provides an internal module circuit verification system based on dual MCUs, comprising the following units:

[0033] A signal driving unit, used for sending a first EN signal to a driving circuit module, and the driving circuit module sends a first SignalEN signal after receiving the first EN signal, and sends it to a circuit module under test, and the circuit module under test outputs an internal signal after internal processing;

[0034] A signal sampling unit, configured to sample the internal signal of the circuit module under test by a process sampling module during the process in which the circuit module under test outputs the internal signal, output a first sampling signal, and send the first sampling signal to the first MCU module and the second MCU module;

[0035] A signal comparison unit, wherein the first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time, and if it is found that the first sampling signal is consistent with the expected signal, it indicates that the circuit module under test is working normally; if it is found that the first sampling signal is inconsistent with the expected signal, a detection processing unit is executed;

[0036] The detection processing unit, the first MCU module turns off the output of the first EN signal, the second MCU module sends a second EN signal and a second SignalEN signal, and constructs a new second sampling signal to the circuit module under test through an enabling circuit module and a verification signal construction module;

[0037] The fault judgment unit samples the internal signal output by the circuit module under test for the second time after the second sampling signal is input into the circuit module under test, obtains a new first sampling signal, and inputs the new first sampling signal into the first MCU module and the second MCU module to judge the fault information.

[0038] Compared with the prior art, the beneficial effects of the present invention are at least as follows:

[0039] In the present invention, the first MCU module sends a first EN signal, the driving circuit module works and sends a first SignalEN signal, the circuit module under test works and sends an output signal, a process sampling module is used to sample the internal signal of the circuit module under test, and the first sampling signal is output to the first MCU module and the second MCU module. The first MCU module and the second MCU module establish a communication channel, and compare the first sampling signal with each other. When it is detected that the output signal is inconsistent with the expected signal, the first MCU module turns off the output of the first EN signal, and the second MCU module sends a second EN signal and a second SignalEN signal. A new first sample signal is constructed by a verification signal construction module, and the new first sample signal is sent to the first MCU module and the second MCU module, and the new first sampling signal is compared with each other. It is judged whether there is a fault based on the comparison result, and fault information is output in the case of a fault. The present invention can realize rapid judgment of circuit faults, and can also perform self-calibration verification on the circuit to improve the safety and reliability of the circuit. BRIEF DESCRIPTION OF THE DRAWINGS

[0040] Figure 1 A flowchart of the steps of a dual-MCU-based internal module circuit verification method of the present invention;

[0041] Figure 2 Flow chart of the operation of each module of the present invention;

[0042] Figure 3 The present invention is a structural diagram of an internal module circuit verification system based on dual MCUs. DETAILED DESCRIPTION

[0043] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.

[0044] It is understood that the terms "first", "second", etc. used in this application may be used herein to describe various elements, but unless otherwise specified, these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, without departing from the scope of this application, a first xx script may be referred to as a second xx script, and similarly, a second xx script may be referred to as a first xx script.

[0045] In the prior art, when diagnosing and judging faults in circuits, the problem of low diagnostic efficiency is not considered.

[0046] Thus, the present invention provides Figure 1 The internal module circuit verification method based on dual MCU is implemented by executing the following steps:

[0047] Step S1, the first MCU module sends a first EN signal to the driving circuit module. After receiving the first EN signal, the driving circuit module sends a first SignalEN signal and sends it to the circuit module under test. The circuit module under test outputs an internal signal after internal processing.

[0048] Specifically, under normal working conditions, the first MCU module is responsible for the main functional output, and the second MCU module is in standby monitoring and detection status. MCU is a small computer system that integrates multiple functional modules such as processor, memory, input and output interface, etc. The MCU controller usually includes CPU, memory, input and output interface, timer, ADC, DAC and other modules, which can realize various control, calculation, data processing and other functions. The first MCU module sends a first EN signal to the driving circuit module. After receiving the first EN signal, the driving circuit module sends a first SignalEN signal and sends it to the circuit module under test. The circuit module under test outputs the internal signal after internal processing.

[0049] Step S2: When the circuit module under test outputs an internal signal, the process sampling module samples the internal signal of the circuit module under test, outputs a first sampling signal, and sends the first sampling signal to the first MCU module and the second MCU module.

[0050] Specifically, in the process of the circuit module under test outputting an internal signal, the process sampling module samples the internal signal of the circuit module under test. In order to improve the accuracy and efficiency of detection, the sampling frequency is dynamically adjusted according to environmental changes. The specific sampling process will be explained in detail later. A first sampling signal is output and the first sampling signal is also sent to the first MCU module and the second MCU module. Subsequently, the first MCU module and the second MCU module can perform fault detection and processing based on the comparison of the first sampling signal and the expected signal.

[0051] Step S3: the first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time. If the first sampling signal is found to be consistent with the expected signal, it indicates that the circuit module under test is working normally. If the first sampling signal is found to be inconsistent with the expected signal, step S4 is executed.

[0052] Specifically, the first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time. When it is detected that the first sampling signal is consistent with the expected signal, it indicates that the circuit module under test is working normally. If it is found that the first sampling signal is inconsistent with the expected signal, it indicates that the circuit module under test may have a fault. At the same time, there is also a situation where the circuit module under test does not have a fault, but the first sampling signal has a problem. Therefore, the circuit module under test is further tested by executing step S4.

[0053] Step S4: the first MCU module turns off the output of the first EN signal, the second MCU module sends out a second EN signal and a second SignalEN signal, and constructs a new second sampling signal to the circuit module under test through the enabling circuit module and the verification signal construction module.

[0054] Specifically, when it is detected that the first sampling signal is inconsistent with the expected signal, the first MCU module turns off the output of the first EN signal, and the second MCU module outputs the second EN signal to the drive module, outputs the second SignalEN signal to the enable circuit module, and the verification signal construction module constructs a second sampling signal to output to the circuit module under test. In order to determine whether the circuit module under test is correct, a new second sampling signal that ensures accuracy and reliability is constructed by the verification signal construction module, and the second sampling signal is input to the circuit module under test to further verify the fault condition of the circuit and improve the accuracy of fault diagnosis.

[0055] Step S5: After the second sampling signal is input into the circuit module under test, the internal signal output by the circuit module under test is sampled for the second time to obtain a new first sampling signal, and the new first sampling signal is input into the first MCU module and the second MCU module to determine the fault information.

[0056] Specifically, a new second sampling signal is constructed to input the circuit module under test, and then a second sampling is performed on the internal signal output by the circuit module under test to obtain a new first sampling signal, and the new first sampling signal is input into the first MCU module and the second MCU module again. Subsequently, the first MCU module and the second MCU module compare and determine whether the circuit module under test is abnormal. The specific judgment method will be explained in detail later. The above method can accurately locate the source of the fault, reduce misjudgment, and improve the efficiency of fault diagnosis.

[0057] like Figure 2 The flowchart shown is the operation flow of each module when implementing the present invention. The first MCU module sends a first EN signal, the driving circuit module works and sends a first SignalEN signal, the circuit module under test works and outputs an internal signal, the process sampling module is used to sample the internal signal of the circuit module under test, and the first sampling signal is output to the first MCU module and the second MCU module. The first MCU module and the second MCU module establish a communication channel, and compare the first sampling signal with each other. When it is detected that the output signal is inconsistent with the expected signal, the first MCU module turns off the output of the first EN signal, and the second MCU module sends a second EN signal and a second SignalEN signal. A new second sample signal is constructed by the enabling circuit module and the verification signal construction module, and is output to the circuit module under test. The circuit module under test is sampled for a second time to obtain a new first sampling signal. The first MCU module and the second MCU module compare the new first sampling signal with each other, and determine whether there is a fault based on the comparison result, and output fault information if there is a fault.

[0058] Further, judging the fault information includes the following steps:

[0059] Step S51: The first MCU module and the second MCU module compare the new first sampling signal with the expected signal for the second time. If the new first sampling signal is consistent with the expected signal, it indicates that the circuit module under test is working normally.

[0060] Step S52: If the new first sampling signal is still inconsistent with the expected signal, it indicates that there is an internal fault in the circuit module under test.

[0061] Specifically, the first MCU module compares the acquired new first sampling signal with the expected signal. If the first sampling signal is consistent with the expected signal, it means that after using the correct new first sampling signal, the circuit module under test can output the first sampling signal that is correct with the expected signal, indicating that the circuit module under test is fault-free and can work normally. If the first sampling signal is inconsistent with the expected signal, it means that after using the correct new first sampling signal, the first sampling signal is still inconsistent with the expected signal, indicating that there is an internal fault in the circuit under test.

[0062] Furthermore, in step S1, the following steps are also performed:

[0063] The first MCU module also establishes a communication channel with the second MCU module, and sends the first EN signal to the second MCU module through the communication channel.

[0064] Specifically, in order to enable the first MCU module and the second MCU module to exchange signals, the first MCU module also establishes a communication channel with the second MCU module, and sends the first EN signal to the second MCU module through the communication channel, so that the first MCU module and the second MCU module can determine whether there is a fault in the circuit module under test through mutual interaction.

[0065] Furthermore, the first MCU module and the second MCU module compare the first sampled signal with the expected signal for the first time, including the following steps:

[0066] Step S31: After receiving the first sampling signal, the first MCU module compares the first sampling signal with the expected signal to obtain a first comparison result, where the first comparison result includes two situations: consistency and inconsistency;

[0067] Step S32: After receiving the first sampling signal, the second MCU module compares the first sampling signal with the expected signal to obtain a second comparison result, where the second comparison result includes two situations: consistency and inconsistency;

[0068] Step S33: the first MCU module sends the first comparison result to the second MCU module through the communication channel, and the second MCU module sends the second comparison result to the first MCU module through the communication channel;

[0069] Step S34: If the first comparison result and the second comparison result are both consistent, it is determined that the first sampling signal is consistent with the expected signal; otherwise, it is determined that the first sampling signal is inconsistent with the expected signal.

[0070] Specifically, after the first MCU module receives the first sampling signal, it compares the first sampling signal with the expected signal to obtain a first comparison result. The first comparison result includes two situations: consistency and inconsistency. If the first MCU module determines that the first sampling signal is consistent with the expected signal, and the second MCU module also determines that the first sampling signal is consistent with the expected signal, then it can be more accurately explained that the first sampling signal and the expected signal are consistent. If the first MCU module determines that the first sampling signal is consistent with the expected signal, or the second MCU module also determines that the first sampling signal and the expected signal are inconsistent, or both determine that the first sampling signal and the expected signal are inconsistent, then it means that the first sampling signal and the expected signal are inconsistent. The above method can accurately determine whether the first sampling signal and the expected signal are consistent.

[0071] Further, comparing the first sampled signal with the expected signal to obtain a first comparison result includes the following steps:

[0072] Signal conditioning is performed on the first sampling signal, key parameters are extracted from the conditioned first sampling signal, the key parameters including amplitude, frequency, phase and timestamp, and the key parameters are compared with key parameters of the expected signal to obtain a first comparison result.

[0073] Specifically, by acquiring key parameters of the first sampled signal and the expected signal through the above method, and subsequently comparing the first sampled signal and the expected signal based on the key parameters, a more accurate comparison result can be obtained.

[0074] Further, comparing the key parameter with the key parameter of the expected signal to obtain a first comparison result includes the following steps:

[0075] It is determined whether each key parameter of the first sampling signal is within the threshold range of each key parameter of the expected signal. If each key parameter is within the threshold range of the corresponding key parameter of the expected signal, it is determined that the first comparison result of the first sampling signal and the expected signal is consistent; otherwise, the first comparison result is inconsistent.

[0076] Specifically, the above method is used to determine whether the key parameter of the first sampling signal is within the key parameter threshold range of the expected signal. If so, it indicates that the first sampling signal is consistent with the expected signal, otherwise, it indicates that they are inconsistent, and a more accurate comparison result can be obtained.

[0077] Furthermore, the expected signal means that there is a set of preset standards inside the first MCU module and the second MCU module. Based on the preset standards, the first MCU module and the second MCU module can output the expected signal based on the first EN signal. The preset standard may be a theoretical model of circuit design, or a signal characteristic under normal working conditions in historical data.

[0078] Furthermore, the process sampling module samples the internal signal of the circuit module under test, including the following steps:

[0079] Real-time detection of environmental parameters, including temperature and humidity, etc., evaluate the impact of environmental parameters on signal quality to obtain the first environmental parameter, which refers to the environmental parameter with the greatest impact on signal quality, set sampling rules, and increase the sampling frequency under specific circumstances.

[0080] Specifically, in order to improve the accuracy and efficiency of detection, the environmental parameters are detected in real time to obtain the environmental parameters that have the greatest impact on signal quality, set sampling rules, and increase the sampling frequency in specific circumstances, such as increasing the sampling frequency in a high-noise environment to capture more signal details. The above method can dynamically adjust the sampling frequency based on the environmental parameters to improve the accuracy and efficiency of detection.

[0081] Further, evaluating the influence of the environmental parameter on the signal quality to obtain the first environmental parameter includes the following steps:

[0082] The sampling signals and corresponding environmental parameters in the historical sampling process are obtained. For each type of environmental parameter, the corresponding key signal features are obtained based on the sampling signals. The key signal features refer to the amplitude values ​​of the signals. The correlation coefficients between different environmental parameter values ​​and the key signal features are calculated, and the environmental parameter with the largest correlation coefficient is taken as the first environmental parameter.

[0083] Specifically, obtaining the first environmental parameter that has the greatest impact on signal quality through the above method is helpful to collect more detailed signal samples.

[0084] According to another aspect of the embodiment of the present invention, Figure 3 As shown, a dual-MCU-based internal module circuit verification system is also provided, including a signal driving unit, a signal sampling unit, a signal comparison unit, a detection processing unit and a fault judgment unit, which is used to implement an internal module circuit verification method based on a dual-MCU as described above. The specific functions of each unit are as follows:

[0085] A signal driving unit, used for sending a first EN signal to a driving circuit module, and the driving circuit module sends a first SignalEN signal after receiving the first EN signal, and sends it to the circuit module under test, and the circuit module under test outputs an internal signal after internal processing;

[0086] The signal sampling unit is used for sampling the internal signal of the circuit module under test by the process sampling module during the process of the circuit module under test outputting the internal signal, outputting the first sampling signal, and sending the first sampling signal to the first MCU module and the second MCU module;

[0087] The signal comparison unit, the first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time, if it is found that the first sampling signal is consistent with the expected signal, it means that the circuit module under test works normally, if it is found that the first sampling signal is inconsistent with the expected signal, the detection processing unit is executed;

[0088] The detection processing unit, the first MCU module turns off the output of the first EN signal, the second MCU module sends a second EN signal and a second SignalEN signal, and constructs a new second sampling signal to the circuit module under test through the enabling circuit module and the verification signal construction module;

[0089] The fault judgment unit samples the internal signal output by the circuit module under test for the second time after the second sampling signal is input into the circuit module under test, obtains a new first sampling signal, and inputs the new first sampling signal into the first MCU module and the second MCU module to judge the fault information.

[0090] In summary, the present invention proposes a method and system for verifying an internal module circuit based on a dual MCU, the method includes a first MCU module sending a first EN signal to drive the circuit module under test to generate an internal signal, a process sampling module collects and samples the internal signal of the circuit module under test to obtain a first sampling signal, and the first MCU module and the second MCU module compare to find out whether the first sampling signal is consistent with the expected signal. If they are consistent, it is judged that the circuit module under test is working normally, otherwise the first MCU module is turned off and sends a first EN signal, and the second MCU module sends a second EN signal and a second Signal signal to construct a second sampling signal, and the circuit module under test is sampled for a second time based on the second sampling signal to obtain a new first sampling signal, and the fault is judged based on the new first sampling signal. The present invention can realize the rapid judgment of circuit faults by self-checking the circuit.

[0091] It should be understood that, although each step in the flow chart of each embodiment of the present invention is shown in sequence according to the indication of the arrow, these steps are not necessarily performed in sequence according to the order indicated by the arrow. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be performed in other orders. Moreover, at least a portion of the steps in each embodiment may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these sub-steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.

[0092] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program. The above-mentioned program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

[0093] The technical features of the above-mentioned embodiments can be combined arbitrarily. In order to make the description concise, not all possible combinations of the technical features in the above-mentioned embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0094] The above-mentioned embodiments only express several implementation methods of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the patent of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.

[0095] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A method for verifying an internal module circuit based on dual MCUs, characterized in that: The steps include: Step S1, the first MCU module sends a first EN signal to the driving circuit module, and the driving circuit module sends a first SignalEN signal after receiving the first EN signal, and sends it to the circuit module under test, and the circuit module under test outputs an internal signal after internal processing; Step S2: When the circuit module under test outputs the internal signal, the process sampling module samples the internal signal of the circuit module under test, outputs a first sampling signal, and sends the first sampling signal to the first MCU module and the second MCU module; Step S3, the first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time. If it is found that the first sampling signal is consistent with the expected signal, it indicates that the circuit module under test works normally. If it is found that the first sampling signal is inconsistent with the expected signal, step S4 is executed; Step S4, the first MCU module turns off the output of the first EN signal, the second MCU module sends a second EN signal and a second SignalEN signal, and constructs a new second sampling signal to the circuit module under test through the enabling circuit module and the verification signal construction module; Step S5: After the second sampling signal is input into the circuit module under test, the internal signal output by the circuit module under test is sampled for the second time to obtain a new first sampling signal, and the new first sampling signal is input into the first MCU module and the second MCU module to determine fault information.

2. The method according to claim 1, characterized in that: Determining fault information includes the following steps: Step S51: the first MCU module and the second MCU module compare the new first sampling signal with the expected signal for the second time. If the new first sampling signal is consistent with the expected signal, it indicates that the circuit module under test is working normally. Step S52: If the new first sampling signal is still inconsistent with the expected signal, it indicates that there is an internal fault in the circuit module under test.

3. The method according to claim 1, characterized in that In step S1, the following steps are also performed: The first MCU module also establishes a communication channel with the second MCU module, and sends the first EN signal to the second MCU module through the communication channel.

4. The method according to claim 1, characterized in that The first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time, including the following steps: Step S31: After receiving the first sampling signal, the first MCU module compares the first sampling signal with the expected signal to obtain a first comparison result, where the first comparison result includes two situations: consistency and inconsistency; Step S32: After receiving the first sampling signal, the second MCU module compares the first sampling signal with the expected signal to obtain a second comparison result, where the second comparison result includes two situations: consistency and inconsistency; Step S33: the first MCU module sends the first comparison result to the second MCU module through the communication channel, and the second MCU module sends the second comparison result to the first MCU module through the communication channel; Step S34: If the first comparison result and the second comparison result are both consistent, it is determined that the first sampling signal is consistent with the expected signal; otherwise, it is determined that the first sampling signal is inconsistent with the expected signal.

5. The method according to claim 4, characterized in that Comparing the first sampled signal with the expected signal to obtain a first comparison result includes the following steps: Signal conditioning is performed on the first sampling signal, key parameters are extracted from the conditioned first sampling signal, the key parameters including amplitude, frequency, phase and timestamp, and the key parameters are compared with key parameters of the expected signal to obtain a first comparison result.

6. The method according to claim 5, characterized in that Comparing the key parameter with the key parameter of the expected signal to obtain a first comparison result comprises the following steps: Determine whether each key parameter of the first sampling signal is within the threshold range of each key parameter of the expected signal; if each of the key parameters is within the threshold range of the corresponding key parameter of the expected signal, determine that the first comparison result of the first sampling signal and the expected signal is consistent; otherwise, the first comparison result is inconsistent.

7. The method according to claim 1, characterized in that The expected signal means that there is a set of preset standards inside the first MCU module and the second MCU module. Based on the preset standards, the first MCU module and the second MCU module can output the expected signal based on the first EN signal. The preset standards may be a theoretical model of circuit design, or signal characteristics under normal working conditions in historical data.

8. The method according to claim 1, characterized in that The process sampling module samples the internal signal of the circuit module under test, including the following steps: Real-time detection of environmental parameters, including temperature and humidity, assessing the impact of the environmental parameters on signal quality to obtain a first environmental parameter, the first environmental parameter refers to the environmental parameter that has the greatest impact on signal quality, setting sampling rules, and increasing the sampling frequency under specific circumstances.

9. The method according to claim 8, characterized in that Evaluating the influence of the environmental parameter on the signal quality to obtain the first environmental parameter includes the following steps: Acquire sampling signals and corresponding environmental parameters in the historical sampling process. For each type of environmental parameter, obtain the corresponding key signal feature based on the sampling signal, where the key signal feature refers to the amplitude value of the signal. Calculate the correlation coefficient between different environmental parameter values ​​and the key signal feature, and take the environmental parameter with the largest correlation coefficient as the first environmental parameter.

10. An internal module circuit verification system based on dual MCUs, used to implement an internal module circuit verification method based on dual MCUs as described in any one of claims 1 to 9, characterized in that: The following units are included: A signal driving unit, used for sending a first EN signal to a driving circuit module, and the driving circuit module sends a first SignalEN signal after receiving the first EN signal, and sends it to a circuit module under test, and the circuit module under test outputs an internal signal after internal processing; A signal sampling unit, configured to sample the internal signal of the circuit module under test by a process sampling module during the process in which the circuit module under test outputs the internal signal, output a first sampling signal, and send the first sampling signal to the first MCU module and the second MCU module; A signal comparison unit, wherein the first MCU module and the second MCU module compare the first sampling signal with the expected signal for the first time, and if it is found that the first sampling signal is consistent with the expected signal, it indicates that the circuit module under test is working normally; if it is found that the first sampling signal is inconsistent with the expected signal, a detection processing unit is executed; The detection processing unit, the first MCU module turns off the output of the first EN signal, the second MCU module sends a second EN signal and a second SignalEN signal, and constructs a new second sampling signal to the circuit module under test through an enabling circuit module and a verification signal construction module; The fault judgment unit samples the internal signal output by the circuit module under test for the second time after the second sampling signal is input into the circuit module under test, obtains a new first sampling signal, and inputs the new first sampling signal into the first MCU module and the second MCU module to judge fault information.

Citation Information

Patent Citations

  • Watchdog circuit with signal verification function and working method thereof

    CN114721862A

  • Integrated circuit chip testing system and method

    CN110456257A

  • Fault detection circuit and method, power adapter and electronic equipment

    CN112986803A

  • High-precision ADC acquisition control system suitable for double-MCU hardware architecture

    CN113050476A

  • Fault diagnosis circuit, method and device and computer readable storage medium

    CN113656230A