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

By optimizing the motor control method, the actuator is first driven away from the zero position, and then its movement is controlled to zero based on the position distance. The position is predicted using historical data, which solves the noise problem in the motor's zero-seeking process and achieves a significant reduction in noise.

CN122126102APending Publication Date: 2026-06-02ZHEJIANG GEELY HLDG GRP CO LTD +1

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ZHEJIANG GEELY HLDG GRP CO LTD
Filing Date
2026-04-28
Publication Date
2026-06-02

AI Technical Summary

Technical Problem

During the movement of the motor-driven actuator, a power outage or malfunction of the motor makes it impossible to know the real-time position. During the zero-finding process, the actuator collides with the physical limit device at the zero point, generating significant noise. Existing mechanical structure optimization methods are difficult to continuously and effectively suppress the noise.

Method used

After receiving the zero-finding command, the target motor drives the actuator to move towards the endpoint position. Based on the distance between the zero point position and the endpoint position, the motor drives the actuator to move towards the zero point position until the actuator reaches the zero point position. The historical position request data is used to predict the current position to optimize the movement path.

Benefits of technology

It effectively reduces the impact time between the actuator and the zero point position, reduces noise generation, and achieves significant noise reduction without increasing hardware costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122126102A_ABST
    Figure CN122126102A_ABST
Patent Text Reader

Abstract

This application provides a motor control method, apparatus, electronic device, storage medium, and vehicle. The method includes: in response to receiving a zero-finding command, controlling a target motor drive actuator to move towards a target position; in response to the actuator moving a distance towards the target position to reach a target distance, controlling the target motor drive actuator to move towards a zero position based on the distance between the zero position and the target position, until the actuator reaches the zero position. Upon receiving the zero-finding command, this application first controls the target motor drive actuator to move towards the target position to move it away from the zero position, and then controls it to move towards the zero position based on the distance between the zero position and the target position. This effectively reduces the time it takes for the actuator to collide with the physical limit device at the zero position, thereby reducing the noise generated by the collision.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

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

[0002] If the motor experiences a power outage, malfunction, or other abnormal situation during the movement of the motor-driven actuator, the real-time position of the actuator may become unknown. To ensure the accuracy of subsequent positioning, the actuator needs to be controlled to find its zero-point position again after the motor returns to normal. However, during the process of finding the zero-point position, significant noise is often generated due to the actuator colliding with the physical limit device at the zero-point position, affecting the user experience.

[0003] Current noise reduction methods mostly focus on mechanical structure optimization, such as adding buffer components or using sound-absorbing materials. However, such methods are constrained by installation space, and the performance of buffer components and sound-absorbing materials is prone to degradation after long-term wear, making it difficult to continuously and effectively suppress the noise generated by the collision between the actuator and the physical limiting device at the zero point position during the zero-finding process. Summary of the Invention

[0004] The main objective of this application is to provide a motor control method, device, electronic device, storage medium, and vehicle, which aims to reduce noise generated during the zero-finding process due to the collision between the actuator and the physical limiting device at the zero point position.

[0005] This application provides a motor control method, including: in response to receiving a zero-finding instruction, controlling a target motor to drive an actuator to move towards a destination position; the zero-finding instruction instructs the target motor to drive the actuator to move to a zero point position; the zero point position and the destination position are the mechanical travel limit positions of the actuator; in response to the actuator moving a distance towards the destination position to reach a target distance, based on the distance between the zero point position and the destination position, controlling the target motor to drive the actuator to move towards the zero point position until the actuator moves to the zero point position.

[0006] In one embodiment, before controlling the target motor to drive the actuator to move towards the zero-point position based on the distance between the zero-point position and the end position in response to the actuator moving a distance towards the end position reaching a target distance, the method further includes: determining the current predicted position of the actuator based on first historical position request data; the first historical position request data being request data from a historical period used to instruct the target motor to drive the actuator to a first position; and determining the target distance based on the distance between the current predicted position and the zero-point position, and the distance between the zero-point position and the end position.

