User Manual

Table Of Contents
Brushless Motor Connections and Operation
122 Advanced Digital Motor Controller User Manual V2.1, December 3, 2020
Or by sending the configuration command for dual Channel Controllers:
^KPF 1 nn = Proportional Gain for Channel 1 Flux
^KPF 2 nn = Proportional Gain for Channel 2 Flux
^KPF 3 nn = Proportional Gain for Channel 1 Torque
^KPF 4 nn = Proportional Gain for Channel 2 Torque
^KIF 1 nn = Integral Gain for Channel 1 Flux
^KIF 2 nn = Integral Gain for Channel 2 Flux
^KIF 3 nn = Integral Gain for Channel 1 Torque
^KIF 4 nn = Integral Gain for Channel 2 Torque
Where nn = Gain * 1000000, e.g. 12500000 = 12.5 (on version 2.x of firmware)
FOC Gains Determination & Tuning
Good PI gains are important for the controller to quickly reach and stabilize the desired Id
and Iq current. A very good approximation of the gain values can be calculated from the
motor’s Resistance and Inductance using the formulas:
Flux Proportional gain = Motor Phase Inductance(Henry) * Bandwidth
Flux Integral gain = Motor Phase Resistance(Ohm) * Bandwidth
Bandwidth is in rad/sec and according to Nyquist criteria the current loop bandwidth can-
not be more than the half of the current loop sampling time. Most commonly the current
loop bandwidth is set to the 1/10-1/20 of the current loop sampling time. The current loop
sampling time is at 1kHz. So if we choose as current loop bandwidth the 50Hz then:
1Hz = 2π rad/sec
So for 50Hz Bandwidth = 50*2π rad/sec = 314.
Usually even smaller bandwidth can be as effective as the 50Hz. It is better to start with
the smaller possible gains and then tune according to the behavior of the motor. Test in
open loop with caution.
Example calculation for 50Hz bandwith, 11mOhm Phase resistance and 90uH Phase In-
ductance
Ki = 0.011 * 314 = 3.45
Kp = 0,00009 * 314 = 0.028
The FOC Proportional and Integral gains for brushless dc motors could be automatically
calculated from “Motor characterization” tool at Roborun+ (see Roborun+ Utility User
Manual for more details).