Disclosure of Invention
The invention provides a method, a device, equipment and a medium for rotary soft decoding, which are used for solving the problems that sampling signals are easy to fluctuate and sampling is inaccurate when peak value sampling is carried out in the related technology.
In order to solve the above problems, an embodiment of an aspect of the present invention provides a method for soft-rotation decoding, including:
Setting positive pulse and negative pulse and their corresponding durations to form positive and negative alternating square wave pulse;
integrating the square wave pulse with alternating positive and negative to obtain a trapezoidal wave reference signal;
taking difference from the trapezoidal wave reference signal to form a differential signal, and sending a trapezoidal wave excitation signal to act on the rotary transformer after the differential signal passes through a hardware modulation amplifying circuit;
Peak value sampling is carried out on the feedback signal of the rotary transformer, and a sampling signal is obtained;
performing delay compensation on the sampling signal based on the trapezoidal wave reference signal to obtain a delay compensation sampling signal;
Extracting a sine and cosine envelope curve containing rotor position information based on the delay compensation sampling signal;
And obtaining rotor position information based on the sine and cosine envelope curve.
Optionally, the peak sampling the feedback signal of the rotary transformer to obtain a sampled signal includes:
And sampling the center corresponding to the peak line segment of the feedback signal to obtain the sampling signal.
Optionally, performing delay compensation on the sampling signal based on the trapezoidal wave reference signal, to obtain a delay compensated sampling signal includes:
And obtaining a delay signal of the trapezoidal wave reference signal, and applying the sign of the delay signal to the sampling signal to obtain the delay compensation sampling signal.
Optionally, acquiring the delay signal of the trapezoidal wave reference signal includes:
when the trapezoid wave reference signal starts to be generated from 0, controlling the same-frequency clock to count from 0;
When the sampling signal is acquired, controlling the same-frequency clock to stop counting, and obtaining a first delay time according to the counting of the same-frequency clock;
obtaining a substantial delay time based on the first delay time and a period of the trapezoidal wave reference signal; wherein, the steps are circulated at least once, and when the circulation is repeated for a plurality of times, the substantial delay time is the average value of the substantial delay time obtained each time;
And delaying the trapezoidal wave reference signal by a substantial delay time to obtain the delay signal.
Optionally, the deriving the substantial delay time based on the first delay time and the period of the trapezoidal-wave reference signal includes:
The substantial delay time is a remainder of a ratio of the first delay time to a period of the trapezoidal wave reference signal.
Optionally, the obtaining rotor position information based on the sine and cosine envelope curve includes:
Calculating the ratio of the sine envelope curve to the cosine envelope curve to obtain a tangent signal;
and performing arc tangent function calculation on the tangent signal to obtain rotor position information.
Optionally, after obtaining the rotor position information based on the sine and cosine envelope, the method further includes:
And acquiring an angle compensation value of the rotor position information, and performing error compensation on the rotor position information.
Optionally, the obtaining the angle compensation value of the rotor position information, performing error compensation on the rotor position information, includes:
carrying out current loop calculation based on the rotor position information, wherein a measured motor is dragged to a certain rotating speed by a dynamometer, and the current of a required d axis and a required q axis is set to be 0A;
calculating an arctangent value of a ratio of a required d-axis projection voltage and a required q-axis projection voltage in the current loop as the angle compensation value;
And after the rotor position information is overlapped by using the angle compensation value, circularly executing the step of acquiring the angle compensation value of the rotor position information and performing error compensation on the rotor position information until the angle compensation value is 0, and outputting corresponding rotor position information.
To solve the above problem, an embodiment of a second aspect of the present invention provides a soft-rotation decoding device, including:
the setting module is used for setting positive pulses, negative pulses and corresponding durations thereof to form square wave pulses with positive and negative alternation;
The integration module is used for integrating the square wave pulse with positive and negative alternation to obtain a trapezoidal wave reference signal;
the feedback signal generation module is used for taking difference of the trapezoidal wave reference signals to form difference signals, and the difference signals send trapezoidal wave excitation signals to act on the rotary transformer after passing through the hardware modulation amplifying circuit;
The sampling module is used for carrying out peak value sampling on the feedback signal of the rotary transformer to obtain a sampling signal;
The delay compensation module is used for carrying out delay compensation on the sampling signal based on the trapezoidal wave reference signal to obtain a delay compensation sampling signal;
An envelope extraction module for extracting a sine and cosine envelope including rotor position information based on the delay compensation sampling signal;
and the rotor position information calculation module is used for obtaining rotor position information based on the sine and cosine envelope curve.
To solve the above problem, an embodiment of a third aspect of the present invention provides an electronic device, including:
At least one processor; and
A memory communicatively coupled to the at least one processor; wherein,
The memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the method of soft-spin decoding according to any one of the embodiments of the present invention.
To solve the above-mentioned problem, a fourth aspect of the present invention provides a computer readable storage medium, where computer instructions are stored, where the computer instructions are configured to cause a processor to execute the method for soft-spin decoding according to any one of the embodiments of the present invention.
According to the technical scheme, positive and negative alternating square wave pulses are formed by setting positive pulses, negative pulses and corresponding durations; integrating the square wave pulse with alternating positive and negative to obtain a trapezoidal wave reference signal; then taking difference to the trapezoid wave reference signal to form a difference signal, and sending out a trapezoid wave excitation signal to act on the rotary transformer after the difference signal passes through the hardware modulation amplifying circuit; then, peak value sampling is carried out on the feedback signal of the rotary transformer, and a sampling signal is obtained; then, based on the trapezoidal wave reference signal, carrying out delay compensation on the sampling signal to obtain a delay compensation sampling signal; then extracting sine and cosine envelope curves containing rotor position information based on the delay compensation sampling signals; and finally, obtaining rotor position information based on the sine and cosine envelope curve, and further forming a trapezoidal wave reference signal through integration of square wave pulses, wherein the trapezoidal wave reference signal is easier to sample compared with the sine wave reference signal and is not easy to be influenced by harmonic waves compared with the square wave reference signal, so that the accuracy of the sampling signal can be improved, and the accuracy of the rotor position information is further improved.
It should be understood that the description in this section is not intended to identify key or critical features of the embodiments of the invention or to delineate the scope of the invention. Other features of the present invention will become apparent from the description that follows.
Detailed Description
In order that those skilled in the art will better understand the present invention, a technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present invention without making any inventive effort, shall fall within the scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present invention and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the invention described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Fig. 1 is a flowchart of a method for soft-spin decoding according to an embodiment of the present invention. As shown in fig. 1, the soft-rotation decoding method includes:
s101, positive and negative pulses and corresponding durations are set to form square wave pulses with positive and negative alternation.
As shown in fig. 2, the positive pulse of the square wave pulse alternating positive and negative has a duration of t1 and the negative pulse has a duration of t2, where t1=t2.
S102, integrating the square wave pulse with alternating positive and negative to obtain a trapezoidal wave reference signal.
With continued reference to fig. 2, the square wave pulse is integrated to obtain a trapezoidal wave reference signal, where the period of the trapezoidal wave reference signal is t=t1+t2.
S103, taking difference to the trapezoidal wave reference signal to form a difference signal, and sending out a trapezoidal wave excitation signal to act on the rotary transformer after the difference signal passes through the hardware modulation amplifying circuit.
It is known that after the trapezoidal wave reference signal is generated, one path of the trapezoidal wave reference signal is output, and the other path of the trapezoidal wave reference signal is output after being inverted, and then the two paths of trapezoidal wave reference signals form differential signals, and after modulation and amplification, trapezoidal wave excitation signals are formed to act on the rotary transformer. Wherein, the resolver is a resolver: when exciting signal is applied to exciting winding, the rotor and motor rotate coaxially, and two orthogonal waveforms are generated at two ends of output winding.
S104, peak value sampling is carried out on the feedback signal of the rotary transformer, and a sampling signal is obtained.
That is, after the trapezoidal wave excitation signal acts on the resolver, the output end of the resolver can output two orthogonal waveforms depending on the rotor position. That is, the feedback signal of the resolver in step S104 is then peak-sampled, and a sampled signal can be obtained. For example, with continued reference to fig. 3, when the feedback signal is peak sampled, the sampling point may be at any point of the peak, and the sampling period may be a period of half a trapezoidal wave reference signal, the value=t1=t2.
S105, performing delay compensation on the sampling signal based on the trapezoidal wave reference signal to obtain a delay compensation sampling signal.
It can be understood that the reference signal is generated from the trapezoidal wave, and is collected by the sampler after being subjected to a hardware modulation amplifying circuit and a rotary transformer, and the signal delay exists in the middle. Thus, delay compensation of the sampled signal is required to achieve accurate control of the motor. The specific delay compensation content is described below.
And S106, extracting sine and cosine envelope curves containing rotor position information based on the delay compensation sampling signals.
And S107, obtaining rotor position information based on the sine and cosine envelope curve.
Therefore, the delay compensation sampling signal is extracted into sine and cosine envelope curves, and rotor position information of the motor can be obtained through calculation.
Therefore, the method for the rotational-to-soft decoding provided by the embodiment of the invention avoids the influence of easy fluctuation when the sinusoidal reference signal is sampled by generating the trapezoidal wave reference signal, is easy to be influenced by harmonic waves when the square wave reference signal is sampled, does not need high-frequency sampling, has small change on hardware, does not need additional design of a hardware circuit, and can realize accurate decoding and correction of position angles while reducing cost.
Optionally, peak sampling the feedback signal of the rotary transformer, and obtaining the sampling signal includes:
And sampling the center corresponding to the peak line segment of the feedback signal to obtain a sampling signal.
With continued reference to fig. 3, the peak sampling points of the feedback signal may be, for example, at points a, B, and C. Because the excitation signal is trapezoidal wave, step mutation can not appear in the trapezoidal wave signal in the process of sampling from A to B, the trapezoidal wave signal keeps the continuity of the sinusoidal reference signal, also keeps the longer duration of the square wave signal at the peak value, and is favorable for the sampling of the sampler. And the sampling value is more stable at the midpoint of the peak value, so that the sampling value is more accurate.
Optionally, performing delay compensation on the sampling signal based on the trapezoidal wave reference signal, and obtaining the delay compensated sampling signal includes: and obtaining a delay signal of the trapezoidal wave reference signal, and applying the sign of the delay signal to the sampling signal to obtain a delay compensation sampling signal.
It is understood that the delay signal is a signal obtained by compensating for the delay of the reference signal of the trapezoidal wave, and the period of the delay signal is the same as the period of the reference signal of the trapezoidal wave. After the sign of the delay signal is applied to the sampled signal, a delay compensated sampled signal is obtained. So that the sampled signal is delay corrected.
Optionally, acquiring the delay signal of the trapezoidal wave reference signal includes: when the trapezoid wave reference signal starts to be generated from 0, the same-frequency clock is controlled to count from 0; when a sampling signal is acquired, controlling the same-frequency clock to stop counting, and obtaining a first delay time according to the counting of the same-frequency clock; obtaining a substantial delay time based on the first delay time and the period of the trapezoidal wave reference signal; wherein, the steps are circulated at least once, and when the circulation is repeated for a plurality of times, the substantial delay time is the average value of the substantial delay time obtained each time; and delaying the trapezoidal wave reference signal by a substantial delay time to obtain a delay signal.
That is, with continued reference to fig. 3, when the trapezoidal wave reference signal starts to be generated from 0, the same-frequency clock starts to count, and since the trapezoidal wave reference signal becomes two paths of trapezoidal wave rotation feedback signals after rotation, the two paths of signals can be collected to the AD sampler at the same time. Because the delay is adopted, the signal which is just collected by the AD sampler is very weak, the amplitude always fluctuates near 0, when a certain amplitude appears suddenly, namely when the signal fluctuation threshold value is exceeded, the AD sampler is indicated to be adopted by the trapezoidal wave rotation feedback signal, then the signal with larger amplitude is selected to correspond to the count value (because two paths are in cosine-like state, one path is sine-like state, the signal with larger amplitude which is received first is selected, so that the rotation feedback signal can be clearly known to reach the sampler), and further, the erroneous judgment can be prevented. At this time, the same-frequency clock may be controlled to stop, and the first delay time t3 is recorded.
Optionally, deriving the substantial delay time based on the first delay time and the period of the trapezoidal wave reference signal includes: the substantial delay time is the remainder of the ratio of the first delay time to the period of the trapezoidal wave reference signal.
In addition, since the trapezoidal wave is a periodic signal, the first delay time T3 is divided by the period T of the trapezoidal wave, and the remainder is the substantial delay time. In order to ensure the accuracy of the substantial delay time, the step of acquiring the substantial delay time may be performed multiple times, and finally, the average value of the substantial delay time is taken as the final substantial delay time.
It will be appreciated that, with continued reference to FIG. 3, after the substantial delay time is obtained, a time of t1/2, or t2/2, may be superimposed on the substantial delay time as the actual sampling time of the sampled signal.
Optionally, obtaining the rotor position information based on the sine and cosine envelope comprises:
calculating the ratio of the sine envelope curve to the cosine envelope curve to obtain a tangent signal; and performing arctangent function calculation on the tangent signal to obtain rotor position information.
That is, a tangent signal may be obtained by performing a tangent operation on a sine curve formed by connecting a plurality of sampling points ABC of one path of trapezoidal wave rotation feedback signal and a cosine curve formed by connecting a plurality of sampling points of another Lu Tixing wave rotation feedback signal. Then, the tangent signal is resolved by arctangent to obtain rotor position information.
The calculation method can be used for calculating the position angle and the rotating speed by using a conventional soft decoding method such as an atan function method or a phase-locked loop. The present invention is not particularly limited thereto.
Optionally, after obtaining the rotor position information based on the sine and cosine envelope, obtaining an angle compensation value of the rotor position information, and performing error compensation on the rotor position information.
It can be understood that the sampling point is acquired from the sampler until the corresponding rotor position information is resolved, at this time, the motor has rotated by a certain angle, and then the current resolved rotor position information is delayed from the current rotor angle of the motor, so that the resolved rotor position information needs to be adapted to the current rotor angle of the motor after being increased by a certain angle for compensation.
Optionally, acquiring an angle compensation value of the rotor position information, performing error compensation on the rotor position information, including: carrying out current loop calculation based on rotor position information, wherein a measured motor is dragged to a certain rotating speed by a dynamometer, and the current of a required d axis and a required q axis is set to be 0A; calculating an arctangent value of a ratio of a required d-axis projection voltage and a required q-axis projection voltage in the current loop as an angle compensation value; and after the rotor position information is overlapped by using the angle compensation value, circularly executing the steps of acquiring the angle compensation value of the rotor position information and performing error compensation on the rotor position information until the angle compensation value is0, and outputting the corresponding rotor position information.
Referring to fig. 4, q×d is a coordinate system of the electronic angular distribution current calculated by soft decoding, and qd is a coordinate system of the actual angular distribution current of the motor. The soft decoding angle is finally used for motor control, but due to delays such as sampling calculation, the decoded angle may deviate from the actual motor position angle, and soft decoding angle error compensation calibration can be performed according to the following method. On the premise of ensuring that the initial angle is correct, the angle calculated by soft decoding is used for calculating a current loop, a measured motor is dragged to a certain rotating speed (a rated rotating speed or half of the rated rotating speed, the rotating speed cannot be too low) by a dynamometer, the current of a d-axis of a demand and a q-axis of the demand is set to be 0A, at the moment, the current loop PI only adjusts the voltage of the q-axis to offset counter-potential, and the voltage on the d-axis is set to be 0. When the soft decoding angle is incorrect, the d-q axis calculated by the current loop in the software has an angle deviation from the dq axis of the actual motor rotorThe counter potential E will then project a voltage Ud on the d axis, according to which the equation can be followedThe error between the soft decoding angle and the actual angle can be calculated, when the angle error does not exist=0, WillThe compensation is corrected by forming a closed loop at the soft decoding angle used for the coordinate transformation. Filtering is added as necessary to ensure that the calculated angle does not fluctuate frequently. The method can complete error compensation and calibration of the soft decoding angle.
Therefore, in the rotational soft decoding method provided by the invention, trapezoidal wave excitation is used in combination with peak sampling, the sampling accuracy is improved while the sampling frequency is low, the influence of harmonic wave and noise signals is reduced, meanwhile, the automatic delay compensation is added to extract envelope signals, the signal extraction process is simplified, soft decoding and error calibration are carried out, the accuracy of soft decoding calculation angle in the mode is ensured, an additional design hardware circuit is not needed, and ultrahigh frequency AD sampling is not needed. By changing the excitation wave generation and processing on the software, no additional hardware circuit is required, and the accurate decoding and correction of the position angle are realized while the cost is reduced.
The embodiment of the invention provides a rotary soft decoding device, which comprises:
the setting module is used for setting positive pulses, negative pulses and corresponding durations thereof to form square wave pulses with positive and negative alternation;
The integration module is used for integrating the square wave pulse with positive and negative alternation to obtain a trapezoidal wave reference signal;
The feedback signal generation module is used for taking difference of the trapezoidal wave reference signals to form difference signals, and the difference signals send trapezoidal wave excitation signals to act on the rotary transformer after passing through the hardware modulation amplifying circuit;
The sampling module is used for carrying out peak value sampling on the feedback signal of the rotary transformer to obtain a sampling signal;
The delay compensation module is used for carrying out delay compensation on the sampling signal based on the trapezoidal wave reference signal to obtain a delay compensation sampling signal;
an envelope extraction module for extracting a sine and cosine envelope including rotor position information based on the delay compensation sampling signal;
And the rotor position information calculation module is used for obtaining rotor position information based on the sine and cosine envelope curve.
Optionally, the sampling module is configured to sample a center corresponding to a peak line segment of the feedback signal, so as to obtain a sampling signal.
Optionally, the delay compensation module is configured to obtain a delay signal of the trapezoidal wave reference signal, and apply a sign of the delay signal to the sampling signal to obtain a delay compensated sampling signal.
Optionally, the process of the delay compensation module obtaining the delay signal is as follows:
When the trapezoid wave reference signal starts to be generated from 0, the same-frequency clock is controlled to count from 0;
When a sampling signal is acquired, controlling the same-frequency clock to stop counting, and obtaining a first delay time according to the counting of the same-frequency clock;
Obtaining a substantial delay time based on the first delay time and the period of the trapezoidal wave reference signal; wherein, the steps are circulated at least once, and when the circulation is repeated for a plurality of times, the substantial delay time is the average value of the substantial delay time obtained each time;
And delaying the trapezoidal wave reference signal by a substantial delay time to obtain a delay signal.
Optionally, the substantial delay time is a remainder of a ratio of the first delay time to a period of the trapezoidal wave reference signal.
Optionally, the rotor position information calculating module is used for calculating the ratio of the sine envelope curve to the cosine envelope curve to obtain a tangent signal; and performing arctangent function calculation on the tangent signal to obtain rotor position information.
Optionally, the rotary soft decoding device further comprises an angle compensation module;
the angle compensation module is used for acquiring an angle compensation value of the rotor position information and performing error compensation on the rotor position information.
Optionally, the angle compensation module is used for carrying out current loop calculation based on rotor position information, wherein a power measuring machine is used for dragging a motor to be measured to a certain rotating speed, and the current of a required d axis and a required q axis is given to be 0A; calculating an arctangent value of a ratio of a required d-axis projection voltage and a required q-axis projection voltage in the current loop as an angle compensation value; and after the rotor position information is overlapped by using the angle compensation value, circularly executing the steps of acquiring the angle compensation value of the rotor position information and performing error compensation on the rotor position information until the angle compensation value is 0, and outputting the corresponding rotor position information.
The rotary soft decoding device provided by the embodiment of the invention can execute the rotary soft decoding method provided by any embodiment of the invention, and has the corresponding functional modules and beneficial effects of the execution method.
In order to solve the above problems, an embodiment of the present invention provides an electronic device, including:
At least one processor; and
A memory communicatively coupled to the at least one processor; wherein,
The memory stores a computer program executable by the at least one processor to enable the at least one processor to perform the method of soft-spin decoding according to any one of the embodiments of the present invention.
To solve the above-mentioned problems, an embodiment of the present invention proposes a computer readable storage medium storing computer instructions for implementing the soft-spin decoding method according to any one of the embodiments of the present invention when executed by a processor.
Fig. 5 shows a schematic diagram of the structure of an electronic device that may be used to implement an embodiment of the invention. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. Electronic equipment may also represent various forms of mobile devices, such as personal digital processing, cellular telephones, smartphones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the inventions described and/or claimed herein.
As shown in fig. 5, the electronic device 10 includes at least one processor 11, and a memory, such as a Read Only Memory (ROM) 12, a Random Access Memory (RAM) 13, etc., communicatively connected to the at least one processor 11, in which the memory stores a computer program executable by the at least one processor, and the processor 11 may perform various appropriate actions and processes according to the computer program stored in the Read Only Memory (ROM) 12 or the computer program loaded from the storage unit 18 into the Random Access Memory (RAM) 13. In the Random Access Memory (RAM) 13, various programs and data required for the operation of the electronic device 10 may also be stored. The processor 11, read Only Memory (ROM) 12 and Random Access Memory (RAM) 13 are connected to each other by a bus 14. An input/output (I/O) interface 15 is also connected to bus 14.
The various components in the electronic device 10 are connected to an input/output (I/O) interface 15, including: an input unit 16 such as a keyboard, a mouse, etc.; an output unit 17 such as various types of displays, speakers, and the like; a storage unit 18 such as a magnetic disk, an optical disk, or the like; and a communication unit 19 such as a network card, modem, wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information/data with other devices via a computer network, such as the internet, and/or various telecommunication networks.
The processor 11 may be a variety of general and/or special purpose processing components having processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various specialized Artificial Intelligence (AI) computing chips, various processors running machine learning model algorithms, digital Signal Processors (DSPs), and any suitable processor, controller, microcontroller, etc. The processor 11 performs the various methods and processes described above, such as the soft-spin decoding method.
In some embodiments, the soft-spin decoding method may be implemented as a computer program tangibly embodied on a computer-readable storage medium, such as the storage unit 18. In some embodiments, part or all of the computer program may be loaded and/or installed onto the electronic device 10 via Read Only Memory (ROM) 12 and/or communication unit 19. One or more of the steps of the spiral-wound soft decoding method described above may be performed when the computer program is loaded into Random Access Memory (RAM) 13 and executed by processor 11. Alternatively, in other embodiments, the processor 11 may be configured to perform the soft-spin decoding method by any other suitable means (e.g., by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuit systems, field Programmable Gate Arrays (FPGAs), application Specific Integrated Circuits (ASICs), application Specific Standard Products (ASSPs), systems On Chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs, the one or more computer programs may be executed and/or interpreted on a programmable system including at least one programmable processor, which may be a special purpose or general-purpose programmable processor, that may receive data and instructions from, and transmit data and instructions to, a storage system, at least one input device, and at least one output device.
A computer program for carrying out methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the computer programs, when executed by the processor, cause the functions/acts specified in the flowchart and/or block diagram block or blocks to be implemented. The computer program may execute entirely on the machine, partly on the machine, as a stand-alone software package, partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of the present invention, a computer-readable storage medium may be a tangible medium that can contain, or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The computer readable storage medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. Alternatively, the computer readable storage medium may be a machine readable signal medium. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) through which a user can provide input to the electronic device. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), blockchain networks, and the internet.
The computing system may include clients and servers. The client and server are typically remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also called a cloud computing server or a cloud host, and is a host product in a cloud computing service system, so that the defects of high management difficulty and weak service expansibility in the traditional physical hosts and VPS service are overcome.
According to the technical scheme, positive and negative alternating square wave pulses are formed by setting positive pulses, negative pulses and corresponding durations; integrating the square wave pulse with alternating positive and negative to obtain a trapezoidal wave reference signal; then taking difference to the trapezoid wave reference signal to form a difference signal, and sending out a trapezoid wave excitation signal to act on the rotary transformer after the difference signal passes through the hardware modulation amplifying circuit; then, peak value sampling is carried out on the feedback signal of the rotary transformer, and a sampling signal is obtained; then, based on the trapezoidal wave reference signal, carrying out delay compensation on the sampling signal to obtain a delay compensation sampling signal; then extracting sine and cosine envelope curves containing rotor position information based on the delay compensation sampling signals; and finally, obtaining rotor position information based on the sine and cosine envelope curve, and further forming a trapezoidal wave reference signal through integration of square wave pulses, wherein the trapezoidal wave reference signal is easier to sample compared with the sine wave reference signal and is not easy to be influenced by harmonic waves compared with the square wave reference signal, so that the accuracy of the sampling signal can be improved, and the accuracy of the rotor position information is further improved.
It should be appreciated that various forms of the flows shown above may be used to reorder, add, or delete steps. For example, the steps described in the present invention may be performed in parallel, sequentially, or in a different order, so long as the desired results of the technical solution of the present invention are achieved, and the present invention is not limited herein.
The above embodiments do not limit the scope of the present invention. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives are possible, depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the scope of the present invention.