PFC:800WPSUC7-4pin
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
controller_PI Struct Reference

#include <init_bckgnd_funct.h>

Data Fields

int32_t a0
 
int32_t a1
 
int32_t a2
 
int32_t aux
 
uint8_t qformat
 
uint8_t shift_to_q13
 
uint8_t shift_to_q29
 
int32_t state_output [3]
 
int16_t * duty_iL
 
uint16_t duty_ff
 
int16_t duty
 
int32_t state_error [3]
 
int16_t max_duty
 
uint16_t PI_ref
 
uint32_t PI_ref_int
 
uint16_t PI_ref_max
 
int32_t interm_calc1
 
int32_t interm_calc2
 
bool double_freq
 

Detailed Description

Controller structure for current loop

Field Documentation

int32_t controller_PI::a0

PI 'k' error coefficient. Q14 format.

int32_t controller_PI::a1

PI 'k-1' error coefficient. Q14 format.

int32_t controller_PI::a2

PI 'k-2' error coefficient. Q14 format.

int32_t controller_PI::aux

Auxiliary variable for coefficient calculation. Q14 format.

bool controller_PI::double_freq

Flag for switching frequency change

int16_t controller_PI::duty

Duty cycle to be used in the PWM generation

uint16_t controller_PI::duty_ff

Duty cycle information obtained from the input voltage measurement (feedforward)

int16_t* controller_PI::duty_iL

Duty cycle information obtained from the state_output vector of the current loop

int32_t controller_PI::interm_calc1

Intermediate calculation for debugging

int32_t controller_PI::interm_calc2

Intermediate calculation for debugging

int16_t controller_PI::max_duty

Maximum duty cycle allowed. Q15 format?.

uint16_t controller_PI::PI_ref

Reference value. Q15 format

uint32_t controller_PI::PI_ref_int

Intermediate reference value.

uint16_t controller_PI::PI_ref_max

Maximum allowed current reference value. Q15 format

uint8_t controller_PI::qformat

Q format of the coefficients.

uint8_t controller_PI::shift_to_q13

Applicable shift to obtain Q13 output

uint8_t controller_PI::shift_to_q29

Applicable shift to obtain Q29 intermediate value

int32_t controller_PI::state_error[3]

Previous ('k'), ('k-1') and ('k-2') errors. Q15 format.

int32_t controller_PI::state_output[3]

Previous ('k'), ('k-1') and ('k-2') outputs. Q15 format.


The documentation for this struct was generated from the following file: