Simulation test method and system of controller and storage medium

By directly modifying the data of registers in the controller to realize the testing of simulated parameters, the problems of low efficiency, high cost and insufficient accuracy in the existing technology are solved, and efficient, economical and accurate testing results are achieved.

CN119916709APending Publication Date: 2025-05-02SHANGHAI RUIPU ENERGY CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411998678.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-31
Publication Date
2025-05-02

AI Technical Summary

Technical Problem

The simulation testing methods of existing communication device controllers have problems such as low working efficiency, high testing cost and insufficient testing accuracy.

Method used

By directly modifying the data of the registers in the controller based on the simulation parameters, forming a test case and executing it to determine whether the function corresponding to the simulation parameters is tested and passed.

Benefits of technology

Improves work efficiency, reduces testing costs, and significantly improves testing accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119916709A_ABST
    Figure CN119916709A_ABST
Patent Text Reader

Abstract

The invention discloses a simulation testing method and system of a controller and a storage medium, and relates to the field of communication equipment testing. The method comprises the following steps: correspondingly modifying data of a register in a controller according to simulation parameters, and then obtaining a feedback result of the register; the feedback result is used for judging whether the function corresponding to the simulation parameter passes the test. According to the method, the effect of sending different simulation parameters to the controller to change the test environment is realized in a manner of correspondingly modifying the data of the register in the controller directly according to the simulation parameters; the mode not only replaces a test mode of sending different simulation parameters in the prior art, but also omits wiring and signal sending processes, does not cause signal congestion, and further greatly improves the working efficiency; and the value of the register is directly modified to accurately correspond to the specific simulation parameter, and high-precision test equipment is not needed, so that the test cost is remarkably reduced, and the test precision is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of communication equipment testing, and in particular to a simulation testing method, system and storage medium for a controller. Background Art

[0002] During the development of communication equipment, functional testing may be required due to functional defects or other reasons to ensure that the functions implemented by the communication equipment meet the requirements.

[0003] Taking ECU (Electronic Control Unit) as an example, the simulation test of ECU generally uses HIL (Hardware in the Loop) for simulation testing, that is, the real controller is connected to the simulated controlled object (simulated by real-time simulation hardware) for testing.

[0004] However, to simulate the external working environment of the ECU, it is necessary to simulate each hard-wired signal, and change the external working environment according to the change of the hard-wire and communication signal, so as to achieve the test purpose. The ECU test process requires more than 3,000 interactive signals, which will increase exponentially when testing complex systems or multiple controllers together. High-precision test equipment is also required to control the output accuracy of hard-wired signals. Not only is the operation process cumbersome, the work efficiency is low, and the test cost is high.

[0005] At the same time, even if high-precision test equipment is used to control the output accuracy of hard-wired signals, because many observation signals need to be changed during the test execution, and most signals are sent in millisecond cycles, communication congestion and test delays will occur, that is, the test accuracy needs to be improved. Summary of the invention

[0006] In view of the defects existing in the prior art, the technical problem solved by the present invention is to provide a simulation test method for a controller with high working efficiency and low test cost.

[0007] To achieve the above objectives, in the first aspect, an embodiment of the present application provides a simulation test method for a controller, the method comprising the following steps: determining a register write instruction corresponding to a required simulation parameter, the register write instruction comprising a modification value of specified data in the register; according to the register write instruction, modifying the value of the corresponding data of the register, and obtaining a feedback result of the register; the feedback result is used to determine whether the function corresponding to the simulation parameter has passed the test.

[0008] In combination with the first aspect, in one embodiment, the process of determining the register write instruction corresponding to the required simulation parameter and modifying the value of the data corresponding to the register according to the register write instruction includes: forming a test case according to the test conditions, the simulation parameter range required by the test conditions, the execution order of each simulation parameter range, and the modified waiting time range corresponding to each simulation parameter range; when executing the test case, modifying the value of the corresponding data in the register according to the simulation parameter range.

[0009] In combination with the first aspect, in one implementation, the process of obtaining the feedback result of the register includes:

[0010] Read the data modified by the register and its modified value, as well as the calculation result of the register for the modified value;

[0011] When the data modified by the read register and its modified value are the same as the data and its modified value in the register write instruction, determine whether the calculation result of the register is the same as the target result:

[0012] If so, confirm that the function test corresponding to the controller and the test parameters has passed;

[0013] Otherwise, the functional test corresponding to the confirmation controller and the test parameters fails.

[0014] In combination with the first aspect, in one implementation, after the value of the data corresponding to the register is modified according to the register write instruction, the process of obtaining the feedback result of the register further includes:

[0015] When receiving a test case recording instruction and the memory is not full, the test case information is recorded;

[0016] When receiving a test case execution instruction, execute the test case;

[0017] When receiving a test case reading instruction, the test result of the corresponding test case is fed back;

[0018] When receiving a test case deletion instruction, delete the corresponding test case.

[0019] In conjunction with the first aspect, in one implementation, the register write instruction is generated according to the format of the calibration protocol;

[0020] The process of obtaining the feedback result of the register also includes: converting the format of the feedback result according to the calibration protocol.

[0021] In a second aspect, an embodiment of the present application provides a simulation test system for a controller, the system comprising a test module disposed on the controller;

[0022] The test module is used to: implement the method provided by the first aspect.

[0023] In conjunction with the second aspect, in one implementation, the system further includes a test terminal;

[0024] The test terminal is used to: determine the register write instruction corresponding to the required simulation parameter according to the calibration protocol, and send the register write instruction to the test module;

[0025] The test module is specifically used to: modify the value of the data corresponding to the register according to the register write instruction; and send the feedback result of the register to the test terminal.

[0026] In conjunction with the second aspect, in one implementation, the system further includes a bridge;

[0027] The bridge is used to: convert the information sent by the test terminal to the test module into a communication format supported by the test module; and convert the information sent by the test module to the test terminal into a communication format supported by the test terminal.

[0028] In conjunction with the second aspect, in one implementation, the test terminal and the test module are further configured to: verify data consistency using the same verification method when sending and receiving information.

[0029] In a third aspect, an embodiment of the present application provides a computer-readable storage medium, on which a simulation test program of a controller is stored, wherein when the simulation test program of the controller is executed, the method provided in the first aspect is implemented.

[0030] Compared with the prior art, the advantages of the present invention are:

[0031] The present application achieves the effect of changing the test environment by sending different simulation parameters to the controller by directly modifying the data of the register in the controller according to the simulation parameters (that is, directly modifying the corresponding data to the corresponding value according to the simulation parameters); this method not only replaces the test method of sending different simulation parameters in the prior art, that is, it eliminates the wiring and signal sending process, and does not cause signal congestion, thereby greatly improving work efficiency; and directly modifying the value of the register can accurately correspond to the specific simulation parameters, does not require high-precision test equipment, significantly reduces the test cost, and improves the test accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0033] Figure 1 This is a schematic diagram of the architecture of a simulation test system for a controller in an embodiment of the present application;

[0034] Figure 2 A schematic diagram of the workflow of a simulation test system for a controller in an embodiment of the present application;

[0035] Figure 3 This is a schematic diagram of the hardware structure of the simulation test equipment of the controller involved in the embodiment of the present application. DETAILED DESCRIPTION

[0036] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.

[0037] The flowcharts shown in the accompanying drawings are only examples and do not necessarily include all the contents and operations / steps, nor must they be executed in the order described. For example, some operations / steps may also be decomposed, combined or partially merged, so the actual execution order may change according to actual conditions.

[0038] First, the research and development principle of this application is briefly explained.

[0039] The inventors have found that the specific process of the existing controller testing solution is generally as follows:

[0040] The test terminal (PC) is operated to send the simulation parameters (such as cell voltage, cell temperature, current, etc.) required for the test to the lower computer. The lower computer interprets and analyzes the messages sent by the PC and forwards them to the corresponding output boards to simulate the corresponding simulation parameters for ECU sampling. After the ECU sampling is completed, the above information is calculated and processed, and the sampled values ​​are fed back to the lower computer. After receiving the ECU message, the lower computer feeds back to the PC, and the PC displays the above information to the tester for viewing and analysis.

[0041] On this basis, if the problems of the prior art are to be solved, it is necessary to reduce the number of simulation parameters, or not to simulate the parameters but require the ECU to be able to generate feedback corresponding to the simulation parameters.

[0042] In order to reduce the number of simulation parameters, composite signals can be used, but no corresponding specific solution has been developed for this method.

[0043] For not using simulation parameters, the inventors further developed that the ECU can generate feedback corresponding to the simulation parameters, which is actually a change in the value corresponding to the simulation parameters in the register in the ECU. Then, by directly changing the value of the register, the test effect of the simulation parameters can be achieved without using the simulation parameters.

[0044] On this basis, in order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below in conjunction with the accompanying drawings.

