Printer paper taking state detection device capable of resisting ambient light interference and detection method thereof
By using dual-sensor components and adaptive threshold judgment logic, the problem of printer paper feeding status detection being easily interfered with by ambient light has been solved, achieving high-precision paper feeding status judgment and fault warning, thus improving the stability and ease of maintenance of the printer.
Patent Information
- Application Number
- CN202511617627.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-06
- Publication Date
- 2026-01-16
AI Technical Summary
Existing printer paper feed status detection devices are susceptible to interference from ambient light, leading to misjudgments and affecting stability and user experience.
A dual-sensor assembly, including a detection sensor and a reference sensor, is used to compensate for ambient light interference by calculating their voltage difference. The paper feeding status is determined by combining moving average filtering and adaptive threshold.
It improves the accuracy and stability of paper picking status judgment, reduces printing failures caused by misjudgment, and enhances the reliability and maintainability of the equipment.
Smart Images

Figure CN121340802A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to a printer paper taking state detection device and its detection method, which are not interfered by ambient light, and belongs to the field of printers. BACKGROUND
[0002] In the daily use of printers (especially thermal ticket printers and label printers), the paper taking sensor is the core component for determining whether the ticket or label is taken away by the user, and its detection accuracy directly determines the working stability of the printer. The current mainstream printers mostly use a single sensor to detect the paper taking state. The sensor outputs a corresponding voltage signal by receiving the intensity change of the reflected light or transmitted light of the paper, and then determines whether the paper exists.
[0003] However, the use scenarios of the printer are complex, and the intensity of the natural light in the environment often fluctuates (such as strong light irradiation in a shopping mall, weak light environment at night, indoor light switching, etc.). These ambient light will directly interfere with the light reception of the single sensor, causing the voltage signal output by the sensor to deviate from the true value, and leading to misjudgment of the paper taking state: for example, when the ambient light is too strong, even if the paper is not taken away, the sensor may misidentify it as a "no paper" state, causing the printer to stop printing in advance; when the ambient light is too weak, the paper has been taken away but may be misidentified as a "paper" state, causing the printer to jam, repeat printing and other faults, which seriously affects the user experience and increases the equipment maintenance cost. Therefore, there is an urgent need for a technical solution that can offset the interference of ambient light and improve the accuracy of paper taking state judgment to solve the defects of the existing single sensor detection method. SUMMARY
[0004] To overcome the defects of the prior art, the purpose of the present application is to provide a printer paper taking state detection device and method that are not interfered by ambient light, which offsets the interference of ambient light on the detection signal through the cooperative work of the double sensors and the difference judgment logic, realizes accurate and stable judgment of the paper taking state, and reduces the printing faults caused by misjudgment.
[0005] The present application provides a printer paper taking state detection device and its detection method that are not interfered by ambient light. The technical solution of the present application is as follows: A printer paper taking state detection device that is not interfered by ambient light, comprising a double sensor assembly, a printer control board and a key indicator light board. The double sensor assembly comprises a detection sensor and a reference sensor. The detection sensor is installed at the paper output path of the printer for detecting the paper state and outputting a real-time voltage value V1. The reference sensor is installed inside the printer in a position that is not blocked by the paper and has the same ambient light conditions as the detection sensor, and is used to output a reference voltage value V2. The printer control board is electrically connected to the detection sensor and the reference sensor respectively, and is used to collect the real-time voltage value V1 and the reference voltage value V2, and calculate their absolute difference |V1-V2|. The paper feeding status is determined based on the comparison result of the difference with the preset threshold T. The button indicator board is electrically connected to the printer control board and is used to receive calibration commands and display the working status of the device.
[0006] The printer control board includes a signal acquisition module, which is used to synchronously acquire real-time voltage value V1 and reference voltage value V2 at a sampling frequency of 1-5kHz, and filter the acquired signal to eliminate circuit noise. The difference calculation module is used to perform moving average filtering on the filtered real-time voltage value V1 and the reference voltage value V2, and calculate their absolute difference |V1-V2|. The status judgment module has a pre-stored threshold T, which is used to compare the absolute difference with the threshold T and output a judgment signal indicating whether the paper has been taken or not. The calibration control module is used to respond to calibration commands from the button indicator panel, store standard voltage values, and update the threshold T.
[0007] Both the detection sensor and the reference sensor are reflective photoelectric sensors or transmissive photoelectric sensors.
[0008] The button indicator panel includes calibration buttons, including a paperless calibration button and a paper-based calibration button; status indicator lights, including a sensor normal light to indicate that the sensor is working normally, a calibration complete light to indicate that the calibration operation is complete, and a sensor fault light to indicate that the sensor is malfunctioning.
[0009] When the calibration control module performs calibration: In response to the triggering of the paperless calibration key, the current real-time voltage value V1 and the reference voltage value V2 are recorded as standard values for the paperless state; in response to the triggering of the paper-present calibration key, the real-time voltage value V1 and the reference voltage value V2 when paper is present are recorded as standard values for the paper-present state; and the threshold T is calculated and updated based on the standard values for the paperless state and the standard values for the paper-present state.
[0010] It also includes a fault alarm unit. When the printer control board detects that the sensor is open-circuited, short-circuited, or the absolute difference is continuously abnormal, the status judgment module triggers the fault alarm unit to issue an audible and visual alarm and records the corresponding fault code.
[0011] A method for detecting the paper feeding status of a printer that is resistant to ambient light interference, the method comprising the following steps: Signal acquisition steps: Simultaneously acquire the real-time detection voltage value V1 output by the detection sensor and the reference voltage value V2 output by the reference sensor; Difference calculation steps: Filter the real-time detected voltage value V1 and the reference voltage value V2, and calculate their absolute difference D = |V1 - V2|; State determination step: Compare the absolute difference D with the preset sensor accuracy threshold T; If D < T, the paper is determined to have been taken; if D > T, the paper is determined to have not been taken. Control execution steps: Based on the result of the state judgment step, control the printer to perform the corresponding subsequent operations.
[0012] In the signal acquisition step, the detection voltage value V1 and the reference voltage value V2 are synchronously sampled using a sampling frequency of 1-5kHz, and circuit noise is filtered out. In the difference calculation step, the detection voltage value V1 and the reference voltage value V2 are filtered using a moving average filtering algorithm.
[0013] It also includes a calibration step: under standard ambient light conditions, trigger a paperless calibration command and record the detected voltage value V1 and the reference voltage value V2 collected at this time as the standard value of the paperless state; When the paper is in place, a paper calibration command is triggered, and the detection voltage value V1 and the reference voltage value V2 collected at this time are recorded as the standard values of the paper-containing state. Based on the standard values for the paperless state and the paper-containing state, the sensor accuracy threshold T is calculated and updated.
[0014] It also includes a fault monitoring step: real-time monitoring of the sensor's operating status and the absolute difference D; when an open circuit, short circuit, or absolute difference D is detected in the sensor, an audible and visual alarm is triggered and a fault code is recorded.
[0015] The advantages of this invention are: By using the difference between two identical sensors, the common-mode interference of ambient light on both can be offset (for example, when the ambient light is enhanced, the detection voltage value V1 and the reference voltage value V2 change in the same trend, and the difference is minimally affected). Compared with single-sensor detection, the detection accuracy is improved, and misjudgment caused by ambient light fluctuations is effectively avoided.
[0016] By employing a dual-sensor hardware layout, simple interpolation, and logical continuous sampling filtering, along with status de-jitter judgment, false triggering caused by transient interference is reduced. Furthermore, the addition of a reference sensor for fault monitoring provides early warning of maintenance needs, thereby lowering the equipment failure rate. Attached Figure Description
[0017] Figure 1 This is a block diagram of the main structure of the device of the present invention.
[0018] Figure 2 yes Figure 1A structural block diagram of the printer control board. Detailed Implementation
[0019] The present invention will be further described below with reference to specific embodiments, and the advantages and features of the present invention will become clearer as a result. However, these embodiments are merely exemplary and do not constitute any limitation on the scope of the present invention. Those skilled in the art should understand that modifications or substitutions can be made to the details and form of the technical solutions of the present invention without departing from the spirit and scope of the present invention, but all such modifications and substitutions fall within the protection scope of the present invention.
[0020] See Figure 1 and Figure 2 This invention relates to a printer paper feeding status detection device resistant to ambient light interference, comprising a dual-sensor assembly, a printer control board 1, and a button indicator board 4; the dual-sensor assembly includes a detection sensor 2 and a reference sensor 3, the detection sensor 2 is installed at the printer paper output path to detect the paper status and output a real-time voltage value V1; the reference sensor 3 is installed inside the printer in a position unobstructed by paper and with ambient light conditions consistent with those of the detection sensor, and outputs a reference voltage value V2; The printer control board 1 is electrically connected to the detection sensor 2 and the reference sensor 3 respectively, and is used to collect the real-time voltage value V1 and the reference voltage value V2, and calculate their absolute difference |V1-V2|. The paper feeding status is determined based on the comparison result of the difference with the preset threshold T. The button indicator board 4 is electrically connected to the printer control board 1 and is used to receive calibration commands and display the working status of the device.
[0021] By setting a reference sensor and calculating the difference (|V1-V2|) between it and the detection sensor, the common-mode interference caused by changes in ambient light to the two sensors can be offset. This transforms the judgment basis from the easily disturbed absolute voltage value to a stable relative difference, fundamentally improving the accuracy and reliability of the paper picking status judgment.
[0022] By continuously sampling and filtering the difference signal using the printer control board, and combining it with preset thresholds for logical judgment, this mechanism can effectively filter out instantaneous interference signals, prevent false triggering caused by signal jitter, and significantly reduce the probability of "paper present but not present" or "paper absent but present".
[0023] With an independent button and indicator light panel, users or maintenance personnel can perform convenient calibration operations under different ambient light conditions, enabling the system to adapt to different working environments, update judgment thresholds, and ensure the long-term applicability and detection consistency of the device under various lighting scenarios.
[0024] It integrates comprehensive status indication and fault alarm functions (such as sensor fault light, buzzer alarm and fault code recording), which can monitor the health status of sensors in real time and immediately prompt when abnormalities occur, greatly facilitating the daily maintenance and troubleshooting of the equipment, and effectively improving the maintainability and user experience of the equipment.
[0025] The printer control board includes a signal acquisition module 11, used to synchronously acquire real-time voltage value V1 and reference voltage value V2 at a sampling frequency of 1-5kHz, and filter the acquired signal to eliminate circuit noise; a difference calculation module 12, used to perform moving average filtering on the filtered real-time voltage value V1 and reference voltage value V2, and calculate their absolute difference |V1-V2|; a status judgment module 13, which pre-stores the threshold T, used to compare the absolute difference with the threshold T, and output a judgment signal indicating whether the paper has been taken or not; and a calibration control module 14, used to respond to calibration commands from the button indicator board, store standard voltage values and update the threshold T.
[0026] The synchronous sampling (1-5kHz) of the signal acquisition module ensures the time consistency of V1 and V2 data, enabling the difference calculation to truly reflect the paper condition rather than ambient light fluctuations. Combined with the moving average filtering of the difference calculation module, instantaneous noise is effectively suppressed, and a full-link anti-interference mechanism from hardware acquisition to software processing is constructed, significantly improving signal quality.
[0027] The state determination module does not use a fixed threshold, but relies on the calibration control module to make judgments based on a threshold T calibrated according to the actual environment. This allows the judgment benchmark to adapt to different individual sensor differences and environmental characteristics, forming a closed-loop, learnable judgment system, thereby significantly improving the accuracy and robustness of state recognition.
[0028] The complete data processing flow (acquisition → filtering → calculation → judgment → calibration) is divided into four independent modules with specific functions. This modular architecture not only makes the system logic clear, easy to maintain and upgrade, but more importantly, it allows for independent optimization of each step (such as sampling frequency, filtering algorithm, and calibration strategy), thereby achieving the best balance between detection accuracy, response speed, and environmental adaptability as a whole.
[0029] Both the detection sensor 2 and the reference sensor 3 are reflective or transmissive photoelectric sensors. By using the same type (reflective or transmissive) photoelectric sensors as the detection and reference sensors, a high degree of consistency in their physical characteristics, spectral response characteristics, and temperature drift characteristics is ensured. This results in a high degree of common-mode similarity between the influence of ambient light changes on their output voltages (V1 and V2), which can be maximized to cancel each other out in the subsequent difference calculation (|V1-V2|), fundamentally improving the reliability and effectiveness of the system in suppressing ambient light interference.
[0030] The button and indicator panel 4 includes calibration buttons, including paperless calibration and paper-based calibration buttons; and status indicator lights, including a sensor normal light to indicate normal sensor operation, a calibration complete light to indicate calibration completion, and a sensor fault light to indicate sensor malfunction. By integrating a dedicated paperless / paper-based calibration button and a multi-status indicator light system, the complex sensor calibration process is transformed into a simple user interaction operation. This allows the device to be quickly and accurately learned and updated by the user on-site based on the actual ambient light. Simultaneously, different colored lights provide an immediate and intuitive display of the system status (normal, calibration complete, fault), thereby greatly improving the device's environmental adaptability, ease of use, and maintainability.
[0031] During calibration, the calibration control module, in response to the triggering of the paperless calibration key, records the current real-time voltage value V1 and the reference voltage value V2 as standard values for the paperless state; in response to the triggering of the paper-present calibration key, it records the real-time voltage value V1 and the reference voltage value V2 when paper is present as standard values for the paper-present state; and calculates and updates the threshold T based on the standard values for the paperless and paper-present states. By recording the sensor voltage values under both "paperless" and "paper-present" standard states respectively, and dynamically calculating and updating the judgment threshold T accordingly, the system can actively learn and adapt to specific sensor individual differences, ambient light background, and paper characteristics, thereby establishing a dynamic judgment benchmark that matches actual working conditions, ensuring the long-term accuracy and reliability of the detection device in different application scenarios.
[0032] It also includes a fault alarm unit. When the printer control board detects an open circuit, short circuit, or persistently abnormal absolute difference in the sensor, the status judgment module triggers the fault alarm unit to issue an audible and visual alarm and record the corresponding fault code. By monitoring the hardware health status (open circuit / short circuit) and logical rationality (persistently abnormal absolute difference) of the sensor in real time, and actively triggering audible and visual alarms and recording specific codes when a fault occurs, a leap from passive response to proactive early warning is achieved. This not only effectively prevents systemic misjudgments and equipment damage caused by sensor failure, but also greatly simplifies the subsequent maintenance and diagnosis process, improving the reliability and serviceability of the equipment.
[0033] This invention also relates to a method for detecting the paper-feeding status of a printer that resists ambient light interference, the method comprising the following steps: Signal acquisition steps: Simultaneously acquire the real-time detection voltage value V1 output by the detection sensor and the reference voltage value V2 output by the reference sensor; Difference calculation steps: Filter the real-time detected voltage value V1 and the reference voltage value V2, and calculate their absolute difference D = |V1 - V2|; Status determination step: Compare the absolute difference D with the preset sensor accuracy threshold T; if D < T, it is determined that the paper has been removed; if D > T, it is determined that the paper has not been removed; Control execution step: Based on the result of the status determination step, control the printer to perform the corresponding subsequent operations.
[0034] In the signal acquisition step, the detection voltage value V1 and the reference voltage value V2 are synchronously sampled using a sampling frequency of 1-5kHz, and circuit noise is filtered out. In the difference calculation step, the detection voltage value V1 and the reference voltage value V2 are filtered using a moving average filtering algorithm.
[0035] It also includes a calibration step: under standard ambient light conditions, trigger a paperless calibration command and record the detected voltage value V1 and the reference voltage value V2 collected at this time as the standard value of the paperless state; When the paper is in place, a paper calibration command is triggered, and the detection voltage value V1 and the reference voltage value V2 collected at this time are recorded as the standard values of the paper-containing state. Based on the standard values for the paperless state and the paper-containing state, the sensor accuracy threshold T is calculated and updated.
[0036] It also includes a fault monitoring step: real-time monitoring of the sensor's operating status and the absolute difference D; when an open circuit, short circuit, or absolute difference D is detected in the sensor, an audible and visual alarm is triggered and a fault code is recorded.
[0037] From synchronous high-speed sampling (1-5kHz) and moving average filtering to difference calculation, a complete signal purification chain is formed. This process effectively removes ambient light common-mode interference and random circuit noise, ensuring the high stability and authenticity of the core data (absolute difference D) used for state judgment, laying the foundation for accurate judgment.
[0038] By introducing an independent calibration step, the method eliminates the reliance on factory-set fixed thresholds. Instead, it enables on-site calibration based on actual usage scenarios (including specific ambient light, individual sensor differences, and paper characteristics), dynamically updating the threshold T. This significantly improves the method's adaptability and accuracy in different application environments, avoiding performance degradation due to long-term use or environmental changes.
[0039] It not only completes the core paper dispensing status judgment, but also extends its function to system health management through fault monitoring steps. It can proactively diagnose sensor hardware faults (open circuit / short circuit) and system logic anomalies (persistent abnormal D value), and trigger alarms and records, realizing a leap from "passive response" to "proactive early warning and maintenance", significantly improving the reliability and maintainability of the equipment.
[0040] By employing a simple yet effective "D vs. T" comparison logic, combined with front-end filtering, this method effectively prevents misjudgments caused by signal jitter. Ultimately, control actions are executed based on this reliable judgment result, fundamentally reducing the risk of paper jams, duplicate printing, or unexplained printer shutdowns, thus ensuring user experience and equipment stability.
[0041] A standardized operating paradigm has been defined, encompassing data acquisition, calculation, judgment, control, calibration, and diagnostics. This enables the technical solution to be stably implemented and replicated on different printer models, facilitating the promotion and application of the technology, while also simplifying production debugging and after-sales maintenance.
[0042] The working principle of this invention is a closed-loop process from initial calibration to normal operation monitoring, with continuous fault diagnosis capabilities. The steps of its workflow are as follows: Step 1: Initialization and Calibration 1. Power-on startup: After power is applied, the sensor normal light on the button indicator board will remain on, indicating that the sensor hardware connection is normal.
[0043] 2. Perform calibration: Under standard ambient light, the user performs the calibration operation: a. Paperless Calibration: Ensure there is no paper in the paper path and press the paperless calibration button. The calibration control module records the voltage value V1 of the detection sensor and the voltage value V2 of the reference sensor at this time.
[0044] b. Paper Calibration: Place the paper in the detection position and press the paper calibration button. The calibration control module records the voltage value V1 of the detection sensor and the voltage value V2 of the reference sensor at this time.
[0045] 3. Calculate and update the threshold: Based on the two sets of recorded standard values, the calibration control module calculates the judgment threshold T and updates it to the status judgment module. Upon completion, the calibration completion indicator flashes.
[0046] Step 2: Real-time status detection and judgment (executed in a loop) 4. Synchronous signal acquisition: During normal operation, the signal acquisition module synchronously acquires the real-time voltage V1 output by the detection sensor and the real-time voltage V2 output by the reference sensor at a sampling frequency of 1-5kHz.
[0047] 5. Signal filtering and difference calculation: The difference calculation module performs moving average filtering on multiple sets of continuously collected V1 and V2 values to suppress instantaneous noise.
[0048] Subsequently, the absolute difference D between the filtered V1 and V2 is calculated as |V1 - V2|. The key to this step is that changes in ambient light will affect V1 and V2 simultaneously and in the same direction, so the difference D can effectively cancel out the common-mode interference.
[0049] 6. Status Judgment: The status judgment module compares the calculated real-time difference D with the pre-stored threshold T. If D < T, it indicates that the difference in light environment between the detection point and the reference point is very small, which is consistent with the characteristics of the paperless state. Therefore, it is judged that "the paper has been removed".
[0050] If D > T, it indicates that there is a significant difference in the light environment between the detection point and the reference point, which is consistent with the characteristics of "paper present state". Therefore, it is determined that the paper has not been removed.
[0051] 7. Control Execution: The printer control panel determines the printer's actions based on the status. If it determines that the paper has been removed, it prepares for the next print job; if it determines that the paper has not been removed, it waits or continues feeding paper.
[0052] Step 3: Parallel Fault Monitoring and Alarm 8. Continuous Fault Diagnosis: Throughout the entire operation, the status judgment module executes fault monitoring steps in parallel: monitoring whether the sensor has an open circuit or short circuit; monitoring whether the absolute difference D remains within a significantly unreasonable abnormal range.
[0053] 9. Alarm and Recording: Once any of the above faults is detected, the status judgment module immediately triggers the fault alarm unit, causing the "sensor fault light" (red) to flash and the buzzer to sound at specific intervals. At the same time, the specific fault code is recorded so that maintenance personnel can quickly locate and repair the problem.
[0054] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A printer paper-feeding status detection device resistant to ambient light interference, characterized in that, Includes a dual-sensor assembly, a printer control board, and a button indicator light board; The dual-sensor assembly includes a detection sensor and a reference sensor. The detection sensor is installed at the paper output path of the printer to detect the paper status and output a real-time voltage value V1. The reference sensor is installed inside the printer in a position where it is not obstructed by paper and where the ambient light conditions are the same as those of the detection sensor, and is used to output a reference voltage value V2; The printer control board is electrically connected to the detection sensor and the reference sensor respectively, and is used to collect the real-time voltage value V1 and the reference voltage value V2, and calculate their absolute difference |V1-V2|. The paper feeding status is determined based on the comparison result of the difference with the preset threshold T. The button indicator board is electrically connected to the printer control board and is used to receive calibration commands and display the working status of the device.
2. The printer paper feeding status detection device resistant to ambient light interference according to claim 1, characterized in that, The printer control board includes: The signal acquisition module is used to synchronously acquire real-time voltage value V1 and reference voltage value V2 at a sampling frequency of 1-5kHz, and to filter the acquired signal to eliminate circuit noise. The difference calculation module is used to perform moving average filtering on the filtered real-time voltage value V1 and the reference voltage value V2, and calculate their absolute difference |V1-V2|. The status judgment module has a pre-stored threshold T, which is used to compare the absolute difference with the threshold T and output a judgment signal indicating whether the paper has been taken or not. The calibration control module is used to respond to calibration commands from the button indicator panel, store standard voltage values, and update the threshold T.
3. The printer paper feeding status detection device resistant to ambient light interference according to claim 1 or 2, characterized in that, Both the detection sensor and the reference sensor are reflective photoelectric sensors or transmissive photoelectric sensors.
4. The printer paper feeding status detection device against ambient light interference according to claim 1, characterized in that, The button indicator panel includes: Calibration buttons, including paperless calibration buttons and paper-based calibration buttons; Status indicator lights include a sensor normal light to indicate that the sensor is working properly, a calibration complete light to indicate that the calibration operation is complete, and a sensor fault light to indicate that the sensor is malfunctioning.
5. The printer paper feeding status detection device against ambient light interference according to claim 4, characterized in that, When the calibration control module performs calibration: In response to the triggering of the paperless calibration key, the current real-time voltage value V1 and the reference voltage value V2 are recorded as standard values for the paperless state; In response to the triggering of the paper calibration key, the real-time voltage value V1 and the reference voltage value V2 when paper is present are recorded as standard values for the paper-present state. The threshold T is calculated and updated based on the paperless state standard value and the paper-containing state standard value.
6. The printer paper feeding status detection device against ambient light interference according to claim 1, characterized in that, It also includes a fault alarm unit. When the printer control board detects that the sensor is open-circuited, short-circuited, or the absolute difference is continuously abnormal, the status judgment module triggers the fault alarm unit to issue an audible and visual alarm and records the corresponding fault code.
7. A method for detecting the paper feeding status of a printer resistant to ambient light interference, employing the apparatus as described in any one of claims 1-6, characterized in that, The method includes the following steps: Signal acquisition steps: Simultaneously acquire the real-time detection voltage value V1 output by the detection sensor and the reference voltage value V2 output by the reference sensor; Difference calculation steps: Filter the real-time detected voltage value V1 and the reference voltage value V2, and calculate their absolute difference D = |V1 - V2|; State determination step: Compare the absolute difference D with the preset sensor accuracy threshold T; If D < T, then the paper has been removed. If D > T, then the paper is determined to be in a state where it has not been taken away; Control execution steps: Based on the result of the state judgment step, control the printer to perform the corresponding subsequent operations.
8. The method according to claim 7, characterized in that, In the signal acquisition step, the detection voltage value V1 and the reference voltage value V2 are synchronously sampled using a sampling frequency of 1-5kHz, and circuit noise is filtered out. In the difference calculation step, the detection voltage value V1 and the reference voltage value V2 are filtered using a moving average filtering algorithm.
9. The method according to claim 7, characterized in that, It also includes a calibration step: Under standard ambient light conditions, trigger the paperless calibration command and record the collected detection voltage value V1 and reference voltage value V2 as the standard values for the paperless state. When the paper is in place, a paper calibration command is triggered, and the detection voltage value V1 and the reference voltage value V2 collected at this time are recorded as the standard values of the paper-containing state. Based on the standard values for the paperless state and the paper-containing state, the sensor accuracy threshold T is calculated and updated.
10. The method according to claim 7, characterized in that, It also includes a fault monitoring step: real-time monitoring of the sensor's operating status and the absolute difference D; when an open circuit, short circuit, or absolute difference D is detected in the sensor, an audible and visual alarm is triggered and a fault code is recorded.