The Adaptive Threshold: Why a Fixed Voltage Fails and How Barcode Scanners Learn to Adapt |
Subtitle: A Deep Dive into the Circuits and Algorithms That Track the Signal's Changing Baseline - with Real-World Designs from Symbol, Zebra, Honeywell, Datalogic, MicroVision, and Datalogic Scanning |

|
Opening Summary |
Imagine trying to read a book in a room where the lighting changes from dim to bright every few seconds. Your eyes would constantly adjust, but if they were stuck at one setting, the words would become illegible. This is precisely the problem that a fixed-voltage comparator faces in a barcode scanner. The signal from the photodetector is not a stable, predictable waveform. It varies in amplitude due to differences in label contrast, scanning distance, ambient light, and even the ink and paper quality. A fixed threshold, set to a constant voltage, will work perfectly on a pristine label under ideal lighting, but it will fail on a dirty label, a faded label, or a label scanned in direct sunlight. |
The solution is the adaptive threshold - a threshold voltage that automatically tracks the signal's changing average level. It is set to the midpoint between the signal's maximum (white spaces) and minimum (black bars). This ensures that the comparator always makes a clean, accurate decision, regardless of the signal's amplitude. The adaptive threshold is one of the most important innovations in barcode scanning, and it is implemented in every modern scanner. |
This article is dedicated to the adaptive threshold - its principles, its implementation, and its critical role in the barcode scanner. We will explore the classic analog peak-detector circuit, which uses diodes and capacitors to track the signal's extremes. We will examine how major companies have implemented adaptive thresholds in their products. We will see how Symbol (now Zebra) used a simple but effective peak detector in the LS2208. We will explore Honeywell's use of a digital adaptive threshold in their imagers, and Datalogic's patented automatic threshold adjustment in their industrial scanners. We will also look at advanced techniques, such as MicroVision's derivative-based threshold and dual-threshold systems for ternary barcodes. |
By the end of this journey, you will understand why a fixed threshold is inadequate, and how the adaptive threshold is the key to reliable, robust barcode reading across a wide range of conditions. |

|
Full Article |
Section 1: The Flaw of the Fixed Threshold |
A fixed threshold is a voltage level that is set once and never changes. For example, the threshold might be set to 2.5 volts, halfway between ground and a 5-volt supply. The comparator compares the input signal to this fixed level. If the signal is above 2.5 volts, the output is high (white space). If the signal is below 2.5 volts, the output is low (black bar). |
The fixed threshold works well when the signal amplitude is constant. In a controlled environment, with a high-contrast label and a stable light source, it can be perfectly adequate. However, in the real world, the signal amplitude varies widely. A label with a high print contrast (e.g., black ink on white paper) produces a large signal swing. A label with a low print contrast (e.g., black ink on a dark gray background) produces a small signal swing. A label that is scanned from a close distance produces a strong signal. A label that is scanned from a far distance produces a weak signal. The fixed threshold cannot adapt to these variations. |
If the threshold is set too high for a low-contrast label, the comparator may never see a white space. If the threshold is set too low for a high-contrast label, the comparator may see white spaces everywhere. The fixed threshold is a compromise, and it is a compromise that often fails. |

|
Section 2: The Adaptive Threshold - The Solution |
The adaptive threshold is a threshold voltage that changes with the signal. It is set to the midpoint between the signal's peak (the white level) and its valley (the black level). This is the optimal decision point, because it is exactly halfway between the two states. |
The adaptive threshold is generated by a circuit that measures the signal's peak and valley. The circuit continuously updates the threshold as the signal changes. If the signal amplitude increases, the threshold increases. If the signal amplitude decreases, the threshold decreases. The threshold always stays at the midpoint. |
The adaptive threshold circuit is typically a peak detector. A peak detector is a circuit that captures the maximum (peak) and minimum (valley) of a signal. Two peak detectors are used: one for the positive peak and one for the negative peak. The outputs of the two peak detectors are combined through a resistor divider to produce the midpoint voltage. |

|
Section 3: The Classic Analog Peak Detector |
The classic analog peak detector uses a diode, a capacitor, and a resistor. For the positive peak detector, the diode is connected so that it charges the capacitor to the signal's peak voltage. When the signal rises, the diode conducts, charging the capacitor to the new peak. When the signal falls, the diode is reverse-biased, and the capacitor holds the peak voltage. The resistor in parallel with the capacitor provides a slow discharge path, allowing the peak detector to track slow changes in the signal's average level. |
The negative peak detector is similar, but the diode is reversed. It charges the capacitor to the signal's valley voltage (the most negative voltage). The outputs of the positive and negative peak detectors are fed to a resistor divider. The midpoint voltage is the adaptive threshold. |
The time constant of the peak detector (the product of the resistor and the capacitor) is critical. It must be long enough to hold the peak during the duration of a bar, but short enough to track changes in the signal's average level. A typical time constant is 10-100 milliseconds. |

