Thermal printer paper type identification and paper shortage detection method and system based on single reflection sensor
By using a single reflection sensor and the MN2000 microprocessor circuit design in a thermal printer, the complexity of thermal paper and label detection is solved, and the hardware is simplified and the cost is reduced.
Patent Information
- Application Number
- CN202510833123.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-20
- Publication Date
- 2025-09-12
AI Technical Summary
Existing thermal printers find it difficult to accurately detect thermal paper and thermal labels at the same time, which leads to complex hardware design and increased costs.
A single reflection sensor is combined with the microprocessor MN2000. By setting the receiving lamp current detection circuit at its port 19 and the transmitting lamp current control circuit at terminal 41, and using the RC filter circuit to adjust the transmitting lamp current, paper type recognition and paper out detection can be achieved.
It is possible to simultaneously identify thermal paper and thermal labels using only a single reflection sensor, which simplifies the hardware structure and reduces costs.
Smart Images

Figure CN120620882A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of printer manufacturing, and in particular to a method and system for identifying paper type and detecting paper shortage of a thermal printer based on a single reflection sensor. Background Art
[0002] Thermal printers are highly portable due to their simple structure and lack of consumables such as toner or ink. Thermal printers require thermal print media such as thermal paper or thermal labels. To detect the presence of print media, thermal printers typically have a paper detection sensor positioned along the print media's path.
[0003] Conventional thermal paper is typically detected using a reflective photoelectric detection sensor, while thermal labels are detected using a through-beam photoelectric detection sensor. This is because thermal labels are typically adhered to a transparent or translucent release substrate. When rolled, there is a certain gap between adjacent labels, known as a seam label. The transmittance of the seam label is higher than that of the label. Using a reflective photoelectric detection sensor for detection can lead to misjudgment at the gap. Therefore, existing thermal printers are typically only suitable for a single type of print media, or they employ two sets of detection sensors: one reflective photoelectric detection sensor for detecting paper shortages and another through-beam photoelectric detection sensor for determining label gaps. Given this background, if customers require label printing, the hardware design will be more complex, the cost will increase, and this will impact the user experience.
[0004] China Patent Publication (Announcement) No.: CN218315886U, Patent Title: A Thermal Printer Mechanism and Thermal Printer, which discloses "
[0005] On the one hand, the present invention provides a thermal printer mechanism, comprising: a head frame, on which a print head is provided; a rubber roller frame, on which a paper pressing rubber roller is provided, and the rubber roller frame is detachably combined with the head frame...a second light receiver corresponds to the second end of the light guide, and the light guide can guide the light beam incident from the first end to be emitted from the second end" The technical solution has achieved "
[0038] The thermal printer mechanism provided by the embodiment of the present invention can be applied to both conventional thermal paper out-of-paper detection and thermal label paper seam detection, thereby increasing the application range of the product."
[0005] However, this thermal printer structure still relies on two photoelectric pairs: a first photoreceiver and a second photoreceiver, and there is no fundamental structural improvement. The market is looking for a single reflective photoelectric sensor in the thermal print head that can simultaneously detect label and paper out of the paper. Summary of the Invention
[0006] The object of the present invention is to provide a method and system for identifying paper type and detecting paper shortage in a thermal printer based on a single reflection sensor, so as to solve the problems raised in the above-mentioned background technology.
[0007] In order to solve the above technical problems, the present invention is achieved through the following technical measures: a thermal printer paper type recognition and paper out detection system based on a single reflection sensor, including a microprocessor MN2000 for controlling various input and output operation signals of the thermal printer, which is characterized in that: a receiving lamp current detection circuit is provided at port 19 of MN2000, and a transmitting lamp current control circuit is provided at terminal 41 of MN2000; the receiving lamp current detection circuit includes Q2, the GND terminal of Q2 is grounded, and then a capacitor is connected in series, and the capacitor The other end is connected to the first resistor, which is then connected to Vdd. The VPS end of Q2 is connected to the second resistor, which is then connected to Vdd. The PS end of Q2 is connected to a diode, which is then connected to terminal 19 of MN2000. The emitting lamp current control circuit is connected from terminal 19 of MN2000 to the RC filter circuit composed of R2009, L2001 and C2040, and then connected in series with the third resistor R2035, and then connected to the base end of Q2000, and Q2000 is then connected to the VPS signal end.
[0008] Compared with the prior art, the advantages of the present invention are that the thermal printer with a new structure can realize label detection and paper shortage detection at the same time by adding a transmitting lamp current control circuit and a receiving lamp current detection circuit to the microprocessor.
[0009] As an improvement to the present invention, the resistance of the first resistor is 47 kilo-ohms, and the resistance of the second resistor is 220 ohms. This design is chosen for the purpose of limiting the current after connecting the resistors in series, thereby protecting other electronic components in the circuit from damage caused by excessive current.
[0010] The present application also provides a method for identifying paper type and detecting paper out of a thermal printer based on a single reflection sensor, comprising the system for identifying paper type and detecting paper out of a thermal printer based on a single reflection sensor as described in claim 1, and the operating steps are as follows: 1: Set the ADC value of the receiving light LED-SENSOR when the transmitting light is turned on as the reference value; 2: Adjust VPS_EN1 from output high level to output low level, so that Q2000 is adjusted from cut-off state to saturated conduction state; 3: If the value of LED_SENSOR is the same as the reference value of the receiving light LED-SENSOR, it is determined that there is no paper; 4: If the value of LED_SENSOR is different from the reference value of the receiving light LED-SENSOR, it is determined that there is paper; 5: Control VPS_EN1 to output a 720Khz square wave with a duty cycle of 20% / 50% / 80% for 5 seconds respectively. After passing through the RC filter circuit composed of R2009 / L2001 / C2040, different base voltages are formed at R2035-1. By controlling the base voltage of Q2000, the amplification state of Q2000 is controlled, thereby achieving current control of the emission lamp with different voltages. 6: If the LED-SENSOR value is three fixed values within 5 seconds under three different duty cycles, the paper is determined to be thermal paper; 7: If the LED-SENSOR value is three unfixed values within 5 seconds under three different duty cycles, the paper is judged to be label paper; 8: Based on the fluctuation pattern of the LED-SENSOR value and the printing speed of the print head, the label length and gap length in the label paper are automatically determined, and the fluctuation value is recorded. The NM2000 automatically sets the threshold value for determining the label and gap. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] The accompanying drawings, which constitute a part of the present invention, are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute improper limitations on the present invention.
[0012] In the attached figure: Figure 1 This is the overall logic block diagram of the single reflection sensor-based thermal printer paper type recognition and paper out-of-paper detection method and system described in the present invention.
[0013] Figure 2 This is a logic block diagram of the circuit of the thermal printer paper type identification and paper out detection method and system based on a single reflection sensor according to the present invention.
[0014] Figure 3 This is a partial terminal diagram of the microprocessor MN2000 according to the present invention.
[0015] Figure 4 This is the receiving lamp current detection circuit described in the present invention.
[0016] Figure 5 This is the emission lamp current control circuit described in the present invention.
[0017] Explanation of the accompanying figures: 1. Receiving lamp current detection circuit; 2. Transmitting lamp current control circuit. DETAILED DESCRIPTION
[0018] The preferred embodiments of the present invention are described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are only used to illustrate and explain the present invention, and are not used to limit the present invention.
[0019] Example 1 Please refer to Figure 1-5 .
[0020] This embodiment provides a thermal printer paper type identification and paper out-of-paper detection system based on a single reflection sensor, including a microprocessor MN2000 that controls various input and output operation signals of the thermal printer. The NM2000 is also a security chip processor unique to smart POS products, and performs detection through logical judgment.
[0021] In the embodiments of the present invention, please refer to Figure 3 The receiving lamp current detection circuit 1 is provided at the No. 19 port of MN2000, and the transmitting lamp current control circuit 2 is provided at the No. 41 terminal of MN2000.
[0022] In the embodiments of the present invention, please refer to Figure 4 The receiving lamp current detection circuit 1 includes Q2. Q2's GND terminal is grounded, followed by a capacitor connected in series. The other end of the capacitor is connected to a first resistor, which is then connected to Vdd. Q2's VPS terminal is connected to a second resistor, which is then connected to Vdd. Q2's PS terminal is connected to a diode, which is then connected to terminal 19 of the MN2000. The receiving lamp detects current by transmitting light through the printed paper.
[0023] In the embodiments of the present invention, please refer to Figure 5 Transmitter lamp current control circuit 2 connects from terminal 19 of MN2000 to an RC filter circuit consisting of R2009, L2001, and C2040, and then to a third resistor, R2035, in series. This connection is then connected to the base of Q2000, which in turn is connected to the VPS signal terminal. VPS EN1 controls the output of a 720kHz square wave with a duty cycle of 20%, 50%, or 80%, respectively, thereby controlling the base of Q2000 and, in turn, the voltage of VPS. The overall concept is that the transmitter lamp current control circuit achieves transmitter lamp voltage control and regulation through RC filtering using PWM with different duty cycles, thereby controlling the transmitter lamp current.
[0024] Furthermore, the resistance of the first resistor is 47 kilo-ohms, and the resistance of the second resistor is 220 ohms. After the resistors are connected in series, the magnitude of the current can be limited, thereby protecting other electronic components in the circuit from damage caused by excessive current.
[0025] The present application also provides a method for identifying paper type and detecting paper out of a thermal printer based on a single reflection sensor, comprising the system for identifying paper type and detecting paper out of a thermal printer based on a single reflection sensor as described in claim 1, and the operating steps are as follows: 1: Set the ADC value of the receiving light LED-SENSOR when the transmitting light is turned on as the reference value. That is, before the product leaves the factory, the paper-out status in the bin will be recorded during the production process. The ADC value of the receiving light LED-SENSOR when the transmitting light is turned on will be used as the reference to determine whether there is paper shortage.
[0026] 2: Adjust VPS_EN1 from output high to output low, so that Q2000 switches from cutoff to saturated conduction. That is, when the terminal is in use, in the initial state, to determine whether there is paper in the print chamber, VPS_EN1 is adjusted from output high to output low, so that Q2000 switches from cutoff to saturated conduction.
[0027] 3: If the value of LED_SENSOR is the same as the reference value of the receiving light LED-SENSOR, it is determined that there is no paper.
[0028] 4: If the LED_SENSOR value differs from the baseline value of the receiving light, the presence of paper is determined. This means that if paper is present in the paper bin, the reflective effect of the paper increases the brightness of the receiving light, significantly amplifying the current across the Q2 switch, which reduces the voltage drop across Q2 and, consequently, the LED_SENSOR value. By comparing the LED_SENSOR values, the presence of paper in the paper bin can be determined. After determining the presence of paper, the same light is used to distinguish between label paper and thermal paper. See the next step for details.
[0029] 5: Control VPS_EN1 to output a 720Khz square wave with a duty cycle of 20% / 50% / 80% for 5 seconds respectively. After passing through the RC filter circuit composed of R2009 / L2001 / C2040, different base voltages are formed at R2035-1. By controlling the base voltage of Q2000, the amplification state of Q2000 is controlled, thereby achieving current control of the emission lamp with different voltages. 6: If the LED-SENSOR value is three fixed values within 5 seconds under three different duty cycles, the paper is determined to be thermal paper; 7: If the LED-SENSOR value is three unfixed values within 5 seconds under three different duty cycles, the paper is judged to be label paper; 8: Based on the fluctuation pattern of the LED-SENSOR value and the printing speed of the print head, the label length and gap length in the label paper are automatically determined, and the fluctuation value is recorded. The NM2000 automatically sets the threshold value for determining the label and gap.
[0030] Compared with the existing technology, the advantages of the present invention are: this new type of thermal printer can simultaneously realize label detection and paper out detection by adding a transmitting lamp current control circuit and a receiving lamp current detection circuit to the microprocessor, and can realize the functions of label printing and thermal printing with only one reflector lamp.
[0031] In the description of the present invention, it should be noted that the terms "vertical", "up", "down", "horizontal", etc., indicating orientations or positional relationships, are based on the orientations or positional relationships shown in the accompanying drawings. They are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation. Therefore, they cannot be understood as limiting the present invention.
[0032] In the description of the present invention, it should also be noted that, unless otherwise expressly specified or limited, the terms "disposed," "installed," "connected," and "connected" should be understood in a broad sense. For example, they may refer to fixed connections, detachable connections, or integral connections; they may refer to mechanical connections or electrical connections; they may refer to direct connections or indirect connections through an intermediate medium; and they may refer to internal communication between two components. Those skilled in the art will understand the specific meanings of the above terms in the present invention based on specific circumstances.
[0033] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art will be able to modify the technical solutions described in the aforementioned embodiments or substitute equivalents for some of the technical features. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention shall be included within the scope of protection of the present invention.
Claims
1. A thermal printer paper type identification and paper out detection system based on a single reflection sensor, including a microprocessor MN2000 that controls various input and output operation signals of the thermal printer, characterized by: A receiving lamp current detection circuit (1) is provided at port 19 of MN2000, and a transmitting lamp current control circuit (2) is provided at terminal 41 of MN2000; the receiving lamp current detection circuit (1) includes Q2, the GND terminal of Q2 is grounded, and then a capacitor is connected in series, the other end of the capacitor is connected to a first resistor, and the first resistor is connected to Vdd, the VPS terminal of Q2 is connected to a second resistor, and the second resistor is connected to Vdd, the PS terminal of Q2 is connected to a diode, and the diode is connected to terminal 19 of MN2000; the transmitting lamp current control circuit (2) is connected from terminal 19 of MN2000 to an RC filter circuit composed of R2009, L2001 and C2040, and then connected in series with a third resistor R2035, and then connected to the base terminal of Q2000, and Q2000 is connected to the VPS signal terminal.
2. The thermal printer paper type recognition and paper out detection system based on a single reflection sensor according to claim 1, characterized in that: The resistance of the first resistor is 47 kilo-ohms, and the resistance of the second resistor is 220 ohms.
3. A method for identifying paper type and detecting paper out of a thermal printer based on a single reflection sensor, comprising the system for identifying paper type and detecting paper out of a thermal printer based on a single reflection sensor as described in claim 1, wherein the operating steps are as follows: 3.1: Set the ADC value of the receiving light LED-SENSOR when the transmitting light is turned on as the reference value; 3.2: Adjust VPS_EN1 from output high level to output low level, so that Q2000 is adjusted from cut-off state to saturated conduction state; 3.3: If the value of LED_SENSOR is the same as the reference value of the receiving light LED-SENSOR, it is determined that there is no paper; 3.4: If the value of LED_SENSOR is different from the reference value of the receiving light LED-SENSOR, it is determined that there is paper; 3.5: Control VPS_EN1 to output a 720Khz square wave with a duty cycle of 20% / 50% / 80% for 5 seconds respectively. After passing through the RC filter circuit composed of R2009 / L2001 / C2040, different base voltages are formed at R2035-1. By controlling the base voltage of Q2000, the amplification state of Q2000 is controlled, thereby achieving current control of the emitter lamp with different voltages. 3.6: If the LED-SENSOR value is three fixed values within 5 seconds under three different duty cycles, the paper is determined to be thermal paper; 3.7: If the LED-SENSOR value is three unfixed values within 5 seconds under three different duty cycles, the paper is determined to be label paper; 3.8: Based on the fluctuation pattern of the LED-SENSOR value and the printing speed of the print head, the label length and gap length in the label paper are automatically determined, and the fluctuation value is recorded. The NM2000 automatically sets the threshold value for determining the label length and gap length.
Citation Information
Patent Citations
Thermal printer core and thermal printer
CN218315886U