[0007] In one embodiment, determining the current predicted position of the execution component based on the first historical position request data includes: dividing the total travel distance of the execution component from the zero point position to the end point position into multiple travel intervals; determining the weight of each travel interval based on the first historical position request data; and determining the current predicted position of the execution component based on each travel interval and the weight of each travel interval.

[0008] In one embodiment, determining the weight of each travel interval based on the first historical location request data includes: for each travel interval, determining the number of times the execution component is located in the travel interval based on the first historical location request data; and determining the weight of the travel interval based on the number of times the execution component is located in the travel interval.

[0009] In one embodiment, before determining the current predicted position of the execution component based on the first historical position request data, the method further includes: acquiring second historical position request data; the second historical position request data is request data used by the historical period to instruct the target motor to drive the execution component to a second position; and filtering the second historical position request data based on the working state of the target motor in the historical period to obtain the first historical position request data.

[0010] In one embodiment, the historical period includes multiple historical moments; the step of filtering the second historical location request data based on the working state of the target motor in the historical period to obtain the first historical location request data includes: for each of the multiple historical moments, in response to the target motor being in an abnormal state corresponding to the historical moment, excluding the second historical location request data corresponding to the historical moment; and determining the second historical location request data corresponding to the remaining historical moments in the multiple historical moments as the first historical location request data.

[0011] This application embodiment also provides a motor control device, the device including a first control module and a second control module; The first control module is used to control the target motor to drive the actuator to move towards the endpoint position in response to receiving a zero-finding instruction; the zero-finding instruction is used to instruct the target motor to drive the actuator to move to the zero point position; the zero point position and the endpoint position are the mechanical travel limit positions of the actuator; the second control module is used to control the target motor to drive the actuator to move towards the zero point position in response to the actuator moving a distance towards the endpoint position to reach a target distance, based on the distance between the zero point position and the endpoint position, until the actuator moves to the zero point position.

[0012] This application also provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the above-described motor control method.

[0013] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described motor control method.

[0014] This application also provides a vehicle that includes the aforementioned electronic equipment.

[0015] The present application provides a motor control method, device, electronic device, storage medium, and vehicle. After receiving a zero-finding command, the method first controls the target motor to drive the actuator to move towards the endpoint position, so that the actuator moves away from the zero position. Then, based on the distance between the zero position and the endpoint position, the method controls the motor to drive the actuator to move towards the zero position until the actuator reaches the zero position. This can effectively reduce the time of collision between the actuator and the physical limit device of the zero position, thereby reducing the noise generated by the collision. Attached Figure Description

[0016] Figure 1 This is a flowchart illustrating the motor control method provided in the embodiments of this application.

[0017] Figure 2 This is a schematic diagram of the data filtering process provided in the embodiments of this application.

[0018] Figure 3 This is a schematic diagram showing the location of the execution component provided in the embodiments of this application.

[0019] Figure 4 This is a schematic diagram of the structure of the motor control device provided in the embodiments of this application.

[0020] Figure 5 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application. Detailed Implementation

[0021] The technical solutions of the embodiments of this application will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application are within the scope of protection of this application.

[0022] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the digit " / " generally indicates that the preceding and following objects are in an "or" relationship.

[0023] The motor control method provided in this application can be applied to electronic devices or the software of electronic devices. The electronic device can be a terminal or a server. In some embodiments, the terminal can be a smartphone, tablet computer, laptop computer, desktop computer, etc.; the server can be configured as an independent physical server, or as a server cluster or distributed system composed of multiple physical servers. The software can be an application that implements the motor control method, but is not limited to the above forms.

[0024] Currently, during the zero-finding process, since the real-time position of the actuator is unknown, to ensure that the actuator can fully move to the zero position, the target motor is often directly controlled to drive the actuator towards the zero position using the drive parameters required for the total travel distance of the actuator. Here, the total travel distance is the distance between the two mechanical travel limit positions of the actuator (zero position and end position). While this operation ensures that the actuator can fully move to the zero position, it causes the actuator to collide with the physical limit device at the zero position for a prolonged period, generating significant noise.

[0025] To address this issue, this application provides a motor control method. After receiving a zero-finding command, the method first controls the target motor to drive the actuator to move towards the endpoint position, so that the actuator moves away from the zero position. Then, based on the distance between the zero position and the endpoint position, the method controls the target motor to drive the actuator to move towards the zero position. This effectively reduces the time it takes for the actuator to collide with the physical limit device at the zero position, thereby reducing the noise generated by the collision.

[0026] The motor control method provided in this application will be described in detail below with reference to the accompanying drawings and specific embodiments.

[0027] Please see Figure 1 The motor control method provided in this application embodiment may include: Step S101: In response to receiving the zero-finding command, control the target motor to drive the actuator to move towards the end position; the zero-finding command is used to instruct the target motor to drive the actuator to move to the zero position; the zero position and the end position are the mechanical travel limit positions of the actuator; In actual implementation, upon receiving a zero-finding command, the target motor drive execution component can be controlled to move towards the endpoint position. During this drive process, the distance the motor moves towards the endpoint position can be calculated based on motion state parameters such as the number of rotations and rotation angle of the motor.

[0028] Step S102: In response to the target distance being reached by the movement of the actuator towards the endpoint position, based on the distance between the zero position and the endpoint position, control the target motor to drive the actuator to move towards the zero position until the actuator moves to the zero position.

[0029] Optionally, the target distance can be a fixed distance obtained through experimental calibration, or it can be determined based on historical location request data. For specific implementation details, please refer to the relevant description below, which will not be described here.

[0030] In practice, the drive parameters required to drive the distance between the zero point and the end point of the actuator can be determined first. Then, when the actuator moves a distance to the end point, the target motor can be controlled to drive the actuator to move towards the zero point with the drive parameters. This not only ensures that the actuator can move to the zero point, but also reduces the time it takes for the actuator to collide with the physical limit device at the zero point, thereby reducing the noise generated by the collision.

[0031] In this embodiment, after receiving the zero-finding command, the target motor drives the execution component to move towards the endpoint position so that the execution component is away from the zero position. Then, based on the distance between the zero position and the endpoint position, the motor drives the execution component to move towards the zero position until the execution component moves to the zero position. This can effectively reduce the time when the execution component collides with the zero position, thereby reducing the noise generated by the collision.

[0032] In one embodiment, before controlling the target motor to drive the actuator to move towards the zero position based on the distance between the zero position and the end position in step S102 in response to the actuator moving a target distance towards the end position, the motor control method provided in this application embodiment further includes: Based on the first historical position request data, the current predicted position of the execution component is determined; the first historical position request data is the request data of a historical period used to instruct the target motor to drive the execution component to the first position; The target distance is determined based on the distance between the current predicted position and the zero point position, and the distance between the zero point position and the endpoint position.

[0033] Optionally, the first historical location request data can be the original location request data for a historical time period, or it can be request data obtained after filtering the original location request data for a historical time period. For specific implementation details, please refer to the relevant description below, which will not be described here. Optionally, the first location indicated by the first historical location request data corresponding to multiple historical moments in the historical time period can be partially the same, completely the same, or completely different.

[0034] In practice, the average value of the first positions indicated by the request data of each historical time period can be used to determine the current predicted position of the execution unit; alternatively, the current predicted position of the execution unit can be determined based on the first historical position request data and multiple travel intervals of the execution unit. For details, please refer to the relevant descriptions below, which will not be elaborated here. Optionally, the historical time period can be obtained through experimental calibration, and its value range can be 30 minutes to 60 minutes.

[0035] After determining the current predicted position of the actuator, the distance 1 between the current predicted position and the zero position can be calculated; then the difference between the distance 2 between the zero position and the end position and the distance 1 can be calculated; then this difference can be determined as the target distance, or a coefficient can be added to the difference to obtain the target distance, so as to improve the adaptability of the determined target distance to the mechanical stroke of the actuator.

[0036] This application embodiment determines the current predicted position of the execution component based on the first historical position request data, which can accurately predict the current position of the execution component; further, based on the distance between the current predicted position and the zero point position, and the distance between the zero point position and the endpoint position, the target distance is determined, realizing the dynamic adaptation and calibration of the target distance. This not only improves the reliability of controlling the motor to drive the execution component to move towards the endpoint position based on the target distance, but also makes the noise reduction effect of this solution more significant.

[0037] In one embodiment, determining the current predicted position of the execution unit based on the first historical position request data includes: The total travel distance of the actuator from the zero point to the end point is divided into multiple travel intervals; Based on the first historical location request data, determine the weight of each travel interval; The current predicted position of the execution unit is determined based on each travel interval and its weight.

[0038] In actual implementation, for each trip interval, based on the first historical location request data, the time of the first location request and the time of the last location request corresponding to the trip interval can be counted, and the time difference between the two can be calculated to obtain the time span of the location request corresponding to the trip interval; then, based on the ratio of the time span corresponding to the trip interval to the total time span corresponding to all trip intervals, the weight of the trip interval can be determined.

[0039] For each travel interval, data can be requested based on the first historical position to count the number of times the execution unit is located in that travel interval. Then, the weight of that travel interval can be determined based on the number of times the execution unit is located in that travel interval. For details on the implementation, please refer to the relevant description below, which will not be described here.

[0040] In actual implementation, for each travel interval, the two endpoint values ​​of the travel interval can be multiplied by the weight of the travel interval to obtain the prediction interval corresponding to the travel interval; then the endpoint values ​​on the same side of the prediction interval corresponding to each travel interval can be summed to obtain the target prediction interval; then the midpoint of the target prediction interval can be determined as the current prediction position of the execution unit.

[0041] For each travel interval, the midpoint of the travel interval can be selected as the representative position of the travel interval. The midpoint of the travel interval is multiplied by the weight of the travel interval to obtain the interval prediction position corresponding to the travel interval. Then, the interval prediction positions corresponding to each travel interval can be summed to obtain the current prediction position of the execution unit.

[0042] This application embodiment divides the total travel distance of the execution component from the zero point position to the end position into multiple travel intervals. Based on the first historical position request data, the weight of each travel interval is determined. Based on each travel interval and its weight, the current predicted position of the execution component is determined. This improves the accuracy of predicting the current position of the execution component, thereby improving the reliability of controlling the motor to drive the execution component to move towards the end position based on the current predicted position of the execution component. It also makes the noise reduction effect of this solution more significant.

[0043] In one embodiment, determining the weight of each travel interval based on the first historical location request data includes: For each travel interval, based on the first historical position request data, determine the number of times the execution unit is located within the travel interval; The weight of the travel interval is determined based on the number of times the execution component is located within the travel interval.

[0044] In actual implementation, for each travel interval, the first position indicated by the first historical position request data can be matched with the travel interval, and the number of times the travel interval is successfully matched can be counted to obtain the number of times the execution unit is located in the travel interval.

[0045] Next, the weight of the stroke interval can be determined by the ratio of the number of times the execution component is located in the stroke interval to the sum of the number of times the execution component is located in all stroke intervals; alternatively, the weight of the stroke interval can be obtained by querying the correspondence between the number of times the execution component is located in the stroke interval and the weight.

[0046] For example, the total travel (0 to 100) of the actuator from the zero position to the end position is divided into 10 travel intervals: 0-10, 10-20, 20-30, ..., 90-100; for each travel interval, the midpoint of the travel interval can be selected as the representative position of the travel interval, resulting in 10 representative positions: 5, 15, 25, ..., 95.

[0047] Next, the current predicted position of the execution component can be calculated using formula (1): C = (5×C1+ 15×C2+ 25×C3+ ... + 95×C 10 ) / A (1) Where C represents the current predicted position of the execution unit, C1, C2, C3, ..., C 10 Each of these represents the number of times the execution unit is located in the aforementioned 10 travel intervals, determined based on the first historical location request data, and A represents the sum of the number of times the execution unit is located in the aforementioned 10 travel intervals.

[0048] This application embodiment improves the accuracy of determining the weight corresponding to each travel interval by determining the number of times the execution component is located in the travel interval based on the first historical position request data for each travel interval, and by determining the weight of the travel interval based on the number of times the execution component is located in the travel interval. This improves the accuracy of predicting the current position of the execution component.

[0049] In one embodiment, before determining the current predicted position of the execution unit based on the first historical position request data, the method further includes: Obtain the second historical position request data; the second historical position request data is the request data for a historical period used to instruct the target motor to drive the execution component to the second position; Based on the target motor's operating status during historical periods, the second historical location request data is filtered to obtain the first historical location request data.

[0050] Optionally, the second historical location request data can be the original location request data for a historical time period.

[0051] In actual implementation, upon obtaining the second historical position request data, the second historical position request data during the historical period when the target motor is in a normal state can be retained, and / or the second historical position request data during the historical period when the target motor is in an abnormal state can be excluded, and the finally retained second historical position request data can be determined as the first historical position request data. Optionally, the abnormal state includes at least one of power failure and fault.

[0052] This application embodiment first obtains the original position request data of historical time periods, and then filters the original position request data in combination with the working status of the target motor in the historical time periods to obtain the first historical position request data for predicting the current position of the execution component. This not only ensures the authenticity of the source of the first historical position request data, but also reduces the interference of invalid original position request data of historical time periods on the prediction of the current position of the execution component, thereby improving the accuracy of predicting the current position of the execution component based on the first historical position request data.

[0053] Optionally, the historical time period includes multiple historical moments. In one embodiment, the above-mentioned filtering of the second historical position request data based on the operating status of the target motor during the historical time period to obtain the first historical position request data includes: For each of the multiple historical moments, in response to the target motor being in an abnormal state corresponding to the historical moment, the second historical position request data corresponding to the historical moment is excluded. The second historical position request data corresponding to the remaining historical time among multiple historical time periods is determined as the first historical position request data.

[0054] Optionally, the aforementioned multiple historical moments can be the moments in a historical period when the second historical location request data is received; the second location indicated by the second historical location request data corresponding to each historical moment can be partially the same, completely the same, or completely different.

[0055] In actual implementation, for each historical moment, the state of the target motor corresponding to that historical moment can be determined first; if the state of the target motor corresponding to that historical moment is an abnormal state, the second historical position request data corresponding to that historical moment can be excluded; if the state of the target motor corresponding to that historical moment is a normal state, the second historical position request data corresponding to that historical moment can be retained; then the second historical position request data corresponding to the remaining historical moments among multiple historical moments can be determined as the first historical position request data.

[0056] This application embodiment, by excluding the second historical position request data corresponding to each historical moment in response to the target motor being in an abnormal state at the corresponding historical moment, and by determining the second historical position request data corresponding to the remaining historical moments in the multiple historical moments as the first historical position request data, can reduce the interference of invalid original position request data in historical periods on the current position of the predicted execution component, thereby improving the accuracy of predicting the current position of the execution component based on the first historical position request data.

[0057] Please see Figure 2 In one specific embodiment, the motor control method provided in this application may further include, but is not limited to, the following steps: Step S201: In response to receiving the zero-finding instruction, determine whether there is a second historical position request data; If no second historical location request data is available, proceed to step S202: determine the fixed distance as the target distance; If there is a second historical location request data, then execute step S203: based on the working status of the target motor in the historical period, filter the second historical location request data to obtain the first historical location request data; Step S204: Determine the target distance based on the first historical location request data; Step S205: Control the target motor to drive the actuator to move towards the endpoint position; Step S206: In response to the target distance being reached by the movement of the actuator towards the endpoint position, control the target motor to drive the actuator towards the zero position until the actuator reaches the zero position.