|
Section 4: Symbol's LS2208 - A Classic Adaptive Threshold |
Symbol's LS2208 uses a classic analog peak detector for its adaptive threshold. The circuit uses two diodes, two capacitors, and two resistors. The positive peak detector uses a Schottky diode (for its low forward voltage) and a 1-microfarad capacitor. The discharge resistor is 1 megaohm. The time constant is 1 second, which is long enough to hold the peak during the entire barcode. |
The negative peak detector is similar, with the diode reversed. The outputs of the two peak detectors are fed to a resistor divider. The midpoint voltage is the adaptive threshold. This threshold is fed to the comparator's inverting input. The comparator's non-inverting input receives the amplified signal. The comparator's output is the digital square wave. |
The LS2208's adaptive threshold is simple, robust, and effective. It has been proven in millions of units. The time constant is long enough to hold the peak during the barcode, but short enough to track changes in the ambient light. |

|
Section 5: The Limitations of the Analog Peak Detector |
The analog peak detector is a simple and elegant solution, but it has limitations. The diode's forward voltage drop can cause errors. The forward voltage drop is typically 0.3-0.7 volts for a silicon diode and 0.2-0.4 volts for a Schottky diode. This voltage drop is added to the peak voltage, causing the threshold to be slightly off. |
The diode's forward voltage drop is also temperature-dependent. As the temperature changes, the forward voltage drop changes, causing the threshold to drift. This is a problem for scanners that are used in outdoor environments with large temperature variations. |
The peak detector's time constant is also a limitation. A long time constant is needed to hold the peak during the barcode, but a short time constant is needed to track changes in the ambient light. The optimal time constant is a compromise. |

|
Section 6: Honeywell's Digital Adaptive Threshold |
Honeywell's imaging scanners use a digital adaptive threshold. The threshold is calculated in the digital domain, after the ADC. The scanner captures the image of the barcode, and then the firmware analyzes the pixel values. The firmware calculates the average of the white pixels and the average of the black pixels. The threshold is set to the midpoint between these two averages. |
The digital adaptive threshold is more accurate than the analog peak detector. There is no diode forward voltage drop, and there is no temperature drift. The threshold is calculated with high precision. The digital adaptive threshold is also more flexible. The firmware can use different algorithms to calculate the threshold, depending on the barcode type and the image quality. |
Honeywell's user manuals refer to 'Decode Settings' that can be adjusted for poorly printed or damaged barcodes. These settings allow the user to adjust the scanner's 'reading tolerance' - essentially the aggressiveness of the adaptive threshold. A lower setting makes the decoder more lenient for low-quality barcodes, while a higher setting makes it more strict. |

|
Section 7: Datalogic's Automatic Threshold |
Datalogic's industrial scanners use an automatic threshold adjustment. The scanner's firmware analyzes the captured image and automatically determines the optimal threshold. The user can also manually set the threshold, but the automatic mode is the default. |
The automatic threshold algorithm works by analyzing the histogram of the pixel values. The histogram is a graph that shows the number of pixels at each brightness level. The algorithm identifies two peaks in the histogram: one peak for the white pixels and one peak for the black pixels. The threshold is set to the midpoint between these two peaks. |
Datalogic's AV7000 product reference manual describes an 'Automatic Threshold' setting. When this is enabled, 'the decode engine automatically determines the contrast between white and black in the bar codes'. If the user disables the automatic threshold, they must manually enter a 'Minimum 2D Contrast' value, specifying the minimum difference between what is considered a black bar and a white space. |

|
Section 8: MicroVision's Derivative-Based Adaptive Threshold |
MicroVision, a company that specializes in MEMS-based scanning engines, has developed a more advanced adaptive threshold technique. Their patent US20080265034 describes an adaptive threshold that uses the first derivative of the reflectance profile. |
The first derivative of the signal is the rate of change of the signal. It is large at the edges of the barcode (where the signal changes rapidly) and small in the middle of the bars and spaces (where the signal is relatively constant). MicroVision's technique uses the derivative to adjust the threshold dynamically. |
The threshold is set lower when the derivative is low (noise is more likely) and higher when the derivative is high (the signal is stronger). This provides better noise immunity. The derivative-based threshold is more complex than the simple peak detector, but it provides superior performance in noisy environments. |

