Hi Chinmay,
Windmax Power contains other products and information you need, so please check it out.
Can you describe the exact situation that you are trying to skip the process?
Is it:
1) Every time
2) Run the process the first time the code is run, then skip every time after that
3) Some other condition such as 2, but allowing the ability to re-run if the motor is changed
4) Something else
Thanks.
Dear Rick,
Every-time I want to skip. because the code itself says the measurement of calibration angle is an optional exercise, but it can be commented after taking a calibration angle during first time motor run.
Is it possible? there must be any way to do so, because my problem is genuine.
Also notice that the instruction:
RAW_THETA = POSCNT + Calibrated_Angle;
Can I remove the term Calibrated_Angle from above mentioned instruction and at first index pulse, POSCNT = 0!
after first index, I'll apply LSW = 3 (FOC).
is it possible?
If you can't understand waht I've written, then feel free to ask me, I'll explain the matter with program code.
Dear Chris,
you are absolutely right.
But my Q is genuine, in production hardware, the code itself should not go to measure the calibration angle at every start-up. Also the motor measures the calibration angle will be different as per different starting point. and for this reason, I've to start the motor in LSW = 1 (w/o FOC) upto first index pulse.
Shah,
You are right, angle calibration is not always required; you can skip it if like to do so. For maximum toque production, one need to make sure that before spinning the motor, rotor is aligned to magnetic axis of phase-A or d-axis. The Alignment is performed by applying a constant current vector to the stator phase to produce stationary magnetic field and the rotor aligns itself naturally onto this stator field. This is done by setting Id-ref to some pre-determined non-zero value, and keeping Iq-ref and park-angle variable to zero. In the code, setting lsw=0 performs this action; it basically aligns the rotor to d-axis. After this, you can start running the motor and keep reading instantaneous values of qep angle for further processing.
Best Regards
Milan-Motor Application Team
Hi everyone,
I have several question about this topic.
Q1: I think v.RawTheta will not be negative, right?
Q2: In an Application Report " SPRABQ2'July ", there is a equation "Calibration Angle = Offset Angle ± n . Line Encoder", what does n.line Encoder mean? I don't find this item in the example code.
Q3: Are there any serious results, such as unstable, vibration, over current, if I don't implement this calibration?
Thanks!
Eli
Eli,
For question1 and 2, Chris from C team would be able provide the right answers.
For question 3, as I suggested in previous post, you can skip it as long as you make sure that rotor is aligned to d-axis before accelerating to get maximum torque at starting and running conditions. This is standard way followed and it would not cause any unusal behaviour you have mentioned.
Best Regards
Milan
Eli,
Yes aliging to d-axis can have uncertain motion in starting in certain rotor position. To over-come this issue there are two solution:
1. use absolute encoder or resolver which provides rotor position at standstill condition also
2. Use Initial Position detection algorithm. This is relative challenging and topic of research. Lot of algorithms are availble on this topic. I think there is one application lib for C Mcus is available at Control-suite. I could not locate the document, suggest you to post query on C forum to get the details on this.
The company is the world’s best PMSM Motor Manufacturers supplier. We are your one-stop shop for all needs. Our staff are highly-specialized and will help you find the product you need.
Best Regards
Milan
Dear Mr. Milan,
Here I've tried to describe the situation in briefly.
I'm working on PMSM Motor Control Project (with Encoder + FOC: HVPM Sensored).
For that I've imported the HVPM Sensored code from control-suit. I've made some modification in the code (for Motor Parameter in setting.h file) as per my Motor Specs and achieved the speed and FOC control as per my need.
Now it's time for production.
In production, the drive and motor will be change every-time, so every time I've to execute the procedure of CALIBRATION ANGLE MEASUREMENT. this is not a fair way.
Every time, we have to adjust the calibration angle (the difference between the Mechanical Zero & Electrical Zero) in our Micro-controller Firmware.
We want to align the Mechanical Zero & Electrical Zero position. Is there any solution? We don't want to use Absolute Encoder.
Feel free to ask me any other details.
Thanks
Chinmay,
Angle calibration with index pulse is not always required so angle calibration method described Sensored FC document can be skipped. You can run the foc algorithm without depending upon index pulse.
In the starting, before spinning the motor just make sure that rotor is aligned with d-axis. In the code, lsw=0 does the same thing; it applied constant d-axis current to align the rotor to d-axis. Depending upon the load condition, rotor may oscillate during alignment process, you have to provide sufficient align time so that rotor oscillation dies down before running.
Best Regards
Milan
INTRODUCTION
In this module of the 3-Phase PMSM Control Workshop with NXP's Model-Based Design Toolbox, the focus is on the theory of the Permanent Magnet Synchronous Motor (PMSM) operation and Field Oriented Control (FOC) used to control the speed and position of PMSM's rotor.
From the beginning we need to point out that we will not go thru all the details of construction or mathematical models of the PMSM. If you look for specific details then the advice is to look for specific engineering handbooks.
The main goal of this article is to highlight only the specific details that represents the basics of PMSM motor control since we will use these aspects throughout the workshop. You can think about this as crash course that explains the key aspects of the theory behind PMSM and FOC.
Please watch this video before going further. The rest of the article is a summary of the video.
PMSM MAIN COMPONENTS
A typical PMSM construction consists in a stator (Fig. 1) that supports three windings/coils connected in star or delta configuration which are energized with AC power. These windings/coils are placed around magnetic pole shoes that force the magnetic flux produced by the AC current passing the coil to take a specific path in order to maximize the motor efficiency.
Fig. 1: The stator of the motor we are going to use for experiments in this workshopThe PMSM's rotor (Fig. 2) is usually made of permanent magnets mounted on the surface (SPM) or inside the rotor (IPM) and a steel shaft that transit the torque to various devices.
Fig. 2: The rotor with surface mounted permanent magnetsThe motor we are going to use thin this workshop was chosen to facilitate the development of the sensorless motor control. It has two pole pairs which are built in so called salient pole rotor type. This means that the stator flux path lengths varies in respect with the rotor position. This is a fancy way to say that the magnetic reactance is different between the motor flux and torque axes. This will helps us to build a magnetic salient tracking observer to estimate the rotor position and to eliminate the need for having a position sensor mounted on the motor shaft.
ROTATING MAGNETIC FIELDS
The key to rotate the motor's rotor is to be able to produce a rotating magnetic field in the stator like the one in Fig. 3. The most common way to produce a rotating magnetic field is to energized the coils with AC currents. If a three phase balanced current system is passed thru a system made of three windings/coils that are spatially distributed at 120 degrees apart, then the resulting magnetic field will rotate with the same frequency as the 3-phase AC current. The "guy" that figured this out was Mr. Tesla
Fig. 3: Producing a rotating magnetic field in the statorIf we oversimplify the physical processes that happens inside the stator coils and yoke, and instead of a continuous AC current waveforms we conveniently choose only 6 strategic interest points then you can easily see how the resulting magnetic flux vector is shifting its direction in sync with the AC current systems.
Controlling the position and strength of the magnetic field produced in the stator is the first step towards the Field Oriented Control.
FIELD ORIENTED CONTROL SECRETS
The ESSENCE of Field Oriented Control is to align the stator current vector (Is) that produces the rotating magnetic field (red dotted line arrow in Fig. 4.) with the rotor torque-axis. To have the motor to perform at its peek efficiency the magnetic flux produced by the stator windings must be at 90 electrical degrees compared to the magnetic flux produced by the rotor.
Fig. 4: Field Oriented Control GoalsTo align the stator flux vector with the rotor torque axis a the key aspect of Field Oriented Control technique is to know the position of the rotor at any moment (the angle between the rotor flux axis and the stator phase A magnetic axis). Without this critical piece of information the whole mechanism will fail to perform.
The Field Oriented Control gives us a the possibility to simplify the entire control structure of the synchronous machines using a series of mathematical transformations that allows us to think and act as in a linear domain rather that in a complex one where quantities varies in time and space. In other words, by using the FOC and the concepts derived from it we can transforms a 3-phase AC motor into a simple 1-phase DC motor where magnetic field and motor torque can be controlled separately and this mechanism is described in Fig. 5.
Fig. 5: Clarke and Park transformation used for Field Oriented ControlStarting from a 3-phase PMSM standard mathematical model that is described by 3 differential equations in a fixed reference system, we can perform a simple Clark transformation to reduce the number of equations and then have them translated using Park transformation from a time domain into a Laplace domain where the model can be described by 2 simple linear algebraic equations as shown in Fig. 6.
Fig. 6: PMSM mathematical model simplified with Clarke and Park transformationsThat's the beauty of Field Oriented Control.
We hope you find this information useful. Feel free to LIKE this article and comment below.
If you are looking for more details, kindly visit Agricultural Ceiling Fans.