[0045] In the first aspect, an embodiment of the present application provides a simulation test method for a controller, the steps of the method comprising: determining a register write instruction corresponding to a required simulation parameter, the register write instruction comprising an ID and a modification value of specified data in the register; according to the register write instruction, modifying the value of the data corresponding to the register, and obtaining a feedback result of the register, the feedback result being used to determine whether the function corresponding to the simulation parameter has passed the test.

[0046] Among them, the ID of the data specified by the register is the address of the parameter to be simulated in the register, the modified value is the test value of the parameter to be simulated, and the value of the corresponding data of the register is modified according to the register write instruction, including writing the modified value to the ID of the specified data in the register to realize the writing of the test data, so as to make the controller test the modified value when the simulated parameter is required, and feed back the test result to the register. Exemplarily, taking the battery cell voltage as an example, the register write instruction includes the ID of the battery cell voltage in the register of the controller and the modified value of the battery cell voltage, and the value of the battery cell voltage in the register is modified to the modified value. After the value of the battery cell voltage in the register is modified to the modified value, the controller is tested according to the modified value, and the test result of the modified value is written to the register. The feedback result of the register is obtained to determine whether the function corresponding to the simulation parameter has passed the test.

[0047] It can be seen from this that the present application achieves the effect of changing the test environment by sending different simulation parameters to the controller by directly modifying the data of the registers in the controller according to the simulation parameters (that is, directly modifying the corresponding data to the corresponding values ​​according to the simulation parameters); this method not only replaces the test method of sending different simulation parameters in the prior art, that is, it eliminates the wiring and signal sending process, and does not cause signal congestion, thereby greatly improving work efficiency; and directly modifying the value of the register can accurately correspond to the specific simulation parameters, does not require high-precision testing equipment, and significantly reduces the testing cost.

[0048] In one embodiment, the process of determining the register write instruction corresponding to the required simulation parameter in the above method and modifying the value of the data corresponding to the register according to the register write instruction includes: forming a test case according to the test conditions, the simulation parameter range required by the test conditions, the execution order of each simulation parameter range, and the modified waiting time range corresponding to each simulation parameter range; the simulation parameter range and the waiting time range can both be point values ​​or range values. When executing the test case, the value of the corresponding data in the register is modified according to the simulation parameter range.

[0049] For ease of understanding, the following is an illustrative example of testing a controller in a battery management system. The test conditions are determined according to the items to be tested. For example, when the item to be tested is a low voltage fault, the test conditions may include: 1) When the cell temperature is less than 0°C and the cell voltage is less than 2500mV, it lasts for 2000ms, triggering a cell voltage low fault of one level; 2) When the cell temperature is ≥0°C and the cell voltage is ≤2800mV, it lasts for 2000ms, triggering a cell voltage low fault of one level; Based on this, the simulation parameter range and waiting time range required under the test conditions can be set to: cell voltage range is [2500mV, 2800mV], cell temperature range is [-1°C, 0°C], waiting time range is [0ms, 2000ms]; In order to further ensure the accuracy of the test, the test case can also set the offset of the required simulation parameter. When the simulation parameter range and waiting time range are range values, the step value of the required simulation parameter also needs to be set. Taking the above as an example, the simulation parameter range and step value, offset, waiting time range and step value of the required simulation parameter can be:

[0050] Cell voltage: [2500mV, 2800mV], 50mV, 50mV, [0ms, 2000ms], 100ms;

[0051] Battery cell temperature: [-1°C, 0°C], 1°C, 2°C, [0ms, 2000ms], 100ms;

[0052] The step value and offset of the analog parameter range may be consistent or inconsistent. For example, the step value and offset of the cell voltage may be consistent at 50mV, and the step value and offset of the cell temperature may be inconsistent at 1°C and 2°C respectively.

[0053] During execution, the first use case: set the cell voltage to 2450mV, wait for 0ms, set the cell temperature to -3℃, wait for 0ms, and obtain the feedback result of the register; the second use case: set the cell voltage to 2500mV, wait for 0ms, set the cell temperature to -3℃, wait for 0ms, and obtain the feedback result of the register; and so on, until the nth use case: set the cell voltage to 2850mV, wait for 2000ms, set the cell temperature to 2℃, wait for 2000ms, and obtain the feedback result of the register.

[0054] It should be noted that the above test cases are only exemplary. Other simulation parameter ranges, offsets, waiting time ranges and step values ​​can also be set under the above test conditions, as long as the test conditions can be met; in addition, the execution order of the test cases can be specified by the PC, and specifically can be random, sequential, reverse order, specified order, etc. according to the actual test cases, and the embodiments of the present application do not limit this.

