CN110202956B - Light emitting unit brightness configuration method and device in printer and printer - Google Patents

Light emitting unit brightness configuration method and device in printer and printer Download PDF

Info

Publication number
CN110202956B
CN110202956B CN201910297430.7A CN201910297430A CN110202956B CN 110202956 B CN110202956 B CN 110202956B CN 201910297430 A CN201910297430 A CN 201910297430A CN 110202956 B CN110202956 B CN 110202956B
Authority
CN
China
Prior art keywords
voltage
light emitting
emitting unit
value
reference value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910297430.7A
Other languages
Chinese (zh)
Other versions
CN110202956A (en
Inventor
林扬
其他发明人请求不公开姓名
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xiamen Hanyin Co ltd
Original Assignee
Xiamen Hanyin Electronic Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xiamen Hanyin Electronic Technology Co Ltd filed Critical Xiamen Hanyin Electronic Technology Co Ltd
Priority to CN201910297430.7A priority Critical patent/CN110202956B/en
Publication of CN110202956A publication Critical patent/CN110202956A/en
Application granted granted Critical
Publication of CN110202956B publication Critical patent/CN110202956B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • BPERFORMING OPERATIONS; TRANSPORTING
    • B41PRINTING; LINING MACHINES; TYPEWRITERS; STAMPS
    • B41JTYPEWRITERS; SELECTIVE PRINTING MECHANISMS, i.e. MECHANISMS PRINTING OTHERWISE THAN FROM A FORME; CORRECTION OF TYPOGRAPHICAL ERRORS
    • B41J11/00Devices or arrangements  of selective printing mechanisms, e.g. ink-jet printers or thermal printers, for supporting or handling copy material in sheet or web form
    • B41J11/008Controlling printhead for accurately positioning print image on printing material, e.g. with the intention to control the width of margins

Landscapes

  • Accessory Devices And Overall Control Thereof (AREA)
  • Handling Of Sheets (AREA)

Abstract

The invention discloses a method and a device for configuring the brightness of a light emitting unit in a printer and the printer, wherein the method comprises the following steps: s1, sending a rotation instruction to the control motor to make the control motor drive the printing medium to advance; s2, detecting the voltage value output by the light receiving unit; s3, adjusting the voltage output to the light emitting unit according to the magnitude relation between the voltage value and at least two voltage reference values to make the voltage value between the first reference voltage value and the second reference voltage value; s4, recording the moving distance of the printing medium; s5, judging whether the moving distance is larger than a preset length; if yes, the adjusted voltage is configured to be the voltage of the light emitting unit; if not, the voltage of the light emitting unit is updated according to the adjusted voltage, and returns to S1. The invention can adjust the voltage output by the light emitting unit, so that the voltage value output by the light receiving unit is suitable for detecting the current printing medium.

Description

Light emitting unit brightness configuration method and device in printer and printer
Technical Field
The invention relates to the technical application field of printers, in particular to a method and a device for configuring the brightness of a light emitting unit in a printer and the printer.
Background
In the field of printing of print media, the print media is composed of a printable portion (surface paper) and an unprintable portion (base paper), the printable portion (surface paper) is called a stamp face, the unprintable portion (base paper) between the stamp face and the stamp face is called a seam mark, and in order to ensure that the content to be printed is printed on the correct printable position (stamp face), the position of a printing head on the print media needs to be accurately detected. However, since the thickness of the seam mark is different from that of the stamp face, the light transmittance is also different.
In the prior art, the position detection adopts a photoelectric detection mode, and a light emitting unit and a light receiving unit are respectively arranged on two sides of a printing medium. The light emitting unit is connected to a power supply, emits a beam of light to penetrate through a printing medium, the light receiving unit receives the light passing through the printing medium, the light is converted into voltage to be connected to the central processing unit, and the central processing unit reads the voltage output by the light receiving unit and calculates the corresponding position of the current printing head on the printing medium. However, since the specifications of the printing media in different industries are different, the transmittance of the paper is also different, and different position detection hardware circuits need to be designed.
Disclosure of Invention
The embodiment of the invention provides a method and a device for configuring the brightness of a light emitting unit in a printer and the printer, which can enable the voltage value output by a light receiving unit to be suitable for detecting the current printing medium by adjusting the voltage output by the light emitting unit.
In a first aspect, an embodiment of the present invention provides a printer, including a controller, a light emitting unit, a light receiving unit, and a control motor, where the light emitting unit and the light receiving unit are disposed on two sides of a paper feeding path; the controller comprises a memory and a processor, the memory, the light emitting unit, the light receiving unit and the control motor are all connected with the processor, a computer program is stored in the memory, and the computer program can be executed by the processor to realize the following steps:
s1, sending a first rotation instruction to the control motor, so that the control motor drives the printing medium to move forwards;
s2, detecting the voltage value output by the light receiving unit;
s3, adjusting the voltage output to the light emitting unit according to the magnitude relation between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value;
s4, recording the moving distance of the printing medium;
s5, judging whether the moving distance is larger than a preset length;
if yes, configuring the adjusted voltage as the voltage of the light emitting unit;
if not, the voltage of the light emitting unit is updated according to the adjusted voltage, and the process returns to step S1.
Preferably, the adjusting the voltage output to the light emitting unit according to the magnitude relationship between the voltage value and at least two voltage reference values makes the voltage value between a first voltage reference value and a second voltage reference value, specifically:
when the voltage value is judged to be larger than a preset first voltage reference value, adjusting the voltage output to the light emitting unit to enable the voltage value not to be larger than the first voltage reference value;
and when the voltage value is judged to be smaller than a preset second voltage reference value, adjusting the voltage output to the light emitting unit so that the voltage value is not smaller than the second voltage reference value.
Preferably, the first voltage reference value is a saturation voltage of the light receiving unit; the second voltage reference value is a cut-off voltage of the light receiving unit.
Preferably, the method further comprises the following steps:
acquiring the length of a printing medium; the preset length is equal to the length of the printing medium.
In a second aspect, an embodiment of the present invention provides a method for configuring brightness of a light emitting unit in a printer, including:
s1, sending a first rotation instruction to the control motor to enable the control motor to drive the printing medium to advance;
s2, detecting the voltage value output by the light receiving unit;
s3, adjusting the voltage output to the light emitting unit according to the magnitude relation between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value;
s4, recording the moving distance of the printing medium;
s5, judging whether the moving distance is larger than a preset length;
if yes, configuring the adjusted voltage as the voltage of the light emitting unit;
if not, the voltage of the light emitting unit is updated according to the adjusted voltage, and the process returns to step S1.
Preferably, the voltage output to the light emitting unit is adjusted according to the magnitude relationship between the voltage value and at least two voltage reference values, so that the voltage of the light emitting unit tends to the first voltage reference value or the second voltage reference value, specifically:
when the voltage value is judged to be larger than a preset first voltage reference value, adjusting the voltage output to the light emitting unit to enable the voltage value not to be larger than the first voltage reference value;
and when the voltage value is judged to be smaller than a preset second voltage reference value, adjusting the voltage output to the light emitting unit so that the voltage value is not smaller than the second voltage reference value.
Preferably, the first voltage reference value is a saturation voltage; the second voltage reference value is a cutoff voltage.
Preferably, the method further comprises the following steps:
acquiring the length of a printing medium; the preset length is equal to the length of the printing medium
In a third aspect, an embodiment of the present invention provides a device for configuring brightness of a light emitting unit in a printer, including:
a rotation instruction issuing unit for issuing a rotation instruction to the control motor so that the control motor drives the printing medium to advance;
a detection unit for detecting a voltage value output by the light receiving unit;
the adjusting unit is used for adjusting the voltage output to the light emitting unit according to the magnitude relation between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value;
a recording unit for recording a moving distance of the printing medium;
the judging unit is used for judging whether the moving distance is larger than a preset length; if yes, calling a configuration unit, and if not, calling an updating unit; wherein,
the configuration unit is used for configuring the adjusted voltage as the voltage of the light emitting unit;
and the updating unit is used for updating the voltage of the light emitting unit according to the adjusted voltage and returning to the rotating instruction sending unit.
Preferably, the adjusting unit is specifically configured to:
the first voltage reference value judging module is used for adjusting the voltage output to the light emitting unit when the voltage value is judged to be larger than a preset first voltage reference value, so that the voltage value is not larger than the first voltage reference value;
and the second voltage reference value judging module is used for adjusting the voltage output to the light emitting unit when the voltage value is judged to be smaller than a preset second voltage reference value, so that the voltage value is not smaller than the second voltage reference value.
Preferably, the first voltage reference value is a saturation voltage of the light receiving unit; the second voltage reference value is a cut-off voltage of the light receiving unit.
Preferably, the method further comprises the following steps:
an acquisition unit configured to acquire a length of a printing medium; the preset length is equal to the length of the printing medium.
In a fourth aspect, the present invention provides a computer-readable storage medium, which includes a stored computer program, wherein when the computer program runs, an apparatus in which the computer-readable storage medium is located is controlled to execute the method for configuring brightness of light emitting units in a printer according to the second aspect.
In the above one embodiment, the voltage value output by the light receiving unit is detected in real time, the voltage output to the light emitting unit is adjusted according to the magnitude relationship between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value, and the voltage of the light emitting unit is changed by judging the moving distance of the printing medium and the preset length. The printer can be adapted to all specifications of printing media by adjusting the voltage output from the light emitting unit.
Drawings
In order to more clearly illustrate the technical solution of the present invention, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic structural diagram of a printer according to a first embodiment of the present invention.
Fig. 2 is a flowchart illustrating a method for configuring brightness of a light emitting unit in a printer according to an embodiment of the present invention.
Fig. 3 is a structural diagram of a relationship between voltage and light brightness provided by an embodiment of the present invention.
Fig. 4 is a schematic structural diagram of a light emitting unit, a light receiving unit, and a printing medium according to a first embodiment of the present invention.
Fig. 5 is a schematic structural diagram of a brightness configuration apparatus for a light emitting unit in a printer according to a third embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The first embodiment of the present invention:
referring to fig. 1 to 3, a first embodiment of the present invention provides a printer including a controller, a light emitting unit 11, a light receiving unit 12, and a control motor 14, wherein the light emitting unit 11 and the light receiving unit 12 are disposed at both sides of a paper path. The controller includes a memory 13 and a processor 15, and the memory 13, the light emitting unit 11, the light receiving unit 12, and the control motor 14 are all connected to the processor 15.
In this embodiment, the processor 15 adjusts the voltage output to the light emitting unit 11 to change the brightness of the light emitting unit 11, and the light receiving unit 12 receives the light from the light emitting unit 11, converts the light signal into an electrical signal and feeds the electrical signal back to the processor 15 (i.e. converts the intensity of the light into the magnitude of the voltage), so that the processor 15 adjusts the voltage output from the light emitting unit 11 according to the detected voltage change output from the light receiving unit 12 to change the intensity of the light from the light emitting unit 11.
When the existing printer is used, after a new printing medium is replaced, due to different light transmittances of different specifications, the voltage of the existing light emitting unit 11 is found to be not suitable for the replaced printing medium, and the problem that the actual printing position is different from the preset printing position greatly, so that the printing deviation occurs on the replaced printing medium may occur. During the debugging, the inventors found that since the new printing medium is different in thickness or specification from the old printing medium, so that the intensity of light received by the light receiving unit 12 largely varies from the intensity of light received by the old printing medium, when the light emitting unit 11 and the light receiving unit 12 correspond to voltage values output in the region of the enlarged region when the region of the printing medium and/or the slit width region, the voltage value change is made sensitive so that a large change in voltage value occurs in the area of the printing medium or the slit width alone, further, the judgment is wrong, and the boundary position between the printing medium and the slit width is mistaken when the voltage value is greatly changed, the voltage value of the new printing medium may be adjusted such that the voltage value approaches a critical value of a saturation region or a cutoff region to be adapted to the new specification and thickness of the printing medium.
Specifically, the controller includes a memory 13 and a processor 15, and the memory 13, the light emitting unit 11, the light receiving unit 12, and the control motor 14 are all connected to the processor 15. Stored in the memory 13 is a computer program that can be executed by the processor 15 to implement the following steps, see in particular fig. 2:
s1, a first rotation command is sent to the control motor 14, so that the control motor 14 drives the printing medium 3 to move forward.
S2, the voltage value output by the light receiving unit 12 is detected.
S3, the voltage outputted to the light emitting unit 11 is adjusted according to the magnitude relationship between the voltage value and at least two voltage reference values so that the voltage value is between the first voltage reference value and the second voltage reference value.
In this embodiment, the voltage value output by the light receiving unit 12 is different according to the intensity of the light emitting unit 11, so that the processor 15 has different sensitivities to the voltage value change. Specifically, referring to fig. 3, it is assumed that the light receiving unit 12 is divided into a saturation region (2.7V or more), an amplification region (0.6V-2.7V), and a cut-off region (0V-0.6V) according to a light intensity variation, according to photoelectric characteristics (when received light is stronger, converted voltage is smaller). When the voltage output by the light receiving unit 12 approaches the critical value of the saturation region or the cut-off region, the voltage is stable, and when the voltage changes between the saturation region and the cut-off region, the voltage passes through the amplification region, and the boundary between the printing medium and the slit width can be sensitively sensed. Therefore, the first voltage reference value is set as the saturation voltage of the light receiving unit 12, specifically, the critical value of the saturation region voltage and the amplification region (2.7V in fig. 3), so that the voltage output by the light receiving unit 12 is stabilized when it is aligned with the print surface area of the printing medium. The second voltage reference value is set to the cut-off voltage of the light receiving unit 12, specifically to the cut-off voltage and the critical value of the amplification region (e.g., 0.6V in fig. 4), so that the voltage output by the light receiving unit 12 is stabilized when it is aligned with the print medium slit width region. Specifically, the voltage value of the light receiving unit 12 may be adjusted by:
when the voltage value is determined to be greater than a preset first voltage reference value, the voltage output to the light emitting unit 11 is adjusted so that the voltage value is not greater than the first voltage reference value.
When it is determined that the voltage value is smaller than a preset second voltage reference value, the voltage output to the light emitting unit 11 is adjusted so that the voltage value is not smaller than the second voltage reference value.
S4, the moving distance of the printing medium 3 is recorded.
In this embodiment, the moving distance of the printing medium is the sum of the moving distance recorded when the voltage value is made not greater than the first voltage reference value and the moving distance when the voltage value is made not less than the second voltage reference value, so that when it is determined that the voltage value is not greater than the first voltage reference value, the printing medium is completely run, not from the middle.
And S5, judging whether the moving distance is larger than the preset length.
If so, configuring the adjusted voltage as the voltage of the light emitting unit 11;
if not, the voltage of the light emitting unit 11 is updated according to the adjusted voltage, and the process returns to step S1.
In this embodiment, the actual position of the printing head relative to the edge of the printing medium is determined by determining the position of the print surface of the printing medium, the position of the seam width, and the voltage value corresponding thereto by determining that the moving distance of the first voltage reference value and the second voltage reference value is greater than the preset length in one cycle of the conversion between the first voltage reference value and the second voltage reference value, and determining the critical positions of the print surface and the seam surface of the printing medium.
However, it should be noted that the actual edge position of the printing medium can be confirmed only in the case where the first voltage reference value and the second voltage reference value are sequentially shifted not less than three times. It will be appreciated that the printer will not be able to recognize that it has gone through a complete cycle when it detects three edge positions, for example, assuming that the first change in detected voltage value corresponds to a change from the first voltage reference value to the second voltage reference value, which is a change from the print side position to the slot width position of the print medium, which is the first edge. The second change of the voltage value is detected to correspond to the second voltage reference value change to the first voltage reference value, which is a change from the slot width position of the printing medium to the printing surface position, which is the second edge, i.e. the slot width position is between the first edge and the second edge, the third change of the voltage value is detected to correspond to the first voltage reference value change to the second voltage reference value, which is a change from the printing surface position of the printing medium to the slot width position, which is the third edge, i.e. the printing surface position of the printing medium is complete between the second edge and the third edge, i.e. when the moving distance of the printing medium is judged to be greater than the preset length, the adjusted voltage is configured as the voltage of the light emitting unit 11, i.e. the adjustment is confirmed to be completed.
To sum up, the voltage value output by the light receiving unit 12 is detected in real time, the voltage output to the light emitting unit 11 is adjusted according to the magnitude relationship between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value, and the voltage of the light emitting unit 11 is changed by judging the moving distance and the preset length of the printing medium. The voltage value output by the light receiving unit 12 can be adapted to be used to detect the current printing medium by adjusting the voltage output by the light emitting unit 11.
Referring to fig. 4, on the basis of the above embodiment, in a preferred embodiment of the present invention, the light emitting unit 11 may be, but is not limited to, a light emitting diode, as long as the light emitting unit 11 includes, for example, the structure shown in fig. 4, and the light emitting unit 11 includes a light emitting unit light emitting tube 1 (light source), a light emitting unit collimating mirror 2 (mirror for converting a divergent light beam into a parallel light beam), and the like, and the present invention is not described herein again.
The light receiving unit 12 may be, but not limited to, a photodiode, as long as the structure includes, for example, as shown in fig. 4, the structure of the light receiving unit 12 includes a light receiving unit condenser 4 (a light receiving channel, a convex lens for converging light), a light receiving unit converter 5 (for converting an optical signal into an electrical signal), and the like, and it is understood that the light receiving unit converter 5 may be, for example, a triode, and the description of the present invention is omitted.
On the basis of the above embodiments, in a preferred embodiment of the present invention, the method further includes:
acquiring the length of the printing medium 3; the preset length is equal to the length of the printing medium 3
Second embodiment of the invention:
referring to fig. 2, a second embodiment of the present invention provides a method for configuring brightness of a light emitting unit in a printer, including:
s1, sending a first rotation instruction to the control motor to enable the control motor to drive the printing medium to advance;
s2, detecting the voltage value output by the light receiving unit;
s3, adjusting the voltage output to the light emitting unit according to the magnitude relation between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value;
s4, recording the moving distance of the printing medium;
s5, judging whether the moving distance is larger than a preset length;
if yes, configuring the adjusted voltage as the voltage of the light emitting unit;
if not, the voltage of the light emitting unit is updated according to the adjusted voltage, and the process returns to step S1.
On the basis of the foregoing embodiments, in a preferred embodiment of the present invention, the adjusting the voltage output to the light emitting unit according to the magnitude relationship between the voltage value and at least two voltage reference values so that the voltage value is between a first voltage reference value and a second voltage reference value specifically includes:
when the voltage value is judged to be larger than a preset first voltage reference value, adjusting the voltage output to the light emitting unit to enable the voltage value not to be larger than the first voltage reference value;
and when the voltage value is judged to be smaller than a preset second voltage reference value, adjusting the voltage output to the light emitting unit so that the voltage value is not smaller than the second voltage reference value.
On the basis of the above embodiments, in a preferred embodiment of the present invention, the first voltage reference value is a saturation voltage; the second voltage reference value is a cutoff voltage.
On the basis of the above embodiments, in a preferred embodiment of the present invention, the method further includes:
acquiring the length of a printing medium; the preset length is equal to the length of the printing medium
Third embodiment of the invention:
referring to fig. 5, a third embodiment of the present invention provides a light emitting unit luminance configuring apparatus in a printer, including:
a rotation instruction issuing unit 100 configured to issue a rotation instruction to the control motor so that the control motor drives the printing medium to advance;
a detection unit 200 for detecting a voltage value output from the light receiving unit;
an adjusting unit 300, configured to adjust the voltage output to the light emitting unit according to a magnitude relationship between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value;
a recording unit 400 for recording a moving distance of the printing medium;
a judging unit 500, configured to judge whether the moving distance is greater than a preset length; if yes, the configuration unit 600 is called, and if not, the update unit 700 is called; wherein,
the configuration unit 600 is configured to configure the adjusted voltage as the voltage of the light emitting unit;
the updating unit 700 is configured to update the voltage of the light emitting unit according to the adjusted voltage, and return to the rotation instruction issuing unit.
On the basis of the above embodiments, in a preferred embodiment of the present invention, the adjusting unit 300 specifically includes:
the first voltage reference value judging module is used for adjusting the voltage output to the light emitting unit when the voltage value is judged to be larger than a preset first voltage reference value, so that the voltage value is not larger than the first voltage reference value;
and the second voltage reference value judging module is used for adjusting the voltage output to the light emitting unit when the voltage value is judged to be smaller than a preset second voltage reference value, so that the voltage value is not smaller than the second voltage reference value.
On the basis of the above embodiments, in a preferred embodiment of the present invention, the first voltage reference value is a saturation voltage of the light receiving unit; the second voltage reference value is a cut-off voltage of the light receiving unit.
On the basis of the above embodiments, in a preferred embodiment of the present invention, the method further includes:
an acquisition unit configured to acquire a length of a printing medium; the preset length is equal to the length of the printing medium.
The fourth embodiment of the present invention:
a fourth embodiment of the present invention provides a computer-readable storage medium, which is characterized in that the computer-readable storage medium includes a stored computer program, and when the computer program runs, the apparatus where the computer-readable storage medium is located is controlled to execute the method for configuring the brightness of the light emitting unit in the printer according to the above embodiment.
Illustratively, the computer programs described herein can be partitioned into one or more modules that are stored in the memory and executed by the processor to implement the invention. The one or more modules may be a series of computer program instruction segments capable of performing specific functions, the instruction segments describing the execution process of the computer program in the implementation server device. For example, the device described in the third embodiment of the present invention.
The Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an APPlication Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component, or the like. The general purpose processor may be a microprocessor or the processor may be any conventional processor or the like, the processor is a control center of the light emitting unit brightness configuration method in the printer, and various interfaces and lines are used to connect the whole to realize the various parts of the light emitting unit brightness configuration method in the printer.
The memory may be used to store the computer programs and/or modules, and the processor may implement the various functions of the light emitting unit brightness configuration method in the printer by running or executing the computer programs and/or modules stored in the memory and calling the data stored in the memory. The memory may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, a text conversion function, etc.), and the like; the storage data area may store data (such as audio data, text message data, etc.) created according to the use of the user terminal, etc. In addition, the memory may include high speed random access memory, and may also include non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), at least one magnetic disk storage device, a Flash memory device, or other volatile solid state storage device.
Wherein, the module for realizing the service device can be stored in a computer readable storage medium if it is realized in the form of software functional unit and sold or used as a stand-alone product. Based on such understanding, all or part of the flow of the method according to the embodiments of the present invention may also be implemented by a computer program, which may be stored in a computer-readable storage medium, and when the computer program is executed by a processor, the steps of the method embodiments may be implemented. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
It should be noted that the above-described device embodiments are merely illustrative, where the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. In addition, in the drawings of the embodiment of the apparatus provided by the present invention, the connection relationship between the modules indicates that there is a communication connection between them, and may be specifically implemented as one or more communication buses or signal lines. One of ordinary skill in the art can understand and implement it without inventive effort.
The above description is only for the preferred embodiment of the present invention, but the scope of the present invention is not limited thereto, and any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present invention are included in the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (9)

