A motor controller testing system and method

A testing system consisting of a battery simulator and a motor simulator replaces the real motor for motor controller testing, solving the problems of high testing costs, safety risks, and high noise, and achieving safe, low-cost, and efficient testing results.

CN123137281APending Publication Date: 2026-11-20DONGFENG MOTOR GRP
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611457934.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-09-18
Publication Date
2026-11-20

AI Technical Summary

Technical Problem

Existing motor controller testing systems rely on real motors for testing, resulting in high testing costs, safety risks associated with high-voltage rotating machinery, and excessive noise.

Method used

A testing system consisting of a battery simulator, a motor simulator, and a host computer is used. The motor simulator replaces the real motor for testing, forming a closed-loop test circuit. The host computer configures the mathematical model of the motor and controls the output voltage of the battery simulator, and collects feedback data from the motor controller.

Benefits of technology

While maintaining testing accuracy, this technology enables safe, low-cost, and flexibly configurable closed-loop testing of electromagnetic characteristics, lowering the testing threshold and improving testing efficiency, and solving the safety risks and noise problems in existing technologies.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123137281A_ABST
    Figure CN123137281A_ABST
Patent Text Reader

Abstract

The application discloses a motor controller test system and method, and relates to the technical field of motor controller testing.The system comprises a battery simulator, a motor simulator and an upper computer.The battery simulator is electrically connected with a motor controller to be tested.The motor controller is electrically connected with the motor simulator.The motor simulator is connected with the motor controller.The upper computer is configured to send a physical parameter configuration instruction to the motor simulator to set the physical parameters of the motor mathematical model of the motor simulator, send an output instruction to the battery simulator to make the battery simulator output a preset DC bus voltage to the motor controller, send a control instruction to the motor controller to drive the motor simulator to operate, and receive the operating state data fed back by the motor controller to complete the performance test of the motor controller.The application solves the problems of high test cost, high safety risk of high-voltage rotating machinery and high noise caused by the dependence on real motors for testing in the prior art.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of motor controller testing technology, and in particular to a motor controller testing system and method. Background Technology

[0002] With the rapid development of the new energy vehicle industry, the motor controller, as a core component of the drive system, directly affects the vehicle's power, economy, and safety. During the development and verification phase of the motor controller, extensive testing is required to ensure the accuracy of the control strategy and the reliability of the hardware.

[0003] In existing technologies, motor controller testing typically involves using a real motor on a test bench. However, this method, based on a real motor, has the following drawbacks: 1. Testing requires real motor prototypes, which is costly and takes a long time to obtain, making it difficult to conduct large-scale testing in the early stages of development; 2. Real motor testing involves high-voltage electricity and high-speed rotating machinery, posing significant risks to personal safety and equipment damage. 3. Real motors are noisy when running, so the environmental requirements for the testing site are high. Summary of the Invention

[0004] This invention provides a motor controller testing system and method to solve the technical problems of existing motor controller testing systems that rely on real motors for testing, resulting in high testing costs, safety risks associated with high-voltage rotating machinery, and high noise levels.

[0005] In a first aspect, a motor controller testing system is provided, comprising: a battery simulator, a motor simulator, and a host computer, wherein the motor simulator is configured with a motor mathematical model; The high-voltage output terminal of the battery simulator is electrically connected to the high-voltage input terminal of the motor controller under test. The control output terminal of the motor controller is electrically connected to the control input terminal of the motor simulator; The sensor signal output terminal of the motor simulator is connected to the sensor signal input terminal of the motor controller; The host computer is communicatively connected to the motor controller, the battery simulator, and the motor simulator, and is configured as follows: Send a physical parameter configuration command to the motor simulator to set the physical parameters of the motor mathematical model of the motor simulator; Send an output command to the battery simulator to cause the battery simulator to output a preset DC bus voltage to the motor controller; Control commands are sent to the motor controller to drive the motor simulator to run, and the operating status data fed back by the motor controller are received to complete the performance test of the motor controller.

