In addition, this article also explains the error sources of the entire system and the methods to reduce errors and improve accuracy.
0 Preface
The electronics industry is developing rapidly. As one of the most basic circuit components, the demand for resistors in electronic systems is increasing. In electronic instruments, precise resistors are needed to improve the accuracy of the instrument. For ordinary electronic instrument companies, a resistance tester that is both fast and accurate is needed. In the design of electronic circuits, it is often necessary to conveniently measure the resistance value. Therefore, it is of great practical significance to design a high-precision resistance measuring instrument that is not only safe and reliable, but also simple and practical. Intelligent instruments and meters that use single-chip microcomputers as the control core are widely used. They have the advantages of high reliability, low power consumption, and small size, making the measuring instruments more digital, intelligent, and miniaturized.
1 System Design
This system is controlled by the single-chip computer STC89C54RD. The measured resistance is passed through the measuring circuit, and the change of resistance is converted into the change of voltage and current and sent to the analog-to-digital converter for A/D conversion. The obtained digital signal is sent to the single-chip computer. The resistance value can be judged and measured through software design. Finally, the measured resistance is displayed through the display circuit. At the same time, the automatic screening function can be realized through software design. The system block diagram is shown in Figure 1.
2 Hardware Design
2.1 Constant current source voltage measurement method
The dual op amp constant current source circuit composed of OP07 uses the constant current flowing through the measured resistor Rx. The resistance value of Rx is calculated by measuring the voltage value across Rx. It can have high accuracy when measuring small resistance (100-100kΩ).
2.2 Constant voltage source current measurement method
When using a constant current source to measure voltage to measure a large resistor (100k-10MΩ), the current flowing through the resistor is very small, the output voltage is small, and it is difficult for the A/D to sample and convert it. At the same time, there is a large error, so this method of measuring current by adding pressure is not feasible when measuring large resistors. Therefore, the method of measuring current by a constant voltage source is used, and its design circuit diagram is shown in Figure 2.
2.3 12-bit A/D conversion interface circuit
The improvement of the measurement accuracy and speed of the whole system also depends on the analog-to-digital conversion circuit. The analog-to-digital conversion chip AD574 is a classic 12-bit high-speed successive approximation A/D. It is a hybrid integrated chip with a built-in bipolar conversion circuit. It has few external components, low power consumption, high precision, automatic zero calibration and automatic polarity conversion functions, and only needs a small number of external resistors and capacitors to form a complete A/D conversion circuit.
The nonlinear error of AD574 is less than 1/2LSB, and the maximum conversion time is 35us, which is suitable for applications with a conversion rate of less than 30kB/s. The input control signals of AD574 are CE, CS, R/C, A0, and 12/8. The control signals and their corresponding working states are shown in Table 1, and the interface circuit with the microcontroller is shown in Figure 3.
3 Software Design
In this circuit, the STC89C54RD single-chip microcomputer controls the on and off of the relay to realize the gear switching of the resistance measurement circuit. The voltage measured by the measured resistor is sent to the A/D converter AD574 (the data is converted, and the voltage and resistance values are equal). The data after A/D conversion is sent to the single-chip microcomputer for processing and finally displayed. The flow chart is shown in Figure 4. The automatic screening program first determines whether there is a key pressed on the single-chip microcomputer. When a key is pressed, it enters the screening, otherwise it enters the measurement circuit, collects the numerical value output by the A/D module, processes it, and displays the processed numerical value.
4 Error analysis
4.1 Causes of Systematic Errors
(1) The non-ideal nature of the integrated operational amplifier generates errors;
(2) Errors caused by the A/D conversion circuit;
(3) Interference of electric field, etc.
4.2 Main methods to reduce errors and improve accuracy
(1) Four ranges are set, but in the same range, the voltage range of AD conversion is also between full amplitude and 1/10 full amplitude. When using 12-bit AD conversion, the accuracy is not enough when it is below 1/10 full amplitude (1V). Now the AD oversampling method is used to improve the accuracy. In each test, multiple AD conversions (200 times) are performed and the average value is taken;
(2) During high impedance testing, power frequency interference will affect the measurement. Performing multiple (200) AD conversions in one power frequency sine cycle can achieve the best digital filtering effect.
(3) When testing low resistance, the wire resistance and the contact resistance between the relay and the probe cannot be ignored. The "four-wire system" is used during the test to eliminate the corresponding errors.
(4) Process requirements. In order to ensure the high precision of the resistance tester, the process requirements are also crucial. First, the power supply must be decoupled and filtered, and the ground wire must be as thick as possible and as short as possible. Secondly, the resistor selection of the operational amplifier must pay attention to "pairing", that is, it is necessary to screen from a large number of resistors. Thirdly, the range resistor must use a precision resistor of more than one thousandth, and finally the operational amplifier must be a high-precision operational amplifier OP07.
5 Conclusion
The STC89C54RD microcontroller controls the on and off of the relay to switch the range of the measured resistance. The small resistor uses a dual high-precision op amp OP07 to form a constant current source to measure the voltage. The large resistor is measured by measuring the current through a constant voltage source. The measured voltage or current is sent to the 12-bit serial AD574 circuit to realize the acquisition of analog quantity. The entire circuit is controlled by the STC89C54RD microcontroller and the keyboard display circuit. The hardware structure of the entire circuit is concise and the output voltage is stable. However, the entire system focuses on software design. The A/D conversion has different conversion algorithms for the output voltage of resistors of different ranges. The algorithm error of the A/D conversion is the main source of system test error. The A/D conversion algorithm should be continuously adjusted to continuously improve the test accuracy.
Previous article:Wide range and high precision temperature measurement device using platinum resistance
Next article:Design of intelligent car based on MSP430 microcontroller
- Popular Resources
- Popular amplifiers
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- 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
- [ESP32-S2-Kaluga-1 Review] 3. ADC button test
- This week's highlights
- For the STM32 MCU, is it generally better to choose a high frequency or a low frequency external main crystal oscillator? Is there any technical principle?
- Long-lasting and durable electric motorcycle 16S-17S lithium-ion battery pack solution BQ76940
- MSP430F249—SPI Master-Slave Communication
- MicroPython Hands-on (03) - Learn to boot up the computer with MaixPy from scratch
- [RVB2601 Creative Application Development] How to use font tools
- Why do we need LoRa and NB-IoT when we have GPRS?
- Recommend a network disk that supports automatic synchronization - TeraCLOUD, supports WebDav
- [AIoT Smart Smoke Detection System] SiPEED MAIX Bit K210 Development Board Hands-on Experience