1. A printer comprises a controller, a light emitting unit, a light receiving unit and a control motor, wherein the light emitting unit and the light receiving unit are arranged on two sides of a paper feeding channel; characterized in that the controller comprises a memory and a processor, the memory, the light emitting unit, the light receiving unit and the control motor all being connected to the processor, the memory having stored therein a computer program executable by the processor to implement the steps of:
s1, sending a first rotation instruction to the control motor, so that the control motor drives the printing medium to move forwards;
s2, detecting the voltage value output by the light receiving unit;
s3, adjusting the voltage output to the light emitting unit according to the magnitude relation between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value;
s4, recording the moving distance of the printing medium;
s5, judging whether the moving distance is larger than a preset length;
if yes, configuring the adjusted voltage as the voltage of the light emitting unit;
if not, the voltage of the light emitting unit is updated according to the adjusted voltage, and the process returns to step S1.
2. The printer according to claim 1, wherein the voltage output to the light emitting unit is adjusted according to a magnitude relationship between the voltage value and at least two voltage reference values, such that the voltage value is between a first voltage reference value and a second voltage reference value, in particular:
when the voltage value is judged to be larger than a preset first voltage reference value, adjusting the voltage output to the light emitting unit to enable the voltage value not to be larger than the first voltage reference value;
and when the voltage value is judged to be smaller than a preset second voltage reference value, adjusting the voltage output to the light emitting unit so that the voltage value is not smaller than the second voltage reference value.
3. The printer according to claim 1, wherein the first voltage reference value is a saturation voltage of the light receiving unit; the second voltage reference value is a cut-off voltage of the light receiving unit; the light receiving unit is divided into a saturation region, an amplification region and a cut-off region according to light intensity changes, the saturation voltage is a critical value of the saturation region and the amplification region, and the cut-off voltage is a critical value of the amplification region and the cut-off region.
4. The printer according to claim 1, further comprising:
acquiring the length of a printing medium; the preset length is equal to the length of the printing medium.
5. A method for configuring brightness of a light emitting unit in a printer, comprising:
s1, sending a first rotation instruction to a control motor, so that the control motor drives a printing medium to advance;
s2, detecting the voltage value output by the light receiving unit;
s3, adjusting the voltage output to the light emitting unit according to the magnitude relation between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value;
s4, recording the moving distance of the printing medium;
s5, judging whether the moving distance is larger than a preset length;
if yes, configuring the adjusted voltage as the voltage of the light emitting unit;
if not, the voltage of the light emitting unit is updated according to the adjusted voltage, and the process returns to step S1.
6. The method for configuring the brightness of the light emitting unit in the printer according to claim 5, wherein the adjusting the voltage output to the light emitting unit according to the magnitude relationship between the voltage value and at least two voltage reference values makes the voltage value between a first voltage reference value and a second voltage reference value comprises:
when the voltage value is judged to be larger than a preset first voltage reference value, adjusting the voltage output to the light emitting unit to enable the voltage value not to be larger than the first voltage reference value;
and when the voltage value is judged to be smaller than a preset second voltage reference value, adjusting the voltage output to the light emitting unit so that the voltage value is not smaller than the second voltage reference value.
7. The method of configuring brightness of a light emitting unit in a printer according to claim 5, wherein the first voltage reference value is a saturation voltage; the second voltage reference value is a cut-off voltage; the light receiving unit is divided into a saturation region, an amplification region and a cut-off region according to light intensity changes, the saturation voltage is a critical value of the saturation region and the amplification region, and the cut-off voltage is a critical value of the amplification region and the cut-off region.
8. The method for configuring brightness of a light emitting unit in a printer according to claim 5, further comprising:
acquiring the length of a printing medium; the preset length is equal to the length of the printing medium.
9. A light emitting unit brightness configuring apparatus in a printer, comprising:
a rotation instruction issuing unit for issuing a rotation instruction to the control motor so that the control motor drives the printing medium to advance;
a detection unit for detecting a voltage value output by the light receiving unit;
the adjusting unit is used for adjusting the voltage output to the light emitting unit according to the magnitude relation between the voltage value and at least two voltage reference values, so that the voltage value is between a first voltage reference value and a second voltage reference value;
a recording unit for recording a moving distance of the printing medium;
the judging unit is used for judging whether the moving distance is larger than a preset length; if yes, calling a configuration unit, and if not, calling an updating unit; wherein,
the configuration unit is used for configuring the adjusted voltage as the voltage of the light emitting unit;
and the updating unit is used for updating the voltage of the light emitting unit according to the adjusted voltage and returning to the rotating instruction sending unit.
CN201910297430.7A 2019-04-15 2019-04-15 Light emitting unit brightness configuration method and device in printer and printer Active CN110202956B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910297430.7A CN110202956B (en) 2019-04-15 2019-04-15 Light emitting unit brightness configuration method and device in printer and printer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910297430.7A CN110202956B (en) 2019-04-15 2019-04-15 Light emitting unit brightness configuration method and device in printer and printer

Publications (2)

Publication Number Publication Date
CN110202956A CN110202956A (en) 2019-09-06
CN110202956B true CN110202956B (en) 2021-11-02

Family

ID=67785353

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910297430.7A Active CN110202956B (en) 2019-04-15 2019-04-15 Light emitting unit brightness configuration method and device in printer and printer

Country Status (1)

Country Link
CN (1) CN110202956B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111516397B (en) * 2020-04-30 2022-04-29 厦门汉印电子技术有限公司 Label paper identification method, device, equipment and readable storage medium

Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000301786A (en) * 1999-04-26 2000-10-31 Sato Corp Label printer
CN1597332A (en) * 2003-07-15 2005-03-23 三星电子株式会社 Print media edge detection method and apparatus
JP2005288906A (en) * 2004-03-31 2005-10-20 Sato Corp Printer and method for regulating print position sensor
CN1938209A (en) * 2004-01-30 2007-03-28 Zih公司 Self calibrating media edge sensor
JP2007106556A (en) * 2005-10-14 2007-04-26 Seiko Epson Corp Medium detection device and printer
CN101293604A (en) * 2007-04-28 2008-10-29 致伸科技股份有限公司 Automatic paper feeder
JP2011110778A (en) * 2009-11-26 2011-06-09 Sato Knowledge & Intellectual Property Institute Device and method for detecting center part of position detection area of printing paper for printer, device and method for detecting printing start position of printing paper, and printer
CN102205735A (en) * 2010-03-04 2011-10-05 兄弟工业株式会社 Label producing apparatus and label producing method
CN104071605A (en) * 2013-03-27 2014-10-01 精工爱普生株式会社 Recording apparatus and medium feeding device
CN204077095U (en) * 2014-09-28 2015-01-07 梅特勒-托利多(常州)测量技术有限公司 The printer of bar code printing scale goes out paper detecting apparatus
JP2015224120A (en) * 2014-05-29 2015-12-14 株式会社沖データ Image forming apparatus
CN105531119A (en) * 2013-08-15 2016-04-27 柯达阿拉里斯股份有限公司 System and method for determining receiver type in a thermal printer
CN106033056A (en) * 2015-02-04 2016-10-19 诚研科技股份有限公司 Identification method and device for detecting specific area of transparent medium
CN107584908A (en) * 2016-07-07 2018-01-16 日本冲信息株式会社 Medium detection device, medium conveying apparatus and image processing system

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3305578B2 (en) * 1996-06-05 2002-07-22 長野日本無線株式会社 Label position detecting device in label printer
JP2006062210A (en) * 2004-08-27 2006-03-09 Canon Finetech Inc Recorder
JP2018001703A (en) * 2016-07-07 2018-01-11 東芝テック株式会社 Label printer and program

Patent Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000301786A (en) * 1999-04-26 2000-10-31 Sato Corp Label printer
CN1597332A (en) * 2003-07-15 2005-03-23 三星电子株式会社 Print media edge detection method and apparatus
CN1938209A (en) * 2004-01-30 2007-03-28 Zih公司 Self calibrating media edge sensor
JP2005288906A (en) * 2004-03-31 2005-10-20 Sato Corp Printer and method for regulating print position sensor
JP2007106556A (en) * 2005-10-14 2007-04-26 Seiko Epson Corp Medium detection device and printer
CN101293604A (en) * 2007-04-28 2008-10-29 致伸科技股份有限公司 Automatic paper feeder
JP2011110778A (en) * 2009-11-26 2011-06-09 Sato Knowledge & Intellectual Property Institute Device and method for detecting center part of position detection area of printing paper for printer, device and method for detecting printing start position of printing paper, and printer
CN102205735A (en) * 2010-03-04 2011-10-05 兄弟工业株式会社 Label producing apparatus and label producing method
CN104071605A (en) * 2013-03-27 2014-10-01 精工爱普生株式会社 Recording apparatus and medium feeding device
CN105531119A (en) * 2013-08-15 2016-04-27 柯达阿拉里斯股份有限公司 System and method for determining receiver type in a thermal printer
JP2015224120A (en) * 2014-05-29 2015-12-14 株式会社沖データ Image forming apparatus
CN204077095U (en) * 2014-09-28 2015-01-07 梅特勒-托利多(常州)测量技术有限公司 The printer of bar code printing scale goes out paper detecting apparatus
CN106033056A (en) * 2015-02-04 2016-10-19 诚研科技股份有限公司 Identification method and device for detecting specific area of transparent medium
CN107584908A (en) * 2016-07-07 2018-01-16 日本冲信息株式会社 Medium detection device, medium conveying apparatus and image processing system

