A key consideration and success factor for any metering and medical measurement application is the analog-to-digital converter (ADC) module. Meters and monitors convert real-world signals, which are (by definition) analog, into the digital electronic realm to be processed, recorded, and acted upon. The most common measurement signals read by a microcontroller (MCU) and converted by an ADC module are voltage and current, as all sensors are capable of converting to this electronic realm. For system designers, choosing an MCU with the most appropriate ADC module for their application is not as simple as looking for signal granularity. Resolution is only part of the consideration, and speed, linearity, noise, and other factors that contribute to measurement errors must also be analyzed and their impact understood. The first step is to find an appropriate MCU product, and the second step is to understand the ADC module and use it to minimize adverse effects or even turn them into advantages for the system.
Applications such as electricity meters and high-precision medical equipment require the measurement of very small signals, so the resolution of the ADC is often a key parameter (i.e., 10-bit, 12-bit, or 16-bit resolution) and consideration when selecting an MCU for the application design. It is important to remember that all ADCs have inherent errors because they need to convert real-world information and digitize the signal in discrete steps, a process called quantization. Therefore, the digital output cannot perfectly represent the analog input signal. For example, for a maximum input voltage of 5V, a 16-bit converter will provide a least significant bit (LSB) step size of 76uV. Therefore, the ADC can only digitize the value in steps of 76uV (76uV, 152uV, 228uV, etc.). For this case, this means that in the best case, the accuracy of the measurement result will never be better than ±0.5LSB (±38uV).
The meter must be able to accurately measure a relatively large current range. A typical US meter needs to read currents from 0.25A to 200A with 1% accuracy. This is equivalent to 800 levels of 1% accuracy (200/0.25), or 80,000 (800*100), which is equivalent to 16 bits. The maximum voltage of the meter across this current range is very small (<1V=, so a differential pair input is used to reduce the voltage accuracy to about 5uV.
Similarly, in a high-precision medical device, such as a small blood sample glucose meter (0.3μl), high ADC accuracy is also required. Narrowing the measurable voltage band differential input will provide better noise immunity than single-ended input. The ADC input signal line acts as an antenna, collecting environmental electrical activity (noise). When using single-ended input, it is impossible to distinguish between signal and noise, but the two inputs of the differential input have the same noise, which effectively cancels the noise. In practice, differential input amplifiers are not perfectly matched, so a small portion of the noise voltage may appear in the conversion result. The degree of closeness of the differential input amplifier to the ideal situation is expressed by the common-mode rejection ratio (CMRR).
Different types of ADCs have different speeds (conversion times). The conversion time is proportional to the number of channels. For a successive approximation ADC (found in Freescale's 9S08MM, MCF51MM, MCF51EM, and 9S08LH MCU families that support 16-bit ADCs), the conversion time will scale as the logarithm of the number of channels. Since analog technology is inherently slower than digital technology, the required conversion time will increase as the number of channels increases. There is a trade-off between speed and accuracy. These successive approximation ADCs consist of a sample-and-hold circuit that takes the input voltage (VIN), a comparator, a successive approximation register subcircuit, and an internal reference capacitor digital-to-analog converter (DAC) (Figure 1). The DAC provides the comparator with an analog voltage that is equivalent to the digital code output from the successive approximation register (SAR) for comparison with VIN.
Using the example of an electricity meter again, the mains voltage/current signal has a fundamental frequency (50/60Hz, depending on the country). The required ADC sampling frequency is usually taken as the frequency required to measure the 21st harmonic of the mains frequency (50/60Hz). This requires a sampling frequency of 2*21*60, which is 2.52kHz or about 400us. This means that all required measurements must be completed within 400us. However, this leads to tighter frequency requirements due to hysteresis caused by current transformer coils or similar system circuits that distort circuit measurements. This hysteresis means that the previous voltage conversion must be completed before the current conversion can be made within the specified time. This delay is calibrated for each CT, but the conversion speed may be reduced to less than the required 5us. The preferred solution is to use multiple independent ADC modules with a programmable synchronous hardware trigger mechanism. Freescale's 9S08MM, MCF51MM and MCF51EM microcontrollers provide a programmable delay block (PDB) to accomplish this task.
Some ADC devices have programmable conversion times. Any method that shortens the sampling time will negatively affect conversion accuracy because it will increase acquisition errors caused by the acquisition circuitry not being able to fully charge the ADC input in the allotted time. Shortening the SAR hold time will also increase the chance of errors if the result cannot be determined in a timely manner. The severity of these errors depends on the ADC and the implementation, but the general rule is to allow the ADC to have a long enough comparison time that the application can handle.
[page] Unfortunately, several other embedded ADC features introduce errors and reduce accuracy, including offset, gain, temperature drift, and nonlinear performance. Some ADCs, such as the 16-bit ADCs in Freescale's latest products, have the ability to reduce offset and gain errors through calibration. The calibration process is divided into three steps: sampling, comparing, and approximating, which can be used to adjust the conversion result. Many ADCs exhibit some nonlinear characteristics at the endpoints because it is difficult to measure the same signal as the reference. The zero-scale and full-scale errors, which are usually specified in the product's electrical characteristics, can be applied to the extremes of the conversion result scale. Considering only these two errors, the adjusted transfer function between ground potential and power supply can be calculated (the green dashed line in Figure 2). Another way to view these errors is in terms of offset and gain. Some ADC modules have the ability to adjust the result (through calibration) through predetermined gain adjustments and offset adjustments, which improve the adjusted transfer function so that it better represents the ideal transfer function (the blue line in Figure 2).
The nonlinearity of the ADC cannot be corrected by the system and must be addressed by the module designer. There are two types of nonlinearity, differential nonlinearity and integral nonlinearity. Differential nonlinearity (DNL) is the most critical performance measurement for an ADC for many control applications because it represents the ADC's ability to relate small changes in input voltage to the correct change in code transition. DNL is the difference between the current code width (CCW) and the ideal code width (ICW) for each transition. Integral nonlinearity (INL) represents the curvature in the actual transfer function by highlighting the difference between the current and ideal transition voltages. Many ADCs have the ability to measure the temperature of the die through an on-chip temperature sensor connected internally to the ADC channel, allowing temperature compensation to be included if the temperature compensation curve is known, which is generally achieved through controlled environmental characterization during product development.
These errors can be summed up and expressed as a total unadjusted error (TUE) number, usually quoted in a number of LSBs. TUE refers to the maximum error (greater or less than the ideal direct transfer function), including the aforementioned DNL, INL, zero-scale, and full-scale errors, or the maximum deviation between the actual transfer function and the ideal ADC.
The number of bits effective (BNOB) of an ADC is a true indicator of resolution and accuracy. This value indicates how many bits provide accurate information in a given system, that is, how much of the result represents noise and how much represents signal. It can be calculated using the following formula:
ENOB = (SINAD - 1.76dB) / 6.02dB
Among them, the signal-to-noise-and-distortion ratio (SINAD) refers to the ratio between useful information (signal) and background noise (noise or error). The SINAD value is not only affected by the ADC design and chip integration, but also by the layout and design of the PCB, as well as the selected additional discrete components. A larger SINAD value means that more signals are data and the error is small, which can improve the accuracy of the measurement results when measuring signals with microvolt level changes. A smaller SINAD value means that the signal is interfered by the noise in the system and the accuracy is affected.
Knowing the data in the ADC module electrical specifications will help you make an informed decision based on your system needs, but there are techniques that can be applied to improve the resolution and accuracy of the conversion results. The first technique is called dithering. Adding a small amount of controlled noise (0.5LSB Gaussian white noise) to the input of an ADC forces the signal to be above or below the nearest resolution step, thus avoiding the need to round down below that value. The LSB state of the conversion will randomly oscillate between 0 and 1 instead of being held at a fixed value. By introducing a small amount of noise, we extend the effective range of the signal that the ADC can convert, rather than simply removing all the signal at this low level (quantized to only one bit of resolution). In fact, this quantization error covers a range of noise values. Dithering only increases the resolution of the sampling circuitry, improving linearity, but not accuracy. However, by adding 1 to 2 LSBs of noise to the signal and using oversampling techniques, accuracy can be improved.
[page]When adding artificial noise to a signal, it is important to note that the average value of the noise must be 0. However, many systems have white noise from other noise sources, including thermal noise, CPU cores, switching ports, and power supply variations. Blood pressure monitors are particularly susceptible to white noise because the pulsation of blood generates electromagnetic interference and oscillations, which will be absorbed by the PCB and then enter the microcontroller.
Oversampling is the process of sampling a signal at a frequency much higher than the Nyquist frequency of the signal being sampled. In practice, oversampling is used to achieve lower-cost, higher-resolution ADC conversions. For example, to achieve a 16-bit converter, simply use a 12-bit converter running at 256 times the target sampling rate. For each additional bit of resolution, the signal must be oversampled 4 times the frequency. Averaging a set of 256 consecutive 12-bit samples increases the resolution of the result by 4 bits, thus producing a 16-bit resolution. Because real-world ADCs do not complete conversions instantly, the input value should be held constant while the converter is converting. A sample and hold circuit accomplishes this task by using a capacitor to store the analog voltage at the input and disconnecting the capacitor from the input with an electronic switch. Using an ADC with the sample and hold times set to best suit the input signal will help improve the accuracy of the conversion result.
The above two methods (noise injection and oversampling) can be combined to further improve accuracy. This technique is generally referred to as oversampling and decimation. By adding 1 to 2 noise LSBs, simultaneous samples will not produce the same result. This method increases SINAD and improves ENOB. By adding 1 to 2 noise LSBs and oversampling at the input signal, the results are averaged to provide a more accurate value. The average data obtained from the ADC measurement also flattens the burrs in the input signal, which has the advantage of reducing signal fluctuations and noise. The average value of ordinary noise will always remain at 0, so by averaging the results of simultaneous samples, the effect of noise can be reduced. The amount of averaging applied by the system depends on the rate of signal change and the required sampling interval. Some ADC modules have built-in averaging capabilities (Figure 3).
The above concepts are all incorporated into the software design of the system, but there are some hardware improvements that can also improve conversion accuracy. Many circuits (especially battery voltage and temperature sensing circuits) use high-value resistor dividers to generate analog references. Typically, capacitors are placed at the input, which will reduce the source impedance of the analog AC power supply, so the ADC will be able to properly acquire the signal. The inherent resistance of the PCB itself is less than 1MΩ. The leakage current (IIN) at the analog input is usually required to be no more than 1μA, and its typical value is generally around 25nA. This leakage current will produce errors (EIL):
EIL=IIN*RAS
Where RAS is the analog source resistance of the ADC voltage source. The best way to eliminate this error is to reduce RAS and any form of leakage current (such as PCB leakage) within the controllable range of the system.
[page]System power can also affect conversion accuracy in the form of noise. If the ADC uses a noisy power supply (including the ADC voltage reference), it will not accurately represent the level that the sensor is outputting. There are several ADC design methods that can remove some power supply noise, but the best way to eliminate power supply noise is to create a quiet environment for conversion. Some modes provided by the MCU can suspend the CPU and various peripherals. Freescale's Flexis mode is called WAIT mode. In this environment, the device does not drive the output, but the ADC conversion will still occur and interrupt the CPU, that is, quickly wake up the device, and resume all operations and communications after the conversion is completed.
The most difficult noise to eliminate is synchronous noise, which has the same parameters as the conversion schedule. This type of noise can masquerade as gain or offset errors. The only way to reduce this effect is to change the conversion time relative to the synchronous noise, which is only effective if the noise source has a low frequency. Many random noises are difficult to prevent, such as EMC events, line noise, and white noise, because they are random, but they can be treated to some extent by averaging through oversampling.
Energy metering has been an example of an application that requires accurate analog signal conversion. Another application is medical equipment, in the example below, a portable home blood glucose meter with MMS capabilities. All of these portable home medical products require long battery life, fast response time, powerful data processing, and wired and wireless communication interfaces. Pressure and acceleration sensors based on microelectromechanical systems (MEMS) can be used to acquire physical parameters that provide precise and accurate conversion of natural, continuous signal voltage or current, allowing the MCU to process them through the ADC module (Figure 4).
Diabetics need to monitor their blood sugar levels at all times and take appropriate actions. As a result, the home medical market has developed home medical products that make it easier for patients to do the above. These devices are battery-powered and have relatively simple user interfaces. Today's meters have date/time clocks and memory, and many meters can transmit data to a computer or even to a doctor's office via a mobile phone network. Some blood glucose monitors have a DC motor that allows a lancet to be inserted into the skin to collect a blood sample. The chemical reaction in the blood sample will generate an electric current. The magnitude of the current corresponds to the glucose content in the blood sample. These glucose levels are in the range of 1 mg/dL. It only takes a few seconds for the glucose reading to reach its maximum value, which requires a stable reference voltage. The accuracy of home blood glucose monitors is a concern for everyone because they must meet the International Organization for Standardization (ISO) 15197 accuracy standard, which stipulates that for absolute levels of concentrations above 75 mg/dl or lower, the test results of the blood glucose monitor must be within 20% of the laboratory standard in 95% of cases. Factors that affect meter accuracy include meter calibration, ambient temperature, blood sample volume and quality, other substances present at high levels in the blood, hematocrit, dirt in the meter, humidity, and aging of the test strip.
These requirements are for the entire system. If all active electronic system components have accuracy requirements, the required specifications for the ADC are usually 16-bit resolution, ENOB>13.5 bits, at least 4 differential paired inputs (two differential pairs), and a rate greater than 100kHz. Each blood glucose meter manufacturer will divide accuracy in its own way based on the components used and the special algorithms, but the above parameters are used uniformly by the market.
[page] Summary
The biggest challenge for any medical measurement or metrology system is to accurately convert real-world analog signals into the digital domain of the embedded controller. High-resolution ADCs provide high-granularity results (LSB represents nV change), but do not necessarily provide the accuracy required by the application. Many error-inducing factors are unavoidable because perfect analog-to-digital conversion cannot be achieved. However, different ADC techniques, such as averaging, oversampling and decimation, calibration, leakage control, noise reduction, and temperature compensation, can be used to improve conversion accuracy (TUE) and ADC ENOB.
Freescale's Flexis microcontrollers MM256/128 and JE256/128 devices enable ultra-low power operation, USB connectivity, graphics display support and excellent measurement accuracy on an interchangeable 8-bit or 32-bit microcontroller, allowing device designers to design feature-rich products at a low cost. Such devices are suitable for industrial control, instrumentation and medical applications, or any other application that requires a large number of high-precision analogs. The devices provide designers with two options for high-resolution ADC and DAC modules, and the JE256/128 devices also integrate general-purpose operational amplifiers and transimpedance amplifiers into the microcontroller. These highly integrated microcontrollers have a rich collection of peripherals, including a USB 2.0 controller, multiple serial interfaces and an external bus interface. Like other USB microcontrollers in the Freescale controller family, the MM256/128 devices are also supported by the USB stack for medical applications. This complimentary USB stack currently supports MSD, HID, CDC and personal medical device class applications (PHDC), while the medical device connection library supports communication between devices (compliant with IEEE11073). In addition, Freescale's MQX software supports real-time operating system (RTOS) functions and USB stack.
Previous article:Analysis of PWM Control Strategy for Soft-Switching Half-Bridge DC/DC Converter
Next article:Study on the transfer characteristics of loosely coupled full-bridge resonant converter
- 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
- 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
- Introduction to the Oscilloscope's Auto-Setup and Auto-Range
- Voltage is pulled down
- A beautiful keyboard mug developed by Google Japan
- The problem of no output of Jiuqi nyquest voice chip playback has finally been solved
- FPGA and DSP communication issues
- [RVB2601 Creative Application Development] + 2 Simple Demo Tests
- Why do voice chips have malfunctions?
- Introducing the H-bridge Motor Drive Circuit
- EEWORLD University Hall----Application of EMI optimized transformer integrated isolated DC/DC power supply chip in industrial products
- 51. What is the difference between STM32 and Linux lighting?