Online UPS Designer Reference Manual, Rev. 05-14 Freescale SemiconductorPreliminaryThe transfer function of a discrete time PI control loop is calculated by the following equation:The sine wave generated is used as the set point of the inverter control. The inverter uses theoutput voltage and current as sensing inputs to the control, which have a double control looptopology, inner PI current control and outer PID voltage control. Figure 5-10 shows the details ofthe inverter loop as implemented in the source code. Signal names are the actual variable namesin the C code.Figure 5-10. Inverter Control Loop Diagram5.6 PFC Control LoopFigure 5-11 shows the actual function implementation of the PFC control loop. It consists of twocontrols: One to control the rail-to-rail voltage and another to control the current drawn to the ACmain line. The current set point for the inner loop is the AC line voltage times a factor linearlyproportional to the error signal at the rails (and finally dependent on the UPS load current). Thehardware implementation in this UPS (please refer to Figure 5-11) requires the inner control towork with the absolute values of the signals in order to avoid discontinuities at the current controloutput.Both control loops use Proportional–Integral (PI) compensators, implemented with 32-bitintegrators. The Z domain transfer function of a PI compensator is:TIP K1ZZ*KK)Z(C ⎥⎦⎤⎢⎣⎡−+=PLL SinTableLookup xInverter_SoftStart(0 to 1 in 1.6 sec)INVERTER_OUTPUTSETTINGΣPID ControlwithSaturation Function+++PIDΣ Σ +Σ+PIGain = 0.475Shift = 1Gain = 0.9Shift = 2Gain = 0.25Shift = 1Gain = 0.38Shift = 5DisconnectIntegrator if|output|greater than0.833Gain = 0.3Shift = 1Gain = 0.35Shift = 2Gain = 0.04PWMActuator &SwitchingNetworkInductanceCapacitorand Load+--+PI ControlwithSaturation FunctionUPS_OutputVoltageUPS_OutputCurrentPLL SinTableLookup xInverter_SoftStart(0 to 1 in 1.6 sec)INVERTER_OUTPUTSETTINGΣPID ControlwithSaturation Function+++PIDΣ Σ +Σ+PIGain = 0.475Shift = 1Gain = 0.9Shift = 2Gain = 0.25Shift = 1Gain = 0.38Shift = 5DisconnectIntegrator if|output|greater than0.833Gain = 0.3Shift = 1Gain = 0.35Shift = 2Gain = 0.04PWMActuator &SwitchingNetworkInductanceCapacitorand Load+--+PI ControlwithSaturation FunctionUPS_OutputVoltageUPS_OutputCurrentTIP K1ZZ*KK)Z(C ⎥⎦⎤⎢⎣⎡−+=