JPH0452967B2 - - Google Patents

Info

Publication number
JPH0452967B2
JPH0452967B2 JP60235807A JP23580785A JPH0452967B2 JP H0452967 B2 JPH0452967 B2 JP H0452967B2 JP 60235807 A JP60235807 A JP 60235807A JP 23580785 A JP23580785 A JP 23580785A JP H0452967 B2 JPH0452967 B2 JP H0452967B2
Authority
JP
Japan
Prior art keywords
data
write
magnetic tape
buffer
instruction
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
Application number
JP60235807A
Other languages
Japanese (ja)
Other versions
JPS6295755A (en
Inventor
Masayuki Ishiguro
Noboru Oowa
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.)
Fujitsu Ltd
Original Assignee
Fujitsu 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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP60235807A priority Critical patent/JPS6295755A/en
Priority to US06/883,630 priority patent/US4757396A/en
Priority to AU60031/86A priority patent/AU576090B2/en
Priority to DE86305345T priority patent/DE3689021T2/en
Priority to CA000513624A priority patent/CA1273710A/en
Priority to EP86305345A priority patent/EP0213703B1/en
Priority to KR8605635A priority patent/KR920004769B1/en
Publication of JPS6295755A publication Critical patent/JPS6295755A/en
Priority to CA000614390A priority patent/CA1280510C/en
Publication of JPH0452967B2 publication Critical patent/JPH0452967B2/ja
Granted legal-status Critical Current

Links

Landscapes

  • Digital Magnetic Recording (AREA)

Description

【発明の詳細な説明】 〔目次〕 概 要 産業上の利用分野 従来の技術 発明が解決しようとする問題点 問題点を解決するための手段(第1図) 作 用 実施例 (a) 一実施例の全体構成の説明(第2図) (b) 先取り制御部の構成の説明(第3図、第4
図) (c) 起動処理動作の説明(第5図、第6図) (d) 対ホスト処理動作の説明(第7図、第8図) (e) 対ドライブ処理動作の説明(第9図、第10
図) (f) 全体動作の説明(第11図) (g) 他の実施例の説明 発明の効果 〔概要〕 上位から転送された命令を複数蓄積しうるバツ
フアを備え、命令を先取りする磁気テープ装置の
命令先取り制御方法において、論理的にEOTを
発して命令先取り制御する第1のモードと、実際
のEOT検出によつて命令先取り制御する第2の
モードとを設けることにより、テープ終端領域近
傍でのストリーミング制御による書込みを有効に
行うようにしたものである。
[Detailed Description of the Invention] [Table of Contents] Overview Industrial Application Fields Conventional Technology Problems to be Solved by the Invention Means for Solving the Problems (Fig. 1) Working Example (a) One Implementation Explanation of the overall configuration of the example (Figure 2) (b) Explanation of the configuration of the preemption control section (Figures 3 and 4)
(Figure) (c) Explanation of startup processing operation (Figures 5 and 6) (d) Explanation of host processing operation (Figures 7 and 8) (e) Explanation of drive processing operation (Figure 9) , 10th
(Figure) (f) Explanation of overall operation (Figure 11) (g) Explanation of other embodiments Effects of the invention [Summary] Magnetic tape that is equipped with a buffer that can store multiple instructions transferred from a higher level and that preempts instructions. In the command prefetch control method for the device, by providing a first mode in which command prefetch control is performed by logically issuing an EOT, and a second mode in which command prefetch control is performed by actual EOT detection, it is possible to This allows writing to be performed effectively using streaming control.

〔産業上の利用分野〕[Industrial application field]

本発明は、複数の命令の格納可能なバツフアを
有する磁気テープ装置において、当該バツフアに
上位からの命令を先取りしうる命令先取り制御方
法及びその装置に関する。
The present invention relates to an instruction prefetch control method and apparatus for prefetching instructions from a higher level into the buffer in a magnetic tape device having a buffer capable of storing a plurality of instructions.

コンピユータの外部記憶装置として広く磁気テ
ープ装置が利用されており、近年特に磁気デイス
ク装置等の他に外部記憶装置のバツクアツプ用と
して用いられている。
Magnetic tape devices are widely used as external storage devices for computers, and in recent years have been particularly used for backing up external storage devices in addition to magnetic disk devices.

このような磁気テープ装置においては、第12
図に示す如く、磁気テープへ書込み及び読出しを
行う磁気ヘツドと、磁気テープの走行駆動を行う
磁気テープ駆動部とを有するテープドライブ部1
と、ホストコントローラからの命令によりこれを
制御する制御部CTとが設けられて構成されてい
る。
In such a magnetic tape device, the 12th
As shown in the figure, a tape drive unit 1 has a magnetic head that writes to and reads from a magnetic tape, and a magnetic tape drive unit that drives the magnetic tape.
and a control unit CT that controls this based on instructions from a host controller.

近年、この制御部CT内にバツフアBFを設け、
ホストコントローラからの命令、データを先取り
し、バツフアBF内に蓄えておき、テープドライ
ブ部1に対しバツフアBF内の命令、データを順
次実行させる命令先取り制御を行うものが開発さ
れ、実用に供されている。
In recent years, a buffer BF has been installed within this control unit CT,
A system has been developed that performs command prefetch control that preempts commands and data from the host controller, stores them in the buffer BF, and causes the tape drive section 1 to sequentially execute the commands and data in the buffer BF, and has been put into practical use. ing.

このような磁気テープ装置は、バツフア付き磁
気テープ装置と称され、ホストコントローラから
の命令に対し、非同期でテープドライブ部1を動
作できるので、ホストコントローラ側では一命令
に対しテープドライブ部1の動作完了を待つ必要
なく、命令を継続的に発行でき、又テープドライ
ブ部1もホストコントローラからの命令を待つこ
となく継続的に動作が実行できるから、処理効率
の向上が得られ、特にストリーミングモードの動
作効率を向上しうる。
Such a magnetic tape device is called a buffered magnetic tape device, and can operate the tape drive unit 1 asynchronously in response to commands from the host controller, so the host controller side can operate the tape drive unit 1 in response to one command. Since commands can be issued continuously without having to wait for completion, and the tape drive section 1 can also perform operations continuously without waiting for commands from the host controller, processing efficiency can be improved, especially in streaming mode. Operational efficiency can be improved.

〔従来の技術〕[Conventional technology]

このようなバツフアBFを有して命令を先取り
するために、バツフアBFは複数の命令の蓄積し
うる命令バツフアと、複数のデータの蓄積しうる
データバツフアとで構成され、例えば、命令バツ
フアには最大64命令、データバツフアには最大
256KByteのデータを格納しうるようにして、先
取り命令、データを増加しうるようにしている。
In order to have such a buffer BF and preempt instructions, the buffer BF is composed of an instruction buffer that can store multiple instructions and a data buffer that can store multiple data. 64 instructions, maximum for data buffer
It is designed to be able to store 256KBytes of data, allowing for prefetch instructions and data to be increased.

一方、第13図Aに示す如く磁気テープ16は
無限長でなく、有限長のため、終端には、EOT
(END OF TAPE)マーカが貼付されており、
EOT検出後のテープウオーニングエリア
(TWA)は約3mしか使用できない。
On the other hand, as shown in FIG. 13A, the magnetic tape 16 does not have an infinite length but a finite length, so at the end there is an EOT
(END OF TAPE) marker is attached,
The tape walking area (TWA) after EOT detection can only be used for approximately 3m.

従つて、ライト系の処理においては、先取り命
令・データがEOT検出時に3m分以上であると、
これを磁気テープ16上にライトできなくなり、
何等かの対策が必要となる。
Therefore, in write-based processing, if the prefetch instruction/data is 3m or more at the time of EOT detection,
It becomes impossible to write this onto the magnetic tape 16,
Some kind of countermeasure is required.

従来、このため磁気テープの終端であるEOT
を検出する以前にテープ終端近傍信号EWAを、
例えばEOTの約20m分前に発生し、これによつ
て第13図Bの如く、バツフアBFのデータバツ
フアの蓄積可能量(データバイト数)を減少させ
ていた。例えば第13図Bの如く最大256KByte
のデータの蓄積できるデータバツフアに対し、こ
れを128KByteに減少し、データバツフアのデー
タ蓄積量が128KByte以下にならないと、ホスト
コントローラからのライトデータの受付けを許可
しないようにして、係る書込み不能を防止するよ
うにしていた。
Conventionally, this is why EOT, the end of magnetic tape,
Before detecting the tape end near signal EWA,
For example, this occurred approximately 20 m before EOT, and as a result, the data buffer storage capacity (number of data bytes) of the buffer BF was reduced, as shown in FIG. 13B. For example, as shown in Figure 13B, the maximum is 256KByte.
This is reduced to 128KByte for the data buffer that can store data of I was doing it.

〔発明が解決しようとする問題点〕[Problem that the invention seeks to solve]

係る従来技術によれば、データバツフアの容量
を制限することによつて、間接的にライト系命令
の先取り数を制限しようとするものであつた。
According to such conventional technology, by limiting the capacity of the data buffer, the number of prefetching of write-related instructions is indirectly limited.

一方、係るバツフア付き磁気テープ装置の性能
は、命令先取り数に大きく影響され、命令先取数
が多いほうがストリーミング走行を長く維持で
き、性能的に優れている。
On the other hand, the performance of such a buffered magnetic tape device is greatly influenced by the number of instructions prefetched, and the larger the number of instructions prefetched, the longer streaming can be maintained and the performance is superior.

しかしながら、EOT以降のテープウオーニン
グエリア(TWA)に書込み可能な長さは限られ
ており、EOT検出時に命令先取り数が多過ぎる
と、先取りした全ての命令を実行することができ
なくなる。
However, the length that can be written to the tape warning area (TWA) after EOT is limited, and if the number of prefetched instructions is too large when EOT is detected, it becomes impossible to execute all prefetched instructions.

このため、EOT付近までは先取り数をできる
だけ多くし、EOTが近付いたら書込み可能な数
に減らすことが必要である。
For this reason, it is necessary to increase the number of pre-reads as much as possible until near EOT, and then reduce the number to a writable number as EOT approaches.

しかしながら、従来技術では、データバツフア
の容量制限を行うことから、先取りされるライト
系命令自体が不当に先取り制限されたり、ライト
系命令のうち先取り制限されないものも生じ、テ
ープ終端領域の近傍において効率の良いストリー
ミング走行が困難であるという問題が生じてい
た。
However, in the conventional technology, since the capacity of the data buffer is limited, the prefetched write instructions themselves are unreasonably prefetched, and some write instructions are not prefetched. The problem was that it was difficult to get a good streaming run.

即ち、テープ終端領域近傍におけるライト系命
令を先取り制限し過ぎて、ストリーミング走行が
行われなかつたり、ライト系命令の先取りが多過
ぎて、ストリーミング走行は行われてもTWA内
で全ての命令が実行できないという事態が生じて
いた。
In other words, write-related instructions near the tape end area are too preemptively restricted and streaming is not performed, or too many write-related instructions are prefetched and even though streaming is performed, all instructions are executed within the TWA. There was a situation where I couldn't do it.

本発明は、テープ終端領域近傍において効率良
くストリーミング走行ができ、且つ先取つたライ
ト系命令をTWA内に確実に実行しうる磁気テー
プ装置の命令先取り制御方法及びその装置を提供
することを目的とする。
SUMMARY OF THE INVENTION An object of the present invention is to provide a command preemption control method and apparatus for a magnetic tape device that can efficiently perform streaming near the tape end area and reliably execute preempted write instructions within the TWA. .

〔問題点を解決するための手段〕[Means for solving problems]

第1図は本発明の原理説明図である。 FIG. 1 is a diagram explaining the principle of the present invention.

本発明では、磁気テープ16の終端近傍領域
(EWA)において2つのモードを有している。
In the present invention, the magnetic tape 16 has two modes in the area near the end (EWA).

第1のモード(ロジカルEOTモードと称す)
では磁気テープドライブ部1が磁気テープ16を
走行して、EWAを検出すると、制御部CTが
EWA検出時点から磁気テープの走行距離を計数
し、計数値ECTRが一定値EPTRに達すると、テ
ープ終端領域検出とみなし、疑似的なEOTを得
るようにし、この間のEWAでは第1図Bの実線
の如く命令先取り数を減少しない。
The first mode (referred to as logical EOT mode)
Then, when the magnetic tape drive unit 1 runs the magnetic tape 16 and detects EWA, the control unit CT
The traveling distance of the magnetic tape is counted from the time of EWA detection, and when the counted value ECTR reaches a certain value EPTR, it is regarded as the detection of the end of the tape and a pseudo EOT is obtained. does not reduce the number of instruction prefetching as in

この疑似EOTは通常のEOT検出と同一の効果
を持ち、これによつて、実際に磁気テープに設け
られたEOTマーカを検出することなく、それ以
前にEOTの取扱いが行われる。
This pseudo-EOT has the same effect as normal EOT detection, whereby EOT is handled before actually detecting the EOT marker provided on the magnetic tape.

この第1のモードにおいてEWA検出時点を疑
似EOTとせず、磁気テープ16の一定距離走行
後に疑似EOT検出とするが、これは、EWA検出
機構がドライブのサーボ制御機構を利用したもの
であり、EWA検出点を任意の時点に少ない誤差
で設定することができるだけの精度を有さないた
めである。EWA検出精度を高めるためにサーボ
制御機構の精度を過剰に高くすることは装置のコ
スト上昇を招く。
In this first mode, pseudo EOT is not detected at the time of EWA detection, but pseudo EOT is detected after the magnetic tape 16 has traveled a certain distance. This is because the EWA detection mechanism uses the servo control mechanism of the drive, This is because the accuracy is not high enough to set a detection point at an arbitrary time point with a small error. Increasing the accuracy of the servo control mechanism excessively in order to improve EWA detection accuracy increases the cost of the device.

一方、第2のモード(フイジカルEOTモード
と称す)では、EWA検出から実際にEOTマーカ
を検出するまでをアーリーウオーニングエリア
EWAとし、この間のEWAにおいて第1図Bの点
線の如く、先取りしうる命令数を減少しようとす
るものである。
On the other hand, in the second mode (called physical EOT mode), the period from EWA detection to actually detecting the EOT marker is an early warning area.
EWA, and attempts to reduce the number of instructions that can be prefetched during this EWA, as shown by the dotted line in FIG. 1B.

この第1のモードと第2のモードに切換えは
EWAにおいて、第1のモードで動作途中にリー
ド系命令実行によつて第1のモードの実行が不能
となつた場合に行うと、効率の良いストリーミン
グ走行が実行できる。又、操作パネルによつてモ
ードを選択するようにして、第1のモードと第2
のモードを選択してもよい。
Switching between this first mode and second mode is
In EWA, if execution of the first mode becomes impossible due to execution of a read-related command during operation in the first mode, efficient streaming running can be executed. Also, by selecting the mode using the operation panel, the first mode and the second mode can be selected.
You may also select the mode.

〔作用〕[Effect]

本発明では、第1のモードでは論理的な疑似
EOTを得ているので、第1図Aに示す如くEOT
検出時点を早くすることにより、TWAを長くで
きる。このため、TWAに書込むことのできるブ
ロツク数が多くなるため、第1図Bの実線に示す
如く、EWAにおけるライト系命令の先取り数を
減らす必要がなくなる。
In the present invention, in the first mode, a logical pseudo
Since EOT is obtained, EOT is obtained as shown in Figure 1A.
TWA can be lengthened by making the detection point earlier. Therefore, the number of blocks that can be written to the TWA increases, so there is no need to reduce the number of write instructions in the EWA, as shown by the solid line in FIG. 1B.

従つて、EWAにおいてもストリーミング走行
を続行し且つTWAにおいて全ての先取りライト
系命令を実行できる。
Therefore, streaming can be continued in EWA and all preemptive write-related commands can be executed in TWA.

即ち、第1図Cの実線の如く、EOT付近まで
は、命令先取り数はできるだけ多くし、EOTが
近づいたら、書込み可能な数に減らすという理想
的な先取り制御が可能となる。
That is, as shown by the solid line in FIG. 1C, ideal prefetch control is possible in which the number of instructions prefetched is as large as possible until near EOT, and as the EOT approaches, the number is reduced to a writable number.

一方、第2のモードでは、通常と同様のEWA
において、ライト系命令の蓄積可能数を制限する
ため、ライトデータを伴わないイレーズ、ライト
テープマーク等のライト系命令も制限されるか
ら、磁気テープ内に全てのライト系命令の実行が
でき、ライト系命令の処理不能を防止することが
できる。
On the other hand, in the second mode, EWA similar to normal
In order to limit the number of write-related instructions that can be stored, write-related instructions such as erase and write tape mark that do not involve write data are also limited, so all write-related instructions can be executed on the magnetic tape and write It is possible to prevent system instructions from being unable to be processed.

即ち、ライトデータを伴わないライト系命令で
あるイレーズやライトテープマークも制限され、
ライト系命令を不当に制限することなく、第1図
Cの点線の如く、先取つたライト系命令を全て
TWA内に実行できる。
In other words, write commands such as erase and write tape mark that do not involve write data are also restricted.
As shown in the dotted line in Figure 1C, all write-related instructions that have been pre-empted are not unduly restricted.
Can be executed within TWA.

〔実施例〕〔Example〕

(a) 一実施例の全体構成の説明 第2図は、本発明の一実施例の説明のための全
体構成図である。
(a) Description of overall configuration of one embodiment FIG. 2 is an overall configuration diagram for explaining one embodiment of the present invention.

図中、第12図で示したものと同一のものは同
一の記号で示してあり、1はリール間直接駆動方
式の磁気テープドライブユニツト(以下ドライブ
と称す)であり、巻取リール(マシンリール)1
1と供給リール(フアイルリール)12の間に磁
気テープ16がテンシヨンアーム15のローラ1
5a、磁気ヘツド14、アイドラ13を介して巻
取リール11に至るよう構成され、磁気ヘツド1
4の両側ではガイド17a,17bによつてガイ
ドされている。
In the figure, the same components as those shown in FIG. )1
1 and a supply reel (file reel) 12, a magnetic tape 16 is attached to the roller 1 of the tension arm 15.
5a, a magnetic head 14, an idler 13, and a take-up reel 11.
4 is guided by guides 17a and 17b on both sides.

一方、巻取リール11、供給リール12は各々
駆動モータ10a,10bによつて回転駆動さ
れ、更に駆動モータ10a,10bにはロータリ
ーエンコーダ18a,18bが設けられ駆動モー
タ10a,10bの回転量を検出できるようにし
ている。又、アイドラ13にもロータリーエンコ
ーダ19aが設けられ、これによつて実際のテー
プの走行位置の監視を可能とし、一方、テンシヨ
ンアーム15には張力検出器19bが設けられ、
テープ張力の検出を可能としている。
On the other hand, the take-up reel 11 and the supply reel 12 are rotationally driven by drive motors 10a and 10b, respectively, and rotary encoders 18a and 18b are provided on the drive motors 10a and 10b to detect the amount of rotation of the drive motors 10a and 10b. I'm trying to make it possible. Further, the idler 13 is also provided with a rotary encoder 19a, which makes it possible to monitor the actual running position of the tape, while the tension arm 15 is provided with a tension detector 19b.
This makes it possible to detect tape tension.

2はドライブ制御部であり、後述する命令・デ
ータ先取り制御部からの命令及びデータによつて
テープ走行駆動及びヘツド書込み又は読取り駆動
を行うものであり、各ロータリーエンコーダ18
a,18b,19aの出力を受けて走行状態を監
視し、又張力検出器19bの出力より張力を監視
し、駆動回路20,21を介し両駆動モータ10
a,10bを制御して、テープ張力を一定にしつ
つテープを走行駆動するとともに磁気ヘツド14
にライトデータを与え書込みを行わせ且つ磁気ヘ
ツド14からのリードデータを受けるものであ
る。
Reference numeral 2 denotes a drive control section, which drives the tape running and drives the head for writing or reading according to commands and data from a command/data prefetch control section, which will be described later.
a, 18b, and 19a to monitor the running state, and also monitor the tension from the output of the tension detector 19b.
a and 10b to drive the tape to run while keeping the tape tension constant, and also to drive the magnetic head 14.
It supplies write data to perform writing and receives read data from the magnetic head 14.

3は命令・データ先取り制御部であり、ホスト
コントローラからのライト系又はリード系の命令
及びライトデータを受け、これらを蓄え、ライト
系命令ならドライブ制御部2へライト命令及びラ
イトデータを送り、ライト動作せしめ、且つ正常
終了なら次のブロツクのライト命令及びライトデ
ータを送り、正常終了でなければドライブ制御部
2へライトリトライ動作せしめるものである。
Reference numeral 3 denotes a command/data prefetch control unit which receives write or read commands and write data from the host controller, stores them, and sends write commands and write data to the drive control unit 2 in the case of write commands. If the operation is completed normally, the write command and write data for the next block are sent, and if the operation is not completed normally, the drive control section 2 is made to perform a write retry operation.

命令・データ先取り制御部3は、後述する命令
バツフアとデータバツフアを有し、ホストコント
ローラに対しては磁気テープ装置として動作し、
ドライブ制御部2に対してはホストコントローラ
として動作するアダプタである。
The command/data prefetch control unit 3 has a command buffer and a data buffer, which will be described later, and operates as a magnetic tape device for the host controller.
For the drive control unit 2, it is an adapter that operates as a host controller.

(b) 先取り制御部の構成の説明 第3図は第2図構成における要部、即ち、命
令・データ先取り制御部3の構成図である。
(b) Description of the structure of the prefetch control section FIG. 3 is a block diagram of the main part in the structure of FIG. 2, that is, the instruction/data prefetch control section 3.

図中、30はマイクロプロセツサ(以下MPU
と称す)であり、後述するプログラムメモリのマ
イクロプログラムに従つてホストコントローラか
らの命令及びデータの受信制御及びデータ、ステ
ータスの送信制御を行うとともに、ドライブ制御
部2へ命令、データの送信制御及びドライブ制御
部からのデータ、ステータスの受信制御を行い、
更にドライブ1の状態制御の処理を行うもの、3
1aはプログラムメモリであり、MPU30が実
行すべきプログラムを格納しておくもの、31b
はランダムアクセスメモリ(以下RAMと称す)
であり、MPU30の処理に必要な各種データ、
命令、パラメータを格納しておくものであり、命
令バツフアエリアCBUF、命令バツフア管理エリ
アCA及びデータバツフア管理エリアDA、各種
モード管理エリアEA、リード命令レジスタRCを
有するものである。
In the figure, 30 is a microprocessor (hereinafter referred to as MPU).
), which controls the reception of commands and data from the host controller and controls the transmission of data and status according to the microprogram in the program memory, which will be described later. Controls reception of data and status from the control unit,
3 further performs state control processing for drive 1;
1a is a program memory that stores programs to be executed by the MPU 30; 31b is a program memory;
is random access memory (hereinafter referred to as RAM)
, various data necessary for MPU30 processing,
It stores instructions and parameters, and has an instruction buffer area CBUF, an instruction buffer management area CA, a data buffer management area DA, various mode management areas EA, and a read instruction register RC.

命令バツフアエリアCBUFには、ライト系コマ
ンド時には、ホストコントローラから先取りした
命令及びその命令により転送されたデータのデー
タバツフア内の先頭アドレス、バイトカウント数
などがリード系コマンド時には先読みしたブロツ
クのリード実行結果、リードデータのデータバツ
フア内の先頭アドレス、バイト数などが格納さ
れ、命令バツフア管理エリアCAには、命令記憶
数CBSTKと、バツフアサイズCBSiZEと、最終
制限値CBEが格納される。命令記憶数CBSTKと
しては、ライト系コマンド時には、命令バツフア
エリアCBUFに記憶され、未だ実行されていない
先取り命令数が、リード系コマンド時には先読み
ブロツク数が格納され、バツフアサイズCBSiZE
は、命令バツフアエリアCBUFの大きさを命令数
で示したものであり、最終制限値は、ロジカル
EOTモードでない時のフイジカルEOTモード時
のEWAにおけるライト系命令先取り数の最終制
限値である。
The instruction buffer area CBUF contains information such as the start address and byte count in the data buffer of the instruction prefetched from the host controller and the data transferred by that instruction in the case of a write command, and the read execution result of the prefetched block in the case of a read command. The starting address, number of bytes, etc. in the data buffer of data are stored, and the instruction buffer management area CA stores the instruction storage number CBSTK, buffer size CBSiZE, and final limit value CBE. The instruction storage number CBSTK is the number of prefetched instructions that are stored in the instruction buffer area CBUF and has not been executed yet for a write type command, and the number of prefetched blocks is stored for a read type command, and the buffer size CBSiZE
is the size of the instruction buffer area CBUF in terms of the number of instructions, and the final limit value is the logical
This is the final limit value for the number of prefetching write instructions in EWA in physical EOT mode when not in EOT mode.

データバツフア管理エリアDAには、データバ
ツフアの空き容量を単位数(1KByte単位)で示
すバツフア空き容量FSEGと、データバツフアへ
の書込みを行うデータ転送時のデータバツフアの
先頭アドレスを示すバツフアアドレスBADRと、
処理の対象となるデータブロツクの最大長を示す
最大ブロツク長MAXLとが格納される。
The data buffer management area DA contains a buffer free capacity FSEG that indicates the free capacity of the data buffer in units (in units of 1KByte), and a buffer address BADR that indicates the start address of the data buffer at the time of data transfer for writing to the data buffer.
The maximum block length MAXL indicating the maximum length of the data block to be processed is stored.

モード管理エリアEAには、ロードポイントか
らの書込み時の記録密度(1600rpi又は6250rpi)
を決定するための書込み記録密度とロジカル
EOTモードであることを示すLEOTフラグと、
ロジカルEOTモード時にEWA検出後のテープ走
行距離を格納する走行カウンタECTRが格納され
る。
The mode management area EA has recording density (1600rpi or 6250rpi) when writing from the load point.
Write recording density and logic to determine
LEOT flag indicating EOT mode,
A travel counter ECTR is stored that stores the tape travel distance after EWA detection in the logical EOT mode.

32aはドライブインターフエイス回路であ
り、ドライブ制御部2との間で制御信号等のやり
とりを行うためのもの、32bはホストインター
フエイス回路であり、ホストコントローラとの間
で制御信号等のやりとりをするもの、33はデー
タ転送制御回路であり、後述するデータバツフア
を制御してホストコントローラ或いはドライブ制
御部2との間のデータ転送を制御するものであ
り、ホストコントローラへデータ転送要求信号を
発し且つドライブ制御部2からのデータ転送要求
信号を受けデータ転送制御を行うものであり、デ
ータバツフアへのストアアドレスカウンタ
SCTR、データバツフアからのロードアドレスカ
ウンタLCTR、バツフアロード時のバイトカウン
タBCTRなどを有するものである。
32a is a drive interface circuit for exchanging control signals etc. with the drive control unit 2; 32b is a host interface circuit for exchanging control signals etc. with the host controller. Reference numeral 33 is a data transfer control circuit, which controls a data buffer (described later) to control data transfer with the host controller or the drive control unit 2, and issues a data transfer request signal to the host controller and controls the drive. It receives a data transfer request signal from part 2 and controls data transfer, and stores address counter to data buffer.
It has an SCTR, a load address counter LCTR from a data buffer, a byte counter BCTR when loading a buffer, and the like.

34はデータバツフアであり、データ転送制御
回路33によつて制御され、ホストコントローラ
からのライトデータを蓄え、ドライブ制御部2へ
転送し、逆にドライブ制御部2からのリードデー
タを蓄え、ホストコントローラへ転送するための
ものであり、例えば256キロバイトの容量を持つ
もの、35はデータバスであり、MPU30とプ
ログラムメモリ31a、RAM31b、ドライブ
インターフエイス回路32a、ホストインターフ
エイス回路32b、データ転送制御回路33とを
接続しコマンド、データのやりとりを行うもので
ある。
34 is a data buffer, which is controlled by the data transfer control circuit 33, stores write data from the host controller and transfers it to the drive control unit 2, and conversely stores read data from the drive control unit 2 and sends it to the host controller. 35 is a data bus, which connects the MPU 30, program memory 31a, RAM 31b, drive interface circuit 32a, host interface circuit 32b, and data transfer control circuit 33. It is used to connect and exchange commands and data.

36aは制御信号線であり、ドライブ制御部2
へコマンド等を送信し、逆にドライブ制御部2か
らステータス等を受信するためのもの、36bは
テープエンド近傍領域検出信号線であり、ドライ
ブ制御部2からのテープエンド近傍領域検出
(EWA)信号の転送のためのもの、36cは割込
み線であり、ドライブインターフエイス回路32
aよりMPU30へ割込みを通知するもの、37
aはデータ転送制御信号線であり、ドライブ制御
部2からデータ転送要求信号をデータ転送制御回
路33へ伝え、データ転送終了信号をドライブ制
御部2へ伝えるためのもの、37bはライトデー
タバスであり、データバツフア34からライトデ
ータをドライブ制御部2へ伝えるためのもの、3
7cはリードデータバスであり、ドライブ制御部
2からのリードデータをデータバツフア34へ伝
えるためのもの、38は制御信号線であり、ホス
トコントローラとコマンド、ステータスのやりと
りを行うためのもの、39aはデータ転送制御信
号線であり、ホストコントローラへデータ転送要
求信号を伝え、ホストコントローラからのデータ
転送終了信号を伝えるためのもの、39bはライ
トデータバスであり、ホストコントローラからの
ライトデータをデータバツフア34へ伝えるため
のもの、39cはリードデータバスであり、ホス
トコントローラへデータバツフア34からリード
データを伝えるためのものである。
36a is a control signal line, which is connected to the drive control unit 2.
36b is a tape end vicinity area detection signal line, which is used to send commands, etc. to the drive control unit 2, and conversely receive status etc. from the drive control unit 2. 36b is a tape end vicinity area detection signal line, which receives the tape end vicinity area detection (EWA) signal from the drive control unit 2. 36c is an interrupt line for the transfer of the drive interface circuit 32.
Something that notifies the MPU 30 of an interrupt from a, 37
37b is a data transfer control signal line for transmitting a data transfer request signal from the drive control unit 2 to the data transfer control circuit 33 and a data transfer end signal to the drive control unit 2; 37b is a write data bus; , for transmitting write data from the data buffer 34 to the drive control unit 2, 3
7c is a read data bus for transmitting read data from the drive control unit 2 to the data buffer 34; 38 is a control signal line for exchanging commands and status with the host controller; 39a is a data bus A transfer control signal line is used to transmit a data transfer request signal to the host controller and a data transfer end signal from the host controller. 39b is a write data bus that transmits write data from the host controller to the data buffer 34. A read data bus 39c is used to transmit read data from the data buffer 34 to the host controller.

