A method and system for adaptive adjustment of a code disc (CCD) threshold

By adaptively adjusting the integration time and edge threshold of the code disk CCD, combined with LED brightness adjustment, the problem of low accuracy in code disk angle reading was solved, achieving stable and accurate reading of the code disk output waveform.

CN116295548BActive Publication Date: 2025-11-21SOUTH SURVEYING & MAPPING INSTR
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211608047.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-14
Publication Date
2025-11-21
Estimated Expiration
2042-12-14

AI Technical Summary

Technical Problem

Existing technologies fail to effectively adjust the edge threshold of the output waveform of the code disk CCD, resulting in low accuracy of the code disk angle reading. Furthermore, the difference in LED brightness caused by mirror mounting affects the accuracy of the code disk.

Method used

By adaptively adjusting the integration time and edge threshold of the CCD, the output waveform of the encoder is ensured to be within a stable voltage range. The CCD waveform signal is smoothed by interpolation acquisition and amplitude limiting shaping to determine the edge threshold and improve reading accuracy. The brightness difference is corrected by adaptively adjusting the brightness of the LED.

Benefits of technology

It improves the accuracy of the encoder angle reading, enhances the linearity and precision of the encoder, and ensures the accuracy of the encoder output waveform.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116295548B_ABST
    Figure CN116295548B_ABST
Patent Text Reader

Abstract

The present application relates to the field of surveying and mapping, and proposes a code disc CCD threshold adaptive adjustment method and system, which comprises the following steps: comparing the current output voltage signal of the CCD device with the preset voltage threshold, adaptively adjusting the integration time to obtain a CCD waveform signal meeting the stable voltage range; interpolating and collecting the CCD waveform signal, limiting and shaping the CCD waveform signal according to the preset collection deviation threshold and the corresponding collection value of the CCD waveform signal, to obtain a smoothed CCD waveform signal; determining the edge threshold of the current CCD waveform signal according to the smoothed CCD waveform signal, and determining the rising edge and falling edge of the current CCD waveform signal according to the edge threshold. The present application adaptively adjusts the integration time parameter of the CCD and the edge threshold of the CCD waveform signal, so as to ensure that the code disc can correctly capture the edges of the output waveform, and further improve the code disc angle reading accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of surveying and mapping technology, and more specifically, to an adaptive adjustment method and system for the threshold of a code disk CCD. Background Technology

[0002] Absolute code disks possess absolute position, high accuracy, no need for zeroing upon startup, and no cumulative error, making them widely used in surveying instruments. In this system, light from the source passes through the transparent area of ​​the grating and is received by the CCD (charge-coupled device), outputting a "1". If the light is blocked by an opaque area, the output is "0", and the combination of codes represents the instrument's absolute position. Due to differences between CCD devices, the CCD's output voltage may exceed the AD's acquisition range. The CCD's integration time determines the CCD's exposure; too long or too short an integration time will cause saturation and distortion of the CCD's output signal, failing to accurately reflect the measured information. Furthermore, the code disk reading depends on the edge changes of the CCD output waveform. Therefore, adjusting the CCD output waveform within a reasonable voltage range and determining the CCD edge judgment threshold are crucial.

[0003] Currently, methods for adaptively adjusting the CCD integration time have been proposed. These methods employ mean-median filtering to filter pixel amplitude, correcting the ratio between integration time and maximum amplitude, and then adjusting the integration time based on this corrected ratio. However, this method only considers the adjustment of the integration time and neglects the importance of edge threshold adjustment in the code disk output waveform, resulting in insufficient accuracy in code disk angle readings. Furthermore, high-precision absolute code disks require at least two LEDs and a CCD, mounted 180° opposite a mirror. Due to the mirror, the brightness of the two LEDs differs, causing poor linearity in the code disk angle and affecting its accuracy. Summary of the Invention

[0004] To overcome the shortcomings of the prior art, which does not consider the importance of edge threshold adjustment of the code disk output waveform and has low accuracy of code disk angle reading, this invention provides an adaptive adjustment method and system for the CCD threshold of the code disk.

[0005] To solve the above-mentioned technical problems, the technical solution of the present invention is as follows:

[0006] An adaptive adjustment method for the threshold of a code disk CCD includes the following steps:

[0007] S1. Compare the current output voltage signal of the CCD device with the preset voltage threshold, and adaptively adjust the integration time to obtain a CCD waveform signal that meets the stable voltage range.

[0008] S2. Interpolate and acquire the CCD waveform signal. Based on the preset acquisition deviation threshold and the corresponding acquisition value of the CCD waveform signal, perform amplitude limiting and shaping on the CCD waveform signal to obtain a smoothed CCD waveform signal.

[0009] S3. Based on the smoothed CCD waveform signal, determine the edge threshold of the current CCD waveform signal, and determine the rising edge and falling edge of the current CCD waveform signal based on the edge threshold.

[0010] In this technical solution, the voltage of the code disk output waveform is kept stable within the target range by adaptively adjusting the integration time; the edge threshold of the CCD waveform is adjusted adaptively to ensure that the code disk can correctly capture the edge of the output waveform, thereby improving the accuracy of the code disk angle reading.

[0011] As a preferred approach, the steps for adaptively adjusting the integration time include:

[0012] The current output voltage signal of the CCD device is compared with a preset voltage threshold: when the voltage signal value is greater than the preset first voltage threshold, the integration time is reduced; when the voltage signal value is less than the preset second voltage threshold, the integration time is increased; wherein, the first voltage threshold is greater than the second voltage threshold.

[0013] As a preferred approach, the steps for interpolating and acquiring CCD waveform signals include:

[0014] The CCD waveform signal of the current period is divided into M acquisition values, denoted as f0, f1, ..., f M-1 Where M is the number of pixels in the CCD device;

[0015] For any two adjacent collected values ​​f i-1 and f i , in f i-1 and f i Interpolation f between x =(f i-1 +f i ); where i = 1, 2, ..., M-1.

[0016] As a preferred approach, the steps for amplitude limiting and shaping the CCD waveform signal include:

[0017] The maximum allowable deviation between two samplings is determined as the acquisition deviation threshold.

[0018] Each time a new collected value is processed, it is determined whether the difference between the current collected value and the previous collected value is less than or equal to the collected deviation threshold. If so, the current collected value is retained; otherwise, the current collected value is deleted.

[0019] As a preferred embodiment, the steps of determining the edge threshold of the current CCD waveform signal and determining the rising and falling edges of the current CCD waveform signal based on the edge threshold include:

[0020] One-third of the signal values ​​from the smoothed CCD waveform signal are filtered and averaged to serve as the edge threshold V0.

[0021] For any signal value of the smoothed CCD waveform signal, the following criteria are applied: if the current signal value is less than the edge threshold V0, the current signal value is determined to be the falling edge of the waveform; otherwise, the current signal value is determined to be the rising edge of the waveform.

[0022] Furthermore, in step S3, starting from the CCD waveform signal of the 3rd frame or any frame after the 3rd frame, 1 / 3 of the signal values ​​are filtered and averaged, and then used as the edge threshold V0.

[0023] As a preferred embodiment, for a code disk that includes paired LEDs and a CCD device, the following steps are also included:

[0024] The CCD device includes a first CCD device and a second CCD device, which operate synchronously; the LED light includes a first LED light and a second LED light, which are arranged opposite to each other.

[0025] When the waveform signal value of the first CCD device is greater than the waveform signal value of the second CCD device, the brightness of the second LED is increased.

[0026] When the waveform signal value of the first CCD device is less than the waveform signal value of the second CCD device, the brightness of the second LED is reduced.

[0027] Furthermore, this invention also proposes an adaptive adjustment system for the CCD threshold of the code disk, applying the adaptive adjustment method for the CCD threshold of the code disk proposed in any of the above-mentioned technical solutions. The adaptive adjustment system includes:

[0028] The integral time adaptive adjustment module is used to compare the current output voltage signal of the CCD device with a preset voltage threshold and adaptively adjust the integral time to obtain a CCD waveform signal that meets the stable voltage range.

[0029] The waveform adaptive shaping module is used to interpolate and acquire the CCD waveform signal. Based on the preset acquisition deviation threshold and the corresponding acquisition value of the CCD waveform signal, the module performs amplitude limiting and shaping on the CCD waveform signal to obtain a smoothed CCD waveform signal.

[0030] An edge threshold adaptive adjustment module is used to determine the edge threshold of the current CCD waveform signal based on the smoothed CCD waveform signal, and to determine the rising edge and falling edge of the current CCD waveform signal based on the edge threshold.

[0031] As a preferred embodiment, the system is applied to a code disk including at least two LEDs and at least two CCD devices; the system further includes a brightness adaptive adjustment module for adaptively adjusting the brightness of the second LED based on the waveform signal values ​​of the first CCD device and the second CCD device.

[0032] Specifically, when the waveform signal value of the first CCD device is greater than the waveform signal value of the second CCD device, the brightness of the second LED is increased.

[0033] When the waveform signal value of the first CCD device is less than the waveform signal value of the second CCD device, the brightness of the second LED is reduced.

[0034] Furthermore, the present invention also proposes a computer-readable storage medium storing a computer program thereon, wherein when the computer program is executed by a processor, it implements the steps of the adaptive adjustment method for the CCD threshold proposed in any of the above technical solutions.

[0035] Compared with the prior art, the beneficial effects of the technical solution of the present invention are: the present invention adaptively adjusts the integration time parameter of the CCD so that the voltage of the output waveform of the code disk is controlled within the target range, ensuring that the output signal of the CCD will not be saturated and distorted; the present invention adaptively adjusts the edge threshold of the CCD waveform signal to ensure that the code disk can correctly capture the edge of the output waveform, thereby improving the accuracy of the code disk angle reading. Attached Figure Description

[0036] Figure 1 This is a flowchart of the adaptive adjustment method for the CCD threshold of the code disk according to the present invention.

[0037] Figure 2 This is a schematic diagram of the CCD driving timing in Example 1.

[0038] Figure 3 This is a schematic diagram illustrating the principle of CCD waveform signal interpolation acquisition in Example 1.

[0039] Figure 4 This is a schematic diagram illustrating the principle of CCD waveform signal limiting and shaping in Example 1.

[0040] Figure 5 This is a schematic diagram of the CCD waveform before amplitude limiting and shaping in Example 1.

[0041] Figure 6This is a schematic diagram of the CCD waveform after amplitude limiting and shaping in Example 1.

[0042] Figure 7 This is a schematic diagram illustrating the principle of CCD waveform signal edge determination in Example 1.

[0043] Figure 8 This is a schematic diagram of the encoder mirror structure.

[0044] Figure 9 This is an architecture diagram of the adaptive adjustment system for the CCD threshold of the code disk according to the present invention. Detailed Implementation

[0045] The accompanying drawings are for illustrative purposes only and should not be construed as limiting the scope of this patent.

[0046] To better illustrate this embodiment, some parts in the accompanying drawings may be omitted, enlarged, or reduced, and do not represent the actual product dimensions.

[0047] It will be understood by those skilled in the art that certain well-known structures and their descriptions may be omitted in the accompanying drawings.

[0048] The technical solution of the present invention will be further described below with reference to the accompanying drawings and embodiments.

[0049] Example 1

[0050] This embodiment proposes an adaptive adjustment method for the CCD threshold, such as... Figure 1 The diagram shown is a flowchart of the adaptive adjustment method for the CCD threshold in this embodiment.

[0051] The adaptive adjustment method for the CCD threshold proposed in this embodiment includes the following steps:

[0052] S1. Compare the current output voltage signal of the CCD device with the preset voltage threshold, and adaptively adjust the integration time to obtain a CCD waveform signal that meets the stable voltage range.

[0053] S2. Interpolate and acquire the CCD waveform signal. Based on the preset acquisition deviation threshold and the corresponding acquisition value of the CCD waveform signal, perform amplitude limiting and shaping on the CCD waveform signal to obtain a smoothed CCD waveform signal.

[0054] S3. Based on the smoothed CCD waveform signal, determine the edge threshold of the current CCD waveform signal, and determine the rising edge and falling edge of the current CCD waveform signal based on the edge threshold.

[0055] In this embodiment, the CCD driving timing is as follows: Figure 2As shown, M is the main clock frequency, SH is the integration signal, ICG is the reset signal, and OS is the waveform output. Considering that the integration time of the CCD determines the exposure of the CCD, a longer integration time allows the photosensitive unit to absorb sufficient light information; however, if the integration time is too long, the output signal of the CCD will be saturated and distorted, and cannot accurately reflect the information to be measured.

[0056] This embodiment adaptively adjusts the integration time of the CCD to control the voltage of the code disk output waveform within the target range, so that the CCD output signal will not saturate or become distorted.

[0057] In one optional embodiment, the step of adaptively adjusting the integration time includes: comparing the current output voltage signal of the CCD device with a preset voltage threshold; when the voltage signal value is greater than a preset first voltage threshold, starting to decrease the integration time; when the voltage signal value is less than a preset second voltage threshold, starting to increase the integration time; wherein the first voltage threshold is greater than the second voltage threshold.

[0058] In one specific embodiment, the first voltage threshold is set to 2V and the second voltage threshold is set to 1V, so that the voltage of the encoder output waveform is stabilized within the target range of 1V to 2V.

[0059] In another specific embodiment, for a code disk with a CCD clock frequency of 2MHz and a CCD power supply voltage of 3.3V, the method of this embodiment is applied for adaptive adjustment of the integration time. The smaller the peak difference of the CCD waveform, the flatter the waveform, the better the linearity of the code disk angle value, and the higher the accuracy.

[0060] In this embodiment, considering that the code disk reading needs to accurately capture the edges of the output waveform, it is necessary to determine an appropriate CCD waveform edge threshold. However, the installation position and distance of the code disk vary among different instruments, resulting in different CCD waveform edge thresholds. Therefore, it is necessary to adaptively determine the CCD waveform edge threshold.

[0061] In this embodiment, when adaptively determining the edge threshold of the CCD waveform, the CCD waveform is first shaped. Specifically, in this embodiment, the CCD waveform signal is interpolated and acquired. Based on the preset acquisition deviation threshold and the corresponding acquisition value of the CCD waveform signal, the CCD waveform signal is amplitude-limited and shaped to obtain a smoothed CCD waveform signal.

[0062] In an optional embodiment, the step of interpolating and acquiring the CCD waveform signal includes:

[0063] The CCD waveform signal of the current period is divided into M acquisition values, denoted as f0, f1, ..., f M-1Where M is the number of pixels in the CCD device. For any two adjacent acquired values ​​f i-1 and f i , in f i-1 and f i Interpolation f between x =(f i-1 +f i ); where i = 1, 2, ..., M-1.

[0064] like Figure 3 The diagram shown is a schematic of the CCD waveform signal interpolation acquisition in this embodiment.

[0065] In one specific embodiment, the CCD has 600 pixels, and the pixel acquisition values ​​are f0, f1, ..., f 599 For any two adjacent collected values ​​f i-1 and f i , in f i-1 and f i Interpolation f between x =(f i-1 +f i ); where i = 1, 2, ..., 598. The number of pixel acquisition values ​​of the CCD is doubled to 1200 through interpolation, and then the waveform of the CCD is shaped.

[0066] In an optional embodiment, the step of limiting and shaping the CCD waveform signal includes:

[0067] The maximum allowable deviation between two samplings is determined as the acquisition deviation threshold.

[0068] Each time a new collected value is processed, it is determined whether the difference between the current collected value and the previous collected value is less than or equal to the collected deviation threshold. If so, the current collected value is retained; otherwise, the current collected value is deleted.

[0069] like Figure 4 The diagram shown illustrates the principle of amplitude limiting and shaping in this embodiment. U2 represents the upper limit amplitude voltage, and U1 represents the lower limit amplitude voltage. For waveforms exceeding the range of U1 to U2 and surpassing the deviation threshold, the corresponding acquired values ​​are deleted, resulting in a CCD waveform with smooth upper and lower boundaries.

[0070] In one specific embodiment, the experimental results before and after amplitude limiting and shaping are as follows: Figure 5 , 6 As shown in the figure, after the CCD waveform signal is subjected to amplitude limiting and shaping processing, irregular interference caused by chance can be removed, thereby improving the smoothness of the upper and lower boundaries of the waveform.

[0071] After shaping the CCD waveform, a smoothed CCD waveform signal is obtained, and the edge threshold of the current CCD waveform signal is determined from it.

[0072] In an optional embodiment, the step of determining an edge threshold of the current CCD waveform signal and determining the rising and falling edges of the current CCD waveform signal based on the edge threshold includes:

[0073] One-third of the signal values ​​from the smoothed CCD waveform signal are filtered and averaged to serve as the edge threshold V0.

[0074] For any signal value of the smoothed CCD waveform signal, the following criteria are applied: if the current signal value is less than the edge threshold V0, the current signal value is determined to be the falling edge of the waveform; otherwise, the current signal value is determined to be the rising edge of the waveform.

[0075] like Figure 7 The diagram shown is a schematic representation of the principle of CCD edge determination in this embodiment.

[0076] In the specific implementation process, the voltage value of the CCD waveform signal is acquired by AD acquisition.

[0077] Alternatively, starting from the CCD waveform signal of the 3rd frame or any frame thereafter, one-third of the signal values ​​are filtered and averaged, and this value is used as the edge threshold V0.

[0078] In this embodiment, considering that the data of the first two frames is not yet stable and contains a lot of noise when the CCD device is powered on, the CCD waveform signal of the third frame or any frame after the third frame is selected as the starting point to calculate the edge threshold of the current CCD waveform signal.

[0079] Furthermore, considering that an absolute code disk with only one LED and CCD would cause significant eccentricity, a high-precision absolute code disk requires at least two LEDs and a CCD, mounted at a 180° angle to the mirror, to correct this eccentricity. Figure 8 The diagram shows a schematic of the encoder disk with a mirror. The final absolute encoder disk angle output value is the average of the two CCD output values. Due to the presence of the mirror, the brightness of the two LEDs differs, resulting in poor linearity of the encoder disk angle output value and affecting the encoder disk accuracy. Therefore, it is necessary to adaptively adjust the brightness of the mirror LEDs.

[0080] In an alternative embodiment, for a code disk comprising a pair of LEDs and a CCD device, the following steps are further included:

[0081] The CCD device includes a first CCD device and a second CCD device, which operate synchronously; the LED light includes a first LED light and a second LED light, which are arranged opposite to each other.

[0082] When the waveform signal value of the first CCD device is greater than the waveform signal value of the second CCD device, the brightness of the second LED is increased.

[0083] When the waveform signal value of the first CCD device is less than the waveform signal value of the second CCD device, the brightness of the second LED is reduced.

[0084] In the specific implementation process, when the encoder is powered on, the parameters of the two CCD devices are initialized to ensure that the parameters of the two CCD devices are completely consistent. At this time, the output voltage of the two CCD devices is collected, and the output waveform of CCD1 is used as a reference. When the output value of CCD1 is greater than the output value of CCD2, the brightness of LED2 is increased; when the output value of CCD1 is less than the output value of CCD2, the brightness of LED2 is decreased.

[0085] This embodiment ensures stable output values ​​of the two CCD devices by adaptively adjusting the brightness of the mirror LED, thereby improving the linearity of the code disk angle output value and increasing the accuracy of the code disk.

[0086] Example 2

[0087] This embodiment proposes an adaptive adjustment system for the CCD threshold of a code disk, applying the adaptive adjustment method for the CCD threshold of a code disk proposed in Embodiment 1. For example... Figure 9 The diagram shown is an architecture diagram of the adaptive adjustment system for the CCD threshold of the encoder disk in this embodiment.

[0088] The adaptive adjustment system for the CCD threshold proposed in this embodiment includes:

[0089] The integral time adaptive adjustment module is used to compare the current output voltage signal of the CCD device with a preset voltage threshold and adaptively adjust the integral time to obtain a CCD waveform signal that meets the stable voltage range.

[0090] The waveform adaptive shaping module is used to interpolate and acquire the CCD waveform signal. Based on the preset acquisition deviation threshold and the corresponding acquisition value of the CCD waveform signal, the module performs amplitude limiting and shaping on the CCD waveform signal to obtain a smoothed CCD waveform signal.

[0091] An edge threshold adaptive adjustment module is used to determine the edge threshold of the current CCD waveform signal based on the smoothed CCD waveform signal, and to determine the rising edge and falling edge of the current CCD waveform signal based on the edge threshold.

[0092] The adaptive adjustment system for the CCD threshold of the code disk in this embodiment is connected to the CCD device and AD converter on the code disk. It is used to acquire the current output voltage waveform signal and pixel acquisition value, and to adaptively adjust the integration time, waveform amplitude and edge threshold of the CCD device to improve the accuracy of the code disk angle reading.