[0055] It can be seen that the present application performs simulation testing of the controller by means of test cases. Different test conditions in the test cases and different simulation parameters under each test condition can correspond to different working conditions of the controller, thereby improving the coverage of the simulation test. Moreover, by using test cases to perform simulation testing of the controller, automatic testing of the simulation parameters within a preset range can be achieved. Compared with the prior art, each change in the test value of a simulation parameter requires data modification and transmission, which greatly improves the test efficiency.

[0056] In one embodiment, the process of obtaining the feedback result of the register in the above method includes: reading the data modified by the register and its modified value, and the calculation result of the register for the modified value.

[0057] On this basis, after obtaining the feedback result of the register, the above method further includes the following steps:

[0058] Determine whether the data modified by the read register and its modified value are the same as the data and its modified value in the register write instruction:

[0059] If not, it means that the data received by the register is wrong. At this time, confirm that the current operation of the register is invalid and retest;

[0060] If so, determine whether the calculation result of the register is the same as the target result (the target result can be calculated in advance based on the modified value). If so, confirm that the functional test corresponding to the controller and the test parameters has passed, otherwise confirm that the functional test corresponding to the controller and the test parameters has failed.

[0061] It can be seen that this application will have multiple read and write register operations during testing, and the normal read and write timing is:

[0062] Modifying the register value according to the simulation parameters is a write operation;

[0063] To obtain feedback information from a register, a read operation is performed;

[0064] Of course, before each writing, a step of obtaining the state of the register through a read operation may be added, and the specific execution method is selected according to different requirements.

[0065] In one embodiment, after the value of the data corresponding to the register is modified according to the register write instruction in the above method, the process of obtaining the feedback result of the register further includes:

[0066] When receiving the instruction to record a test case, determine whether the memory is full. If so, do not record the test case information and give an alarm feedback. Otherwise, record the test case information and give a recording completion feedback.

[0067] When receiving a test case execution instruction, execute the test case;

[0068] When receiving the test case reading instruction, the test result of the corresponding test case is fed back; this is passive feedback (i.e. feedback after receiving the instruction), and in actual application, active feedback can also be given, i.e. the result is automatically fed back after the test case is executed;

[0069] When receiving a test case deletion instruction, delete the corresponding test case.

[0070] In one embodiment, the read and write operations of the registers in the above method are all based on the calibration protocol (the calibration protocol can directly use the elf file generated when the ECU program file is compiled, and the file contains the register ID and data range corresponding to the variables), that is, the register write instruction is generated according to the format of the calibration protocol; after obtaining the feedback result of the register, the format conversion is performed according to the calibration protocol.

[0071] In a second aspect, an embodiment of the present application further provides a simulation test system for a controller, which is used to implement the steps of the method mentioned in the first aspect.

[0072] In one embodiment, the system includes a test module disposed on the controller, and the module is used to: modify the value of the data corresponding to the register according to the register write instruction, and obtain the feedback result of the register.

[0073] For further information, see Figure 1 As shown, the system also includes a test terminal (PC), a controller and a power supply.

[0074] The power supply is used to: provide power to the controller.

[0075] The test terminal is used to: determine the register write instruction corresponding to the required simulation parameters according to the calibration protocol, and then send the register write instruction to the test module.

[0076] The test module is specifically used to: modify the value of the data corresponding to the register according to the register write instruction; and send the feedback result of the register to the test terminal.

[0077] At the same time, the test terminal and the test module are also used to verify the consistency of data using the same verification method (such as CheckSum) when sending and receiving information.

[0078] For further information, see Figure 1 As shown, the system also includes a bridge, which is used to: convert information sent by the test terminal to the test module into a communication format supported by the controller to which the test module belongs; convert information sent by the test module to the test terminal into a communication format supported by the test terminal.

[0079] It can be seen that in actual use, the bridge can be any communication device. When the controller and PC support the same communication protocol, they can work normally without a bridge. When the controller and PC cannot support the same protocol, a bridge is required to act as a communication hub between the controller and PC.

[0080] The following describes the working process of the above system in chronological order through a specific embodiment.

[0081] First, the system architecture of this embodiment is described.

[0082] The controller of this embodiment is the ECU under test, and a test module is provided on the ECU. The test module is configured with an ECU test auxiliary program for realizing its functions; the operation terminal is a PC; and the ECU and the PC use CheckSum to perform consistency verification of sent and received information.