従つて、MPU30はデータバス35を介し
RAM31b、ホストインターフエイス回路32
b、ドライブインターフエイス回路32a、デー
タ転送制御回路33との間で書込み、読出しを行
い、所望の処理を行う。
Therefore, the MPU 30 communicates via the data bus 35.
RAM31b, host interface circuit 32
b, writes and reads between the drive interface circuit 32a and the data transfer control circuit 33, and performs desired processing.

即ち、ホストコントローラと制御信号線38を
介しMPU30の制御によりホストインターフエ
イス回路32bがコマンド、ステータスのやりと
りを行い、ドライブ制御部2と制御信号線36a
を介しMPU30の制御によりドライブインター
フエイス回路32aがコマンド、ステータスのや
りとりを行う。
That is, the host interface circuit 32b exchanges commands and status with the host controller under the control of the MPU 30 via the control signal line 38, and the drive control unit 2 and the control signal line 36a.
The drive interface circuit 32a exchanges commands and status under the control of the MPU 30 via the MPU 30.

一方、MPU30の指示によりデータ転送制御
回路33が、データ転送制御信号線39aを介し
ホストコントローラにデータ転送要求を発し、こ
れに応じてホストコントローラはライトデータを
ライトデータバス39bを介しデータバツフア3
4へ送り、蓄積せしめる。又、ドライブ制御部2
からのデータ転送制御信号線37aのデータ転送
要求により、データ転送制御回路33はライトデ
ータバス37bを介しデータバツフア34のライ
トデータをドライブ制御部2へ発する。
On the other hand, in response to instructions from the MPU 30, the data transfer control circuit 33 issues a data transfer request to the host controller via the data transfer control signal line 39a, and in response, the host controller transfers the write data to the data buffer 3 via the write data bus 39b.
4 and accumulate it. In addition, the drive control section 2
In response to a data transfer request from the data transfer control signal line 37a, the data transfer control circuit 33 issues write data from the data buffer 34 to the drive control section 2 via the write data bus 37b.

更に、データ転送制御回路33はMPU30の
指示によりドライブ制御部2からリードデータバ
ス37cを介するリードデータをデータバツフア
34に蓄え、ホストコントローラへリードデータ
バス39cを介しデータバツフア34のリードデ
ータを送信する。
Further, the data transfer control circuit 33 stores read data from the drive control unit 2 via the read data bus 37c in the data buffer 34 according to instructions from the MPU 30, and transmits the read data from the data buffer 34 to the host controller via the read data bus 39c.

尚、ドライブ制御部2は、ロータリーエンコー
ダ19aによる走行位置の監視によつてテープ終
端領域近傍を検出してEWA信号を信号線36b
に発し、EOT検出によつてTWA信号を信号線3
6aに発する。
The drive control unit 2 detects the vicinity of the tape end area by monitoring the running position using the rotary encoder 19a, and transmits the EWA signal to the signal line 36b.
and sends a TWA signal to signal line 3 upon EOT detection.
Emit at 6a.

このような先取り制御部3とホストコントロー
ラ、デバイス1間のインターフエイスは、第4図
Aに示す如く、ホストコントローラからの起動信
号GOとコマンド信号が与えられることによつて
MPU30はホストインターフエイス回路32b
を介し応答信号FBYをホストコントローラへ返
答し、更にコマンド実行中を示すデータビジー
DBYをホストコントローラへ与える。
The interface between the preemption control unit 3, the host controller, and the device 1 is established by receiving the activation signal GO and command signal from the host controller, as shown in FIG. 4A.
MPU30 is host interface circuit 32b
The response signal FBY is returned to the host controller via the
Give DBY to the host controller.

コマンド信号がデータ転送を伴うライト系コマ
ンドなら、データ転送制御回路33からホストコ
ントローラへライトストローブパルスWSTBを
与えて、ホストコントローラからはライトストロ
ーブパルスWSTBに同期してライトデータが転
送され、データバツフアに順次格納される。ホス
トコントローラは最終のライトデータと同時にラ
ストワード信号LWDをデータ転送制御回路33
へ送出し、制御回路33はこのラストワード信号
LWDを検出するとライトストローブパルス
WSTBの送出を止め、データ転送を終了し、受
信動作の正常/異常を示すステータス信号をホス
トコントローラへ与え、データビジーDBYをオ
フしてライトデータの転送動作を終了する。尚、
受信コマンドは命令バツフアCBUFに格納され
る。
If the command signal is a write command that involves data transfer, the data transfer control circuit 33 gives a write strobe pulse WSTB to the host controller, and the host controller transfers the write data in synchronization with the write strobe pulse WSTB, sequentially to the data buffer. Stored. The host controller sends the last word signal LWD to the data transfer control circuit 33 at the same time as the final write data.
The control circuit 33 sends this last word signal to
Light strobe pulse when detecting LWD
Stops WSTB transmission, terminates data transfer, provides a status signal indicating normal/abnormal reception operation to the host controller, turns off data busy DBY, and terminates write data transfer operation. still,
The received command is stored in the command buffer CBUF.

一方、コマンドがリードコマンドなら、テープ
ドライブ1から読取つたリードデータをリードス
トローブパルスRSTBとともにホストコントロー
ラへ転送する。リードデータ転送の終了はデータ
ビジーDBYをオフすることによつてホストコン
トローラへ通知される。
On the other hand, if the command is a read command, the read data read from the tape drive 1 is transferred to the host controller together with the read strobe pulse RSTB. The end of read data transfer is notified to the host controller by turning off data busy DBY.

このようなインターフエイス手順は、第4図B
に示す如く先取り部3とドライブ1との間も同一
であり、先取り部3の命令バツフアCBUF、デー
タバツフア34がフルの状態では、ホストコント
ローラからGO信号、ライトコマンドが到来して
もバツフアCBUF、データバツフア34が空くま
でデータビジーDBYを上げないようにしてデー
タ転送を待たせるようにしている。
Such an interface procedure is shown in Figure 4B.
As shown in the figure, the same relationship exists between the prefetch unit 3 and the drive 1, and when the command buffer CBUF and data buffer 34 of the prefetch unit 3 are full, even if a GO signal and a write command arrive from the host controller, the buffer CBUF and data buffer 34 are full. The data busy DBY is not raised until 34 is free, so that the data transfer waits.

(c) 一実施例の起動処理動作の説明 第5図は本発明の一実施例動作の起動処理フロ
ー図、第6図は第5図における初期設定処理フロ
ー図である。
(c) Description of startup processing operation in one embodiment FIG. 5 is a startup processing flow diagram of one embodiment of the present invention, and FIG. 6 is an initialization processing flow diagram in FIG. 5.

電源が投入されると、MPU30はドライブ
インターフエイス回路32aを介し、ドライブ
の書込み記録密度設定を調べ、RAM31bの
エリアEAの書込み記録密度にドライブの書込
み記録密度設定を記憶する。そして第6図Aの
初期設定処理(1)を行う。
When the power is turned on, the MPU 30 checks the write recording density setting of the drive via the drive interface circuit 32a, and stores the write recording density setting of the drive in the write recording density of the area EA of the RAM 31b. Then, the initial setting process (1) shown in FIG. 6A is performed.

即ち、MPU30はRAM31の命令バツフ
ア管理エリアCAの命令記憶数CBSTKを零ク
リアし、データバツフア管理エリアDAのバツ
フア空き容量FSEGを最大の256単位
(256KByte)とし、データバツフアアドレス
BADRを“00”に設定する。
That is, the MPU 30 clears the instruction storage number CBSTK in the instruction buffer management area CA of the RAM 31 to zero, sets the buffer free capacity FSEG in the data buffer management area DA to the maximum of 256 units (256KByte), and sets the data buffer address
Set BADR to “00”.

更に、データバツフア管理エリアDAの最大
ブロツク長MAXLを最小の8単位(8KByte)
に設定し、エリアEAのロジカルEOTモードフ
ラグをオフとして初期設定(1)を終了する。
Furthermore, the maximum block length MAXL of the data buffer management area DA is set to the minimum 8 units (8KByte).
, turn off the logical EOT mode flag of the area EA, and finish the initial settings (1).

次に電源投入時あるいはREW命令、UNL命
令実行後の初期設定終了後又はホストからの起
動待ちルーチンにおいて、MPU30はバス3
5を介しドライブインターフエイス回路32a
を介し磁気テープが供給リール12にセツトさ
れたオンライン状態にあるかを調べる。
Next, when the power is turned on, after the initial settings are completed after executing the REW command or UNL command, or in a routine waiting for startup from the host, the MPU 30
5 through the drive interface circuit 32a.
It is checked whether the magnetic tape is set on the supply reel 12 and in an online state via the magnetic tape.

オンライン状態にあれば、MPU30はバス
35を介しホストインターフエイス回路32b
のレジスタの内容を調べ、ホストからREW(リ
ワインド)命令又はUNL(アンロード)命令が
到来しているかを調べる。
When online, the MPU 30 connects to the host interface circuit 32b via the bus 35.
The contents of the register are checked to see if a REW (rewind) command or UNL (unload) command has arrived from the host.

REW命令又はUNL命令が到来していれば、
MPU30はドライブ制御部2の実行処理モー
ドがリード系か、ライト系か又は実行中でない
かを調べる。
If a REW or UNL command has arrived,
The MPU 30 checks whether the execution processing mode of the drive control unit 2 is read type, write type, or not currently being executed.

実行処理モードがリード系なら、ドライブ1
の先読みを停止させる。即ち、ドライブ制御部
2が実行中の処理を終了したならばドライブイ
ンターフエイス回路32aを介し制御線36a
よりドライブ制御部2に、新たな処理を命じな
いようにし、リード系処理を停止させる。
If the execution processing mode is read, drive 1
Stop reading ahead. That is, when the drive control unit 2 finishes the process being executed, the control line 36a is transmitted via the drive interface circuit 32a.
Therefore, the drive control unit 2 is not instructed to perform any new processing, and the read-related processing is stopped.

一方、実行処理モードがライト系なら、命令
バツフアCBUF内の全てのライト系命令を実行
させる。
On the other hand, if the execution processing mode is write type, all write type instructions in the instruction buffer CBUF are executed.

そして、全命令の実行後、実行中の処理なし
の場合又はドライブの先読み処理の停止後、
MPU30はドライブインターフエイス回路3
2aを介しREW命令(テープをBOTまで戻
す)又はUNL命令(テープを巻取る)を与え
てドライブ1にこれを実行させ、ステツプの
初期設定(1)へ戻る。
After all instructions have been executed, if there is no processing in progress, or after the drive's prefetch processing has stopped,
MPU30 is drive interface circuit 3
A REW command (to return the tape to BOT) or an UNL command (to wind up the tape) is given through 2a to cause the drive 1 to execute this command, and the process returns to step initialization (1).

一方、REW命令又はUNL命令が到来してい
ないと、MPU30はバス35を介しホストイ
ンターフエイス回路32bのレジスタの内容を
調べ、ホストからの起動(GO)があるかを調
べる。
On the other hand, if the REW instruction or UNL instruction has not arrived, the MPU 30 checks the contents of the register of the host interface circuit 32b via the bus 35 to see if there is a start (GO) from the host.

ホストからの起動がなければ、起動待ちとな
り、ステツプへ戻る。
If there is no activation from the host, the process waits for activation and returns to step.

ホストからの起動あり、即ちGO信号受信と
判断すると、MPU30はバス35を介しホス
トインターフエイス回路32bのレジスタの内
容を調べ、与えられた命令が何かを判断する。
When it is determined that there is activation from the host, that is, a GO signal has been received, the MPU 30 checks the contents of the register of the host interface circuit 32b via the bus 35, and determines what the given command is.

与えられた命令がリード系ならステツプ
へ、記録密度設定ならステツプへ進み、その
処理ルーチンを実行する。
If the given command is a read type command, the process goes to step, and if it is a recording density setting, the process goes to step and executes the processing routine.

命令が記録密度設定なら、MPU30はホス
トインターフエイス回路32bを介しデータビ
ジーDBYをオンとして通知し、更にドライブ
インターフエイス回路32aを介しドライブ1
の磁気テープ16がロードポイントLDP、即
ちBOTの位置にあるかを調べる。
If the command is to set the recording density, the MPU 30 notifies the data busy DBY to be turned on via the host interface circuit 32b, and also notifies the drive 1 via the drive interface circuit 32a.
Check whether the magnetic tape 16 is located at the load point LDP, ie, BOT.

ロードポイントLDPにあれば、記録密度設
定命令が有効であるので、MPU30はドライ
ブインターフエイス回路32aを介し、ドライ
ブに対して記録密度設定命令を実行し後に、
RAM31bのエリアEAの書込み記録密度に
ホストから指示された記録密度をセツトする。
If it is at the load point LDP, the recording density setting command is valid, so the MPU 30 executes the recording density setting command to the drive via the drive interface circuit 32a, and then
The recording density instructed by the host is set as the write recording density of area EA of RAM 31b.

ロードポイントLDPになければ、記録密度
設定命令は無効でありドライブに対する記録密
度設定命令の実行及び書込み記録密度のセツト
は必要ない。
If it is not at the load point LDP, the recording density setting command is invalid and there is no need to execute the recording density setting command to the drive and set the write recording density.

その後、MPU30はホストインターフエイ
ス回路32bを介しホストへ終了報告し、デー
タビジーDBYをオフして、ステツプへ戻る。
Thereafter, the MPU 30 reports completion to the host via the host interface circuit 32b, turns off the data busy DBY, and returns to step.

一方、与えられた命令がライト系なら、
MPU30はドライブ制御部2の実行処理モー
ドがリード系か、ライト系か又は実行中でない
かを調べる。
On the other hand, if the given command is light type,
The MPU 30 checks whether the execution processing mode of the drive control unit 2 is read type, write type, or not currently being executed.

実行処理モードがリード系なら、ドライブ1
の先読み処理を停止させる。即ち、ドライブ制
御部2が実行中の処理を終了したならばドライ
ブインターフエイス回路32aを介し制御線3
6aよりドライブ制御部2に、新たな処理を命
じないようにし、リード系処理を停止させる。
If the execution processing mode is read, drive 1
Stop the prefetch processing. That is, when the drive control section 2 finishes the process being executed, the control line 3 is transmitted via the drive interface circuit 32a.
6a, the drive control unit 2 is not instructed to perform any new processing, and the read-related processing is stopped.

次に、第6図Bの初期設定(2)を実行し、
MPU30はRAM31bの命令バツフア管理
エリアCAの命令記憶数CBSTKを零クリアし、
データバツフア管理エリアDAのバツフア空き
容量FSEGを最大の256とし、データバツフア
アドレスBADRを“00”に設定する。
Next, execute the initial settings (2) in Figure 6B,
The MPU 30 clears the instruction storage number CBSTK in the instruction buffer management area CA of the RAM 31b to zero,
Set the buffer free capacity FSEG in the data buffer management area DA to the maximum of 256, and set the data buffer address BADR to "00".