[0006] In some embodiments, sending control commands to the motor controller to drive the motor simulator to run and receiving operating status data fed back by the motor controller to complete the performance test of the motor controller includes: Based on a preset vehicle driving condition curve, the driving condition curve is converted into a control command for the target torque and sent to the motor controller to simulate the operating state of the motor controller during actual vehicle driving; wherein, the preset vehicle driving condition curve includes at least one of NEDC, WLTC or CLTC driving condition curves.

[0007] In some embodiments, the step of sending control commands to the motor controller to drive the motor simulator to run and receiving operating status data fed back by the motor controller to complete the performance test of the motor controller further includes: The steady-state error and dynamic error are calculated based on the actual torque in the operating status data fed back by the motor controller and the target torque of the motor controller. The torque control accuracy of the motor controller is evaluated based on steady-state error and dynamic error.

[0008] In some embodiments, calculating the steady-state error and dynamic error based on the actual torque in the operating status data fed back by the motor controller and the target torque of the motor controller includes: Multiple sampling points of the motor simulator within the steady-state operating range are selected, and the absolute value of the deviation between the actual torque and the target torque at each sampling point is calculated. The maximum value among them is taken as the maximum steady-state error. Multiple sampling points are selected within the dynamic operating range of the motor simulator. The absolute value of the deviation between the actual torque and the target torque at each sampling point is calculated, and the maximum value is taken as the maximum dynamic error.

[0009] In some embodiments, the battery simulator includes an overvoltage protection unit and an overcurrent protection unit. When the output voltage of the battery simulator exceeds a preset voltage threshold or the output current exceeds a preset current threshold, the battery simulator automatically cuts off the high voltage output and sends a fault alarm signal to the host computer.

[0010] In some embodiments, the host computer, the motor controller, the battery simulator, and the motor simulator are connected via an Ethernet switch.

[0011] In some embodiments, the host computer is also used to store multiple sets of physical parameter configuration files, and each set of physical parameter configuration files corresponds to a motor type of the motor simulator.

[0012] In some embodiments, the motor mathematical model of the motor simulator is based on A mathematical model is established using a rotating coordinate system, wherein the rotational speed and rotor position are used as state variables. When the rotational speed and rotor position are respectively set to preset speed values ​​and preset position values, the coefficient matrix of the mathematical model is transformed from a time-varying matrix into a constant matrix.

[0013] In some embodiments, the physical parameters include at least direct-axis inductance, quadrature-axis inductance, permanent magnet flux linkage, stator resistance, and number of pole pairs. The motor simulator is configured to calculate the motor's voltage equation, torque equation, and flux linkage equation based on the physical parameters to simulate the motor's operating characteristics.

[0014] Secondly, a test method for a motor controller is provided, including the following steps: Electrically connect the high-voltage output terminal of the battery simulator to the high-voltage input terminal of the motor controller, electrically connect the control output terminal of the motor controller to the control input terminal of the motor simulator, connect the sensor signal output terminal of the motor simulator to the sensor signal input terminal of the motor controller, and connect the host computer to the motor controller, the battery simulator, and the motor simulator for communication respectively. The host computer sends physical parameter configuration instructions to the motor simulator to set the physical parameters of the motor mathematical model of the motor simulator; The host computer sends an output command to the battery simulator, causing the battery simulator to output a preset DC bus voltage to the motor controller. The host computer sends control commands to the motor controller to drive the motor simulator to run, and receives the running status data fed back by the motor controller to complete the performance test of the motor controller.

