WO2021128338A1 - Motor vibration displacement control method, storage medium, and electronic device - Google Patents

Motor vibration displacement control method, storage medium, and electronic device Download PDF

Info

Publication number
WO2021128338A1
WO2021128338A1 PCT/CN2019/129416 CN2019129416W WO2021128338A1 WO 2021128338 A1 WO2021128338 A1 WO 2021128338A1 CN 2019129416 W CN2019129416 W CN 2019129416W WO 2021128338 A1 WO2021128338 A1 WO 2021128338A1
Authority
WO
WIPO (PCT)
Prior art keywords
voltage
displacement
vibrator
motor
value
Prior art date
Application number
PCT/CN2019/129416
Other languages
French (fr)
Chinese (zh)
Inventor
郑亚军
向征
Original Assignee
瑞声声学科技(深圳)有限公司
瑞声科技(新加坡)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 瑞声声学科技(深圳)有限公司, 瑞声科技(新加坡)有限公司 filed Critical 瑞声声学科技(深圳)有限公司
Priority to PCT/CN2019/129416 priority Critical patent/WO2021128338A1/en
Publication of WO2021128338A1 publication Critical patent/WO2021128338A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • HELECTRICITY
    • H02GENERATION; CONVERSION OR DISTRIBUTION OF ELECTRIC POWER
    • H02PCONTROL OR REGULATION OF ELECTRIC MOTORS, ELECTRIC GENERATORS OR DYNAMO-ELECTRIC CONVERTERS; CONTROLLING TRANSFORMERS, REACTORS OR CHOKE COILS
    • H02P25/00Arrangements or methods for the control of AC motors characterised by the kind of AC motor or by structural details
    • H02P25/02Arrangements or methods for the control of AC motors characterised by the kind of AC motor or by structural details characterised by the kind of motor
    • H02P25/06Linear motors

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Power Engineering (AREA)
  • General Electrical Machinery Utilizing Piezoelectricity, Electrostriction Or Magnetostriction (AREA)

Abstract

A motor vibration displacement control method, a storage medium, and an electronic device. A preset basic voltage signal is updated according to a preset limited displacement value and a specific motor system response. Furthermore, if a linear motor is driven by the updated basic voltage signal, and an oscillator cannot move from an original displacement point to the displacement limiting position, several segments of alternating positive and negative start-up voltages are added to the basic voltage signal, so that the motor is driven by the basic voltage signal to which the start-up voltage is added, and the oscillator can move from the original displacement point to the displacement limiting position. The method is a directional derivative update of the basic voltage signal, and has fast computing speed and higher efficiency. The startup is rapid, and the oscillator can achieve a maximum limited displacement.

Description

马达振动位移的控制方法、存储介质及电子设备Motor vibration displacement control method, storage medium and electronic equipment 技术领域Technical field
本发明涉及线性马达技术领域,尤其涉及一种线性马达位移的控制方法、存储介质及电子设备。 The present invention relates to the technical field of linear motors, in particular to a method for controlling the displacement of a linear motor, a storage medium and electronic equipment.
背景技术Background technique
线性马达由于结构尺寸的限制与驱动电压的限制,其存在最大振动强度,即振子存在最大限制位移。传统的驱动方式为通过穷举的方式生成多个信号,然后从中选取能最快实现限制位移的信号。但是此驱动方式是一种随机的生成方式,计算时间过长且效率过低,因此线性马达在传统的驱动方式下,存在启动慢和振子达不到最大限制位移的问题。Due to the limitation of the structure size and the limitation of the driving voltage, the linear motor has the maximum vibration intensity, that is, the vibrator has the maximum limited displacement. The traditional driving method is to generate multiple signals in an exhaustive manner, and then select the signal that can limit the displacement the fastest. However, this driving method is a random generation method, and the calculation time is too long and the efficiency is too low. Therefore, in the traditional driving method of the linear motor, there are problems of slow start and the vibrator cannot reach the maximum limit displacement.
技术问题technical problem
鉴于上述现有技术的不足,本发明的目的在于提供一种马达振动位移的控制方法、存储介质及电子设备,旨在解决现有技术中线性马达存在启动慢和振子达不到最大限制位移的问题。In view of the above-mentioned shortcomings of the prior art, the purpose of the present invention is to provide a method for controlling the vibration displacement of a motor, a storage medium and an electronic device, aiming to solve the problem of slow start-up of linear motors and failure of the vibrator to reach the maximum limit displacement in the prior art. problem.
技术解决方案Technical solutions
第一方面,本发明提供了一种马达振动位移的控制方法,应用于一线性马达,以使所述线性马达的振子从位移原点处运动至限制位移处,所述马达振动位移的控制方法包括:In the first aspect, the present invention provides a method for controlling the vibration displacement of a motor, which is applied to a linear motor, so that the vibrator of the linear motor moves from the origin of the displacement to the position where the displacement is limited. The method for controlling the vibration displacement of the motor includes :
S1、预先设置一限制位移值以及一基础电压信号;S1, preset a limit displacement value and a basic voltage signal;
其中,所述限制位移值为位移原点处与限制位移处之间的直线距离值,所述基础电压信号的设置具体为设置电压幅值以及设置电压时长;Wherein, the limit displacement value is the linear distance value between the origin of the displacement and the limit displacement, and the setting of the basic voltage signal is specifically the setting of the voltage amplitude and the setting of the voltage duration;
S2、根据一指定的马达系统响应以及所述限制位移值与基础电压信号,将所述基础电压信号的预设电压时长更新为实际电压时长,并获取所述振子的初始位移值;S2, according to a specified motor system response and the limit displacement value and the basic voltage signal, update the preset voltage duration of the basic voltage signal to the actual voltage duration, and obtain the initial displacement value of the vibrator;
S3、判断所述振子的初始位移值是否等于0;S3: Determine whether the initial displacement value of the vibrator is equal to 0;
若等于,则输出当前基础电压信号;If it is equal, output the current basic voltage signal;
若不等于,则根据所述马达系统响应以及所述振子的初始位移值,为基础电压信号增设若干段正负交替的启动电压后,输出当前基础电压信号;If it is not equal, output the current basic voltage signal after adding several segments of alternating positive and negative starting voltages to the basic voltage signal according to the response of the motor system and the initial displacement value of the vibrator;
S4、用当前基础电压信号驱动所述马达,实现振动位移;S4. Use the current basic voltage signal to drive the motor to realize vibration displacement;
其中,所述马达系统响应为马达在驱动电压驱动下振子从位移原点处运动至位移终点处,且振子在位移原点处和位移终点处的速度均为0;所述马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值。Wherein, the response of the motor system is that the vibrator moves from the origin of the displacement to the end of the displacement under the driving voltage of the motor, and the speed of the vibrator at the origin of the displacement and the end of the displacement are both 0; the response of the motor system is used according to a The driving voltage and a set displacement end point value are used to obtain the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator.
进一步地,所述步骤S2包括:Further, the step S2 includes:
S21、在所述马达系统响应下,将所述限制位移值设置为位移终点值,并将所述基础电压信号设置为驱动电压;S21: In response to the motor system, the limit displacement value is set as a displacement end value, and the basic voltage signal is set as a driving voltage;
S22、获取对应于所述基础电压信号的实际电压时长以及所述振子的初始位移值后,将所述基础电压信号的预设电压时长更新为实际电压时长。S22: After obtaining the actual voltage duration corresponding to the basic voltage signal and the initial displacement value of the vibrator, update the preset voltage duration of the basic voltage signal to the actual voltage duration.
进一步地,所述步骤S3包括:Further, the step S3 includes:
S31、若所述振子的初始位移值不等于0,则设置第一段启动电压;其中,启动电压的设置具体为设置电压幅值以及设置电压时长,所述第一段启动电压的电压幅值与所述基础电压信号的电压幅值方向相反;S31. If the initial displacement value of the vibrator is not equal to 0, set the first-stage starting voltage; wherein, the setting of the starting voltage specifically includes setting the voltage amplitude and setting the voltage duration, and the voltage amplitude of the first-stage starting voltage The direction of the voltage amplitude is opposite to the voltage amplitude of the basic voltage signal;
S32、在所述马达系统响应下,将所述振子的初始位移值设置为位移终点值,并将所述第一段启动电压设置为驱动电压;S32. In response to the motor system, the initial displacement value of the vibrator is set as a displacement end value, and the first segment start voltage is set as a driving voltage;
S33、获取对应于所述第一段启动电压的实际电压时长以及所述振子的当前初始位移值后,将所述第一段启动电压的预设电压时长更新为实际电压时长。S33. After obtaining the actual voltage duration corresponding to the first segment of the startup voltage and the current initial displacement value of the vibrator, update the preset voltage duration of the first segment of the startup voltage to the actual voltage duration.
再进一步地,所述步骤S3还包括:Still further, the step S3 further includes:
S34、若所述振子的当前初始位移值等于0,则为当前基础电压信号增设所述第一段启动电压,输出当前基础电压信号后执行步骤S4。S34. If the current initial displacement value of the vibrator is equal to 0, add the first-stage start voltage to the current basic voltage signal, and perform step S4 after outputting the current basic voltage signal.
再进一步地,所述步骤S3还包括:Still further, the step S3 further includes:
S35、若所述振子的当前初始位移值不等于0,则设置下一段启动电压;其中,所述下一段启动电压的电压幅值与当前启动电压的电压幅值方向相反;S35. If the current initial displacement value of the vibrator is not equal to 0, set the start voltage of the next segment; wherein the voltage amplitude of the next segment of the start voltage is opposite to the voltage amplitude of the current start voltage;
S36、在所述马达系统响应下,将所述振子的当前初始位移值设置为位移终点值,并将所述下一段启动电压设置为驱动电压;S36. In response to the motor system, set the current initial displacement value of the vibrator as a displacement end value, and set the next-stage start voltage as a driving voltage;
S37、获取对应于所述下一段启动电压的实际电压时长以及下一次振子的初始位移值后,将所述下一段启动电压的预设电压时长更新为实际电压时长;S37: After obtaining the actual voltage duration corresponding to the next segment of the startup voltage and the initial displacement value of the next vibrator, update the preset voltage duration of the next segment of the startup voltage to the actual voltage duration;
S38、判断所述下一次振子的初始位移值是否等于0;S38: Determine whether the initial displacement value of the vibrator is equal to 0 for the next time;
若不等于,则返回步骤S35;If it is not equal, return to step S35;
若等于,则为当前基础电压信号依次增设所有启动电压后,输出当前基础电压信号。If it is equal, the current basic voltage signal is output after all starting voltages are sequentially added to the current basic voltage signal.
进一步地,所述马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值,具体为:Further, the motor system response is used to obtain the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator according to a driving voltage and a set displacement end value, specifically:
将所述驱动电压以及设置的位移终点值输入至马达虚拟模型中,在所述马达系统响应下,计算出对应于所述驱动电压的实际电压时长和振子的初始位移值;Input the driving voltage and the set displacement end point value into the virtual motor model, and in response to the motor system, calculate the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator;
其中,所述马达虚拟模型对应于所述马达。Wherein, the virtual model of the motor corresponds to the motor.
进一步地,所述马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值,具体为:Further, the motor system response is used to obtain the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator according to a driving voltage and a set displacement end value, which is specifically:
A、将当前初始位移值设置为0;A. Set the current initial displacement value to 0;
B、用当前驱动电压驱动马达虚拟系统后,判断振子在起始时刻的速度响应是否等于0;B. After driving the virtual system of the motor with the current driving voltage, judge whether the speed response of the vibrator at the initial moment is equal to 0;
若不等于,则修正当前驱动电压的电压时长后,重新执行本步骤;If it is not equal, after correcting the voltage duration of the current driving voltage, perform this step again;
若等于,则执行步骤C;If it is equal, go to step C;
C、判断振子的位移响应是否等于所述设置的位移终点值;C. Determine whether the displacement response of the vibrator is equal to the set displacement end value;
若不等于,则修正当前初始位移值后,返回步骤B;If it is not equal, after correcting the current initial displacement value, return to step B;
若等于,则输出对应于所述驱动电压的实际电压时长和振子的初始位移值。If it is equal, output the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator.
第二方面,本发明提供了一种计算机可读存储介质,所述计算机可读存储介质上存储有马达振动位移的控制程序,所述马达振动位移的控制程序被处理器运行时执行如第一方面所述的马达振动位移的控制方法的步骤。In a second aspect, the present invention provides a computer-readable storage medium, the computer-readable storage medium stores a motor vibration displacement control program, the motor vibration displacement control program is executed when the processor is running, as in the first The steps of the method for controlling the vibration displacement of the motor described in the aspect.
第三方面,本发明提供了一种电子设备,所述电子设备包括存储器、处理器以及存储在所述存储器上并可在所述处理器上运行的马达振动位移的控制程序,所述马达振动位移的控制程序被所述处理器执行时实现如第一方面所述的马达振动位移的控制方法的步骤。In a third aspect, the present invention provides an electronic device that includes a memory, a processor, and a motor vibration displacement control program that is stored in the memory and can be run on the processor. The motor vibrates When the displacement control program is executed by the processor, the steps of the method for controlling the vibration displacement of the motor as described in the first aspect are realized.
有益效果Beneficial effect
有益效果:本发明提供的一种马达振动位移的控制方法、存储介质及电子设备,本发明通过预设的限制位移值和指定的马达系统响应,更新预设的基础电压信号,更进一步的,若线性电机在更新后的基础电压信号驱动下振子无法从位移原点处运动至限制位移处,则为基础电压信号增设若干段正负交替的启动电压,以使马达在增设启动电压后的基础电压信号驱动下,振子能够从位移原点处运动至限制位移处。可以看出,本发明对基础电压信号是一种有方向性的推导更新,计算速度快且效率更高。与现有技术相比,马达在本实施例的驱动方式下,不仅启动快且可以使振子实现最大限制位移。Beneficial effects: The present invention provides a method for controlling vibration displacement of a motor, a storage medium, and electronic equipment. The present invention updates the preset basic voltage signal through a preset limit displacement value and a specified motor system response, and furthermore, If the linear motor is driven by the updated basic voltage signal, the vibrator cannot move from the origin of the displacement to the limit of the displacement, add a number of alternating positive and negative starting voltages to the basic voltage signal, so that the basic voltage of the motor after the starting voltage is increased Driven by the signal, the vibrator can move from the displacement origin to the limit displacement. It can be seen that the present invention is a directional derivation update for the basic voltage signal, and the calculation speed is faster and the efficiency is higher. Compared with the prior art, in the driving mode of this embodiment, the motor not only starts quickly but also enables the vibrator to achieve the maximum limit displacement.
附图说明Description of the drawings
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明中记载的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to explain the embodiments of the present invention or the technical solutions in the prior art more clearly, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only These are some embodiments described in the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative work.
图1为本发明实施例1所提供的一种马达振动位移的控制方法的流程图;FIG. 1 is a flowchart of a method for controlling vibration displacement of a motor provided by Embodiment 1 of the present invention;
图2为本发明实施例1中第二种获取驱动电压的实际电压时长和振子的初始位移值的流程图;2 is a second method of obtaining the actual voltage duration of the driving voltage and the initial displacement value of the vibrator in Embodiment 1 of the present invention;
图3为本发明实施例2所提供的电子设备的结构示意图。FIG. 3 is a schematic structural diagram of an electronic device provided by Embodiment 2 of the present invention.
本发明的实施方式Embodiments of the present invention
为了使本技术领域的人员更好地理解本发明方案,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。In order to enable those skilled in the art to better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be described clearly and completely in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only It is a part of the embodiments of the present invention, not all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative work shall fall within the protection scope of the present invention.
实施例Example 11
本实施例提供了一种马达振动位移的控制方法,应用于一线性马达,以使所述线性马达的振子从位移原点处运动至限制位移处,请参阅图1,该方法包括:This embodiment provides a method for controlling the vibration displacement of a motor, which is applied to a linear motor so that the vibrator of the linear motor moves from the displacement origin to the restricted displacement. Please refer to FIG. 1. The method includes:
S1、预先设置一限制位移值以及一基础电压信号。S1, preset a limit displacement value and a basic voltage signal.
在上述步骤S1中,限制位移为在本次控制方法中马达的振子所要实现的实际位移,因此限制位移值为位移原点处与限制位移处之间的直线距离值。限制位移值最大可设置为振子的最大限制位移值,也就是说,通过本实施例振子可以运动到最大限制位移处。In the above step S1, the limit displacement is the actual displacement to be achieved by the vibrator of the motor in this control method, so the limit displacement value is the linear distance value between the origin of the displacement and the limit displacement. The maximum limit displacement value can be set to the maximum limit displacement value of the vibrator, that is, the vibrator can move to the maximum limit displacement through this embodiment.
另外,基础电压信号为单向电压,需设置其电压幅值和电压时长。但需要说明的是,电压幅值和电压时长均可以任意设置,但电压幅值不得大于马达的最大输出电压。In addition, the basic voltage signal is a unidirectional voltage, and its voltage amplitude and voltage duration need to be set. However, it should be noted that the voltage amplitude and voltage duration can be set arbitrarily, but the voltage amplitude must not be greater than the maximum output voltage of the motor.
在本实施例中,将限制位移值设置为振子的最大限制位移值,将基础电压信号的电压幅值设置为马达的最大输出电压(记为Vmax),电压时长合理设置。In this embodiment, the limit displacement value is set as the maximum limit displacement value of the vibrator, the voltage amplitude of the basic voltage signal is set as the maximum output voltage of the motor (denoted as Vmax), and the voltage duration is set reasonably.
S2、根据一指定的马达系统响应以及所述限制位移值与基础电压信号,将所述基础电压信号的预设电压时长更新为实际电压时长,并获取所述振子的初始位移值。S2. According to a specified motor system response and the limited displacement value and the basic voltage signal, update the preset voltage duration of the basic voltage signal to the actual voltage duration, and obtain the initial displacement value of the vibrator.
在上述步骤S2 中,需要在指定的马达系统响应下,获取基础电压信号的实际电压时长以及振子的初始位移值,接着将基础电压信号的预设电压时长(即步骤S1中设置的电压时长)更新为实际电压时长(记为t 0)。 In the above step S2, it is necessary to obtain the actual voltage duration of the basic voltage signal and the initial displacement value of the vibrator under the response of the specified motor system, and then set the preset voltage duration of the basic voltage signal (that is, the voltage duration set in step S1) Update to the actual voltage duration (denoted as t 0 ).
马达系统响应为马达在驱动电压的驱动下的运动响应特征,上述步骤S2中的马达系统响应为马达在一驱动电压驱动下振子从位移原点处运动至位移终点处,且振子在位移原点处和位移终点处的速度均为0。The motor system response is the motion response characteristic of the motor driven by the driving voltage. The motor system response in the above step S2 is that the vibrator moves from the displacement origin to the displacement end under the driving voltage of the motor, and the vibrator is at the displacement origin and The speed at the end of the displacement is 0.
具体来说,振子在位移原点处和位移终点处的速度均为0,即振子以静止状态从位移原点运动至位移终点,且运动到位移终点的时候振子刚好停下来。如此,一方面,振子在位移原点处没有初速度,因此不存在因初速度导致振子的实际位移变大的问题;另一方面,振子在位移终点处的速度刚好为0,则振子不会因为惯性的原因导致振子的实际位移变大。因此,本实施例中的马达系统响应,使本实施例所提供的方法能够实现精准控制。Specifically, the speed of the vibrator at the origin of the displacement and the end of the displacement are both 0, that is, the vibrator moves from the origin of the displacement to the end of the displacement in a static state, and the vibrator just stops when it moves to the end of the displacement. In this way, on the one hand, the vibrator has no initial velocity at the origin of the displacement, so there is no problem that the actual displacement of the vibrator becomes larger due to the initial velocity; on the other hand, if the velocity of the vibrator at the end of the displacement is exactly 0, the vibrator will not The inertia causes the actual displacement of the vibrator to become larger. Therefore, the motor system in this embodiment responds, so that the method provided in this embodiment can achieve precise control.
因此,步骤S2中的马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值。Therefore, the motor system response in step S2 is used to obtain the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator according to a driving voltage and a set displacement end value.
具体来说,在驱动电压和位移终点值确定的情况下,在该马达系统响应下,可以获取到驱动电压的实际电压时长和振子的初始位移值。Specifically, when the driving voltage and the displacement end value are determined, the actual voltage duration of the driving voltage and the initial displacement value of the vibrator can be obtained under the response of the motor system.
进一步地,“马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值”具体为:Further, the “response of the motor system is used to obtain the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator according to a driving voltage and a set displacement end value” specifically as follows:
将所述驱动电压以及设置的位移终点值输入至马达虚拟模型中,在所述马达系统响应下,计算出对应于所述驱动电压的实际电压时长和振子的初始位移值。其中,所述马达虚拟模型对应于所述马达,即马达虚拟模型与本实施例使用的实际马达相对应。The driving voltage and the set displacement end value are input into the virtual motor model, and under the response of the motor system, the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator are calculated. Wherein, the motor virtual model corresponds to the motor, that is, the motor virtual model corresponds to the actual motor used in this embodiment.
具体来说,上述方式为获取驱动电压的实际电压时长和振子的初始位移值的第一种方式。具体的,马达的虚拟模型用物理方程表示如下:Specifically, the above method is the first method for obtaining the actual voltage duration of the driving voltage and the initial displacement value of the vibrator. Specifically, the virtual model of the motor is represented by physical equations as follows:
Figure dest_path_image002
Figure dest_path_image002
Figure dest_path_image004
Figure dest_path_image004
其中,m为振子的质量,c为阻尼系数,k为弹簧弹性系数,BL为电磁力系数,R为线圈静态电阻,L为线圈电感,x为振子位移,i为电流,u为驱动电压,t为时间。需要说明的是,由于马达虚拟模型对应用于实际的马达,因此m、c、k、BL、R和L均为固定参数。Among them, m is the mass of the vibrator, c is the damping coefficient, k is the spring elasticity coefficient, BL is the electromagnetic force coefficient, R is the static resistance of the coil, L is the coil inductance, x is the displacement of the vibrator, i is the current, and u is the driving voltage. t is time. It should be noted that since the virtual motor model corresponds to the actual motor, m, c, k, BL, R, and L are all fixed parameters.
因此,在上述物理方程中,设驱动电压的幅值为V K,其电压时长为t K,设位移终点值为X K,则在该马达系统响应下,可以知道u(t)= V K,x(t=t K)= X K
Figure dest_path_image006
(即位移原点处速度为0)和
Figure dest_path_image008
(即位移终点处速度为0),如此,将所有已知条件代入上述物理方程中,即可计算出驱动电压的实际电压时长和振子的初始位移值。
Therefore, in the above physical equation, suppose the amplitude of the driving voltage is V K , its voltage duration is t K , and the displacement end value is X K , then under the response of the motor system, u(t) = V K , X(t=t K )= X K ,
Figure dest_path_image006
(That is, the velocity at the origin of the displacement is 0) and
Figure dest_path_image008
(That is, the velocity at the end of the displacement is 0). In this way, by substituting all known conditions into the above physical equations, the actual voltage duration of the driving voltage and the initial displacement value of the vibrator can be calculated.
进一步地,“所述马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值”具体为:Further, the “response of the motor system is used to obtain the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator according to a driving voltage and a set displacement end value” specifically as follows:
A、将当前初始位移值设置为0;A. Set the current initial displacement value to 0;
B、用当前驱动电压驱动马达虚拟系统后,判断振子在起始时刻的速度响应是否等于0;B. After driving the virtual system of the motor with the current driving voltage, judge whether the speed response of the vibrator at the initial moment is equal to 0;
若不等于,则修正当前驱动电压的电压时长后,重新执行本步骤;If it is not equal, after correcting the voltage duration of the current driving voltage, perform this step again;
若等于,则执行步骤C;If it is equal, go to step C;
C、判断振子的位移响应是否等于所述设定的位移终点值;C. Determine whether the displacement response of the vibrator is equal to the set displacement end value;
若不等于,则修正当前初始位移值后,返回步骤B;If it is not equal, after correcting the current initial displacement value, return to step B;
若等于,则输出对应于所述驱动电压的实际电压时长和振子的初始位移值。If it is equal, output the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator.
具体来说,上述方式为获取驱动电压的实际电压时长和振子的初始位移值的第二种方式,此方式可应用在不知道实际马达所对应的虚拟模型的情况下。具体的,每一次用驱动电压驱动马达虚拟系统,均可以得到一速度响应和一位移响应,速度响应指的是振子在起始时刻的速度,位移响应指的是振子所运动的位移值。根据速度响应可以修正驱动电压的电压时长,根据位移响应可以修正初始位移值,如此即可得到驱动电压的实际电压时长和振子的初始位移值。Specifically, the above method is the second method for obtaining the actual voltage duration of the driving voltage and the initial displacement value of the vibrator. This method can be applied in the case where the virtual model corresponding to the actual motor is not known. Specifically, each time the motor virtual system is driven with the driving voltage, a velocity response and a displacement response can be obtained. The velocity response refers to the velocity of the vibrator at the initial moment, and the displacement response refers to the displacement value of the vibrator. The voltage duration of the drive voltage can be corrected according to the speed response, and the initial displacement value can be corrected according to the displacement response, so that the actual voltage duration of the drive voltage and the initial displacement value of the vibrator can be obtained.
请参阅图2,此方式为一种不断循环更新的方式。具体的,先将初始位移值(记为Xm)设置为0,用驱动电压驱动后根据速度响应决定是否更新驱动电压的电压时长(记为t m),此时的电压时长为预设的电压时长。 Please refer to Figure 2. This method is a continuous loop update method. Specifically, first set the initial displacement value (denoted as Xm) to 0, and after driving with the driving voltage, determine whether to update the voltage duration of the driving voltage (denoted as t m ) according to the speed response, and the voltage duration at this time is the preset voltage duration.
若速度响应等于0,则不需更新t m。若速度响应不等于0,则需要更新t m,具体为增大t m的值,具体增大步长(记为△t)可合理设置。每一次更新后,都用更新后的驱动电压继续去驱动马达虚拟系统,直至某一次的速度响应等于0。 If the speed response is equal to 0, there is no need to update t m . If the speed response is not equal to 0, t m needs to be updated, specifically increasing the value of t m , and the specific increasing step length (denoted as △t) can be set reasonably. After each update, the updated drive voltage is used to continue to drive the motor virtual system until the speed response of a certain time is equal to 0.
在速度响应等于0的条件下,判断此次的位移响应是否等于设定的位移终点值(记为Xmax)。若位移响应不等于Xmax,则需更新Xm,具体为增大Xm的值,具体增大步长(记为△X)可合理设置,需要说明的是,△X的方向与Xmax的方向相反。然后继续用当前的驱动电压驱动马达虚拟系统,直至某一次的位移响应等于Xmax。需要说明的是,由于更新Xm是在速度响应等于0的条件下,因此每一次更新Xm,t m都需要经过一次完整的循环更新,也就是说,在完成X m的更新后,速度响应等于0且位移响应等于Xmax。 Under the condition that the speed response is equal to 0, judge whether the displacement response this time is equal to the set displacement end value (denoted as Xmax). If the displacement response is not equal to Xmax, Xm needs to be updated, specifically increasing the value of Xm. The specific increase step (denoted as △X) can be set reasonably. It should be noted that the direction of △X is opposite to the direction of Xmax. Then continue to drive the virtual motor system with the current drive voltage until the displacement response is equal to Xmax. It should be noted that since the update of Xm is under the condition that the speed response is equal to 0, every time Xm is updated, t m needs to go through a complete cycle update, that is, after the update of X m is completed, the speed response is equal to 0 and the displacement response is equal to Xmax.
如此,在更新完成之后得到的t m和Xm即分别为驱动电压的实际电压时长以及振子的初始位移值。 In this way, t m and Xm obtained after the update is completed are the actual voltage duration of the driving voltage and the initial displacement value of the vibrator, respectively.
进一步地,上述步骤S2包括:Further, the above step S2 includes:
S21、在所述马达系统响应下,将所述限制位移值设置为位移终点值,并将所述基础电压信号设置为驱动电压。S21: In response to the motor system, the limit displacement value is set as a displacement end value, and the basic voltage signal is set as a driving voltage.
S22、获取对应于所述基础电压信号的实际电压时长以及所述振子的初始位移值后,将所述基础电压信号的预设电压时长更新为实际电压时长。S22: After obtaining the actual voltage duration corresponding to the basic voltage signal and the initial displacement value of the vibrator, update the preset voltage duration of the basic voltage signal to the actual voltage duration.
在上述步骤S21和S22中,将限制位移值设置为位移终点值,以及将基础电压信号设置为驱动电压,如此,在前述马达系统响应下,通过前述两种方式均可获得基础电压信号的实际电压时长(记为t 0),以及步骤S2下的振子的初始位移值(记为x 0),具体获取方式此处不再赘述。在获取t 0之后,将基础电压信号的电压时长更新为t 0In the above steps S21 and S22, the limit displacement value is set as the displacement end value, and the basic voltage signal is set as the driving voltage. In this way, under the response of the aforementioned motor system, the actual value of the basic voltage signal can be obtained by the aforementioned two methods. The voltage duration (denoted as t 0 ), and the initial displacement value of the vibrator in step S2 (denoted as x 0 ), the specific acquisition method will not be repeated here. After obtaining t 0 , the voltage duration of the basic voltage signal is updated to t 0 .
S3、判断所述振子的初始位移值是否等于0;若等于,则输出当前基础电压信号;若不等于,则根据所述马达系统响应以及所述振子的初始位移值,为基础电压信号增设若干段正负交替的启动电压后,输出当前基础电压信号。S3. Determine whether the initial displacement value of the vibrator is equal to 0; if it is equal, output the current basic voltage signal; if it is not equal, add a number of basic voltage signals according to the response of the motor system and the initial displacement value of the vibrator After the start voltage is alternated between positive and negative, the current basic voltage signal is output.
在上述步骤S3中,根据步骤S2获取到的x 0判断是否需要为当前基础电压信号增设启动电压。具体的,若x 0等于0,则说明马达在当前基础电压信号驱动下振子可以运动至限制位移处,则不需要为基础电压信号增设启动电压,直接输出当前基础电压信号。若x 0不等于0,则说明马达在当前基础电压信号驱动下振子运动不到限制位移处,即只能从x 0运动到限制位移处,因此需要为当前基础电压信号增设若干段正负交替的启动电压,以使马达在增设后的基础电压信号驱动下振子能从位移原点处运动至限制位移处。需要说明的是,增设后的基础电压信号为一正负交替的电压信号。 In the above step S3, it is determined whether it is necessary to add a starting voltage to the current basic voltage signal according to x 0 obtained in step S2. Specifically, if x 0 is equal to 0, it means that the vibrator can move to the limit displacement under the current basic voltage signal, and there is no need to add a starting voltage to the basic voltage signal, and the current basic voltage signal is directly output. If x 0 is not equal to 0, it means that the vibrator cannot move to the limit displacement under the current basic voltage signal, that is, it can only move from x 0 to the limit displacement. Therefore, it is necessary to add a number of positive and negative alternations for the current basic voltage signal. The starting voltage of the motor is driven by the basic voltage signal after the addition of the motor, so that the vibrator can move from the displacement origin to the limit displacement. It should be noted that the added basic voltage signal is a voltage signal that alternates between positive and negative.
可以看出,通过预设的限制位移值和指定的马达系统响应,更新预设的基础电压信号,更进一步的,若马达在更新后的基础电压信号驱动下振子无法从位移原点处运动至限制位移处,则为基础电压信号增设若干段正负交替的启动电压。因此用输出后的基础电压信号驱动马达,振子可以运动至限制位移处。It can be seen that through the preset limit displacement value and the specified motor system response, the preset basic voltage signal is updated. Furthermore, if the motor is driven by the updated basic voltage signal, the vibrator cannot move from the displacement origin to the limit. At the displacement, a number of alternating positive and negative starting voltages are added to the basic voltage signal. Therefore, the basic voltage signal after the output is used to drive the motor, and the vibrator can move to the limited displacement.
进一步地,步骤S3包括:Further, step S3 includes:
S31、若所述振子的初始位移值不等于0,则设置第一段启动电压。S31. If the initial displacement value of the vibrator is not equal to 0, set the first-stage start voltage.
在上述步骤S31中,由于增设后的基础电压信号需为正负交替的电压信号,因此第一段启动电压的电压幅值需跟基础电压信号的电压幅值方向相反。本实施例中的每一段启动电压均为单向电压,且其电压幅值和电压时长的设置均跟基础电压信号的设置一致。在本实施例中,第一段启动电压的电压幅值设置为-Vmax,电压时长合理设置。In the above step S31, since the added basic voltage signal needs to be a positive-negative alternating voltage signal, the voltage amplitude of the first segment of the starting voltage needs to be in the opposite direction to the voltage amplitude of the basic voltage signal. In this embodiment, each segment of the starting voltage is a unidirectional voltage, and the setting of the voltage amplitude and the voltage duration are consistent with the setting of the basic voltage signal. In this embodiment, the voltage amplitude of the first-stage startup voltage is set to -Vmax, and the voltage duration is set reasonably.
S32、在所述马达系统响应下,将所述振子的初始位移值设置为位移终点值,并将所述第一段启动电压设置为驱动电压。S32. In response to the motor system, the initial displacement value of the vibrator is set as a displacement end value, and the first segment starting voltage is set as a driving voltage.
S33、获取对应于所述第一段启动电压的实际电压时长以及所述振子的当前初始位移值后,将所述第一段启动电压的预设电压时长更新为实际电压时长。S33. After obtaining the actual voltage duration corresponding to the first segment of the startup voltage and the current initial displacement value of the vibrator, update the preset voltage duration of the first segment of the startup voltage to the actual voltage duration.
在上述步骤S32和S33中,由于要使马达在第一段启动电压的驱动下,振子能从位移原点处运动至x 0,因此需检测第一段启动电压能不能使得振子从位移原点处运动至x 0。具体的,将x 0设置为位移终点值并将第一段启动电压设置为驱动电压,在前述马达系统响应下,通过前述两种方式均可获得对应于第一段启动电压的实际电压时长(记为t 1)以及振子的当前初始位移值(记为x 1),具体获取方式此处不再赘述。在获取t 1之后,将第一段启动电压的预设电压时长更新为t 1In the above steps S32 and S33, because the vibrator can move from the displacement origin to x 0 under the drive of the first segment of the starting voltage of the motor, it is necessary to detect whether the first segment of the starting voltage can make the vibrator move from the displacement origin To x 0 . Specifically, x 0 is set as the displacement end value and the first segment starting voltage is set as the driving voltage. Under the response of the aforementioned motor system, the actual voltage duration corresponding to the first segment starting voltage can be obtained through the aforementioned two methods ( Denoted as t 1 ) and the current initial displacement value of the vibrator (denoted as x 1 ), the specific acquisition method will not be repeated here. After obtaining t 1 , the preset voltage duration of the first stage of starting voltage is updated to t 1 .
S34、若所述振子的当前初始位移值等于0,则为当前基础电压信号增设所述第一段启动电压,输出当前基础电压信号后执行步骤S4。S34. If the current initial displacement value of the vibrator is equal to 0, the first segment start voltage is added to the current basic voltage signal, and step S4 is executed after the current basic voltage signal is output.
在上述步骤S34中,若x 1等于0,则说明马达在第一段启动电压驱动下振子可以从位移原点处运动至x 0,因此不需要再为基础电压信号增设启动电压。因此,将当前基础电压信号增设第一段启动电压后执行步骤S4。 In the above step S34, if x 1 is equal to 0, it means that the vibrator can move from the displacement origin to x 0 under the driving of the first-stage starting voltage of the motor, so there is no need to add a starting voltage to the basic voltage signal. Therefore, step S4 is executed after adding the current basic voltage signal to the first stage starting voltage.
S35、若所述振子的当前初始位移值不等于0,则设置下一段启动电压。S35. If the current initial displacement value of the vibrator is not equal to 0, set the next stage of starting voltage.
在上述步骤S35中,若x 1不等于0,则说明马达在第一段启动电压驱动下振子不能从位移原点处运动至x 0,因此需要再为基础电压信号增设启动电压。具体的,由前述可知下一段的启动电压的电压幅值需跟当前启动电压(即上一段启动电压)的电压幅值方向相反,如此才能使最终输出的基础电压信号为正负交替的电压信号。 In the above step S35, if x 1 is not equal to 0, it means that the vibrator cannot move from the displacement origin to x 0 under the driving of the first-stage starting voltage of the motor. Therefore, it is necessary to add a starting voltage to the basic voltage signal. Specifically, it can be seen from the foregoing that the voltage amplitude of the next segment's start voltage needs to be opposite to the current start voltage (that is, the previous segment's start voltage) voltage amplitude, so that the final output basic voltage signal is a positive and negative alternating voltage signal. .
S36、在所述马达系统响应下,将所述振子的当前初始位移值设置为位移终点值,并将所述下一段启动电压设置为驱动电压。S36. In response to the motor system, the current initial displacement value of the vibrator is set as a displacement end value, and the next segment start voltage is set as a driving voltage.
S37、获取对应于所述下一段启动电压的实际电压时长以及下一次振子的初始位移值后,将所述下一段启动电压的预设电压时长更新为实际电压时长。S37. After obtaining the actual voltage duration corresponding to the next segment of the startup voltage and the next initial displacement value of the vibrator, update the preset voltage duration of the next segment of the startup voltage to the actual voltage duration.
S38、判断所述下一次振子的初始位移值是否等于0;若不等于,则返回步骤S35;若等于,则为当前基础电压信号依次增设所有启动电压后,输出当前基础电压信号。S38: Determine whether the initial displacement value of the vibrator is equal to 0 for the next time; if it is not equal, return to step S35; if it is equal, then output the current basic voltage signal after all starting voltages are sequentially added to the current basic voltage signal.
在上述步骤S36-S38中,将x 1设置为位移终点值(即将上一次的初始位移值设置为位移终点值),并将下一段启动电压设置为驱动电压,在前述马达系统响应下,通过前述两种方式均可获得对应于下一段启动电压的实际电压时长以及下一次振子的初始位移值,具体获取方式此处不再赘述。在获取下一段启动电压的实际电压时长之后,将下一段启动电压的电压时长更新为实际电压时长。 In the above steps S36-S38, x 1 is set as the displacement end value (that is, the last initial displacement value is set as the displacement end value), and the starting voltage of the next stage is set as the driving voltage. Under the response of the aforementioned motor system, pass Both of the foregoing two methods can obtain the actual voltage duration corresponding to the starting voltage of the next segment and the initial displacement value of the next vibrator. The specific obtaining method will not be repeated here. After obtaining the actual voltage duration of the next segment of the startup voltage, the voltage duration of the next segment of the startup voltage is updated to the actual voltage duration.
若下一次振子的初始位移值等于0,则说明马达在最后一段增设的启动电压驱动下,振子能够从位移原点处运动至上一次的初始位移处,因此不需要在增设启动电压了,则依次为当前基础电压信号增设每一段启动电压。如此,马达在增设后的基础电压信号驱动下,振子能从位移原点处运动至限制位移处。具体的,为基础电压信号增设每一段启动电压的方式,简单理解即在基础电压信号后面依次拼接每一段启动电压,举个例子,假设基础电压信号为V0,假设有第一段启动电压V1、第二段启动电压V2、第三启动电压V3,则增设后的基础电压信号V0=[V3,V2 ,V1 ,V0]。If the initial displacement value of the vibrator next time is equal to 0, it means that the motor can move from the origin of the displacement to the initial displacement of the last time under the drive of the starting voltage added in the last stage. Therefore, there is no need to add the starting voltage. The current basic voltage signal adds the starting voltage for each segment. In this way, driven by the added basic voltage signal of the motor, the vibrator can move from the displacement origin to the restricted displacement. Specifically, the method of adding each segment of the start voltage to the basic voltage signal is simple to understand, that is, each segment of the start voltage is spliced after the basic voltage signal. For example, suppose the basic voltage signal is V0, and suppose there is a first segment of start voltage V1. The second-stage starting voltage V2 and the third starting voltage V3, the added basic voltage signal V0=[V3, V2, V1, V0].
若下一次振子的实际初始位移值还是不等于0,则说明马达在下一段增设的启动电压驱动下,振子还是不能从位移原点处运动至上一次的初始位移处,因此需要继续增加启动电压,直至某一次振子的初始位移值等于0。If the actual initial displacement value of the vibrator next time is still not equal to 0, it means that the vibrator still cannot move from the displacement origin to the previous initial displacement under the drive of the additional starting voltage in the next stage. Therefore, it is necessary to continue to increase the starting voltage until a certain value. The initial displacement value of the primary vibrator is equal to zero.
S4、用当前基础电压信号驱动所述马达,实现振动位移。S4. Use the current basic voltage signal to drive the motor to realize vibration displacement.
在上述步骤S4中,马达在步骤S3输出的基础电压信号驱动下,振子可以从位移原点处运动至限制位移处。需要说明的是,步骤S3输出的基础电压信号,可以使振子运动至其最大限制位移处。In the above step S4, the vibrator can move from the displacement origin to the restricted displacement under the driving of the basic voltage signal outputted by the motor in the step S3. It should be noted that the basic voltage signal output in step S3 can move the vibrator to its maximum limit displacement.
综上所述,本实施例通过预设的限制位移值和指定的马达系统响应,更新预设的基础电压信号,更进一步的,若线性电机在更新后的基础电压信号驱动下振子无法从位移原点处运动至限制位移处,则为基础电压信号增设若干段正负交替的启动电压,以使马达在增设启动电压后的基础电压信号驱动下,振子能够从位移原点处运动至限制位移处。可以看出,本实施例对基础电压信号是一种有方向性的推导更新,计算速度快且效率更高。与现有技术相比,马达在本实施例的驱动方式下,不仅启动快且可以使振子实现最大限制位移。To sum up, this embodiment updates the preset basic voltage signal through the preset limit displacement value and the specified motor system response. Furthermore, if the linear motor is driven by the updated basic voltage signal, the vibrator cannot be displaced from When the origin moves to the limit displacement, a number of alternating positive and negative start voltages are added to the basic voltage signal, so that the motor can move from the displacement origin to the limit displacement under the drive of the basic voltage signal after the start voltage is added. It can be seen that this embodiment is a directional derivation update for the basic voltage signal, and the calculation speed is fast and the efficiency is higher. Compared with the prior art, in the driving mode of this embodiment, the motor not only starts quickly but also enables the vibrator to achieve the maximum limit displacement.
基于同一发明构思,本发明实施例还提供了与上述马达振动位移的控制方法相对应的计算机存储介质和电子设备,由于本发明实施例中的计算机存储介质和电子设备解决问题的原理与本发明实施例1所述的马达振动位移的控制方法相似,因此其具体实施可以参见前述马达振动位移的控制方法的实施,重复之处不再赘述。Based on the same inventive concept, the embodiments of the present invention also provide computer storage media and electronic equipment corresponding to the above-mentioned method for controlling the vibration displacement of the motor. Because the computer storage medium and electronic equipment in the embodiments of the present invention solve the problem with the principle of the present invention The method for controlling the vibration displacement of the motor described in Embodiment 1 is similar. Therefore, the specific implementation can refer to the implementation of the aforementioned method for controlling the vibration displacement of the motor, and the repetition is not repeated here.
实施例Example 22
本实施例提供的计算机可读存储介质,所述计算机可读存储介质上存储有马达振动位移的控制程序,所述马达振动位移的控制程序被处理器运行时执行上述实施例1描述的马达振动位移的控制方法的步骤。具体实现可参见方法实施例1,在此不再赘述。The computer-readable storage medium provided in this embodiment has a motor vibration displacement control program stored on the computer-readable storage medium, and the motor vibration displacement control program is executed by the processor when the motor vibration displacement control program is executed by the above-mentioned embodiment 1. Steps of the displacement control method. For specific implementation, please refer to method embodiment 1, which will not be repeated here.
此外,请参阅图3,本实施例还提供了一种电子设备,所述电子设备包括处理器21、存储器22及马达振动位移的控制程序23,图3仅示出了所述电子设备的部分组件。 In addition, please refer to FIG. 3, this embodiment also provides an electronic device that includes a processor 21, a memory 22, and a motor vibration displacement control program 23. FIG. 3 only shows a part of the electronic device. Components.
所述存储器22在一些实施例中可以是所述电子设备的内部存储单元,例如电子设备的硬盘或内存。所述存储器22在另一些实施例中也可以是所述电子设备的外部存储设备,例如所述电子设备上配备的插接式硬盘,智能存储卡(Smart Media Card, SMC),安全数字(Secure Digital, SD)卡,闪存卡(Flash Card)等。进一步地,所述存储器22还可以既包括所述电子设备的内部存储单元也包括外部存储设备。所述存储器22用于存储安装于所述电子设备的应用软件及各类数据,例如所述安装电子设备的程序代码等。所述存储器22还可以用于暂时地存储已经输出或者将要输出的数据。在一实施例中,存储器22上存储有马达振动位移的控制程序23,该程序23可被处理器21所执行。In some embodiments, the memory 22 may be an internal storage unit of the electronic device, such as a hard disk or a memory of the electronic device. In other embodiments, the memory 22 may also be an external storage device of the electronic device, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), and a secure digital (Secure Digital) equipped on the electronic device. Digital, SD) card, flash card (Flash Card), etc. Further, the memory 22 may also include both an internal storage unit of the electronic device and an external storage device. The memory 22 is used to store application software and various data installed in the electronic device, such as the program code of the installed electronic device. The memory 22 can also be used to temporarily store data that has been output or will be output. In an embodiment, the memory 22 stores a control program 23 for the vibration displacement of the motor, and the program 23 can be executed by the processor 21.
所述处理器21在一些实施例中可以是一中央处理器(Central Processing Unit, CPU),微处理器或其他数据处理芯片,用于运行所述存储器22中存储的程序代码或处理数据。The processor 21 may be a central processing unit (Central Processing Unit) in some embodiments. Processing Unit (CPU), a microprocessor or other data processing chip, used to run the program code or processing data stored in the memory 22.
在本实施例中,当处理器21执行所述存储器22中存储的马达振动位移的控制程序23时执行上述实施例1描述的线性电机位移的控制方法的步骤。具体实现可参见方法实施例1,在此不再赘述。In this embodiment, when the processor 21 executes the motor vibration displacement control program 23 stored in the memory 22, the steps of the linear motor displacement control method described in the first embodiment are executed. For specific implementation, please refer to method embodiment 1, which will not be repeated here.
以上所述,仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应所述以权利要求的保护范围为准。The above are only specific embodiments of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed by the present invention. It should be covered within the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the protection scope of the claims.