Also Published As

Publication number Publication date
CN110202956A (en) 2019-09-06

Similar Documents

Publication Publication Date Title
CN106626847B (en) Printing method and printer
EP3266618B1 (en) Thermal printer and method for improving detection precision by the same
US8947483B1 (en) Printer and mark detection method
CN111516397B (en) Label paper identification method, device, equipment and readable storage medium
CN110202956B (en) Light emitting unit brightness configuration method and device in printer and printer
CN110202960B (en) Printing equipment, printing device and edge determining method of printing medium
CN111923612A (en) Learning method, device and equipment of paper shortage threshold and readable storage medium
JP5419205B2 (en) Label detection device
US10055676B2 (en) Image forming apparatus with print modes, the print modes comprising printing based on detection of a location on a print medium and printing not based on detection of a location on a print medium
US9721197B2 (en) Control device and control method
JP2005061926A (en) Colorimetric system, colorimetric method, colorimetric program, storage medium
JP2603908B2 (en) Barcode reader
JP2013195177A (en) Recording material determination sensor and image forming device
US20200001632A1 (en) Printer and method for accurately recognizing positions of labels
CN111591044B (en) Method, device and equipment for acquiring operation position of RFID label paper and readable storage medium
CN112731548B (en) Photoelectric pair control method, photoelectric pair control device, photoelectric pair control equipment and readable storage medium
US20240078205A1 (en) Method and device for detecting a connection of a chip to a printing device
JP6174399B2 (en) Printing apparatus and mark detection method for printing apparatus
CN210821448U (en) Printing equipment
CN113434097A (en) Printer, detection control method and device thereof, and computer-readable storage medium
JPH06191526A (en) Method for detecting label
JP3186669B2 (en) Identification device
CN115332935A (en) Pulse number self-correction control device and method and optical fiber laser
JP5381497B2 (en) Multi-beam laser light quantity control circuit and image forming apparatus using multi-beam laser light quantity control circuit
JP6351555B2 (en) Printing apparatus and computer program

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB03 Change of inventor or designer information
CB03 Change of inventor or designer information

Inventor after: Lin Yang

Inventor after: Other inventors ask not to disclose names

Inventor before: Do not announce the inventor

GR01 Patent grant
GR01 Patent grant
CP03 Change of name, title or address
CP03 Change of name, title or address

Address after: 361000 room 305A, Aung Yip house, Pioneer Park, torch high tech Zone, Xiamen, Fujian

Patentee after: Xiamen Hanyin Co.,Ltd.

Country or region after: China

Address before: 361000 room 305A, Aung Yip house, Pioneer Park, torch high tech Zone, Xiamen, Fujian

Patentee before: XIAMEN HANIN ELECTRONIC TECHNOLOGY Co.,Ltd.

Country or region before: China