[0015] The beneficial effects of the technical solution provided by this invention include: This invention provides a motor controller testing system and method. The testing system connects a battery simulator, a motor simulator, and a motor controller under test via a host computer. The high-voltage output of the battery simulator, the three-phase output of the motor controller, the input of the motor simulator, and the sensor signal terminals are sequentially electrically connected to form a closed-loop test circuit. The host computer configures the physical parameters of the motor mathematical model in the motor simulator, controls the output voltage of the battery simulator, and collects the operating status data fed back by the motor controller to complete the performance test. This invention replaces the actual physical motor in traditional testing with a motor simulator. While maintaining testing accuracy, it achieves safe, low-cost, and flexibly configurable closed-loop testing of electromagnetic characteristics without the need for a physical motor. This effectively lowers the testing threshold and improves testing efficiency, effectively solving the technical problems of high testing costs, safety risks associated with high-voltage rotating machinery, and high noise levels caused by relying on actual motors in existing technologies. Attached Figure Description

[0016] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0017] Figure 1 This is a schematic diagram of the structure of a motor controller testing system provided in an embodiment of the present invention; Figure 2 A schematic diagram showing the comparison between actual torque and target torque during a motor controller test process, provided as an embodiment of the present invention; Figure 3 This is a flowchart illustrating a motor controller testing method provided in an embodiment of the present invention; Figure 4 Provided for embodiments of the present invention Figure 3 A flowchart of step S400; Figure 5 Provided for embodiments of the present invention Figure 4 A flowchart of step S401. Detailed Implementation

[0018] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0019] This invention provides a motor controller testing system that solves the technical problems of high testing costs, safety risks of high-voltage rotating machinery, and high noise caused by existing motor controller testing systems that rely on real motors for testing.

[0020] like Figure 1 As shown in the figure, this embodiment of the invention provides a motor controller testing system, which includes a battery simulator, a motor simulator, and a host computer. The motor simulator is configured with a motor mathematical model.

[0021] The high-voltage output terminal of the battery simulator is electrically connected to the high-voltage input terminal of the motor controller under test. Specifically, the battery simulator is used to replace a real power battery pack to provide DC bus voltage to the motor controller. In actual connection, the positive and negative output terminals of the battery simulator are connected to the DC input terminal of the motor controller via a high-voltage wiring harness.

[0022] The control output terminal (U / V / W) of the motor controller is electrically connected to the control input terminal of the motor simulator. The motor simulator here functions as a real-time simulation device, whose input terminal receives the three-phase AC signal output by the motor controller to calculate the motor state.

[0023] The sensor signal output terminal of the motor simulator is connected to the sensor signal input terminal of the motor controller. Specifically, the motor simulator simulates the resolver sensor or Hall sensor of the motor, feeding back signals such as rotor position and speed to the motor controller, thereby forming a closed-loop control.

[0024] The host computer is communicatively connected to the motor controller, the battery simulator, and the motor simulator, respectively. Figure 1 In the diagram, dashed lines represent communication connections, and solid lines represent electrical connections.

[0025] The host computer, as the central control unit, is configured as follows: First, a physical parameter configuration command is sent to the motor simulator to set the physical parameters of the motor mathematical model of the motor simulator, ensuring that the electromagnetic characteristics of the motor simulator are consistent with the electromagnetic characteristics of the target motor.

[0026] Secondly, an output command is sent to the battery simulator to cause the battery simulator to output a preset DC bus voltage to the motor controller; Finally, control commands are sent to the motor controller to drive the motor simulator to run, and the operating status data fed back by the motor controller is received to complete the performance test of the motor controller. The operating status data may include current, voltage, speed, torque, etc.

[0027] The motor controller testing system in this embodiment of the invention connects a battery simulator, a motor simulator, and the motor controller under test via a host computer. The high-voltage output terminal of the battery simulator, the three-phase output terminal of the motor controller, the input terminal of the motor simulator, and the sensor signal terminal are sequentially electrically connected to form a closed-loop test circuit. The host computer configures the physical parameters of the motor mathematical model in the motor simulator, controls the output voltage of the battery simulator, and collects the operating status data fed back by the motor controller to complete the performance test. This embodiment of the invention replaces the actual physical motor in traditional testing with a motor simulator. While maintaining testing accuracy, it achieves safe, low-cost, and flexibly configurable closed-loop testing of electromagnetic characteristics without the need for a physical motor. This effectively lowers the testing threshold and improves testing efficiency, effectively solving the technical problems of high testing costs, safety risks associated with high-voltage rotating machinery, and high noise levels caused by relying on actual motors in existing technologies.

[0028] As an optional implementation, in one embodiment of the invention, sending control commands to the motor controller to drive the motor simulator to run, and receiving operating status data fed back by the motor controller to complete the performance test of the motor controller includes: Based on a preset vehicle driving condition curve, the driving condition curve is converted into a control command for the target torque and sent to the motor controller to simulate the operating state of the motor controller during actual vehicle driving; wherein, the preset vehicle driving condition curve includes at least one of NEDC, WLTC or CLTC driving condition curves.

[0029] For example, the host computer loads the WLTC operating condition file, parses the target vehicle speed at each time point, converts it into target torque, and then sends it to the motor controller. This makes the test scenario highly similar to the actual user situation and can verify the adaptability of the motor controller under complex operating conditions.

[0030] As an optional implementation, in one embodiment of the invention, the step of sending control commands to the motor controller to drive the motor simulator to run and receiving operating status data fed back by the motor controller to complete the performance test of the motor controller further includes: The steady-state error and dynamic error are calculated based on the actual torque in the operating status data fed back by the motor controller and the target torque of the motor controller. The torque control accuracy of the motor controller is evaluated based on steady-state error and dynamic error.

[0031] Specifically, the host computer acquires the actual torque calculated by the motor simulator in real time and compares it with the target torque issued by the host computer. The torque control accuracy of the motor controller is evaluated based on steady-state error and dynamic error. For example, if the steady-state error exceeds ±5%, the torque control accuracy is deemed unqualified. This quantitative evaluation method provides clear data support for the performance optimization of the motor controller. Figure 2 This is a schematic diagram comparing the actual torque with the target torque during a test process.

[0032] Further, the step of calculating the steady-state error and dynamic error based on the actual torque in the operating status data fed back by the motor controller and the target torque of the motor controller includes: First, multiple sampling points are selected within the steady-state operating range of the motor simulator. The absolute value of the deviation between the actual torque and the target torque at each sampling point is calculated, and the maximum value is taken as the maximum steady-state error. The steady-state operating range typically refers to the time period during which the torque command remains constant or has a very small rate of change.

[0033] Secondly, multiple sampling points are selected within the dynamic operating range of the motor simulator, and the absolute value of the deviation between the actual torque and the target torque at each sampling point is calculated. The maximum value is taken as the maximum dynamic error. The dynamic operating range typically refers to the time period during which the torque command changes rapidly.

[0034] This invention provides an intuitive way to determine the performance boundaries of a motor controller in different operating ranges through minimum / maximum value error analysis.

[0035] As an optional implementation, in one embodiment of the invention, the battery simulator includes an overvoltage protection unit and an overcurrent protection unit. When the output voltage of the battery simulator exceeds a preset voltage threshold or the output current exceeds a preset current threshold, the battery simulator automatically cuts off the high-voltage output and sends a fault alarm signal to the host computer. This ensures the safety of the testing system itself when abnormal demands are caused by a logic error in the motor controller, preventing damage to high-voltage equipment or injury to personnel.

[0036] As an optional implementation, in one embodiment of the invention, the host computer, the motor controller, the battery simulator, and the motor simulator are connected via an Ethernet switch. Specifically, each device is equipped with an Ethernet interface and connected to the same switch via a network cable. Ethernet communication features high bandwidth and low latency, which can meet the real-time transmission requirements of large amounts of test data (such as high-frequency current waveforms and operating condition data), ensuring the real-time monitoring of the host computer.

