JPH0444312B2 - - Google Patents
Info
- Publication number
- JPH0444312B2 JPH0444312B2 JP61212639A JP21263986A JPH0444312B2 JP H0444312 B2 JPH0444312 B2 JP H0444312B2 JP 61212639 A JP61212639 A JP 61212639A JP 21263986 A JP21263986 A JP 21263986A JP H0444312 B2 JPH0444312 B2 JP H0444312B2
- Authority
- JP
- Japan
- Prior art keywords
- mark
- paper
- marks
- read
- printing
- 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 - Lifetime
Links
Description
【発明の詳細な説明】
〔産業上の利用分野〕
本発明は、用紙の種別、印字内容等を示す識別
マークの記録された用紙が装填され、識別マーク
の読取を光電的に行なうプリンタにおいて、識別
マークの読取を行なう方法に関するものである。DETAILED DESCRIPTION OF THE INVENTION [Industrial Application Field] The present invention relates to a printer loaded with paper on which identification marks indicating the type of paper, printed content, etc. are recorded, and in which the identification marks are read photoelectrically. The present invention relates to a method for reading identification marks.
伝票用紙等へ印字を行なう際、用紙の種別、印
字内容等に応じ、バーコード形式等による識別
(以下、ID)マークを用紙の所定部位へ記録して
おき、光学的読取装置による用紙内容の判別を可
能とし、または、IDコードの印字された用紙へ
追加印字を行なう場合、IDコードの読取に応じ
て印字内容を設定し、これにしたがつて追加印字
を行なうことがだされている。
When printing on slip paper, etc., an identification (hereinafter referred to as ID) mark in the form of a bar code is recorded on a predetermined part of the paper depending on the paper type, printing content, etc., and an optical reading device records the paper content. When making identification possible or performing additional printing on paper with an ID code printed on it, it has been proposed to set the printing content according to the reading of the ID code and perform additional printing accordingly.
すなわち、用紙の行方向へ所定のピツチとして
各々が特定幅を有する複数のマークからなるID
マークを記録しておき、これをプリンタが印字の
開始に先立ち基準位置から一定方向へ光電的に読
取り、各マークの配列状況に応じて用紙の識別を
行ない、これにしたがう印字を行なうものとなつ
ている。 In other words, an ID consisting of multiple marks each having a specific width at a predetermined pitch in the line direction of the paper.
Marks are recorded, and the printer reads them photoelectrically in a fixed direction from a reference position before starting printing, identifies the paper according to the arrangement of each mark, and prints accordingly. ing.
しかし、用紙が単票状の場合、ガイドに沿つて
用紙を挿入しても、挿入状況に傾斜を生じ、プリ
ンタの読取機構と用紙のIDマークとの相対関係
が不正規となり、あらかじめ機構的に定めた基準
位置から読取を行なうと読取状況が不正確となる
ため、用紙の識別が不可能となり、あるいは、識
別に誤りを生ずる等の問題を招来している。
However, if the paper is in the form of a single sheet, even if the paper is inserted along the guide, the insertion situation will be tilted, and the relative relationship between the printer's reading mechanism and the ID mark on the paper will be irregular. If reading is performed from a predetermined reference position, the reading situation will be inaccurate, leading to problems such as making it impossible to identify the paper or causing an error in identification.
前述の問題を解決するため、本発明はつぎの手
段により構成するものとなつている。
In order to solve the above-mentioned problem, the present invention is constructed by the following means.
すなわち、上述のプリンタにおいて、各マーク
を一定方向へ光電的に読取つて最初のマークを検
出しかつこのマークの幅を求め、この幅の値へ1/
2を乗じて中心位置を算出し、この中心位置から
特定幅の1/2を減じて基準位置を求め、この基準
位置を基準として識別マークの読取を行なうもの
としている。 That is, in the above-mentioned printer, each mark is photoelectrically read in a certain direction, the first mark is detected, the width of this mark is determined, and the value of this width is divided by 1/
The center position is calculated by multiplying by 2, the reference position is obtained by subtracting 1/2 of the specific width from this center position, and the identification mark is read using this reference position as a reference.
したがつて、実際に検出した最初のマークの読
取開始側々辺が基準位置として求められ、これを
基準とした読取が行なわれるものとなり、IDマ
ークの読取および判別が確実となる。
Therefore, the reading start sides of the first mark actually detected are determined as reference positions, and reading is performed based on these positions, making it possible to reliably read and identify ID marks.
以下、実施例を示す図によつて本発明の詳細を
説明する。
Hereinafter, details of the present invention will be explained with reference to figures showing examples.
第2図は、水平形プリンタの要部を示す側面図
であり、供給口1から挿入された用紙は、上下に
対向して配されたガイド板2a,2bへ互に対向
して設けられた発光ダイオードおよび受光トラン
ジスタ等の給紙センサ3により検出され、この検
出出力に応じて移送用のモータ4が回転するのに
したがい、ギヤ5,6、ブーリ7およびベルト8
を介してローラ9,10が矢印方向へ回転し、ロ
ーラ9,10を当接する抑えローラ11,12に
より用紙が挾持され、図上右方へ移送される。 FIG. 2 is a side view showing the main parts of the horizontal printer, in which the paper inserted from the supply port 1 is placed facing each other on guide plates 2a and 2b arranged vertically opposite each other. It is detected by the paper feed sensor 3 such as a light emitting diode and a light receiving transistor, and as the transport motor 4 rotates according to the detection output, the gears 5, 6, the pulley 7 and the belt 8 are rotated.
The rollers 9 and 10 rotate in the direction of the arrow, and the paper is held between the holding rollers 11 and 12 that are in contact with the rollers 9 and 10, and is transported to the right in the figure.
たゞし、ローラ9と10との中間には、下方に
プラテン13が設けてあると共に、これと対向す
る上方にワイヤードツト印字式の印字ヘツド14
が設けてあり、これの供給口1側に給紙センサ3
と同様の紙端センサ15が設けられており、これ
により用紙の前縁が検出されると、この位置を基
準として用紙の印字開始位置が印字ヘツド14の
直下へ一致するまでの移送距離が定めてあるた
め、この移送距離分を移送するとモータ4が停止
し印字待機状態となる。 However, between the rollers 9 and 10, a platen 13 is provided on the lower side, and a wire dot printing type printing head 14 is provided on the upper side facing the platen.
is provided, and a paper feed sensor 3 is installed on the supply port 1 side of this.
A paper edge sensor 15 similar to the above is provided, and when the leading edge of the paper is detected by this, the transport distance is determined based on this position until the printing start position of the paper coincides directly below the print head 14. Therefore, when the paper is transferred by this distance, the motor 4 stops and enters a printing standby state.
印字ヘツド14は、図上省略した機構により、
供給口1側から見て左右両方向へ移動すると共
に、用紙面に対し垂直方向へ進退自在として支持
されており、用紙面と先端14aとの間隙が用紙
厚に応じて自動的に定められ、印字の開始したが
つて左右両方向へ移動しながら印字を行ない、1
行分の印字終了に応じてモータ4が回転して改行
を行ない、つぎに印字ヘツド14が反応方向へ移
動しながら印字を行ない、以上の動作を反復する
ものとなつており、印字の進行に伴ない、用紙が
図上右方の排出口16側へ次第に移送される。 The print head 14 is operated by a mechanism not shown in the figure.
It is supported so that it can move in both left and right directions when viewed from the supply port 1 side, and can move forward and backward in a direction perpendicular to the paper surface, and the gap between the paper surface and the leading edge 14a is automatically determined according to the paper thickness. As the process starts, printing is performed while moving both left and right, and 1
When printing for a line is completed, the motor 4 rotates to perform a line feed, and then the printing head 14 prints while moving in the reaction direction, and the above operations are repeated, and the printing progresses. Accordingly, the paper is gradually transferred to the discharge port 16 on the right side in the figure.
また、用紙の後縁が紙端センサ15を通過する
とき、これの出力変化により後緑が検出され、こ
の位置を基準として用紙の最終印字位置が定めら
れるものとなつている。 Further, when the trailing edge of the paper passes the paper edge sensor 15, trailing green is detected based on a change in the output of the paper edge sensor 15, and the final printing position of the paper is determined based on this position.
第3図は、印字ヘツド14の支持状況を示す読
部破断斜視図であり、両側方の側板21a,21
b間にインクリボンのカートリツジ22が装着さ
れ、これの背面に垂直方向へ移動自在とした可動
ガイドシヤフト23が設けてあると共に、可動ガ
イドシヤフト23が下部を貫通しかつ滑合する支
持台24の水平方向突出部24aへ印字ヘツド1
4が固定されており、支持台24の上方開口部2
4bには、垂直方向へ移動自在であるのに対し、
水平方向には支持台24と係止されているスリー
ブ25が設けてあり、これを滑合状に貫通する固
定ガイドシヤフト26により、支持台24の可動
ガイドシヤフト23を中心とする回動が阻止さ
れ、可動ガイドシヤフト23を図上省略した偏心
カムによる機構により上下すれば、印字ヘツド1
4が用紙面に対し自在に進退するものとなつてい
る。 FIG. 3 is a cutaway perspective view of the reading section showing how the printing head 14 is supported, and shows side plates 21a and 21 on both sides.
An ink ribbon cartridge 22 is installed between b, and a movable guide shaft 23 is provided on the back side of the ink ribbon cartridge 22, and the movable guide shaft 23 is movable in the vertical direction. Print head 1 to horizontal protrusion 24a
4 is fixed, and the upper opening 2 of the support base 24
4b, while it is movable in the vertical direction,
A sleeve 25 that is engaged with the support base 24 is provided in the horizontal direction, and a fixed guide shaft 26 that passes through the sleeve 25 in a sliding manner prevents the support base 24 from rotating around the movable guide shaft 23. If the movable guide shaft 23 is moved up and down by a mechanism using an eccentric cam (not shown in the figure), the printing head 1 can be moved up and down.
4 can freely move forward and backward relative to the paper surface.
また、側板21aの外側には、印字ヘツド14
を移動させるモータ27が固定してあり、これの
回転に応じ、プーリ28,29間へ張架されたシ
ンクロベルト30の一部が支持台24と軽視され
ているため、支持台24が左右方向へ移動し、こ
れに伴つて印字ヘツド14も同様に移動するもの
となつている。 Further, a printing head 14 is provided on the outside of the side plate 21a.
The motor 27 that moves the motor 27 is fixed, and as the motor 27 rotates, a part of the synchro belt 30 stretched between the pulleys 28 and 29 is considered to be the support stand 24, so the support stand 24 moves in the left and right direction. The printing head 14 is also moved accordingly.
なお、モータ27の回転にしたがい、プーリ3
1,32およびベルト33を介し、カートリツジ
22中を経由して印字ヘツド14の先端下面へ張
架されたインクリボン34も同時に駆動され、印
字に応じて循環移動を行なうものとなつている。 In addition, as the motor 27 rotates, the pulley 3
An ink ribbon 34, which is stretched over the lower surface of the tip of the print head 14 through the cartridge 22 and the belt 33, is simultaneously driven and circulated in response to printing.
したがつて、モータ27の正転および逆転に応
じて印字ヘツド14が左方から右方および右方か
ら左方へ往復移動し、この両方向移動毎に印字ヘ
ツド14を駆動することにより、両方向からの印
字が各行として行なわれる。 Therefore, the print head 14 reciprocates from the left to the right and from the right to the left in response to the forward and reverse rotation of the motor 27, and by driving the print head 14 each time it moves in both directions, it is possible to print from both directions. is printed as each line.
第4図、IDマークの読取を行なうIDセンサの
取付状況を示す斜視図であり、支持台24の水平
方向突出部24aに対し、取付板36を介して
IDセンサン37が下方へ向けて固定されており、
IDセンサ37は、印字ヘツド14の先端14a
とほゞ同一左右方向の用紙部位を対象とし、投光
および反射光の受光を行ない、印字ヘツド14と
共に一体として移動しながらIDマークの光学的
読取を行なうものとなつている。 FIG. 4 is a perspective view showing how the ID sensor for reading the ID mark is mounted, and is attached to the horizontal protrusion 24a of the support base 24 via the mounting plate 36.
ID sensor 37 is fixed facing downward,
The ID sensor 37 is connected to the tip 14a of the print head 14.
The ID mark is optically read while moving as a unit with the print head 14, by projecting light and receiving reflected light, targeting the same area of the paper in the left and right direction.
なお、自らIDマークを印字した後に、IDマー
クの確認を行なうため読取を行なう際は、例えば
印字ヘツド14が右方向へ移動しながらIDマー
クの印字を行ない、これについで左方向へ移動す
る間にIDセンサ37がIDマークの読取を行なう
ものとなつている。 When reading the ID mark to confirm it after printing the ID mark by yourself, for example, print the ID mark while moving the print head 14 to the right, and then print the ID mark while moving to the left. An ID sensor 37 is configured to read the ID mark.
第5図は、以上の制御を行なう回路構成のブロ
ツク図であり、マイクロプロセツサ(以下、
CPU)およびメモリ等からなる主制御部(以下、
MCT)41、これと同様であるが若干小規模な
副制御部(以下、SCT)42が設けてあり、
MCT41には、増幅整形回路(以下、AWF)4
3を介するIDセンサ(以下、IDS)37の検出出
力が与えられていると共に、図上省略した電子計
算機等の上位装置(以下、UCE)とデータの授
受を行なうものとなつている。 FIG. 5 is a block diagram of the circuit configuration that performs the above control, and is implemented by a microprocessor (hereinafter referred to as
The main control unit (hereinafter referred to as
MCT) 41, and a similar but slightly smaller sub-control unit (hereinafter referred to as SCT) 42.
MCT41 includes amplification shaping circuit (hereinafter referred to as AWF) 4
The detection output of an ID sensor (hereinafter referred to as IDS) 37 is provided via the ID sensor 3, and data is exchanged with a host device such as a computer (hereinafter referred to as UCE) not shown in the figure.
またSCT42には、MCT41からの指令が与
えられている一方、駆動回路(以下、DRV)4
4を介し、ステツプモータを用いた移動用モータ
(以下、SPM)27を駆動すると共に、DRV4
5を介して印字ヘツド(以下、PHD)14の駆
動も行なうものとなつている。 In addition, the SCT 42 is given commands from the MCT 41, while the drive circuit (hereinafter referred to as DRV) 4
4, a moving motor (hereinafter referred to as SPM) 27 using a step motor is driven, and the DRV 4
A print head (hereinafter referred to as PHD) 14 is also driven via the print head 5.
なお、MCT41、SCT42な、各々CPUがメ
モリ中の命令を実行し、必要とするデータをメモ
リに対してアクセスしながら所定の制御動作を行
なうものとなつている。 Note that each CPU, such as the MCT 41 and the SCT 42, executes instructions in the memory and performs predetermined control operations while accessing necessary data from the memory.
第6図は、IDマークの記録状況および読取状
況を示す図であり、Aにおいては、用紙51の前
縁52に対し、その近傍かつ図上左右方向の印字
を行なう行方向へ、所定のピツチPにより各々が
特定幅Wを有する複数の長方形マーク511,5
32,541〜54nおよび、551,552が例え
ば黒色として記録されており、この例では、マー
ク531,532がスタートマーク、マーク541
〜54nがコードマーク、マーク551,552が
ストツプマークとして用いられ、スタートマーク
532とコードマーク541との間、およびコード
マーク54nとストツプマーク551との間は、
各2マーク分がスペースとなつている一方、コー
ドマーク541〜54nは、コードマーク541を
最下位ビツト、マーク54nを最上位ビツトと
し、例えば2進コードにより用紙51の識別コー
ドを表わすものとなつているため、これの内容に
応じてスペースとするマークが定められる。 FIG. 6 is a diagram showing the recording status and reading status of the ID mark. In A, a predetermined pitch is placed on the front edge 52 of the paper 51 in the vicinity of the leading edge 52 and in the horizontal direction in the figure. A plurality of rectangular marks 51 1 , 5 each having a specific width W by P
3 2 , 54 1 to 54n and 55 1 , 55 2 are recorded as black, for example, and in this example, marks 53 1 and 53 2 are start marks and marks 54 1
~54n is used as a code mark, marks 551 and 552 are used as stop marks, and between the start mark 532 and the code mark 541 , and between the code mark 54n and the stop mark 551 ,
While each two marks are spaces, the code marks 54 1 to 54 n represent the identification code of the paper 51 using a binary code, for example, with the code mark 54 1 as the least significant bit and the mark 54 n as the most significant bit. Therefore, the mark to be used as a space is determined according to the content.
また、Bにおいては、用紙51に対するPHD
14およびIDS37の移動速度Sを示し、両端の
移動限界位置PHLおよびPHRから各々30ステツプの
駆動をSPM27に対して行なう間は、速度Sが
変化する加速または減速区間となつており、これ
らの区間との境界位置PCL,RCRの間が一定速度の
印字または読取を行なう定速区間であり、この区
間では約1200ステツプの駆動をSPM27に対し
て行なうものとなつている。 In addition, in B, PHD for paper 51
14 and IDS37, and while the SPM27 is driven 30 steps each from the movement limit positions PHL and PHR at both ends, it is an acceleration or deceleration section in which the speed S changes. The area between the boundary position P CL and R CR is a constant speed area in which constant speed printing or reading is performed, and in this area, approximately 1200 steps of driving are performed on the SPM 27.
なお、IDマーク531〜552は、用紙51へあ
らかじめ印刷され、または、MCT41を介する
UCEからのIDマーク印字指令に応じ、SCT42
がSPM27およびPHD14の駆動により印字す
るものとなつており、この場合には、矢印P方向
の移動によりIDマーク531〜551を印字し、こ
れにつぐ矢印R方向の移動によりIDマーク552
〜531を印字とは反対方向から遂次読取り、こ
の状況をMCT42中のメモリへ格納のうえ、こ
れらの動作終了後にメモリの内容を格納時とは反
対方向から読取し、IDマーク531〜552を矢印
P方向に沿う一定方向から読取つたときと同等の
判別を行ない、印字状況の確認を行なうものとな
つている。 Note that the ID marks 53 1 to 55 2 are printed on the paper 51 in advance or are printed via the MCT 41.
In response to the ID mark printing command from UCE, SCT42
is to be printed by driving the SPM 27 and PHD 14. In this case, ID marks 53 1 to 55 1 are printed by moving in the direction of arrow P, and ID marks 55 2 are printed by moving in the direction of arrow R.
~53 1 is successively read from the direction opposite to that of printing, this status is stored in the memory in the MCT 42, and after these operations are completed, the contents of the memory are read from the direction opposite to the direction in which it was stored, and the ID mark 53 1 ~ 55 2 is read from a certain direction along the direction of arrow P, and the printing status is checked.
第7図は、IDマークの検出状況を示す図であ
り、Aに示す例えばスタートマーク531,532
をIDS37により検出すると、Bの電気信号が得
られ、これをAWF43中において増幅し、基準
レベルLsにより波形整形を行なうと、Cのパルス
状波形となり、これの高いレベルが検出出力Bの
白を示す論理値「0」、低レベルが同出力Bの黒
を示す同様な「1」となる。 FIG. 7 is a diagram showing the detection status of ID marks, for example, start marks 53 1 , 53 2 shown in A.
When detected by the IDS37, an electrical signal B is obtained, which is amplified in the AWF43 and waveform shaped using the reference level Ls , resulting in a pulsed waveform C, whose high level is the white of the detection output B. The logic value "0" indicates that the output B is low, and the logic value "1" indicates that the output B is black when the low level is low.
たゞし、第6図の定速区間における読取は、ク
ロツクパルスと同期したSPM27の駆動に応じ
てなされると共に第7図Cのパルス状波形が
MCT41においてクロツクパルスと同期したサ
ンプリングにより処理されるため、スタートマー
ク531,532は一定方向Pに沿うドツトに分解
され、この例では、スタートマーク531,532
が各々8ドツトにより構成されたものとして処理
される。 However, the reading in the constant speed section of FIG. 6 is done in accordance with the driving of the SPM 27 in synchronization with the clock pulse, and the pulse-like waveform of FIG.
In the MCT 41, the start marks 53 1 and 53 2 are processed by sampling synchronized with the clock pulse, so the start marks 53 1 and 53 2 are decomposed into dots along a certain direction P. In this example, the start marks 53 1 and 53 2
are processed as if they each consist of 8 dots.
また、第7図Bの波形歪に基づき、スタートマ
ーク531,532の幅Wが同図Cのパルス幅xへ
減少し、この例では幅Wの8ドツトが幅xの6ド
ツトへ減少するものとなり、各マーク541〜5
4n551,552においても同様となる。 Furthermore, based on the waveform distortion shown in FIG. 7B, the width W of the start marks 53 1 and 53 2 is reduced to the pulse width x shown in FIG. Each mark 54 1 to 5
The same applies to 4n55 1 and 55 2 .
一方、第6図において、スタートマーク531
の側辺53aを基準位置PRとし、これを基準と
して一定方向PへIDマーク531〜552の読取を
行なえば、これらの判別を正確とできるが、ID
マーク531〜552の印刷された、あるいは、別
途に印字された用紙51が挿入された場合、挿入
状況に応じてIDマーク531〜552と境界位置
PCL,PCRとの相対関係に偏差を生じており、環境
位置PCLから一定ステツプ数の位置を基準位置PR
として読取を行なうと、IDマーク531〜552の
マークスペースとの判別が不正確となるため、基
準位置PRを実際の読取状況に応じて正確に求め
なければならない。 On the other hand, in Fig. 6, start mark 53 1
If the ID marks 53 1 to 55 2 are read in a certain direction P using the side 53a as a reference position P R , these identifications can be made accurately.
When the paper 51 on which the marks 53 1 to 55 2 are printed or separately printed is inserted, the border position of the ID marks 53 1 to 55 2 is determined depending on the insertion status.
There is a deviation in the relative relationship between P CL and P CR , and the position of a certain number of steps from the environmental position P CL is changed to the reference position P R
If the ID marks 53 1 to 55 2 are read as follows, the ID marks 53 1 to 55 2 will be inaccurately distinguished from the mark space, so the reference position PR must be accurately determined according to the actual reading situation.
すなわち、第10図aに示すようなスタートマー
クイに続くロ以降のマークを読み取る場合を想定
する。第10図bはこのマークを読み取つたときの
アナログ信号であり、第10図cはそのアナログ信
号を2値化した信号である。CPUは第10図cに
示す信号を取り込んでおり、その信号のLレベル
信号が5ドツト以上あるものを黒レベルとして判
定するようになつている。 That is, let us assume a case where the marks after B following the start mark A as shown in FIG. 10a are to be read. FIG. 10b shows an analog signal when this mark is read, and FIG. 10c shows a signal obtained by converting the analog signal into a binary value. The CPU takes in the signal shown in FIG. 10c, and determines that the signal has an L level signal of 5 or more dots as a black level.
この場合、CPUはcの信号を全ての場所がに
ついて、すなわちの時点t1からt2まで連続してど
こに黒レベルがあるかを調べることはCPU処理
時間が増し、好ましくない。第10図aに示すよ
うに黒レベルはPの間隔でしか配置されていない
のでその間隔に対応するタイミングの部分だけ調
べれは充分であつて、それ以外の時間CPUは他
の処理を行い得る。 In this case, it is not preferable for the CPU to examine the signal c at all locations, that is, to continuously check where the black level is from time t1 to time t2, as this increases CPU processing time. As shown in FIG. 10a, the black levels are arranged only at intervals of P, so it is sufficient to examine only the timing portion corresponding to the interval, and the CPU can perform other processing at other times.
第10図dはスタートマークイに対応する二値
化信号「ろ」の発生時点からPの間隔で黒レベル
があるか否かを調べた例である。この例では信号
「い」の信号は記号a2の部分から判定を開始す
ることになるが、これはcに示すように、二値化
信号の途中から調べることになる。 FIG. 10d is an example in which it is checked whether or not there is a black level at intervals of P from the time point when the binary signal ``ro'' corresponding to the start mark I is generated. In this example, the determination of the signal "I" starts from the part of the symbol a2, but this means checking from the middle of the binarized signal as shown in c.
二値化信号はマークの幅全てにわたつて発生す
るのでなく、マークの幅8ドツトより狭くなつて
いる。判定は図の左方向に行われるので、二値化
信号の途中から黒レベルか否かの判断を行うとそ
の信号が終了するまでの時点(二値化信号の右
端)まで調べても黒レベルが5ドツト分以下とな
つてしまう可能性がある。この図ではa2,a
4,a5の部分がその箇所であるが、この様な場
合はそこを黒レベルでないと判断してしまう不都
合がある。 The binarized signal is not generated over the entire width of the mark, but is narrower than the eight dot width of the mark. Judgment is made to the left in the diagram, so if you judge whether the black level is in the middle of the binarized signal, the black level will still be the same even if you check until the end of the signal (the right end of the binarized signal). may end up being less than 5 dots. In this figure, a2, a
4, a5 is the location, but in such a case, there is an inconvenience that it is determined that the black level is not at that location.
そこで本願は二値化信号の発生時点あるいはそ
の少し手前から判定を始めるようにしている。こ
のようにすると二値化信号の幅が5ドツト以上あ
れば、そこは必ず黒レベルとして判定する。第1
0図eはこの状態を表している。即ちスタートマ
ークの発生時点よりも手前をスタート地点b1と
し、そこからPの間隔で調べている。このように
すると白レベルの部分から判定を開始し、CPU
が他の処理を行える時間は減少するが、誤判定を
行うことはない。第8図はこのスタート時点を求
める方法を説明する図である。 Therefore, in the present application, the determination is started from the time when the binary signal is generated or slightly before that time. In this way, if the width of the binarized signal is 5 dots or more, it will always be determined as a black level. 1st
Figure 0e represents this state. That is, the point before the start mark is set as the start point b1, and the search is performed at intervals of P from there. In this way, the judgment starts from the white level part, and the CPU
Although the time available for other processing is reduced, false judgments will not occur. FIG. 8 is a diagram illustrating a method for determining this starting point.
第8図は、基準位置PRを求める状況の拡大図
であり、第6図の矢印R方向においてメモリへ格
納されたスタートマーク531とがメモリのアド
レス番号ADRとの関係を示し、境界位置PCLと対
応するアドレス番号ADRをチエツクスタートア
ドレスA3とすれば、これよりアドレス番号ADR
を矢印P方向へ遂次進めてメモリの内容読出を行
なうと、アドレスA1〜A6において最初に「1」
のドツトが読取され、これの幅A1〜A6=6ドツ
トへ1/2を乗ずると中心位置Pcが求められる。 FIG. 8 is an enlarged view of the situation in which the reference position P R is determined, and shows the relationship between the start mark 531 stored in the memory in the direction of the arrow R in FIG. 6 and the memory address number ADR, and the boundary position If the address number ADR corresponding to P CL is the check start address A 3 , then the address number ADR
When the contents of the memory are read by sequentially advancing in the direction of arrow P, "1" is first read at addresses A 1 to A 6 .
dots are read, and the center position P c is obtained by multiplying the width A 1 to A 6 =6 dots by 1/2.
また、破断線により示す原スタートマーク53
1の幅は8ドツトであり、これの1/2=4ドツトお
よび、IDマーク531〜552の印刷偏差、第7図
に示す波形歪等を考慮した許容差2ドツトを中心
位置Pcから減ずれば、許容差を含んだ基準位置
PRと対応するアドレスARが求められ、このアド
レスARを起点としてメモリの内容を遂次読出し、
論理値の「1」,「0」に応じてマーク、スペース
の判断を行なうことにより、IDマーク531〜5
52を正確に判別することができる。 In addition, the original start mark 53 indicated by the broken line
1 has a width of 8 dots, 1/2 of this = 4 dots, and a tolerance of 2 dots, taking into account the printing deviation of ID marks 53 1 to 55 2 and waveform distortion shown in Fig. 7, is the center position P c If subtracted from, the reference position including tolerance
An address A R corresponding to P R is obtained, and the contents of the memory are successively read from this address A R as a starting point.
ID marks 53 1 to 5 are determined by determining marks and spaces according to logical values of “1” and “0”.
5 Able to accurately identify 2 .
第9図は、SCT42のCPUによる基準位置判
断状況のフローチヤートであり、DRV44を介
するSPM27のパルス駆動により「SPM駆動」
101を行ない、第6図に示す例えば限界位置
PHRからの「30ステツプ駆動?」102がY
(YES)となれば「IDマーク読取」111をIDS
37により行ない、これの検出出力をAWF43
およびMCT41を介し「検出データ・メモリ格
納」112によりメモリの各アドレスス順次に格
納し、「1200ステツプ駆動?」113がN(NO)
の間はステツプ111以降を反復する。 FIG. 9 is a flowchart of the reference position judgment situation by the CPU of the SCT 42, and "SPM drive" is performed by pulse driving of the SPM 27 via the DRV 44.
101, for example, the limit position shown in FIG.
“30 step drive?” 102 from P HR is Y
If (YES), “Read ID mark” 111 will be sent to IDS.
37, and the detection output of this is AWF43.
Then, each address is sequentially stored in the memory by the "Detection data/memory storage" 112 via the MCT 41, and the "1200 step drive?" 113 is set to N (NO).
During this time, steps 111 and subsequent steps are repeated.
ステツプ113がYとなり境界位置PCLへ達すれ
ば、更にステツプ102と同じく「30ステツプ駆
動?」121を判断し、これがYとなるいのに応
じ、「SPM停止」122によりSPM27の駆動
を停止してから、「基準位置チエツク」131を
行なう。 When the step 113 becomes Y and the boundary position PCL is reached, the CPU 21 further judges the ``30 step drive?'' 121 in the same way as the step 102, and if this becomes Y, stops the driving of the SPM 27 with the ``SPM stop'' 122. After that, a "reference position check" 131 is performed.
第1図は、「基準位置チエツク」の詳細を示す
フローチヤートであり、ステツプ112により検出
データを格納したメモリのアドレスを指定するア
ドレスカウンタ「ADC←PCL」201により、境
界位置PCLと対応するアドレスを設定し、「メモリ
読取」202を行ない、このデータが「黒?」2
11を判断し、Nのときは「ADC=ADC+1」
212によりアドレスカウンタADCを登算のう
え、ステツプ202以降を反復するのに対し、ステ
ツプ211がYであれば、黒の検出データに応じて
黒のドツト数をカウントするためCPU中へ構成
した黒カウンタ「BCT←0」213によりこれ
をクリアしてから、「BCT=BCT+1」214
により登算し、これのカウント値が5以上となり
黒ドツトが5ドツト以上連続したか否かを
「BCT≧5?」215によりチエツクする。 FIG. 1 is a flowchart showing the details of the "reference position check", in which the address counter "ADC←P CL " 201, which specifies the address of the memory storing the detected data in step 112, corresponds to the boundary position P CL . Set the address to be used, perform "memory read" 202, and check if this data is "black?" 2
11, if N, “ADC=ADC+1”
After registering the address counter ADC in step 212, steps 202 and subsequent steps are repeated.If step 211 is Y, the black dots configured in the CPU are counted in accordance with the black detection data. After clearing this with the counter “BCT←0” 213, “BCT=BCT+1” 214
It is checked by "BCT≧5?" 215 whether the count value is 5 or more and there are 5 or more consecutive black dots.
ステツプ215がNであれば、ステツプ212と同じ
く「ADC=ADC+1」221によりメモリの読取
アドレスを勧め、ステツプ202と同じく「メモリ
読取」222を行ない、これのデータが「黒?」
223をステツプ211と同じく判断し、Yのとき
はステツプ214以降を反復するのに対し、ステツ
プ223がNのときにはステツプ212を介し、ステツ
プ202以降を反復する。 If step 215 is N, the memory read address is recommended by "ADC=ADC+1" 221 as in step 212, "memory read" 222 is performed as in step 202, and the data is "black?"
Step 223 is determined in the same manner as step 211, and when the result is Y, steps 214 and subsequent steps are repeated, whereas when step 223 is N, steps 202 and subsequent steps are repeated via step 212.
したがつて、第8図のとおり、境界位置PCLか
らメモリのアドレスADRが遂次矢印P方向へ進
められると共に、各アドレスの内容が読取されて
黒か白かの判断がなされ、黒ドツトの5ドツト連
続が最初に検出され、ステツプ215がYとなるま
では、黒ドツトが不連続に検出されても雑音また
は用紙の汚点として無視される。 Therefore, as shown in FIG. 8, the memory address ADR is sequentially advanced from the boundary position PCL in the direction of the arrow P, and the contents of each address are read to determine whether it is black or white, and the black dot is Until five consecutive dots are first detected and step 215 returns Y, even if black dots are detected discontinuously, they are ignored as noise or paper smudges.
スタートマーク531が最初に黒ドツトの5ド
ツト連続として検出され、ステツプ215がYとな
れば、ステツプ221〜223と同じく「ADC=ADC
+1」231〜「黒?」233を実行し、ステツ
プ233がYの間はステツプ214と同じく「BCT=
BCT+1」234を行ない、スタートマーク5
31の幅xと対応する黒ドツトの連続数をカウン
トし、スタートマーク531の終了に応じステツ
プ233がNとなるのにしたがい、「PR=ADC−
(BCT/2)−(4+2)」241の演算により、第6
図および第8図の基準位置PRを求める。 If the start mark 531 is first detected as 5 consecutive black dots and step 215 is Y, then "ADC=ADC" is detected as in steps 221 to 223.
+1" 231 to "Black?" 233 are executed, and while step 233 is Y, "BCT=" is executed as in step 214.
BCT + 1” 234 and start mark 5
3. Count the number of consecutive black dots corresponding to the width x of 531, and as the start mark 531 ends and step 233 becomes N, "PR=ADC-
(BCT/2)-(4+2)"241, the 6th
Find the reference position P R in Figures and Figure 8.
すなわち、このときのアドレスカウンタADC
は第8図のアドレスA6を示し、黒カウンタBCT
はスタートマーク531を幅xを示しており、
BCT・(1/2)により中心位置PCが求められ、こ
れより原スタートマーク531幅Wの1/2および許
容差に応ずる(4+2)ドツトを減ずれば、基準
位置PRと対応するメモリ上のアドレスARが求め
られる。 In other words, the address counter ADC at this time
indicates address A 6 in Figure 8, and black counter BCT
indicates the width x of the start mark 53 1 ,
The center position P C is determined by BCT・(1/2), and by subtracting 1/2 of the original start mark 53 1 width W and (4+2) dots corresponding to the tolerance, the center position P C corresponds to the reference position P R. Address A R in memory is found.
したがつて、スセツプ241により求めたアドレ
ARを基準としてメモリの読出しを行ない、各ア
ドレスの内容に応じて黒および白の判断を行なう
ことによりIDマーク531〜552を正確に読取る
ことができる。 Therefore, the address obtained by step 241
The ID marks 53 1 to 55 2 can be read accurately by reading out the memory based on AR and determining whether it is black or white depending on the content of each address.
ただし、ステツプ241の演算上、右辺第3項の
(4+2)は、スタートマーク531の特定幅Wお
よび許容差に応じて定めればよく、条件によつて
は許容差を省略することもできる。 However, in the calculation of step 241, (4+2) in the third term on the right side may be determined according to the specific width W of the start mark 531 and the tolerance, and the tolerance may be omitted depending on the conditions. .
また、ステツプ215による連続ドツト数のチエ
ツクは、5ドツト以上とするほか状況に応じて連
続ドツト数を選定すればよく、第1図の処理を読
取と同時に行なうものとしても同様である。 Further, in checking the number of consecutive dots in step 215, the number of consecutive dots may be selected depending on the situation other than 5 dots or more, and the same applies even if the process of FIG. 1 is performed simultaneously with reading.
なお、MCT41およびSCT42は一体化し、
あるいは、専用の制御回路を用いても同様であ
り、SPM27としてはステツプモータのほか、
移送量の予測できるものであれは各種のモータを
使用できると共に、水平形プリンタのみならず、
各形式のプリンタへ適用できる等、種々の変形が
自在である。 In addition, MCT41 and SCT42 are integrated,
Alternatively, the same effect can be achieved by using a dedicated control circuit, and the SPM27 can be used in addition to a step motor.
Various motors can be used as long as the transfer amount can be predicted, and not only horizontal printers but also
Various modifications are possible, such as being applicable to various types of printers.
以上の説明により明らかなとおり本発明によれ
ば、IDマークの読取に際し、用紙の挿入状況が
不正規であつてもIDマークを正確に読取ること
ができるため、IDマークの読取を行なう各種の
プリンタにおいて顕著な効果が得られる。
As is clear from the above description, according to the present invention, the ID mark can be accurately read even if the paper is inserted in an irregular manner when reading the ID mark, and therefore, various types of printers that read the ID mark can use the present invention. Remarkable effects can be obtained.
図は本発明の実施例を示し、第1図は基準位置
のチエツクのフローチヤート、第2図は要部を示
す側面図、第3図は印字ベツドの支持状況を示す
要部破断斜視図、第4図はIDセンサの取付状況
を示す斜視図、第5図は回路構成のブロツク図、
第6図はIDマークの記録状況および取付状況を
示す図、第7図はIDマークの検出状況を示す図、
第8図は基準位置を求める状況の拡大図、第9図
は基準位置判断状況のフローチヤート、第10図
は判定開始タイミングを説明するための図であ
る。
14……印字ヘツド(PHD)、27……モータ
(SPM)、37……IDS(IDセンサ)、41……主
制御部(MCT)、42……副制御部(SCT)、5
1……用紙、531〜552……IDマーク、PR……
基準位置、P……ピツチ、W……特定幅、Pc……
中心位置。
The figures show an embodiment of the present invention; FIG. 1 is a flowchart for checking the reference position, FIG. 2 is a side view showing the main parts, and FIG. 3 is a cutaway perspective view of the main parts showing the support situation of the printing bed. Figure 4 is a perspective view showing how the ID sensor is installed, Figure 5 is a block diagram of the circuit configuration,
Figure 6 is a diagram showing the recording status and installation status of the ID mark, Figure 7 is a diagram showing the detection status of the ID mark,
FIG. 8 is an enlarged view of the situation in which the reference position is determined, FIG. 9 is a flowchart of the reference position determination situation, and FIG. 10 is a diagram for explaining the determination start timing. 14...Print head (PHD), 27...Motor (SPM), 37...IDS (ID sensor), 41...Main control section (MCT), 42...Sub control section (SCT), 5
1...Paper, 53 1 to 55 2 ...ID mark, P R ...
Reference position, P...Pitch, W...Specific width, P c ...
center position.
Claims (1)
ツチにより記録された各々が特定幅を有する複数
のマークからなる用紙の識別マークを基準位置か
ら一定方向へ読取を行なうプリンタにおいて、 前記各マークを一定方向へ光電的に読取つて最
初のマークを検出しかつ該マークの幅を求め、該
幅の値へ1/2を乗じて中心位置を算出し、該中心
位置から前記特定幅の1/2を減じて前記基準位置
を求め、該基準位置を基準として所定の間隔毎に
前記識別マークの読取を行うことを特徴とするプ
リンタの識別マーク読取方法。[Scope of Claims] 1. In a printer that reads identification marks on a sheet of paper, each consisting of a plurality of marks each having a specific width, recorded at a predetermined pitch in the form of a barcode in the row direction of the paper, in a fixed direction from a reference position. , photoelectrically read each of the marks in a certain direction to detect the first mark, find the width of the mark, multiply the value of the width by 1/2 to calculate the center position, and calculate the specified position from the center position. A method for reading an identification mark for a printer, characterized in that the reference position is obtained by subtracting 1/2 of the width, and the identification mark is read at predetermined intervals using the reference position as a reference.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP61212639A JPS6368986A (en) | 1986-09-11 | 1986-09-11 | Method for reading identification mark of printer |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP61212639A JPS6368986A (en) | 1986-09-11 | 1986-09-11 | Method for reading identification mark of printer |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPS6368986A JPS6368986A (en) | 1988-03-28 |
| JPH0444312B2 true JPH0444312B2 (en) | 1992-07-21 |
Family
ID=16625974
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP61212639A Granted JPS6368986A (en) | 1986-09-11 | 1986-09-11 | Method for reading identification mark of printer |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPS6368986A (en) |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPH01251187A (en) * | 1988-03-31 | 1989-10-06 | Tamura Electric Works Ltd | Method for reading identification mark |
| JP6984520B2 (en) * | 2018-03-28 | 2021-12-22 | 沖電気工業株式会社 | Sheet-shaped medium transfer device, image forming device and sheet-like medium transfer method |
-
1986
- 1986-09-11 JP JP61212639A patent/JPS6368986A/en active Granted
Also Published As
| Publication number | Publication date |
|---|---|
| JPS6368986A (en) | 1988-03-28 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JPH0444312B2 (en) | ||
| JP2934797B2 (en) | Print position determination device for time clock | |
| JPS6233629B2 (en) | ||
| JP2004082641A (en) | Recording device and recording method | |
| JP2608807B2 (en) | Printer paper length detection method | |
| JP3638197B2 (en) | Printer device | |
| US6036384A (en) | Printer for printing edge marks on gaming tickets | |
| JPS63191661A (en) | printing device | |
| JP2005231243A (en) | Printer control apparatus, printer control method, and printer | |
| JPH0315313Y2 (en) | ||
| JPS6369675A (en) | Identification mark printing apparatus of printer | |
| JPH0431067A (en) | Impact type printer | |
| JPH0631566Y2 (en) | Sensor device for time recorder | |
| KR0147577B1 (en) | Printer | |
| JP2690759B2 (en) | Recording device | |
| JP4387316B2 (en) | Form printing device | |
| JP2568712Y2 (en) | Identification code reading device in time clock | |
| JPS6346476B2 (en) | ||
| JP2578920B2 (en) | Printer print positioning mechanism | |
| JPS61215077A (en) | Inserter apparatus | |
| JPH07186481A (en) | Printing device with image reading device | |
| JP2900049B2 (en) | Card processing device with printing function | |
| JPH0431072A (en) | Impact printer | |
| JP2005059424A (en) | Ink jet recorder | |
| JPH07164647A (en) | Serial printer |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313115 |
|
| R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
| R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
| R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
| LAPS | Cancellation because of no payment of annual fees |