Motor sound generation method, vehicle, computer program product and storage medium
By acquiring the audio sample signal and determining the control signal of the motor based on it, the problem of low sound quality of the motor in the prior art is solved, and a higher quality audio signal reproduction is achieved.
Patent Information
- Application Number
- CN202411211814.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-30
- Publication Date
- 2025-03-21
- Estimated Expiration
- 2044-08-30
AI Technical Summary
In the prior art, when the motor is used to simulate the sound waves of an internal combustion engine, the sound quality is low and high-quality audio signals cannot be effectively reproduced.
By acquiring the audio sampled signal, the audio injection signal is determined, including the voltage vector and/or current vector under the coordinate system of the motor's target vector, and the control signal of the motor is adjusted according to these signals to achieve higher quality sounding.
The quality of the motor sound is improved, so that the audio signal can be reproduced accurately, and the control accuracy of the sound volume and tone are improved.
Smart Images

Figure CN118713524B_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of vehicle technology, and in particular, relates to a motor sound generation method, a vehicle, a computer program product, and a storage medium. Background Art
[0002] New energy vehicles are driven by electric drive systems. Compared with fuel engines, the motor drive makes the vehicle environment quieter during driving and the noise inside the vehicle is also reduced accordingly.
[0003] In the related art, the corresponding alternating current is injected into the automobile motor to make the motor simulate the sound of the internal combustion engine to increase the driving pleasure. However, since the motor is not specially designed for sound reproduction, the quality of the sound produced by the motor is low. Summary of the invention
[0004] The present application aims to solve at least one of the technical problems existing in the prior art. To this end, the present application proposes a motor sound generation method, a vehicle, a computer program product and a storage medium, which can improve the sound generation quality of the motor.
[0005] In a first aspect, the present application provides a method for producing sound of a motor, comprising:
[0006] Acquire an audio sampling signal, where the audio sampling signal is obtained by sampling the audio data;
[0007] Determine an audio injection signal according to the audio sampling signal, wherein the audio injection signal includes a voltage vector and / or a current vector in a target vector coordinate system of the motor;
[0008] Determine a control signal for the motor to generate sound according to the audio injection signal;
[0009] The motor is controlled according to the control signal so that the motor produces sound.
[0010] According to an embodiment of the present application, determining a control signal of a motor according to the audio injection signal includes:
[0011] The duty cycle of the control signal of the motor is adjusted according to the audio injection signal.
[0012] According to one embodiment of the present application, it also includes:
[0013] The duty cycle of the control signal of the excitation bridge arm of the motor is adjusted according to the audio sampling signal.
[0014] According to an embodiment of the present application, the step of adjusting the duty cycle of the control signal of the excitation bridge arm of the motor according to the audio sampling signal includes:
[0015] Determine the excitation current of the motor magnetic field according to the audio sampling signal;
[0016] Obtaining an excitation voltage corresponding to the excitation current;
[0017] The duty cycle of the control signal of the excitation bridge arm of the motor is adjusted according to the excitation voltage.
[0018] According to an embodiment of the present application, determining the excitation current of the motor magnetic field according to the audio sampling signal includes:
[0019] Obtaining a per-unit value corresponding to the audio sampling signal;
[0020] The excitation current of the motor magnetic field is determined according to the excitation current peak value, the excitation current offset and the per-unit value of the motor magnetic field.
[0021] According to an embodiment of the present application, adjusting the duty cycle of the control signal of the motor according to the audio injection signal includes:
[0022] determining a phase voltage of a motor according to the audio injection signal;
[0023] The duty cycle of the control signal of the phase bridge arm of the motor is adjusted according to the phase voltage.
[0024] According to an embodiment of the present application, determining the phase voltage of the motor according to the audio injection signal includes:
[0025] Obtaining a phase sampling current of the motor;
[0026] The phase voltage of the motor is determined according to the phase sampling current and the audio injection signal.
[0027] According to an embodiment of the present application, the step of adjusting the duty cycle of the control signal of the phase bridge arm of the motor according to the phase voltage includes:
[0028] At the moment when the extreme value point of the carrier signal is located, the duty cycle of the control signal of the phase bridge arm of the motor is adjusted according to the phase voltage.
[0029] According to an embodiment of the present application, at the moment when the extreme value point of the carrier signal is located, adjusting the duty cycle of the control signal of the phase bridge arm of the motor according to the phase voltage includes:
[0030] At time t1 of the carrier signal, adjusting the duty cycle of the control signal of the phase bridge arm of the motor according to the phase voltage;
[0031] Among them, t1 is the extreme point, and 0<t1-tm<Ts, Ts is the carrier period, and tm is the time when this sampling is completed.
[0032] According to an embodiment of the present application, determining the phase voltage of the motor according to the audio injection signal further includes:
[0033] Determine the motor's torque output command, motor speed, battery voltage, and phase sampling current;
[0034] Determine a given current vector according to the torque output command, the motor speed and the battery voltage, wherein the given current vector is a current vector in a first-order rotating coordinate system;
[0035] Determining the phase voltage of the motor according to the phase sampling current and the audio injection signal includes: determining the phase voltage of the motor according to the given current vector, the phase sampling current and the audio injection signal.
[0036] According to an embodiment of the present application, determining the phase voltage of the motor according to the phase sampling current and the audio injection signal includes:
[0037] Acquire a first phase current vector corresponding to the phase sampling current, where the first phase current vector is a current vector in a stationary coordinate system;
[0038] A phase voltage of the motor is determined based on the audio injection signal and the first phase current vector.
[0039] According to one embodiment of the present application, when the audio injection signal includes a voltage vector in a stationary coordinate system or a voltage vector in an m-order rotating coordinate system, m is a real number that is not 1, and determining the phase voltage of the motor according to the audio injection signal and the first phase current vector includes:
[0040] Acquire a second phase current vector corresponding to the phase sampling current, where the second phase current vector is a current vector in a first-order rotating coordinate system;
[0041] determining a target voltage vector according to the second phase current vector, wherein the target voltage vector is a voltage vector in the stationary coordinate system;
[0042] A phase voltage of the motor is determined according to the audio injection signal and the target voltage vector.
[0043] According to one embodiment of the present application, when the audio injection signal includes a voltage vector and / or a current vector in a first-order rotating coordinate system, determining the phase voltage of the motor according to the audio injection signal and the first phase current vector includes:
[0044] Acquire a second phase current vector corresponding to the phase sampling current, where the second phase current vector is a current vector in a first-order rotating coordinate system;
[0045] determining a target voltage vector according to the second phase current vector and the audio injection signal, wherein the target voltage vector is a voltage vector in the stationary coordinate system;
[0046] A phase voltage of the motor is determined according to the target voltage vector.
[0047] According to one embodiment of the present application, when the audio injection signal includes a current vector in an m-order rotating coordinate system, m is a real number that is not 1, and determining the phase voltage of the motor according to the audio injection signal and the first phase current vector includes:
[0048] Acquire a second phase current vector and a third phase current vector corresponding to the phase sampling current, wherein the second phase current vector is a current vector in a first-order rotating coordinate system, and the third phase current vector is a current vector in an m-order rotating coordinate system;
[0049] Determine a target voltage vector according to the second phase current vector, the third phase current vector and the audio injection signal, wherein the target voltage vector is a voltage vector in the stationary coordinate system;
[0050] A phase voltage of the motor is determined according to the target voltage vector.
[0051] According to an embodiment of the present application, determining the audio injection signal according to the audio sampling signal includes:
[0052] Acquire an amplitude signal corresponding to the audio sampling signal;
[0053] An audio injection signal is determined according to the amplitude signal, the injection angle and the target vector coordinate system of the motor, wherein the injection angle is determined according to the electrical angle of the motor rotor.
[0054] According to an embodiment of the present application, the acquiring the amplitude signal corresponding to the audio sampling signal includes:
[0055] Obtaining a per-unit value corresponding to the audio sampling signal;
[0056] An amplitude signal is obtained according to the per-unit value and a maximum current amplitude and / or a maximum voltage amplitude used by the motor controller to respond to the sound.
[0057] According to one embodiment of the present application, when the target vector coordinate system includes a stationary coordinate system, the amplitude signal includes a voltage, and determining the audio injection signal according to the amplitude signal, the injection angle, and the target vector coordinate system of the motor includes:
[0058] According to the injection angle, the vectors of each coordinate axis of the amplitude signal in the stationary coordinate system are obtained to obtain the audio injection signal.
[0059] According to one embodiment of the present application, when the target vector coordinate system includes a rotating coordinate system, the amplitude signal includes voltage and / or current, and determining the audio injection signal according to the amplitude signal, the injection angle and the target vector coordinate system of the motor includes:
[0060] According to the injection angle, the vectors of each coordinate axis of the amplitude signal in the rotating coordinate system of order n are obtained to obtain an audio injection signal, where n is a real number.
[0061] According to one embodiment of the present application, when the target vector coordinate system includes a rotating coordinate system, the amplitude signal includes voltage and / or current, and determining the audio injection signal according to the amplitude signal, the injection angle and the target vector coordinate system of the motor includes:
[0062] According to the injection angle, vectors of each coordinate axis of the amplitude signal in a first-order coordinate system and a second-order coordinate system are obtained to obtain an audio injection signal, wherein the first-order coordinate system and the second-order coordinate system are rotating coordinate systems of different orders.
[0063] According to one embodiment of the present application, the method further includes:
[0064] In one carrier cycle, the audio data is sampled multiple times to obtain the audio sampling signal.
[0065] According to an embodiment of the present application, the audio data is sampled multiple times within one carrier cycle, including:
[0066] In one carrier cycle, the audio data is sampled at the time when multiple extreme points of the carrier signal are located.
[0067] In a second aspect, the present application provides a vehicle, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method for producing sound of a motor as described in any one of the above items when executing the computer program.
[0068] In a third aspect, the present application provides a non-transitory computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method for producing sound of a motor as described in any one of the above items.
[0069] In a fourth aspect, the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the method for producing sound of a motor as described in any one of the above items.
[0070] The motor sound generation method, vehicle, computer program product and storage medium provided in the embodiments of the present application are achieved by acquiring an audio sampling signal, which is obtained by sampling audio data; determining an audio injection signal based on the audio sampling signal, the audio injection signal including a voltage vector and / or a current vector in a target vector coordinate system of the motor; determining a control signal for the motor sound generation based on the audio injection signal; and controlling the motor based on the control signal to make the motor sound, that is, converting the audio sampling signal based on the target vector coordinate system of the motor, and determining the control signal of the motor based on the conversion signal, thereby achieving control of the vibration amplitude and frequency of the motor based on the audio signal, and further controlling the volume and pitch of the motor sound, so that the audio signal is accurately reproduced, thereby improving the quality of the motor sound.
[0071] Additional aspects and advantages of the present application will be given in part in the description below, and in part will become apparent from the description below, or will be learned through the practice of the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0072] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0073] Figure 1 It is a flow chart of a method for producing sound of a motor provided in an embodiment of the present application;
[0074] Figure 2 is a schematic diagram of a music file parsing process provided by an embodiment of the present application;
[0075] Figure 3 It is one of the schematic diagrams of the sampling channel in the vehicle provided in the embodiment of the present application;
[0076] Figure 4 This is the second schematic diagram of the sampling channel in the vehicle provided in the embodiment of the present application;
[0077] Figure 5 It is one of the schematic diagrams of coordinate transformation when the amplitude signal provided in the embodiment of the present application is current;
[0078] Figure 6It is one of the schematic diagrams of coordinate transformation when the amplitude signal provided in the embodiment of the present application is a voltage;
[0079] Figure 7 It is a schematic diagram of adjusting the duty cycle by transferring the voltage in the amplitude signal to a rotating coordinate system of -5th order and 7th order provided by an embodiment of the present application;
[0080] Figure 8 It is a schematic diagram of adjusting the duty cycle by transferring the current and voltage in the amplitude signal to a first-order rotating coordinate system provided by an embodiment of the present application;
[0081] Fig. 9 It is a schematic diagram of adjusting the duty cycle by transferring the current in the amplitude signal to a first-order rotating coordinate system provided by an embodiment of the present application;
[0082] Fig.10 It is a schematic diagram of adjusting the duty cycle by transferring the voltage in the amplitude signal to a first-order rotating coordinate system provided by an embodiment of the present application;
[0083] Fig.11 It is a schematic diagram of adjusting the duty cycle by transferring the current in the amplitude signal to a rotating coordinate system of -5th order and 7th order provided by an embodiment of the present application;
[0084] Fig.12 It is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0085] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.
[0086] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.
[0087] The current development of new energy vehicles is moving from single visual interaction to multi-sensory interaction such as sight and hearing, and from in-car interaction to out-car interaction. However, many companies' current models do not yet have out-car auditory interaction functions.
[0088] In the off-vehicle auditory interaction, the motor sound generation method, vehicle, computer program product and storage medium provided in the embodiments of the present application can be used to fill the functional gaps. The advantage is that the motor is the "heart" of the new energy vehicle, and the sound it produces is the most authentic sound from the heart of the electric vehicle, which best represents the voice of the car man. It can generate low-speed sound, sound waves, anthropomorphic voices, music, background sounds of nature and other stereo surround sounds outside the vehicle. It can be applied to vehicle status prompts, off-vehicle voice interaction, off-vehicle media entertainment and other scenarios, which can give the new energy vehicle a soul while improving vehicle safety, interaction convenience and fun, and create a warm smart car man.
[0089] The following, in conjunction with the accompanying drawings, describes in detail the motor sound generation method, vehicle, storage medium and computer program product provided in the embodiments of the present application through specific embodiments and their application scenarios.
[0090] Among them, the sound generation method of the motor can be applied to the terminal, and can be specifically executed by hardware or software in the terminal.
[0091] The terminal includes, but is not limited to, a portable communication device such as a mobile phone or a tablet computer having a touch-sensitive surface (e.g., a touch screen display and / or a touch pad). It should also be understood that in some embodiments, the terminal may not be a portable communication device, but a desktop computer having a touch-sensitive surface (e.g., a touch screen display and / or a touch pad).
[0092] In the following various embodiments, a terminal including a display and a touch-sensitive surface is described. However, it should be understood that the terminal may include one or more other physical user interface devices such as a physical keyboard, a mouse and a joystick.
[0093] The motor sound production method provided in the embodiment of the present application may be executed by an electronic device or a functional module or functional entity in the electronic device that can implement the motor sound production method. The electronic device mentioned in the embodiment of the present application may include but is not limited to an ECU (Electronic Control Unit), an MCU (Microcontroller Unit) or other controllers. The motor sound production method provided in the embodiment of the present application is described below using an electronic device as an example of the execution subject.
[0094] like Figure 1 As shown, Figure 11 is a flow chart of a method for producing sound of a motor provided in an embodiment of the present application. The motor may be an electric motor, an asynchronous motor, an electrically excited motor, or other types of motors. The motor may be used in new energy vehicles, or in other fields, such as household appliances, electric bicycles, power-assisted bicycles, and the like.
[0095] The sound generation method of the motor includes: steps 110 to 140.
[0096] Step 110: Acquire an audio sampling signal, where the audio sampling signal is obtained by sampling the audio data;
[0097] Step 120: determining an audio injection signal according to the audio sampling signal, where the audio injection signal includes a voltage vector and / or a current vector in a target vector coordinate system of the motor;
[0098] Step 130, determining a control signal for the motor to generate sound according to the audio injection signal;
[0099] Step 140: Control the motor according to the control signal to make the motor produce sound.
[0100] According to the method for producing sound of a motor in an embodiment of the present application, an audio sampling signal is obtained, and an audio injection signal is determined based on the audio sampling signal, the audio injection signal includes a voltage vector and / or a current vector in a target vector coordinate system of the motor; a control signal for producing sound of the motor is determined based on the audio injection signal, and the motor is controlled based on the control signal; that is, the audio sampling signal is converted based on the target vector coordinate system of the motor, and the control signal of the motor is determined based on the conversion signal, so that the vibration amplitude and frequency of the motor can be controlled based on the audio signal, and then the volume and tone of the sound produced by the motor can be controlled, so that the audio signal is accurately reproduced, thereby improving the quality of the sound produced by the motor.
[0101] The above steps 110 to 140 will be described in detail below.
[0102] Step 110: Acquire an audio sampling signal, where the audio sampling signal is obtained by sampling the audio data.
[0103] In the embodiment of the present application, the audio data includes information such as the frequency, amplitude and waveform of the sound, and the audio data can be an analog signal or a digital signal, and can also be various audio files. For example, the audio data includes but is not limited to: files in various music formats such as mp3, wma, wav, flac, ape, MIDI files, song files transmitted by Bluetooth, PCM encoded files, digital signals processed by music chips, analog signals processed by chips, analog signals amplified by power amplifiers, analog signals input by microphones, or digital signals corresponding to music files, etc.
[0104] Specifically, for audio data from different sources, sampling channels that match the signal source can be used for sampling, so that the sampling process can adapt to the characteristics of signals from different sources, more accurately capture the details of the audio signal, reduce distortion and noise interference, and thus obtain clearer audio recordings.
[0105] In some embodiments, the sampling channel includes at least one of the following:
[0106] Obtain the analog signal input to the speaker and sample the analog signal through the ADC sampling port;
[0107] Obtain the I2S signal of the port of the in-vehicle entertainment system and sample the I2S signal;
[0108] Obtain the A2B signal of the port of the in-vehicle entertainment system, convert the A2B signal into an I2S signal, and then sample the I2S signal;
[0109] Acquire data packets on the Ethernet in the vehicle, parse the data packets, and then sample the parsed data.
[0110] Among them, the in-vehicle entertainment system is an in-vehicle electronic device that integrates multiple functions and is mainly used to enhance the driving and riding experience. The in-vehicle entertainment system makes the journey more comfortable and enjoyable by providing audio, video, navigation, communication and other entertainment functions. The in-vehicle entertainment system host assembly and various ports, such as USB ports, HDMI ports, RCA ports, Bluetooth ports, etc., can be connected to other devices, such as audio, power amplifier equipment, etc.
[0111] The data packet may include various music files, which need to be decoded and extracted through mono separation to obtain parsed data. Figure 2 As shown, Figure 2 : This is a schematic diagram of the music file parsing process provided by the embodiment of the present application. For music files of different formats, they can be decoded according to the encoding rules of the corresponding music files, the decoded data can be separated into channels to obtain a mono audio signal, the sampling points can be discretized or the sampling frequency can be interpolated and reduced according to the playback frequency to obtain the amplitude of the corresponding audio signal sampling point. For example, MP3 and other files have a sampling rate of 44.1kHz, and the variable of the amplitude of each point at the sampling frequency is obtained according to the 44.1kHz sampling rate, which is finally converted into a digital signal.
[0112] like Figure 3 As shown, Figure 3 This is one of the schematic diagrams of the sampling channel in the vehicle provided by the embodiment of the present application. When the motor is the driving motor of the vehicle, the host assembly of the in-vehicle entertainment system can be debugged, the corresponding audio data can be collected from the host audio line, and the data output by the multimedia entertainment system can be converted into a digital signal that can be recognized by the motor controller.
[0113] In one embodiment, Figure 3 As shown in Solution 1, the analog signal output by the power amplifier or other equipment in the vehicle to the audio system can be connected to the ADC sampling port of the MCU. The MCU performs ADC sampling and converts the power amplifier analog signal into a digital signal by debugging the underlying driving function of the electric drive system.
[0114] In one embodiment, Figure 3 As shown in the second solution, the I2S signal of the port of the external power amplifier device in the vehicle or the port of the host assembly can be obtained, and the I2S signal on the host assembly can be converted into a digital signal by debugging the corresponding underlying driver function on the electric drive system. The converted digital signal can be sent to other MCU units through the CANFD bus for further processing, such as the MCU in the motor controller.
[0115] In one embodiment, Figure 3 As shown in the third solution, the A2B signal of the port of the external power amplifier device in the vehicle can be obtained, and by debugging the underlying drive function of the corresponding electric drive system, the A2B signal can be converted into an I2S signal and then converted into a digital signal that can be recognized by the drive motor controller. The converted digital signal can be sent to other MCUs through the CANFD bus for further processing, such as the MCU in the motor controller.
[0116] In one embodiment, the fourth embodiment Figure 4 As shown, Figure 4 This is the second schematic diagram of the sampling channel in the vehicle provided by the embodiment of the present application. The data packet on the Ethernet in the vehicle environment can be obtained, and by debugging the underlying driving function of the corresponding electric drive system, the data packet can be converted into a digital signal recognizable by the drive motor controller. The converted digital signal can be sent to other MCUs through the CANFD bus for further processing, such as the MCU in the motor controller.
[0117] Solution 1 can capture the signal directly related to the final audio output by sampling the analog signal output from the power amplifier to the audio in the vehicle environment. This sampling method can improve the accuracy and integrity of the audio data. Solution 2 can reduce the noise and distortion that may be introduced in the signal conversion process by sampling the I2S digital signal in the vehicle environment. Solution 3 samples the A2B signal and converts it into an I2S signal. The A2B bus is a high-bandwidth, bidirectional, digital audio bus for vehicles. It adopts a daisy chain structure with a single node distance of up to 15m, which can reduce the complexity of wiring. A2B can realize long-distance I2S and reduce the noise and distortion that may be introduced in the signal conversion process. The A2B bus is very suitable for long-distance synchronous audio signal transmission of the front and rear electric drives of the whole vehicle. Solution 4 transmits audio to the front and rear electric drive assemblies through the Ethernet bus. The advantage is that the amount of data transmitted is large and fast, which can shorten the upgrade time of the electric drive program, and is used for big data calibration and analysis to improve the user experience. It takes advantage of the Ethernet to transmit audio data, which can reduce the complexity of wiring and enable audio data to be flexibly transmitted in the vehicle's internal network.
[0118] In some embodiments, the drive system of an electric vehicle is designed in various ways and can be configured with a single motor or multiple motors. A single motor is simple to configure and relatively low in cost, and is suitable for small or economical electric vehicles. The motor is usually installed on the rear axle or front axle of the vehicle to provide direct driving force. The multi-motor configuration is more complex, usually including a rear-drive motor and a front-drive motor. The rear-drive motor is mainly responsible for driving the rear wheels of the vehicle, providing the main thrust and acceleration performance; the front-drive motor is responsible for driving the front wheels to enhance the traction and stability of the vehicle.
[0119] In some embodiments, the method for generating sound of a motor further includes:
[0120] In one carrier cycle, the audio data is sampled multiple times to obtain an audio sampling signal.
[0121] The carrier period refers to the time required for the carrier signal to complete a complete change from zero to the maximum value and then back to zero in a pulse width modulation (PWM) signal. The carrier signal is usually a continuous waveform, such as a sine wave, triangle wave, or square wave, which is used to modulate the duty cycle of the output signal.
[0122] Specifically, within a carrier cycle Ts, the acquired audio data can be sampled at different time points to obtain an audio sampling signal. By sampling the audio data multiple times within each carrier cycle, more sampling points are collected to capture subtle changes in the audio signal, and the sampling frequency is increased to improve the restoration of the audio signal and the quality of the motor sound.
[0123] In some embodiments, the above step of “sampling the audio data multiple times within one carrier cycle” specifically includes:
[0124] In one carrier cycle, the audio data is sampled at the time when multiple extreme points of the carrier signal are located.
[0125] Among them, the extreme points include peaks and / or troughs. For a three-phase synchronous motor, the extreme points of the carrier in each carrier cycle may include a peak and a trough, including a total of 2 extreme points. Within a carrier cycle Ts, if sampling is only performed at the peaks and troughs, two samplings can be performed. For three-phase bridge arm uniformly staggered phase motor control, within each carrier cycle, the carrier signal of each bridge arm includes a peak and a trough, and the phase bridge arm includes a total of 6 extreme points. If sampling is only performed at the peaks and troughs, six samplings can be performed.
[0126] The extreme points of the carrier signal represent the highest and lowest points of the control signal in each cycle. The extreme points of the carrier signal are also the points where the comparison value of each bridge arm register is updated, that is, the points where the duty cycle can be updated. By sampling at these extreme points, the changes in the audio signal can be captured in a timely manner, and further processed in a timely manner to become the duty cycle of the motor control signal. Timely updating of the duty cycle reduces the noise and stress caused by control delays. Sampling at the extreme points is synchronized with the natural beat of the control signal, which helps to maintain the time consistency between the audio signal and the motor control signal, so that the sound signal output by the motor closely follows the changes in the original audio signal.
[0127] Step 120 : determining an audio injection signal according to the audio sampling signal, where the audio injection signal includes a voltage vector and / or a current vector in a target vector coordinate system of the motor.
[0128] In an embodiment of the present application, the target vector coordinate system is a mathematical model for describing the state of the motor magnetic field. The target vector coordinate system can be a rotating coordinate system (i.e., a dq axis rotating coordinate system, hereinafter referred to as the dq coordinate system), or a stationary coordinate system (i.e., an α-β coordinate system). Specifically, a field vector control (FOC) system based on rotor flux orientation (RFO) can be established. FOC is an advanced motor control strategy. FOC usually uses rotor flux orientation and regards the control of the motor as two orthogonal components that can be adjusted independently.
[0129] The dq coordinate system decomposes the motor's magnetic field into two orthogonal components, one related to the motor's rotation direction (d-axis) and the other perpendicular to the motor's rotation direction (q-axis). The α-β coordinate system decomposes the motor's magnetic field into two stationary components, the α component and the β component. In this way, the motor's control can be simplified to two independent components, thereby simplifying the control algorithm.
[0130] In an embodiment of the present application, for the audio sampling signal, it is necessary to convert the audio sampling signal to obtain the amplitude dimension corresponding to the motor controller, and map it to the target vector coordinate system to obtain the audio injection signal. The amplitude dimension can be current, voltage, or current and voltage. If the audio sampling signal is converted into current or voltage, the process of controlling the motor to make sound is relatively simple. If the audio sampling signal is converted into voltage and current, the bandwidth of the audio response can be improved, higher sound frequencies can be responded to, and the sound restoration degree can be improved.
[0131] In some embodiments, the above step 120 specifically includes:
[0132] Obtaining an amplitude signal corresponding to an audio sampling signal;
[0133] The audio injection signal is determined according to the amplitude signal, the injection angle and the target vector coordinate system of the motor, and the injection angle is determined according to the electrical angle of the motor rotor.
[0134] Furthermore, the above step of “obtaining an amplitude signal corresponding to the audio sampling signal” specifically includes:
[0135] Get the per-unit value corresponding to the audio sampling signal;
[0136] An amplitude signal is obtained according to the per-unit value and a maximum current amplitude and / or a maximum voltage amplitude used by the motor controller to respond to the sound.
[0137] The audio sampling signal can be normalized to obtain a normalized value. Normalization is to scale the value of a digital signal to a uniform range, such as a range of -1 to 1. For example, each sample value of the audio sampling signal can be divided by the maximum possible amplitude value of the signal to achieve normalization and obtain a normalized value.
[0138] After obtaining the per-unit value, the per-unit value can be converted according to the maximum current amplitude and / or maximum voltage amplitude of the motor controller for responding to the sound to obtain the amplitude signal. For example, if the maximum current amplitude of the motor controller for responding to the sound is 2A, then the per-unit value is multiplied by 2 to obtain the current Is in the amplitude dimension corresponding to the motor controller. If the maximum current amplitude of the motor controller for responding to the sound is 5V, then the per-unit value is multiplied by 5 to obtain the voltage Us in the amplitude dimension corresponding to the motor controller.
[0139] In this embodiment, by normalizing the audio sampling signal, it helps to achieve signal consistency between different systems and devices. By considering the maximum audio response capability of the motor controller, the amplitude signal can be optimal within the dynamic range of the motor, so that the motor can output a sound intensity that matches the audio sampling signal, thereby maintaining the sound quality emitted by the motor and achieving more accurate sound reproduction.
[0140] Further, when the target vector coordinate system includes a stationary coordinate system, the amplitude signal includes a voltage. In this case, the above step of "determining the audio injection signal according to the amplitude signal, the injection angle and the target vector coordinate system of the motor" specifically includes:
[0141] According to the injection angle, the vectors of each coordinate axis of the amplitude signal in the stationary coordinate system are obtained to obtain the audio injection signal.
[0142] Wherein, when the target vector coordinate system is a stationary coordinate system (α-β coordinate system), the amplitude signal includes the voltage U S , U can be converted by injecting the angle theta S Mapped to the α-β coordinate system, the specific formula is as follows:
[0143] Uαth = Us * cos(theta);
[0144] Uβth = Us * sin(theta);
[0145] Among them, theta=K*θ+theta_init, where K is a real number, θ is the electrical angle of the rotor magnetic field, and theta_init is the initial angle of injection, ranging from 0 to 360 degrees. For example, K=2*π*f*t, t is time, f is frequency, and can be negatively correlated with the speed.
[0146] Further, when the target vector coordinate system includes a rotating coordinate system, the amplitude signal includes voltage and / or current, and the above step of "determining the audio injection signal according to the amplitude signal, the injection angle and the target vector coordinate system of the motor" specifically includes:
[0147] According to the injection angle, the vectors of each coordinate axis of the amplitude signal in the n-order rotating coordinate system are obtained to obtain the audio injection signal, where n is a real number.
[0148] Among them, the current Is and / or voltage Us can be converted to an n-order dq coordinate system in a positive direction or a negative direction. The direction can be positive or negative, and the order n can be n=1, 2, 3, 4, 5, 6, 7, etc. in the positive direction, and n=-1, -2, -3, -4, -5, -6, -7, etc. in the negative direction.
[0149] For example, see Figure 5 , when the target vector coordinate system is the dq coordinate system, n is 1, and the amplitude signal includes the current Is, Is can be mapped to the first-order dq coordinate system by injecting the angle theta, as shown in the formula:
[0150] ;
[0151] ;
[0152] in, represents the d-axis current vector in the first-order rotating coordinate system, Represents the q-axis current vector in the first-order rotating coordinate system, theta=K*θ+theta_init, where K is a real number, θ is the electrical angle of the rotor magnetic field, and theta_init is the initial angle of injection, ranging from 0 to 360 degrees. The injection angle is used to adjust the sound volume of the motor.
[0153] After calculating the d-axis current vector and the q-axis current vector, the current can be converted into voltage through the current-voltage conversion module to obtain the d-axis voltage vector in the first-order rotating coordinate system. , q-axis voltage vector .
[0154] For example, see Figure 6 , when the target vector coordinate system is the dq coordinate system, n is 1, and the amplitude signal includes the voltage U S When U S Mapped to the first-order dq coordinate system, as shown in the formula:
[0155] ;
[0156] ;
[0157] theta=K*θ+theta_init, where K is a real number, θ is the electrical angle of the rotor magnetic field, and theta_init is the initial angle of injection, ranging from 0 to 360 degrees.
[0158] In an embodiment of the present application, by simultaneously converting the voltage and current in the amplitude signal into a target vector coordinate system and subsequently controlling the motor based on the converted signal, the bandwidth of the motor's response to the audio signal can be improved, and the motor can respond to higher sound frequencies, thereby improving the sound restoration degree.
[0159] Moreover, when n is of high order (that is, the absolute value of n is greater than 1), such as 2, 3, 4, -2, -3, etc., by converting the voltage and / or current in the amplitude signal into the current vector and / or voltage vector of the high-order dq coordinate system, a higher-order rotating coordinate system is used to increase the control complexity. Compared with the low-frequency vibration or jitter problem that may exist in the low-frequency audio signal in the 1st-order dq coordinate system, in the high-order dq coordinate system, since the rotation frequency is faster than that in the 1st-order dq coordinate system, the duration of the vibration point is dispersed, and the rotor rotates multiple times around one circle, and the corresponding vibration point time becomes shorter and the duration becomes shorter, which almost does not cause jitter, thereby solving the jitter problem caused by low-frequency audio signals, helping to suppress motor jitter during the motor playing music, and improving the music playback quality.
[0160] Further, when the target vector coordinate system includes a rotating coordinate system, the amplitude signal includes voltage and / or current, and the above step of "determining the audio injection signal according to the amplitude signal, the injection angle and the target vector coordinate system of the motor" specifically includes:
[0161] According to the injection angle, the vectors of each coordinate axis of the amplitude signal in the first order coordinate system and the second order coordinate system are obtained to obtain the audio injection signal. The first order coordinate system and the second order coordinate system are rotating coordinate systems of different orders.
[0162] Among them, the current Is and / or voltage Us can be converted to different orders of dq coordinate systems, such as 1st order and higher order, in the positive direction or negative direction, so that the low-frequency part of the audio sampling signal can be injected into the 1st order dq coordinate system, and the high-frequency part of the audio sampling signal can be injected into the higher order dq coordinate system. For example, converting the current Is to the -5th order and 7th order dq coordinate systems yields , , , , and / or convert the voltage Us to the -5th order and 7th order dq coordinate system to obtain , , , In order to filter out sounds of other frequencies in the audio sampling signal, the current Is and / or the voltage Us may be filtered by a filter to obtain a low-frequency part and a high-frequency part, and then converted to the target vector coordinate system.
[0163] In this embodiment, by converting the amplitude signal into dq coordinate systems of different orders, the electromagnetic driving force of the motor can be accurately matched with the corresponding audio signal, so as to smooth the operation of the motor, reduce torque pulsation and noise during motor operation, and improve the audio playback quality; further, if the amplitude signal includes voltage and current, the bandwidth of the audio signal response can be improved, and higher sound frequencies can be responded to, thereby improving the sound restoration degree.
[0164] 130. Determine a control signal for the motor to generate sound according to the audio injection signal.
[0165] In the embodiment of the present application, the control signal of the motor can be updated based on the audio injection signal, for example, the duty cycle of the pulse width modulation (PWM) signal can be updated, and the PWM signal waveform can be generated according to the updated duty cycle, and the power electronic devices of the motor, such as the opening and closing of the IGBT (insulate-gate bipolar transistor), can be controlled according to the PWM signal waveform to adjust the current of the motor, so that the electromagnetic force generated by the air gap magnetic field of the motor acting on the motor core excites electromagnetic vibration, so that the motor can emit corresponding musical sounds. Among them, the air gap magnetic field is determined by the magnetomotive force of the stator and rotor windings and the air gap magnetic permeance, and the size of the electromagnetic sound is closely related to the amplitude and frequency of the harmonic magnetic field in the air gap of the motor.
[0166] In some embodiments, the above step 130 specifically includes:
[0167] determining a phase voltage of the motor according to the audio injection signal;
[0168] The duty cycle of the control signal of the phase bridge arm of the motor is adjusted according to the phase voltage.
[0169] In some embodiments, the above step of “adjusting the duty cycle of the control signal of the phase bridge arm of the motor according to the phase voltage” specifically includes:
[0170] At the moment when the extreme value point of the carrier signal is located, the duty cycle of the control signal of the phase bridge arm of the motor is adjusted according to the phase voltage.
[0171] The extreme point includes a peak and / or a trough. By completing the determination and adjustment of the duty cycle at the extreme point of the carrier signal, the update of the control signal can be synchronized with the audio sampling data, which helps to reduce the audio distortion that may be generated due to signal update delay.
[0172] In some embodiments, the above step of “adjusting the duty cycle of the control signal of the phase bridge arm of the motor according to the phase voltage at the moment when the extreme value point of the carrier signal is located” includes:
[0173] At time t1 of the carrier signal, the duty cycle of the control signal of the phase bridge arm of the motor is adjusted according to the phase voltage;
[0174] Among them, t1 is the extreme point, and 0<t1-tm<Ts, Ts is the carrier period, and tm is the time when this sampling is completed.
[0175] That is, after this sampling, the duty cycle is adjusted at the moment of the extreme value point closest to this sampling according to the phase voltage determined by the audio sampling signal obtained in this sampling. Specifically, the duty cycle ratio is obtained by dividing the phase voltage by the bus, and the comparison value is calculated according to the ratio of the carrier signal peak value to the duty cycle. The bridge arm switching action is output according to the comparison value and the carrier signal to obtain the duty cycle of the motor control signal.
[0176] After each sampling, the duty cycle of the control signal is updated and adjusted at the next extreme point of the carrier according to the digital signal obtained from this sampling. Therefore, the control signal can be adjusted according to the new audio signal characteristics in each carrier cycle of the motor, so that the time difference between the update of the control signal and the latest sampling data of the audio signal is minimized, and the audio distortion that may be caused by signal update delay is minimized, so that the sound signal output by the motor closely follows the changes of the original audio signal, thereby improving the dynamic response and accuracy of the sound, being able to reproduce the sound more accurately, and improving the quality of the motor sound.
[0177] The above step of “determining the phase voltage of the motor according to the audio injection signal” specifically includes:
[0178] Get the phase sampling current of the motor;
[0179] The phase voltage of the motor is determined based on the phase sampled current and the audio injection signal.
[0180] In some embodiments, the above step of “determining the phase voltage of the motor according to the phase sampled current and the audio injection signal” includes:
[0181] Acquire a first phase current vector corresponding to the phase sampling current, where the first phase current vector is a current vector in a stationary coordinate system;
[0182] A phase voltage of the motor is determined based on the audio injection signal and the first phase current vector.
[0183] Among them, for the p-phase motor, it is necessary to first perform Clark coordinate transformation on the phase sampling current i1 / i2…ip to obtain the first phase current vectors iα and iβ, and then determine the phase voltage U1\U2\...Up based on iα and iβ and the audio injection signal.
[0184] The motor in the embodiment of the present application can make a sound when the vehicle is stationary or when the vehicle is moving. When the sound is made when the vehicle is stationary, the above-mentioned phase voltage determination step does not need to be further superimposed with a torque signal. If the sound is made when the vehicle is moving, the above-mentioned phase voltage determination step needs to be further superimposed with a torque signal. In this case, the above-mentioned step of "determining the phase voltage of the motor according to the audio injection signal" also includes:
[0185] Determine the motor's torque output command, motor speed, battery voltage, and phase sampling current;
[0186] A given current vector is determined according to a torque output command, a motor speed and a battery voltage, and the given current vector is a current vector in a first-order rotating coordinate system.
[0187] At this time, the above step of "determining the phase voltage of the motor according to the phase sampling current and the audio injection signal" includes: determining the phase voltage of the motor according to the given current vector, the phase sampling current and the audio injection signal.
[0188] Among them, the current given vector includes the d-axis component id* and the q-axis component iq*. When the motor makes a sound while the vehicle is moving, the final phase voltage U1\U2\...Up is determined based on iα, iβ, id*, iq* and the audio injection signal. When the motor makes a sound while the vehicle is stationary, the final phase voltage U1\U2\...Up is determined based on iα, iβ and the audio injection signal.
[0189] The following describes the process of determining the phase voltage by taking the sound of the motor when the vehicle is stationary as an example.
[0190] In some embodiments, when the audio injection signal includes a voltage vector in a stationary coordinate system or a voltage vector in an m-order rotating coordinate system, m is a real number that is not 1, and the above step of “determining the phase voltage of the motor according to the audio injection signal and the first phase current vector” includes:
[0191] Acquire a second phase current vector corresponding to the phase sampling current, where the second phase current vector is a current vector in a first-order rotating coordinate system;
[0192] Determine a target voltage vector according to the second phase current vector, the target voltage vector being a voltage vector in a stationary coordinate system;
[0193] The phase voltage of the motor is determined based on the audio injection signal and the target voltage vector.
[0194] Among them, when the audio injection signal includes a voltage vector in a stationary coordinate system, for a p-phase motor, the first phase current vectors iα and iβ can be transformed by Park coordinates to obtain second phase current vectors id and iq, and then Uα and Uβ (i.e., target voltage vector) in the stationary coordinate system are determined based on the second phase current vectors id and iq and the audio injection signal. After that, Uα and Uβ are transformed by inverse Clark coordinates to obtain the phase voltages U1\U2\...Up of the motor, and are input into the FOC control system to adjust the duty cycle of the control signal.
[0195] When the audio injection signal includes a voltage vector in an m-order rotating coordinate system, such as Figure 7 As shown, taking the audio injection signal as voltage, m includes -5 and 7 as an example, the harmonic voltage obtained by -5 and 7 order conversion is , , , (i.e., audio injection signal), after inverse Park transformation, the voltage vector U in the stationary coordinate system is obtained α7th , U β7th , U α5th and U β5th At the same time, the phase sampling current i1 / i2…ip is transformed into Clark coordinates and Park coordinates to obtain the second phase current vector id and iq, and according to id and iq, the voltage vector Uα and Uβ in the stationary coordinate system are obtained after PID regulator and inverse park transformation. α7th , U β7th , U α5th , U β5th , Uα and Uβ are transformed by inverse Clark coordinates to obtain the phase voltage U1\U2\...Up of the motor, and input it into the FOC control system to adjust the duty cycle of the control signal.
[0196] In some embodiments, when the audio injection signal includes a voltage vector and / or a current vector in a first-order rotating coordinate system, the above step of “determining the phase voltage of the motor according to the audio injection signal and the first phase current vector” includes:
[0197] Acquire a second phase current vector corresponding to the phase sampling current, where the second phase current vector is a current vector in a first-order rotating coordinate system;
[0198] Determine a target voltage vector according to the second phase current vector and the audio injection signal, where the target voltage vector is a voltage vector in a stationary coordinate system;
[0199] The phase voltage of the motor is determined based on the target voltage vector.
[0200] Among them, Figure 8As shown, if the audio injection signal includes the d-axis current vector in the first-order dq coordinate system and the q-axis current vector , and the d-axis voltage vector in the first-order dq coordinate system and the q-axis voltage vector , and the second phase current vector obtained by Clark coordinate transformation and Park coordinate transformation of phase sampling current i1 / i2…ip is id and iq, then first according to id, iq, , , and , as well as the PID regulator and the inverse Park coordinate transformation, the voltage vectors Uα and Uβ (i.e., the target voltage vector) in the stationary coordinate system are obtained, and then the inverse Clark coordinate transformation is performed on Uα and Uβ to obtain the phase voltage U1\U2\...Up of the motor, which is input into the FOC control system to adjust the duty cycle of the control signal.
[0201] like Fig. 9 As shown, if the audio injection signal includes the d-axis current vector in the first-order dq coordinate system and the q-axis current vector , and the second phase current vector obtained by Clark coordinate transformation and Park coordinate transformation of phase sampling current i1 / i2…ip is id and iq, then first according to id, iq, and , as well as the PID regulator and the inverse Park coordinate transformation, determine Uα and Uβ (i.e., the target voltage vector) in the stationary coordinate system. After that, the inverse Clark coordinate transformation is performed on Uα and Uβ to obtain the phase voltage U1\U2\...Up of the motor, and input it into the FOC control system to adjust the duty cycle of the control signal.
[0202] like Fig.10 As shown, if the audio injection signal includes the d-axis voltage vector in the first-order dq coordinate system and the q-axis voltage vector , and the second phase current vector obtained by Clark coordinate transformation and Park coordinate transformation of phase sampling current i1 / i2…ip is id and iq, then first according to id, iq, and , as well as the PID regulator and inverse Park coordinate transformation, determine Uα and Uβ (i.e., the target voltage vector) in the stationary coordinate system, and then perform inverse Clark coordinate transformation on Uα and Uβ to obtain the motor's phase voltage U1\U2\...Up, which is input into the FOC control system to adjust the duty cycle of the control signal.
[0203] In some embodiments, when the audio injection signal includes a current vector in an m-order rotating coordinate system, m is a real number that is not 1, the above step of "determining the phase voltage of the motor according to the audio injection signal and the first phase current vector" includes:
[0204] Acquire a second phase current vector and a third phase current vector corresponding to the phase sampling current, the second phase current vector is a current vector in a first-order rotating coordinate system, and the third phase current vector is a current vector in an m-order rotating coordinate system;
[0205] Determine a target voltage vector according to the second phase current vector, the third phase current vector and the audio injection signal, where the target voltage vector is a voltage vector in a stationary coordinate system;
[0206] The phase voltage of the motor is determined based on the target voltage vector.
[0207] Among them, Fig.11 As shown in the figure, taking the audio injection signal as current, m includes -5 and 7 as an example, the motor phase sampling current i1 / i2…ip can be transformed into the -5th and 7th order dq coordinate system respectively, and then the -5th order harmonic current and +7th order harmonic current are extracted through the filter. After that, the current vector Is is transformed into the -5th and 7th order harmonic current. , , , Distributed to the d-axis and q-axis, the target harmonic current is obtained, and then after the PID regulator and inverse Park transformation, the voltage vector U in the stationary coordinate system is obtained. α7th , U β7th , U α5th and U β5th At the same time, the phase sampling current i1 / i2…ip is transformed into Clark coordinates and Park coordinates to obtain the second phase current vector id and iq. According to id and iq, the voltage vectors Uα and Uβ in the stationary coordinate system are obtained after PID regulator and inverse park transformation. Then, U α7th , U β7th , U α5th , U β5th , Uα and Uβ are subjected to inverse Clark transformation to obtain the motor phase voltage U1\U2\...Up, which is injected into the FOC control system to adjust the duty cycle of the control signal.
[0208] In addition, the motor can be a motor with an excitation winding, which is used to generate the magnetic field required by the motor. The motor may include a stator, a rotor and an excitation winding. The excitation winding can usually be installed on the motor rotor, such as a set of coils or electromagnets. By passing a current of a specific magnitude and direction through the excitation winding, that is, passing an excitation current. When the excitation current flows through the excitation winding, according to the Ampere loop theorem, a magnetic field is generated around the rotor, that is, the rotor excitation magnetic field. By adjusting the magnitude and phase of the excitation current, the strength and characteristics of the magnetic field can be controlled to meet different working requirements.
[0209] In this embodiment, the excitation current may also change following the audio sampling signal. That is, the sound generation method of the motor further includes:
[0210] The duty cycle of the control signal of the excitation bridge arm of the motor is adjusted according to the audio sampling signal.
[0211] In some embodiments, the above step of “adjusting the duty cycle of the control signal of the excitation bridge arm of the motor according to the audio sampling signal” specifically includes:
[0212] Determine the excitation current of the motor magnetic field according to the audio sampling signal;
[0213] Obtain the excitation voltage corresponding to the excitation current;
[0214] The duty cycle of the control signal of the excitation bridge arm of the motor is adjusted according to the excitation voltage.
[0215] The above step of “determining the excitation current of the motor magnetic field according to the audio sampling signal” specifically includes:
[0216] Get the per-unit value corresponding to the audio sampling signal;
[0217] The excitation current of the motor magnetic field is determined according to the excitation current peak value, excitation current offset and per unit value of the motor magnetic field.
[0218] Among them, since the amplitude change of the audio sampling signal reflects the strength and pitch of the sound, by responding to these changes in real time and adjusting the size of the excitation current, for example, as the amplitude of the audio sampling signal increases, the excitation current can also be increased, thereby changing the strength of the motor's magnetic field, so that the strength of the motor's magnetic field can change with the amplitude of the music to enhance the sound intensity and frequency range of the motor, so that the motor can accurately reproduce the music and sound details in the audio signal.
[0219] Specifically, the formula for determining the excitation current is as follows:
[0220]
[0221] in, represents the excitation current, represents the excitation current bias, Equal to the excitation current peak value - excitation current bias, Indicates the per-unit value, and the per-unit value can be taken as the absolute value. The audio sampling signal is normalized so that the maximum absolute value of the audio sampling signal is equal to 1 and the minimum absolute value is equal to 0, so that the absolute value of the per-unit value is between 0 and 1.
[0222] Of course, in some embodiments, the excitation current if can also be set to be equal to the excitation current bias ,in, Greater than 0 and less than the maximum excitation current, that is, the excitation current does not change with the audio sampling signal, but only adjusts the duty cycle of the control signal of the motor phase bridge arm according to the audio injection signal. This can also ensure the normal sounding of the motor, but the intensity and texture range of the sound are slightly different from the excitation current adjusted by the above formula.
[0223] The motor sound generation method provided in the embodiment of the present application can be performed by an electronic device or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal or other devices other than a terminal. For example, the electronic device can include but is not limited to an ECU (Electronic Control Unit), an MCU (Microcontroller Unit) or other controllers, etc., which are not specifically limited in the embodiment of the present application.
[0224] In some embodiments, the embodiments of the present application also provide a vehicle, including a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the processor executes the computer program, the method for producing sound of the motor as described above is implemented.
[0225] In some embodiments, Fig.12 As shown, the embodiment of the present application also provides an electronic device 300, including a processor 310, a memory 320, and a computer program stored in the memory 320 and executable on the processor 310. When the program is executed by the processor 310, each process of the above-mentioned motor sound generation method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be described here.
[0226] It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.
[0227] An embodiment of the present application also provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the various processes of the above-mentioned motor sound generation method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0228] The processor is the processor in the electronic device in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0229] The embodiment of the present application also provides a computer program product, including a computer program, which implements the above-mentioned sound generation method of the motor when executed by a processor.
[0230] The processor is the processor in the electronic device in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0231] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface and the processor are coupled, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned motor sound generation method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0232] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0233] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0234] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for enabling a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0235] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
[0236] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "illustrative embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials, or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0237] Although the embodiments of the present application have been shown and described, those skilled in the art will appreciate that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present application, and that the scope of the present application is defined by the claims and their equivalents.
Claims
1. A method for producing sound of a motor, characterized in that: include: Acquire an audio sampling signal, where the audio sampling signal is obtained by sampling the audio data; Determine an audio injection signal according to the audio sampling signal, the audio injection signal includes a voltage vector and / or a current vector in a target vector coordinate system of the motor, the target vector coordinate system includes a rotating coordinate system, the audio injection signal includes a voltage vector and / or a current vector in the rotating coordinate system of order n or the rotating coordinate system of different orders, where n is a real number not equal to 1; Determine a control signal for the motor to generate sound according to the audio injection signal; The motor is controlled according to the control signal so that the motor produces sound.
2. The method for producing sound of a motor according to claim 1, characterized in that: Also includes: The duty cycle of the control signal of the excitation bridge arm of the motor is adjusted according to the audio sampling signal.
3. The method for producing sound of a motor according to claim 2, characterized in that: The step of adjusting the duty cycle of the control signal of the excitation bridge arm of the motor according to the audio sampling signal comprises: Determine the excitation current of the motor magnetic field according to the audio sampling signal; Obtaining an excitation voltage corresponding to the excitation current; The duty cycle of the control signal of the excitation bridge arm of the motor is adjusted according to the excitation voltage.
4. The method for producing sound of a motor according to claim 3, characterized in that: The method of determining the excitation current of the motor magnetic field according to the audio sampling signal comprises: Obtaining a per-unit value corresponding to the audio sampling signal; The excitation current of the motor magnetic field is determined according to the excitation current peak value, the excitation current offset and the per-unit value of the motor magnetic field.
5. The method for producing sound of a motor according to claim 1, characterized in that: The step of determining the control signal for the motor to generate sound according to the audio injection signal comprises: The duty cycle of the control signal of the motor is adjusted according to the audio injection signal.
6. The method for producing sound of a motor according to claim 5, characterized in that: The step of adjusting the duty cycle of the control signal of the motor according to the audio injection signal comprises: determining a phase voltage of a motor according to the audio injection signal; The duty cycle of the control signal of the phase bridge arm of the motor is adjusted according to the phase voltage.
7. The method for producing sound of a motor according to claim 6, characterized in that: The step of adjusting the duty cycle of the control signal of the phase bridge arm of the motor according to the phase voltage comprises: At the moment when the extreme value point of the carrier signal is located, the duty cycle of the control signal of the phase bridge arm of the motor is adjusted according to the phase voltage.
8. The method for producing sound of a motor according to claim 7, characterized in that: The step of adjusting the duty cycle of the control signal of the phase bridge arm of the motor according to the phase voltage at the moment when the extreme value point of the carrier signal is located includes: At time t1 of the carrier signal, adjusting the duty cycle of the control signal of the phase bridge arm of the motor according to the phase voltage; Among them, t1 is the extreme point, and 0<t1-tm<Ts, Ts is the carrier period, and tm is the time when this sampling is completed.
9. The method for producing sound of a motor according to claim 6, characterized in that: Determining the phase voltage of the motor according to the audio injection signal comprises: Obtaining a phase sampling current of the motor; The phase voltage of the motor is determined according to the phase sampling current and the audio injection signal.
10. The method for producing sound of a motor according to claim 9, characterized in that: The determining the phase voltage of the motor according to the audio injection signal further includes: Determine the motor's torque output command, motor speed, battery voltage, and phase sampling current; Determine a given current vector according to the torque output command, the motor speed and the battery voltage, wherein the given current vector is a current vector in a first-order rotating coordinate system; Determining the phase voltage of the motor according to the phase sampling current and the audio injection signal includes: determining the phase voltage of the motor according to the given current vector, the phase sampling current and the audio injection signal.
11. The method for producing sound of a motor according to claim 9, characterized in that: The determining the phase voltage of the motor according to the phase sampling current and the audio injection signal comprises: Acquire a first phase current vector corresponding to the phase sampling current, where the first phase current vector is a current vector in a stationary coordinate system; A phase voltage of the motor is determined based on the audio injection signal and the first phase current vector.
12. The method for producing sound of a motor according to claim 11, characterized in that: When the audio injection signal includes a voltage vector in a stationary coordinate system or a voltage vector in an m-order rotating coordinate system, m is a real number that is not 1, and determining the phase voltage of the motor according to the audio injection signal and the first phase current vector includes: Acquire a second phase current vector corresponding to the phase sampling current, where the second phase current vector is a current vector in a first-order rotating coordinate system; determining a target voltage vector according to the second phase current vector, wherein the target voltage vector is a voltage vector in the stationary coordinate system; A phase voltage of the motor is determined according to the audio injection signal and the target voltage vector.
13. The method for producing sound of a motor according to claim 11, characterized in that: When the audio injection signal includes a current vector in an m-order rotating coordinate system, and m is a real number that is not 1, determining the phase voltage of the motor according to the audio injection signal and the first phase current vector includes: Acquire a second phase current vector and a third phase current vector corresponding to the phase sampling current, wherein the second phase current vector is a current vector in a first-order rotating coordinate system, and the third phase current vector is a current vector in an m-order rotating coordinate system; Determine a target voltage vector according to the second phase current vector, the third phase current vector and the audio injection signal, wherein the target voltage vector is a voltage vector in the stationary coordinate system; A phase voltage of the motor is determined according to the target voltage vector.
14. The method for producing sound of a motor according to claim 1, characterized in that: The step of determining the audio injection signal according to the audio sampling signal comprises: Acquire an amplitude signal corresponding to the audio sampling signal; An audio injection signal is determined according to the amplitude signal, the injection angle and the target vector coordinate system of the motor, wherein the injection angle is determined according to the electrical angle of the motor rotor.
15. The method for producing sound of a motor according to claim 14, characterized in that: The obtaining of the amplitude signal corresponding to the audio sampling signal comprises: Obtaining a per-unit value corresponding to the audio sampling signal; An amplitude signal is obtained according to the per-unit value and a maximum current amplitude and / or a maximum voltage amplitude used by the motor controller to respond to the sound.
16. The method for producing sound of a motor according to claim 14, characterized in that: When the target vector coordinate system includes a stationary coordinate system, the amplitude signal includes a voltage, and determining the audio injection signal according to the amplitude signal, the injection angle, and the target vector coordinate system of the motor includes: According to the injection angle, the vectors of each coordinate axis of the amplitude signal in the stationary coordinate system are obtained to obtain the audio injection signal.
17. The method for producing sound of a motor according to claim 14, characterized in that: When the target vector coordinate system includes a rotating coordinate system, the amplitude signal includes voltage and / or current, and determining the audio injection signal according to the amplitude signal, the injection angle, and the target vector coordinate system of the motor includes: According to the injection angle, the vectors of the amplitude signal on each coordinate axis in the rotating coordinate system of order n are obtained to obtain an audio injection signal, where n is a real number not equal to 1.
18. The method for producing sound of a motor according to claim 14, characterized in that: When the target vector coordinate system includes a rotating coordinate system, the amplitude signal includes voltage and / or current, and determining the audio injection signal according to the amplitude signal, the injection angle, and the target vector coordinate system of the motor includes: According to the injection angle, vectors of each coordinate axis of the amplitude signal in a first-order coordinate system and a second-order coordinate system are obtained to obtain an audio injection signal, wherein the first-order coordinate system and the second-order coordinate system are rotating coordinate systems of different orders.
19. The method for producing sound of a motor according to claim 1, characterized in that: Also includes: In one carrier cycle, the audio data is sampled multiple times to obtain the audio sampling signal.
20. The method for producing sound of a motor according to claim 19, characterized in that: The audio data is sampled multiple times within one carrier cycle, including: In one carrier cycle, the audio data is sampled at the time when multiple extreme points of the carrier signal are located.
21. A vehicle, characterized in that: The invention comprises a processor, a memory and a computer program stored in the memory and capable of running on the processor, wherein when the computer program is executed by the processor, the method for producing sound of a motor according to any one of claims 1 to 20 is implemented.
22. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method for producing sound of a motor as described in any one of claims 1 to 20 is implemented.
23. A computer program product, characterized in that The invention comprises a computer program, which, when executed by a processor, implements the method for producing sound of a motor as claimed in any one of claims 1 to 20.
Citation Information
Patent Citations
Method and apparatus for acoustic signal generation
CN109039187A
Active sound generation apparatus using motor
CN112350639A