[0083] See also Figure 1 and Figure 2 As shown in the figure, the workflow of this system includes:

[0084] S1: The tester confirms that the basic ECU program required by the development requirements and the ECU test auxiliary program are working properly (if not, an alarm will be issued), initializes the communication channel configuration between the ECU and the bridge, and goes to S2.

[0085] S2: The tester forms a test case on the PC and sends it to the bridge according to the calibration protocol, that is, sends the test conditions, the simulation parameter range required for the test conditions, the execution order of each simulation parameter range, and the modified waiting time range corresponding to each simulation parameter range to the bridge, and then goes to S3.

[0086] S3: After the bridge converts the test case into a communication format supported by the ECU test assistant program, it sends it to the ECU test assistant program and goes to S4.

[0087] S4: The ECU test assistant executes the test case (modifies the corresponding value in the test case and waits for the corresponding time after modification; obtains the feedback result after execution is completed; converts the feedback result into a format according to the calibration protocol and sends it to the bridge, and then goes to S5.

[0088] S5: The feedback result of the bridge register is converted into a communication format supported by the PC, sent to the PC, and then goes to S6.

[0089] S6: The PC displays the feedback results for the tester to observe and analyze to obtain the test results.

[0090] By repeating S2 to S6, the ECU can be simulated and tested under different working conditions.

[0091] To sum up, the present application can directly and accurately change the signal value in the ECU register based on the calibration protocol, thereby changing the ECU working environment configuration, which not only solves the problems of high cost and cumbersome operation in simulating the external working environment of the ECU in the prior art, as well as the problem of insufficient accuracy when using functional devices to simulate the ECU working environment in the prior art; and the present application combines the calibration protocol to directly and accurately change the corresponding numerical value in the register according to the simulation parameters, thereby improving the reliability of the ECU test verification process.

[0092] In a third aspect, an embodiment of the present application provides a simulation test device for a controller, which may be a personal computer (PC), a laptop computer, a server, or other device with data processing capabilities.

[0093] Reference Figure 3 , Figure 3 The hardware structure diagram of the simulation test device of the controller involved in the embodiment of the present application is shown in FIG. In the embodiment of the present application, the simulation test device of the controller may include a processor, a memory, a communication interface and a communication bus.

[0094] The communication bus may be of any type and is used to interconnect the processor, the memory, and the communication interface.

[0095] The communication interface includes input / output (I / O) interface, physical interface and logical interface, etc., which are used to realize the interconnection of devices inside the simulation test equipment of the controller, and the interface used to realize the interconnection between the simulation test equipment of the controller and other devices (such as other computing devices or user devices). The physical interface can be an Ethernet interface, a fiber optic interface, an ATM interface, etc.; the user device can be a display, a keyboard, etc.

[0096] The memory can be various types of storage media, such as random access memory (RAM), read-only memory (ROM), non-volatile RAM (NVRAM), flash memory, optical storage, hard disk, programmable ROM (PROM), erasable PROM (EPROM), electrically erasable PROM (EEPROM), etc.

[0097] The processor may be a general-purpose processor, and the general-purpose processor may call the simulation test program of the controller stored in the memory, and execute the simulation test method of the controller provided in the embodiment of the present application. For example, the general-purpose processor may be a central processing unit (CPU). The method executed when the simulation test program of the controller is called may refer to the various embodiments of the simulation test method of the controller of the present application, which will not be repeated here.

[0098] Those skilled in the art will understand that Figure 3 The hardware structure shown in the figure does not constitute a limitation on the present application, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.

[0099] In a fourth aspect, an embodiment of the present application also provides a computer-readable storage medium.

[0100] The computer-readable storage medium of the present application stores a simulation test program for a controller, wherein when the simulation test program for the controller is executed by a processor, the steps of the simulation test method for the controller as described above are implemented.

[0101] Among them, the method implemented when the simulation test program of the controller is executed can refer to the various embodiments of the simulation test method of the controller of the present application, and will not be repeated here.

[0102] It should be noted that the serial numbers of the above-mentioned embodiments of the present application are only for description and do not represent the advantages or disadvantages of the embodiments.

[0103] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, disk, CD) as described above, and includes a number of instructions for a terminal device to execute the methods described in each embodiment of the present application.

[0104] The terms "including" and "having" and any variations thereof in the specification and claims of this application and the above-mentioned drawings are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices. The terms "first", "second" and "third" are used to distinguish different objects, etc., and do not represent a sequence, nor do they limit "first", "second" and "third" to different types.

