Inverter power supply is a key component of many equipment such as uninterruptible power supply , static aviation power supply, and new energy power generation technology. In many occasions, the inverter is required to output a sine wave with low distortion, so eliminating harmonics is one of the basic requirements of the inverter power supply. The author intends to use a single-chip microcomputer as the controller, and the pulse signal generation adopts the deharmonic PWM method, and introduces its hardware and software implementation process in detail.
Detuning PWM control
One of the main purposes of using PWM control technology is to solve the harmonic problem of inverter power output. High-frequency PWM control can not only effectively reduce the harmonic content of the output voltage, but also easily adjust the size of the output voltage. The basic idea of de-harmonic control is: take the switching point phase of the PWM pulse waveform as the unknown, and obtain the expression of the fundamental component and each harmonic component of the output voltage through the Fourier series analysis of the PWM pulse. Then, according to the requirements of the amplitude of the fundamental wave and each harmonic, establish an equation group equal to the number of unknowns. By solving the equation group, the switching moment of each pulse is obtained, and the control is implemented according to the moment, then the amplitude of the fundamental wave and each harmonic of the output voltage will be the expected value. In general, the fundamental amplitude is always set to a desired non-zero value, and the magnitude of each harmonic is set to zero, so that the inverter after the de-harmonic PWM control equation will not contain the specified low-order harmonic value.
Assume that the inverter output PWM waveform has N switching points within a quarter cycle, and the phase angles corresponding to each switching point are (ai=1, 2, ..., N), and 0≤a1
Formula (1) is the expression when bipolar modulation and the number of switch angles N is an odd number, Formula (2) is the expression when bipolar modulation and the number of switch angles N is an even number, and Formula (3) is the expression when unipolar modulation. Assume that the ratio of the inverter output fundamental voltage amplitude to the input DC bus voltage is M, and assume that the PWM waveforms corresponding to Formulas (1) and (2) are used for three-phase inverters, and the PWM waveform corresponding to Formula (3) is used for single-phase inverters, then Formulas (1) to (3) can derive the corresponding detuning equations as shown in Formulas (4) to (6). Solving the above equations can obtain a set of switch angles, which are converted into a microcontroller timing count pulse data table and saved in the program memory for query during real-time control.
Control System
The control system controls and adjusts the opening and closing of the main circuit switch tube according to the requirements of the given signal, thereby controlling the main circuit to generate the desired output voltage and making the output voltage follow the given voltage signal as much as possible. Figure 1 shows the basic block diagram of the hardware circuit of the inverter power supply. The generation of the trigger pulse adopts the method of digital circuit, and its function can be fully realized by the software program of the controller, which saves costs, and compared with the analog circuit, this method has a stronger anti-interference ability.
The inverter circuit control system is based on the AVR microcontroller. Its main function is to generate the drive signal of the switch tube in the full-bridge inverter circuit, and to adjust and protect the inverter power supply by real-time sampling of the line voltage and current. For the input voltage signal on the DC bus side, after the Hall sensor is used for voltage transformation, the voltage signal is sent to the window comparator through the emitter follower composed of an operational amplifier. The upper and lower thresholds of the window correspond to the overvoltage and undervoltage limits respectively. If it is within the window range, the voltage is normal, otherwise the overvoltage or undervoltage fault signal is output; for the current signal on the DC bus side, a sampling resistor is used to measure it. The voltage across the sampling resistor is sent to the operational amplifier for amplification and anti-interference filtering, and then compared with the set overcurrent threshold to realize the alarm and processing of the inverter output or internal circuit overcurrent. The above two protection signals are sent to the external interrupt request input pin of the microcontroller after logic and processing. Regardless of the fault signal caused by any situation, an interrupt request can be made to the microcontroller. The microcontroller responds to the interrupt and realizes protection by blocking the drive signals of all switch tubes, and gives a fault indication at the same time.
The controller uses an 8-bit AVR microcontroller. The 8-bit AVR MCU has a high-speed processing capability of 1MIPS/MHz; the ultra-functional reduced instruction set (RISC) has 32 general working registers, which overcomes the bottleneck phenomenon caused by the single ACC used in 8051 MCUs; the fast access register group and single-cycle instruction system greatly optimize the size and execution efficiency of the target code; when used as an output, it is the same as the HI/LOW of the PIC, and can output 40mA (single output); when used as an input, it can be set to a three-state high-impedance input or an input with a pull-up resistor, and has the ability to sink 10~20mA current; the chip integrates multiple frequency RC oscillators, power-on automatic reset, watchdog, startup delay and other functions, the peripheral circuit is simpler, and the system is more stable and reliable; the on-chip resources are rich. The desired output frequency given value of the inverter is input into the controller in a coded manner. The CPU determines the detuning PWM control data to be selected based on the read frequency code, and through internal timing control, outputs the drive signal of the inverter bridge switch tube from the CPU I/O port according to the specified PWM data, controls the conduction and shutdown of the switching device, and realizes detuning control.
System Software
The control software of the inverter power supply consists of three parts: the main program, the timer interrupt service program, and the external interrupt service program. The main program is used to initialize the working mode of the single-chip microcomputer and read the code of the given value of the inverter power supply's expected output frequency from the I/O port. When the given output frequency changes, its code value will change accordingly. At this time, the frequency change flag is modified, and the timer interrupt service program is used to perform timing control according to the new detuning PWM switch switching data to achieve the switching of the drive signal. The timer interrupt service program mainly completes the timing control of the switch switching data, outputs the corresponding switch tube drive signal, and realizes the detuning PWM control. The external interrupt service program mainly realizes the fault protection function of the inverter power supply. When a fault interrupt request occurs, the single-chip microcomputer responds to the interrupt in time. When a fault is confirmed, the drive signal is blocked and the fault code is output.
Conclusion
This design analyzes the inverter power supply's single-chip microcomputer implementation process in a relatively detailed and comprehensive manner. While analyzing the basic principles of detuned PWM control in detail, it gives a structural diagram of the three-phase inverter power supply's main circuit, and also gives an inverter power supply hardware control circuit based on a single-chip microcomputer.
Previous article:Current status and development of small and medium power photovoltaic inverters
Next article:Solar Inverter Battery Characteristics Analysis and Description
- Popular Resources
- Popular amplifiers
- MathWorks and NXP Collaborate to Launch Model-Based Design Toolbox for Battery Management Systems
- STMicroelectronics' advanced galvanically isolated gate driver STGAP3S provides flexible protection for IGBTs and SiC MOSFETs
- New diaphragm-free solid-state lithium battery technology is launched: the distance between the positive and negative electrodes is less than 0.000001 meters
- [“Source” Observe the Autumn Series] Application and testing of the next generation of semiconductor gallium oxide device photodetectors
- 采用自主设计封装,绝缘电阻显著提高!ROHM开发出更高电压xEV系统的SiC肖特基势垒二极管
- Will GaN replace SiC? PI's disruptive 1700V InnoMux2 is here to demonstrate
- From Isolation to the Third and a Half Generation: Understanding Naxinwei's Gate Driver IC in One Article
- The appeal of 48 V technology: importance, benefits and key factors in system-level applications
- Important breakthrough in recycling of used lithium-ion batteries
- LED chemical incompatibility test to see which chemicals LEDs can be used with
- Application of ARM9 hardware coprocessor on WinCE embedded motherboard
- What are the key points for selecting rotor flowmeter?
- LM317 high power charger circuit
- A brief analysis of Embest's application and development of embedded medical devices
- Single-phase RC protection circuit
- stm32 PVD programmable voltage monitor
- Introduction and measurement of edge trigger and level trigger of 51 single chip microcomputer
- Improved design of Linux system software shell protection technology
- What to do if the ABB robot protection device stops
- Huawei's Strategic Department Director Gai Gang: The cumulative installed base of open source Euler operating system exceeds 10 million sets
- Download from the Internet--ARM Getting Started Notes
- Learn ARM development(22)
- Learn ARM development(21)
- Learn ARM development(20)
- Learn ARM development(19)
- Learn ARM development(14)
- Learn ARM development(15)
- Analysis of the application of several common contact parts in high-voltage connectors of new energy vehicles
- Wiring harness durability test and contact voltage drop test method
- Taking a “family-first” approach to op amp design
- Please check if this is the real F199C
- How to use J-Link remote debugging?
- Design of digital anti-noise module for airborne communications
- AD19, same rules, automatic routing is ok, manual routing will be short circuit and un-roated, what is the reason?
- We are looking for candidates who are proficient in zigbee!
- 【MM32 eMiniBoard Review】2a. Found that the virtual serial port may have problems, and the serial port routines cannot receive
- Help! Does anyone know what sensor this is?
- Do you usually read e-books or paper books now?
- ADC12 single channel multiple conversion routine (MSP430F5529)