AN1905 ST Microelectronics, Inc., AN1905 Datasheet - Page 72

no-image

AN1905

Manufacturer Part Number
AN1905
Description
St7mc Three-phase BLDC Motor Control Software Library
Manufacturer
ST Microelectronics, Inc.
Datasheet
ST7MC THREE-PHASE BLDC MOTOR CONTROL SOFTWARE LIBRARY
Below is an example of the use of this regulation process.
Note: Whatever the declared number of pair poles is, the ‘Set_Target_Electrical_Frequency’ rou-
72/77
...
if (ValBit(Flag_MTC,SAMP_EVT))
...
– When tuning the PI parameters you should look for the worst case conditions, which may
–Frequency regulation output is a 10-bit variable. If the final application requires a different
– A regulation tuned in no-load condition (at the highest) will most probably be unresponsive
Tricks and traps
Implementing the closed loop regulation
resolution (involving the PI routine to be rewritten), the output might be chosen as a power
of 2 so that logical shift operations can be used as divisions (new duty = (max_duty x PI-
output)>>10 for 10-bit returned value). This will result in compact code and will reduce the
CPU time consumption while processing the PI output. To give sufficient accuracy to the
control algorithm, the returned data should not be less than an 8-bit value, and shouldn’t
be greater than 12 bits long (the same resolution as the MTC cell PWM timer).
be when the load quickly and unpredictably varies, when the inertia is at a minimum, or
when the mains voltage is maximum for an off-line application.
in the final application, and vice versa: a regulation tuned in the application may become
unstable in no-load conditions.
tine needs to be fed with an electrical frequency input. The ‘Pole_Pair_Num’ definition in
‘MTC_Settings_Sensorless.h’ or ‘MTC_Settings_Sensor.h’ file is just declared as a reference; it can
be used for example in the final application in order to display the mechanical frequency instead of
the electrical.
{
ClrBit(Flag_MTC,SAMP_EVT);
Set_Target_Electrical_Frequency((u16)(your_frequency));
}
// Sampling time elapsed? -> update PWM

Related parts for AN1905