[0093] Furthermore, in an optional embodiment, when the integration time adaptive adjustment module adaptively adjusts the integration time, it compares the current output voltage signal of the CCD device with a preset voltage threshold: when the voltage signal value is greater than a preset first voltage threshold, it starts to decrease the integration time; when the voltage signal value is less than a preset second voltage threshold, it starts to increase the integration time; wherein, the first voltage threshold is greater than the second voltage threshold.

[0094] After the integral time adaptive adjustment module completes the adaptive adjustment of the integral time, it outputs a CCD waveform signal that meets the stable voltage range to the waveform adaptive shaping module.

[0095] In one optional embodiment, when the waveform adaptive shaping module performs interpolation acquisition on the CCD waveform signal, specifically, the CCD waveform signal of the current period is divided into M acquisition values, represented as f0, f1, ..., f M-1 Where M is the number of pixels in the CCD device; for any two adjacent acquired values ​​f i-1 and f i , in f i-1 and f i Interpolation f between x =(f i-1 +f i ); where i = 1, 2, ..., M-1; finally, a waveform signal with doubled pixel acquisition values ​​is obtained.

[0096] Furthermore, when the waveform adaptive shaping module performs amplitude limiting shaping on the CCD waveform signal, it first determines the maximum allowable deviation value between two samplings as the acquisition deviation threshold. Then, when processing a new acquisition value each time, it determines whether the difference between the current acquisition value and the previous acquisition value is less than or equal to the acquisition deviation threshold. If so, the current acquisition value is retained; otherwise, the current acquisition value is deleted.

[0097] After completing the amplitude limiting and shaping of the current CCD waveform signal, the waveform adaptive shaping module outputs a smoothed CCD waveform signal to the edge threshold adaptive adjustment module.

[0098] In one optional embodiment, when determining the edge threshold of the current CCD waveform signal, the edge threshold adaptive adjustment module takes one-third of the signal values ​​from the smoothed CCD waveform signal, performs filtering and averaging processing, and uses this as the edge threshold V0. Then, it judges any signal value of the smoothed CCD waveform signal: if the current signal value is less than the edge threshold V0, the current signal value is determined to be a falling edge of the waveform; otherwise, the current signal value is determined to be a rising edge of the waveform. This edge threshold adaptive adjustment effectively improves the angle reading accuracy of the encoder.

[0099] Optionally, the edge threshold adaptive adjustment module takes the CCD waveform signal from the 3rd frame or any frame after the 3rd frame as the starting point, takes 1 / 3 of the signal values, performs filtering and averaging processing, and then uses it as the edge threshold V0.

[0100] In another optional embodiment, the system further includes a brightness adaptive adjustment module. For a code disk comprising paired LEDs and CCD devices, the brightness adaptive adjustment module is used to adaptively adjust the brightness of the second LED based on the magnitudes of the waveform signal values ​​of the first CCD device and the second CCD device.

[0101] In one specific implementation, the brightness adaptive adjustment module is connected to the first CCD device, the second CCD device, and the second LED, respectively, and judges the waveform signal values ​​of the first CCD device and the second CCD device: when the waveform signal value of the first CCD device is greater than the waveform signal value of the second CCD device, the brightness of the second LED is increased; when the waveform signal value of the first CCD device is less than the waveform signal value of the second CCD device, the brightness of the second LED is decreased.

[0102] Example 3

[0103] This embodiment proposes a computer-readable storage medium storing a computer program thereon. When the computer program is executed by a processor, it implements the steps of the adaptive adjustment method for the CCD threshold proposed in Embodiment 1 above.

[0104] The same or similar labels correspond to the same or similar parts;

[0105] The terms used to describe positional relationships in the accompanying drawings are for illustrative purposes only and should not be construed as limiting this patent.

[0106] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the implementation of the present invention. Those skilled in the art can make other variations or modifications based on the above description. It is neither necessary nor possible to exhaustively describe all embodiments here. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the claims of the present invention.

Claims

1. An adaptive adjustment method for the threshold of a code disk CCD, characterized in that, Includes the following steps: S1. Compare the current output voltage signal of the CCD device with the preset voltage threshold, and adaptively adjust the integration time to obtain a CCD waveform signal that meets the stable voltage range. S2. Interpolate and acquire the CCD waveform signal. Based on the preset acquisition deviation threshold and the corresponding acquisition value of the CCD waveform signal, perform amplitude limiting and shaping on the CCD waveform signal to obtain a smoothed CCD waveform signal. The step of interpolating and acquiring the CCD waveform signal includes: The CCD waveform signal of the current period is divided into: M Each collected value is represented as f 0, f 1, ..., f M-1 ;in, M The number of pixels in a CCD device; For any two adjacent collected values f i-1 and f i ,exist f i-1 and f i Interpolation between f x =( f i-1 + f i );in i =1,2,..., M -1; The step of limiting and shaping the CCD waveform signal includes: The maximum allowable deviation between two samplings is determined as the acquisition deviation threshold. Each time a new collected value is processed, it is determined whether the difference between the current collected value and the previous collected value is less than or equal to the collected deviation threshold. If so, the current collected value is retained; otherwise, the current collected value is deleted. S3. Based on the smoothed CCD waveform signal, determine the edge threshold of the current CCD waveform signal, and determine the rising edge and falling edge of the current CCD waveform signal based on the edge threshold, including: One-third of the signal values ​​from the smoothed CCD waveform signal are filtered and averaged, and then used as the edge threshold. V 0; For any signal value of the smoothed CCD waveform signal, determine: if the current signal value is less than the edge threshold... V If the value is 0, the current signal value is determined to be the falling edge of the waveform; otherwise, the current signal value is determined to be the rising edge of the waveform.

2. The adaptive adjustment method for the CCD threshold according to claim 1, characterized in that, In step S1, the step of adaptively adjusting the integration time includes: The current output voltage signal of the CCD device is compared with a preset voltage threshold: when the voltage signal value is greater than the preset first voltage threshold, the integration time is reduced; when the voltage signal value is less than the preset second voltage threshold, the integration time is increased; wherein, the first voltage threshold is greater than the second voltage threshold.

3. The adaptive adjustment method for the CCD threshold according to claim 1, characterized in that, In step S3, starting from the CCD waveform signal of the 3rd frame or any frame thereafter, one-third of the signal values ​​are filtered and averaged, and then used as the edge threshold. V 0.

4. The adaptive adjustment method for the CCD threshold according to any one of claims 1 to 3, characterized in that, For code disks that include paired LEDs and CCD devices, the following steps are also included: The CCD device includes a first CCD device and a second CCD device, which operate synchronously; the LED light includes a first LED light and a second LED light, which are arranged opposite to each other. When the waveform signal value of the first CCD device is greater than the waveform signal value of the second CCD device, the brightness of the second LED is increased. When the waveform signal value of the first CCD device is less than the waveform signal value of the second CCD device, the brightness of the second LED is reduced.

5. An adaptive adjustment system for the threshold of a code disk CCD, employing the adaptive adjustment method for the threshold of a code disk CCD according to any one of claims 1 to 4, characterized in that, include: The integral time adaptive adjustment module is used to compare the current output voltage signal of the CCD device with a preset voltage threshold and adaptively adjust the integral time to obtain a CCD waveform signal that meets the stable voltage range. The waveform adaptive shaping module is used to interpolate and acquire the CCD waveform signal. Based on the preset acquisition deviation threshold and the corresponding acquisition value of the CCD waveform signal, the module performs amplitude limiting and shaping on the CCD waveform signal to obtain a smoothed CCD waveform signal. An edge threshold adaptive adjustment module is used to determine the edge threshold of the current CCD waveform signal based on the smoothed CCD waveform signal, and to determine the rising edge and falling edge of the current CCD waveform signal based on the edge threshold.

6. The adaptive adjustment system for the CCD threshold according to claim 5, characterized in that, The system is applied to a code disk including at least two LEDs and at least two CCD devices; the system also includes a brightness adaptive adjustment module for adaptively adjusting the brightness of the second LED based on the waveform signal values ​​of the first CCD device and the second CCD device. Specifically, when the waveform signal value of the first CCD device is greater than the waveform signal value of the second CCD device, the brightness of the second LED is increased. When the waveform signal value of the first CCD device is less than the waveform signal value of the second CCD device, the brightness of the second LED is reduced.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the adaptive adjustment method for the CCD threshold of the code disk as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Anti-interference decoding method and system

    CN106921463A

  • Linear array CCD optical integral time self-adaptive control method and apparatus

    CN1635780A