|
Section 9: Dual-Threshold Systems for Ternary Barcodes |
Most barcodes are binary - they have only two states: black and white. However, some advanced barcodes are ternary - they have three states: black, gray, and white. These barcodes can store more information than binary barcodes. |
A ternary barcode requires a dual-threshold system. The comparator has two thresholds: one between black and gray, and one between gray and white. The output of the comparator is not a single bit but a two-bit signal. |
Dual-threshold systems are more complex than single-threshold systems. They require two peak detectors and two comparators. The thresholds are set to the midpoints between the three levels. |
A study published in Sensors and Actuators describes a 'ternary barcode detection system employing a dual-threshold detection method'. The system uses two reference signals, generated by attenuating the envelope of the barcode signal to 60% and 25% of its peak. These reference signals are used as the two thresholds for the comparator. |

|
Section 10: Datalogic Scanning's Adaptive Data Reader |
Datalogic Scanning, Inc. (a subsidiary of Datalogic) has developed an advanced adaptive data reader that adjusts multiple operating parameters, not just the threshold. Their patent US20120000982 describes a system that analyzes captured images to determine whether the item has a highly reflective surface. Based on this determination, the system automatically adjusts the gain, exposure time, and amount of illumination to capture an image with sufficient contrast. |
The system determines the reflectivity by analyzing the image histogram. If the histogram shows a large number of pixels at the white level, the surface is highly reflective. The system then reduces the illumination and/or the gain to prevent saturation. This adaptive approach ensures that the optical code can be decoded even on shiny or reflective surfaces, such as aluminum cans, plastic packaging, or mobile phone screens. |
Section 11: The Adaptive Threshold in the TIDA-00857 |
Texas Instruments' TIDA-00857 reference design uses an adaptive threshold based on a peak detector. The design uses two peak detectors: one for the positive peak and one for the negative peak. The peak detectors use Schottky diodes and 1-microfarad capacitors. The discharge resistors are 1-megaohm resistors. |
The outputs of the two peak detectors are fed to a resistor divider. The midpoint voltage is the adaptive threshold. The threshold is fed to the comparator's inverting input. The TIDA-00857's adaptive threshold is a classic analog design, similar to the LS2208's. |

|
Section 12: The Adaptive Threshold in Analog Devices' Reference Design |
Analog Devices' reference design uses a more sophisticated adaptive threshold. The design uses an active peak detector, which uses an op-amp to eliminate the diode's forward voltage drop. The active peak detector is a precision rectifier that accurately captures the signal's peak and valley. |
The active peak detector is more accurate than the passive peak detector. The op-amp's feedback loop compensates for the diode's forward voltage drop. The resulting peak voltage is very close to the actual signal peak. The threshold is set to the midpoint of the peak and valley. |
Section 13: The Adaptive Threshold and the Comparator |
The adaptive threshold is typically fed to the comparator's inverting input. The signal from the gain stage is fed to the comparator's non-inverting input. The comparator compares the signal to the adaptive threshold. When the signal is above the threshold, the comparator's output is high. When the signal is below the threshold, the output is low. |
The comparator's output is the digital square wave. The square wave is a clean, binary representation of the barcode. The decoder then measures the widths of the bars and spaces. |

|
Section 14: The Adaptive Threshold and the Decoder |
The adaptive threshold is a critical part of the decoder. If the threshold is wrong, the decoder will measure the bar widths incorrectly. The decoder will then produce incorrect data. The checksum will fail, and the scanner will reject the read. |
The adaptive threshold ensures that the decoder always sees a clean, accurate signal. The threshold is always at the midpoint, regardless of the signal's amplitude. This maximizes the decoder's accuracy. |
Section 15: The Adaptive Threshold and the Noise |
The adaptive threshold does not eliminate noise; it only adapts to the signal's amplitude. If the noise is large, the threshold will still be at the midpoint, but the comparator may still jitter. The hysteresis in the comparator helps to suppress the noise. |
The adaptive threshold also helps to reject low-frequency noise. Low-frequency noise is a slow drift in the signal. The peak detector's time constant is long enough to track the low-frequency drift. The threshold follows the drift, so the comparator's decision is not affected. |