Claims (9)

  1. 马达振动位移的控制方法,应用于一线性马达,以使所述线性马达的振子从位移原点处运动至限制位移处,其特征在于,所述马达振动位移的控制方法包括:The method for controlling the vibration displacement of a motor is applied to a linear motor so that the vibrator of the linear motor moves from the origin of the displacement to the position where the displacement is limited. The method is characterized in that the method for controlling the vibration displacement of the motor includes:
    S1、预先设置一限制位移值以及一基础电压信号;S1, preset a limit displacement value and a basic voltage signal;
    其中,所述限制位移值为位移原点处与限制位移处之间的直线距离值,所述基础电压信号的设置具体为设置电压幅值以及设置电压时长;Wherein, the limit displacement value is the linear distance value between the origin of the displacement and the limit displacement, and the setting of the basic voltage signal is specifically the setting of the voltage amplitude and the setting of the voltage duration;
    S2、根据一指定的马达系统响应以及所述限制位移值与基础电压信号,将所述基础电压信号的预设电压时长更新为实际电压时长,并获取所述振子的初始位移值;S2, according to a specified motor system response and the limit displacement value and the basic voltage signal, update the preset voltage duration of the basic voltage signal to the actual voltage duration, and obtain the initial displacement value of the vibrator;
    S3、判断所述振子的初始位移值是否等于0;S3: Determine whether the initial displacement value of the vibrator is equal to 0;
    若等于,则输出当前基础电压信号;If it is equal, output the current basic voltage signal;
    若不等于,则根据所述马达系统响应以及所述振子的初始位移值,为基础电压信号增设若干段正负交替的启动电压后,输出当前基础电压信号;If it is not equal, output the current basic voltage signal after adding several segments of alternating positive and negative starting voltages to the basic voltage signal according to the response of the motor system and the initial displacement value of the vibrator;
    S4、用当前基础电压信号驱动所述马达,实现振动位移;S4. Use the current basic voltage signal to drive the motor to realize vibration displacement;
    其中,所述马达系统响应为马达在驱动电压驱动下振子从位移原点处运动至位移终点处,且振子在位移原点处和位移终点处的速度均为0;所述马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值。Wherein, the response of the motor system is that the vibrator moves from the origin of the displacement to the end of the displacement under the driving voltage of the motor, and the speed of the vibrator at the origin of the displacement and the end of the displacement is 0; The driving voltage and a set displacement end point value are used to obtain the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator.
  2. 根据权利要求1所述的马达振动位移的控制方法,其特征在于,所述步骤S2包括:The method for controlling the vibration displacement of a motor according to claim 1, wherein the step S2 comprises:
    S21、在所述马达系统响应下,将所述限制位移值设置为位移终点值,并将所述基础电压信号设置为驱动电压;S21: In response to the motor system, the limit displacement value is set as a displacement end value, and the basic voltage signal is set as a driving voltage;
    S22、获取对应于所述基础电压信号的实际电压时长以及所述振子的初始位移值后,将所述基础电压信号的预设电压时长更新为实际电压时长。S22: After obtaining the actual voltage duration corresponding to the basic voltage signal and the initial displacement value of the vibrator, update the preset voltage duration of the basic voltage signal to the actual voltage duration.
  3. 根据权利要求1所述的马达振动位移的控制方法,其特征在于,所述步骤S3包括:The method for controlling vibration displacement of a motor according to claim 1, wherein the step S3 comprises:
    S31、若所述振子的初始位移值不等于0,则设置第一段启动电压;其中,启动电压的设置具体为设置电压幅值以及设置电压时长,所述第一段启动电压的电压幅值与所述基础电压信号的电压幅值方向相反;S31. If the initial displacement value of the vibrator is not equal to 0, set the first-stage start voltage; where the setting of the start-up voltage specifically includes setting the voltage amplitude and setting the voltage duration, and the voltage amplitude of the first-stage start voltage Opposite to the voltage amplitude direction of the basic voltage signal;
    S32、在所述马达系统响应下,将所述振子的初始位移值设置为位移终点值,并将所述第一段启动电压设置为驱动电压;S32. In response to the motor system, the initial displacement value of the vibrator is set as a displacement end value, and the first segment start voltage is set as a driving voltage;
    S33、获取对应于所述第一段启动电压的实际电压时长以及所述振子的当前初始位移值后,将所述第一段启动电压的预设电压时长更新为实际电压时长。S33. After obtaining the actual voltage duration corresponding to the first segment of the startup voltage and the current initial displacement value of the vibrator, update the preset voltage duration of the first segment of the startup voltage to the actual voltage duration.
  4. 根据权利要求3所述的马达振动位移的控制方法,其特征在于,所述步骤S3还包括:The method for controlling vibration displacement of a motor according to claim 3, wherein the step S3 further comprises:
    S34、若所述振子的当前初始位移值等于0,则为当前基础电压信号增设所述第一段启动电压,输出当前基础电压信号后执行步骤S4。S34. If the current initial displacement value of the vibrator is equal to 0, add the first-stage start voltage to the current basic voltage signal, and perform step S4 after outputting the current basic voltage signal.
  5. 根据权利要求3所述的马达振动位移的控制方法,其特征在于,所述步骤S3还包括:The method for controlling vibration displacement of a motor according to claim 3, wherein the step S3 further comprises:
    S35、若所述振子的当前初始位移值不等于0,则设置下一段启动电压;其中,所述下一段启动电压的电压幅值与当前启动电压的电压幅值方向相反;S35. If the current initial displacement value of the vibrator is not equal to 0, set the start voltage of the next segment; wherein the voltage amplitude of the next segment of the start voltage is opposite to the voltage amplitude of the current start voltage;
    S36、在所述马达系统响应下,将所述振子的当前初始位移值设置为位移终点值,并将所述下一段启动电压设置为驱动电压;S36. In response to the motor system, set the current initial displacement value of the vibrator as a displacement end value, and set the next-stage start voltage as a driving voltage;
    S37、获取对应于所述下一段启动电压的实际电压时长以及下一次振子的初始位移值后,将所述下一段启动电压的预设电压时长更新为实际电压时长;S37: After obtaining the actual voltage duration corresponding to the next segment of the startup voltage and the initial displacement value of the next vibrator, update the preset voltage duration of the next segment of the startup voltage to the actual voltage duration;
    S38、判断所述下一次振子的初始位移值是否等于0;S38: Determine whether the initial displacement value of the vibrator is equal to 0 for the next time;
    若不等于,则返回步骤S35;If it is not equal, return to step S35;
    若等于,则为当前基础电压信号依次增设所有启动电压后,输出当前基础电压信号。If it is equal, the current basic voltage signal is output after all starting voltages are sequentially added to the current basic voltage signal.
  6. 根据权利要求1所述的马达振动位移的控制方法,其特征在于,所述马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值,具体为:The method for controlling vibration displacement of a motor according to claim 1, wherein the motor system responds to obtain the actual voltage duration corresponding to the driving voltage and the vibrator according to a driving voltage and a set displacement end value. The initial displacement value of is specifically:
    将所述驱动电压以及设置的位移终点值输入至马达虚拟模型中,在所述马达系统响应下,计算出对应于所述驱动电压的实际电压时长和振子的初始位移值;Input the driving voltage and the set displacement end point value into the virtual motor model, and in response to the motor system, calculate the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator;
    其中,所述马达虚拟模型对应于所述马达。Wherein, the virtual model of the motor corresponds to the motor.
  7. 根据权利要求1所述的马达振动位移的控制方法,其特征在于,所述马达系统响应用于根据一驱动电压以及一设置的位移终点值,获取对应于所述驱动电压的实际电压时长以及振子的初始位移值,具体为:The method for controlling vibration displacement of a motor according to claim 1, wherein the motor system responds to obtain the actual voltage duration corresponding to the driving voltage and the vibrator according to a driving voltage and a set displacement end value. The initial displacement value of is specifically:
    A、将当前初始位移值设置为0;A. Set the current initial displacement value to 0;
    B、用当前驱动电压驱动马达虚拟系统后,判断振子在起始时刻的速度响应是否等于0;B. After driving the virtual system of the motor with the current driving voltage, judge whether the speed response of the vibrator at the initial moment is equal to 0;
    若不等于,则修正当前驱动电压的电压时长后,重新执行本步骤;If it is not equal, after correcting the voltage duration of the current driving voltage, perform this step again;
    若等于,则执行步骤C;If it is equal, go to step C;
    C、判断振子的位移响应是否等于所述设置的位移终点值;C. Determine whether the displacement response of the vibrator is equal to the set displacement end value;
    若不等于,则修正当前初始位移值后,返回步骤B;If it is not equal, after correcting the current initial displacement value, return to step B;
    若等于,则输出对应于所述驱动电压的实际电压时长和振子的初始位移值。If it is equal, output the actual voltage duration corresponding to the driving voltage and the initial displacement value of the vibrator.
  8. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质上存储有马达振动位移的控制程序,所述马达振动位移的控制程序被处理器运行时执行如权利要求1-7任一项所述的马达振动位移的控制方法的步骤。A computer-readable storage medium, characterized in that a motor vibration displacement control program is stored on the computer-readable storage medium, and the motor vibration displacement control program is executed by a processor as in any of claims 1-7. One of the steps of the control method of motor vibration displacement.
  9. 一种电子设备,其特征在于,所述电子设备包括存储器、处理器以及存储在所述存储器上并可在所述处理器上运行的马达振动位移的控制程序,所述马达振动位移的控制程序被所述处理器执行时实现如权利要求1-7任一项所述的马达振动位移的控制方法的步骤。An electronic device, characterized in that the electronic device includes a memory, a processor, and a motor vibration displacement control program stored in the memory and running on the processor, and the motor vibration displacement control program When executed by the processor, the steps of the method for controlling the vibration displacement of the motor according to any one of claims 1-7 are realized.
PCT/CN2019/129416 2019-12-27 2019-12-27 Motor vibration displacement control method, storage medium, and electronic device WO2021128338A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2019/129416 WO2021128338A1 (en) 2019-12-27 2019-12-27 Motor vibration displacement control method, storage medium, and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2019/129416 WO2021128338A1 (en) 2019-12-27 2019-12-27 Motor vibration displacement control method, storage medium, and electronic device

Publications (1)

Publication Number Publication Date
WO2021128338A1 true WO2021128338A1 (en) 2021-07-01

Family

ID=76575085

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/129416 WO2021128338A1 (en) 2019-12-27 2019-12-27 Motor vibration displacement control method, storage medium, and electronic device

Country Status (1)

Country Link
WO (1) WO2021128338A1 (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0965634A (en) * 1995-08-28 1997-03-07 Matsushita Electric Works Ltd Controller for linear vibrating motor
WO2006122307A2 (en) * 2005-05-10 2006-11-16 Newport Corporation Apparatus and methods for estimation of initial phase of a brushless motor
CN106100494A (en) * 2016-05-20 2016-11-09 瑞声科技(新加坡)有限公司 The drive system of linear electric machine and driving method thereof
CN106301137A (en) * 2016-08-31 2017-01-04 歌尔股份有限公司 Actively control the method for linear motor vibrations, device, system and electronic equipment
CN106461727A (en) * 2016-10-31 2017-02-22 北京小米移动软件有限公司 Method and device for controlling motor vibration, and electronic device
CN108415556A (en) * 2018-01-29 2018-08-17 瑞声科技(新加坡)有限公司 Motor vibrations control method and device
CN109217617A (en) * 2018-08-09 2019-01-15 瑞声科技(新加坡)有限公司 A kind of the pumping signal searching method and electronic equipment of motor
CN109742998A (en) * 2018-12-24 2019-05-10 维沃移动通信有限公司 Vibration component, motor control method and terminal
CN110058679A (en) * 2018-12-29 2019-07-26 瑞声科技(新加坡)有限公司 A kind of the pumping signal searching method and electronic equipment of motor

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0965634A (en) * 1995-08-28 1997-03-07 Matsushita Electric Works Ltd Controller for linear vibrating motor
WO2006122307A2 (en) * 2005-05-10 2006-11-16 Newport Corporation Apparatus and methods for estimation of initial phase of a brushless motor
CN106100494A (en) * 2016-05-20 2016-11-09 瑞声科技(新加坡)有限公司 The drive system of linear electric machine and driving method thereof
CN106301137A (en) * 2016-08-31 2017-01-04 歌尔股份有限公司 Actively control the method for linear motor vibrations, device, system and electronic equipment
CN106461727A (en) * 2016-10-31 2017-02-22 北京小米移动软件有限公司 Method and device for controlling motor vibration, and electronic device
CN108415556A (en) * 2018-01-29 2018-08-17 瑞声科技(新加坡)有限公司 Motor vibrations control method and device
CN109217617A (en) * 2018-08-09 2019-01-15 瑞声科技(新加坡)有限公司 A kind of the pumping signal searching method and electronic equipment of motor
CN109742998A (en) * 2018-12-24 2019-05-10 维沃移动通信有限公司 Vibration component, motor control method and terminal
CN110058679A (en) * 2018-12-29 2019-07-26 瑞声科技(新加坡)有限公司 A kind of the pumping signal searching method and electronic equipment of motor

Similar Documents

Publication Publication Date Title
US10613635B2 (en) Method and apparatus for generating motor brake signal
WO2016123991A1 (en) Shift register and drive method therefor, grid drive circuit and display device
WO2022134219A1 (en) Motor vibration signal generation method and apparatus, computer device, and storage medium
US9699382B2 (en) Optical image stabilizer and method of decreasing power consumption
US11876474B2 (en) Linear resonant device, and braking method for same
TW202023176A (en) A method, a system and a device for calibrating a frequency of a driving voltage waveform for a linear resonance device
US20050071570A1 (en) Prefetch controller for controlling retrieval of data from a data storage device
WO2021042637A1 (en) Method, apparatus and system for controlling stepping motor, and storage medium
JP6301466B2 (en) DC brushless motor, apparatus and method for controlling pulse width modulation of a system
TW202025642A (en) Apparatus and method for offset optimization for low-density parity-check code
WO2021128338A1 (en) Motor vibration displacement control method, storage medium, and electronic device
JP2015133878A (en) Motor control device and motor control method
CN111555690B (en) Method for controlling vibration displacement of motor, storage medium, and electronic apparatus
JP2020042591A (en) Information processing apparatus and information processing method
CN111510137A (en) Clock circuit, computing chip, computing board and digital currency mining machine
CN101369800A (en) Motor control apparatus
US20140129851A1 (en) Voltage identification definition reference voltage generation circuit and boot voltage generating method thereof
JPS60263220A (en) Clock signal generation circuit
JP2003150283A (en) Power controller and power control method
JP2020064283A (en) Lens drive device, lens drive method, and program
CN113162597B (en) Dual-mode clustered oscillation piecewise linear memristor system
US10965540B2 (en) Balancing distances between nodes on a token ring
TWI683525B (en) Motor driving circuit and motor driving method
WO2017090078A1 (en) Embedded device, communication method, and communication program
WO2021134326A1 (en) Drive signal acquisition method for motor of touch display apparatus, and terminal device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19957453

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19957453

Country of ref document: EP

Kind code of ref document: A1