In recent years, many single-chip microcomputer manufacturers, such as Atmel, Analog Devices, Intel, Philips, Dallas, Maxim, etc., have launched new high-speed single-chip microcomputers. Their instruction execution cycle is only 1/3 to 1/10 of the original, and EEPROM, WDT, A/D converter and D/A converter are integrated in the single-chip microcomputer, which greatly improves the performance of the single-chip microcomputer and facilitates users. However, the output of the D/A converter in many single-chip microcomputers adopts the form of pulse width modulation (PWM). PWM is very suitable for the control of switching power supplies, thyristors and other devices, and can also be used in occasions such as LCD brightness control and audio output that do not require accurate voltage output. Since PWM has no reference voltage, the amplitude of its output pulse is not very constant, which limits the scope of PWM. In occasions where precise control voltage output is required, such as precise adjustable voltage sources, motor inverters, etc., PWM cannot be used.
However, only two cheap integrated circuits are needed to convert the PWM output with unstable amplitude into a precise PWM output voltage.
1 Circuit Principle
The circuit principle of using a three-terminal precision reference power supply and an analog switch to obtain a voltage-precision PWM pulse is shown in Figure 1. D1 is a TL431 three-terminal reference voltage integrated circuit, and U1 uses a single-pole double-throw analog switch MAX4544; resistors R1, R2, and R3 are determined according to specific needs. Of course, other types of integrated circuits can also be used.
When the PWM pulse is at a high level (logic 1), the COM terminal of U1 is thrown to the normally closed terminal (NC), the adjustment pin of TL431 is connected to the positive voltage pin, and the output voltage value is 2.5 V. When the PWM pulse is at a low level (logic 0), the COM terminal of U1 is thrown to the normally open terminal (NO), and the output voltage of TL431 is sent to the adjustment pin after being divided by R2 and R3. At this time, the output voltage value is equal to [(R2+R3)/R3]×2.5 V. In this example, the output voltage is equal to 8 V. In this way, when the IN pin of U1 inputs a PWM signal, the circuit outputs a PWM pulse with a high level of 8 V and a low level of 2.5 V, and its amplitude is 8 V - 2.5 V = 5.5 V. If it is necessary to output a PWM signal with a low level of zero, adding a differential amplifier can solve the problem.
In situations where the precision requirement is not very high, a simpler method can be used. Figure 2 is a circuit diagram for stabilizing and limiting PWM pulses using precision voltage regulator diodes. In Figure 2, the PWM signal is amplified by the high-speed operational amplifier U1 to become an output voltage of ±12 V. After the current limiting of R1 and the voltage stabilization of D1, a PWM pulse output of ±6.5 V is obtained.
2 Error Analysis
In Figure 1, as long as the reference power supply is properly selected, the error of the reference power supply itself can be completely ignored. In addition, the sources of error are mainly the following:
(1) Error caused by the on-resistance of the analog switch
The analog switch has a certain on-resistance when it is turned on. When the input current of the TL431 adjustment pin passes through the analog switch, a voltage drop will be formed, resulting in an error. The on-resistance of the MAX4544 is 35 Ω, while the input current of the TL431 adjustment pin is less than 4 μA. As a result, the error of the reference voltage is less than 140 μV, which is 0.000 056 of 2.5 V, equivalent to 14 bits of binary precision.
(2) Error introduced by switch delay time
The switch delay time will cause the pulse duty cycle to change, resulting in an error in the PWM output pulse. The on-time of the MAX4544 is 30 ns and the off-time is 25 ns. Calculation shows that when the PWM frequency is 10 kHz, the maximum error caused by this is 0.0003, equivalent to 12 bits of precision. If the PWM frequency is selected to be lower, the influence of the switching delay time will be reduced accordingly. For example, when 1 kHz is selected, the introduced error is 0.000 03, which is equivalent to 15-bit accuracy.
Among the above two items, the drift of these parameters with temperature and time is what really affects the accuracy of the output power supply. Since the absolute values of these two parameters themselves are very small, it can be inferred that their drift is smaller.
From the above analysis, it can be seen that the error introduced by the additional circuit can fully meet the accuracy requirements of PWM.
In the circuit of Figure 2, there are three main reasons for the error:
(1) Error introduced by the dynamic resistance of the Zener diode
The dynamic resistance of the Zener diode is relatively large, generally around tens of Ω (when the working current is 5~10 mA); while the driving capability of the operational amplifier is relatively small, and the Zener diode can only work at a smaller working current. In addition, the dynamic resistance of the Zener diode is larger when working at a small current, which is more likely to cause voltage changes.
(2) Error introduced by the temperature drift of the Zener diode
The internal structure of 2DW7 (2DW230~236) can be considered to be two Zener diodes connected in series. The forward voltage drop of one diode (with a negative temperature coefficient) compensates the temperature drift of the other Zener diode (with a positive temperature coefficient), resulting in a very low temperature coefficient. However, when 2DW7 is applied in reverse, its temperature drift cannot be properly compensated, resulting in a higher temperature coefficient of the negative pulse part.
(3) Errors introduced by the operational amplifier
The drift of the input offset voltage of the operational amplifier can directly lead to errors in the pulse amplitude; and if the conversion rate (SR) is too low, it will cause distortion of the pulse square wave waveform, which will then cause voltage errors. The price of an operational amplifier with low offset voltage temperature drift and high conversion rate will be very high.
However, for 8~10-bit PWM, this circuit can already meet the requirements. For occasions with lower requirements, two cheap Zener diodes can be connected to replace 2DW7.
3 Application Examples
Using the PWM output of the microcontroller, an RC filter circuit and a first-stage operational amplifier are added to Figure 1 to obtain a 0~10 V DC output voltage as the control signal of the inverter, which has achieved good results. Figure 3 shows an example of using PWM output to control a frequency converter.
Previous article:Application of TCP/IP protocol stack with open source code in remote monitoring
Next article:USB2.0 Features and USB Microcontroller
Recommended ReadingLatest update time:2024-11-17 02:26
- Popular Resources
- Popular amplifiers
- 西门子S7-12001500 PLC SCL语言编程从入门到精通 (北岛李工)
- Small AC Servo Motor Control Circuit Design (by Masaru Ishijima; translated by Xue Liang and Zhu Jianjun, by Masaru Ishijima, Xue Liang, and Zhu Jianjun)
- Intelligent Control Technology of Permanent Magnet Synchronous Motor (Written by Wang Jun)
- 100 Examples of Microcontroller C Language Applications (with CD-ROM, 3rd Edition) (Wang Huiliang, Wang Dongfeng, Dong Guanqiang)
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- 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!
- Rambus Launches Industry's First HBM 4 Controller IP: What Are the Technical Details Behind It?
- 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
- I bought a ZT303 multimeter.
- Design techniques for machine learning algorithm generation (provided by ST official, Chinese subtitles)
- Add a startup program to the itop4412 development board
- IWR1642 Vehicle Occupant Detection Routine Problem
- How can I use an oscilloscope to capture pulses within a certain time range, such as capturing waveforms between 100us and 200us?
- Next-generation wireless network standard technology HiperLAN/2
- Products + DC brushless motor control + drive kit
- Due to the epidemic, you are under home quarantine. Has your salary been reduced?
- ARM9-compatible soft-core processor design: based on FPGA
- 5G era promotes PCB development in multiple fields