|
Section 16: The Adaptive Threshold and the Ambient Light |
The ambient light is the most significant source of signal variation. The ambient light can change rapidly, especially when the scanner is moved from a dark room to a bright room. The adaptive threshold must track these changes quickly. |
The peak detector's time constant is the key to tracking the ambient light. The time constant must be short enough to track the ambient light changes, but long enough to hold the peak during the barcode. The optimal time constant is a balance between these two requirements. |
Section 17: The Adaptive Threshold and the Temperature |
The adaptive threshold's accuracy is affected by temperature. The diode's forward voltage drop changes with temperature. The capacitor's capacitance changes with temperature. The resistor's resistance changes with temperature. |
To minimize the temperature drift, the components should be chosen carefully. Schottky diodes have a lower temperature coefficient than silicon diodes. COG capacitors have a very low temperature coefficient. Metal film resistors have a low temperature coefficient. The analog peak detector's drift can be minimized by using these components. |
The digital adaptive threshold, used in Honeywell's imagers, is not affected by temperature. The digital threshold is calculated from the pixel values, and there is no analog drift. This is a significant advantage of the digital approach. |

|
Section 18: The Adaptive Threshold and the Label's Contrast |
The adaptive threshold is designed to handle different label contrasts. A high-contrast label produces a large signal swing. A low-contrast label produces a small signal swing. The adaptive threshold tracks these variations and remains at the midpoint. |
The adaptive threshold's range is limited by the comparator's input range. The threshold must be between the comparator's low and high input voltages. For a 5-volt supply, the threshold must be between 0 and 5 volts. If the signal amplitude is very small, the threshold may be too low for the comparator to detect. This is the fundamental limit of the adaptive threshold. |
Section 19: The Adaptive Threshold and the Scanning Speed |
The adaptive threshold is not affected by the scanning speed. The peak detector's time constant is long enough to hold the peak during the barcode, regardless of the scanning speed. The threshold is updated continuously, tracking the signal's changes. |
The scanning speed does affect the comparator's output. A fast scan produces narrow pulses; a slow scan produces wide pulses. The decoder must handle these variations, but the adaptive threshold is not affected. |

|
Section 20: The Adaptive Threshold and the Barcode Type |
The adaptive threshold is used for all types of 1D barcodes. It works for Code 39, UPC, Code 128, and all other linear symbologies. The adaptive threshold is also used for some 2D barcodes, but the 2D decoders usually use a different thresholding algorithm. |
For 2D barcodes, the threshold is often calculated from the histogram of the image. The histogram shows the distribution of pixel values. The threshold is set to the midpoint between the two peaks of the histogram. This is a global threshold, meaning it is applied to the entire image. |
Section 21: The Adaptive Threshold and the 2D Imager |
In a 2D imager, the adaptive threshold is usually calculated in the digital domain. The sensor captures the image, and the firmware analyzes the pixel values. The firmware calculates the average of the white pixels and the average of the black pixels. The threshold is set to the midpoint between these two averages. |
The digital adaptive threshold is more accurate than the analog peak detector. It is not affected by diode forward voltage drops, temperature drift, or component tolerances. The digital threshold is also more flexible. The firmware can use different algorithms to calculate the threshold for different barcode types. |

