JP5307595B2 - Label printer, paper cueing position control method and program - Google Patents
Label printer, paper cueing position control method and program Download PDFInfo
- Publication number
- JP5307595B2 JP5307595B2 JP2009076547A JP2009076547A JP5307595B2 JP 5307595 B2 JP5307595 B2 JP 5307595B2 JP 2009076547 A JP2009076547 A JP 2009076547A JP 2009076547 A JP2009076547 A JP 2009076547A JP 5307595 B2 JP5307595 B2 JP 5307595B2
- Authority
- JP
- Japan
- Prior art keywords
- paper
- sensor
- value
- output value
- threshold
- 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.)
- Expired - Fee Related
Links
Images
Description
本発明は、積載した用紙とともにロール状に巻かれた台紙をロールから引き出して印刷を行うラベルプリンタに関し、特に、用紙先端マークに濃淡があったり、台紙にミシン目が形成されていても用紙の頭出しを正確に行えるラベルプリンタに関する。 The present invention relates to a label printer that performs printing by pulling out a mount wound in a roll with a stacked sheet from the roll, and in particular, even if the sheet leading mark is shaded or a perforation is formed on the mount. The present invention relates to a label printer that can accurately perform cueing.
ラベルプリンタは、積載した用紙とともにロール状に巻かれた台紙をロールから引き出して印刷を行う。このため、用紙の先端が所定の位置に到達したことを検出するために、検出センサを備えており、これで台紙に設けられたマークや用紙の端部をセンサで検出することで用紙位置を判断している。 The label printer performs printing by pulling out a mount wound in a roll shape together with the loaded paper from the roll. For this reason, a detection sensor is provided to detect that the leading edge of the paper has reached a predetermined position. With this, the position of the paper is detected by detecting the mark provided on the mount or the edge of the paper with the sensor. Deciding.
図15に、マークの読み取りの一例を示す。マークが検出センサを通過する際に、センサの出力値は徐々に増加していき、マークの中央の部分でセンサ出力値が最大となる。そして、センサ出力値は徐々に減少していき、元の出力レベルに戻る。センサの出力波形は、マークの中央の部分を中心として略対象となる。コンパレータはセンサ出力値が所定の閾値以上となった時にONし、所定の閾値を下回るとOFFする。 FIG. 15 shows an example of mark reading. When the mark passes through the detection sensor, the output value of the sensor gradually increases, and the sensor output value becomes maximum at the center of the mark. Then, the sensor output value gradually decreases and returns to the original output level. The output waveform of the sensor is substantially the object around the central part of the mark. The comparator is turned on when the sensor output value exceeds a predetermined threshold value, and turned off when the sensor output value falls below the predetermined threshold value.
特許文献1に開示される発明は、検出センサの出力の最大値及び最小値並びに現在の閾値を基に新しい閾値を求めることにより、マークの検出精度を高めるものである。
The invention disclosed in
ところで、ロールの中には、台紙にミシン目が設けられているものがある。図16に、ミシン目が形成されている台紙のマークを読み取る動作の一例を示す。ミシン目が検出センサを通過する際にセンサ出力値が増加し、マークが検出センサを通過する際には、元の出力レベルに戻ることなくセンサ出力値は最大となる。そして、センサ出力値は徐々に減少していき、元の出力レベルに戻る。 By the way, some rolls have perforations on the mount. FIG. 16 shows an example of an operation for reading a mark on a mount on which a perforation is formed. When the perforation passes the detection sensor, the sensor output value increases, and when the mark passes the detection sensor, the sensor output value becomes maximum without returning to the original output level. Then, the sensor output value gradually decreases and returns to the original output level.
この時、図16に示すようにコンパレータがONする閾値が高く設定されていれば、コンパレータがONする期間は、マークが検出センサを通過するタイミングと一致するため、用紙の位置を正確に検出することが可能である。 At this time, if the threshold value for turning on the comparator is set high as shown in FIG. 16, the period during which the comparator is turned on coincides with the timing at which the mark passes the detection sensor, and thus the position of the sheet is accurately detected. It is possible.
しかし、コンパレータがONする閾値が高く設定されていると、マークの濃淡ばらつきなどの原因でセンサ出力値が閾値以上とならない場合があり、その場合は用紙が検出されずに印刷ページ抜けが発生してしまう。 However, if the threshold value at which the comparator is turned on is set high, the sensor output value may not exceed the threshold value due to variations in the density of the mark. In this case, the page is missing without detecting the paper. End up.
これを防ぐために、図17に示すようにコンパレータをONさせる閾値を低く設定すると、ミシン目の部分を含めてマークを検出してしまい、用紙位置を正確に検出できなくなってしまう。 In order to prevent this, if the threshold value for turning on the comparator is set low as shown in FIG. 17, marks including the perforation are detected, and the paper position cannot be detected accurately.
マークに濃淡があったり、台紙にミシン目が形成されていてもマークを正確に検出できるようにすることに関する発明として、特許文献2に開示される発明がある。
特許文献2に開示される発明は、検出センサ出力の最大値を常に確認して最大値から補正量を計算して求めることにより、マークの濃淡にばらつきがあったり、台紙にミシン目が形成されていたりしてもマークの位置を正確に検出できる。
There is an invention disclosed in
In the invention disclosed in
しかし、特許文献2に開示される発明は、検出センサの出力の最大値を常に確認するため、高感度のセンサや処理速度の速いA/Dコンバータ、CPUなどの高性能のデバイスを用いて構成する必要がある。一般に高性能のデバイスは高価であるため、ラベルプリンタの部品コストが高くなってしまう。
However, the invention disclosed in
本発明は係る問題に鑑みてなされたものであり、高性能のデバイスを用いることなく用紙の頭出しを正確に行えるラベルプリンタ、用紙頭出し位置制御方法及びプログラムを提供することを目的とする。 SUMMARY An advantage of some aspects of the invention is that it provides a label printer, a paper cue position control method, and a program that can accurately cue paper without using a high-performance device.
上記目的を達成するため、本発明は、第1の態様として、用紙が単位量搬送されるごとに用紙の黒レベルを検出するセンサと、センサの出力値が所定の値以上になるとオンし、センサの出力値が所定の値未満となるとオフするコンパレータと、用紙を所定の距離搬送した時の単位量ごとのセンサの出力値を、少なくとも1回の所定の距離の搬送分記録するセンサ出力値記録手段と、センサ出力値記録手段に記録されているセンサの出力値に基づいて、所定の値としての閾値を決定する手段と、閾値とセンサ出力値記録手段に記録されているセンサの出力値とに基づいて、センサ出力値が閾値以上となる用紙上の位置とセンサ出力値が最大となる用紙上の位置との間隔である第1の距離と、センサ出力が閾値以上となる用紙上の位置とセンサ出力値が閾値未満となる用紙上の位置との間隔である第2の距離との比率を算出する手段と、印刷時に、センサ出力が閾値以上となった用紙上の位置とセンサ出力値が閾値未満となった用紙上の位置との距離に比率を乗じることにより、用紙頭出し位置を決定する手段とを有することを特徴とするラベルプリンタを提供するものである。 In order to achieve the above object, the present invention provides, as a first aspect, a sensor that detects the black level of a sheet every time the sheet is conveyed by a unit amount, and is turned on when an output value of the sensor becomes a predetermined value or more. A comparator output that is turned off when the output value of the sensor is less than a predetermined value, and a sensor output value that records the output value of the sensor for each unit amount when the paper is conveyed for a predetermined distance for at least one predetermined distance of conveyance. Recording means, means for determining a threshold value as a predetermined value based on the sensor output value recorded in the sensor output value recording means, and the sensor output value recorded in the threshold value and sensor output value recording means Based on the above, the first distance, which is the distance between the position on the sheet where the sensor output value is equal to or greater than the threshold and the position on the sheet where the sensor output value is maximum, and the position on the sheet where the sensor output is equal to or greater than the threshold Position and sensor output Means for calculating a ratio with a second distance that is an interval from a position on the paper whose value is less than the threshold, and a position on the paper where the sensor output is equal to or greater than the threshold and the sensor output value are less than the threshold during printing The present invention provides a label printer characterized by having means for determining a paper cueing position by multiplying the distance to the position on the paper by a ratio.
また、上記目的を達成するため、本発明は、第2の態様として、用紙が単位量搬送されるごとに用紙の黒レベルを検出するセンサと、センサの出力値が所定の値以上になるとオンし、センサの出力値が所定の値未満となるとオフするコンパレータとを有するラベルプリンタでの用紙頭出し位置制御方法であって、用紙を所定の距離搬送した時の単位量ごとのセンサの出力値を、少なくとも1回の所定の距離の搬送分センサ出力値記録手段に蓄積し、蓄積したセンサの出力値に基づいて、所定の値としての閾値を決定し、閾値と蓄積したセンサの出力値とに基づいて、センサ出力値が閾値以上となる用紙上の位置とセンサ出力値が最大となる用紙上の位置との間隔である第1の距離と、センサ出力が閾値以上となる用紙上の位置とセンサ出力値が閾値未満となる用紙上の位置との間隔である第2の距離との比率を算出し、印刷時に、センサ出力が閾値以上となった用紙上の位置とセンサ出力値が閾値未満となった用紙上の位置との距離に比率を乗じることにより、用紙頭出し位置を決定することを特徴とする用紙頭出し位置制御方法を提供するものである。 In order to achieve the above object, according to a second aspect of the present invention, a sensor for detecting the black level of the paper every time the paper is transported by a unit amount, and an ON value when the output value of the sensor exceeds a predetermined value. A method for controlling the cueing position of a label printer having a comparator that is turned off when the output value of the sensor is less than a predetermined value, wherein the output value of the sensor for each unit amount when the paper is conveyed by a predetermined distance Is stored in at least one conveyance distance sensor output value recording means for a predetermined distance, a threshold value is determined as a predetermined value based on the accumulated sensor output value, and the threshold value and the accumulated sensor output value are Based on the first distance, which is the distance between the position on the paper where the sensor output value is equal to or greater than the threshold and the position on the paper where the sensor output value is maximum, and the position on the paper where the sensor output is equal to or greater than the threshold. And sensor output value The ratio between the second distance, which is the distance from the position on the paper that is less than the threshold, is calculated, and the position on the paper where the sensor output is greater than or equal to the threshold and the sensor output value is less than the threshold during printing The present invention provides a paper cue position control method characterized by determining a paper cue position by multiplying a distance to an upper position by a ratio.
また、上記目的を達成するため、本発明は、第3の態様として、ラベルプリンタの動作を制御するコンピュータに、上記本発明の第2の態様に係る用紙頭出し位置制御方法を実行させることを特徴とする用紙頭出し位置制御プログラムを提供するものである。 In order to achieve the above object, according to a third aspect of the present invention, a computer for controlling the operation of the label printer is caused to execute the paper cueing position control method according to the second aspect of the present invention. The present invention provides a paper cueing position control program.
本発明によれば、高性能のデバイスを用いることなく用紙の頭出しを正確に行えるラベルプリンタ、用紙頭出し位置制御方法及びプログラムを提供できる。 According to the present invention, it is possible to provide a label printer, a paper cueing position control method, and a program that can accurately cue paper without using a high-performance device.
本発明の好適な実施の形態について説明する。
図1に、本実施形態に係るラベルプリンタの概略構成を示す。
ロール1から引き出された用紙は、サーマルヘッド2とプラテンローラ3との間に挟持されており、不図示のステッピングモータによって駆動されるプラテンローラ3の回転に伴って搬送される。ロール1とサーマルヘッド2との間の用紙搬送経路上には、検出センサ4が設けられており、台紙に表示されたマーク用紙先端マークを検出可能となっている。なお、図1では、透過型の光センサを想定して用紙の搬送経路を挟んで発光部と受光部とが配置された構成を示しているが、反射型の光センサであっても良いことは言うまでもない。検出センサ4の出力は、用紙先端検出機能部5へ入力される。用紙先端検出機能部5は、検出センサ4の検出結果を基に用紙の頭出しを行う。
A preferred embodiment of the present invention will be described.
FIG. 1 shows a schematic configuration of a label printer according to the present embodiment.
The paper drawn from the
図2に、用紙先端検出機能部5の構成を示す。用紙先端検出機能部5は、検出センサ4の出力値をデジタル化するA/Dコンバータ51、検出センサ4のデジタル化された出力値がテーブル化されて履歴保存されるメモリエリア52、履歴保存されたセンサ出力値に基づいて、閾値及び比率を算出するセンサ閾値調整処理部53、センサ閾値調整処理部53が生成した閾値をアナログ値に変換するD/Aコンバータ54、検出センサ4の出力値がアナログ化された閾値以上である場合にONし、閾値を下回るとOFFするコンパレータ55、コンパレータのON・OFF基づいて用紙頭出し位置を判断する用紙頭出し判断処理部56とを有する。
なお、閾値調整処理部56及び用紙頭出し判断処理部53は、コンピュータによるソフトウェア処理によってCPU等の演算処理装置内に実現可能である。
FIG. 2 shows the configuration of the paper leading edge
The threshold adjustment processing unit 56 and the paper cueing determination processing unit 53 can be realized in an arithmetic processing unit such as a CPU by software processing by a computer.
用紙先端検出機能部5の動作について説明する。図3に、センサ閾値調整処理部53の動作の流れを示す。センサ閾値調整処理部53が行うセンサ閾値調整処理は、検出センサの閾値及び用紙頭出し位置を求める比率を決定する処理である。
センサ閾値調整処理部53は、まず変数を初期化し(ステップS11)、続いてセンサ出力テーブル化処理(ステップS12)及び閾値計算処理(ステップS13)を行い、計算した閾値をコンパレータのON/OFFを切り替える閾値として設定する(ステップS14)。
The operation of the paper leading edge
The sensor threshold value adjustment processing unit 53 first initializes variables (step S11), subsequently performs sensor output table processing (step S12) and threshold value calculation processing (step S13), and sets the calculated threshold value to ON / OFF of the comparator. It sets as a threshold value to switch (step S14).
図4に、センサ出力テーブル化処理の流れを示す。
まず、ステッピングモータを1ステップ駆動させ(ステップS101)、検出センサの出力値をA/Dコンバータを介して読み取る(ステップS102)。閾値調整処理部53は設定されている最大値Ymaxと読み取り値とを比較し(ステップS103)、読み取り値の方が大きい場合には(ステップS103/Yes)、最大値Ymaxを更新する(ステップS104)。読み取り値がYmax以下の場合は(ステップS103/No)、最小値Yminと読み取り値とを比較する(ステップS105)。読み取り値の方が小さい場合には(ステップS105/Yes)、最小値Yminを更新する(ステップS106)。読み取り値がYmin以上の場合には(ステップS105/No)、Yminの更新は行わない。
FIG. 4 shows the flow of the sensor output table processing.
First, the stepping motor is driven one step (step S101), and the output value of the detection sensor is read through the A / D converter (step S102). The threshold adjustment processing unit 53 compares the set maximum value Ymax with the read value (step S103). If the read value is larger (step S103 / Yes), the maximum value Ymax is updated (step S104). ). When the read value is Ymax or less (step S103 / No), the minimum value Ymin is compared with the read value (step S105). If the read value is smaller (step S105 / Yes), the minimum value Ymin is updated (step S106). When the read value is Ymin or more (step S105 / No), Ymin is not updated.
その後、読み取り値の履歴を保存するために、図5に示すように読み取り値を時系列に従って整列させて、センサ記録テーブルとしてメモリエリア52に保存する(ステップS107)。 Thereafter, in order to save the history of reading values, the reading values are arranged in time series as shown in FIG. 5 and stored in the memory area 52 as a sensor recording table (step S107).
その後、コンパレータ55のON/OFFを切り替えるための閾値を決定するために予め決定されている距離分ステッピングモータを駆動したか(ステップ数が既定値に達しているか)を判断する(ステップS108)。既定値に達していない場合(ステップS108/No)、ステップ数をカウントアップし(ステップS109)、再度ステッピングモータを駆動する(ステップS101)。既定値に達している場合は(ステップS108/Yes)、センサ出力テーブル化処理を終了する。 Thereafter, it is determined whether or not the stepping motor has been driven by a predetermined distance in order to determine a threshold value for switching ON / OFF of the comparator 55 (whether the number of steps has reached a predetermined value) (step S108). If the predetermined value has not been reached (step S108 / No), the number of steps is counted up (step S109), and the stepping motor is driven again (step S101). If the predetermined value has been reached (step S108 / Yes), the sensor output table creation process is terminated.
図6に、閾値計算処理の流れを示す。
センサ出力テーブル化処理で求められた最大値Ymax及び最小値Yminから中間値Yminを求めて仮閾値Ymidとする(ステップS201)。その後、保存されたセンサ記録値テーブルを走査して、複数の用紙頭出し位置からセンサ閾値を求めるテーブル走査処理を実行する(ステップS202)。
FIG. 6 shows a flow of threshold value calculation processing.
An intermediate value Ymin is obtained from the maximum value Ymax and the minimum value Ymin obtained in the sensor output table process, and is set as a temporary threshold Ymid (step S201). Thereafter, the stored sensor recording value table is scanned to execute a table scanning process for obtaining sensor threshold values from a plurality of paper cueing positions (step S202).
図7〜図9に、テーブル走査処理の流れを示す。
一つ目の用紙頭出し位置の最大値Ymax1及び最小値Ymin1を求めるため、TBlの最初の値を最小値Ymin1として保存し(ステップS301)、仮閾値Ymidを最大値Ymax1として保存する(ステップS302)。そして、テーブル走査を行うためにカウンタとしてステップ数αに1を設定する(ステップS303)。
まず、最小値Ymin1を求めるため、現在のテーブル値とYmin1とを比較し(ステップS304)、テーブル値の方が小さければ置き換える(ステップS305)。次に、カウンタステップ数αに1を加算し(ステップS306)、その後、テーブル値が仮閾値Ymidを以上となっていないか比較する(ステップS307)。テーブル値が仮閾値以上となっていなければ(ステップS307/No)、マークが検出センサ4から離れた位置にある可能性がある。マークが検出センサ4から離れた位置にある状態では、検出センサの出力値は低いレベルで変動するため、最小値Ymin1が更新される可能性がある。したがって、テーブル値が仮閾値を超えていない場合には、まだ最小値Ymin1が更新される可能性があるため、ステップS304に進み処理を繰り返す。
テーブル値が仮閾値Ymid以上であれば(ステップS307/Yes)、その位置は用紙頭出し検出が開始される位置になり、それ以降に最低値Ymin1が更新されることは想定しにくいため、最小値Ymin1を確定し、最大値Ymax1を検出する処理に移行する。
7 to 9 show the flow of the table scanning process.
In order to obtain the maximum value Ymax1 and minimum value Ymin1 of the first sheet cueing position, the first value of TBl is stored as the minimum value Ymin1 (step S301), and the temporary threshold Ymid is stored as the maximum value Ymax1 (step S302). ). Then, 1 is set to the step number α as a counter to perform table scanning (step S303).
First, in order to obtain the minimum value Ymin1, the current table value is compared with Ymin1 (step S304), and if the table value is smaller, it is replaced (step S305). Next, 1 is added to the counter step number α (step S306), and then, it is compared whether the table value is equal to or larger than the temporary threshold Ymid (step S307). If the table value is not equal to or greater than the temporary threshold value (step S307 / No), there is a possibility that the mark is located away from the
If the table value is equal to or greater than the temporary threshold Ymid (step S307 / Yes), the position is the position where the paper cueing detection is started, and it is difficult to assume that the minimum value Ymin1 is updated thereafter. The value Ymin1 is fixed, and the process proceeds to a process for detecting the maximum value Ymax1.
最大値Ymax1を検出する処理では、まずテーブル値とYmax1とを比較し(ステップS308)、テーブル値の方が大きければ(ステップS308/Yes)、Ymax1を更新する(ステップS309)。次にカウンタステップ数αを1加算し(ステップS310)、テーブル値が仮閾値Ymid以下になっていないかを判断する(ステップS311)。 In the process of detecting the maximum value Ymax1, first, the table value is compared with Ymax1 (step S308), and if the table value is larger (step S308 / Yes), Ymax1 is updated (step S309). Next, the counter step number α is incremented by 1 (step S310), and it is determined whether or not the table value is equal to or less than the temporary threshold Ymid (step S311).
テーブル値が仮閾値Ymidよりも大きければ(ステップS311/No)、まだ最大値Ymax1が更新される可能性があるため、ステップS308に進み処理を繰り返す。
テーブル値が仮閾値Ymid以下であれば(ステップS311/Yes)、用紙頭出し検出が終了される位置になるため、最大値Ymax1が確定する。
If the table value is larger than the temporary threshold Ymid (step S311 / No), there is a possibility that the maximum value Ymax1 is still updated, so that the process proceeds to step S308 and the process is repeated.
If the table value is equal to or less than the temporary threshold Ymid (step S311 / Yes), the maximum value Ymax1 is determined because the paper cueing detection end position is reached.
次に、二つ目の用紙頭出し位置の最大値Ymax2及び最小値Ymin2を求めるため、最小値Ymin2に仮閾値Ymidを格納し(ステップS312)、最大値Ymax2にも仮閾値Ymidを格納する(ステップS313)。
ステップS314〜S321は二つ目の最大値及び最小値を求める処理であり、各ステップにおける処理はステップS304〜S311と同様である。
Next, in order to obtain the maximum value Ymax2 and minimum value Ymin2 of the second paper cueing position, the temporary threshold Ymid is stored in the minimum value Ymin2 (step S312), and the temporary threshold Ymid is also stored in the maximum value Ymax2 (step S312). Step S313).
Steps S314 to S321 are processes for obtaining the second maximum value and the minimum value, and the processes in each step are the same as those in steps S304 to S311.
その後、求められた二つの最小値の平均としてYminを求め(ステップS322)、二つの最大値の平均としてYmaxを求め(ステップS323)、テーブル走査処理を終了する。 Thereafter, Ymin is obtained as the average of the two obtained minimum values (step S322), Ymax is obtained as the average of the two maximum values (step S323), and the table scanning process is terminated.
図6に戻って、閾値計算処理の続きを説明する。テーブル走査処理S202において求められたYmin、Ymaxを基に閾値Ymidを決定する(ステップS203)。
次に、各用紙頭出し位置の最大値の位置とステップS203で決定されたYmidでコンパレータのON/OFFが切り替わる位置とから、用紙頭出し位置を決定する比率を求める比率計算処理を実行する(ステップS204)。
Returning to FIG. 6, the continuation of the threshold value calculation process will be described. A threshold Ymid is determined based on Ymin and Ymax obtained in the table scanning process S202 (step S203).
Next, a ratio calculation process for obtaining a ratio for determining the paper cueing position is executed from the position of the maximum value of each paper cueing position and the position where the comparator ON / OFF is switched at Ymid determined in step S203 ( Step S204).
図10、図11に、比率計算処理の流れを示す。
テーブルを走査するためのカウンタとしてのステップ数αを0に設定する(ステップS401)。そして、閾値Ymidよりも大きくなる(コンパレータ出力がONとなる)位置を求めるため、テーブル値と比較する(ステップS402)。テーブル値の方が小さければ(ステップS402/No)、ステップ数αに1を加算し(ステップS403)、次のテーブル値を閾値Ymidと比較する(ステップS402)。
テーブル値が閾値Ymid以上となったら(ステップS402/Yes)、テーブル値が閾値Ymid以上となった位置を記憶するため、変数βにステップ数αの値を保存し、最大値Ymaxを閾値Ymidで初期化する(ステップS404)。
10 and 11 show the flow of the ratio calculation process.
A step number α as a counter for scanning the table is set to 0 (step S401). Then, in order to obtain a position that is larger than the threshold Ymid (the comparator output is turned on), it is compared with a table value (step S402). If the table value is smaller (step S402 / No), 1 is added to the step number α (step S403), and the next table value is compared with the threshold value Ymid (step S402).
If the table value is equal to or greater than the threshold value Ymid (step S402 / Yes), the position where the table value is equal to or greater than the threshold value Ymid is stored. Therefore, the value of the step number α is stored in the variable β, and the maximum value Ymax is set to the threshold value Ymid. Initialization is performed (step S404).
次に、センサ出力最大値の位置を求めるため、テーブル値と最大値Ymaxとを比較し(ステップS405)、テーブル値の方が大きければ(ステップS405/Yes)、Ymaxを更新してその位置を変数γに保存する(ステップS406)。 Next, in order to obtain the position of the sensor output maximum value, the table value is compared with the maximum value Ymax (step S405). If the table value is larger (step S405 / Yes), Ymax is updated and the position is updated. The variable γ is stored (step S406).
ステップS405、S406の処理を、テーブル値が閾値Ymidを下回る(コンパレータ出力値がOFFとなる)位置まで繰り返す(ステップS407、S408)。 The processes in steps S405 and S406 are repeated until the table value falls below the threshold value Ymid (the comparator output value becomes OFF) (steps S407 and S408).
図12に、各変数の関係を示す。変数βは、テーブル値が閾値Ymid以上となった場所の位置(換言すると、コンパレータ55がONとなる位置)を示している。また、変数γは、センサ出力が最大となる場所の位置を示している。また、変数αは、テーブル値が閾値Ymid以下となる場所の位置(換言すると、コンパレータ55がOFFとなる位置)を示している。 FIG. 12 shows the relationship between each variable. The variable β indicates the position of the place where the table value is equal to or greater than the threshold value Ymid (in other words, the position where the comparator 55 is turned on). The variable γ indicates the position of the place where the sensor output is maximum. The variable α indicates the position of the place where the table value is equal to or less than the threshold value Ymid (in other words, the position where the comparator 55 is turned off).
求められた変数β、変数γ及びステップ数αから、一つ目の用紙頭出し位置のコンパレータがONとなる距離1とセンサ出力値最大位置となる距離2との比率σ1を求める(ステップS409)。
From the obtained variable β, variable γ, and step number α, the ratio σ1 between the
次に、ステップS402〜S409と同様の手順により、コンパレータがONとなる距離3とセンサ出力値最大位置となる距離4との比率σ2を求める(ステップS410〜S417)。
Next, the ratio σ2 between the
その後、比率σ1及びσ2の平均として、用紙頭出し位置比率σを求める(ステップS418)。 Thereafter, a sheet cueing position ratio σ is obtained as an average of the ratios σ1 and σ2 (step S418).
上記のようにして用紙頭出し位置比率σを設定し、実際の印刷時には用紙頭出し判断処理部56は、設定したσを用いて以下に説明する用紙頭出し判断処理を行う。 The paper cue position ratio σ is set as described above, and during actual printing, the paper cue determination processing unit 56 performs a paper cue determination process described below using the set σ.
図13に、用紙頭出し判断処理の流れを示す。
まず、ステッピングモータを1ステップ駆動し(ステップS501)、コンパレータの出力値を読み取る(ステップS502)。そして、既にコンパレータがONとなっているかを判断するため、コンパレータがONとなっている時にONとなる用紙頭検出フラグの状態を確認する(ステップS503)。まだコンパレータがONになっていない(用紙頭検出フラグがOFFである)ならば(ステップS503/Yes)、読み取り値がONであるか否かを判断する(ステップS504)。
読み取り値がONであるならば(ステップS504/Yes)、用紙頭検出フラグをONに設定し(ステップS505)、コンパレータがONとなる距離を求めるためにカウンタをゼロクリアする(ステップS506)。その後、用紙頭出し判断処理を一旦抜け、再度実行された場合にはステップS501から処理を再開する。
FIG. 13 shows a flow of paper cueing determination processing.
First, the stepping motor is driven one step (step S501), and the output value of the comparator is read (step S502). Then, in order to determine whether the comparator is already ON, the state of the paper head detection flag that is ON when the comparator is ON is confirmed (step S503). If the comparator has not been turned on yet (the paper head detection flag is OFF) (step S503 / Yes), it is determined whether or not the read value is ON (step S504).
If the read value is ON (step S504 / Yes), the paper head detection flag is set to ON (step S505), and the counter is cleared to zero to determine the distance at which the comparator is ON (step S506). Thereafter, the paper cueing determination process is temporarily exited, and when it is executed again, the process is restarted from step S501.
用紙頭検出フラグがONになっている(既にコンパレータがONとなっている)場合(ステップS503/No)、カウンタを1加算して(ステップS507)、距離を更新する。そして、読み取り値がOFFであるか否かを判断する(ステップS508)。読み取り値がOFFであるならば(ステップS508/Yes)、用紙頭検出フラグをクリアする(ステップS509)。そして、カウンタの値を基にコンパレータがONとなる距離を求め、カウンタに比率σを乗算した値から頭出し位置を算出する(ステップS510)。図14に示すように、頭出し位置はマークの中央の位置に相当する。さらに、用紙頭出し判断処理部56は、カウンタ値から頭出し位置を減算し、補正量を求める(ステップS511)。図14に示すように、補正量は、マークの中央からマークの後端までの距離に相当する。この補正量を、サーマルヘッド2〜検出センサ4間の距離から減算することで、頭出し停止量が求められる(ステップS512)。図14に示すように、頭出し停止量は、マークが検出センサ4を通過した後どれだけ用紙を送れば印刷開始位置がサーマルヘッド2に到達するかを示す量である。これにより、正しい位置から印刷を開始することが可能となる。
If the paper head detection flag is ON (the comparator is already ON) (step S503 / No), the counter is incremented by 1 (step S507), and the distance is updated. Then, it is determined whether or not the read value is OFF (step S508). If the read value is OFF (step S508 / Yes), the paper head detection flag is cleared (step S509). Then, the distance at which the comparator is turned on is obtained based on the value of the counter, and the cue position is calculated from the value obtained by multiplying the counter by the ratio σ (step S510). As shown in FIG. 14, the cue position corresponds to the center position of the mark. Further, the paper cueing determination processing unit 56 subtracts the cueing position from the counter value to obtain a correction amount (step S511). As shown in FIG. 14, the correction amount corresponds to the distance from the center of the mark to the rear end of the mark. By subtracting this correction amount from the distance between the
このように、本実施形態に係るラベルプリンタは、用紙先端マークに濃淡があったり、用紙先端マークの手前にミシン目が存在していても用紙の頭出しを正確に行える。しかも、実際の印刷には用紙頭出し判断処理のみを行うため、高感度のセンサや処理速度の速いA/Dコンバータ、CPUなどの高性能のデバイスを用いて構成する必要はないため、製造コストの高騰を抑えることができる。 As described above, the label printer according to the present embodiment can accurately cue the paper even if the paper front end mark is shaded or a perforation exists in front of the paper front end mark. In addition, since only the paper cueing determination process is performed in actual printing, it is not necessary to use a high-sensitivity sensor, a high-speed A / D converter, or a high-performance device such as a CPU. Can be prevented.
なお、上記実施形態は本発明の好適な実施の一例であり、本発明はこれに限定されることはない。
例えば、上記実施形態においては、最大値及び最小値を二つ求め、それを基にコンパレータのON/OFFを切り替える基準となる閾値や、コンパレータがONとなる距離とセンサ出力値最大位置となる距離との比率を二つ求めて平均を算出する例を示したが、三つ以上の最大値及び最小値から3以上の閾値や比率を求めてそれぞれの平均を算出しても良い。
このように、本発明は様々な変形が可能である。
In addition, the said embodiment is an example of suitable implementation of this invention, and this invention is not limited to this.
For example, in the above-described embodiment, the maximum value and the minimum value are obtained, a threshold value serving as a reference for switching ON / OFF of the comparator based on the two values, the distance at which the comparator is ON, and the distance at which the sensor output value is the maximum position Although an example is shown in which the average is calculated by obtaining two ratios, the average may be calculated by obtaining three or more thresholds and ratios from three or more maximum values and minimum values.
As described above, the present invention can be variously modified.
1 ロール
2 サーマルヘッド
3 プラテンローラ
4 検出センサ
5 用紙先端検出機能部
51 A/Dコンバータ
52 メモリエリア
53 センサ閾値調整処理部
54 D/Aコンバータ
55 コンパレータ
56 用紙頭出し判断処理部
DESCRIPTION OF
Claims (9)
前記センサの出力値が所定の値以上になるとオンし、前記センサの出力値が前記所定の値未満となるとオフするコンパレータと、
前記用紙を所定の距離搬送した時の前記単位量ごとの前記センサの出力値を、少なくとも1回の前記所定の距離の搬送分記録するセンサ出力値記録手段と、
前記センサ出力値記録手段に記録されている前記センサの出力値に基づいて、前記所定の値としての閾値を決定する手段と、
前記閾値と前記センサ出力値記録手段に記録されている前記センサの出力値とに基づいて、前記センサ出力値が前記閾値以上となる前記用紙上の位置と前記センサ出力値が最大となる前記用紙上の位置との間隔である第1の距離と、前記センサ出力が前記閾値以上となる前記用紙上の位置と前記センサ出力値が前記閾値未満となる前記用紙上の位置との間隔である第2の距離との比率を算出する手段と、
印刷時に、前記センサ出力が前記閾値以上となった前記用紙上の位置と前記センサ出力値が前記閾値未満となった前記用紙上の位置との距離に前記比率を乗じることにより、用紙頭出し位置を決定する手段とを有することを特徴とするラベルプリンタ。 A sensor that detects the black level of the paper each time the paper is transported by a unit amount;
A comparator that is turned on when the output value of the sensor is equal to or greater than a predetermined value, and that is turned off when the output value of the sensor is less than the predetermined value;
Sensor output value recording means for recording the output value of the sensor for each unit amount when the paper is transported by a predetermined distance for at least one transport of the predetermined distance;
Means for determining a threshold value as the predetermined value based on the output value of the sensor recorded in the sensor output value recording means;
Based on the threshold value and the sensor output value recorded in the sensor output value recording means, the position on the sheet at which the sensor output value is equal to or greater than the threshold value and the sheet at which the sensor output value is maximized A first distance that is an interval from the upper position, and a position between the position on the sheet at which the sensor output is equal to or greater than the threshold and the position on the sheet at which the sensor output value is less than the threshold. Means for calculating a ratio to a distance of 2;
When printing, a paper cueing position is obtained by multiplying the distance between the position on the paper where the sensor output is greater than or equal to the threshold and the position on the paper where the sensor output value is less than the threshold by the ratio. And a label printer.
前記用紙に対する印刷を実行する印刷ヘッドと前記センサとの距離と、前記補正量との差を、印刷時の前記用紙の搬送量とすることを特徴とする請求項1記載のラベルプリンタ。 During printing, the distance between the position on the paper where the sensor output is greater than or equal to the threshold and the position on the paper where the sensor output value is less than the threshold, and the output value of the sensor is greater than or equal to the threshold The difference from the paper position to the paper cue position is calculated as a correction amount,
The label printer according to claim 1, wherein a difference between a distance between a print head that performs printing on the sheet and the sensor and the correction amount is a conveyance amount of the sheet at the time of printing.
各回の前記単位量ごとの前記センサの出力値を基に算出した、それぞれの回についての前記閾値及び前記比率について各々平均をとることを特徴とする請求項1又は2記載のラベルプリンタ。 The output value of the sensor for each unit amount is recorded in the sensor output value recording means for two or more conveyances of the predetermined distance,
3. The label printer according to claim 1, wherein an average is taken for each of the threshold value and the ratio for each time calculated based on the output value of the sensor for each unit amount each time.
前記センサの出力値が所定の値以上になるとオンし、前記センサの出力値が前記所定の値未満となるとオフするコンパレータとを有するラベルプリンタでの用紙頭出し位置制御方法であって、
前記用紙を所定の距離搬送した時の前記単位量ごとの前記センサの出力値を、少なくとも1回の前記所定の距離の搬送分センサ出力値記録手段に蓄積し、
前記蓄積した前記センサの出力値に基づいて、前記所定の値としての閾値を決定し、
前記閾値と前記蓄積した前記センサの出力値とに基づいて、前記センサ出力値が前記閾値以上となる前記用紙上の位置と前記センサ出力値が最大となる前記用紙上の位置との間隔である第1の距離と、前記センサ出力が前記閾値以上となる前記用紙上の位置と前記センサ出力値が前記閾値未満となる前記用紙上の位置との間隔である第2の距離との比率を算出し、
印刷時に、前記センサ出力が前記閾値以上となった前記用紙上の位置と前記センサ出力値が前記閾値未満となった前記用紙上の位置との距離に前記比率を乗じることにより、用紙頭出し位置を決定することを特徴とする用紙頭出し位置制御方法。 A sensor that detects the black level of the paper each time the paper is transported by a unit amount;
A paper cueing position control method in a label printer having a comparator that is turned on when the output value of the sensor is equal to or greater than a predetermined value and turned off when the output value of the sensor is less than the predetermined value,
The output value of the sensor for each unit amount when the paper is transported for a predetermined distance is accumulated in the transport sensor output value recording means at least once for the predetermined distance,
Based on the accumulated output value of the sensor, determine a threshold value as the predetermined value,
Based on the threshold value and the accumulated output value of the sensor, an interval between the position on the paper where the sensor output value is equal to or greater than the threshold and the position on the paper where the sensor output value is maximum. A ratio between a first distance and a second distance that is an interval between a position on the sheet at which the sensor output is equal to or greater than the threshold and a position on the sheet at which the sensor output value is less than the threshold is calculated. And
When printing, a paper cueing position is obtained by multiplying the distance between the position on the paper where the sensor output is greater than or equal to the threshold and the position on the paper where the sensor output value is less than the threshold by the ratio. A method for controlling the cueing position of a sheet, characterized by:
前記用紙に対する印刷を実行する印刷ヘッドと前記センサとの距離と、前記補正量との差を、印刷時の前記用紙の搬送量とすることを特徴とする請求項5記載の用紙頭出し位置制御方法。 During printing, the distance between the position on the paper where the sensor output is greater than or equal to the threshold and the position on the paper where the sensor output value is less than the threshold, and the output value of the sensor is greater than or equal to the threshold The difference from the paper position to the paper cue position is calculated as a correction amount,
6. The paper cue position control according to claim 5, wherein a difference between a distance between the print head that performs printing on the paper and the sensor and the correction amount is a conveyance amount of the paper at the time of printing. Method.
各回の前記単位量ごとの前記センサの出力値を基に算出した、それぞれの回についての前記閾値及び前記比率について各々平均をとることを特徴とする請求項5又は6記載の用紙頭出し位置制御方法。
The output value of the sensor for each unit amount is accumulated in the sensor output value recording means for the conveyance of the predetermined distance twice or more,
Was calculated based on the output value of the sensor for each of said unit quantity of each round, the sheet indexing position according to claim 5 or 6, wherein the taking each average for said threshold value and said ratio for each round Control method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009076547A JP5307595B2 (en) | 2009-03-26 | 2009-03-26 | Label printer, paper cueing position control method and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009076547A JP5307595B2 (en) | 2009-03-26 | 2009-03-26 | Label printer, paper cueing position control method and program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2010228839A JP2010228839A (en) | 2010-10-14 |
JP5307595B2 true JP5307595B2 (en) | 2013-10-02 |
Family
ID=43045038
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2009076547A Expired - Fee Related JP5307595B2 (en) | 2009-03-26 | 2009-03-26 | Label printer, paper cueing position control method and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5307595B2 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5320240B2 (en) * | 2009-09-28 | 2013-10-23 | Necエンベデッドプロダクツ株式会社 | Printing position control apparatus, label printer, and printing position control method |
JP5904798B2 (en) | 2012-01-13 | 2016-04-20 | サトーホールディングス株式会社 | RFID tag and method of attaching the same |
JP2013189005A (en) | 2012-02-13 | 2013-09-26 | Sato Holdings Corp | Printer |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2959961B2 (en) * | 1994-06-28 | 1999-10-06 | 東芝テック株式会社 | Printer |
-
2009
- 2009-03-26 JP JP2009076547A patent/JP5307595B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2010228839A (en) | 2010-10-14 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7976018B2 (en) | Discharged-sheet monitoring mechanism and method for printer | |
AU2009210361B2 (en) | Medium conveying apparatus and image forming apparatus | |
RU2741511C1 (en) | Information processing device, printing device and information processing method | |
US20100330262A1 (en) | Recording apparatus and sheet processing method | |
RU2598289C2 (en) | Printing device, control method and storage medium | |
JP5307595B2 (en) | Label printer, paper cueing position control method and program | |
JPH0437964A (en) | Document reading device | |
JP4437188B2 (en) | Cutting system and cutting position detection method | |
US11459199B2 (en) | Printing apparatus | |
US20140043664A1 (en) | Sheet conveyance device that can detect sheet size | |
JPH06255840A (en) | Skew correcting method | |
JPH11193152A (en) | Image forming device | |
JP2001253149A (en) | Method for correcting page upper end position of printer, apparatus therefor, computer readable medium, computer-program element, and printer with the apparatus | |
JP4275324B2 (en) | Image forming apparatus | |
US11082576B2 (en) | Image reading apparatus, image reading method, and image reading system | |
JP2006281677A (en) | Recording device | |
US11230451B2 (en) | Estimate count of print media | |
JPH07101076A (en) | Ink jet recording device | |
JP2005280210A (en) | Paper end detection device and printer using the same | |
JP4098481B2 (en) | Information code reading method and apparatus | |
JPH09190113A (en) | Recording medium classifying device and recording medium calssifying method | |
JPH08156282A (en) | Ink jet recorder | |
JP6697956B2 (en) | Image forming device | |
JPH04116053A (en) | Recording sheet completion advance notice mark detecting system | |
JP4093082B2 (en) | Image forming apparatus |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD01 | Notification of change of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7421 Effective date: 20110920 |
|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20111215 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20130305 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20130312 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20130509 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20130604 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20130627 |
|
R150 | Certificate of patent or registration of utility model |
Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
LAPS | Cancellation because of no payment of annual fees |