このステツプの終了後又はドライブ制御部
2が実行中でなければ、第6図Cの初期設定(3)
のバツフアサイズのセツトを行う。
After completing this step or if the drive control unit 2 is not running, the initial settings (3) in Figure 6C
Set the buffer size.

先づ、MPU30は、ドライブインターフエ
イス回路32aを介し信号線36bのEWA(テ
ープ終端近傍領域)信号がオンかオフかを調
べ、オフ(未だテープ終端近傍領域へ到つてい
ない)なら、RAM31bのエリアEAの
LEOTモードフラグをオンし、走行カウンタ
ECTRを零クリアする。
First, the MPU 30 checks whether the EWA (area near the end of the tape) signal on the signal line 36b is on or off via the drive interface circuit 32a, and if it is off (has not yet reached the area near the end of the tape), the EWA signal of the RAM 31b is checked. Area EA
Turn on the LEOT mode flag and turn on the travel counter
Clear ECTR to zero.

一方、EWA信号がオンなら、RAM31b
のLEOTモードフラグがオン(YES)、オフ
(NO)かを調べ、オフなら、命令バツフア管
理エリアCAの最終制限値CBEをバツフアサイ
ズCBSiZEへ移し、リターンする。
On the other hand, if the EWA signal is on, RAM31b
Checks whether the LEOT mode flag is on (YES) or off (NO), and if it is off, moves the final limit value CBE of the instruction buffer management area CA to the buffer size CBSiZE and returns.

逆にLEOTモードフラグがオン又は前述の走
行カウンタECTRの零クリア後、MPU30は、
RAM31bの命令バツフア管理エリアCAの
バツフアサイズCBSiZEに最大値の「64」をセ
ツトし、リターンする。
Conversely, after the LEOT mode flag is turned on or the aforementioned travel counter ECTR is cleared to zero, the MPU 30
The buffer size CBSiZE of the instruction buffer management area CA of the RAM 31b is set to the maximum value "64" and the process returns.

次に、MPU30はテープ位置を調整すべく、
ドライブ制御部2にテープ位置調整のための命
令(スペースまたはバツフアスペース)をドラ
イブインターフエイス回路32aを介し命じ
る。
Next, the MPU 30 adjusts the tape position by
A command (space or buffer space) for tape position adjustment is given to the drive control unit 2 via the drive interface circuit 32a.

そして第7図の後述するライト系処理ルーチ
ンへ進む。
The program then proceeds to a write-related processing routine in FIG. 7, which will be described later.

一方、ステツプで実行処理モードがライト
系なら直ちにライト系処理ルーチンへ進む。
On the other hand, if the execution processing mode in the step is write type, the process immediately advances to the write type processing routine.

ステツプで転送された命令がリード系な
ら、MPU30はドライブ制御部2の実行処理
モードがリード系か、ライト系か又は実行中で
ないかを調べる。
If the instruction transferred in the step is a read type instruction, the MPU 30 checks whether the execution processing mode of the drive control unit 2 is read type, write type, or not being executed.

実行処理モードがリード系なら、MPU30
は先づリード方向が一致しているかを調べリー
ド方向不一致ならドライブ1の先読み処理を停
止させる。即ち、ドライブ制御部2が実行中の
処理を終了したならばドライブインターフエイ
ス回路32aを介し制御線36aよりドライブ
制御部2に、新たな処理を命じないようにし、
リード系処理を停止させる。
If the execution processing mode is read type, MPU30
First, it is checked whether the read directions match, and if the read directions do not match, the pre-reading process of the drive 1 is stopped. That is, once the drive control unit 2 finishes the process being executed, no new process is commanded to the drive control unit 2 from the control line 36a via the drive interface circuit 32a.
Stop read processing.

更に、MPU30はステツプと同一の初期
設定(2)を実行し、次にステツプと同一のテー
プ位置調整を行う。
Furthermore, the MPU 30 executes the same initial setting (2) as in the step, and then performs the tape position adjustment as in the step.

一方、実行処理モードがライト系なら、命令
バツフアCBUF内の全ての命令を実行させる。
On the other hand, if the execution processing mode is write, all instructions in the instruction buffer CBUF are executed.

そして、全命令の実行後、実行中の処理なし
の場合又はドライブ処理の停止後、前述の先読
みリード系命令をRAM31bのリード命令レ
ジスタRCにセツトする。
Then, after all instructions are executed, if there is no process being executed, or after the drive process is stopped, the above-mentioned prefetch read-related instructions are set in the read instruction register RC of the RAM 31b.

そして、このセツト後又は、リード方向一致
なら、第8図のリード系処理ルーチンへ進む。
After this setting, or if the read directions match, the process advances to the read-related processing routine shown in FIG.

従つて、ホストからの起動がライト系コマン
ドであれば、リード系処理中でも、ライト系処
理に切換わり、ライト系処理なら、ライト系処
理を続行する。
Therefore, if the activation from the host is a write-related command, even if read-related processing is in progress, it switches to write-related processing, and if it is write-related processing, write-related processing is continued.

そして初期設定(1)で最大ブロツク長MAXL
は最小の8単位に、初期設定(1)又は(2)で命令記
憶数CBSTKは零、データバツフア空き容量
FSEGは最大の256、データバツフアアドレス
BADRは(00)に、更に初期設定(3)でバツフ
アサイズCBSiZEは、LEOTモードのオン/オ
フに応じ、最大の64又は最終制限値CBEにセ
ツトされる。
And the initial setting (1) is the maximum block length MAXL
is the minimum unit of 8, and with the initial setting (1) or (2), the number of instruction memory CBSTK is zero, and the data buffer free space is
FSEG is maximum 256, data buffer address
BADR is set to (00), and in the initial setting (3), the buffer size CBSiZE is set to the maximum 64 or the final limit value CBE, depending on whether the LEOT mode is turned on or off.

又、ロードポイントLDPからの書込み時に
おける記録密度がRAM31bのエリアEAに
設定される。
Also, the recording density at the time of writing from the load point LDP is set in area EA of the RAM 31b.

(d) 対ホスト処理動作の説明 第7図は対ホストライト系処理フロー図であ
る。
(d) Description of host-related processing operation FIG. 7 is a flowchart of host-based write system processing.

MPU30は第5図によつてホストコントロ
ーラからライト系コマンドによつて起動される
と、ライト系コマンドが格納可能かを調べるた
め、RAM31bの命令バツフア管理エリア
CAの命令記憶数CBSTKと命令バツフアサイ
ズCBSiZEをバス35を介し読み出し比較す
る。CBSiZE≦CBSTK、即ち記憶可能な命令
数までライト系命令が命令バツフアCBUFに格
納されていると、命令バツフアCBUFへのライ
ト系コマンドの格納を保留する。
When the MPU 30 is activated by a write command from the host controller as shown in FIG.
The instruction memory number CBSTK of CA and the instruction buffer size CBSiZE are read out via the bus 35 and compared. If CBSiZE≦CBSTK, that is, write-related instructions are stored in the instruction buffer CBUF up to the number of instructions that can be stored, storage of the write-related commands in the instruction buffer CBUF is suspended.

一方、CBSiZE>CBSTKであれば、ライト
系命令の命令バツフアCBUFへの格納可能なた
め、MPU30は係るライト系命令がデータバ
ツフア34を使用するものかどうかを調べる。
イレーズ、ライトテープマークのデータバツフ
ア34を使用しないものであれば、データビジ
ーDBYをオンとし、ステツプの最終制限値
CBEの初期設定ステツプに進む。
On the other hand, if CBSiZE>CBSTK, the write-related instruction can be stored in the instruction buffer CBUF, so the MPU 30 checks whether the write-related instruction uses the data buffer 34 or not.
If the erase/write tape mark data buffer 34 is not used, turn on the data busy DBY and set the final limit value of the step.
Proceed to the CBE initial configuration steps.

第5図Aで示した如く上位(ホスト)から起
動(GO)とコマンドが与えられると、下位
(先取り制御部3)はその命令が実行可能なら、
実行中であることを示すデータビジーDBY信
号をオンとし上位へ返す。この関係は先取り制
御部3を上位とし、ドライブ制御部2を下位と
した場合も同様である。
As shown in FIG. 5A, when a start (GO) command is given from the higher level (host), the lower level (preemption control unit 3) will, if the command can be executed,
It turns on the data busy DBY signal indicating that it is being executed and returns it to the upper level. This relationship is the same even when the prefetch control section 3 is placed at the upper level and the drive control section 2 is placed at the lower level.

逆に、MPU30はライト系命令がデータバ
ツフア34を使用する通常のライト命令である
と、データバツフア34への自動転送の許可判
断を行う。
Conversely, if the write-related instruction is a normal write instruction that uses the data buffer 34, the MPU 30 determines whether automatic transfer to the data buffer 34 is permitted.

即ち、先づ、MPU30はRAM31bのデ
ータバツフア管理エリアDAの空きバツフア容
量FSEGと最大ブロツク長MAXLを読出し、
空きバツフア容量FSEGが最大ブロツク長
MAXL以上か否かを調べる。空きバツフア容
量FSEGが最大ブロツク長MAXL以下なら、
ライトデータの受信を保留し、データバツフア
34が最大ブロツク長MAXL分空くまで待ち、
空きバツフア容量FSEGが最大ブロツク長
MAXL以上なら、転送許可する。従つて、前
述のデータビジーDBY信号をオンとして、ホ
ストコントローラへ転送可を通知する。
That is, first, the MPU 30 reads the free buffer capacity FSEG and the maximum block length MAXL of the data buffer management area DA of the RAM 31b, and
Free buffer capacity FSEG is maximum block length
Check whether it is greater than or equal to MAXL. If the free buffer capacity FSEG is less than the maximum block length MAXL,
It suspends the reception of write data and waits until the data buffer 34 is free for the maximum block length MAXL.
Free buffer capacity FSEG is maximum block length
If it is more than MAXL, transfer is allowed. Therefore, the aforementioned data busy DBY signal is turned on to notify the host controller that transfer is possible.

次に、MPU30は、ドライブインターフエ
イス回路32aを介しドライブ1の磁気テープ
16がロードポイントLDPの位置にあるかを
調べる。
Next, the MPU 30 checks whether the magnetic tape 16 of the drive 1 is located at the load point LDP via the drive interface circuit 32a.

ロードポイントLDPの位置になければ、既
に最終制限値CBEはセツトされているので、
次の自動転送ステツプへ進む。一方、ロード
ポイントLDPの位置にあれば、書込み記録密
度によつて最終制限値CBEのセツトを行う。
If it is not at the load point LDP, the final limit value CBE has already been set, so
Proceed to the next automatic transfer step. On the other hand, if it is at the load point LDP, a final limit value CBE is set according to the write recording density.

即ち、MPU30は、RAM31bのモード
エリアEAの書込み記録密度を調べ、書込み記
録密度が1600rpiなら、RAM31bの命令バツ
フア管理エリアCAの最終制限値CBEに「8」
を、6250rpiなら同様に最終制限値CBEに「16」
を初期セツトし、ステツプに進む。
That is, the MPU 30 checks the write recording density of the mode area EA of the RAM 31b, and if the write recording density is 1600 rpi, sets the final limit value CBE of the instruction buffer management area CA of the RAM 31b to "8".
Similarly, for 6250rpi, the final limit value CBE is "16"
Set the initial settings and proceed to the next step.

次に、MPU30は係るライト系命令がデー
タバツフア34を使用するものかどうかを調べ
る。
Next, the MPU 30 checks whether the write-related instruction uses the data buffer 34 or not.

データバツフア34を使用しないものなら、
ステツプの命令格納ステツプへ進む。
If the data buffer 34 is not used,
Proceed to the instruction storage step.

一方、データバツフア34を使用するものな
ら、データ転送を実行する。
On the other hand, if the data buffer 34 is used, data transfer is executed.

即ち、MPU30は、RAM31bのデータ
バツフア管理エリアDAの先頭バツフアアドレ
スBADRを読出し、データ転送制御回路33
のストアアドレスカウンタSCTRにセツトし、
データ転送制御回路33を起動する。これによ
つてデータ転送制御回路33はデータ転送制御
信号線39aよりデータ転送要求をホストコン
トローラへ発する。
That is, the MPU 30 reads the first buffer address BADR of the data buffer management area DA of the RAM 31b, and transfers it to the data transfer control circuit 33.
Set the store address counter SCTR of
The data transfer control circuit 33 is activated. As a result, the data transfer control circuit 33 issues a data transfer request to the host controller via the data transfer control signal line 39a.

従つて、ホストコントローラはライトデータ
をライトデータバス39bよりデータバツフア
34へ転送し、データ転送制御回路33のスト
アアドレスカウンタSCTRのアドレスに従つて
ライトデータがデータバツフア34へ蓄積され
る。ストアアドレスカウンタSCTRはライトデ
ータが1バイト転送される毎にカウントアツプ
する。
Therefore, the host controller transfers the write data from the write data bus 39b to the data buffer 34, and the write data is stored in the data buffer 34 according to the address of the store address counter SCTR of the data transfer control circuit 33. The store address counter SCTR counts up every time one byte of write data is transferred.

データ転送制御回路33がデータ転送終了と
判定すると、MPU30はデータ転送制御回路
33のストアアドレスカウンタSCTRを読出し
データバツフア管理エリアDAのバツフアアド
レスBADRとの差を計算して転送されたライ
トデータのバイト数BCを求める。
When the data transfer control circuit 33 determines that the data transfer is completed, the MPU 30 reads the store address counter SCTR of the data transfer control circuit 33, calculates the difference between the buffer address BADR in the data buffer management area DA, and calculates the difference between the buffer address BADR and the byte of the transferred write data. Find the number BC.

次に、MPU30はRAM31bの命令バツ
フアCBUF及びデータバツフア管理エリアDA
の更新を行う。
Next, the MPU 30 uses the instruction buffer CBUF and data buffer management area DA of the RAM 31b.
Update.

先づ、RAM31bの命令バツフアCBUFの
当該命令欄にRAM31bのデータバツフア管
理エリアDAのバツフアアドレス(即ちライト
データの先頭アドレス)BADRと、算出され
たライトデータのバイト数BCを格納する。
First, the buffer address (ie, the start address of write data) BADR of the data buffer management area DA of RAM 31b and the calculated number of bytes BC of write data are stored in the relevant instruction column of the instruction buffer CBUF of RAM 31b.

次に、RAM31bのデータバツフア管理エ
リアDAの空き容量FSEGからデータバツフア
34の使用単位数USEGを差し引き、この空き
容量FSEGを更新し、更に、バツフアアドレス
BADRに使用単位数USEGを加算し、先頭アド
レスBADRを更新する。
Next, the number of used units USEG of the data buffer 34 is subtracted from the free capacity FSEG of the data buffer management area DA of the RAM 31b, this free capacity FSEG is updated, and the buffer address
Add the number of used units USEG to BADR and update the start address BADR.

次に、MPU30は前述の使用単位数(受信
ブロツク長)USEGとRAM31bのデータバ
ツフア管理エリアDAの最大ブロツク長MAXL
とを比較する。
Next, the MPU 30 uses the aforementioned number of units to be used (reception block length) USEG and the maximum block length MAXL of the data buffer management area DA of the RAM 31b.
Compare with.