|
Section 22: The Adaptive Threshold and the 'Decode Security' Setting |
Honeywell's scanners have a 'Decode Security' setting, which adjusts the decoder's tolerance for low-quality barcodes. This setting is closely related to the adaptive threshold. The Decode Security setting effectively adjusts the aggressiveness of the threshold algorithm. A lower setting makes the decoder more lenient (the threshold is adjusted more aggressively to track the signal's extremes), while a higher setting makes it more strict (the threshold is more conservative). |
Honeywell's user manuals advise that 'Lower settings are more lenient when reading low quality barcodes while higher values are more strict'. This setting is typically used when scanning damaged, faded, or poorly printed barcodes. The user can adjust the setting to optimize the scanner's performance for the specific application. |
Section 23: The Adaptive Threshold and the 'Redundancy Level' |
Some scanners have a 'Redundancy Level' setting, which requires multiple consecutive, identical decodes before passing the barcode data. This is a form of error checking that complements the adaptive threshold. The Redundancy Level ensures that the decoded data is consistent. If the barcode is read with a different result, the scan is rejected. |
The Redundancy Level is particularly useful for low-quality barcodes, where the adaptive threshold may produce occasional errors. By requiring multiple identical reads, the scanner can filter out the errors. Honeywell's printer command reference lists redundancy levels from 'Auto Mode' up to 'read code 45X'. |

|
Section 24: The Adaptive Threshold and the 'Center Decode' Feature |
Some scanners have a 'Center Decode' feature, which restricts decoding to the center of the scanner's field of view. This feature is useful when multiple barcodes are close together, as it prevents the scanner from reading the wrong barcode. The Center Decode feature is independent of the adaptive threshold, but it is part of the overall decoding strategy. |
Honeywell's CT40 and CT47 user manuals describe the Center Decode feature, which 'enables the imager to scan and decode a barcode only if part of the barcode is at the center of the aimer window'. This feature does not affect the threshold calculation; it simply restricts which part of the image is considered for decoding. |
Section 25: The Adaptive Threshold and the 'ROI Threshold' |
Datalogic's scanners have a 'ROI Threshold' setting, which defines the region of interest (ROI) for the decoder. The ROI Threshold specifies the minimum contrast within the ROI. If the contrast is below this threshold, the decoder will ignore the ROI. This is a way to filter out low-contrast areas of the image. |
The ROI Threshold is related to the adaptive threshold. The adaptive threshold sets the decision point for the comparator, while the ROI Threshold sets a minimum quality level for the image. Both are used to ensure reliable decoding. |

|
Section 26: The Adaptive Threshold and the 'Minimum 2D Contrast' |
Datalogic's manual mentions a 'Minimum 2D Contrast' setting. If the automatic threshold is disabled, the user must specify the minimum contrast between black and white. The contrast is defined as the difference between the white level and the black level. For example, if the white level is 158 and the black level is 58, the contrast is 100. The user adds an extra 10% for error, giving a Minimum 2D Contrast value of 90. |
This manual setting is essentially a fallback if the automatic threshold is not suitable. It allows the user to manually set a threshold that is appropriate for their specific barcode. However, the automatic threshold is the default and is usually the best choice. |
Section 27: The Adaptive Threshold and the 'Object Sense' Mode |
Datalogic's TC1200 scanner has an 'Automatic (Object Sense)' operating mode, where the scanner is normally in a low-power 'Object Sense' state. When an object is detected, the scanner enters the 'Automatic' mode and starts scanning. The 'Automatic Threshold' setting determines how many scans without a code will cause the scanner to return to the Object Sense state. |
This mode is designed for applications where objects are presented intermittently. The Automatic Threshold ensures that the scanner does not stay in the scanning mode for too long, which would waste power. This is a system-level feature that works in conjunction with the adaptive threshold. |

|
Section 28: The Adaptive Threshold and the 'Ternary Barcode' |
The paper on the dual-threshold ternary barcode detection system notes that the system is 'adaptable to any ternary barcode pattern through the attenuation of an enveloped line of a detected barcode signal and subtraction from the original barcode signal'. The two thresholds are generated by attenuating the envelope to two levels. |
This is a clever way to generate the thresholds without using peak detectors. The envelope is generated by a low-pass filter, and then attenuated to create the two reference levels. The two thresholds are then subtracted from the original signal to create the dual-threshold detection. |
Section 29: The Adaptive Threshold and the '2D Ternary Barcode' |
The follow-up paper on the 2D ternary barcode detection system extends the dual-threshold concept to two dimensions. The system uses a time-sharing laser emission method to effectively double the scanning speed. The prototype system successfully detected barcodes at a maximum scanning speed of 835 scans per second, which is 16 times faster than conventional CCD cameras. |
This work demonstrates that the adaptive threshold concept can be extended to more advanced barcode formats. The dual-threshold approach is a powerful technique for handling the greater complexity of ternary barcodes. |

|
Section 30: The Adaptive Threshold and the 'Reflectance Profile' |
MicroVision's patent describes the adaptive threshold based on the 'first derivative of a reflectance profile'. The reflectance profile is the signal from the photodetector. The first derivative is the rate of change of the reflectance. The threshold is set based on the derivative amplitude. |
This technique is more advanced than the simple peak detector. It takes into account the shape of the signal, not just its peak and valley. The derivative-based threshold can provide better noise immunity and more accurate edge detection. |
Section 31: The Adaptive Threshold and the 'Static and Dynamic Portion' |
MicroVision's patent also describes the threshold as comprising a 'static portion' and a 'dynamic portion'. The static portion is a constant value, and the dynamic portion is based on the charge or discharge profile of a capacitor. The threshold is set lower when the derivative is lower, and higher when the derivative is higher. |
This approach provides a more nuanced threshold that adapts to both the amplitude and the shape of the signal. It is a more sophisticated implementation of the adaptive threshold concept. |

|
Section 32: The Adaptive Threshold and the 'Automatic Threshold' in Datalogic's AV7000 |
Datalogic's AV7000 product manual describes the 'Automatic Threshold' as a setting that 'enables the decode engine [to] automatically determine the contrast between white and black in the bar codes'. The user can also select 'Minimum 2D Contrast' to specify the minimum contrast manually. |
This illustrates the two levels of control that are often provided: an automatic mode that works well in most cases, and a manual mode for fine-tuning. The automatic mode is based on an algorithm, while the manual mode relies on the user's knowledge of the specific application. |
Section 33: The Adaptive Threshold and the 'Signal Averaging' |
Some scanners use a technique called 'signal averaging' to improve the robustness of the adaptive threshold. The signal averaging is a digital filter that smooths the signal, reducing the noise. The averaged signal is then used to calculate the adaptive threshold. |
The signal averaging is usually implemented in the firmware. The ADC samples the signal at a high rate, and the firmware calculates a running average. The running average is then used to generate the adaptive threshold. This technique is commonly used in 2D imagers. |

|
Section 34: The Adaptive Threshold and the 'Histogram Method' |
The histogram method is the most common way to calculate the adaptive threshold for 2D barcodes. The histogram is a graph of the pixel values. The two peaks in the histogram correspond to the black and white areas of the barcode. The threshold is set to the midpoint between the two peaks. |
The histogram method is robust and easy to implement. It works well for images that have a bimodal distribution of pixel values. The histogram method is used in most 2D barcode decoders, including those from Honeywell and Datalogic. |
Section 35: The Adaptive Threshold and the 'Local Threshold' |
In some cases, a single global threshold is not sufficient. The image may have varying contrast across the barcode. In this case, a local threshold is used. The local threshold is calculated for each pixel based on the surrounding pixels. |
The local threshold is more computationally intensive than the global threshold. It is used in high-end 2D barcode decoders that need to handle challenging images. The local threshold is implemented in the firmware. |

|
Section 36: The Adaptive Threshold - A Summary of Best Practices |
Based on our exploration, let us summarize the best practices for implementing the adaptive threshold in a barcode scanner: |
1. Use an Adaptive Threshold: A fixed threshold is not sufficient for reliable barcode reading. An adaptive threshold is essential. |
2. Choose an Implementation Method: For laser scanners, the analog peak detector is a proven, reliable solution. For imagers, the digital histogram method is the standard. |
3. Set the Time Constant Appropriately: For analog peak detectors, the time constant must be long enough to hold the peak during the barcode, but short enough to track changes in ambient light. |
4. Consider Advanced Techniques: For demanding applications, consider using a derivative-based threshold (MicroVision) or a dual-threshold system (for ternary barcodes). |
5. Provide User Control: Allow the user to adjust the 'Decode Security' or 'Minimum Contrast' settings to fine-tune the scanner's performance. |
6. Integrate with Other Features: The adaptive threshold works in conjunction with hysteresis, redundancy checks, and center decoding to provide reliable barcode reading. |
7. Test the Scanner: The scanner must be tested with a variety of barcodes, under a variety of lighting conditions, to ensure that the adaptive threshold is working correctly. |

|
Final Summary |
The adaptive threshold is one of the most important innovations in barcode scanning. It solves the fundamental problem of the fixed threshold, which cannot adapt to variations in label contrast, scanning distance, and ambient light. The adaptive threshold tracks the signal's average level, setting the decision point to the midpoint between the black and white levels. |
We have seen how major companies have implemented the adaptive threshold in their products. Symbol's LS2208 uses a classic analog peak detector, which is simple, robust, and effective. Honeywell uses a digital adaptive threshold in their imagers, which provides greater accuracy and flexibility. Datalogic uses an automatic threshold adjustment, which automatically determines the contrast. MicroVision has developed a derivative-based adaptive threshold, which provides better noise immunity. Researchers have developed dual-threshold systems for ternary barcodes. |
The adaptive threshold is not a single circuit but a family of techniques. The analog peak detector is a classic solution that is still widely used. The digital histogram method is the standard for 2D imagers. Advanced techniques, such as the derivative-based threshold and the dual-threshold system, are used in specialized applications. |
The adaptive threshold works in conjunction with the comparator and the decoder. The comparator makes the binary decision, and the decoder measures the bar widths. The adaptive threshold ensures that the decision is made at the optimal point, maximizing the decoder's accuracy. The adaptive threshold is the key to reliable, robust barcode reading across a wide range of conditions. |