[0105] In the description of the embodiments of the present application, "exemplary", "for example" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary", "for example" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary", "for example" or "for example" is intended to present related concepts in a specific way.

[0106] In the description of the embodiments of the present application, unless otherwise specified, “ / ” means or, for example, A / B can mean A or B; the “and / or” in the text is merely a description of the association relationship of associated objects, indicating that three relationships may exist, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, “multiple” refers to two or more than two.

[0107] In some processes described in the embodiments of the present application, multiple operations or steps that appear in a specific order are included, but it should be understood that these operations or steps may not be executed in the order in which they appear in the embodiments of the present application or in parallel, and the sequence number of the operation is only used to distinguish the different operations, and the sequence number itself does not represent any execution order. In addition, these processes may include more or fewer operations, and these operations or steps may be executed in sequence or in parallel, and these operations or steps may be combined.

[0108] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, disk, CD) as described above, and includes a number of instructions for a terminal device to execute the methods described in each embodiment of the present application.

[0109] The above are only specific implementations of the embodiments of the present invention, but the protection scope of the embodiments of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in the embodiments of the present invention, and these modifications or replacements should be included in the protection scope of the embodiments of the present invention. Therefore, the protection scope of the embodiments of the present invention shall be based on the protection scope of the claims.

Claims

1. A simulation test method for a controller, characterized in that: The method includes the following steps: determining a register write instruction corresponding to a required simulation parameter, the register write instruction including a modification value of specified data in the register; modifying the value of the data corresponding to the register according to the register write instruction, and obtaining a feedback result of the register; the feedback result is used to determine whether the function corresponding to the simulation parameter has passed the test.

2. The simulation test method of the controller according to claim 1, characterized in that: The process of determining the register write instruction corresponding to the required simulation parameter and modifying the value of the data corresponding to the register according to the register write instruction includes: forming a test case according to the test conditions, the simulation parameter range required by the test conditions, the execution order of each simulation parameter range, and the modified waiting time range corresponding to each simulation parameter range; when executing the test case, modifying the value of the corresponding data in the register according to the simulation parameter range.

3. The simulation test method of the controller according to claim 2, characterized in that: The process of obtaining the feedback result of the register includes: Read the data modified by the register and its modified value, as well as the calculation result of the register for the modified value; When the data modified by the read register and its modified value are the same as the data and its modified value in the register write instruction, determine whether the calculation result of the register is the same as the target result: If so, confirm that the function test corresponding to the controller and the test parameters has passed; Otherwise, the functional test corresponding to the confirmation controller and the test parameters fails.

4. The simulation test method of the controller according to claim 3, characterized in that: After the value of the data corresponding to the register is modified according to the register write instruction, the process of obtaining the feedback result of the register also includes: When receiving a test case recording instruction and the memory is not full, the test case information is recorded; When receiving a test case execution instruction, execute the test case; When receiving a test case reading instruction, the test result of the corresponding test case is fed back; When receiving a test case deletion instruction, delete the corresponding test case.

5. The simulation test method of the controller according to any one of claims 1 to 4, characterized in that: The register write instruction is generated according to the format of the calibration protocol; The process of obtaining the feedback result of the register also includes: converting the format of the feedback result according to the calibration protocol.

6. A simulation test system for a controller, characterized in that: The system includes a test module disposed on a controller; The test module is used to: execute the process described in any one of claims 1 to 5, after modifying the data of the register in the controller according to the simulation parameters to be tested, and then obtain the feedback result of the register.

7. The simulation test system of the controller according to claim 6, characterized in that: The system also includes a test terminal; The test terminal is used to: determine the register write instruction corresponding to the required simulation parameter according to the calibration protocol, and send the register write instruction to the test module; The test module is specifically used to: modify the value of the data corresponding to the register according to the register write instruction; and send the feedback result of the register to the test terminal.

8. The simulation test system of the controller according to claim 7, characterized in that: The system also includes a bridge; The bridge is used to: convert the information sent by the test terminal to the test module into a communication format supported by the test module; and convert the information sent by the test module to the test terminal into a communication format supported by the test terminal.

9. The simulation test system for a controller according to any one of claims 6 to 8, characterized in that: The test terminal and the test module are also used to verify the consistency of data using the same verification method when sending and receiving information.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a simulation test program for a controller, wherein when the simulation test program for the controller is executed, the steps of the simulation test method for a controller as claimed in any one of claims 1 to 5 are implemented.