この比較によつて、使用単位数USEGが最大
ブロツク長MAXLより大なら、データバツフ
ア管理エリアDAの最大ブロツク長MAXLをこ
の使用単位数USEGに更新する。更に、記録密
度と最大ブロツク長MAXLに応じて最終制限
値CBEを変更する。
As a result of this comparison, if the number of used units USEG is larger than the maximum block length MAXL, the maximum block length MAXL of the data buffer management area DA is updated to this number of used units USEG. Furthermore, the final limit value CBE is changed according to the recording density and the maximum block length MAXL.

即ち、MPU30はRAM31bのエリアEA
の書込み記録密度とエリアDAの最大ブロツク
長MAXLを読出し、記録密度が1600rpiの場合
には、最大ブロツク長MAXLが「16」より大
なら最終制限値を最小の「2」に、最大ブロツ
ク長が「16」以下なら最終制限値CBEを「4」
に設定する。
That is, the MPU 30 uses the area EA of the RAM 31b.
Read the write recording density and the maximum block length MAXL of area DA, and if the recording density is 1600rpi, if the maximum block length MAXL is greater than "16", set the final limit value to the minimum "2" and set the maximum block length to If “16” or less, set the final limit CBE to “4”
Set to .

同様に記録密度が6250rpiの場合には、最大
ブロツク長MAXLが「32」より大なら最終制
限値CBEを「2」に、最大ブロツク長MAXL
が「17」〜「32」の間では最終制限値CBEを
「4」に、最大ブロツク長MAXLが「16」以下
なら最終制限値CBEを「8」に設定する。
Similarly, when the recording density is 6250rpi, if the maximum block length MAXL is greater than "32", the final limit value CBE is set to "2", and the maximum block length MAXL is set to "2".
is between "17" and "32", the final limit value CBE is set to "4", and when the maximum block length MAXL is "16" or less, the final limit value CBE is set to "8".

逆に、使用単位数USEGが最大ブロツク長
MAXL以下なら、最大ブロツク長MAXL、最
終制限値CBEの更新は行わず、ステツプへ
進む。
Conversely, the number of units used is USEG, which is the maximum block length.
If it is less than MAXL, the maximum block length MAXL and final limit value CBE are not updated and the process advances to step.

次に、MPU30は受信したライト系命令の
格納処理を行う。
Next, the MPU 30 performs storage processing of the received write-related command.

先づ、MPU30はRAM31bの命令バツ
フアCBUFにホストインターフエイス回路32
bの受信コマンドを格納する。
First, the MPU 30 connects the host interface circuit 32 to the instruction buffer CBUF of the RAM 31b.
Store the received command of b.

次に、MPU30はRAM31bの命令バツ
フア管理エリアCAを更新すべく、命令記憶数
CBSTKに「1」加算して更新する。
Next, in order to update the instruction buffer management area CA of the RAM 31b, the MPU 30 updates the number of instructions stored in the RAM 31b.
Add "1" to CBSTK and update.

更に、MPU30は、ドライブインターフエ
イス回路32aを調べ、制御線36bのEWA
(テープ終端近傍検出)信号がオンかオフかを
調べる。オフであれば、磁気テープ16がテー
プ終端近傍に達していないので、ステツプへ
進む。
Furthermore, the MPU 30 checks the drive interface circuit 32a and checks the EWA of the control line 36b.
(Detection near end of tape) Check whether the signal is on or off. If it is off, the magnetic tape 16 has not reached the vicinity of the end of the tape, so the process advances to step.

一方、オンであれば、テープ終端近傍に達し
ているので、RAM31bのエリアEAの
LEOTフラグを調べLEOTモードなら、命令バ
ツフアサイズCBSiZEの変更を要しないので、
ステツプに進む。
On the other hand, if it is on, it means that the tape has reached the vicinity of the end of the tape, so the area EA of RAM31b
If the LEOT flag is checked and the mode is LEOT, there is no need to change the instruction buffer size CBSiZE.
Proceed to step.

逆に、LEOTモードでなければ、MPU30
はRAM31bのエリアCAの命令バツフアサ
イズCBSiZEと最終制限値CBEを読み出し比較
する。
Conversely, if it is not LEOT mode, MPU30
reads and compares the instruction buffer size CBSiZE and the final limit value CBE in area CA of the RAM 31b.

命令バツフアサイズCBSiZEが最終制限値
CBE以下ならば、命令バツフアサイズCBSiZE
を変更せず、ステツプへ進む。逆に命令バツ
フアサイズCBSiZEが最終制限値CBEより大な
らば、命令バツフアサイズCBSiZEから「2」
を減算し、更新してステツプへ進む。
Instruction buffer size CBSiZE is the final limit value
If less than CBE, instruction buffer size CBSiZE
Proceed to step without changing. Conversely, if the instruction buffer size CBSiZE is larger than the final limit value CBE, the instruction buffer size CBSiZE is set to "2".
Subtract, update, and proceed to step.

次に、MPU30はドライブ制御部2が処理
実行中かを調べ、処理実行中でなければ(停止
中であれば)、第9図にて後述するドライブ起
動処理を行う。
Next, the MPU 30 checks whether the drive control unit 2 is executing a process, and if it is not executing a process (if it is stopped), performs a drive activation process, which will be described later with reference to FIG.

処理実行中又はドライブ起動処理が行われる
と、MPU30は、ドライブインターフエイス
回路32aを介しドライブ制御部2がEOTを
検出したことを示すTWA信号が制御線36a
より生じているかを調べる。
During processing or when drive startup processing is performed, the MPU 30 transmits a TWA signal indicating that the drive control unit 2 has detected EOT via the drive interface circuit 32a to the control line 36a.
Check to see if it is occurring more frequently.

又、LEOTモードなら、MPU30は、後述
する第10図の対ドライブ処理によつて更新さ
れる走行カウンタECTRが一定値EPTRを越え
たロジカルEOT検出(オン)かを調べる。
In addition, in the LEOT mode, the MPU 30 checks whether a logical EOT is detected (on) when the travel counter ECTR, which is updated by the drive-related processing shown in FIG. 10, which will be described later, exceeds a certain value EPTR.

EOT検出でTWA信号が生じていれば又は
LEOT検出(オン)ならば、MPU30は
RAM31bの命令バツフア管理エリアCAの
命令記憶数(未実行命令数)CBSTKが零かを
調べ、零でなければ、ドライブの実行によつて
零になるまで待つ。これはEOT,LEOT以降
の処理においてはホストからの命令とドライブ
が実行する命令の同期をとるためである。
If a TWA signal is generated during EOT detection or
If LEOT detection (on), MPU30
Check whether the number of stored instructions (number of unexecuted instructions) CBSTK in the instruction buffer management area CA of the RAM 31b is zero, and if it is not zero, wait until it becomes zero by drive execution. This is to synchronize the commands from the host and the commands executed by the drive in processing after EOT and LEOT.

TWA信号が生じていない時には、又は
LEOTがオフである時には、MPU30はデー
タ転送制御回路33の状態から前述のステツプ
のライトデータ転送がデータバツフア34の
空き容量不足によつてオーバーフローしたかを
調べる。
When no TWA signal is present, or
When LEOT is off, the MPU 30 checks from the state of the data transfer control circuit 33 whether the write data transfer in the above-mentioned step has overflowed due to insufficient free space in the data buffer 34.

オーバーフローした場合には、前述と同様同
期をとるため、MPU30はRAM31bの命
令バツフア管理エリアCAの命令記憶数(未実
行命令数)CBSTKが零かを調べ、零でなけれ
ば、ドライブの実行によつて零になるまで待
つ。
If an overflow occurs, in order to synchronize as described above, the MPU 30 checks whether the number of stored instructions (number of unexecuted instructions) CBSTK in the instruction buffer management area CA of the RAM 31b is zero, and if it is not zero, it is Wait until it reaches zero.

バツフアオーバーフローが生じていない時又
はCBSTKが零となると、ホストコントローラ
へMPU30はホストインターフエイス回路3
2bより終了報告(正常受信又はエラー)する
とともにデータビジーDBY信号をオフとし、
第5図の起動待ちルーチンへ戻る。
When no buffer overflow occurs or when CBSTK becomes zero, the MPU 30 is sent to the host controller by the host interface circuit 3.
From 2b, report the completion (normal reception or error) and turn off the data busy DBY signal.
The process returns to the startup waiting routine shown in FIG.

第8図は対ホストリード系処理フロー図であ
る。
FIG. 8 is a flowchart of host read system processing.

第5図の起動処理フローのステツプによつ
てリード系命令を受け、起動処理が行われる
と、MPU30はホストインターフエイス回路
32bを介しデータビジーDBYをオンにし、
ホストコントローラへ実行開始を通知する。
When the MPU 30 receives a read command and performs the startup process according to the steps in the startup process flow shown in FIG. 5, the MPU 30 turns on the data busy DBY via the host interface circuit 32b.
Notify the host controller of the start of execution.

次に、MPU30は、RAM31bのエリア
CAの先読みブロツク数CBSTKに「1」減算
する。
Next, the MPU 30 uses the area of RAM 31b.
Subtract "1" from the number of CA look-ahead blocks CBSTK.

更に、MPU30はドライブ制御部2が処理
実行中かを調べ、処理実行中でなければ(停止
中であれば)、第9図にて後述するドライブ起
動処理を行う。
Furthermore, the MPU 30 checks whether the drive control unit 2 is executing a process, and if it is not executing a process (if it is stopped), performs a drive activation process which will be described later with reference to FIG.

又、MPU30は前述のエリアCAの命令記憶
数(先読みブロツク数)CBSTKが「0」以上
かを調べ、「0」より小のマイナスであれば、
リードデータはデータバツフア34に転送され
ていないから、CBSTKが「0」以上、即ち、
ドライブ1からリードデータが1ブロツク以上
データバツフア34に転送されるまで待つ。
In addition, the MPU 30 checks whether the number of instructions stored (preread block number) CBSTK in the area CA mentioned above is "0" or more, and if it is a negative value smaller than "0",
Since the read data has not been transferred to the data buffer 34, CBSTK is "0" or more, that is,
Wait until one or more blocks of read data are transferred from the drive 1 to the data buffer 34.

先読みブロツク数CBSTKが「0」以上とな
ると、ドライブ1からリードデータがデータバ
ツフア34に転送されているはずであるから、
MPU30は、RAM31bの命令バツフア
CBUFからリード実行結果と、リードデータの
データバツフア34内先頭アドレスRADRと、
リードバイト数RBCを読出す。
When the number of read-ahead blocks CBSTK becomes "0" or more, read data should have been transferred from drive 1 to data buffer 34.
The MPU30 is the instruction buffer of the RAM31b.
Read execution result from CBUF, start address RADR in data buffer 34 of read data,
Read the read byte count RBC.

次にMPU30は前述のステツプでRAM
31bの命令バツフアCBUFから読出したリー
ド実行結果から、ドライブが当該ブロツクを処
理した時にロードポイントLDPを検出してい
たかどうかを調べる、ロードポイントLDPを
検出していたならばリード方向を調べ、リード
リバース方向ならブロツク検出以前にBOTに
達してしまつており、リードデータはデータバ
ツフア34に転送されていないためステツプ
へ進む。
Next, the MPU30 uses the RAM in the steps mentioned above.
From the read execution result read from the instruction buffer CBUF of 31b, check whether the load point LDP was detected when the drive processed the block in question. If the load point LDP was detected, check the read direction and perform read reverse. If it is the direction, BOT has been reached before the block is detected, and the read data has not been transferred to the data buffer 34, so the process advances to step.

一方、リード方向がリードフオワード方向な
らロードポイントLDPから最初のブロツクの
リードであつたので、リード実行結果から記録
密度を調べる。リード実行結果の記録密度は読
取つた磁気テープの記録密度を示している。
On the other hand, if the read direction is the read forward direction, the first block was read from the load point LDP, so the recording density is checked from the read execution result. The recording density of the read execution result indicates the recording density of the magnetic tape read.

そして記録密度が1600rpiなら、RAM31b
の命令バツフア管理エリアCAの最終制限値
CBEに「8」を、6250rpiなら同様に最終制限
値CBEに「16」をセツトする。
And if the recording density is 1600rpi, RAM31b
Final limit value of instruction buffer management area CA
Set "8" to CBE, and similarly set "16" to final limit value CBE for 6250rpi.

更に、MPU30は、ロードポイントLDPを
検出していなかつた場合又は最終制限値CBE
のセツト後、リード実行結果から、リード実行
時にフアイルの区切りを示すテープマークが検
出されたかを調べ、テープマークが検出された
のであればリードデータはデータバツフア34
に転送されていないので、データ転送を行わ
ず、ステツプへ進む。
Furthermore, if the MPU 30 does not detect the load point LDP or the final limit value CBE
After setting, it is checked from the read execution result whether a tape mark indicating the separation of files was detected at the time of read execution, and if a tape mark was detected, the read data is transferred to the data buffer 34.
Since the data has not been transferred to the previous step, the data is not transferred and the process proceeds to step.

逆にテープマークが検出されていなければ、
ステツプの自動転送ステツプへ進む。
Conversely, if no tape mark is detected,
Proceed to automatic transfer step.

先づ、MPU30は前述のリード系命令がデ
ータ転送を伴うものか否かを判別する。データ
転送を伴なわないリード系命令としては、スペ
ース(Space)、バツクスペース(Back−
Space)、スペースフアイル(Space File)、バ
ツクスペースフアイル(Back Space File)が
ある。
First, the MPU 30 determines whether the aforementioned read-related command involves data transfer. Read instructions that do not involve data transfer include Space, Backspace, and Backspace.
Space), Space File, and Back Space File.

データ転送を伴うリード系命令なら、ホスト
コントローラへのデータ転送を実行する。
If it is a read-related command that involves data transfer, the data transfer to the host controller is executed.

即ち、MPU30は、RAM31bの命令バ
ツフアCBUFから読出した先頭バツフアアドレ
スRADRをデータ転送制御回路33のロード
アドレスカウンタLCTRに、リードバイト数を
バイトカウンタBCTRにセツトし、データ転
送制御回路33を起動する。
That is, the MPU 30 sets the first buffer address RADR read from the instruction buffer CBUF of the RAM 31b in the load address counter LCTR of the data transfer control circuit 33, sets the number of read bytes in the byte counter BCTR, and starts the data transfer control circuit 33. .

これによつてデータ転送制御回路33は、リ
ードストローブパルスRSTB(第4図A)とと
もにロードアドレスカウンタLCTRのアドレス
に従つてデータバツフア34内のリードデータ
をホストコントローラに転送する。ロードアド
レスカウンタLCTRは、リードデータを1バイ
ト転送する毎にカウントアツプする。
As a result, the data transfer control circuit 33 transfers the read data in the data buffer 34 to the host controller in accordance with the read strobe pulse RSTB (FIG. 4A) and the address of the load address counter LCTR. The load address counter LCTR counts up every time one byte of read data is transferred.

データ転送制御回路33がリードバイト数分
のデータ転送終了と判定すると、MPU30は
RAM31bのエリアDAの空き容量FSEGに使
用単位数USEGを加算し、更新する。
When the data transfer control circuit 33 determines that data transfer for the number of read bytes has been completed, the MPU 30
The number of used units USEG is added to the free capacity FSEG of area DA of the RAM 31b and updated.

