IDACIM #
Brief #
idacim identifies an AC induction motor. A standstill test measures the stator resistance r (with the inverter dead time voltage drop separated from it), the leakage inductance l (sigma*Ls) by injection at two frequencies around the current loop’s crossover, and the rotor time constant tr and rotor side magnetizing inductance lmr (Lm^2/Lr) by d current steps; an optional current ladder (knee) fits how tr changes with flux. From these and the motor plate it computes a vf parameter set. An optional rotating test spins the rotor open loop; with an encoder it first reads tr and the inertia from up and down speed ramps at two currents, can check tr with the rotor turning under FOC (rot_tr_vel), then sweeps the flux, each level at the ramps’ top emf and at half that speed, and fits the magnetizing curve (acim_flux0.lmr, lmr_sat, i_knee, tr_sat, i_dip, lmr_dip, tr_dip, acim_foc0.id_n). A separate pole pair test reads conf0.polecount and the direction. It runs on the F4 board, drives hv0 directly and is loaded by the id_acim template.
Component Explanation #
- Before you start:
test_curmust be underconf0.max_ac_cur. The r chord’s dead time correction needs every phase above about 2 A in the lower dwell (test_cur / 2on d is-test_cur / 4on v and w), and the rotor test steps between the same two levels, solmrandlsare read overtest_cur / 2 .. test_cur. No test level should go underi_min, where the dead time distorts the voltage: the console warns iftest_cur < 2 * i_min. For the V/f set, atest_curnear the resultingid_nis best (the report says when to rerun).- If you have a four wire measurement of the winding resistance, set
idacim0.r_knownto it: r is then taken as given and only the dead time drop is read. - For the V/f set give the plate:
n_volt,n_freq,n_curandn_pp. Without all four the V/f set is skipped; the rotating test needs at leastn_freqandn_pp, and the tr knee fit needsid_nfrom the V/f set. spin = 1goes on to the rotating test after the standstill test. That test turns the rotor, so the shaft must be free and unloaded.knee = 1adds the tr ladder to the rotor test (see 5.). It needstest_cur >= 1.5 * i_min / 0.7(about 8.6 A with the defaulti_min), otherwise the console says there is no range and no ladder runs.- The template sets
hv0.drop_k = 0(no dead time compensation) for the run: the r fit and the dead time drop are read fromud_fb. - While the state is 0 the nrt function resets
r0.1 ohm,l1 mH,drop0,r_ok,l_ok,tr_okandout_rev0,cur_bw1. The parameters keep their values.
- How to run it:
- At the console,
link id_acim. The template loadsidacimand wiresidacim0.en = fault0.en_out, setsfault0.pos_error = 0andpid0.en = 0, connectshv0.en,cur_bw,cmd_mode,d_cmd,q_cmd,pos,vel(fromcom_vel),rev,r,l,psito this component (hv0.lq = 0) andhv0.ud_fb,id_fb,uq_fb,iq_fb,pwm_volt,dc_volt,conf0.cur_bw(asloop_bw),vel1.velandfb_switch0.vel_fb(aspos_fb, the encoder position without offset) back into it.hv0.r/hv0.lare this component’sr/l, so they are the current loop’s plant model during the tests. - Enable the drive. The rotor may stay free for the standstill test: a dc field and a single pulsating axis make no torque on a cage. The state goes
0->1.0->1.1and the console asks foridacim0.state = 1.2.enlow returns to0from any state. - The standstill test runs r (
1.2, 4 s), leakage (1.3, a few s) and the rotor test (1.4, about(1 + 2 * rot_cycles) * rot_halfat most, shorter once tr is known, plus each ladder rung). State1.5prints the results and goes to3.0(done), to4.0ifspinis set, or back to0if r failed. Append the printed lines to the config and save. - Rotating test:
4.0(set it by hand after a standstill test in the same enable, or viaspin) checks thattr_ok,n_freqandn_ppare there, prints the top speeds of the ramps, the flux sweep and the tr check, and asks foridacim0.state = 4.2. It ends in5.0. - Pole pair test: set
idacim0.state = 2by hand; it asks to unblock the rotor and foridacim0.state = 2.2, and ends in3.0.
- Resistance (
state1.2):
- Current mode,
cur_bw1, current on the d axis atcom_pos = 0: 2 s attest_cur, then 2 s attest_cur / 2.id_fb/ud_fbof each dwell are low-passed (0.001 per tick) intotmp2/tmp3(top) andtmp0/tmp1(half). Meanwhilertracksud_fb / id_fbso the current loop can build up voltage at all. ud_fbcontainsr * id + 4/3 * drop(dead time; at angle 0 the phase currents are id, -id/2, -id/2). After 4 sfit_di = tmp2 - tmp0and the chordr_2p = (tmp3 - tmp1) / fit_di(only iffit_di > 0.01A) are computed, andris taken from one of two modes:r_known > 0:r = r_known,drop = 0.75 * (tmp3 - r * tmp2). Needs the top dwell to reach half oftest_cur.- default:
r = r_2p - r_biaswithr_bias = drop_slope * dc_volt / test_cur(0 ifdc_voltis not wired),dropas above. The dead time drop rises roughly as ln(i), which biases the chord;drop_slopewas fitted on one bridge. r_okis set if the chosen mode produced a value. Thenavg_test_volt = r * test_cur + 4/3 * drop(limited topwm_volt / 2) and the state goes to1.3, or straight to1.5ifr_okis 0.
- Leakage inductance (
state1.3):
- Voltage mode,
cur_bw1:d_cmd = avg_test_volt + amp * sin(w t). The dc bias holds abouttest_curon d, so every phase current stays on one side of zero and the dead time is only an offset. The first settle is 1 s (the bias settles on the slow rotor pole), after a frequency change 0.2 s. - The pair of frequencies sits on either side of the current loop’s crossover
f_c = loop_bw / 2 pi. At acur_bwof 1000 the default pair is 120 / 240 Hz. Both are rounded to multiples of 20 Hz, so every window holds whole cycles, and kept within 20 Hz ..0.2 / period. The leakage of a cage rotor has no plateau over frequency, so this is the bandconf0.lhas to describe. - At each frequency 4 blocks of 50 ms size the amplitude so the injected current is
l_ripple * test_cur, then about 0.4 s (a whole number of cycles, counted in samples) demodulateud_fbandid_fb, with the dc bias taken out of both (the mean times the reference sums, as inidpmsm), into the impedancel_za/l_zb(corrected for the zero order hold of the command) and the current reached,l_ia/l_ib. No resistance goes in:
l * l = (zb * zb - za * za) / (wb * wb - wa * wa);
l_resis the resistance (stator plus cage) the pair implies.l_okneeds a positive l^2 and both currents within 0.5..2 times the target. If the reactance at the upper frequency is under2 * l_res(small leakage, as on high speed spindles), the pair moves up an octave, at most 3 times and while the upper one stays under0.2 / period;l_fa/l_fbare the pair used.l = sqrt(l^2)ifl_ok, else 1 mH (then measure line to line near 150 Hz with an LCR meter and halve it). The state goes to1.4.
- Rotor time constant and magnetizing inductance (
state1.4):
- Current mode at
cur_bw = rot_bw,com_pos = 0:d_cmdsteps betweentest_curandtest_cur / 2,1 + 2 * rot_cycleslevels. The first level only magnetizes. Each level lastsrot_halfuntil an edge has given a tr, then16 * trof the last fit (at least 0.1 s). - The rotor flux follows the stator current with
tr = Lr/Rr, and its emflmr * d(i_mr)/dtappears inud_fbon top ofr * id, the dead time andl * d(id)/dt. Integrated from the edge, withcthe offsetud - r idwhere the edge settles:
lam(t) = integral(ud - r * id - c) - l * (id - i0) = lmr * (i_mr - i0);
integral(lam) = lmr * integral(id - i0) - tr * lam;
- This is fitted by least squares on the current that actually flowed, from
rot_t0(skips the current loop’s settling) to the end of the edge, withlmr,trand the edge’s own offsetcas unknowns (Gauss-Newton in nrt, started from the median of 8 block means over the last quarter).r_2p(orr) is used for r, because the chord takes the dead time out at exactly these two levels. A median of three filters single bad samples; the sums take every 8th tick. An edge counts if it moves the current by more than 10 % of the level; nrt prints one# edgeline per edge. - At the end the rising and falling edges are reduced apart:
tr_rise/tr_fallare their medians,trtheir mean (this cancels the asymmetry a step into saturation causes),tr_spreadthe worse direction’s (max - min) / median,tr_min/tr_maxthe extremes.lmris the median of the falling edges only (rising ones read low near saturation).tr_okiftris over5 * periodand under the start of the last edge’s settled tail (0.75 of its length); thenslip_n = 1 / trandls = l + lmr, otherwise these are 0 (tris reported either way). - Offset ladder (
lad_top > 0): after the main test, rung k oflad_nrepeats the steps between its top andlad_ratiotimes it, and stores its top current,lmrslope,trand spread inlad_i,lad_lm,lad_tr,lad_sp. knee = 1(withlad_top0) writes the ladder itself at the start of a run:lad_ratio0.7,lad_bot = max(0.4 * test_cur, i_min / 0.7),lad_top = test_cur,lad_n4, and records it inlad_auto. A ladder the knee wrote is replaced or dropped on the next run; one set by hand stays.
- Report and V/f set (
state1.5, nrt):
- Waits until nrt has reduced the last rung. If
r_ok: printsconf0.r,conf0.l(or why l failed), and iftr_okalsoacim_flux0.tr,acim_flux0.lmrand the slip foracim_ttc(vel_n = (2 pi freq_n - slip_n) / polecount), with warnings fortr_spread > 0.25androt_dip > 0.1(raiserot_bw). - With
tr_okand all four plate pins the V/f set:u = n_volt * sqrt(2/3),w = 2 pi n_freq,id_n = u / sqrt(r^2 + w^2 ls^2),iq_n = sqrt((sqrt(2) n_cur)^2 - id_n^2). It printsconf0.polecount = n_ppandvf0.u_n = u,vf0.vel_n = w / n_pp,vf0.u_boost = r * id_n + 4/pi * drop(V/f runs in volt mode with no dead time compensation, and a rotating vector loses the square wave’s fundamental, 4/pi of the per phase drop; on the spindler * id_nalone, 3.7 V, stalled and 12 V started),vf0.boost_vel(wherew ls = 3 r, clamped to 2..20 % ofw, per pole pair),vf0.slip_n = iq_n / (tr * id_n) / n_pp,vf0.cur_n = iq_n, andacim_foc0.id_nas a start value. The same values are on thevf_*,id_nandiq_npins. - With a ladder it prints a table per rung (range, lmr slope, tr, spread; with
lad_bot0 andlad_ratio0.5 also psi_r and the secant lmr, integrated from the slopes), then the tr knee fit: acim_flux’s modeltr * (1 + tr_sat * x),x = (id_n - i) / (id_n - i_knee)clamped 0..1, fitted over the rungs (only those with an lmr, a lower current of at leasti_minand spread up to 0.3, each at the middle of its range) and the main test (at0.75 * test_cur), weighted by 1 / spread^2, for everyi_kneefrom 0 to 0.9id_nin 1 % steps. It needsid_nand three levels. It is rejected iftr_satis outside 0..1 or tr atid_nis more than 30 % off the main test’s tr; otherwiseknee_i,knee_tr_sat,knee_trare set and it printsacim_flux0.tr(tr atid_n, replacing the one above),acim_flux0.i_kneeandacim_flux0.tr_sat. - Then the dead time
drop, which is also part ofvf0.u_boost. - If
r_okis 0 it prints why the r test failed and returns to state 0 (withenstill high, straight back to the 1.1 prompt).
- Rotating test (
state4.2 to 4.7), rotor free, no load:
- Current mode at
cur_bw = rot_bw,d_cmd = id_n(ortest_curwithout the V/f set), andcom_posturns open loop.4.2: the field ramps atrot_acctorot_velof plate speed and holds 1 s. Ifvel_fbis within 20 % of the field,rot_enc = 1; if the rotor turns but lags more, it pulled out and the test ends (4.6). The order is then4.4ramps,4.5tr check (ifrot_tr_vel > 0),4.3flux sweep,4.6,4.7; without an encoder4.2goes straight to the sweep. - In every state but
4.5a slow integrator (20 /s) trimsd_cmd(within 25 % of its target) andq_cmd(within 10 % of the d target) untilid_fbis on target andiq_fbis 0: the current loop leaves an error at speed that differs between an up and a down ramp (simulated: id 19.2 / 19.7 A for 20.4, iq 0 / 0.2 A), and with the trim both ramps see the same flux and current. psi(tohv0.psi, curpid’s emf feed forward and predictor) is the rotor flux from the emf,abs(e) / wwithe = u - r i - j w l i, low passed over 20 ms while the field turns faster than 0.1 of plate speed, starting fromlmr * id_n. It does not come fromacim_flux0, whose low flux shape is what this test is after (on the spindle that read 0.075 for 0.107 Vs at 6.9 A, and the predicted iq ran 4 A off at 780 rad/s el).com_velgiveshv0.velthe frame’s own speed: the rotor’s speed has the wrong sign on a motor that turns against the field (out_rev = 1), and hv0 then advanced the frame the wrong way and the F3 decoupled against the emf (the spindle ran iq -3..-12 A for 0 commanded).4.4ramps, only withrot_enc: two pairs, the first atid_n, the second at 0.65id_n(at leasti_min). Each pair holds until the rotor flux has settled (max(6 tr, 0.5 s)), ramps up fromrot_veltow_hi = min(2 rot_vel, 0.9)of plate speed, holds 0.5 s and ramps back down. Over the middle half of each ramp it averages the air gap torque (stator power less copper loss, over the field speed: no tr in it), the slip againstvel_fb, the slip against the encoder position (mean field speed lesspptimes the position travelled over the time), the rotor flux on d ((uq - r iq) / w - l id),id_fband the acceleration. A slip x tr over 1 ends the ramps (pulled out).- tr from the ramps: with the current on d the rotor flux lags it by
atan(ws tr), so the torque is1.5 pp psi_d id ws tr. Up minus down, the air gap torque holds no friction, iron loss, r or dead time error (same speeds, flux and current on both):dT = psi_d id tr dws. The measured slip, though, is the field’s commanded speed against the encoder’s, which comes back a delay D later, so each pair’s slip difference also carriespp (alpha_up - alpha_down) D(simulated: about 1 ms, 23 % ofdwsatid_n). That part does not scale with the flux, so the two pairs give both:
dws_m_k = dT_k / (psi_d_k * id_k * tr_k) + pp * dalpha_k * D; // tr_k = tr * lmr_k / lmr_0
- The 2x2 solve needs the pairs to differ enough in flux (determinant over 0.2 of
a0 b1); D goes torot_delayand a tr within 0.3..3 times the standstilltrtorot_tr_ramp, with the first pair’s lmr times1 + (ws tr)^2. From then on the sweep uses this tr and lmr in place of the standstill ones. (The standstill steps read the spindle’s tr as 0.078-0.093 s, where its orientation needs about 0.12 at every flux.) 4.5rotating tr check, after the ramps whenrot_tr_vel > 0(off by default; the rotor runs up torot_tr_vel): FOC on the encoder with the test’s own rotor flux model at the standstill tr (i_mrlow passed fromid_fbwith tr,slip = iq / (tr i_mr)). The frame turns with the encoder position plus that slip, not withvel_fb, whose lag on a ramp is a frame speed error as large as the one looked for (vel1: 1.8 ms; simulated k 0.99 from the true angles for 1.06). The d current is held at what gives 0.8 of the plate emf atrot_tr_vel(at least 1.5i_min, at mostid_n; a flux that follows the speed tilts the angle with the ramp’s sign, simulated k 0.87 for 1), andq_cmd = +-ia(min(0.6 id_n, sqrt(imax^2 - id^2)), no speed loop) ramps the rotor up torot_tr_veland down to 0.7 of it. After one unmeasured pair, 3 pairs are measured where the speed is between 0.76 and 0.94 ofrot_tr_veland at least3 trinto the ramp.- There the emf is large against the dead time and r errors, so
e = u - r i - j w l i = j w psi_rgives the flux angle in the frame (the dead time loses 4/pi ofdropalong the current and is taken out; simulated k 0.975 for 1.056 without it). With the model’s tr off byk = tr_true / trthe frame settles wheretan(phi - delta) = k tan(phi)(phi the current’s angle, delta the flux’s). An offsetbon the angle (dead time, voltage timing) is the same on the up and the down ramp, where phi changes sign, sobis found by bisection where both ramps give the samek; this needs at least 100 samples on each ramp and phi of opposite sign. Akin 0.3..3 givesrot_tr = k tr,rot_tr_k,rot_tr_imr,rot_tr_lmr(abs(e) / w / i_mr) androt_tr_b; they are printed as comments only. The report also gives the same without the dead time correction and a torque balance(T_up - T_down) = J (a_up - a_down)withT = 1.5 pp psi abs(i) sin(phi - delta), whose J againstrot_jtells which flux angle is right. - Then
q_cmd = -iabrakes the rotor (d current rising to keep 0.8 of the plate emf) until it is underrot_velof plate speed, where the open loop field takes over at the rotor’s speed and the sweep starts. A ramp that does not reach its end within 15 s goes on to the next phase; 30 s without getting underrot_velswitches the bridge off, the rotor coasts and the state goes to4.7. 4.3flux sweep: d current at 1.15, 1.0, 0.9, 0.75, 0.6, 0.45, 0.35, 0.25 ofid_n, from the top down, limited toi_min..0.85 * sqrt(2) * n_cur(levels that would repeat a limit are skipped; without an encoder it stops at 0.45). With an encoder each level runs where its emf is the ramps’ top one, atw_hi * id_n / i, at mostrot_vmaxof plate speed (but not underw_hi): the field weakening range, where acim_flux uses these levels. An inverter voltage error is a larger part of a small emf; at one speed for all levels (0.4 of plate speed) the spindle read lmr at 5.5 A as 6.6 mH and 9.4 at 0.9, against about 12 from a flux observer at 838 rad/s. Without an encoder every level runs atrot_vel.- Each level settles
max(6 tr, 0.3 s)and averages 0.5 s. At no loaduq = r iq + w psi_s, so the rotor flux is(uq - r iq) / w - l id; with an encoder it is corrected for the slip angle (with tr scaled by the point’s own lmr against the lmr that tr belongs to, the ramps’ or the standstill one). A point with slip x tr over 0.35 (0.6 with the ramps’ tr, which holds further) is dropped and ends the pass; a filtered slip x tr over 1 (near pull out) ends it too. - With an encoder the same levels are read again, each at half its speed: an offset du on uq reads as du / w in the flux, so
lmr = (w1 psi1 - w2 psi2) / (w1 i1 - w2 i2)takes it out. While the field changes speed the d current isid_n(id_n * w_hi / wabovew_hi, so the emf stays at the ramps’ top), the flux settles first, and with an encoder the field waits while the slip x tr is over 0.35. Results in rising order insw_i/sw_psi(sw_npoints, at most 8). - Per point the report also lists tr from the voltages:
x_v, the tangent of the flux angle behind the current frome = u - r i - j w l i(slip x tr with no tr in it), over the encoder slip at each speed, and the two speed value(x1 - 2 x2) / (ws1 - 2 ws2), which takes out thew lmr / R_feiron loss puts onx_v. These are diagnostics only. 4.6ramps the field down to 0,4.7(nrt) reports and goes to5.0:rot_id_n, the d current where the stator flux reachesn_voltatn_freq(interpolated from the sweep, orid_nwithoutn_volt), androt_lmr, the secant there, printed asacim_foc0.id_n,acim_flux0.i_nandacim_flux0.lmr. Withrot_tr_rampit printsacim_flux0.tr, the ramps’ tr moved torot_id_nwith the secant lmr (tr follows lmr, Rr does not saturate), which replaces the standstill tr, and the field to position delay; with an encoder but no tr from the ramps it says to keep the standstill tr.- Magnetizing curve: with at least 3 points under 0.95
id_nthe secant lmr is fitted to acim_flux’s shapelmr * (1 + lmr_sat * x) * (1 - lmr_dip * y),x = (id_n - i) / (id_n - i_knee),y = (i_dip - i) / i_dip, both clamped 0..1 (growth as the iron desaturates down to the knee, flat, then a fall underi_dipat low induction), over a grid ofi_kneeandi_dip <= i_kneestarting at the lowest point; terms that come out negative are dropped. The fit is used only with an encoder,lmr_sat <= 1,lmr_dip <= 0.5and its lmr atid_nwithin 5 % ofrot_lmr: then it printsacim_flux0.lmr_sat,i_knee,tr_sat(=lmr_sat),i_dip,lmr_dipandtr_dip(=lmr_dip: tr = Lr / Rr follows the secant lmr below the dip as above the knee; on the spindle the rotating checks agree with this to a few %). Otherwiselmr_satcomes from a straight line through the lowest point at or above 0.4id_nand no knee or dip is set. Without an encoder thatlmr_satis printed to append (at least 0); with an encoder it is only printed as a comment, because the line runs through the dip and does not fit the config’s knee and dip, which stay. - With the ramps also
rot_j(inertia from the first pair’s air gap torque, printed asconf0.j),rot_j_s(the same from the position slip and the ramps’ tr, equal by construction), the friction torquerot_tfandrot_lag, the lag ofvel_fbbehind the position from the difference of their slips.
- Pole pairs and direction (
state2.2), rotor free:
2.0(nrt) clearsppand asks foridacim0.state = 2.2. For 3 s: current mode,cur_bw100,d_cmd = test_cur, andcom_posadvances open loop attest_vel, dragging the rotor along. Whileabs(vel_fb) > 0.1rad/s,ppis low-passed (0.005 per tick, starting from the first reading) fromtest_vel / vel_fb. At the end a negativeppsetsout_rev = 1, andppis rounded to an integer.2.4(nrt) printsconf0.polecountand, if reversed,conf0.out_rev = 1, ifppis at least 1, the ratio before rounding is within 0.15 of it and the rotor turned in more than 80 % of the ticks; otherwise it prints the ratio and that fraction as a failure (a slipping rotor, a load, or novel_fb). Then it goes to3.0(done).
dropis a voltage per phase; it goes intovf0.u_boostbut is not a value forhv0.drop_k(a fraction).conf0.lhere is the leakage, right foracim_foc(which carries the rotor flux inhv0.psi);acim_ttchas no flux term, so with it iq falls short at speed.tris the rotor’s at the test’s temperature and flux: a hot cage reads shorter. The rotating test usesr,l,trandlmrfrom the pins and needstr_ok;enlow resetsrandlto 0.1 ohm / 1 mH and clearstr_ok, so run it in the same enable as the standstill test. Without an encoder the sweep is not corrected for slip, so drag reads as saturation at the low points. In the pole pair test the rotor slips behind the field, sotest_vel / vel_fbreads slightly high before rounding.
Pins #
| Name | Description |
|---|---|
| d_cmd | output, d axis command to hv0.d_cmd, current (A) or voltage (V) depending on cmd_mode |
| q_cmd | output, q axis command to hv0.q_cmd (A), 0 in the standstill and pole pair tests, the slow iq trim in the rotating test and +-ia in the tr check |
| com_pos | output, commutation angle to hv0.pos (rad), 0 in the standstill tests, turns in the pole pair and rotating tests |
| com_vel | output, rate of com_pos (rad/s electrical) to hv0.vel, for hv0’s angle extrapolation and the F3 decoupling |
| cmd_mode | output, to hv0.cmd_mode, 0 = voltage, 1 = current |
| en | input, enable, from fault0.en_out; low aborts (state -> 0) |
| en_out | output, enables hv0 while a test runs |
| id_fb | input, d axis current from hv0.id_fb (A) |
| ud_fb | input, d axis voltage from hv0.ud_fb (V) |
| state | input/output, 0 off, 1.1 wait, 1.2 r, 1.3 leakage, 1.4 rotor, 1.5 report, 2.1 wait, 2.2 pp test, 2.4 print, 3 done, 4.1 wait, 4.2 spin up, 4.4 ramps (tr, inertia), 4.5 rotating tr check, 4.3 flux sweep, 4.6 spin down, 4.7 report, 5 done |
| timer | output, time in the r and pole pair tests (s) |
| r | output, measured resistance (ohm), to hv0.r, 0.1 while idle, result for conf0.r |
| l | output, measured leakage inductance sigma*Ls (H), to hv0.l, 1 mH while idle or if not measured, result for conf0.l |
| l_ok | output, 1 = l is a measurement, 0 = it is not |
| l_freq_a | parameter, leakage test, lower injection frequency (Hz), 0 = 0.75 loop_bw / 2 pi, default 0 |
| l_freq_b | parameter, leakage test, upper injection frequency (Hz), 0 = 1.5 loop_bw / 2 pi, default 0 |
| loop_bw | input, the run’s current loop bandwidth from conf0.cur_bw (rad/s), sets the leakage test frequencies, 0 = 1000 |
| l_ripple | parameter, leakage test, injected current as a fraction of test_cur, default 0.15 |
| l_za | output, impedance magnitude at l_fa (ohm) |
| l_zb | output, impedance magnitude at l_fb (ohm) |
| l_ia | output, injected current amplitude reached at l_fa (A) |
| l_ib | output, injected current amplitude reached at l_fb (A) |
| l_res | output, resistance the two frequencies imply, stator plus cage (ohm) |
| l_fa | output, lower injection frequency used (Hz) |
| l_fb | output, upper injection frequency used (Hz) |
| rot_half | parameter, rotor test, longest time at each current level (s), default 1.5 |
| rot_cycles | parameter, rotor test, measured cycles of two edges each, default 4, at most 16 |
| rot_bw | parameter, current loop bandwidth of the rotor and rotating tests (rad/s), default 1500 |
| rot_t0 | parameter, rotor test, fit starts this long after each edge (s), default 0.015, kept under tr / 5 |
| tr | output, rotor time constant Lr/Rr, mean of tr_rise and tr_fall (s), result for acim_flux0.tr |
| slip_n | output, 1/tr, slip constant (rad/s electrical), 0 = not measured |
| lmr | output, rotor side magnetizing inductance Lm^2/Lr, median of the falling edges (H), result for acim_flux0.lmr |
| ls | output, stator inductance l + lmr (H) |
| rot_n | output, edges that went into tr and lmr |
| rot_dip | output, largest current error at rot_t0, fraction of the step |
| tr_ok | output, 1 = tr, slip_n and lmr are measurements |
| tr_spread | output, (max - min) / median of tr, the worse of the two directions |
| tr_rise | output, median tr of the edges up to test_cur (s) |
| tr_fall | output, median tr of the edges down to test_cur/2 (s) |
| tr_min | output, shortest tr of all edges (s) |
| tr_max | output, longest tr of all edges (s) |
| lad_top | parameter, offset ladder, top current (A), 0 = no ladder, default 0 |
| lad_n | parameter, offset ladder, rungs (at most 4), default 4 |
| lad_bot | parameter, offset ladder, lowest rung’s top (A), rungs evenly from here to lad_top, 0 = lad_top k/n |
| lad_ratio | parameter, offset ladder, rung’s lower current over its top, 0 = 0.5, else clamped 0.3 to 0.9 |
| lad_i0 | output, ladder rung upper current (A) |
| lad_i1 | output, ladder rung upper current (A) |
| lad_i2 | output, ladder rung upper current (A) |
| lad_i3 | output, ladder rung upper current (A) |
| lad_lm0 | output, ladder rung lmr, the slope of rotor flux over the rung (H), 0 = no fit |
| lad_lm1 | output, ladder rung lmr, the slope of rotor flux over the rung (H), 0 = no fit |
| lad_lm2 | output, ladder rung lmr, the slope of rotor flux over the rung (H), 0 = no fit |
| lad_lm3 | output, ladder rung lmr, the slope of rotor flux over the rung (H), 0 = no fit |
| lad_tr0 | output, ladder rung tr (s) |
| lad_tr1 | output, ladder rung tr (s) |
| lad_tr2 | output, ladder rung tr (s) |
| lad_tr3 | output, ladder rung tr (s) |
| lad_sp0 | output, ladder rung tr spread |
| lad_sp1 | output, ladder rung tr spread |
| lad_sp2 | output, ladder rung tr spread |
| lad_sp3 | output, ladder rung tr spread |
| i_min | parameter, lowest current any test level may use, under it the dead time distorts the voltage (A), default 4 |
| knee | parameter, 1 = run the ladder for the tr knee fit, from 0.4 test_cur to test_cur (unless lad_top is set), default 0 |
| lad_auto | output, lad_top the knee wrote, cleared on the next run, 0 = none |
| knee_i | output, i_knee for acim_flux0 from the ladder’s tr (A), 0 = not fitted |
| knee_tr_sat | output, tr_sat for acim_flux0 from the ladder’s tr |
| knee_tr | output, tr at id_n from the knee fit (s), result for acim_flux0.tr when fitted |
| drop | output, dead time voltage per phase at the top dwell (V), 4/pi of it goes into vf_boost |
| r_known | parameter, known winding resistance (ohm), 0 = fit it, default 0 |
| fit_di | output, current difference of the two r dwells (A) |
| r_2p | output, two dwell chord slope (ohm), 0 = the fit did not run, also r of the rotor test |
| drop_slope | parameter, chord dead time bias (ohm A per volt of dc link), default 0.0039 |
| r_bias | output, bias subtracted from the chord to get r (ohm) |
| r_ok | output, 1 = this run produced a resistance |
| pp | output, measured pole pairs from the pole pair test, result for conf0.polecount |
| out_rev | output, 1 = motor turns backwards, to hv0.rev, result for conf0.out_rev |
| spin | parameter, 1 = go on to the rotating test after the standstill test (turns the rotor), default 0 |
| n_volt | parameter, plate voltage, line to line rms (V), 0 = not given |
| n_freq | parameter, plate frequency at that voltage (Hz), 0 = not given |
| n_cur | parameter, plate current, rms (A), 0 = not given |
| n_pp | parameter, plate pole pairs (poles / 2), 0 = not given |
| id_n | output, magnetizing current at plate voltage and frequency (A peak), V/f set |
| iq_n | output, active current at plate current (A peak), V/f set |
| vf_u_n | output, for vf0.u_n, phase peak voltage at vf_vel_n (V) |
| vf_vel_n | output, for vf0.vel_n (rad/s mechanical) |
| vf_boost | output, for vf0.u_boost, r id_n + 4/pi drop (V) |
| vf_boost_vel | output, for vf0.boost_vel (rad/s mechanical) |
| vf_slip_n | output, for vf0.slip_n, slip at vf_cur_n (rad/s mechanical) |
| vf_cur_n | output, for vf0.cur_n, active current at plate current (A peak) |
| test_cur | parameter, highest current of the standstill test (A peak), default 8 |
| test_vel | parameter, field speed of the pole pair test (rad/s electrical), default 50 |
| vel_fb | input, mechanical velocity from vel1.vel (rad/s) |
| pos_fb | input, rotor position without offset from fb_switch0.vel_fb (rad mechanical), slip of the ramps and frame of the rotating tr check |
| psi | output, rotor flux to hv0.psi for curpid’s emf feed forward and predictor (Vs), abs(emf) / w low passed in the rotating test, set to 0 when the standstill or the rotating test starts |
| uq_fb | input, q axis voltage from hv0.uq_fb (V), rotating test |
| iq_fb | input, q axis current from hv0.iq_fb (A), rotating test |
| rot_vel | parameter, rotating test speed, fraction of plate speed (0.05 to 0.45), default 0.4 |
| rot_acc | parameter, rotating test ramp (rad/s^2 electrical), 0 = plate speed in 5 s, default 0 |
| sw_n | output, flux sweep points taken |
| sw_i0 | output, flux sweep magnetizing current, rising (A) |
| sw_i1 | output, flux sweep magnetizing current, rising (A) |
| sw_i2 | output, flux sweep magnetizing current, rising (A) |
| sw_i3 | output, flux sweep magnetizing current, rising (A) |
| sw_i4 | output, flux sweep magnetizing current, rising (A) |
| sw_i5 | output, flux sweep magnetizing current, rising (A) |
| sw_i6 | output, flux sweep magnetizing current, rising (A) |
| sw_i7 | output, flux sweep magnetizing current, rising (A) |
| sw_psi0 | output, flux sweep rotor flux (Vs peak) |
| sw_psi1 | output, flux sweep rotor flux (Vs peak) |
| sw_psi2 | output, flux sweep rotor flux (Vs peak) |
| sw_psi3 | output, flux sweep rotor flux (Vs peak) |
| sw_psi4 | output, flux sweep rotor flux (Vs peak) |
| sw_psi5 | output, flux sweep rotor flux (Vs peak) |
| sw_psi6 | output, flux sweep rotor flux (Vs peak) |
| sw_psi7 | output, flux sweep rotor flux (Vs peak) |
| rot_id_n | output, d current for plate flux at plate voltage and frequency (A), result for acim_foc0.id_n and acim_flux0.i_n |
| rot_lmr | output, secant lmr at rot_id_n (H), result for acim_flux0.lmr |
| rot_lmr_sat | output, saturation from the sweep, result for acim_flux0.lmr_sat (and tr_sat with a knee) |
| rot_i_knee | output, knee current from the sweep (A), result for acim_flux0.i_knee, 0 = not fitted |
| rot_i_dip | output, dip current from the sweep (A), result for acim_flux0.i_dip, 0 = no dip |
| rot_lmr_dip | output, dip depth from the sweep, result for acim_flux0.lmr_dip |
| rot_j | output, inertia from the ramps via the air gap torque (kg m^2), 0 = no encoder, result for conf0.j |
| rot_j_s | output, inertia from the ramps via the position slip and the ramps’ tr (kg m^2) |
| rot_tf | output, friction torque in the ramps speed range (Nm) |
| rot_enc | output, 1 = vel_fb followed the field, so slip can be read (ramps, tr check, sweep correction, second speed) |
| rot_tr_vel | parameter, top speed of the rotating tr check (rad/s mechanical), needs an encoder, 0 = skip the check, default 0 |
| rot_tr | output, tr from the rotating check at rot_tr_imr, rot_tr_k x tr (s), 0 = not run or no solution |
| rot_tr_k | output, rot_tr over the standstill tr |
| rot_tr_imr | output, magnetizing current the check ran at (A) |
| rot_tr_lmr | output, lmr at rot_tr_imr from the emf (H) |
| rot_tr_b | output, flux angle offset shared by the up and down ramps (rad) |
| rot_tr_ramp | output, tr at the ramps’ current (id_n) from the open loop ramps (s), 0 = not measured, moved to rot_id_n for acim_flux0.tr |
| rot_lag | output, lag of vel_fb behind pos_fb on the ramps (s) |
| rot_delay | output, delay from field command to position feedback found on the ramps (s) |
| rot_vmax | parameter, highest field speed of the flux sweep with an encoder, fraction of the plate speed, default 1 |
| pwm_volt | input, usable voltage from hv0.pwm_volt (V), limits avg_test_volt and the injection |
| dc_volt | input, dc link voltage from hv0.dc_volt (V), scales r_bias |
| cur_bw | output, current loop bandwidth to hv0.cur_bw (rad/s) |
| tmp0 | output, filtered id_fb of the half current dwell (A) |
| tmp1 | output, filtered ud_fb of the half current dwell (V) |
| tmp2 | output, filtered id_fb of the full current dwell (A) |
| tmp3 | output, filtered ud_fb of the full current dwell (V) |
| avg_test_volt | output, voltage that holds test_cur incl. dead time, dc bias of the leakage test (V) |
References #
Source: .c File