[0058] The specific implementation process of each step in this embodiment can be found in the relevant descriptions in the above embodiments, and will not be repeated here.

[0059] Taking a stepper motor with open-loop control as the target motor and the valve core of an expansion valve as the actuator, the second historical position request data in step S201 can be extracted from the expansion valve bus request signal obtained from the remote data terminal, such as request data indicating that the stepper motor drives the valve core to move to the second position within the last 30 minutes. The second historical position request data can also be understood as historical position preference data. The fixed distance in step S202 can be 3 / 5 of the total stroke distance between the zero position and the end position of the valve core.

[0060] In this embodiment, in response to receiving a zero-finding instruction, a fixed distance is first determined as the target distance based on the existence of historical position request data, or the target distance is determined based on historical position request data. Then, the target motor drives the actuator to move towards the endpoint position. In response to the actuator moving the distance towards the endpoint position reaching the target distance, the target motor drives the actuator to move towards the zero point position until the actuator moves to the zero point position. This improves the robustness of the motor control method provided in this embodiment.

[0061] The following combination Figure 3 Continuing with the example of a stepper motor with open-loop control as the target motor and the valve core of an expansion valve as the actuator, the technical effects of the motor control method provided in this application embodiment will be explained: Figure 3 The Zero and End positions represent the zero and end positions of the expansion valve core, respectively; Z, C, and T represent the zero position, the current predicted position, and the temporary position of the valve core when the core moves a distance towards the end position to reach the target distance, respectively; S represents the total stroke distance between the zero and end positions of the valve core; S1 represents the distance between the current predicted position C and the temporary position T of the valve core; S2 represents the distance between the zero position Z and the temporary position T of the valve core; S3 represents the distance between the current predicted position C and the zero position Z of the valve core; optionally, S1 = (S-S3) -50.

[0062] Without using the motor control method provided in the embodiments of this application, since the stepper motor cannot know the real-time position of the valve core in the open-loop control mode, in order to ensure that the valve core can move fully to the zero position, the motor will control the valve core to move from the current predicted position C to the Zero position with S pulses corresponding to the total stroke distance S. This will cause the motor to actually execute S-S3 more pulses. The extra number of pulses executed will cause the valve core to collide with the physical limit device of the Zero position for a long time after moving to the Zero position, resulting in obvious noise.

[0063] When using the motor control method provided in the embodiments of this application, the motor drives the valve core to move from the temporary position T to the Zero position using S pulses corresponding to the total stroke distance S. This only causes the motor to actually execute S-S2 more pulses. Assuming the motor running speed is constant, since S-S2 is much smaller than S-S3, the motor control method provided in the embodiments of this application can effectively reduce the time when the valve core moves to the Zero position and collides with the physical limit device of the Zero position, thereby reducing the noise caused by the collision between the two.

[0064] For example, assume that the total travel distance S corresponds to S pulses = 800 pulses, the distance S3 between the current predicted position C of the valve core and the zero position Z corresponds to S3 pulses = 200 pulses, and the motor's operating speed is 100 pulses / second; the distance S1 between the current predicted position C of the valve core and the temporary position T corresponds to S1 pulses = (S-S3) - 50 = 550 pulses; and the distance S2 between the temporary position T of the valve core and the zero position corresponds to S2 pulses = S1 + S3 = 750 pulses.

[0065] Without using the motor control method provided in the embodiments of this application, the valve core is searched for the Zero position using S pulses, which takes 8 seconds in total. Of these, only S3 pulses correspond to the effective search stroke, which takes about 2 seconds. The remaining 6-second strokes corresponding to the S-S3 pulses are all characterized by the continuous impact between the valve core and the physical limit device of the Zero position, which will generate significant noise.

[0066] When using the motor control method provided in this application embodiment, the same S pulses are used to find the Zero position of the valve core, and the overall time is still 8 seconds. However, S2 pulses correspond to the effective search stroke, which takes 7.5 seconds. Only the 0.5-second stroke corresponding to the remaining S-S2 pulses is manifested as the continuous impact between the valve core and the physical limit device of the Zero position. Compared with the 6-second continuous impact time without this solution, this solution can shorten the continuous impact time between the valve core and the physical limit device of the Zero position to less than 1 second, thereby significantly reducing the noise caused by the impact between the two.

[0067] The motor control method provided in this application, upon receiving a zero-finding command, first controls the target motor to drive the actuator towards the endpoint position, thus moving the actuator away from the zero point position. Then, based on the distance between the zero point position and the endpoint position, it controls the motor to drive the actuator towards the zero point position until the actuator reaches the zero point position. This effectively reduces the duration of the collision between the actuator and the zero point position, thereby reducing the noise generated by the collision. Furthermore, compared to modifying the hardware mechanical structure to solve the collision noise, this solution does not require additional hardware or mechanical modification costs, resulting in a lower overall implementation cost.

[0068] Please see Figure 4 This application also provides a motor control device 400, which can implement the above-mentioned motor control method. The device 400 may include a first control module 401 and a second control module 402.

[0069] The first control module 401 is used to control the target motor drive actuator to move towards the end position in response to receiving the zero-finding command; the zero-finding command is used to instruct the target motor drive actuator to move to the zero position; the zero position and the end position are the mechanical travel limit positions of the actuator; The second control module 402 is used to respond to the target distance reached by the movement of the actuator towards the end position, based on the distance between the zero position and the end position, to control the target motor to drive the actuator to move towards the zero position until the actuator moves to the zero position.

[0070] The motor control device provided in this application embodiment can implement all the steps of the above-described motor control method embodiment and achieve the same technical effect. To avoid repetition, it will not be described again here.

[0071] This application also provides an electronic device, including a processor and a memory. The memory stores a program or instructions that can be executed on the processor. When the program or instructions are executed by the processor, they implement the various steps of the above-described motor control method embodiments and achieve the same technical effect. To avoid repetition, they will not be described again here.

[0072] Figure 5 To illustrate the hardware structure of the electronic device according to the embodiments of this application, the electronic device includes: The processor 501 can be implemented using a general-purpose central processing unit (CPU), microprocessor, application specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this application. The memory 502 can be implemented as a read-only memory (ROM), static storage device, dynamic storage device, or random access memory (RAM). The memory 502 can store the operating system and other applications. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 502 and is called and executed by the processor 501 using the motor control method of the embodiments of this application. The input / output interface 503 is used to implement information input and output; The communication interface 504 is used to enable communication and interaction between this electronic device and other devices. Communication can be achieved through wired means (such as USB, network cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.). Bus 505 transmits information between various components of an electronic device (e.g., processor 501, memory 502, input / output interface 503, and communication interface 504); The processor 501, memory 502, input / output interface 503, and communication interface 504 are connected to each other within the electronic device via bus 505.

[0073] The electronic device provided in this application embodiment can implement all the steps of the above-described motor control method embodiment and achieve the same technical effect. To avoid repetition, it will not be described again here.

[0074] This application also provides a computer-readable storage medium storing a program or instructions. When the program or instructions are executed by a processor, they implement the various steps of the above-described motor control method embodiments and achieve the same technical effect. To avoid repetition, they will not be described again here.

[0075] The processor is the processor in the electronic device described in the above embodiments. The computer-readable storage medium includes computer-readable storage media such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.

[0076] This application also provides a chip, which includes a processor and a communication interface. The communication interface and the processor are coupled. The processor is used for motion programs or instructions to implement the various steps of the above-described motor control method embodiments and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0077] It should be understood that the chip mentioned in the embodiments of this application may also be referred to as a system-on-a-chip, system chip, chip system, or system-on-a-chip, etc.

[0078] This application provides a computer program product, which is stored in a storage medium and executed by at least one processor to implement the various steps of the motor control method embodiment described above, and can achieve the same technical effect. To avoid repetition, it will not be described again here.

[0079] This application also provides a vehicle including the aforementioned electronic equipment. The vehicle provided in this application, through the aforementioned electronic equipment, can implement the various steps of the motor control method embodiments described above and achieve the same technical effects. To avoid repetition, further details are omitted here.

[0080] It should be noted that, in this document, 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 delete other identical elements present in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.

[0081] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods of the various embodiments of this application.

[0082] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.

Claims

1. A motor control method, characterized in that, include: In response to receiving a zero-finding command, the target motor drives the actuator to move towards the endpoint position. The zero-finding command is used to instruct the target motor to drive the actuator to move to the zero position; the zero position and the endpoint position are the mechanical travel limit positions of the actuator; In response to the actuator moving a distance toward the endpoint position to reach a target distance, based on the distance between the zero point position and the endpoint position, the target motor is controlled to drive the actuator to move toward the zero point position until the actuator moves to the zero point position.

2. The motor control method as described in claim 1, characterized in that, Before controlling the target motor to drive the actuator to move towards the zero position based on the distance between the zero position and the end position after the distance the actuator moves towards the end position reaches the target distance, the method further includes: Based on the first historical position request data, the current predicted position of the execution component is determined; the first historical position request data is request data from a historical time period used to instruct the target motor to drive the execution component to the first position; The target distance is determined based on the distance between the current predicted position and the zero point position, and the distance between the zero point position and the endpoint position.

3. The motor control method as described in claim 2, characterized in that, Determining the current predicted position of the execution unit based on the first historical position request data includes: The total travel distance of the actuator from the zero point position to the end point position is divided into multiple travel intervals; Based on the first historical location request data, determine the weight of each of the travel intervals; The current predicted position of the execution unit is determined based on each travel interval and the weight of each travel interval.

4. The motor control method as described in claim 3, characterized in that, The step of determining the weight of each travel interval based on the first historical location request data includes: For each travel interval, based on the first historical location request data, determine the number of times the execution unit is located in the travel interval; The weight of the travel interval is determined based on the number of times the execution component is located within the travel interval.

5. The motor control method as described in claim 2, characterized in that, Before determining the current predicted position of the execution unit based on the first historical position request data, the method further includes: Obtain second historical position request data; the second historical position request data is the request data used by the historical time period to instruct the target motor to drive the execution component to the second position; Based on the operating status of the target motor during the historical period, the second historical location request data is filtered to obtain the first historical location request data.

6. The motor control method as described in claim 5, characterized in that, The historical period includes multiple historical moments; The step of filtering the second historical location request data based on the operating status of the target motor during the historical period to obtain the first historical location request data includes: For each of the plurality of historical moments, in response to the target motor being in an abnormal state corresponding to the historical moment, the second historical position request data corresponding to the historical moment is excluded; The second historical location request data corresponding to the remaining historical time among the plurality of historical time moments is determined as the first historical location request data.

7. A motor control device, characterized in that, The device includes a first control module and a second control module; The first control module is used to control the target motor to drive the actuator to move towards the endpoint position in response to receiving a zero-finding command; the zero-finding command is used to instruct the target motor to drive the actuator to move to the zero point position; the zero point position and the endpoint position are the mechanical travel limit positions of the actuator; The second control module is used to respond to the target distance reached by the actuator moving in the direction of the endpoint position, based on the distance between the zero point position and the endpoint position, to control the target motor to drive the actuator to move in the direction of the zero point position until the actuator moves to the zero point position.

8. An electronic device, characterized in that, The electronic device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the motor control method as described in any one of claims 1 to 6.

9. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the motor control method as described in any one of claims 1 to 6.

10. A vehicle, characterized in that, The vehicle includes the electronic equipment as described in claim 8.