Commit 54ba4c9d authored by root's avatar root Committed by Alessio Igor Bogani
Browse files

some field visualization fixes

parent 9d743a62
......@@ -21,6 +21,7 @@ FILENAME : ControlLoop.c DESIGN REF: MC18
REF NO VERSION DATE WHO DETAIL
xx 20210421 21Apr21 MC Visualization fixes
xx 20210420 20Apr21 MC Normalization coefficients
xx 20210415 15Apr21 MC importing normalized values from ReadADC
xx 20200828 28Aug20 MC Added space for Kd parameter
......@@ -31,9 +32,18 @@ FILENAME : ControlLoop.c DESIGN REF: MC18
avoid turning ON after dclink warning cleared
xx 20190108 08Jan19 MC Added DClink warning on main loop
xx 20180724 24Jul18 MC Final version with Debug added
Debug0=regulator;
Debug1=pwm1corr;
Debug2=pwm2corr;
Debug0 = regulator;
Debug1 = integrator;
Debug2 = derivator;
Debug3 = pwm1corr;
error = setpoint - ADCreadout
integrator += (Ki * error)
derivator = (error - prev-error) * Kd
regulator = ((Kp * error) + Integrator) + Derivator)
prev-error = error
*/
......@@ -303,7 +313,7 @@ void Compensator(float SP, float Iout) // PWM frequency 100kHz, control loop 50
prev_error = error; // update error for derivative part
//Debug1=pwm1corr;
Debug3=pwm1corr;
//Debug2=pwm2corr;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment