introduction
Compared with linear power supplies, switching power supplies have many advantages: because the main power transistor works in a switching state, its loss is small and the overall efficiency is greatly improved; the use of ferrite high-frequency transformers greatly reduces the size and weight of the power supply, and the cost is lower. The emergence of some dedicated power supply chips such as TL494 and UC3842 also makes the design of switching power supplies simpler and reliable. However, the output of a switching power supply made only with dedicated chips is usually a single state. If the output state is to be changed, the hardware circuit must be modified. The author designed and implemented a digital switching power supply controlled by a single-chip microcomputer, which effectively improved the above problems.
1 Design principle of digital switching power supply
The digital switching power supply designed by the author has a rated power of 12OW. The system uses the switching power supply as the basic circuit and a high-performance single-chip microcomputer as the control system. With the support of the control algorithm, the output voltage and current are sampled in real time and compared with the given values of the software to control and adjust the working state of the switching power supply to obtain the expected value. It mainly includes five parts: input rectification and filtering correction, power conversion, auxiliary power supply part, drive circuit, and single-chip microcomputer control system. The power conversion part adopts a single-ended flyback conversion circuit. The auxiliary power supply provides power for the drive circuit. The drive circuit amplifies the PWM signal from the single-chip microcomputer and drives the main power transistor. The single-chip microcomputer system is the control core of the entire circuit. The duty cycle of the output PWM is controlled in real time through the change of the sampling value. The entire design strives to achieve the best performance and the lowest cost. Its structure is shown in Figure 1.
1.1 Main circuit analysis
The power conversion part adopts a single-ended flyback circuit, and the structure is shown in Figure 2. When the excitation pulse added to the primary main power switch tube Q1 is high level to turn on Q1, the DC input voltage is applied to both ends of the primary winding. Since the phase of the secondary winding is negative at the top and positive at the bottom, the rectifier tube D1 is reverse biased and cut off, and the primary inductor stores energy; when the excitation pulse is low level to cut off Q1, the voltage polarity at both ends of the primary winding is reversed, the phase of the secondary winding becomes positive at the top and negative at the bottom, the rectifier tube is forward biased and turned on, and the energy stored in the transformer is released to the secondary side. In this switching process, the high-frequency transformer plays both the role of voltage transformation isolation and the role of inductor energy storage.
1.2 Single-chip microcomputer control system
The single chip microcomputer control system is the core part of the entire digital power supply.
The single-chip microcomputer uses Freescale's 68HC908SR12, which has rich internal resources, integrating 12k program memory, 2-way timer/counter, 14-channel 10-bit A/D converter, PWM output, internal temperature sensor, etc. The block diagram of the single-chip microcomputer control system is shown in Figure 3.
ATD0 and ATD10 are the voltage and current sampling pins, which convert the analog quantity collected into digital quantity and send it to the CPU. The CPU makes a control adjustment every 1ms to output a PWM signal with a suitable duty cycle. The PWM signal is isolated and amplified by the drive circuit to directly control the switch tube of the main circuit. Since the 908SR12 has its own pulse width modulation module, the maximum PWM frequency reaches 125kHz, which can be fully used in high-frequency switching power supplies. The 8-bit resolution can ensure the accuracy of the output voltage and current. The keyboard part uses a contact key switch, and the user can adjust the output voltage and current value at the rated power according to their needs.
The whole circuit adopts a double closed-loop control system. Under normal circumstances, the feedback of the voltage loop keeps the output voltage constant. Once the output current exceeds the maximum value, the current loop reduces the output voltage and maintains the output current at the maximum current value. The display part can be composed of a digital tube or a liquid crystal. In this system, the voltage, current, power, temperature, electric energy metering, etc. are displayed separately through key selection, and different states are indicated by indicator lights. If an open circuit or short circuit occurs during operation, the indicator light shows an alarm state, and the CPU will immediately start the protection program to shut down the main circuit. At the same time, the internal temperature of the power supply is continuously detected to prevent the temperature of the whole machine from rising too high.
1.3 Driving circuit design
Since the 5V 1vrL level output by the microcontroller is not enough to drive the main power switch tube, and the primary and secondary sides are completely electrically isolated in the entire circuit, the PWM signal output by the microcontroller cannot be directly connected to the main power switch tube. In addition, the temperature rise of the main power switch tube directly affects the stability and service life of the entire equipment. Improving the on and off speed of the switch tube is the most essential and effective way to solve the problem of temperature rise of the switch tube. This requires the drive circuit to have the following characteristics:
(1) Ability to provide sufficiently large drive current, that is, the charging resistance of the drive circuit should be sufficiently small to shorten the conduction time;
(2) It should have sufficient discharge capacity, that is, the discharge resistance should be sufficiently small to increase its shutdown speed;
(3) Appropriate driving voltage. Generally, 12V is the most appropriate driving voltage.
Considering the electrical isolation between the primary and secondary sides, the following drive circuit is designed, as shown in Figure 4.
PWM is the duty cycle signal output by the microcontroller, which is connected to the primary side through an optocoupler, meeting the electrical isolation requirements of the primary and secondary sides. Inverter U2 realizes the conversion from TTL level to CMOS level. When the PWM signal is high, U2 outputs high level, T1 is turned on, T2 is turned off, and the driving power supply charges the gate-source capacitance of the switch tube, so that it quickly reaches the turn-on threshold voltage of the switch tube, and the switch tube is quickly turned on; when the PWM signal is low, U2 outputs low level, T1 is turned off, T2 is turned on, and the gate-source capacitance of the switch tube quickly discharges the electricity through T2, realizing the rapid shutdown of the switch tube. The driving circuit has a simple structure, stable performance and high driving speed, and can replace the more expensive driver chip.
2 System Software Process
The system flow chart is shown in Figure 5.
In order to improve the dynamic characteristics and stability of the system, the upper and lower limits of the PWM duty cycle are set in the data processing program to prevent large deviations during continuous sampling and limit the PWM. In addition, if an unexpected situation occurs, the microcontroller will turn off the PWM in time to prevent the output voltage or current from being too large and damaging the transistor.
3 Conclusion
After collecting a large amount of data for analysis, the following conclusions were drawn: When the switching power supply operates in constant voltage mode, the error between the output value and the expected value does not exceed 30mV; when operating in constant current mode, the error between the output value and the expected value does not exceed 40mA; the overall efficiency is above 85%, the temperature rise of the main power switch tube is around 40°C, and the temperature rise of the high-frequency transformer is lower than 60°C, which is fully adapted to the power supply requirements in general situations.
The switching power supply with a single-chip microcomputer as the core not only helps to improve the accuracy of the switching power supply, but also makes the switching power supply more intelligent. Intelligence is also a direction for the development of power supply in the future. Therefore, the programmable power supply with a single-chip microcomputer as the core designed in this paper has a high use value.
Previous article:Design of switching power supply based on PQ35
Next article:Design of running water lamp based on digital integrated circuit
- 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
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- How should I find the development board schematics and PCBs of major manufacturers?
- EEWORLD University ---- Wireless Power 101
- TI combines Bluetooth solution with MSP430 microcontroller
- [Erha Image Recognition Artificial Intelligence Vision Sensor] Evaluation 5: Erha Image Recognition Object Recognition
- What are the differences between wire-wound common mode inductors and chip-wound inductors?
- 【Live Replay Summary】Microchip ShieldsUP! Security Solutions Online Seminar Series (18 sessions)
- Lua script development based on serial port screen - use of pi
- NU510 can control the light strip without single chip microcomputer, dual color temperature dimming and color flow light
- TI mmWave Radar MIMO (2TX4RX) Setup
- [STM32MP157C-EV1] After the first unboxing and evaluation, I will run rtt on it and share other