一方、データ転送を伴わないリード系命令で
もリードデータはデータバツフア34内に転送
されているので、同様に空き容量FSEGの更新
を行う。
On the other hand, since the read data is transferred to the data buffer 34 even in the case of a read-related instruction that does not involve data transfer, the free capacity FSEG is updated in the same way.

次に、MPU30は前述のリード系命令がフ
アイルサーチ(File Search)系命令(スペー
スフアイル又はバツクスペースフアイル)かを
調べ、フアイルサーチ系命令なら、ステツプ
に戻る。即ち、フアイルサーチ系命令をリード
(Read)命令に分割していることになる。
Next, the MPU 30 checks whether the aforementioned read-related command is a file search-based command (space file or backspace file), and if it is a file search-based command, returns to step. In other words, file search instructions are divided into read instructions.

一方、ステツプでフアイルサーチ系命令で
ない時又はステツプでリード方向がリバース
の場合又はテープマーク検出の場合には、ホス
トコントローラMPU30はホストインターフ
エイス回路32bより終了報告(正常受信又は
エラー)するとともにデータビジーDBY信号
をオフとし、第5図の起動待ちルーチンへ戻
る。
On the other hand, if the step is not a file search command, the read direction is reversed, or a tape mark is detected, the host controller MPU 30 not only reports completion (normal reception or error) from the host interface circuit 32b but also indicates data busy. Turn off the DBY signal and return to the startup waiting routine shown in FIG.

このようにして、ライト系処理では、ロジカ
ルEOTモードでは、バツフアサイズCBSiZEは
ステツプで減少制限せずに、ロジカルEOT
オンによつてステツプで通常のEOTオンと
同様に先取り命令の禁止を行う。
In this way, in write processing, in logical EOT mode, the buffer size CBSiZE is not limited to decrease in steps, but is
When turned on, preemption commands are prohibited in the step in the same way as when EOT is turned on normally.

一方、ロジカルEOTモードでないフイジカ
ルEOTモードの時には、記録密度と最大ブロ
ツク長MAXLに応じて最終制御値CBEが変更
され(ステツプ)、EWAにおいては、ステツ
プでバツフアサイズが順次減少される。
On the other hand, in the physical EOT mode, which is not the logical EOT mode, the final control value CBE is changed (steps) according to the recording density and the maximum block length MAXL, and in EWA, the buffer size is sequentially decreased in steps.

又、リード系処理では、リード系命令の種類
を問わず先読みが行なわれる。
Further, in read-related processing, prefetching is performed regardless of the type of read-related command.

(e) 対ドライブ処理動作の説明 第9図は対ドライブ起動処理フロー図である。(e) Description of drive processing operation FIG. 9 is a flowchart of drive activation processing.

() MPU30はドライブ起動を行うべく、
RAM31bの命令バツフアCBUFより次に実
行すべき命令を読み出し、ライト系命令かを調
べる。
() In order to start the drive, MPU30
The next instruction to be executed is read from the instruction buffer CBUF of the RAM 31b and checked to see if it is a write type instruction.

ライト系命令でなければ、即ち、リード系命
令なら、MPU30は、RAM31bのエリア
CAの先読みブロツク数CBSTKが零より小の
マイナスかを調べるCBSTKが零以上であれば
すでに先読みを行つているので起動しても良い
かを調べる。起動不可(先読み時にエラーを検
出して停止している)の時はリターンする。
If it is not a write-related instruction, that is, if it is a read-related instruction, the MPU 30
Check whether the number of CA read-ahead blocks CBSTK is a negative value smaller than zero. If CBSTK is greater than or equal to zero, read-ahead has already been performed, so check whether it is OK to start. Returns if it cannot be started (an error was detected during read ahead and stopped).

一方、起動可なら、RAM31bのエリア
CAの先読みブロツク数CBSTKが「63」より
小かを調べる。小でなければRAM31bの命
令バツフアCBUFがフルのため、リターンす
る。
On the other hand, if bootable, RAM31b area
Check whether the number of look-ahead blocks CBSTK of CA is smaller than "63". If it is not, the instruction buffer CBUF in RAM 31b is full, and the process returns.

一方、先読みブロツク数が63ケより小なら、
空き容量FSEGが64Kバイト以上かを調べ、以
下ならデータ転送不可としてリターンする。
On the other hand, if the number of look-ahead blocks is less than 63,
Checks whether the free space FSEG is 64K bytes or more, and if it is less, returns as data transfer is not possible.

() ステツプ()で空き容量FSEGが64K
バイト以上なら、ドライブ1からのデータ転送
可能なため、MPU30はRAM31bの先頭
アドレスBADRをデータ転送制御回路33の
ストアアドレスカウンタSCTRにセツトし、デ
ータ転送制御回路33をスタンバイ状態とす
る。
() Step () free space FSEG is 64K
If it is a byte or more, the data can be transferred from the drive 1, so the MPU 30 sets the start address BADR of the RAM 31b in the store address counter SCTR of the data transfer control circuit 33, and puts the data transfer control circuit 33 into a standby state.

次に、MPU30はドライブインターフエイ
ス回路32aよりEWA信号がオンか、オフか
を調べ、オン(YES)なら、EWAにあるか
ら、RAM31bのLEOTモードフラグをオフ
とし、LEOTモードを解除する。
Next, the MPU 30 checks whether the EWA signal is on or off from the drive interface circuit 32a, and if it is on (YES), since it is in EWA, it turns off the LEOT mode flag in the RAM 31b and cancels the LEOT mode.

更に、MPU30はリード系命令がリードリ
バースかを調べ、リードリバースならロジカル
EOTをオフとする。
Furthermore, the MPU30 checks whether the read-related command is a read-reverse, and if it is a read-reverse, it is a logical
Turn off EOT.

このオフの後又は、EWA信号オフ又はリー
ドリバースでない場合には、MPU30はドラ
イブインターフエイス回路32aを介し、起動
(GO)信号と当該リード系命令とをドライブ
1へ発行し、リターンする。
After this OFF, or if the EWA signal is not OFF or read reverse, the MPU 30 issues a start (GO) signal and the read related command to the drive 1 via the drive interface circuit 32a, and returns.

() 一方、ステツプ()でライト系命令と
判定すると、ドライブへの自動転送準備を行
う。
() On the other hand, if it is determined in step () that it is a write-related command, preparations for automatic transfer to the drive are made.

即ち、MPU30はRAM31bの命令バツ
フアCBUFから当該ライト系命令を読出し、こ
の命令がデータ転送を伴う命令かを調べる。デ
ータ転送を伴う命令であれば、MPU30は
RAM31bの命令バツフアCBUFの先頭アド
レスWADR及びバイト数WBCをデータ転送制
御回路33のロードアドレスカウンタLATR、
バイトカウンタBCTRに各々セツトする。
That is, the MPU 30 reads the write-related instruction from the instruction buffer CBUF of the RAM 31b, and checks whether this instruction involves data transfer. If the instruction involves data transfer, the MPU30 will
The start address WADR and the number of bytes WBC of the instruction buffer CBUF of the RAM 31b are sent to the load address counter LATR of the data transfer control circuit 33,
Set each byte counter BCTR.

更にデータ転送制御回路33をスタンバイ状
態にする。このスタンバイ状態後又は、前述の
データ転送を伴なわないライト系命令(イレー
ズ、ライトテープマーク等)であれば、MPU
30は読出した命令と、起動(GO)信号をド
ライブインターフエイス回路32aを介し制御
線36aよりドライブ制御部2へ発行し、リタ
ーンする。
Furthermore, the data transfer control circuit 33 is put into a standby state. After this standby state, or if it is a write instruction (erase, write tape mark, etc.) that does not involve the aforementioned data transfer, the MPU
30 issues the read command and a start (GO) signal to the drive control section 2 from the control line 36a via the drive interface circuit 32a, and returns.

一方、ドライブ部2は、前述のステツプ
(),()で起動信号及び命令を受けると、
データビジーDBYをオンとして返答し、当該
命令の実行に入る。
On the other hand, when the drive unit 2 receives the activation signal and command at the above-mentioned steps () and (),
It responds with data busy DBY turned on and starts executing the relevant command.

例えばデータ転送を伴うライト系命令なら、
データ転送準備完了後、データ転送制御信号線
37aよりデータ転送要求をデータ転送制御回
路33へ送る。これによつてデータ転送制御回
路33はデータバツフア34のロードアドレス
カウンタLCTRで示す先頭アドレスからバイト
カウンタBCTRのバイト数分ライトデータを
ライトデータバス37bを介しドライブ制御部
2へ送り、これを実行せしめ磁気テープ16に
ライトさせる。
For example, for write instructions that involve data transfer,
After data transfer preparation is completed, a data transfer request is sent to the data transfer control circuit 33 via the data transfer control signal line 37a. As a result, the data transfer control circuit 33 sends write data corresponding to the number of bytes of the byte counter BCTR from the start address indicated by the load address counter LCTR of the data buffer 34 to the drive control unit 2 via the write data bus 37b, and causes the drive control unit 2 to execute the write data. The tape 16 is written.

また、ドライブ制御部2において係るライト
系コマンドの実行が終了すると、終了報告を制
御線36aを介しドライブインターフエイス回
路32aへ上げる。ドライブインターフエイス
回路32aは、これによつてMPU30に割込
みをかけ、第5図乃至第8図の処理を中断せし
める。
Furthermore, when the execution of the write-related command in the drive control section 2 is completed, a completion report is sent to the drive interface circuit 32a via the control line 36a. The drive interface circuit 32a thereby interrupts the MPU 30 and interrupts the processing shown in FIGS. 5 to 8.

第10図は対ドライブライト/リード処理フロ
ー図である。
FIG. 10 is a flowchart of drive write/read processing.

() MPU30はドライブより終了報告を受
けると、終了した命令種別がリード系かライト
系かを調べ、リード系ならステツプ()へ進
む。
() When the MPU 30 receives a completion report from the drive, it checks whether the type of the completed instruction is a read type or a write type, and if it is a read type, it proceeds to step ().

一方、終了した命令種別がライト系なら、
MPU30はドライブインターフエイス回路3
2aを介しEWA信号がオンかオフかを調べる。
オフ(NO)であればステツプ()へ進む。
On the other hand, if the completed instruction type is write type,
MPU30 is drive interface circuit 3
Check whether the EWA signal is on or off via 2a.
If it is off (NO), proceed to step ().

EWA信号がオン(YES)であれば、終端近
傍領域(EWA)内であるから、MPU30は
RAM31bのエリアEAのLEOTモードフラ
グを調べLEOTモードかを判別する。
If the EWA signal is on (YES), it is within the termination vicinity area (EWA), so the MPU 30
Check the LEOT mode flag of area EA of RAM 31b to determine whether it is in LEOT mode.

LEOTモードでなければ、通常のフイジカル
EOTモードであるから、ステツプ()へ進
む。
If not in LEOT mode, normal physical
Since it is EOT mode, proceed to step ().

逆にLEOTモードなら、走行カウンタの歩進
及びLEOT検出点の検出のためステツプ()
へ進む。
Conversely, in LEOT mode, step () is used to increment the travel counter and detect the LEOT detection point.
Proceed to.

() 先づ、MPU30はRAM31bのエリ
アEAの書込み記録密度を調べる。
() First, the MPU 30 checks the write recording density of the area EA of the RAM 31b.

記録密度が6250rpiか1600rpiかの判断は、以
下の走行カウンタの歩進及びLEOT検出点の検
出処理におけるライトテープマーク長WTM、
イレーズ長ERS、IBG長、判定値EPTRを異な
らせるためであり、処理自体は全く同一であ
る。
To determine whether the recording density is 6250rpi or 1600rpi, use the following step of the travel counter and write tape mark length WTM in the LEOT detection point detection process.
This is to make the erase length ERS, IBG length, and judgment value EPTR different, but the processing itself is completely the same.

即ち、MPU30は命令バツフアCBUFの命
令がライト命令、イレーズバリアブル命令、ラ
イトテープマーク命令、イレーズ固定命令かを
調べる。
That is, the MPU 30 checks whether the instruction in the instruction buffer CBUF is a write instruction, erase variable instruction, write tape mark instruction, or fixed erase instruction.

命令がライト命令又はイレーズバリアブル命
令なら、命令バツフアCBUFのバイト数RBC
を使用単位数USEGに変換し、RAM31bの
エリアEAの走行カウント値ECTRに加算更新
する。又、命令がライトテープマーク命令な
ら、固定値であるライトテープマーク長WTM
を同様に走行カウント値ECTRに加算更新す
る。
If the instruction is a write instruction or an erase variable instruction, the number of bytes in the instruction buffer CBUF RBC
is converted into the number of used units USEG, and added to and updated to the running count value ECTR of area EA in the RAM 31b. Also, if the command is a write tape mark command, the fixed value of the write tape mark length WTM
Similarly, add and update the traveling count value ECTR.

更に、命令がイレーズ固定命令なら、固定イ
レーズ長ERSを同様に走行カウント値ECTRに
加算更新する。
Furthermore, if the instruction is a fixed erase instruction, the fixed erase length ERS is similarly added and updated to the running count value ECTR.

そして、更に、IBG長を走行カウント値
ECTRに加算更新する。
Furthermore, the IBG length is set to the running count value.
Add and update to ECTR.

次に、MPU30は、LEOT検出点の検出の
ため、この走行カウント値ECTRと判定値
EPTRとを比較する。
Next, the MPU 30 uses this traveling count value ECTR and the judgment value to detect the LEOT detection point.
Compare with EPTR.

ECTR≧EPTRならLEOT検出点に達してい
るため、ロジカルEOTオンとする。ECTR<
EPTRならロジカルEOTはオンとしない。
If ECTR≧EPTR, the LEOT detection point has been reached, so logical EOT is turned on. ECTR<
For EPTR, logical EOT is not turned on.

() 次に、MPU30は係るライト系命令が
データバツフア34を使用する命令かを調べ、
使用する命令であれば、RAM31bのデータ
バツフア管理エリアDAの空き容量FSEGに使
用単位数USEGを加算し、空き容量FSEGを更
新する。
() Next, the MPU 30 checks whether the relevant write-related instruction is an instruction that uses the data buffer 34,
If the instruction is to be used, the number of used units USEG is added to the free capacity FSEG of the data buffer management area DA of the RAM 31b, and the free capacity FSEG is updated.

次に、この更新後、又はデータバツフア34
を使用していない時には、RAM31bの命令
バツフア管理エリアCAの命令記憶数CBSTK
を「1」減算し、更新する。
Next, after this update or data buffer 34
When not in use, the number of instructions stored in the instruction buffer management area CA of RAM31b CBSTK
Subtract "1" from and update.

更に、MPU30は、RAM31bの命令記
憶数CBSTKが零かを調べ、零なら第5図又は
第7図のルーチンへ戻り、零でなければ、第9
図のステツプ()以降を実行する。
Furthermore, the MPU 30 checks whether the instruction storage number CBSTK in the RAM 31b is zero, and if it is zero, returns to the routine of FIG. 5 or FIG. 7, and if it is not zero, returns to the routine of FIG.
Execute steps after step () in the diagram.

このようにしてドライブはホストコントロー
ラと非同期に命令バツフアの命令を順次実行し
ていく。
In this way, the drive sequentially executes the instructions in the instruction buffer asynchronously with the host controller.

