A motor control method and device, electronic equipment and storage medium

CN122584994APending Publication Date: 2026-08-18SAIC GM WULING AUTOMOBILE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610894186.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-06-18
Publication Date
2026-08-18

AI Technical Summary

Benefits of technology

[0011]本申请实施例中,进一步引入路面附着系数作为修正因子,对初步确定的电流环带宽进行优化。路面附着系数反映了轮胎与路面的摩擦特性,其值越高表示附着力越强。当路面附着系数较高时,可以增大第一电流环带宽,以提高响应速度;而当路面附着系数较低时,可以选择较小的电流环带宽,以增强控制稳定性。这种基于路面条件的动态修正机制,使车辆能够适应不同的路面状况,进一步提升了防溜坡控制的安全性和可靠性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122584994A_ABST
    Figure CN122584994A_ABST
Patent Text Reader

Abstract

This application provides a motor control method, device, electronic device, and storage medium, relating to the field of vehicle technology. By distinguishing between anti-rollback and non-anti-rollback states and configuring differentiated current loop bandwidths, it balances response speed and stability during anti-rollback conditions, reducing rollback distance and avoiding vibration; and optimizes power response during non-anti-rollback conditions, thereby significantly improving the adaptability and accuracy of motor control and ensuring a safe and comfortable driving experience. The motor control method includes: when the vehicle is in anti-rollback condition, controlling the motor through a speed loop and a first current loop with zero speed as the target, wherein the first current loop is configured to use a first current loop bandwidth; when the vehicle is in non-anti-rollback condition, controlling the motor through a second current loop with the driver's required torque as the target, wherein the second current loop is configured to use a second current loop bandwidth, and the first current loop bandwidth and the second current loop bandwidth are different.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of vehicle technology, and in particular to a motor control method, device, electronic device, and storage medium. Background Technology

[0002] Anti-rollback functionality is a key technology for ensuring vehicle safety and stability when starting on an incline. In existing technologies, when a vehicle is parked on an incline, the electric drive system typically outputs torque briefly to counteract gravity and prevent the vehicle from rolling backward after the driver releases the brake pedal. In anti-rollback mode, the control strategy employs a dual closed-loop control with a speed loop as the outer loop and a current loop as the inner loop; while in non-anti-rollback mode, current loop (torque loop) control is used directly. However, the requirements for control response vary under different driving conditions. How to ensure rapid response while maintaining vehicle stability is a pressing technical problem that needs to be solved. Summary of the Invention

[0003] This application provides a motor control method, device, electronic device, and storage medium. By distinguishing between anti-rollback and non-anti-rollback states and configuring differentiated current loop bandwidths, the response speed and stability are balanced during anti-rollback, reducing the rollback distance and avoiding vibration; and the power response is optimized during non-anti-rollback, thereby significantly improving the adaptability and accuracy of motor control and ensuring a safe and comfortable driving experience.

[0004] In a first aspect, embodiments of this application provide a motor control method, the method comprising: When the vehicle is in anti-slip slope state, the motor is controlled by speed loop and first current loop with zero speed as the target. The first current loop is configured to use the first current loop bandwidth. When the vehicle is not in a slope-avoidance state, the motor is controlled through the second current loop with the driver's required torque as the target; the second current loop is configured to use the second current loop bandwidth, which is different from the first current loop bandwidth.

[0005] In this embodiment, by distinguishing between anti-rollback and non-anti-rollback states and configuring different current loop bandwidths for the two states, optimization can be performed to address the characteristics of different control objectives. Specifically, in the anti-rollback state, control is targeted at zero speed. Using a specific first current loop bandwidth effectively balances response speed and stability: ensuring sufficient response speed to reduce vehicle rollback distance while avoiding speed fluctuations caused by excessively fast response, thereby improving ride comfort. In the non-anti-rollback state, control is targeted at the driver's required torque. Using a specific second current loop bandwidth better meets power output demands and improves the vehicle's power response characteristics. This differentiated configuration allows the vehicle to select optimal control parameters under different operating conditions, significantly improving the adaptability and accuracy of motor control and providing users with a safer and more comfortable driving experience.

[0006] Optionally, the method for determining the bandwidth of the first current loop includes: Obtain the vehicle's real-time rotation speed and the real-time slope of the vehicle's location; The bandwidth of the first current loop is determined based on the real-time rotational speed and real-time slope.

[0007] In this embodiment, by simultaneously considering real-time rotational speed and real-time slope to determine the bandwidth of the first current loop, the control requirements under anti-slip slope conditions can be more accurately matched.

[0008] Optionally, the bandwidth of the first current loop is determined based on the real-time rotational speed and real-time slope, including: Based on the correspondence between rotational speed, slope and the bandwidth of the first current loop, the bandwidth of the first current loop corresponding to the real-time rotational speed and real-time slope is determined.

[0009] In this embodiment, a pre-established table mapping the speed, gradient, and bandwidth of the first current loop is used to quickly determine the optimal current loop bandwidth value by looking up the table. This table-based determination method is simple to implement, responds quickly, and allows for offline calibration to obtain the optimal parameter combination. In practical applications, this mapping table can be customized according to different vehicle models, motor characteristics, and driving needs to ensure optimal control performance under various operating conditions.

[0010] Optionally, the method further includes: Obtain the road surface adhesion coefficient; Based on the correspondence between rotational speed, slope, and the bandwidth of the first current loop, the bandwidth of the first current loop corresponding to the real-time rotational speed and real-time slope is determined, including: Based on the correspondence between rotational speed, slope and the bandwidth of the first current loop, the bandwidth of the third current loop corresponding to the real-time rotational speed and real-time slope is determined. The bandwidth of the third current loop is corrected based on the road surface adhesion coefficient to obtain the bandwidth of the first current loop. The road surface adhesion coefficient and the bandwidth of the first current loop are positively correlated.

[0011] In this embodiment, the road surface adhesion coefficient is further introduced as a correction factor to optimize the initially determined current loop bandwidth. The road surface adhesion coefficient reflects the frictional characteristics between the tire and the road surface; a higher value indicates stronger adhesion. When the road surface adhesion coefficient is high, the bandwidth of the first current loop can be increased to improve the response speed; conversely, when the road surface adhesion coefficient is low, a smaller current loop bandwidth can be selected to enhance control stability. This dynamic correction mechanism based on road conditions enables the vehicle to adapt to different road conditions, further improving the safety and reliability of anti-slip control.

[0012] Optionally, the method further includes: Get the motor temperature; The bandwidth of the third current loop is corrected based on the road surface adhesion coefficient to obtain the bandwidth of the first current loop, including: The bandwidth of the third current loop is corrected based on the road surface adhesion coefficient to obtain the bandwidth of the fourth current loop. The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the first current loop. The motor temperature and the bandwidth of the first current loop are negatively correlated.

[0013] In this embodiment, the impact of motor temperature on control parameters is further considered. Increased motor temperature leads to increased motor resistance and decreased heat dissipation capacity; therefore, the current loop bandwidth needs to be appropriately reduced to protect the motor and maintain stable control. By incorporating motor temperature into the correction factor, control parameters can be automatically adjusted under high-temperature conditions, avoiding control instability caused by overheating, thereby extending motor life and improving system safety. This comprehensive multi-factor control strategy significantly enhances the robustness and adaptability of the motor control system.

[0014] Optionally, the method further includes: Obtain the real-time load of the vehicle and determine the real-time load rate based on the real-time load and the maximum allowable load. The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the first current loop, including: The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the fifth current loop; The bandwidth of the fifth current loop is corrected based on the real-time load rate to obtain the bandwidth of the first current loop. The real-time load rate and the bandwidth of the first current loop are negatively correlated.

[0015] In this embodiment, the impact of vehicle load on control parameters is further considered. The real-time load rate reflects the ratio of the vehicle's current load to its maximum permissible load; a high load rate implies greater inertial force and more complex dynamic characteristics. When the load rate is high, an excessively high current loop bandwidth can easily cause system oscillations, therefore the bandwidth should be reduced to ensure stability. Conversely, when the load rate is low, the current loop bandwidth can be appropriately increased to enhance response speed while avoiding start-up lag caused by excessively low bandwidth. This load-based dynamic adjustment mechanism enables the system to adapt to different load conditions, effectively balancing the anti-oscillation requirements under high loads with the response sensitivity under low loads, significantly improving the operational adaptability of the anti-rollover function.

[0016] Optionally, before controlling the motor through the speed loop and the first current loop with the target of zero speed, the method further includes: Set the anti-slide status marker; Before controlling the motor via a second current loop to target the torque demanded by the driver, the method further includes: The anti-slippage status flag is reset.

[0017] In this embodiment, by setting and resetting the anti-slippage status flag, the anti-slippage state and the non-anti-slippage state are clearly distinguished, ensuring that the system can accurately identify the current operating condition and switch the corresponding control strategy. This status flag mechanism simplifies the control logic, improves the accuracy of system judgment, avoids control anomalies caused by misjudgment, and provides reliable status indication for the entire control process.

[0018] Secondly, embodiments of this application disclose a motor control device, which includes: The first control unit is used to control the motor through the speed loop and the first current loop when the vehicle is in the anti-rollback state, with zero speed as the target. The first current loop is configured to use the first current loop bandwidth. The second control unit is used to control the motor through the second current loop when the vehicle is not in the anti-rollover state, with the target torque required by the driver as the objective; wherein the second current loop is configured to use the second current loop bandwidth, and the bandwidth of the first current loop is different from that of the second current loop.

[0019] Optionally, the device may also include: The acquisition unit is used to acquire the real-time rotational speed of the vehicle and the real-time slope of the vehicle's location. The current loop bandwidth determination unit is used to determine the first current loop bandwidth based on the real-time rotational speed and real-time slope.

[0020] Optionally, the current loop bandwidth determination unit includes: The first current loop bandwidth determination unit is used to determine the first current loop bandwidth corresponding to the real-time speed and real-time slope based on the correspondence between the speed, slope and the first current loop bandwidth.

[0021] Optionally, the acquisition unit can also be used to acquire the road surface adhesion coefficient; The first current loop bandwidth determination unit includes: The second current loop bandwidth determination unit is used to determine the third current loop bandwidth corresponding to the real-time speed and the real-time slope based on the correspondence between the rotational speed, the slope and the first current loop bandwidth. The correction unit is used to correct the bandwidth of the third current loop based on the road surface adhesion coefficient to obtain the bandwidth of the first current loop. The road surface adhesion coefficient and the bandwidth of the first current loop are positively correlated.

[0022] Optionally, the acquisition unit is also used to acquire the motor temperature; The first correction unit includes: The second correction unit is used to correct the bandwidth of the third current loop according to the road surface adhesion coefficient to obtain the bandwidth of the fourth current loop. The third correction unit is used to correct the bandwidth of the fourth current loop based on the motor temperature to obtain the bandwidth of the first current loop. The motor temperature and the bandwidth of the first current loop are negatively correlated.

[0023] Optionally, the acquisition unit is also used to acquire the real-time load of the vehicle and determine the real-time load rate based on the real-time load and the maximum allowable load. The third correction unit is specifically used for: The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the fifth current loop; The bandwidth of the fifth current loop is corrected based on the real-time load rate to obtain the bandwidth of the first current loop. The real-time load rate and the bandwidth of the first current loop are negatively correlated.

[0024] Optionally, the device may also include: The setting unit is used to set the anti-slippage status flag before controlling the motor through the speed loop and the first current loop with the target of zero speed. The reset unit is used to reset the anti-slip status flag before controlling the motor through the second current loop with the target torque required by the driver.

[0025] Thirdly, embodiments of this application provide an electronic device, the electronic device including a memory for storing computer program instructions and a processor for executing the program instructions, wherein when the computer program instructions are executed by the processor, the electronic device is triggered to perform the steps of the method as described in any embodiment of the first aspect.

[0026] Fourthly, embodiments of this application provide a computer-readable storage medium for storing computer instructions that, when the computer is run, cause the computer to perform the steps of the method as described in any embodiment of the first aspect.

[0027] It should be understood that the second to fourth aspects of the embodiments of this application are consistent with the technical solutions of the first aspect of the embodiments of this application, and the beneficial effects achieved by each aspect and the corresponding feasible implementation are similar, and will not be described again. Attached Figure Description

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

[0029] Figure 1 A schematic flowchart illustrating a motor control method provided in an embodiment of this application; Figure 2 A flowchart illustrating the first method for determining the bandwidth of a first current loop provided in an embodiment of this application; Figure 3 A flowchart illustrating a second method for determining the bandwidth of a second current loop provided in an embodiment of this application; Figure 4 A flowchart illustrating the third method for determining the bandwidth of the first current loop provided in this application embodiment; Figure 5 A flowchart illustrating the fourth method for determining the bandwidth of the first current loop provided in this application embodiment; Figure 6 A flowchart illustrating the fifth method for determining the bandwidth of the first current loop provided in this application embodiment; Figure 7 This is a schematic diagram of the structure of a motor control device provided in an embodiment of this application; Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0030] To better understand the technical solution of this application, the embodiments of this application will be described in detail below with reference to the accompanying drawings.

[0031] It should be understood that the described embodiments are merely some, not all, of the embodiments in this application. All other embodiments obtained by those skilled in the art based on the embodiments in this application without inventive effort are within the scope of protection of this application.

[0032] The terminology used in the embodiments of this application is for the purpose of describing particular embodiments only and is not intended to be limiting of this application. The singular forms “a,” “the,” and “the” used in the embodiments of this application and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise.

[0033] Hill-rollback prevention is a key technology ensuring vehicle safety and stability when starting on an incline. For vehicles without hill-keeping assist, to improve safety and ease of operation and prevent accidents caused by the vehicle rolling backward when starting on an incline, the electric drive system pre-outputs a certain amount of torque to reduce the vehicle's backward distance and stabilize it for a period of time, allowing the driver sufficient time to complete the start. This replaces the hill-keeping assist system and achieves the hill-rollback prevention function. According to the control principle of the drive motor, when implementing the hill-rollback prevention function, speed loop control is used with zero speed as the target, while at other times, current loop control is used with the driver's required torque as the target, both using the PI control principle. The speed loop is the outer loop of the current loop, and the speed loop control ultimately needs to pass through the current loop control to achieve the control target. However, in hill-rollback prevention mode, it is necessary to maintain stable control at zero speed to avoid vehicle swaying, and also to respond quickly to increase torque during start-up; while during normal driving, it is necessary to respond quickly to changes in torque. Because the requirements for current loop bandwidth differ significantly between these two operating conditions, it is difficult to meet these requirements simultaneously with the same current loop closed-loop bandwidth. This makes it difficult to strike a balance between reducing the rollover distance (rapid response) and ensuring a comfortable driving experience, which is a technical problem that urgently needs to be solved.

[0034] In view of this, embodiments of this application provide a motor control method, device, electronic device, and storage medium. By distinguishing between anti-rollback and non-anti-rollback states and configuring differentiated current loop bandwidths, the response speed and stability are balanced during anti-rollback, reducing the rollback distance and avoiding vibration; and the power response is optimized during non-anti-rollback, thereby significantly improving the adaptability and accuracy of motor control and ensuring a safe and comfortable driving experience.

[0035] The technical solution protected by this application will be described in detail below with reference to the accompanying drawings.

[0036] Please see Figure 1 This is a flowchart illustrating a motor control method provided in an embodiment of this application. The method is applied to a motor control unit (MCU), and the flowchart is described below: S101: When the vehicle is in anti-slip slope state, the motor is controlled by speed loop and first current loop with zero speed as the target. The first current loop is configured to use the first current loop bandwidth.

[0037] In this embodiment of the application, when the vehicle is in the anti-rollover state, it can be considered that the anti-rollover function is activated. The triggering condition of the anti-rollover function can be determined by comprehensively analyzing multiple source signals such as the vehicle's gear signal, brake pedal status, accelerator pedal status, road slope and motor speed.

[0038] Specifically, when the vehicle is detected to be in forward or reverse gear, the brake pedal opening is lower than the first preset threshold (e.g., 5%), the accelerator pedal opening is lower than the second preset threshold (e.g., 3%), the road slope is higher than the third preset threshold (e.g., 2%), and the motor speed direction is opposite to the driving direction indicated by the current gear and exceeds the fourth preset threshold (e.g., 1 rpm), it is determined that the vehicle is at risk of rolling away, and the anti-rollaway function is activated.

[0039] The aforementioned judgment mechanism can accurately identify the potential risk of vehicle slippage under slope parking conditions, providing a reliable basis for the timely intervention of the anti-slippage function and effectively avoiding safety hazards caused by misjudgment or omission.

[0040] The following section provides a detailed explanation of how to execute the corresponding anti-slippage control strategy after activating the anti-slippage function.

[0041] S201: Obtain the target speed command.

[0042] The MCU can set the target speed to zero after detecting that the anti-slip function is activated.

[0043] In some embodiments, after activating the anti-slippage function, the anti-slippage status flag can be set. For example, if the anti-slippage status flag is set to 1, then the MCU can set the target speed to zero after detecting that the anti-slippage status flag is set.

[0044] S202: Collect the actual speed of the motor.

[0045] In this embodiment, the actual current speed of the motor can be detected in real time using a speed sensor.

[0046] S203: Calculate speed error In this embodiment of the application, the speed error is obtained by subtracting the target speed from the actual speed.

[0047] S204: Speed ​​Loop PI Controller Calculation In this embodiment, the speed error is input to the speed loop PI controller, and the target current value is output.

[0048] S205: Collects the actual current of the motor.

[0049] In this embodiment, the actual three-phase current of the motor is detected by a current sensor, and the actual current value is obtained through coordinate transformation.

[0050] S206: Calculate current error.

[0051] In this embodiment, the target current value is subtracted from the actual current value to obtain the current error.

[0052] S207: Determine the current loop bandwidth and calculate the PI gain in the anti-slip mode. In this embodiment, the MCU selects a matching first current loop bandwidth based on the vehicle's current anti-rollover state. Then, based on this first current loop bandwidth and motor parameters (such as resistance and inductance), the proportional gain and integral gain of the current loop PI controller are calculated.

[0053] S208: Current loop PI controller operation.

[0054] Substituting the above proportional gain and integral gain into the current loop PI controller, the proportional-integral operation is performed on the current error, and the voltage command is output.

[0055] S209: Generate PWM signal.

[0056] In this embodiment, a PWM signal is generated based on the voltage command and the rotor position.

[0057] S209: Inverter drives the motor.

[0058] In this embodiment, the inverter drives the motor so that the actual speed approaches the target speed of zero.

[0059] The following section provides a detailed explanation of how to determine the bandwidth of the first matching current loop under anti-slip conditions.

[0060] Please see Figure 2 This is a flowchart illustrating the first method for determining the bandwidth of a first current loop provided in this application embodiment. The flowchart of this method is described as follows: S301: Obtain the vehicle's real-time rotation speed and the real-time slope of the vehicle's location.

[0061] S302: Determine the bandwidth of the first current loop based on the real-time rotational speed and real-time slope.

[0062] In this embodiment of the application, under the anti-rollback slope state, the vehicle is usually in a near-stationary or extremely low-speed state. At this time, the current loop bandwidth can be dynamically adjusted according to the actual slope and the current speed: under steep slope conditions, even if the vehicle is stationary, there is a large tendency to roll backward. The first current loop bandwidth can be appropriately increased to speed up the response and quickly suppress the rollback; while on gentle slopes, the tendency to roll backward is weaker. The first current loop bandwidth can be reduced to ensure the smoothness of the control process and avoid vehicle body shaking caused by excessively fast response.

[0063] In the above embodiments, the dynamic adjustment mechanism based on multiple parameters enables the determined first current loop bandwidth to adapt to changes in actual working conditions in real time, significantly improving the accuracy and reliability of anti-slip control.

[0064] It should be noted that the bandwidth of the first current loop is positively correlated with the real-time slope, that is, the larger the real-time slope, the larger the bandwidth of the first current loop is required in order to respond quickly and suppress slippage; the bandwidth of the first current loop is also positively correlated with the absolute value of the real-time speed, that is, the faster the slippage speed (the larger the absolute value of the real-time speed), the larger the bandwidth of the first current loop is required in order to speed up the control response.

[0065] Please see Figure 3 This is a flowchart illustrating the second method for determining the bandwidth of the second current loop provided in this application embodiment. Specifically, S302 can be implemented by executing S3021: S3021: Determine the first current loop bandwidth corresponding to the real-time speed and real-time slope based on the correspondence between the rotational speed, slope and the bandwidth of the first current loop.

[0066] In this embodiment, a correspondence table between rotational speed, gradient, and the bandwidth of the first current loop is pre-established. Then, the optimal first current loop bandwidth value is quickly determined by looking up the table. This table-based determination method is simple to implement, responds quickly, and allows for offline calibration to obtain the optimal parameter combination. In practical applications, this mapping table can be customized according to different vehicle models, motor characteristics, and driving requirements to ensure optimal control performance under various operating conditions.

[0067] The following describes the specific process of offline calibration of the above mapping table.

[0068] (1): The bandwidth of the first current loop corresponding to different slopes and different speeds is the same fixed value (e.g., 40Hz). (2): On a 30% slope, let the vehicle roll down the slope naturally and confirm the rolling distance; (3): Adjust the bandwidth of the first current loop corresponding to the current slope. The single adjustment amount is 10Hz~50Hz until the slope distance is within the expected range. Then, finely adjust the bandwidth of the first current loop by the speed segment to achieve the optimal slope feeling. (4): Repeat steps (2) to (3) above for other slopes (5% slope, 20% slope) to complete the calibration of the above mapping table.

[0069] It should be noted that for real-time slopes and / or real-time speeds not listed in the mapping table above, the corresponding first current loop bandwidth can be determined by linear interpolation in practical applications.

[0070] In some embodiments, considering that the road conditions on which the vehicle is currently located may vary, including but not limited to: dry road surface, wet road surface, and icy road surface, the current loop bandwidth determined in this application embodiment can be dynamically corrected in combination with road conditions, so that the vehicle can adapt to different road conditions and further improve the safety and reliability of anti-slip control.

[0071] Please see Figure 4 This is a flowchart illustrating the third method for determining the bandwidth of the first current loop provided in this application embodiment. Before executing S3021, S401 can also be executed: S401: Obtain the road surface adhesion coefficient.

[0072] S3021 can be achieved by executing S402 to S403: S402: Determine the third current loop bandwidth corresponding to the real-time speed and real-time slope based on the correspondence between the rotational speed, slope and the bandwidth of the first current loop.

[0073] S403: The bandwidth of the third current loop is corrected based on the road surface adhesion coefficient to obtain the bandwidth of the first current loop. The road surface adhesion coefficient and the bandwidth of the first current loop are positively correlated.

[0074] In this embodiment, the road surface adhesion coefficient reflects the frictional characteristics between the tire and the road surface; a higher value indicates stronger adhesion. When the road surface adhesion coefficient is high, the bandwidth of the first current loop can be appropriately increased to improve the response speed; conversely, when the road surface adhesion coefficient is low, the bandwidth of the first current loop can be appropriately decreased to avoid the risk of runaway due to excessively fast response (i.e., to enhance control stability). Therefore, by introducing the road surface adhesion coefficient to modify the basic current loop bandwidth (third current loop bandwidth), the adaptability of anti-runaway control under different road conditions can be further improved.

[0075] It should be noted that when correcting the bandwidth of the third current loop based on the road surface adhesion coefficient, different road surface adhesion coefficients correspond to different first correction factors, as detailed in Table 1. Based on the determination of the first correction factor corresponding to the current road surface adhesion coefficient, the product between the first correction factor and the bandwidth of the third current loop can be calculated to determine the bandwidth of the first current loop.

[0076] Table 1 In some embodiments, considering that an increase in motor temperature can lead to an increase in winding resistance and a change in inductance characteristics, which may cause control oscillations, and that the motor response speed slows down in low-temperature environments, the present invention can introduce motor temperature to dynamically correct the current loop bandwidth, thereby achieving adaptive control under different temperature conditions, effectively suppressing control instability under high-temperature conditions, while maintaining rapid response capability in low-temperature environments, and significantly improving the reliability and stability of the anti-slip function under various ambient temperatures.

[0077] Please see Figure 5 This is a flowchart illustrating the fourth method for determining the bandwidth of the first current loop provided in this application embodiment. Before executing S403, S501 can also be executed: S501: Obtain motor temperature.

[0078] S403 can be implemented by executing S502 to S503: S502: The bandwidth of the third current loop is corrected based on the road surface adhesion coefficient to obtain the bandwidth of the fourth current loop.

[0079] S503: The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the first current loop. The motor temperature and the bandwidth of the first current loop are negatively correlated.

[0080] In this embodiment, when the motor temperature is high, the bandwidth of the first current loop can be appropriately reduced to enhance stability and avoid control oscillations caused by high motor temperature; conversely, when the motor temperature is both high and low, the bandwidth of the first current loop can be appropriately increased to accelerate the response speed. Therefore, by incorporating motor temperature to modify the bandwidth of the intermediate current loop (fourth current loop bandwidth), the robustness and adaptability of the anti-slip control under different motor temperatures can be further improved.

[0081] It should be noted that when correcting the bandwidth of the fourth current loop based on the motor temperature, different motor temperatures correspond to different second correction factors, as detailed in Table 2. Based on the determination of the second correction factor corresponding to the motor temperature, the product between the second correction factor and the bandwidth of the fourth current loop can be calculated to determine the bandwidth of the first current loop.

[0082] Table 2 In some embodiments, considering that changes in vehicle load significantly affect the vehicle's inertial characteristics and motor output requirements, the system inertia increases under high load conditions, necessitating a reduction in current loop bandwidth to improve stability and avoid oscillations. Under low load conditions, the system inertia decreases, allowing for an appropriate increase in current loop bandwidth to enhance responsiveness, but excessive bandwidth must be avoided to prevent jitter. Therefore, in this embodiment, a load factor can be introduced to dynamically correct the current loop bandwidth, achieving precise control under different load conditions, effectively suppressing control oscillations under high load, while avoiding driving discomfort caused by over-response under low load, significantly improving the adaptability and reliability of the anti-rollover function under various operating conditions.

[0083] Please see Figure 6 This is a flowchart illustrating the fifth method for determining the bandwidth of the first current loop provided in this application embodiment. Before executing S503, S601 can also be executed: S601: Obtain the real-time load of the vehicle and determine the real-time load rate based on the real-time load and the maximum allowable load.

[0084] S503 can be implemented by executing S602 to S603: S602: Correct the bandwidth of the fourth current loop based on the motor temperature to obtain the bandwidth of the fifth current loop; S603: The bandwidth of the fifth current loop is corrected based on the real-time load rate to obtain the bandwidth of the first current loop. The real-time load rate and the bandwidth of the first current loop are negatively correlated.

[0085] In this embodiment, the real-time load rate reflects the ratio of the vehicle's current load to its maximum permissible load. A high load rate implies greater inertial force and more complex dynamic characteristics. When the load rate is high, an excessively high current loop bandwidth can easily cause system oscillations; therefore, the bandwidth should be reduced to ensure stability. Conversely, when the load rate is low, the current loop bandwidth can be appropriately increased to enhance response speed while avoiding start-up lag caused by excessively low bandwidth. This load-based dynamic adjustment mechanism enables the system to adapt to different load conditions, effectively balancing the anti-oscillation requirements under high loads with the response sensitivity under low loads, significantly improving the operational adaptability of the anti-rollover function.

[0086] It should be noted that when correcting the bandwidth of the fifth current loop based on the real-time load rate, different real-time load rates correspond to different third correction factors, as detailed in Table 3. Based on the determination of the third correction factor corresponding to the current real-time load rate, the product between the third correction factor and the bandwidth of the fifth current loop can be calculated to determine the bandwidth of the first current loop.

[0087] Table 3 S102: When the vehicle is not in a slope-avoidance state, the motor is controlled through the second current loop with the driver's required torque as the target; wherein, the second current loop is configured to use the second current loop bandwidth, and the first current loop bandwidth is different from the second current loop bandwidth.

[0088] In this embodiment, when the vehicle is in a non-anti-rollover state, the anti-rollover function can be considered to be turned off. At this time, the anti-rollover status flag can be reset. For example, the anti-rollover status flag can be set to 0 so as to accurately identify the current operating condition and switch to a motor control strategy dominated by the driver's required torque.

[0089] It should be noted that there is no fixed relative size relationship between the bandwidth of the first current loop and the bandwidth of the second current loop. The relative size between the two is determined by the actual situation, and this application does not impose any special restrictions on this.

[0090] The following section provides a detailed explanation of the motor control strategy based on the driver's required torque after the anti-slip function is turned off.

[0091] S701: Obtain the driver's required torque command.

[0092] The MCU receives the torque demand from the driver from the vehicle controller.

[0093] S702: Converts torque command into target current value The MCU converts the driver's required torque into a target current value based on the torque-current mapping relationship.

[0094] S703: Collects the actual current of the motor.

[0095] The actual three-phase current is detected by a current sensor and converted into an actual current value.

[0096] S704: Calculate current error.

[0097] The current error is obtained by subtracting the target current value from the actual current value.

[0098] S705: Determine the current loop bandwidth under non-sloping conditions and calculate the PI gain. Based on the current normal driving state, the MCU determines the bandwidth of the second current loop (this second current loop bandwidth is relatively high to ensure fast torque response and responsive driving). Then, based on this second current loop bandwidth and motor parameters (such as resistance and inductance), the proportional gain and integral gain of the current loop PI controller are calculated.

[0099] S706: Current Loop PI Controller Operation Substituting the above proportional gain and integral gain into the current loop PI controller, the proportional-integral operation is performed on the current error, and the voltage command is output.

[0100] S707: Generates PWM signal PWM signals are generated based on voltage commands and rotor position. S708: Inverter drive motor output torque The inverter drives the motor, making the actual output torque follow the torque required by the driver.

[0101] It should be noted that a relationship between rotational speed and the bandwidth of the second current loop is established in advance. Therefore, in S705, the corresponding bandwidth of the second current loop can be determined based on the current real-time rotational speed.

[0102] In some embodiments, when the vehicle switches between anti-rollover state and non-rollover state, the transition between the first current loop bandwidth and the second current loop bandwidth can be carried out in a linear manner, which reduces the control system oscillation caused by sudden bandwidth changes to a certain extent, ensures smooth changes in speed and torque, effectively suppresses vehicle body vibration, and significantly improves driving comfort and control stability when switching between anti-rollover states.

[0103] Please see Figure 7 This is a schematic diagram of a motor control device provided in an embodiment of this application. The device includes: The first control unit 801 is used to control the motor through a speed loop and a first current loop when the vehicle is in a slope-avoidance state, with zero speed as the target. The first current loop is configured to use the first current loop bandwidth. The second control unit 802 is used to control the motor through a second current loop when the vehicle is not in a slope-avoidance state, with the target torque required by the driver as the objective; wherein the second current loop is configured to use a second current loop bandwidth, and the bandwidth of the first current loop is different from that of the second current loop.

[0104] Optionally, the device may also include: The acquisition unit 803 is used to acquire the real-time rotational speed of the vehicle and the real-time slope of the vehicle's location. The current loop bandwidth determination unit 804 is used to determine the first current loop bandwidth based on the real-time rotational speed and real-time slope.

[0105] Optionally, the current loop bandwidth determination unit 804 includes: The first current loop bandwidth determination unit is used to determine the first current loop bandwidth corresponding to the real-time speed and real-time slope based on the correspondence between the speed, slope and the first current loop bandwidth.

[0106] Optionally, the acquisition unit 803 is also used to acquire the road surface adhesion coefficient; The first current loop bandwidth determination unit includes: The second current loop bandwidth determination unit is used to determine the third current loop bandwidth corresponding to the real-time speed and the real-time slope based on the correspondence between the rotational speed, the slope and the first current loop bandwidth. The correction unit is used to correct the bandwidth of the third current loop based on the road surface adhesion coefficient to obtain the bandwidth of the first current loop. The road surface adhesion coefficient and the bandwidth of the first current loop are positively correlated.

[0107] Optionally, the acquisition unit 803 is also used to acquire the motor temperature; The first correction unit includes: The second correction unit is used to correct the bandwidth of the third current loop according to the road surface adhesion coefficient to obtain the bandwidth of the fourth current loop. The third correction unit is used to correct the bandwidth of the fourth current loop based on the motor temperature to obtain the bandwidth of the first current loop. The motor temperature and the bandwidth of the first current loop are negatively correlated.

[0108] Optionally, the acquisition unit 803 is also used to acquire the real-time load of the vehicle and determine the real-time load rate based on the real-time load and the maximum allowable load. The third correction unit is specifically used for: The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the fifth current loop; The bandwidth of the fifth current loop is corrected based on the real-time load rate to obtain the bandwidth of the first current loop. The real-time load rate and the bandwidth of the first current loop are negatively correlated.

[0109] Optionally, the device may also include: The setting unit 805 is used to set the anti-slippage status flag before controlling the motor through the speed loop and the first current loop with zero speed as the target. The reset unit 806 is used to reset the anti-slip status flag before controlling the motor through the second current loop with the target torque required by the driver.

[0110] Regarding the modules / units included in the various devices described in the above embodiments, they can be software modules / units, hardware modules / units, or a combination of both. For example, for devices applied to or integrated into a chip, all modules / units can be implemented using hardware methods such as circuits, or at least some modules / units can be implemented using software programs running on a processor integrated within the chip, while the remaining modules / units can be implemented using hardware methods such as circuits. For devices applied to or integrated into a chip module, all modules / units can be implemented using hardware methods such as circuits. Different modules / units can be located in the same component (e.g., chip, circuit module, etc.) or different components of the chip module, or at least some modules / units can be implemented using software programs. The software program runs on the processor integrated inside the chip module, and the remaining modules / units can be implemented using hardware methods such as circuits. For each device applied to or integrated into an electronic terminal device, each of its modules / units can be implemented using hardware methods such as circuits. Different modules / units can be located in the same component (e.g., chip, circuit module, etc.) or different components within the electronic terminal device. Alternatively, at least some modules / units can be implemented using software programs that run on the processor integrated inside the electronic terminal device, and the remaining (if any) modules / units can be implemented using hardware methods such as circuits.

[0111] Please see Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. The electronic device can be a mobile device, such as a vehicle, or other devices; this application does not impose any particular limitation on this. The electronic device includes at least one processor 901, which is used to execute computer program instructions stored in a memory to implement the implementation provided in the embodiment of this application. Figures 1-6 The flowchart shown illustrates the steps of the motor control method.

[0112] Optionally, the processor 901 may be a central processing unit, a specific ASIC, or one or more integrated circuits used to control program execution.

[0113] Optionally, the electronic device may further include a memory 902 connected to at least one processor 901. The memory 902 may include ROM, RAM, and disk storage. The memory 902 stores data required for the processor 901 to operate, i.e., it stores instructions executable by at least one processor 901. The at least one processor 901 executes instructions stored in the memory 902 to perform tasks such as... Figures 1-6The method is shown. The number of memories 902 is one or more.

[0114] This application embodiment also provides a computer storage medium, wherein the computer storage medium stores computer instructions, which, when executed on a computer, cause the computer to perform actions such as... Figures 1-6 The method described.

[0115] The aforementioned computer-readable storage medium may be any combination of one or more computer-readable media. A computer-readable medium may be a computer-readable signal medium or a computer-readable storage medium. A computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media (a non-exhaustive list) include: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), or flash memory, optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this document, a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in connection with an instruction execution system, apparatus, or device.

[0116] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which can send, propagate, or transmit programs for use by or in connection with an instruction execution system, apparatus, or device.

[0117] Program code contained on a computer-readable medium may be transmitted using any suitable medium, including but not limited to: wireless, wire, optical fiber, radio frequency (RF), etc., or any suitable combination thereof.

[0118] Computer program code for performing the operations of this application can be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, and C++, as well as conventional procedural programming languages ​​such as "C" or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0119] The foregoing has described specific embodiments of this application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired results. Furthermore, the processes depicted in the drawings do not necessarily require the specific or sequential order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0120] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0121] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in a combination of hardware and software functional units.

[0122] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.

Claims

1. A motor control method, characterized in that, The method includes: When the vehicle is in anti-slip slope state, the motor is controlled by speed loop and first current loop with zero speed as the target. The first current loop is configured to use the first current loop bandwidth. When the vehicle is not in a slope-avoidance state, the motor is controlled through a second current loop with the driver's required torque as the target; wherein, the second current loop is configured to use a second current loop bandwidth, and the bandwidth of the first current loop is different from that of the second current loop.

2. The method according to claim 1, characterized in that, The method for determining the bandwidth of the first current loop includes: The real-time rotational speed of the vehicle and the real-time slope of the vehicle's location are obtained. The bandwidth of the first current loop is determined based on the real-time rotational speed and the real-time slope.

3. The method according to claim 2, characterized in that, The bandwidth of the first current loop is determined based on the real-time rotational speed and the real-time slope, including: Based on the correspondence between rotational speed, slope, and first current loop bandwidth, the first current loop bandwidth corresponding to the real-time rotational speed and the real-time slope is determined.

4. The method according to claim 3, characterized in that, The method further includes: Obtain the road surface adhesion coefficient; Based on the correspondence between rotational speed, slope, and first current loop bandwidth, the first current loop bandwidth corresponding to the real-time rotational speed and the real-time slope is determined, including: Based on the correspondence between rotational speed, slope and first current loop bandwidth, the third current loop bandwidth corresponding to the real-time rotational speed and the real-time slope is determined; The bandwidth of the third current loop is corrected based on the road surface adhesion coefficient to obtain the bandwidth of the first current loop. The road surface adhesion coefficient and the bandwidth of the first current loop are positively correlated.

5. The method according to claim 4, characterized in that, The method further includes: Get the motor temperature; The bandwidth of the third current loop is corrected based on the road surface adhesion coefficient to obtain the bandwidth of the first current loop, including: The bandwidth of the third current loop is corrected based on the road surface adhesion coefficient to obtain the bandwidth of the fourth current loop; The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the first current loop. The motor temperature and the bandwidth of the first current loop are negatively correlated.

6. The method according to claim 5, characterized in that, The method further includes: Obtain the real-time load of the vehicle and determine the real-time load rate based on the real-time load and the maximum allowable load. The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the first current loop, including: The bandwidth of the fourth current loop is corrected based on the motor temperature to obtain the bandwidth of the fifth current loop; The bandwidth of the fifth current loop is corrected based on the real-time load rate to obtain the bandwidth of the first current loop. The real-time load rate and the bandwidth of the first current loop are negatively correlated.

7. The method according to any one of claims 1-6, characterized in that, Before controlling the motor through the speed loop and the first current loop with the target of zero speed, the method further includes: Set the anti-slide status marker; Before controlling the motor via a second current loop to target the torque demanded by the driver, the method further includes: The anti-slippage status flag is reset.

8. A motor control device, characterized in that, The device includes: The first control unit is used to control the motor through a speed loop and a first current loop when the vehicle is in a slope-avoidance state, with zero speed as the target. The first current loop is configured to use the bandwidth of the first current loop. The second control unit is used to control the motor through a second current loop when the vehicle is not in a slope-avoidance state, with the target torque required by the driver as the objective; wherein the second current loop is configured to use a second current loop bandwidth, and the bandwidth of the first current loop is different from that of the second current loop.

9. An electronic device, characterized in that, The electronic device includes a memory and a processor, wherein the memory stores computer program instructions that, when executed by the processor, implement the method as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer program instructions that, when executed by a computer, cause the computer to perform the method as described in any one of claims 1-7.