[0037] As an optional implementation, in one embodiment of the invention, the host computer is further used to store multiple sets of physical parameter configuration files, each set of physical parameter configuration files corresponding to a motor type of the motor simulator. For example, the host computer database stores files such as vehicle model A - permanent magnet synchronous motor configuration, vehicle model B - induction motor configuration, etc. When testing different motor controllers, only the corresponding configuration file needs to be loaded, and the system can automatically update the physical parameters of the motor mathematical model inside the motor simulator, improving the versatility and reusability of the testing system.

[0038] As an optional implementation, in one embodiment of the invention, the motor simulator is based on A mathematical model is established using a rotating coordinate system. This model uses rotational speed and rotor position as state variables. When the rotational speed and rotor position are respectively set to preset speed and position values, the coefficient matrix of the mathematical model is transformed from a time-varying matrix into a constant matrix. In a three-phase stationary coordinate system (ABC), the motor's inductance matrix is ​​a time-varying matrix that changes with the rotor position, making calculation complex. This embodiment of the invention uses the Park transformation to convert the three-phase variables to a synchronous rotating coordinate system. When the rotational speed and the rotor position are respectively set to preset speed values ​​and preset position values, the coefficient matrix of the mathematical model is transformed from a time-varying matrix into a constant matrix. This process greatly simplifies the computational load of real-time simulation while preserving the salient pole or non-salient pole characteristics of the motor, ensuring the operating efficiency of the model in the real-time simulation system.

[0039] As an optional implementation, in one embodiment of the invention, the physical parameters include at least direct-axis inductance, quadrature-axis inductance, permanent magnet flux linkage, stator resistance, and number of pole pairs. The motor mathematical model of the motor simulator is configured to calculate the voltage equation, torque equation, and flux linkage equation of the motor based on the physical parameters to simulate the working characteristics of the motor.

[0040] Specific equation forms may include: ; ; In the formula, For the direct-axis inductance of the motor; The quadrature axis inductance of the motor; This refers to the stator resistance of the motor. For permanent magnet flux linkage in motors; This refers to the rotor speed of the motor. This represents the number of pole pairs of the motor.

[0041] It is the resistance of the three-phase stator winding; , , These are the three-phase stator phase voltages; , , These are the three-phase stator currents; , , These are the self-inductances of the three-phase stator windings; , , These are the magnetic flux linkages of the three-phase stator windings; , , , , , These are the mutual inductances between the windings of different phases; , , These are the linkages generated by the rotor flux in other windings.

[0042] When the rotor in the motor rotates, This represents the rotor's current actual position, and its value is related to time and inductance. The electromotive force generated by the permanent magnet synchronous motor has sinusoidal characteristics. When establishing the mathematical model, it is chosen to model in a rotating coordinate system. When the two variables of velocity and position are reasonably selected, the mathematical model can be greatly simplified.

[0043] like Figure 3 As shown in the figure, this embodiment of the invention also provides a method for testing a motor controller, the method comprising the following steps: Step S100: Electrically connect the high voltage output terminal of the battery simulator to the high voltage input terminal of the motor controller, electrically connect the control output terminal of the motor controller to the control input terminal of the motor simulator, connect the sensor signal output terminal of the motor simulator to the sensor signal input terminal of the motor controller, and connect the host computer to the motor controller, the battery simulator, and the motor simulator for communication respectively.

[0044] Step S200: The host computer sends a physical parameter configuration command to the motor simulator to set the physical parameters of the motor mathematical model of the motor simulator.

[0045] In step S300, the host computer sends an output command to the battery simulator, causing the battery simulator to output a preset DC bus voltage to the motor controller.

[0046] In step S400, the host computer sends control commands to the motor controller to drive the motor simulator to run, and receives the running status data fed back by the motor controller to complete the performance test of the motor controller.

[0047] The motor controller testing method in this embodiment of the invention completes the performance test by configuring the physical parameters of the motor mathematical model of the motor simulator, controlling the output voltage of the battery simulator, and collecting the operating status data fed back by the motor controller through the host computer, thereby achieving efficient and safe motor controller testing.

[0048] As an optional implementation, in one embodiment of the invention, sending control commands to the motor controller to drive the motor simulator to run, and receiving operating status data fed back by the motor controller to complete the performance test of the motor controller includes: Based on a preset vehicle driving condition curve, the driving condition curve is converted into a control command for the target torque and sent to the motor controller to simulate the operating state of the motor controller during actual vehicle driving; wherein, the preset vehicle driving condition curve includes at least one of NEDC, WLTC or CLTC driving condition curves.

[0049] For example, the host computer loads the WLTC operating condition file, parses the target vehicle speed at each time point, converts it into target torque, and then sends it to the motor controller. This makes the test scenario highly similar to the actual user situation and can verify the adaptability of the motor controller under complex operating conditions.

[0050] As an optional implementation, in one embodiment of the invention, such as Figure 3 As shown, the step of sending control commands to the motor controller to drive the motor simulator to run and receiving operating status data fed back by the motor controller to complete the performance test of the motor controller also includes: Step S401: Calculate the steady-state error and dynamic error based on the actual torque in the operating status data fed back by the motor controller and the target torque of the motor controller; Step S402: Evaluate the torque control accuracy of the motor controller based on steady-state error and dynamic error.

[0051] Specifically, the host computer acquires the actual torque calculated by the motor simulator in real time and compares it with the target torque issued by the host computer. The torque control accuracy of the motor controller is evaluated based on steady-state error and dynamic error. For example, if the steady-state error exceeds ±5%, the torque control accuracy is deemed unqualified. This quantitative evaluation method provides clear data support for the performance optimization of the motor controller.

[0052] Furthermore, such as Figure 5 As shown, the step of calculating steady-state error and dynamic error based on the actual torque in the operating status data fed back by the motor controller and the target torque of the motor controller includes: Step S4011: Select multiple sampling points of the motor simulator within the steady-state operating range, calculate the absolute value of the deviation between the actual torque and the target torque at each sampling point, and take the maximum value as the maximum steady-state error. The steady-state operating range typically refers to the time period during which the torque command remains constant or has a very small rate of change.

[0053] Step S4012: Select multiple sampling points of the motor simulator within the dynamic operating range, calculate the absolute value of the deviation between the actual torque and the target torque at each sampling point, and take the maximum value as the maximum dynamic error. The dynamic operating range typically refers to the time period during which the torque command changes rapidly.

[0054] This invention provides an intuitive way to determine the performance boundaries of a motor controller in different operating ranges through minimum / maximum value error analysis.

[0055] In the description of this invention, it should be noted that the terms "upper," "lower," etc., indicating the orientation or positional relationship are based on the orientation or positional relationship shown in the accompanying drawings, and are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. Unless otherwise expressly specified and limited, the terms "installed," "connected," and "linked" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication between two elements. For those skilled in the art, the specific meaning of the above terms in this invention can be understood according to the specific circumstances.

[0056] It should be noted that in this invention, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0057] The above description is merely a specific embodiment of the present invention, enabling those skilled in the art to understand or implement the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the present invention is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features of the invention herein.

Claims

1. A motor controller testing system, characterized in that, include: A battery simulator, a motor simulator, and a host computer, wherein the motor simulator is configured with a motor mathematical model; The high-voltage output terminal of the battery simulator is electrically connected to the high-voltage input terminal of the motor controller under test. The control output terminal of the motor controller is electrically connected to the control input terminal of the motor simulator; The sensor signal output terminal of the motor simulator is connected to the sensor signal input terminal of the motor controller; The host computer is communicatively connected to the motor controller, the battery simulator, and the motor simulator, and is configured as follows: Send a physical parameter configuration command to the motor simulator to set the physical parameters of the motor mathematical model of the motor simulator; Send an output command to the battery simulator to cause the battery simulator to output a preset DC bus voltage to the motor controller; Control commands are sent to the motor controller to drive the motor simulator to run, and the operating status data fed back by the motor controller are received to complete the performance test of the motor controller.

2. The motor controller testing system according to claim 1, characterized in that, The process of sending control commands to the motor controller to drive the motor simulator and receiving operating status data from the motor controller to complete the performance test of the motor controller includes: Based on a preset vehicle driving condition curve, the driving condition curve is converted into a control command for the target torque and sent to the motor controller to simulate the operating state of the motor controller during actual vehicle driving; wherein, the preset vehicle driving condition curve includes at least one of NEDC, WLTC or CLTC driving condition curves.

3. The motor controller testing system according to claim 1, characterized in that, The step of sending control commands to the motor controller to drive the motor simulator to run, and receiving operating status data fed back by the motor controller to complete the performance test of the motor controller, further includes: The steady-state error and dynamic error are calculated based on the actual torque in the operating status data fed back by the motor controller and the target torque of the motor controller. The torque control accuracy of the motor controller is evaluated based on steady-state error and dynamic error.

4. The motor controller testing system according to claim 3, characterized in that, The calculation of steady-state error and dynamic error based on the actual torque in the operating status data fed back by the motor controller and the target torque of the motor controller includes: Multiple sampling points of the motor simulator within the steady-state operating range are selected, and the absolute value of the deviation between the actual torque and the target torque at each sampling point is calculated. The maximum value among them is taken as the maximum steady-state error. Multiple sampling points are selected within the dynamic operating range of the motor simulator. The absolute value of the deviation between the actual torque and the target torque at each sampling point is calculated, and the maximum value is taken as the maximum dynamic error.

5. The motor controller testing system according to claim 1, characterized in that: The battery simulator includes an overvoltage protection unit and an overcurrent protection unit. When the output voltage of the battery simulator exceeds a preset voltage threshold or the output current exceeds a preset current threshold, the battery simulator automatically cuts off the high voltage output and sends a fault alarm signal to the host computer.

6. The motor controller testing system according to claim 1, characterized in that: The host computer, the motor controller, the battery simulator, and the motor simulator are connected via an Ethernet switch.

7. The motor controller testing system according to claim 1, characterized in that: The host computer is also used to store multiple sets of physical parameter configuration files, and each set of physical parameter configuration files corresponds to a motor type of the motor simulator.

8. The motor controller testing system according to claim 1, characterized in that: The mathematical model of the motor in the motor simulator is based on A mathematical model is established using a rotating coordinate system, wherein the rotational speed and rotor position are used as state variables. When the rotational speed and rotor position are respectively set to preset speed values ​​and preset position values, the coefficient matrix of the mathematical model is transformed from a time-varying matrix into a constant matrix.

9. The motor controller testing system according to claim 1, characterized in that: The physical parameters include at least direct-axis inductance, quadrature-axis inductance, permanent magnet flux linkage, stator resistance, and number of pole pairs. The motor simulator is configured to calculate the motor's voltage equation, torque equation, and flux linkage equation based on the physical parameters to simulate the motor's operating characteristics.

10. A method for testing a motor controller, applied to the motor controller testing system of claim 1, characterized in that, The method includes the following steps: Electrically connect the high-voltage output terminal of the battery simulator to the high-voltage input terminal of the motor controller, electrically connect the control output terminal of the motor controller to the control input terminal of the motor simulator, connect the sensor signal output terminal of the motor simulator to the sensor signal input terminal of the motor controller, and connect the host computer to the motor controller, the battery simulator, and the motor simulator for communication respectively. The host computer sends physical parameter configuration instructions to the motor simulator to set the physical parameters of the motor mathematical model of the motor simulator; The host computer sends an output command to the battery simulator, causing the battery simulator to output a preset DC bus voltage to the motor controller. The host computer sends control commands to the motor controller to drive the motor simulator to run, and receives the running status data fed back by the motor controller to complete the performance test of the motor controller.