() 一方、ステツプ()で命令種別がリー
ド系と判定されると、MPU30は命令がリー
ドリバースであつたかを調べ、リードリバース
であつたならばドライブインターフエイス回路
32aを介し、ドライブ1がロードポイント
LDPを検出しているかどうかを調べる。ロー
ドポイント検出信号が上がつていない場合、及
び命令がリードフオワードであつた場合はドラ
イブインターフエイス回路32aを介しテープ
マーク検出信号が上つているかを調べる。
() On the other hand, when the instruction type is determined to be a read type in step (), the MPU 30 checks whether the instruction is a read reverse, and if it is a read reverse, the drive 1 sends a load via the drive interface circuit 32a. point
Check whether LDP is detected. If the load point detection signal is not rising, and if the command is a lead forward word, it is checked via the drive interface circuit 32a whether the tape mark detection signal is rising.

テープマーク検出信号も上つていなければ、
ドライブ処理終了によるデータバツフア34に
転送されたリードデータのバイト数BCを計算
する。
If the tape mark detection signal does not rise,
The number of bytes BC of read data transferred to the data buffer 34 upon completion of drive processing is calculated.

即ち、MPU30はデータ転送制御回路33
のストアアドレスカウンタSCTRを読出しデー
タバツフア管理エリアDAのバツフアアドレス
BADRとの差を計算して転送されたリードデ
ータのバイト数BCを求める。
That is, the MPU 30 is the data transfer control circuit 33
Read the store address counter SCTR of the buffer address of the data buffer management area DA.
Calculate the difference from BADR to find the number of bytes of read data transferred BC.

次に、MPU30はRAM31bの命令バツ
フアCBUF及びデータバツフア管理エリアDA
の更新を行う。
Next, the MPU 30 uses the instruction buffer CBUF and data buffer management area DA of the RAM 31b.
Update.

先づ、RAM31bの命令バツフアCBUFの
当該命令欄にRAM31bのデータバツフア管
理エリアDAのバツフアアドレス(即ち先読み
リードデータの先頭アドレス)BADRと、算
出されたリードデータのバイト数BCを格納す
る。
First, the buffer address BADR of the data buffer management area DA of the RAM 31b (ie, the start address of pre-read read data) and the calculated number of bytes BC of the read data are stored in the relevant instruction column of the instruction buffer CBUF of the RAM 31b.

次に、RAM31bのデータバツフア管理エ
リアDAの空き容量FSEGからデータバツフア
34の使用単位数USEGを差し引き、この空き
容量FSEGを更新し、更に、バツフアアドレス
BADRに使用単位数USEGを加算し、先頭アド
レスBADRを更新する。
Next, the number of used units USEG of the data buffer 34 is subtracted from the free capacity FSEG of the data buffer management area DA of the RAM 31b, this free capacity FSEG is updated, and the buffer address
Add the number of used units USEG to BADR and update the start address BADR.

更に、MPU30はドライブ1がフオワード
方向の動作で且つEOTの検出をしたかを調べ
る。
Furthermore, the MPU 30 checks whether the drive 1 operates in the forward direction and detects EOT.

これによつてYESであれば、リード実行結
果(EOT検出)を命令バツフアCBUFの当該
リードデータの格納欄に格納し、第5図又は第
8図のルーチンへ戻る。
If the result is YES, the read execution result (EOT detection) is stored in the corresponding read data storage column of the instruction buffer CBUF, and the process returns to the routine of FIG. 5 or FIG. 8.

同様にテープマーク検出、リードリバースに
おいてロードポイントLDP検出の場合も、命
令バツフアCBUFにこれを格納し、第5図又は
第8図のルーチンへ戻る。
Similarly, when a load point LDP is detected during tape mark detection or read reverse, this is stored in the command buffer CBUF and the process returns to the routine of FIG. 5 or FIG. 8.

一方前述のMPU30のEOT検出等の調べに
よつてNOであれば、同様にリード実行結果
(不検出)を命令バツフアCBUFの当該リード
データの格納欄に格納する。
On the other hand, if the result of the above-mentioned EOT detection etc. of the MPU 30 is NO, the read execution result (non-detection) is similarly stored in the corresponding read data storage column of the instruction buffer CBUF.

更に、MPU30はRAM31bのエリアCA
の先読みブロツク数CBSTKが63以上かを調
べ、63以上なら、先読みリード不可として第5
図又は第8図のルーチンへ戻り、63より小なら
先読みリードを実行すべく第9図のステツプ
()へ戻る。
Furthermore, MPU30 uses area CA of RAM31b.
Check whether the number of read-ahead blocks CBSTK is 63 or more, and if it is 63 or more, read ahead is not possible and the fifth
Returning to the routine shown in FIG. 8 or FIG. 8, if the value is less than 63, the process returns to step () of FIG. 9 to execute a prefetch read.

(f) 全体動作の説明 以上、第5図から第10までの動作を要約する
と、次の如くなる。
(f) Explanation of overall operation The operations shown in FIGS. 5 to 10 can be summarized as follows.

ライト系動作においては、 (1) 通常のフイジカルEOTモードとは別にロジ
カルEOTモードが設けられている。
For write operations: (1) A logical EOT mode is provided in addition to the normal physical EOT mode.

即ち、第11図Aに示す如く、磁気テープド
ライブ部1が磁気テープ16を走行して、磁気
テープの終端近傍領域(EWA)を検出すると、
先取り制御部3が終端領域近傍時点から磁気テ
ープの走行距離を計数し、計数値ECTRが一定
値EPTRに達すると、テープ終端領域検出とみ
なし、疑似的なEOTを得るようにしている。
That is, as shown in FIG. 11A, when the magnetic tape drive section 1 runs the magnetic tape 16 and detects the end-near end area (EWA) of the magnetic tape,
The look-ahead control unit 3 counts the running distance of the magnetic tape from the time point near the end area, and when the count value ECTR reaches a certain value EPTR, it is regarded as the detection of the tape end area and a pseudo EOT is obtained.

この疑似EOT(ロジカルEOT)は通常のフ
イジカルEOT検出と同一の効果を待ち、これ
によつて実際に磁気テープに設けられたEOT
マーカを検出することなく、それ以前にEOT
の取扱いが行われる。
This pseudo EOT (logical EOT) waits for the same effect as normal physical EOT detection, and thereby detects the actual EOT provided on the magnetic tape.
EOT before that without detecting the marker
will be handled.

これによつて第11図Aに示す如くEOT検
出時点を早くすることにより、TWAを長くで
きる。このため、TWAに書込むことのできる
ブロツク数が多くなるため、第11図Bの実線
に示す如く、EWAにおけるライト系命令の先
取り数を減らす必要がなくなる。
As a result, as shown in FIG. 11A, the TWA can be lengthened by advancing the EOT detection time point. Therefore, the number of blocks that can be written to the TWA increases, so there is no need to reduce the number of write-related instructions prefetched in the EWA, as shown by the solid line in FIG. 11B.

従つて、ホストコントローラは、ライト系命
令の先取り制限をEWAにおいては受けないの
でストリーミング走行の性能低下を防止でき
る。
Therefore, the host controller is not subject to the prefetching restriction of write-related commands in EWA, and can prevent performance deterioration in streaming running.

即ち、第11図cの実線の如く、EOT付近
までは、命令先取り数はできるだけ多くし、
EOTが近づいたら、書込み可能な数に減らす
という理想的な先取り制御が可能となる。
In other words, as shown by the solid line in Figure 11c, the number of instructions prefetched is as large as possible until near EOT.
When EOT approaches, ideal preemption control is possible to reduce the number to a writable number.

これによつて、TWAに書込み不能となるこ
ともなく、性能低下を防止することができる。
This prevents writing to TWA from becoming impossible and prevents performance from deteriorating.

(2) 従つて、第5図ステツプの初期設定()、
即ち第6図cにおいて、LEOTモードならバツ
フアサイズCBSiZEは最大の「64」で減少制限
を受けない。
(2) Therefore, the initial settings of the steps in Figure 5 (),
That is, in FIG. 6c, in the LEOT mode, the buffer size CBSiZE is the maximum "64" and is not subject to any reduction restrictions.

即ち、ロジカルEOTモードであれば、第7
図のステツプにおいて、バツフアサイズ
CBSiZEの漸次減少、即ち減少制限は行われな
い。
In other words, in logical EOT mode, the seventh
In the step shown in the figure, the buffer size
Gradual reduction of CBSiZE, ie no reduction limit is performed.

そして、第10図のステツプ()におい
て、アーリーウオーニングエリアEWA検出か
らテープ走行距離が走行カウント値ECTRとし
て計測され、これが制限値EPTRに達すると、
ロジカルEOTポイント検出として、LEOTオ
ンとなり、第7図のステツプで通常のフイジ
カルEOT検出と同一の扱いが行われる。
Then, in step ( ) of FIG. 10, the tape running distance is measured as the running count value ECTR from the detection of the early warning area EWA, and when this reaches the limit value EPTR,
As logical EOT point detection, LEOT is turned on and the same handling as normal physical EOT detection is performed in the steps shown in FIG.

従つて、LEOTモードでは、LEOT点検出ま
で第11図Bの実線の如くバツフアサイズ
CBSiZEの制限を受けず、LEOT点検出で、
EOTモードと同様、実質的にCBSiZEは零とな
る。
Therefore, in LEOT mode, the buffer size increases as shown by the solid line in Figure 11B until the LEOT point is detected.
With LEOT point detection, without the limitations of CBSiZE,
As in EOT mode, CBSiZE is essentially zero.

このため、LEOTモードでは、第1図cの実
線の如く、LEOT点検出から命令記憶数
CBSTKが減少していく。
Therefore, in LEOT mode, as shown by the solid line in Figure 1c, the number of instructions stored starts from the detection of the LEOT point.
CBSTK is decreasing.

(3) 更にLEOTモードにおいて、第9図のステツ
プ()の如く、テープ走行距離計数開始後
(EWAオン後)に、リード系命令の受信、実行
などにより計数値の保証ができなくなつた時に
は、ロジカルEOTモードがオフとなつて、フ
イジカルEOTモードに移行する。
(3) Furthermore, in the LEOT mode, as shown in step () in Figure 9, if the counted value cannot be guaranteed due to reception or execution of a read-related command after tape travel distance counting has started (after EWA is turned on), , the logical EOT mode is turned off and shifts to the physical EOT mode.

(4) 一方、通常のフイジカルEOTモードであれ
ば、第5図のステツプの初期設定()、即
ち第6図cにおいてバツフアサイズCBSiZEは
最終制限値CBEにより変更される。
(4) On the other hand, in the normal physical EOT mode, the buffer size CBSiZE is changed by the final limit value CBE in the initial setting ( ) of the step in FIG. 5, ie, in FIG. 6c.

又、第7図のステツプにおいて、この最終
制限値CBEは記録密度と最大ブロツク長によ
り変更される。
Also, in the step of FIG. 7, this final limit value CBE is changed depending on the recording density and maximum block length.

即ち、最終制限値CBEは、第11図c及び
Dの如く記録密度と最大ブロツク長により決定
するようにしたものである。
That is, the final limit value CBE is determined by the recording density and the maximum block length as shown in FIG. 11c and D.

例えば、第11図Cの記録密度6250rpiの高
密度記録においては、最大ブロツク長MAXL
に応じて命令先取り最終期限値CBEを「16」
から「8」、「4」、「2」に、記録密度1600rpi
の低密度記録においては、最大ブロツク長
MAXLに応じて命令先取り最終制限値CBEを
「8」から「4」、「2」に変更するようにした
ものである。
For example, in high-density recording with a recording density of 6250 rpm as shown in Fig. 11C, the maximum block length MAXL
According to the instruction preemption final deadline value CBE is "16"
From "8", "4", "2", recording density 1600rpi
In low-density recording, the maximum block length
The instruction prefetch final limit value CBE is changed from "8" to "4" to "2" according to MAXL.

このため、EOT検出時には、記録密度と最
大ブロツク長に応じTWAを十分利用できる分
のライト系命令を先取りすることができ、
TWAを有効に利用することができる。
Therefore, when detecting EOT, it is possible to preempt write instructions that can fully utilize TWA depending on the recording density and maximum block length.
TWA can be used effectively.

更に、フイジカルEOTモードであれば、第
7図のステツプにおいてアーリーウオーニン
グエリアEWA内では、バツフアサイズ
CBSiZEは最終制限値CBE以上なら「2」づつ
減少していく。
Furthermore, in the physical EOT mode, the buffer size is adjusted within the early warning area EWA in the step shown in Figure 7.
CBSiZE decreases by 2 if it exceeds the final limit value CBE.

例えば、命令バツフアに蓄積しうるライト系
命令が64であつたものを第11図Bの点線の如
く、漸次減少するようにする。
For example, the number of write instructions that can be accumulated in the instruction buffer is 64, but is gradually reduced as shown by the dotted line in FIG. 11B.

従つて、ライト系命令の蓄積可能数を制限す
るため、ライトデータを伴わないイレーズ、ラ
イトテープマーク等のライト系命令も制限され
るから、磁気テープ内(特にTWA内)に全て
のライト系命令の実行ができ、ライト系命令の
処理不能を防止することができる。
Therefore, in order to limit the number of write-related instructions that can be stored, write-related instructions such as erase and write tape mark that do not involve write data are also limited, so all write-related instructions can be stored in the magnetic tape (especially in the TWA). can be executed, and the inability to process write instructions can be prevented.

即ち、テープ終端近傍に達しEWA信号がオ
ンとなると、バツフアサイズCBSiZEは最大値
「64」からホストコントローラからのライト系
コマンド受信毎に「2」づつ減少され、即ち命
令格納許可数が漸次減少する。更にTWA
(EOT)信号が発せられると、命令記憶数
CBSTKが零となるまで終了報告をしない。
That is, when near the end of the tape and the EWA signal is turned on, the buffer size CBSiZE is decreased from the maximum value "64" by "2" each time a write command is received from the host controller, that is, the number of commands allowed to be stored gradually decreases. Further TWA
When the (EOT) signal is issued, the number of instructions stored
Do not report completion until CBSTK reaches zero.

このため、先取り命令数は第1図cの点線で
示す如く漸次減少する。
Therefore, the number of prefetch instructions gradually decreases as shown by the dotted line in FIG. 1c.

このような漸次減少する様にすると、ホスト
コントローラは次のコマンドを受付けるまでの
時間が極度に長びかされることがない。これに
対し一挙に減少してしまうと、ホストコントロ
ーラは、(蓄積済の命令数)−(減少後の蓄積可
能命令数−1)だけの数の命令をドライブが実
行するまで次の命令が受付けられないので、ホ
ストコントローラの時間監視によつてタイムオ
ーバーによる装置異常と見なされてしまい不都
合が生じてしまう。
This gradual decrease prevents the host controller from taking an extremely long time to accept the next command. On the other hand, if the number decreases all at once, the host controller will not accept the next instruction until the drive executes the number of instructions equal to (the number of accumulated instructions) - (the number of instructions that can be accumulated after the decrease - 1). Therefore, the host controller's time monitoring will treat this as an abnormality in the device due to a timeout, resulting in an inconvenience.

従つて漸次減少によりこの不都合が防止でき
る。
Gradual reduction can therefore prevent this disadvantage.

この漸次減少は、最終制限値CBE以上であ
る時に行われ、最終制限値CBEは記録密度と
最大ブロツク長に応じて順次変更される。
This gradual reduction is performed when the value is equal to or greater than the final limit value CBE, and the final limit value CBE is sequentially changed according to the recording density and the maximum block length.

(5) 又、第7図のステツプの如く、ホストコン
トローラから起動(GO)がかかり、ライト系
コマンドが与えられると、先づ命令バツフアの
命令記憶可能数内であるかを調べ、命令記憶可
能数内であれば、このコマンドを受付け、命令
記憶可能数を越えると、このコマンドの受付け
を保留してデータビジーDBYを上げない。
(5) Also, as shown in the step in Figure 7, when a start (GO) is received from the host controller and a write command is given, it is first checked to see if the number of instructions that can be stored in the instruction buffer is within the memory capacity. If the number is within the limit, this command is accepted; if the number exceeds the maximum number of commands that can be stored, acceptance of this command is suspended and the data busy DBY is not raised.

即ち、第4図Bの如く、ドライブ側が命令バ
ツフア内の命令を実行し、命令記憶可能数以内
になるまでデータビジーを上げず、命令記憶可
能数以内となると、データビジーを上げ、処理
実行中をホストコントローラへ通知する。
That is, as shown in FIG. 4B, the drive side executes the instructions in the instruction buffer and does not raise the data busy until the number of instructions is within the storable number of instructions. Notify the host controller.

同様に、ステツプにおいて、データバツフ
アの空き容量が最大ブロツク長以上であるかを
調べ最大ブロツク長以上であれば、ホストコン
トローラからのライトデータの転送を受け、最
大ブロツク長以下なら、データ転送を保留して
データビジーDBYを上げない。
Similarly, in the step, it is checked whether the free capacity of the data buffer is greater than or equal to the maximum block length, and if it is greater than or equal to the maximum block length, the write data is transferred from the host controller, and if it is less than the maximum block length, the data transfer is suspended. Do not increase data busy DBY.

従つて、ドライブ側が命令バツフア内の命令
を実行し、データバツフアの空き容量が最大ブ
ロツク長以上になるまでデータビジーを上げ
ず、最大ブロツク長以上になると、データビジ
ーを上げ、転送受付けを可能とする。
Therefore, the drive side executes the instructions in the instruction buffer and does not raise the data busy until the free capacity of the data buffer becomes equal to or greater than the maximum block length, and when it becomes equal to or greater than the maximum block length, the data busy is raised and transfer can be accepted. .

そして、ステツプにおいて、転送されたブ
ロツク長が最大ブロツク長より大なら、実際に
転送されたブロツク長を次回より最大ブロツク
長として採用する。
Then, in the step, if the transferred block length is larger than the maximum block length, the actually transferred block length is adopted as the maximum block length from next time onwards.

このため、リトライ回数の減少及び待ち時間
の短縮の効果が生じる。
Therefore, the effect of reducing the number of retries and shortening waiting time is produced.

(g) 他の実施例の説明 上述の実施例では、ロジカルEOTモードで動
作中にリード系命令の受信実行によつて前述の(3)
で説明した如く走行カウンタの計数値が保証でき
なくなつた場合にフイジカルEOTモードに移行
するようにしているが、操作パネルよりの指示で
RAM31bのエリアEAのLEOTモードフラグ
を強制オフすることによつて、フイジカルEOT
モードのみの動作が可能とするようにしてもよ
い。
(g) Description of other embodiments In the above embodiment, the above (3) is
As explained in , the system switches to physical EOT mode when the count value of the travel counter can no longer be guaranteed.
By forcibly turning off the LEOT mode flag of area EA in RAM31b, physical EOT
It may also be possible to enable operation in only one mode.

又、上述の実施例では、フイジカルEOTモー
ドにおいて、ライト系の命令の蓄積可能数をホス
トからのライト系コマンド受信毎に漸次減少して
いるが、一挙に減少してもよく、ドライブ側の複
数命令実行毎に漸次減少するようにしてもよい。
Furthermore, in the above embodiment, in the physical EOT mode, the number of write-related commands that can be stored is gradually reduced each time a write-related command is received from the host. The number may be gradually decreased each time an instruction is executed.

更にドライブ制御部2と命令データ先取り制御
部が一体であつてもよく、ドライブ1もテープバ
ツフアを有するものであつてもよい。
Furthermore, the drive control section 2 and the command data prefetch control section may be integrated, and the drive 1 may also have a tape buffer.

しかも、最大ブロツク長MAXLも受信ブロツ
クにより変更せず、ステツプ的に変更するように
してもよい。
Furthermore, the maximum block length MAXL may not be changed depending on the reception block, but may be changed in steps.

以上本発明を実施例により説明したが、本発明
は本発明の主旨に従い種々の変形が可能であり、
本発明からこれらを排除するものではない。
Although the present invention has been described above with reference to examples, the present invention can be modified in various ways according to the gist of the present invention.
These are not excluded from the present invention.

〔発明の効果〕〔Effect of the invention〕

以上説明した様に、本発明によれば、第1のモ
ード(ロジカルEOTモード)と第2のモード
(フイジカルEOTモード)との両方の命令先取り
制御モードを有しているので、アーリーウオーニ
ングエリアEWAにおいても、ライト系命令先取
り数を制限せず、ストリーミング走行を長く維持
でる第1のモードと、EWAにおいて、ライト系
命令先取り数を適度に制限し、ストリーミング走
行を効率良く維持しながらテープウオーニングエ
リアTWAに書込めるブロツクを最大としうる第
2のモードとを自動又は手動によつて選択するこ
とができるという効果を奏し、ストリーミング動
作を円滑且つ効率良くテープ終端近傍領域EWA
で実行しうる命令先取り制御が可能となる。
As explained above, according to the present invention, since it has both the first mode (logical EOT mode) and the second mode (physical EOT mode) instruction preemption control modes, the early warning area In EWA, the first mode does not limit the number of prefetching of write-related instructions and maintains streaming for a long time. The second mode that can maximize the number of blocks that can be written in the awning area TWA can be selected automatically or manually, and the streaming operation can be performed smoothly and efficiently in the area EWA near the end of the tape.
This enables command prefetch control that can be executed with

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は本発明の原理説明図、第2図は本発明
の一実施例全体構成図、第3図は第2図構成の要
部構成図、第4図は第2図構成のデータ転送動作
説明図、第5図は本発明の一実施例起動処理フロ
ー図、第6図は第5図の初期設定処理フロー図、
第7図は本発明の一実施例のホストに対するライ
ト系処理フロー図、第8図はホストに対するリー
ド系処理フロー図、第9図はドライブに対する起
動処理フロー図、第10図はドライブに対するラ
イト/リード処理フロー図、第11図は全体動作
の説明図、第12図は磁気テープ装置の命令先取
り制御説明図、第13図は従来技術の説明図であ
る。 図中、1……磁気テープドライブ部、2……ド
ライブ制御部、3……命令・データ先取り制御
部、CBUF……命令バツフア、34……データバ
ツフア。
Fig. 1 is a diagram explaining the principle of the present invention, Fig. 2 is an overall configuration diagram of an embodiment of the invention, Fig. 3 is a main part configuration diagram of the configuration shown in Fig. 2, and Fig. 4 is a data transfer diagram of the configuration shown in Fig. 2. An operation explanatory diagram, FIG. 5 is a flowchart of the startup process of an embodiment of the present invention, FIG. 6 is a flowchart of the initialization process of FIG. 5,
FIG. 7 is a flowchart of write-related processing for the host according to an embodiment of the present invention, FIG. 8 is a flowchart of read-related processing for the host, FIG. 9 is a flowchart of startup processing for the drive, and FIG. 10 is a write/write processing flowchart for the drive. 11 is an explanatory diagram of the overall operation, FIG. 12 is an explanatory diagram of command prefetch control of a magnetic tape device, and FIG. 13 is an explanatory diagram of the prior art. In the figure, 1...Magnetic tape drive unit, 2...Drive control unit, 3...Command/data prefetch control unit, CBUF...Instruction buffer, 34...Data buffer.

Claims (1)

【特許請求の範囲】 1 磁気ヘツドと磁気テープ駆動機構を有する磁
気テープドライブ部と、 上位から与えられた命令を複数先取り蓄積しう
るバツフア部と、 該バツフア部の蓄積された命令に従つて該磁気
テープドライブ部を制御して該命令を実行する制
御部とを備える磁気テープ装置において、 該制御部が該磁気テープドライブ部によつて走
行される磁気テープの終端領域近傍を検出した
後、ライト系命令の実行中に該終端領域近傍検出
時から該磁気テープの走行距離を計数し、 該計数値が一定値に達したことでテープ終端領
域を検出したものとみなし、該終端領域近傍検出
から該テープ終端領域検出とみなした時までの間
該先取りしうる命令数を減少しない第1のモード
を実行し、 且つ該第1のモードの実行を中断した場合又は
該第1のモードを実行しない場合に、 該終端領域近傍検出に基づいて該磁気テープの
終端領域検出までの間該先取りしうる命令数を減
少するようにしたことを特徴とする磁気テープ装
置の命令先取り制御方法。 2 磁気ヘツドと磁気テープ駆動機構を有する磁
気テープドライブ部と、 上位から与えられた命令を複数先取り蓄積しう
るバツフア部を有する命令先取り制御部と、 該バツフア部の蓄積された命令に従つて該磁気
テープドライブ部を制御して該命令を実行するド
ライブ制御部とを備える磁気テープ装置であつ
て、 該命令先取り制御部は、該バツフア部に先取り
しうる命令数を管理するとともに、 ライト系命令実行中に該ドライブ制御部からの
該磁気テープの終端領域近傍を示す検出信号に基
いて該磁気テープの走行距離を計数し、該計数値
が一定値に達したことでテープ終端領域検出とみ
なし、該終端領域近傍検出から該テープ終端領域
検出とみなした時までの間該先取りしうる命令数
を減少しない第1のモードと、 該終端領域近傍検出信号に基づいて該終端領域
近傍検出から該ドライブ制御部からの終端領域検
出時までの間該先取りしうる命令数を減少する第
2のモードとを有することを特徴とする磁気テー
プ装置の命令先取り制御装置。
[Scope of Claims] 1. A magnetic tape drive unit having a magnetic head and a magnetic tape drive mechanism; a buffer unit capable of preemptively storing a plurality of commands given from a higher level; In a magnetic tape device comprising a control unit that controls a magnetic tape drive unit and executes the instruction, the control unit detects the vicinity of the end area of the magnetic tape run by the magnetic tape drive unit, and then performs a write operation. During the execution of system commands, the running distance of the magnetic tape is counted from the time when the vicinity of the end area is detected, and when the counted value reaches a certain value, it is assumed that the tape end area has been detected, and from the time when the vicinity of the end area is detected. If the first mode is executed in which the number of instructions that can be prefetched is not reduced until the tape end area is detected, and the execution of the first mode is interrupted, or the first mode is not executed. A method for prefetching instructions in a magnetic tape device, characterized in that the number of instructions that can be prefetched until detection of the end area of the magnetic tape is reduced based on detection of the vicinity of the end area. 2. A magnetic tape drive unit having a magnetic head and a magnetic tape drive mechanism; an instruction prefetch control unit having a buffer unit that can preemptively store a plurality of commands given from a higher level; The magnetic tape device includes a drive control unit that controls a magnetic tape drive unit to execute the instruction, and the instruction prefetch control unit manages the number of instructions that can be prefetched to the buffer unit, and also controls the number of instructions that can be prefetched to the buffer unit, and During execution, the running distance of the magnetic tape is counted based on a detection signal indicating the vicinity of the end area of the magnetic tape from the drive control unit, and when the counted value reaches a certain value, it is considered that the end area of the tape has been detected. , a first mode in which the number of instructions that can be prefetched is not reduced from the detection of the vicinity of the tape end area until the time when the tape end area is detected; An instruction prefetching control device for a magnetic tape device, comprising a second mode in which the number of instructions that can be prefetched is reduced until an end area is detected from a drive control unit.
JP60235807A 1985-07-12 1985-10-22 Method and apparatus for controlling instruction prefetching of magnetic tape device Granted JPS6295755A (en)

Priority Applications (8)

Application Number Priority Date Filing Date Title
JP60235807A JPS6295755A (en) 1985-10-22 1985-10-22 Method and apparatus for controlling instruction prefetching of magnetic tape device
US06/883,630 US4757396A (en) 1985-07-12 1986-07-09 Magnetic tape system with command prefetch means
AU60031/86A AU576090B2 (en) 1985-07-12 1986-07-10 Magnetic tape system
DE86305345T DE3689021T2 (en) 1985-07-12 1986-07-11 Magnetic tape system with command preselection means.
CA000513624A CA1273710A (en) 1985-07-12 1986-07-11 Magnetic tape system with command prefetch means
EP86305345A EP0213703B1 (en) 1985-07-12 1986-07-11 Magnetic tape system with command prefetch means
KR8605635A KR920004769B1 (en) 1985-07-12 1986-07-12 Magnetic tape system having command pretetching means
CA000614390A CA1280510C (en) 1985-07-12 1989-09-28 Magnetic tape system with command prefetch means

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP60235807A JPS6295755A (en) 1985-10-22 1985-10-22 Method and apparatus for controlling instruction prefetching of magnetic tape device

Publications (2)

Publication Number Publication Date
JPS6295755A JPS6295755A (en) 1987-05-02
JPH0452967B2 true JPH0452967B2 (en) 1992-08-25

Family

ID=16991540

Family Applications (1)

Application Number Title Priority Date Filing Date
JP60235807A Granted JPS6295755A (en) 1985-07-12 1985-10-22 Method and apparatus for controlling instruction prefetching of magnetic tape device

Country Status (1)

Country Link
JP (1) JPS6295755A (en)

Also Published As

Publication number Publication date
JPS6295755A (en) 1987-05-02

Similar Documents

Publication Publication Date Title
US4435762A (en) Buffered peripheral subsystems
US4517641A (en) Lookahead I/O device control subsystem
US5226141A (en) Variable capacity cache memory
EP0080876B1 (en) Cache control method and apparatus
US6038619A (en) Disk drive initiated data transfers responsive to sequential or near sequential read or write requests
JP3257916B2 (en) External storage device
US5606684A (en) On-line dumping system and disk sub-system
JPH07104817B2 (en) Data record transfer method
JPH08212054A (en) Method for operating of buffer memory and related apparatus
JPH08212015A (en) Drive device
US5136692A (en) Memory disk buffer manager
JPH0451851B2 (en)
CA1273710A (en) Magnetic tape system with command prefetch means
JPH0477367B2 (en)
JPH0452967B2 (en)
CA1322596C (en) Seeking multitasking disk controller
JPH07105084A (en) Magnetic tape look-ahead controller
JPH0452966B2 (en)
JPH0452965B2 (en)
US6088818A (en) Data read apparatus and data read method
US5581458A (en) Bufered intelligent digital tape controller with onboard ECC and featuring global control variables
JPH0451850B2 (en)
JPH0456334B2 (en)
EP0278425B1 (en) Data processing system and method with management of a mass storage buffer
JPH04311216A (en) External storage controller

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees